willdurand/propel-eventdispatcher-behavior

This package is abandoned and no longer maintained. No replacement package was suggested.

Integrates the Symfony2 EventDispatcher component in your Model classes.

Maintainers

👁 couac

Package info

github.com/willdurand/EventDispatcherBehavior

pkg:composer/willdurand/propel-eventdispatcher-behavior

Statistics

Installs: 31 931

Dependents: 2

Suggesters: 0

Stars: 19

Open Issues: 0

1.3.0 2014-02-25 08:50 UTC

Requires (Dev)

None

Suggests

None

Provides

None

Conflicts

None

Replaces

None

MIT 2b64c84e3cc5510eea5d51dfb1797dbbe9335d73

propeleventevent dispatcherBehavior

This package is auto-updated.

Last update: 2022-01-31 11:58:37 UTC


README

👁 Build Status

Integrate the Symfony2 EventDispatcher component in your Model classes.

Installation

Requires this behavior in your composer.json:

{
 "require": {
 "willdurand/propel-eventdispatcher-behavior": "dev-master"
 }
}

Add the following line to your propel.ini or build.properties configuration file:

propel.behavior.eventdispatcher.class = vendor.willdurand.propel-eventdispatcher-behavior.src.EventDispatcherBehavior

Note: vendor.willdurand.propel-eventdispatcher-behavior.src is the path of the behavior in dot-path notation.

Finally, adds this behavior to your schema.xml:

<database name="foo">
 <table name="a-table">
 <behavior name="event_dispatcher" />
 </table>
</database>

ActiveRecord API

This behavior adds a single method getEventDispatcher(). This method creates an instance of EventDispatcher per class.

Running tests

Install dependencies:

php composer.phar install --dev

Run the test suite:

phpunit

License

This behavior is released under the MIT License. See the bundled LICENSE file for details.