PHP Class PhpParser\Node\Expr\Closure

Inheritance: extends PhpParser\Node\Expr, implements PhpParser\Node\FunctionLike
Show file Open project: nikic/PHP-Parser

Public Properties

Property Type Description
$byRef Whether to return by reference
$params Parameters
$returnType Return type
$static Whether the closure is static
$stmts Statements
$uses use()s

Public Methods

Method Description
__construct ( array $subNodes = [], array $attributes = [] ) Constructs a lambda function node.
getParams ( )
getReturnType ( )
getStmts ( )
getSubNodeNames ( )
returnsByRef ( )

Method Details

__construct() public method

Constructs a lambda function node.
public __construct ( array $subNodes = [], array $attributes = [] )
$subNodes array Array of the following optional subnodes: 'static' => false : Whether the closure is static 'byRef' => false : Whether to return by reference 'params' => array(): Parameters 'uses' => array(): use()s 'returnType' => null : Return type 'stmts' => array(): Statements
$attributes array Additional attributes

getParams() public method

public getParams ( )

getReturnType() public method

public getReturnType ( )

getStmts() public method

public getStmts ( )

getSubNodeNames() public method

public getSubNodeNames ( )

returnsByRef() public method

public returnsByRef ( )

Property Details

$byRef public property

Whether to return by reference
public $byRef

$params public property

Parameters
public $params

$returnType public property

Return type
public $returnType

$static public property

Whether the closure is static
public $static

$stmts public property

Statements
public $stmts

$uses public property

use()s
public $uses