src/ArrayObject.php
private function _uxsortm($funcs, $sortMode = '')
    {
        if (!is_array($funcs)) {
            $funcs = array($funcs);
        }

        if (count($funcs) > 0) {
            if (null !== $funcs[0]) {
                if ($sortMode == 'a') {
                    $this->uasort($funcs[0]);
                } else if ($sortMode == 'k') {
                    $this->uksort($funcs[0]);
                } else {
                    $this->usort($funcs[0]);
                }
            }

            if (count($funcs) > 1) {
                $this->_uxsortmRec($this, $funcs, 1, $sortMode);
            }
        }

        return $this;
    }
private function _uxsortm($funcs, $sortMode = '')
    {
        if (!is_array($funcs)) {
            $funcs = array($funcs);
        }

        if (count($funcs) > 0) {
            if (null !== $funcs[0]) {
                if ($sortMode == 'a') {
                    $this->uasort($funcs[0]);
                } else if ($sortMode == 'k') {
                    $this->uksort($funcs[0]);
                } else {
                    $this->usort($funcs[0]);
                }
            }

            if (count($funcs) > 1) {
                $this->_uxsortmRec($this, $funcs, 1, $sortMode);
            }
        }

        return $this;
    }
Applies the first sorting function (if set) to the array's first
dimension and starts the recursion to apply the other functions (if set)

A sorting function is exactly the same as an usort callback. If you don't
want to sort a specific dimension but one or more dimensions below it,
pass <var>null</var> for each dimension that should be skipped.
<var>array(null, null, $func)</var> would sort the third dimension but
leave dimensions one and two untouched.

@param  array|callback $funcs    Sorting function(s) to sort one or more
dimensions of the array by
@param  string         $sortMode Possible values: 'a', 'k', '' (= uasort,
uksort, usort)
@return ArrayObject Provides fluent interface