コード例 #1
0
ファイル: Map.php プロジェクト: no22/gongo
 function __construct($seq, $callback)
 {
     parent::__construct($seq);
     if (!is_callable($callback)) {
         throw new InvalidArgumentException();
     }
     $this->callback = $callback;
 }
コード例 #2
0
ファイル: Scan.php プロジェクト: no22/gongo
 function __construct($seq, $init, $callback)
 {
     parent::__construct($seq);
     if (!is_callable($callback)) {
         throw new InvalidArgumentException();
     }
     $this->callback = $callback;
     $this->initialValue = $init;
     $this->accumulator = $init;
     $this->isCached = false;
 }
コード例 #3
0
ファイル: Follow.php プロジェクト: no22/gongo
 function __construct($first, $fn)
 {
     list($this->first, $this->fn) = func_get_args();
     $this->current_value = $first;
     parent::__construct($this);
 }
コード例 #4
0
ファイル: Chunk.php プロジェクト: no22/gongo
 function __construct($seq, $size)
 {
     parent::__construct($seq);
     $this->size = $size;
 }