(PHP 5, PHP 7, PHP 8)
This class allows objects to work as arrays.
$array
= [], int $flags
= 0, string $iteratorClass
= ArrayIterator::class)ArrayObject::STD_PROP_LIST
Properties of the object have their normal functionality when accessed as list (var_dump(), foreach, etc.).
ArrayObject::ARRAY_AS_PROPS
Entries can be accessed as properties (read and write). The ArrayObject class uses its own logic to access properties, thus no warning or error is raised when trying to read or write dynamic properties.