You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Jesse Kuhnert <jk...@gmail.com> on 2007/03/06 05:01:53 UTC

Re: method name of listener

Isn't the name of a listener known by the very definition? I mean,
when ~don't~ you know the name of it?

On 2/19/07, Kristian Marinkovic <kr...@porsche.co.at> wrote:
>
> hi all,
>
> is there a way to obtain the method name of a listener?
>
> I need it to generate a javascript function with the same
> name. calling this js function will trigger an asynchronous XHR
> call (Tapestry.bind) that triggers the corresponding listener.
> The js method also accepts parameters that get send to the page.
>
> in case anyone else needs this very, very simple component
> i'll post it somewhere.
>
> g,
> kris
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>


-- 
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Antwort: Re: method name of listener

Posted by Kristian Marinkovic <kr...@porsche.co.at>.
definining a listener for my component looks sth like this (Tap standard):

<component id="asyncOrder" type="cross:AsyncListenerCaller">
   <binding name="listener" value="listener:contactOrder" />
   ...
</component>

in my component i have a method returning a IActionListener:
public abstract IActionListener getListener();

now i want to generate a js function with the same name and i dont know how
to get it from IActionListener (at least i found no public methods:)). My
workaround is to add another component parameter that contains the
name of the listener as a literal.

... i hope this does not sound that stupid :)




                                                                           
             "Jesse Kuhnert"                                               
             <jkuhnert@gmail.c                                             
             om>                                                        An 
                                        "Tapestry users"                   
             06.03.2007 05:01           <us...@tapestry.apache.org>        
                                                                     Kopie 
                                                                           
              Bitte antworten                                        Thema 
                    an                  Re: method name of listener        
             "Tapestry users"                                              
             <users@tapestry.a                                             
                pache.org>                                                 
                                                                           
                                                                           
                                                                           




Isn't the name of a listener known by the very definition? I mean,
when ~don't~ you know the name of it?

On 2/19/07, Kristian Marinkovic <kr...@porsche.co.at> wrote:
>
> hi all,
>
> is there a way to obtain the method name of a listener?
>
> I need it to generate a javascript function with the same
> name. calling this js function will trigger an asynchronous XHR
> call (Tapestry.bind) that triggers the corresponding listener.
> The js method also accepts parameters that get send to the page.
>
> in case anyone else needs this very, very simple component
> i'll post it somewhere.
>
> g,
> kris
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>


--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org