public function getEvent($name)
    {
        if (!isset($this->events[$name])) {
            throw new \LogicException(sprintf('Event "%s" is not known.', $name));
        }

        return $this->events[$name];
    }
public function getEvent($name)
    {
        if (!isset($this->events[$name])) {
            throw new \LogicException(sprintf('Event "%s" is not known.', $name));
        }

        return $this->events[$name];
    }
public function getEvent ( $ name ) { if ( ! isset ( $ this -> events [ $ name ] ) ) { throw new \ LogicException ( sprintf ( 'Event "%s" is not known.' , $ name ) ) ; } return $ this -> events [ $ name ] ; }
Returns a specific event by name.

@param string $name The event name

@return StopwatchEvent The event

@throws \LogicException When the event is not known
Returns a specific event by name .