Helper class for sorting array with parametrized callback.

author Tomasz Sawicki (https://github.com/Furgas)
package Common

 Methods

Constructs the helper object for sorting array with parametrized callback.

__construct(callback $callback, array $arguments) 

Parameters

$callback

callback

Sorting callback.

$arguments

array

List of arguments to sorting callback.

Proxy to the sorter callback responsible for passing additional parameters.

sort(mixed $a, mixed $b) : int

Parameters

$a

mixed

First value to compare.

$b

mixed

Second value to compare.

Returns

int

 Properties

 

List of arguments to sorting callback.

$arguments : array

 

Sorting callback.

$callback : callback