Functions34 public, 3 private

Transforms all key-value-pairs in the provided source to its struct representation. Decoding is not done automatically.
publicstructkvpToStruct
requiredanysource
structOPTIONS{}
optionstringencodingUTF-8
optionbooleandecodeKeysfalse
optionbooleandecodeValuesfalse
optionbooleantrimKeysfalse
optionbooleantrimValuesfalse
Compares the provided structs and returns if the first struct contains the second struct.
publicbooleanstructContains
requiredstructs1
requiredstructs2
Performs a deep search in the provided struct for the specified value.
publicarraystructContainsValue
requiredstructsource
requiredstringvalue
stringpath
Copies the key-value-pairs of the provided struct. The provided struct may have a read-only lock.
publicstructstructCopyKVP
requiredstructtarget
Counts all keys (including nested ones) in the provided struct.
publicnumericstructCountDeep
requiredstructtarget
publicstructstructDelete
requiredstructstruct
NOTE: "equals" is reserved and cannot be used as named argumentequalTo
NOTE: "contains" is reserved and cannot be used as named argumentcontaining
stringbeginsWith
stringendsWith
Deletes the specified key in the provided struct. The key may reach deep into the struct, but only the last key is removed from the struct.
publicbooleanstructDeleteDeep
Struct where the key is located.
requiredstructtarget
Key or chain of keys to delete.
requiredstringkey
Deletes all keys that match an empty counterpart. Returns the numbber of keys removed.
publicnumericstructDeleteEmpty
requiredstructtarget
structOPTIONS{}
optionbooleandeleteEmptyArraysfalse
optionbooleandeleteEmptyQueryfalse
optionbooleandeleteEmptyStructsfalse
optionbooleandeleteEmptyValuestrue
optionbooleanrecursivetrue
Traverses the provided struct and removes all specified keys.
publicanystructDeleteAny
requiredanystruct
requiredstring, string[]keysToDelete
Deletes all null values in the provided struct. If a key points directly to a null value, the key is removed.
publicanystructDeleteNullValues
requiredanydata
Returns a new struct that contains the differences and only the differences of the provided data objects.
publicanystructDiff
requiredanyold
requiredanynew
booleancaseSensitivetrue
Compares keys and values of two structs and returns if they are all equal.
publicbooleanstructEquals
First struct.
requiredstructstruct1
Second struct.
requiredstructstruct2
Searches for missing keys and different values in the given structs. Case sensitive.
publicstructstructFindDifferences
requiredstructfirst
requiredstructsecond
Searches for missing keys and different values in the given structs. Case insensitive.
publicstructstructFindDifferencesNoCase
requiredstructfirst
requiredstructsecond
Searches the provided struct for the specified value. Returns the key(s) the value was found in.
publicanystructFindValue
requiredstructsource
requiredanyvalue
structOPTIONS{}
option"array", "boolean", "string"returnTypeboolean
Performs a deep search in the provided struct and returns all simple values for the specified key.
publicarraystructFindValueByKey
requiredstringkey
requiredanysource
structOPTIONS{}
optionbooleanreturnArrayfalse
optionbooleanreturnStructfalse
Flattens the given structure and returns its key with a full path.
publicarraystructFlatten
requiredstructstruct
anyfirstKey
publicstringstructHash
Struct to hash.
requiredstructsource
Algorithm to use for the hashing.
stringalgorithmMD5
Encoding to use for the hashing.
stringencodingUTF-8
Returns if the specified key in the provided struct is null.
publicbooleanstructIsNullValue
requiredstructstruct
requiredstringkey
Chains structKeyExists() calls similar to isDefined(). Supports mixed bracket/dot notation.
publicbooleanstructKeyChainExists
requiredstructstruct
requiredstringexpression
Groups all keys of the provided struct using the specified delimiters.
publicarraystructKeysByGroup
requiredstructstruct
stringdelimiters_0123456789
Merges the second struct into the first struct. The second struct may override existing values.
publicstructstructMerge
requiredanys1
requiredanys2
structOPTIONS{}
optionbooleanmergeCasetrue
optionbooleannullToEmptyStringfalse
'
publicstructstructParseChain
requiredstringchain
stringdelimiters
Searches in the provided struct using the specified regular expression and returns the key of the first occurrence.
publicstringstructREfind
requiredstringexpression
requiredstructsource
Searches in the provided struct using the specified regular expression and returns the key of the first occurrence.
publicstringstructREfindNoCase
requiredstringexpression
requiredstructsource
Filters the provided struct using the specified regular expression.
publicstructstructREfilter
requiredstringexpression
requiredstructsource
Filters the provided struct using the specified regular expression.
publicstructstructREfilterNoCase
requiredstringexpression
requiredstructsource
Shuffles the order of the top level keys in the provided struct. Returns an array of the shuffled top level keys.
publicarraystructShuffle
requiredstructsource
Sorts the keys of the provided struct according to the specified order and returns the sorted keys in an array.
publicarraystructSortKeys
requiredstructsource
requiredstringsortType
stringsortOrderASC
Sorts the provided struct by their keys and moves them to a LinkedHashMap.
publicstructstructSortToLinked
requiredstructsource
structOPTIONS{}
option"ASC", "DESC"orderByASC
Returns an array that contains the sorted key order based on their value count.
publicarraystructSortByKeyLength
requiredstructstructure
stringsortOrderCountASC
stringsortOrderKeyASC
numericpadding1
Trims all simple values in the provided struct. Complex values are ignored.
publicstructstructTrimValues
Struct with the values to trim.
requiredstructstruct
How to trim the values. SIMPLE: Remove leading and trailing whitespaces. EXTENDED: Remove leading, trailing and consecutive whitespaces.
stringlevelSIMPLE
publicarraystructValueArray
requiredstructstruct
publicstringstructValueList
requiredstructstruct
stringdelimiter,