Methods |
public
|
__construct(
string|Identifier|null $name,
array{flags?:int, extends?:(Name|null), implements?:Name[], stmts?:Stmt[], attrGroups?:AttributeGroup[]} $subNodes = [],
array<string, mixed> $attributes = [],
)
Constructs a class node.
Parameters
$name |
Name
|
$subNodes |
Array of the following optional subnodes:
'flags' => 0 : Flags
'extends' => null : Name of extended class
'implements' => array(): Names of implemented interfaces
'stmts' => array(): Statements
'attrGroups' => array(): PHP attribute groups
|
$attributes |
Additional attributes
|
Overrides
|
#
|
public
|
getSubNodeNames(): array
Gets the names of the sub nodes.
Gets the names of the sub nodes.
Returns
Implements
|
#
|
public
|
isAbstract(): bool
Whether the class is explicitly abstract.
Whether the class is explicitly abstract.
|
#
|
public
|
isFinal(): bool
Whether the class is final.
Whether the class is final.
|
#
|
public
|
isReadonly(): bool
|
#
|
public
|
isAnonymous(): bool
Whether the class is anonymous.
Whether the class is anonymous.
|
#
|
public
|
getType(): string
Gets the type of the node.
Gets the type of the node.
Returns
Implements
|
#
|