class Illuminate / Events / NullDispatcher

NullDispatcher

Implements

Uses

Properties

protected

$dispatcher Dispatcher

The underlying event dispatcher instance.

Default: null

Methods

public

__construct ( Dispatcher $dispatcher ) : void

Create a new event dispatcher instance that does not fire.

Parameters

public

dispatch ( $event , $payload , $halt ) : void

Don't fire an event.

Parameters

  • $event string|object
  • $payload mixed
  • $halt bool
public

push ( $event , $payload ) : void

Don't register an event and payload to be fired later.

Parameters

  • $event string
  • $payload array
public

until ( $event , $payload ) : mixed

Don't dispatch an event.

Parameters

  • $event string|object
  • $payload mixed
public

listen ( $events , $listener ) : void

Register an event listener with the dispatcher.

Parameters

public

hasListeners ( $eventName ) : bool

Determine if a given event has listeners.

Parameters

  • $eventName string
public

subscribe ( $subscriber ) : void

Register an event subscriber with the dispatcher.

Parameters

  • $subscriber object|string
public

flush ( $event ) : void

Flush a set of pushed events.

Parameters

  • $event string
public

forget ( $event ) : void

Remove a set of listeners from the dispatcher.

Parameters

  • $event string
public

forgetPushed ( ) : void

Forget all of the queued listeners.

public

__call ( $method , $parameters ) : mixed

Dynamically pass method calls to the underlying dispatcher.

Parameters

  • $method string
  • $parameters array