Helper class for working with arrays.
package | Default |
---|
assertNoDuplicates(array $_array, callable $key) : array
Throws \FeaturePhp\Helper\ArrayException if duplicates are found.
array
callable
array
findByKey(array $array, callable $key, mixed $value) : object
array
callable
mixed
object
schwartzianTransform(array $_array, callable $func) : array
This is useful if the key should only be calculated once per element (https://gregheo.com/blog/schwartzian-transform/).
array
callable
extracts a string value from an element
array
sortByKey(array $_array, callable $key) : array
array
callable
array