JOOMLA中国
  • Joomla中国首页
  • 社区
  • 教程
  • 应用市场
  • B计划
Joomla! Framework TM
  • Namespace
  • Class
  • Tree
  • Deprecated

Namespaces

  • Composer
    • Autoload
  • Joomla
    • Application
      • Cli
        • Output
          • Processor
      • Web
    • Data
    • DI
      • Exception
    • Event
    • Filter
    • Input
    • Ldap
    • Registry
      • Format
    • Session
      • Storage
    • String
    • Uri
    • Utilities
  • None
  • PasswordCompat
    • binary
  • PHP
  • Psr
    • Log
  • Symfony
    • Component
      • Yaml
        • Exception
    • Polyfill
      • Util

Classes

  • AbstractEvent
  • DelegatingDispatcher
  • Dispatcher
  • Event
  • EventImmutable
  • ListenersPriorityQueue
  • Priority

Interfaces

  • DispatcherAwareInterface
  • DispatcherInterface
  • EventInterface

Traits

  • DispatcherAwareTrait
 1 <?php
 2 /**
 3  * Part of the Joomla Framework Event Package
 4  *
 5  * @copyright  Copyright (C) 2005 - 2016 Open Source Matters, Inc. All rights reserved.
 6  * @license    GNU General Public License version 2 or later; see LICENSE
 7  */
 8 
 9 namespace Joomla\Event;
10 
11 /**
12  * A dispatcher delegating its methods to an other dispatcher.
13  *
14  * @since  1.0
15  */
16 final class DelegatingDispatcher implements DispatcherInterface
17 {
18     /**
19      * The delegated dispatcher.
20      *
21      * @var    DispatcherInterface
22      *
23      * @since  1.0
24      */
25     private $dispatcher;
26 
27     /**
28      * Constructor.
29      *
30      * @param   DispatcherInterface  $dispatcher  The delegated dispatcher.
31      *
32      * @since   1.0
33      */
34     public function __construct(DispatcherInterface $dispatcher)
35     {
36         $this->dispatcher = $dispatcher;
37     }
38 
39     /**
40      * Trigger an event.
41      *
42      * @param   EventInterface|string  $event  The event object or name.
43      *
44      * @return  EventInterface  The event after being passed through all listeners.
45      *
46      * @since   1.0
47      */
48     public function triggerEvent($event)
49     {
50         return $this->dispatcher->triggerEvent($event);
51     }
52 }
53 
Joomla! Framework TM API documentation generated by ApiGen 2.8.0
Joomla!® and Joomla! Framework™ are trademarks of Open Source Matters, Inc. in the United States and other countries.