substringBy(text: String, predicate: (character: String, index: Number) -> Boolean): Array<String>
Splits a string at each character where the predicate expression
returns true.
Introduced in DataWeave version 2.4.0.
Parameters
| Name | Description |
|---|---|
|
The string to split. The string is treated as an array of characters. |
|
Expression that tests each character and returns a Boolean value. The expression can iterate over each character and index of the string. |