Property
in package
implements
Element, MetaDataContainer
Uses
MetadataContainer
Descriptor representing a property.
Interfaces, Classes and Traits
- Element
- Interface for Api Elements
- MetaDataContainer
Table of Contents
- $default : string|null
- $docBlock : DocBlock|null
- $endLocation : Location
- $fqsen : Fqsen
- $location : Location
- $readOnly : bool
- $static : bool
- $type : Type|null
- $types : array<string|int, mixed>
- $visibility : Visibility|null
- __construct() : mixed
- addType() : void
- Add a type to this property
- getDefault() : string|null
- returns the default value of this property.
- getDocBlock() : DocBlock|null
- Returns the DocBlock of this property.
- getEndLocation() : Location
- getFqsen() : Fqsen
- Returns the Fqsen of the element.
- getLocation() : Location
- getName() : string
- Returns the name of the element.
- getType() : Type|null
- getTypes() : array<string|int, string>
- Returns the types of this property.
- getVisibility() : Visibility|null
- Return visibility of the property.
- isReadOnly() : bool
- isStatic() : bool
- Returns true when this method is static. Otherwise returns false.
Properties
$default
private
string|null
$default
= null
$docBlock
private
DocBlock|null
$docBlock
$endLocation
private
Location
$endLocation
$fqsen
private
Fqsen
$fqsen
$location
private
Location
$location
$readOnly
private
bool
$readOnly
$static
private
bool
$static
= false
$type
private
Type|null
$type
$types
private
array<string|int, mixed>
$types
= []
$visibility
private
Visibility|null
$visibility
= null
Methods
__construct()
public
__construct(Fqsen $fqsen[, Visibility|null $visibility = null ][, DocBlock|null $docBlock = null ][, string|null $default = null ][, bool $static = false ][, Location|null $location = null ][, Location|null $endLocation = null ][, Type|null $type = null ][, bool $readOnly = false ]) : mixed
Parameters
- $fqsen : Fqsen
- $visibility : Visibility|null = null
-
when null is provided a default 'public' is set.
- $docBlock : DocBlock|null = null
- $default : string|null = null
- $static : bool = false
- $location : Location|null = null
- $endLocation : Location|null = null
- $type : Type|null = null
- $readOnly : bool = false
Return values
mixed —addType()
Add a type to this property
public
addType(string $type) : void
Parameters
- $type : string
Return values
void —getDefault()
returns the default value of this property.
public
getDefault() : string|null
Return values
string|null —getDocBlock()
Returns the DocBlock of this property.
public
getDocBlock() : DocBlock|null
Return values
DocBlock|null —getEndLocation()
public
getEndLocation() : Location
Return values
Location —getFqsen()
Returns the Fqsen of the element.
public
getFqsen() : Fqsen
Return values
Fqsen —getLocation()
public
getLocation() : Location
Return values
Location —getName()
Returns the name of the element.
public
getName() : string
Return values
string —getType()
public
getType() : Type|null
Return values
Type|null —getTypes()
Returns the types of this property.
public
getTypes() : array<string|int, string>
Return values
array<string|int, string> —getVisibility()
Return visibility of the property.
public
getVisibility() : Visibility|null
Return values
Visibility|null —isReadOnly()
public
isReadOnly() : bool
Return values
bool —isStatic()
Returns true when this method is static. Otherwise returns false.
public
isStatic() : bool