Collection Utilities DSC

Added by Kendy Yus, last edited by Lachlan Aldred on Feb 06, 2009  (view change)

Labels:

Enter labels to add to this page:
Wait Image 
Looking for a label? Just start typing.

Component: com.avoka.livecycle.collectionUtil 8.0

CollectionUtilService Service

Collection Util: Contains several operations on collections, i.e. Lists and Maps.

Operation Title: Convert List To Map   (convertListToMap)

Convert List To Map: Convert a List to Map. String values of the list indexes are used as the result map keys.

Input Parameter Type Description Editor
Input List java.util.List Specify list to be converted  
Output Parameter Type Description
Result Map java.util.Map Specify process variable to store the result map. Type: Map

Operation Title: Convert Map To List   (convertMapToList)

Convert Map To List: Convert a Map to List. The keys are lost and the order of the list is undefined.

Input Parameter Type Description Editor
Input Map java.util.Map Specify input map. Type: Map  
Output Parameter Type Description
Result List java.util.List Specify process variable to store the result list. Type: List

Operation Title: Clear Collection   (clearCollection)

Clear Collection: Clear Collection. Empty the content of a List or a Map. There is no way to empty a List or Map using SetValue. Note assigning a List to a List variable will append rather than overwrite the contents.

Input Parameter Type Description Editor
Collection java.lang.Object Collection to be cleared. Type: Collection  
Output Parameter Type Description
Collection java.lang.Object Cleared collection. Type: Collection

Operation Title: Create List   (createList)

Create List: Create a list from an arbitrary set of objects specified by XPath expressions. A custom editor is provided to specify the objects.

Input Parameter Type Description Editor
Element java.lang.Object A variable in this process to be passed as element in a List  
Output Parameter Type Description
Result List java.util.List Specify process variable to store the result list. Type: List

Operation Title: Create Map   (createMap)

Create Map: Create a Map from an arbitrary set of objects specified by XPath expression with keys specified. A custom editor is provided to specify the objects.

Input Parameter Type Description Editor
Key java.lang.String A string literal or XPath expression used as a key for the element to add to a Map  
Element java.lang.Object A variable in this process to be passed as element in a Map keyed by the specified key  
Output Parameter Type Description
Result Map java.util.Map Specify process variable to store the result map. Type: Map

Operation Title: Merge List   (mergeList)

Merge List: Merge a list of objects. The object could be a single object, even a collection (List of Map) in which case it will merge the content into the new list.

Input Parameter Type Description Editor
Element java.lang.Object A variable in this process to be passed as element in a List  
Output Parameter Type Description
Result List java.util.List Specify process variable to store the result list. Type: List

Operation Title: Merge Maps   (mergeMap)

Merge Maps: Merge a list of maps. Duplicate keys found in the maps specified will cause RuntimeException

Input Parameter Type Description Editor
Element java.lang.Object A variable in this process to be passed as element in a List  
Output Parameter Type Description
Result Map java.util.Map Specify process variable to store the result map. Type: Map

Operation Title: Multiple Files Reader to List   (multipleFilesReaderToList)

Multiple Files Reader to List: Reads multiple documents from different locations into a List of Document

Input Parameter Type Description Editor
File Location java.lang.Object Specify the location where documents can be read either in: repeating element of an XML, or a list containing file locations, or a map containing file locations.  
Output Parameter Type Description
List of Documents java.util.List Specify process variable to store List of Document. Type: List

Operation Title: Multiple Files Reader to Map   (multipleFilesReaderToMap)

Multiple Files Reader to Map: Reads multiple documents from different locations into a Map of Document keyed by Document name

Input Parameter Type Description Editor
File Location java.lang.Object Specify the location where documents can be read either in: repeating element of an XML, or a list containing file locations, or a map containing file locations.  
Output Parameter Type Description
Map of Documents java.util.Map Specify process variable to store Map of Document. Type: Map

Operation Title: Write List of Documents   (writeListToFiles)

Write List of Documents: Writes list of documents into a directory. Note: It will try to use filename attribute specified in each document (i.e. "wsfilename"), if not specified it will use filename "untitled".

Input Parameter Type Description Editor
Document List java.util.List List of Documents to be written.  
Directory java.lang.String The directory to write the documents to.  

Operation Title: Updates list of documents   (updateDocumentList)

Updates list of documents: Updates a list of documents, overwriting documents with same file name

Input Parameter Type Description Editor
List of Documents to Update java.util.List Specify the list of documents to update.  
List of Updated Documents java.util.List Specify the list of updates.  
Output Parameter Type Description
List of Updated Documents java.util.List Specify the process variable for the List of updated documents.

Operation Title: Updates names in a list of documents   (changeNamesOfDocumentsInList)

Updates names in a list of documents: Updates names in a list of documents with names from a different list.

Input Parameter Type Description Editor
List of Documents to Update java.util.List Specify the list of documents to update. The List must be of the same size as the List of names to update  
List of Doc names java.util.List Specify the list of names. The List must be of the same size as the List of documents it tries to update  
Output Parameter Type Description
List of Updated Documents java.util.List Specify the process variable for the List of documents with updated names.

Operation Title: Deletes a directory or a file   (deleteDirectoryOrFile)

Deletes a directory or a file:

Input Parameter Type Description Editor
Directory or file to delete java.lang.String    

Operation Title: Prints List   (printList)

Prints List:

Input Parameter Type Description Editor
List To Print java.util.List Specify the list of documents ToPrint.  

Operation Title: Remove Duplicate Elements   (removeDuplicateElements)

Remove Duplicate Elements: Removes duplicate elements from a list. If the list contains documents it removes copies of documents with the same filename.

Input Parameter Type Description Editor
List To Clean up. java.util.List Specify the list of documents to be reduced.  

Operation Title: Remove Elements   (removeAll)

Remove Elements: Subtracts from the contents of one list the contents of another list.

Input Parameter Type Description Editor
Remove From Here. java.util.List The List to be reduced in size (by the matching contents of the other list).  
Remove These. java.util.List The List to do the reducing. None of this lists elements can be found in the other list after the operation has completed.  

Operation Title: Read Multiple Documents to Map   (readMultipleDocumentsToMap)

Read Multiple Documents to Map: Reads multiple documents from a directory into a Map of Document keyed by document name

Input Parameter Type Description Editor
Directory Path java.lang.String Specify the directory path to locate documents to be read from.  
File Pattern java.lang.String Specify the file pattern. E.g. "*.pdf"  
Output Parameter Type Description
Map of Documents java.util.Map Specify process variable to store Map of Document. Type: Map of Document

Operation Title: Read Multiple Documents to List   (readMultipleDocumentsToList)

Read Multiple Documents to List: Reads multiple documents from a directory into a List of Document

Input Parameter Type Description Editor
Directory Path java.lang.String Specify the directory path to locate documents to be read from.  
File Pattern java.lang.String Specify the file pattern. E.g. "*.pdf"  
Output Parameter Type Description
List of Documents java.util.List Specify process variable to store List of Document. Type: List of Document

Operation Title: Get Filename List in Directory   (getFilenameListInDir)

Get Filename List in Directory: Get a list of filenames in the directory.

Input Parameter Type Description Editor
Directory Path java.lang.String Specify the directory path  
File Pattern java.lang.String Specify the file pattern. E.g. "*.pdf"  
Output Parameter Type Description
List of Filenames java.util.List Specify process variable to store List of Filenames. Type: List of String

For how to configure license information for this component service - Collection Util, please click on the following link:
Avoka LiveCycle ES Component License Configuration

Please send us any questions or comments on this documentation regarding Collection Util by clicking on the following link:
Feedback

Licence Configuration:

Parameter Type Description
License Key java.lang.String The license key. If blank, DSC will assume evaluation mode and allow 100 invocations or 6 hours up-time.
License Organisation java.lang.String The license organization. If blank, DSC will assume evaluation mode and allow 100 invocations or 6 hours up-time.

You are not logged in. Any changes you make will be marked as anonymous. You may want to Log In if you already have an account. You can also Sign Up for a new account.