hi all,

i can't seem to find the way to get an url for a given RequestTarget.
i'm using wicket 1.4-rc1.

basically i have an SWFComponent : http://paste.pocoo.org/show/110435/

my problem is in line 35, when i call urlFor(target) to the renderHead
method. the target is of type ResourceStreamRequestTarget and when i
dig into the sources for the urlFor call, i end up in
WebRequestCodingStrategy#encode:

// fall through for non-default request targets
                                url = doEncode(requestCycle, requestTarget);

doEncode javadoc reads:

         * In case you are using custom targets that are not part of the
default target hierarchy, you
         * need to override this method, which will be called after the
defaults have been tried. When
         * this doesn't provide a url either (returns null), an exception
will be thrown by the encode
         * method saying that encoding could not be done.

where am i supposed to override this method?

additionally, wicket doesn't seem to throw an exception as stated - it
silently returns the null value.

any ideas on how to get the url, or improvements to the code i pasted
to make it work?

thank you,

francisco

ps: note that the ResourceStreamRequestTarget works fine. for instance
if i call getRequestCycle().setRequestTarget(target); on renderHead,
the http response streams the swf file.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to