|
ArrayObject::__constructConstruct a new array object Description
public ArrayObject::__construct
([ mixed
$input = []
[, int $flags = 0
[, string $iterator_class = "ArrayIterator"
]]] )This constructs a new array object. Parameters
Return ValuesReturns an ArrayObject object on success. Errors/ExceptionsThrows InvalidArgumentException when:
Examples
Example #1 ArrayObject::__construct example
<?php The above example will output: object(ArrayObject)#1 (3) { [1]=> string(3) "one" [2]=> string(3) "two" [3]=> string(5) "three" } See Also
|