Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?PHP
- CLASS TArraySegment implements iterator oder sowas
- {
- private $__reference = NULL;
- private $__length = NULL;
- private $__start = NULL;
- private $__first = NULL;
- private $__last = NULL;
- public function __construct(TArray &$array, $start = NULL, $length = NULL)
- {
- $this->__reference =& $array;
- $this->__start = $start;
- $this->__length = $length;
- $this->__first = ($start === NULL)
- ? 0
- : $start;
- $this->__last = ($length === NULL)
- ? $array->peek()
- : $array->peek($start + $length - 1);
- }
- }
- ?>
- object(ILLI\System\Collection\TArraySegment)#3 (5) {
- ["__reference":"ILLI\System\Collection\TArraySegment":private]=>
- &object(ILLI\System\Collection\TArray)#2 (4) {
- ["__itMode":"ILLI\System\Collection\TArray":private]=>
- int(0)
- ["__index":"ILLI\System\Collection\TArray":private]=>
- int(0)
- ["__array":"ILLI\System\ProtoArray":private]=>
- array(9) {
- [0]=>
- string(3) "The"
- [1]=>
- string(5) "quick"
- [2]=>
- string(5) "brown"
- [3]=>
- string(4) "LION"
- [4]=>
- string(5) "jumps"
- [5]=>
- string(4) "over"
- [6]=>
- string(3) "the"
- [7]=>
- string(4) "lazy"
- [8]=>
- string(3) "dog"
- }
- ["__protMode":"ILLI\System\ProtoArray":private]=>
- int(0)
- }
- ["__length":"ILLI\System\Collection\TArraySegment":private]=>
- int(5)
- ["__start":"ILLI\System\Collection\TArraySegment":private]=>
- int(2)
- ["__first":"ILLI\System\Collection\TArraySegment":private]=>
- int(2)
- ["__last":"ILLI\System\Collection\TArraySegment":private]=>
- int(6)
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement