trait PropertiesTrait

Methods

$this
setProperties(array $properties)

Sets a collection of properties

$this
setProperty(PhpProperty $property)

Adds a property

getProperty(string $property)

Returns a property

boolean
hasProperty(PhpProperty|string $property)

Checks whether a property exists

$this
removeProperty(PhpProperty|string $property)

Removes a property

getProperties()

Returns a collection of properties

Details

at line line 20
$this setProperties(array $properties)

Sets a collection of properties

Parameters

array $properties

Return Value

$this

at line line 40
$this setProperty(PhpProperty $property)

Adds a property

Parameters

PhpProperty $property

Return Value

$this

at line line 53
PhpProperty getProperty(string $property)

Returns a property

Parameters

string $property property name

Return Value

PhpProperty

at line line 69
boolean hasProperty(PhpProperty|string $property)

Checks whether a property exists

Parameters

PhpProperty|string $property property name or instance

Return Value

boolean true if a property exists and false if not

at line line 83
$this removeProperty(PhpProperty|string $property)

Removes a property

Parameters

PhpProperty|string $property property name or instance

Return Value

$this

at line line 103
PhpProperty[] getProperties()

Returns a collection of properties

Return Value

PhpProperty[]