OverloadingSetter
Overloads a class with writable magic properties.
Internally it writes the protected $_data
array whose keys are interpreted
as property names.
Example:
Foo->bar = 42;
will set$_data['bar']
to42
.
Tags
Table of Contents
Methods
Methods
__set()
Write data to an overloaded property.
public
__set(string $property, mixed $value) : void
Parameters
- $property : string
-
The class property to set
- $value : mixed
-
The new value of the property
__unset()
Unset an overloaded property.
public
__unset(string $property) : void
Parameters
- $property : string
-
The class property to unset