just implement your own IActionListener. That should be pretty straight forward.

What tapestry does when you define listener:method is create an IActionListener implementation on the fly. now, you could just delegate the getFlow().doSomething() method to a method in your page/component class or implement the listener yourself. no need to use the listener: prefix.



Aleksej wrote:
Lets say, I have some listener:
-----
<component id="onItem" type="DirectLink">
   <binding name="listener" value="listener:onItemDetails" />
   <binding name="parameters" value="item.id" />
</component>
-----
also special navigation service is injected in that page:
-----
<inject property="flow" object="service:mvctest.flow" />
-----
which has IRequestCicle object injected.
'flow' object has set of methods returning IPage, so
to go on ItemDetails page in listener I need only to do next think:
-----
public IPage onItemDetails( Long itemId ){
   return getFlow().showItemDetails( itemId );
}
-----
So, the question is:
Can I change somehow 'onItem' component description to point
directly on 'flow' object method?
Something like that ( new onItem ):
-----
<component id="onItem" type="DirectLink">
   <binding name="listener" value="listener:flow.showItemDetails" />
   <binding name="parameters" value="item.id" />
</component>
-----

The problem for me is that DirectLink component listener parameter
required  IActionListener object, and it is almost undocumented :(
I simply don't know where to start.




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to