Example #1
0
 private function getNotificationValue(Notification $notification)
 {
     if ($notification instanceof OnCompletedNotification) {
         throw new \Exception("Unable to get value of OnCompletedNotification");
     }
     $value = null;
     $valueGrabber = function ($v) use(&$value) {
         $value = $v;
     };
     $notification->accept($valueGrabber, $valueGrabber);
     return $value;
 }
Example #2
0
 public function __construct($value)
 {
     parent::__construct('N', true);
     $this->value = $value;
 }
Example #3
0
 public function __construct(Exception $exception)
 {
     parent::__construct('E');
     $this->exception = $exception;
 }
 public function __construct()
 {
     parent::__construct('C');
 }