original_string: private function invokeListener($listener, $event)
      {
          if (is_array($listener))
          {
              list($listenerClass, $method) = $listener;
  
              $listenerInstance = $this->objectManager->get($listenerClass);
              $listenerInstance->{$method}($event);
          }
          else
          {
              call_user_func($listener, $event);
          }
      }
code: private function invokeListener($listener, $event)
      {
          if (is_array($listener))
          {
              list($listenerClass, $method) = $listener;
  
              $listenerInstance = $this->objectManager->get($listenerClass);
              $listenerInstance->{$method}($event);
          }
          else
          {
              call_user_func($listener, $event);
          }
      }
code_tokens: private function invokeListener ( $ listener , $ event ) { if ( is_array ( $ listener ) ) { list ( $ listenerClass , $ method ) = $ listener ; $ listenerInstance = $ this -> objectManager -> get ( $ listenerClass ) ; $ listenerInstance -> { $ method } ( $ event ) ; } else { call_user_func ( $ listener , $ event ) ; } }
docstring: Invokes a listener for an event.
  
  @param callable $listener Any type of callable.
  @param object   $event    The event object.
  @return void
  
  @throws UnknownObjectException May be thrown when the listener class cannot be instantiated.
docstring_tokens: Invokes a listener for an event .