Пример #1
0
 /**
  * @param callable $callable
  * @return $this
  */
 public function then($callable)
 {
     call_user_func(Compiler::getCallableObject($callable));
     return $this;
 }
 public function sort($callable)
 {
     $copy = $this->container;
     uasort($copy, Compiler::getCallableObject($callable, 2));
     return new self($copy);
 }
Пример #3
0
 public function sort($callable)
 {
     uasort($this->container, Compiler::getCallableObject($callable, 2));
     return $this;
 }
Пример #4
0
 /**
  * @param callable $callable
  * @return $this
  */
 public function otherwise($callable)
 {
     call_user_func(Compiler::getCallableObject($callable, 0));
     return $this;
 }
Пример #5
0
 /**
  * @param callable $callable
  * @return $this
  */
 public function then($callable)
 {
     call_user_func(Compiler::getCallableObject($callable, 1, false), $this->get());
     return $this;
 }