original_string: public static function instance($name = 'default')
      {
          if (!isset(static::$_instances[$name])) {
              static::$_instances[$name] = new EventDispatcher();
          }
  
          return static::$_instances[$name];
      }
code: public static function instance($name = 'default')
      {
          if (!isset(static::$_instances[$name])) {
              static::$_instances[$name] = new EventDispatcher();
          }
  
          return static::$_instances[$name];
      }
code_tokens: public static function instance ( $ name = 'default' ) { if ( ! isset ( static :: $ _instances [ $ name ] ) ) { static :: $ _instances [ $ name ] = new EventDispatcher ( ) ; } return static :: $ _instances [ $ name ] ; }
docstring: Gets an instance of this class.
  
  @param string $name Name of the Event Dispatcher instance to get, if does not
  exists a new instance will be created and registered
  @return \CMS\Event\EventDispatcher
docstring_tokens: Gets an instance of this class .