Class ParameterGenerator

Summary

Fully Qualified Name: Laminas\Code\Generator\ParameterGenerator
Extends: AbstractGenerator

Description

Methods

Name Description Defined By
__construct() ParameterGenerator
fromArray() Generate from array ParameterGenerator
fromReflection() ParameterGenerator
generate() ParameterGenerator
getDefaultValue() ParameterGenerator
getIndentation() AbstractGenerator
getName() ParameterGenerator
getPassedByReference() ParameterGenerator
getPosition() ParameterGenerator
getSourceContent() AbstractGenerator
getType() ParameterGenerator
getVariadic() ParameterGenerator
isSourceDirty() AbstractGenerator
omitDefaultValue() ParameterGenerator
setDefaultValue() Set the default value of the parameter. ParameterGenerator
setIndentation() AbstractGenerator
setName() ParameterGenerator
setOptions() AbstractGenerator
setPassedByReference() ParameterGenerator
setPosition() ParameterGenerator
setSourceContent() AbstractGenerator
setSourceDirty() AbstractGenerator
setType() ParameterGenerator
setVariadic() ParameterGenerator

Method Details

__construct()

Parameter Name Type Description
$name string
$type string
$defaultValue mixed
$position int
$passByReference bool

Returns:

fromArray()

Generate from array

Parameter Name Type Description
$array array

Returns: \ParameterGenerator

fromReflection()

Parameter Name Type Description
$reflectionParameter \ParameterReflection

Returns: \ParameterGenerator

generate()

Returns: string

getDefaultValue()

Returns: \ValueGenerator

getIndentation()

Returns: string

getName()

Returns: string

getPassedByReference()

Returns: bool

getPosition()

Returns: int

getSourceContent()

Returns: string

getType()

Returns: string

getVariadic()

Returns: bool

isSourceDirty()

Returns: bool

omitDefaultValue()

Parameter Name Type Description
$omit bool

Returns: \ParameterGenerator

setDefaultValue()

Set the default value of the parameter.

Certain variables are difficult to express

Parameter Name Type Description
$defaultValue null|bool|string|int|float|array|\ValueGenerator

Returns: \ParameterGenerator

setIndentation()

Parameter Name Type Description
$indentation string

Returns: \AbstractGenerator

setName()

Parameter Name Type Description
$name string

Returns: \ParameterGenerator

setOptions()

Parameter Name Type Description
$options array|\Traversable

Returns: \AbstractGenerator

setPassedByReference()

Parameter Name Type Description
$passedByReference bool

Returns: \ParameterGenerator

setPosition()

Parameter Name Type Description
$position int

Returns: \ParameterGenerator

setSourceContent()

Parameter Name Type Description
$sourceContent string

Returns: \AbstractGenerator

setSourceDirty()

Parameter Name Type Description
$isSourceDirty bool

Returns: \AbstractGenerator

setType()

Parameter Name Type Description
$type string

Returns: \ParameterGenerator

setVariadic()

Parameter Name Type Description
$variadic bool

Returns: \ParameterGenerator

Top