Method | Description | |
---|---|---|
__clone ( ) : null | After a clone is called on this object, clone our deep objects. | |
__construct ( |
||
__toString ( ) : string | ||
asNonVariadic ( ) : static | Returns the Parameter in the form expected by a caller. | |
fromNode ( |
||
getDefaultValue ( ) : mixed | ||
getDefaultValueType ( ) : |
||
getUnionType ( ) : |
If this parameter is variadic (e.g. `DateTime . | |
getVariadicElementUnionType ( ) : |
If this Parameter is variadic, calling getUnionType will return an array type such as DateTime[]. This method will return the element type (such as DateTime) for variadic parameters. | |
hasDefaultValue ( ) : boolean | ||
isOptional ( ) : boolean | ||
isPassByReference ( ) : boolean | ||
isRequired ( ) : boolean | ||
isVariadic ( ) : boolean | ||
listFromNode ( |
||
setDefaultValue ( mixed $value ) : void | ||
setDefaultValueType ( |
||
setUnionType ( |
public __construct ( |
||
$context | The context in which the structural element lives | |
$name | string | |
$type | ||
$flags | integer |
public asNonVariadic ( ) : static | ||
return | static | (usually $this) |
public static fromNode ( |
||
$context | ||
$code_base | ||
$node | ast\Node | |
return | A parameter built from a node |
public getDefaultValue ( ) : mixed | ||
return | mixed | The value of the default for this parameter if one is defined, otherwise null. |
public getDefaultValueType ( ) : |
||
return | The type of the default value for this parameter if it exists |
public getUnionType ( ) : |
||
return |
public getVariadicElementUnionType ( ) : |
||
return |
public hasDefaultValue ( ) : boolean | ||
return | boolean | True if this parameter has a type for its default value |
public isOptional ( ) : boolean | ||
return | boolean | True if this is an optional parameter |
public isPassByReference ( ) : boolean | ||
return | boolean | True if this parameter is pass-by-reference i.e. prefixed with '&'. |
public isRequired ( ) : boolean | ||
return | boolean | True if this is a required parameter |
public isVariadic ( ) : boolean | ||
return | boolean | True if this parameter is variadic, i.e. can take an unlimited list of parameters and express them as an array. |
public static listFromNode ( |
||
$context | ||
$code_base | ||
$node | ast\Node | |
return | array | A list of parameters from an AST node. |
public setDefaultValue ( mixed $value ) : void | ||
$value | mixed | The value of the default for this parameter |
return | void |
public setDefaultValueType ( |
||
$type | The type of the default value for this parameter | |
return | void |