| @@ 658-666 (lines=9) @@ | ||
| 655 | * |
|
| 656 | * @return $this An Arrayy object with pushed elements to the end of array |
|
| 657 | */ |
|
| 658 | public function push(/* variadic arguments allowed */) |
|
| 659 | { |
|
| 660 | if (func_num_args()) { |
|
| 661 | $args = array_merge(array(&$this->array), func_get_args()); |
|
| 662 | call_user_func_array('array_push', $args); |
|
| 663 | } |
|
| 664 | ||
| 665 | return $this; |
|
| 666 | } |
|
| 667 | ||
| 668 | /** |
|
| 669 | * Shifts a specified value off the beginning of array. |
|
| @@ 683-691 (lines=9) @@ | ||
| 680 | * |
|
| 681 | * @return Arrayy Array object with prepended elements to the beginning of array |
|
| 682 | */ |
|
| 683 | public function unshift(/* variadic arguments allowed */) |
|
| 684 | { |
|
| 685 | if (func_num_args()) { |
|
| 686 | $args = array_merge(array(&$this->array), func_get_args()); |
|
| 687 | call_user_func_array('array_unshift', $args); |
|
| 688 | } |
|
| 689 | ||
| 690 | return $this; |
|
| 691 | } |
|
| 692 | ||
| 693 | /** |
|
| 694 | * Get a value by key. |
|