Skip to main content

prependCollection

Short summary

This method adds all elements of the given collection to the start of this list. Example: For the list1: A B C and list2: D E F will be after list1.prependCollection(list2): D E F A B C. Notice the elements are still in the same order they where befor on each subsection.

Return: CNM_ReturnTypes.SingleExecutionResult.SUCCESS: prepend was successful CNM_ReturnTypes.SingleExecutionResult.ERROR: collection to prepend didn't fit in old container, and new container couldn't be allocated CNM_ReturnTypes.SingleExecutionResult.ABORTED: NULL object or this arraylist was passed

Parameters

NameTypeCommentKind
collectionToPrependCNM_CollectionInterfaces.ICollectionThe collection to be prependedinput

Code

Declaration

METHOD ABSTRACT prependCollection :CNM_ReturnTypes.SingleExecutionResult
VAR_INPUT
(*The collection to be prepended*)
collectionToPrepend :CNM_CollectionInterfaces.ICollection;
END_VAR