Class: a
This class is supposed to simplify array handling
and make it more consistent.
Methods
-
a::contains
Checks if an array contains a certain string
-
a::extract
Extracts a single column from an array
-
a::fill
Fills an array up with additional elements to certain amount.
-
a::first
Returns the first element of an array
-
a::get
Gets an element of an array by key
-
a::getall
Gets all elements for an array of key
-
a::inject
Injects an element into an array
-
a::json
Converts an array to a JSON string
It's basically a shortcut for json_encode() -
a::last
Returns the last element of an array
-
a::missing
Checks for missing elements in an array
-
a::remove
Removes an element from an array
-
a::search
Search for elements in an array by regular expression
-
a::show
Shows an entire array or object in a human readable way
This is perfect for debugging -
a::shuffle
Shuffles an array and keeps the keys
-
a::sort
Sorts a multi-dimensional array by a certain column
-
a::xml
Converts an array to a XML string