Property | Type | Description | |
---|---|---|---|
$value | Current array. |
Method | Description | |
---|---|---|
__construct ( null | array | |
Constructor. | |
__get ( $name ) | Get key | |
__set ( $name, $value ) | Set array object value | |
__toString ( ) : mixed | To string implementation. | |
count ( ) : integer | Get the number of elements inside the array. | |
countValues ( ) : |
Counts the occurrences of the same array values and groups them into an associate array. | |
first ( ) : |
Get the first element in the array. | |
getIterator ( ) : Traversable |
(PHP 5 >= 5.0.0) Retrieve an external iterator |
|
keys ( ) : |
Get only the keys of current array. | |
last ( ) : |
Get the last element in the array. | |
offsetExists ( mixed $offset ) : boolean |
(PHP 5 >= 5.0.0) Whether a offset exists |
|
offsetGet ( mixed $offset ) : mixed |
(PHP 5 >= 5.0.0) Offset to retrieve |
|
offsetSet ( mixed $offset, mixed $value ) : void |
(PHP 5 >= 5.0.0) Offset to set |
|
offsetUnset ( mixed $offset ) : void |
(PHP 5 >= 5.0.0) Offset to unset |
|
sum ( ) : number | Get the sum of all elements inside the array. | |
values ( ) : |
Get only the values of current array. |
public __construct ( null | array | |
||
$array | null | array | |
Array or ArrayAccess from which to create an ArrayObject. |
$values | null | array | Array of values that will be combined with $array. See http://www.php.net/manual/en/function.array-combine.php for more info. $array param is used as key array. |
public __toString ( ) : mixed | ||
return | mixed | String 'Array'. |
public countValues ( ) : |
||
return | An ArrayObject containing the array values as keys and number of their occurrences as values. |
public first ( ) : |
||
return | The first element in the array. |
public getIterator ( ) : Traversable | ||
return | Traversable | An instance of an object implementing Iterator or Traversable |
public keys ( ) : |
||
return | An ArrayObject containing only the keys of current array. |
public last ( ) : |
||
return | The last element in the array. |
public offsetExists ( mixed $offset ) : boolean | ||
$offset | mixed | An offset to check for. |
return | boolean | true on success or false on failure.
The return value will be casted to boolean if non-boolean was returned. |
public offsetUnset ( mixed $offset ) : void | ||
$offset | mixed | The offset to unset. |
return | void |
public values ( ) : |
||
return | An ArrayObject containing only the values of current array. |