コード例 #1
0
ファイル: HookManager.php プロジェクト: nhp/shopware-4
 /**
  * Checks if the given class has registered hooks.
  * If a method is given the examination is limited to the method.
  *
  * @param   $class
  * @param   $method
  * @return  bool
  */
 public function hasHooks($class, $method)
 {
     $eventManager = $this->application->Events();
     return $eventManager->hasListeners($this->getHookEvent($class, $method, 'replace')) || $eventManager->hasListeners($this->getHookEvent($class, $method, 'before')) || $eventManager->hasListeners($this->getHookEvent($class, $method, 'after'));
 }