PHP Class BetterReflection\Reflection\ReflectionType

显示文件 Open project: roave/better-reflection Class Usage Examples

Public Methods

Method Description
__toString ( ) : string Convert this string type to a string
allowsNull ( ) : boolean Does the parameter allow null?
createFromType ( phpDocumentor\Reflection\Type $type, boolean $allowsNull ) : ReflectionType
getTypeObject ( ) : phpDocumentor\Reflection\Type Get a PhpDocumentor type object for this type
isBuiltin ( ) : boolean Checks if it is a built-in type (i.e., it's not an object.

Private Methods

Method Description
__construct ( )

Method Details

__toString() public method

Convert this string type to a string
See also: https://github.com/php/php-src/blob/master/ext/reflection/php_reflection.c#L2993
public __toString ( ) : string
return string

allowsNull() public method

Does the parameter allow null?
public allowsNull ( ) : boolean
return boolean

createFromType() public static method

public static createFromType ( phpDocumentor\Reflection\Type $type, boolean $allowsNull ) : ReflectionType
$type phpDocumentor\Reflection\Type
$allowsNull boolean
return ReflectionType

getTypeObject() public method

Get a PhpDocumentor type object for this type
public getTypeObject ( ) : phpDocumentor\Reflection\Type
return phpDocumentor\Reflection\Type

isBuiltin() public method

..)
See also: http://php.net/manual/en/reflectiontype.isbuiltin.php
public isBuiltin ( ) : boolean
return boolean