lithium\tests\integration\test\FilterTest::_powerPerms PHP Method

_powerPerms() protected method

Methods for getting all permutations of each set in the power set of an array of strings (from the php.net manual on shuffle).
protected _powerPerms ( $arr )
    protected function _powerPerms($arr)
    {
        $powerSet = $this->_powerSet($arr);
        $result = array();
        foreach ($powerSet as $set) {
            $perms = $this->_perms($set);
            $result = array_merge($result, $perms);
        }
        return $result;
    }