Download the PHP package fg/parkour without Composer
On this page you can find all versions of the php package fg/parkour. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Package parkour
Short Description A collection of utilities to manipulate arrays.
License BSD-2-Clause
Homepage http://github.com/felixgirault/parkour
Informations about the package parkour
Parkour
A collection of utilities to manipulate arrays.
The aim of this library is to provide a consistent API, unlike the one natively implemented in PHP.
Examples
Using your own functions:
Using some of the built-in functors:
API
Traverse
each(), map(), mapKeys(), filter(), reject(), reduce(), find(), findKey(), some(), every().
each()
map()
mapKeys()
filter()
reject()
reduce()
Using built-in functors:
find()
findKey()
some()
Using a built-in functor:
every()
Using a built-in functor:
Transform
combine(), normalize(), reindex(), merge().
combine()
normalize()
reindex()
merge()
Access
has(), get(), set(), update().
has()
get()
set()
update()
Functors
Add,
AlwaysFalse,
AlwaysTrue,
Cunjunct,
Disjunct,
Divide,
Equal,
Greater,
GreaterOrEqual,
Identical,
Identity,
Lower,
LowerOrEqual,
Multiply,
NotEqual,
NotIdentical,
Substract.
The vast majority of these functors can be used in two different ways.
Without any configuration:
Or with a fixed parameter: