Arrays (dw::core::Arrays)
This module contains helper functions for working with arrays.
To use this module, you must import it to your DataWeave code, for example,
by adding the line import * from dw::core::Arrays
to the header of your
DataWeave script.
Functions
Name | Description |
---|---|
Counts the elements in an array that match the results of a function. |
|
Breaks up an array into sub-arrays that contain the specified number of elements. |
|
Drops the first |
|
Drops elements from the array while the condition is met but stops the selection process when it reaches an element that fails to satisfy the condition. |
|
Returns |
|
Returns the first element that satisfies the condition, or returns |
|
Returns the index of the first occurrence of an element within the array. |
|
Returns the index of the first occurrence of an element that matches a condition within the array. |
|
Joins two arrays of objects by a given ID criteria. |
|
Joins two arrays of objects by a given ID criteria. |
|
Joins two array of objects by a given |
|
Separates the array into the elements that satisfy the condition from those that do not. |
|
Selects the interval of elements that satisfy the condition:
|
|
Returns |
|
Splits an array into two at a given position. |
|
Splits an array into two at the first position where the condition is met. |
|
Returns the sum of the values of the elements in an array. |
|
Selects the first |
|
Selects elements from the array while the condition is met but stops the selection process when it reaches an element that fails to satisfy the condition. |