Overview

Namespaces

  • Contrib
    • Bundle
      • CoverallsBundle
        • Console
        • Entity
      • CoverallsV1Bundle
        • Api
        • Collector
        • Command
        • Config
        • Entity
          • Git
    • Component
      • File
      • Log
      • System
        • Git
  • Guzzle
    • Batch
      • Exception
    • Cache
    • Common
      • Exception
    • Http
      • Curl
      • Exception
      • Message
      • QueryAggregator
    • Inflection
    • Iterator
    • Log
    • Parser
      • Cookie
      • Message
      • UriTemplate
      • Url
    • Plugin
      • Async
      • Backoff
      • Cache
      • Cookie
        • CookieJar
        • Exception
      • CurlAuth
      • ErrorResponse
        • Exception
      • History
      • Log
      • Md5
      • Mock
      • Oauth
    • Service
      • Builder
      • Command
        • Factory
        • LocationVisitor
          • Request
          • Response
      • Description
      • Exception
      • Resource
    • Stream
  • PHP
  • Psr
    • Log
  • Symfony
    • Component
      • Config
        • Definition
          • Builder
          • Exception
        • Exception
        • Loader
        • Resource
        • Util
      • Console
        • Command
        • Formatter
        • Helper
        • Input
        • Output
        • Tester
      • EventDispatcher
        • Debug
      • Finder
        • Adapter
        • Comparator
        • Exception
        • Expression
        • Iterator
        • Shell
      • Stopwatch
      • Yaml
        • Exception

Classes

  • ContainerAwareEventDispatcher
  • Event
  • EventDispatcher
  • GenericEvent
  • ImmutableEventDispatcher

Interfaces

  • EventDispatcherInterface
  • EventSubscriberInterface
  • Overview
  • Namespace
  • Class
  • Tree
  • Todo

Class GenericEvent

Event encapsulation class.

Encapsulates events thus decoupling the observer from the subject they encapsulate.

Symfony\Component\EventDispatcher\Event
Extended by Symfony\Component\EventDispatcher\GenericEvent implements ArrayAccess, IteratorAggregate
Namespace: Symfony\Component\EventDispatcher
Author: Drak <drak@zikula.org>
Located at event-dispatcher/Symfony/Component/EventDispatcher/GenericEvent.php
Methods summary
public
# __construct( mixed $subject = null, array $arguments = array() )

Encapsulate an event with $subject and $args.

Encapsulate an event with $subject and $args.

Parameters

$subject
mixed
$subject The subject of the event, usually an object.
$arguments
array
$arguments Arguments to store in the event.
public mixed
# getSubject( )

Getter for subject property.

Getter for subject property.

Returns

mixed
$subject The observer subject.
public mixed
# getArgument( string $key )

Get argument by key.

Get argument by key.

Parameters

$key
string
$key Key.

Returns

mixed
Contents of array key.

Throws

InvalidArgumentException
If key is not found.
public Symfony\Component\EventDispatcher\GenericEvent
# setArgument( string $key, mixed $value )

Add argument to event.

Add argument to event.

Parameters

$key
string
$key Argument name.
$value
mixed
$value Value.

Returns

Symfony\Component\EventDispatcher\GenericEvent
public array
# getArguments( )

Getter for all arguments.

Getter for all arguments.

Returns

array
public Symfony\Component\EventDispatcher\GenericEvent
# setArguments( array $args = array() )

Set args property.

Set args property.

Parameters

$args
array
$args Arguments.

Returns

Symfony\Component\EventDispatcher\GenericEvent
public boolean
# hasArgument( string $key )

Has argument.

Has argument.

Parameters

$key
string
$key Key of arguments array.

Returns

boolean
public mixed
# offsetGet( string $key )

ArrayAccess for argument getter.

ArrayAccess for argument getter.

Parameters

$key
string
$key Array key.

Returns

mixed

Throws

InvalidArgumentException
If key does not exist in $this->args.

Implementation of

ArrayAccess::offsetGet()
public
# offsetSet( string $key, mixed $value )

ArrayAccess for argument setter.

ArrayAccess for argument setter.

Parameters

$key
string
$key Array key to set.
$value
mixed
$value Value.

Implementation of

ArrayAccess::offsetSet()
public
# offsetUnset( string $key )

ArrayAccess for unset argument.

ArrayAccess for unset argument.

Parameters

$key
string
$key Array key.

Implementation of

ArrayAccess::offsetUnset()
public boolean
# offsetExists( string $key )

ArrayAccess has argument.

ArrayAccess has argument.

Parameters

$key
string
$key Array key.

Returns

boolean

Implementation of

ArrayAccess::offsetExists()
public ArrayIterator
# getIterator( )

IteratorAggregate for iterating over the object like an array

IteratorAggregate for iterating over the object like an array

Returns

ArrayIterator

Implementation of

IteratorAggregate::getIterator()
Methods inherited from Symfony\Component\EventDispatcher\Event
getDispatcher(), getName(), isPropagationStopped(), setDispatcher(), setName(), stopPropagation()
Properties summary
protected mixed $subject
#

Observer pattern subject.

Observer pattern subject.

protected array $arguments
#

Array of arguments.

Array of arguments.

php-coveralls API documentation generated by ApiGen 2.8.0