Documentation

Class_
in package
implements Element, MetaDataContainer Uses MetadataContainer

Descriptor representing a Class.

Interfaces, Classes and Traits

Element
Interface for Api Elements
MetaDataContainer

Table of Contents

$abstract  : bool
$constants  : array<string|int, mixed>
$docBlock  : DocBlock|null
$endLocation  : Location
$final  : bool
$fqsen  : Fqsen
$implements  : array<string|int, mixed>
$location  : Location
$methods  : array<string|int, mixed>
$parent  : Fqsen|null
$properties  : array<string|int, mixed>
$readOnly  : bool
$usedTraits  : array<string|int, mixed>
__construct()  : mixed
Initializes a number of properties with the given values. Others are initialized by definition.
addConstant()  : void
Add Constant to this class.
addInterface()  : void
Add a interface Fqsen this class is implementing.
addMethod()  : void
Add a method to this class.
addProperty()  : void
Add a property to this class.
addUsedTrait()  : void
Add trait fqsen used by this class.
getConstants()  : array<string|int, Constant>
Returns the constants of this class.
getDocBlock()  : DocBlock|null
getEndLocation()  : Location
getFqsen()  : Fqsen
Returns the Fqsen of the element.
getInterfaces()  : array<string|int, Fqsen>
Returns the interfaces this class is implementing.
getLocation()  : Location
getMethods()  : array<string|int, Method>
Returns the methods of this class.
getName()  : string
Returns the name of the element.
getParent()  : Fqsen|null
Returns the superclass this class is extending if available.
getProperties()  : array<string|int, Property>
Returns the properties of this class.
getUsedTraits()  : array<string|int, Fqsen>
Returns the traits used by this class.
isAbstract()  : bool
Returns true when this class is abstract. Otherwise returns false.
isFinal()  : bool
Returns true when this class is final. Otherwise returns false.
isReadOnly()  : bool
Returns true when this class is read-only. Otherwise returns false.

Properties

$abstract

private bool $abstract = false

Whether this is an abstract class.

$constants

private array<string|int, mixed> $constants = []

References to constants defined in this class.

$final

private bool $final = false

Whether this class is marked as final and can't be subclassed.

$fqsen

private Fqsen $fqsen

Full Qualified Structural Element Name

$implements

private array<string|int, mixed> $implements = []

References to interfaces that are implemented by this class.

$methods

private array<string|int, mixed> $methods = []

References to methods defined in this class.

$parent

private Fqsen|null $parent = null

The class this class is extending.

$properties

private array<string|int, mixed> $properties = []

References to properties defined in this class.

$readOnly

private bool $readOnly = false

$usedTraits

private array<string|int, mixed> $usedTraits = []

References to traits consumed by this class

Methods

__construct()

Initializes a number of properties with the given values. Others are initialized by definition.

public __construct(Fqsen $fqsen[, DocBlock|null $docBlock = null ][, Fqsen|null $parent = null ][, bool $abstract = false ][, bool $final = false ][, Location|null $location = null ][, Location|null $endLocation = null ][, bool $readOnly = false ]) : mixed
Parameters
$fqsen : Fqsen
$docBlock : DocBlock|null = null
$parent : Fqsen|null = null
$abstract : bool = false
$final : bool = false
$location : Location|null = null
$endLocation : Location|null = null
$readOnly : bool = false
Return values
mixed

addConstant()

Add Constant to this class.

public addConstant(Constant $constant) : void
Parameters
$constant : Constant
Return values
void

addInterface()

Add a interface Fqsen this class is implementing.

public addInterface(Fqsen $interface) : void
Parameters
$interface : Fqsen
Return values
void

addMethod()

Add a method to this class.

public addMethod(Method $method) : void
Parameters
$method : Method
Return values
void

addProperty()

Add a property to this class.

public addProperty(Property $property) : void
Parameters
$property : Property
Return values
void

addUsedTrait()

Add trait fqsen used by this class.

public addUsedTrait(Fqsen $fqsen) : void
Parameters
$fqsen : Fqsen
Return values
void

getConstants()

Returns the constants of this class.

public getConstants() : array<string|int, Constant>
Return values
array<string|int, Constant>

getFqsen()

Returns the Fqsen of the element.

public getFqsen() : Fqsen
Return values
Fqsen

getInterfaces()

Returns the interfaces this class is implementing.

public getInterfaces() : array<string|int, Fqsen>
Return values
array<string|int, Fqsen>

getMethods()

Returns the methods of this class.

public getMethods() : array<string|int, Method>
Return values
array<string|int, Method>

getName()

Returns the name of the element.

public getName() : string
Return values
string

getParent()

Returns the superclass this class is extending if available.

public getParent() : Fqsen|null
Return values
Fqsen|null

getProperties()

Returns the properties of this class.

public getProperties() : array<string|int, Property>
Return values
array<string|int, Property>

getUsedTraits()

Returns the traits used by this class.

public getUsedTraits() : array<string|int, Fqsen>
Return values
array<string|int, Fqsen>

isAbstract()

Returns true when this class is abstract. Otherwise returns false.

public isAbstract() : bool
Return values
bool

isFinal()

Returns true when this class is final. Otherwise returns false.

public isFinal() : bool
Return values
bool

isReadOnly()

Returns true when this class is read-only. Otherwise returns false.

public isReadOnly() : bool
Return values
bool

Search results