Beispiel #1
0
 /**
  * Fires a log event.
  *
  * @param  string  $level
  * @param  array   $parameters
  * @return void
  */
 protected function fireLogEvent($level, $message, array $context = array())
 {
     // If the event dispatcher is set, we will pass along the parameters to the
     // log listeners. These are useful for building profilers or other tools
     // that aggregate all of the log messages for a given "request" cycle.
     if (isset($this->dispatcher)) {
         $this->dispatcher->fire('illuminate.log', compact('level', 'message', 'context'));
     }
 }
Beispiel #2
0
 /**
  * Fires an event for the extension.
  *
  * @param  string  $name
  * @return mixed
  */
 protected function fireEvent($name)
 {
     if (!isset(static::$dispatcher)) {
         return;
     }
     return static::$dispatcher->fire("extension.{$name}", array($this));
 }