private static function isValidData($input)
    {
        $type = gettype($input);

        return ($type === 'array')
            || ($type === 'string')
            || ($type === 'double')
            || ($type === 'integer')
            || ($type === 'boolean')
            || ($type === 'NULL');
    }
private static function isValidData($input)
    {
        $type = gettype($input);

        return ($type === 'array')
            || ($type === 'string')
            || ($type === 'double')
            || ($type === 'integer')
            || ($type === 'boolean')
            || ($type === 'NULL');
    }
private static function isValidData ( $ input ) { $ type = gettype ( $ input ) ; return ( $ type === 'array' ) || ( $ type === 'string' ) || ( $ type === 'double' ) || ( $ type === 'integer' ) || ( $ type === 'boolean' ) || ( $ type === 'NULL' ) ; }
Determines whether a value can be used as the data value in an error
object.

@param null|boolean|integer|float|string|array $input
An optional primitive value that contains additional information about
the error. You're free to define the format of this data (e.g. you could
supply an array with detailed error information). Alternatively, you may
omit this field by supplying a null value.

@return bool
Returns true iff the value can be used as the data value in an error
object.
Determines whether a value can be used as the data value in an error object .