ReflectionClosure
extends ReflectionFunction
in package
Table of Contents
Properties
- $classes : mixed
- $code : mixed
- $constants : mixed
- $files : mixed
- $functions : mixed
- $hashedName : mixed
- $isBindingRequired : mixed
- $isScopeRequired : mixed
- $isShortClosure : mixed
- $isStaticClosure : mixed
- $structures : mixed
- $tokens : mixed
- $useVariables : mixed
Methods
- __construct() : void
- Creates a new reflection closure instance.
- getCode() : string
- Get the closure's code.
- getUseVariables() : array<string|int, mixed>
- Gets the use variables by the closure.
- isBindingRequired() : bool
- Checks if binding is required.
- isScopeRequired() : bool
- Checks if access to the scope is required.
- isShortClosure() : bool
- Checks if the closure is a "short closure".
- isStatic() : bool
- Checks if the closure is "static".
- fetchItems() : mixed
- Fetch the items.
- getBuiltinTypes() : array<string|int, mixed>
- Get PHP native built in types.
- getClasses() : array<string|int, mixed>
- Get the classes.
- getClosureNamespaceName() : string
- Returns the namespace associated to the closure.
- getConstants() : array<string|int, mixed>
- Gets the constants.
- getFileTokens() : array<string|int, mixed>
- Get the file tokens.
- getFunctions() : array<string|int, mixed>
- Get the functions.
- getHashedFileName() : string
- The the hash of the current file name.
- getStructures() : array<string|int, mixed>
- Get the structures.
- getTokens() : array<string|int, mixed>
- Get the tokens.
- parseNameQualified() : array<string|int, mixed>
- Parse the given token.
Properties
$classes
protected
static mixed
$classes
= []
$code
protected
mixed
$code
$constants
protected
static mixed
$constants
= []
$files
protected
static mixed
$files
= []
$functions
protected
static mixed
$functions
= []
$hashedName
protected
mixed
$hashedName
$isBindingRequired
protected
mixed
$isBindingRequired
$isScopeRequired
protected
mixed
$isScopeRequired
$isShortClosure
protected
mixed
$isShortClosure
$isStaticClosure
protected
mixed
$isStaticClosure
$structures
protected
static mixed
$structures
= []
$tokens
protected
mixed
$tokens
$useVariables
protected
mixed
$useVariables
Methods
__construct()
Creates a new reflection closure instance.
public
__construct(Closure $closure[, string|null $code = null ]) : void
Parameters
- $closure : Closure
- $code : string|null = null
getCode()
Get the closure's code.
public
getCode() : string
Return values
stringgetUseVariables()
Gets the use variables by the closure.
public
getUseVariables() : array<string|int, mixed>
Return values
array<string|int, mixed>isBindingRequired()
Checks if binding is required.
public
isBindingRequired() : bool
Return values
boolisScopeRequired()
Checks if access to the scope is required.
public
isScopeRequired() : bool
Return values
boolisShortClosure()
Checks if the closure is a "short closure".
public
isShortClosure() : bool
Return values
boolisStatic()
Checks if the closure is "static".
public
isStatic() : bool
Return values
boolfetchItems()
Fetch the items.
protected
fetchItems() : mixed
Tags
getBuiltinTypes()
Get PHP native built in types.
protected
static getBuiltinTypes() : array<string|int, mixed>
Return values
array<string|int, mixed>getClasses()
Get the classes.
protected
getClasses() : array<string|int, mixed>
Return values
array<string|int, mixed>getClosureNamespaceName()
Returns the namespace associated to the closure.
protected
getClosureNamespaceName() : string
Return values
stringgetConstants()
Gets the constants.
protected
getConstants() : array<string|int, mixed>
Return values
array<string|int, mixed>getFileTokens()
Get the file tokens.
protected
getFileTokens() : array<string|int, mixed>
Return values
array<string|int, mixed>getFunctions()
Get the functions.
protected
getFunctions() : array<string|int, mixed>
Return values
array<string|int, mixed>getHashedFileName()
The the hash of the current file name.
protected
getHashedFileName() : string
Return values
stringgetStructures()
Get the structures.
protected
getStructures() : array<string|int, mixed>
Return values
array<string|int, mixed>getTokens()
Get the tokens.
protected
getTokens() : array<string|int, mixed>
Return values
array<string|int, mixed>parseNameQualified()
Parse the given token.
protected
parseNameQualified(string $token) : array<string|int, mixed>
Parameters
- $token : string