org.apache.cayenne.map
Interface EntityListenerFactory
- public interface EntityListenerFactory 
A factory used to create entity listeners. By default listeners are created using a
 noop constructor on the listener class, however if a user needs to customize listener
 creation process (e.g. perform dependency injection, etc.), a custom factory can be
 installed on the EntityResolver. EntityListenerFactory also supports defining listener
 interfaces, not just classes).
- Since:
- 3.0
 
createListener
Object createListener(EntityListener listenerMapping,
                      ObjEntity entity)
- Creates an instance of entity listener of a given class. "entity" parameter denotes
 ObjEntity for which the listener is installed. It is null if this is a default
 listener.
 
- 
- Returns:
- a listener of the given class. May return null to indicate that a
         configured listener should be suppressed.
 
Copyright © 2001-2011 Apache Cayenne. All Rights Reserved.