|
|||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |
See:
Description
Class Summary | |
ListenerMap | Maps a class to a set of listeners based on the public methods of the class. |
ListenerMapHelper | PropertyHelper class for ListenerMap . |
ListenerMapHelper.ListenerMapAccessor |
Support classes that allows an object to expose listener methods instead of listener properties.
Normally, a listener property must be an object that implements either
IActionListener
or
IDirectListener
. This can be cumbersome, in practice, as it
typically involves creating an anonymous inner class.
Using this mechanism, classes can instead implement listener methods. A listener method takes one of two forms:
public void method-name(IRequestCycle
cycle)
throws RequestCycleException
public void method-name(String[] context,
IRequestCycle
cycle)
throws RequestCycleException
The first option can act like either an IActionListener
or
a IDirectListener
, the second must be a
IDirectListener
. In both cases, the throws
clause is optional.
Tapestry will create an appropriate listener object that will invoke the corresponding method.
The methods can be accessed using the property path "listeners.method-name
"
ListenerMap
,
AbstractComponent.getListeners()
,
AbstractEngine.getListeners()
|
|||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |