-
-
Notifications
You must be signed in to change notification settings - Fork 1
SplArrayObject
O2System PHP Framework edited this page Sep 16, 2016
·
7 revisions
This class is an extension class from ArrayObject, the purposes of this class is allows objects to work as arrays. The SplArrayObject class is use ArrayConversionTrait and ArrayFunctionsTrait to robust the class functionalities.
O2System\Spl\DatastructuresO2System\Spl\Datastructures\SplArrayObjectuse O2System\Spl\Datastructures\SplArrayObject;
$vehicles = new SplArrayObject();
$vehicles['cars'] = ['Ferrari', 'Porsche'];O2System\Spl\Datastructures\SplArrayObject class constructor.
| Parameter | type | Requirement | Description |
|---|---|---|---|
$array |
array |
optional | initial array |
$flag |
int |
optional | ArrayObject Flags |
| Type | Description |
|---|---|
void |
no returns |
$vehicles = new SplArrayObject( [ 'cars' => [ 'Ferrari', 'Porsche' ] ], SplArrayObject::ARRAY_AS_PROPS );Copyright (c) 2016 Steeve Andrian Salim - O2System PHP Framework