Esempio n. 1
0
 private function make_static_stream()
 {
     return Stream::make(10, 20, 30);
 }
Esempio n. 2
0
 public static function range($low = null, $high = null)
 {
     if ($low === null) {
         $low = 1;
     }
     if ($low == $high) {
         return Stream::make($low);
     }
     return new Stream($low, function () use($low, $high) {
         return Stream::range($low + 1, $high);
     });
 }