public static function filterKeys(array $input, $included = [])
    {
        if (is_null($included) || count($included) == 0) {
            return $input;
        }

        return array_intersect_key($input, array_flip($included));
    }
public static function filterKeys(array $input, $included = [])
    {
        if (is_null($included) || count($included) == 0) {
            return $input;
        }

        return array_intersect_key($input, array_flip($included));
    }
public static function filterKeys ( array $ input , $ included = [ ] ) { if ( is_null ( $ included ) || count ( $ included ) == 0 ) { return $ input ; } return array_intersect_key ( $ input , array_flip ( $ included ) ) ; }
Filter the keys of an array to only the allowed set.

@param array $input
@param array $included

@throws InvalidArgumentException
@return array
@deprecated
Filter the keys of an array to only the allowed set .