Do you have your own RequestCycle? If so, is it a subclass of WebRequestCycle?
Martijn On 9/24/07, Andrew Lombardi <[EMAIL PROTECTED]> wrote: > The following gives me a ClassCastException: > > ((WebRequestCycle) > RequestCycle.get()).getWebResponse().getHttpServletResponse() > > On Mon, 24 Sep 2007 13:12:39 -0700, Eelco Hillenius wrote: > > Just cast it. If you're building a regular web app, you'll always use > > WebRequestCycle, which returns WebResponse for getResponse. E.g. > > ((WebRequestCycle)RequestCycle.get()).getWebRequest(). I know it looks > > ugly, but then again, the idea is that you typically shouldn't the > > httpservletresponse directly in the first place. > > > > Eelco > > > > On 9/24/07, Andrew Lombardi <[EMAIL PROTECTED]> wrote: > >> yes, I know. but how do I get a WebResponse? > >> RequestCycle.get().getResponse() doesn't give me a class that extends > >> from WebResponse. > >> > >> On Mon, 24 Sep 2007 12:52:52 -0700, Sean Sullivan wrote: > >>> If you are using Wicket 1.3: > >>> > >>> class: WebResponse > >>> > >>> > >> > http://www.wicketstuff.org/wicket13doc/org/apache/wicket/protocol/http/WebResponse.html > >>> > >>> > >>> method: getHttpServletResponse > >>> > >>> > >>> > >>> On 9/24/07, Andrew Lombardi <[EMAIL PROTECTED]> wrote: > >>>> How would I get an instance of the HttpServletResponse? I'm doing some > >>>> integration with an SSO provider that requires it. I've tried: > >>>> > >>>> ((WebResponse) > >>>> RequestCycle.get().getResponse()).getHttpServletResponse() > >>>> > >>>> but RequestCycle.get().getResponse() returns StringResponse, which > >>>> obviously will fail miserably for what I need it for. > >>>> > >>>> thanks. > >>>> > >>>> -- > >>>> To our success! > >>>> > >>>> Andrew Lombardi: Mystic Coders, LLC - Coding Magic > >>>> contact | [EMAIL PROTECTED] | mobile: 714-697-8046 > >>>> office/fax: 714-948-2382 | aim: nlpjunke > >>>> > >>>> ======================================================================= > >>>> This message is for the named person's use only. You must not, directly > >>>> or indirectly, use, disclose, distribute, print, or copy any part of > >>>> this message if you are not the intended recipient. > >>>> ======================================================================= > >>>> > >>>> --------------------------------------------------------------------- > >>>> 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] > >>> > >> > >> -- > >> To our success! > >> > >> Andrew Lombardi: Mystic Coders, LLC - Coding Magic > >> contact | [EMAIL PROTECTED] | mobile: 714-697-8046 > >> office/fax: 714-948-2382 | aim: nlpjunke > >> > >> ======================================================================= > >> This message is for the named person's use only. You must not, directly > >> or indirectly, use, disclose, distribute, print, or copy any part of > >> this message if you are not the intended recipient. > >> ======================================================================= > >> > >> --------------------------------------------------------------------- > >> 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] > > > > -- > To our success! > > Andrew Lombardi: Mystic Coders, LLC - Coding Magic > contact | [EMAIL PROTECTED] | mobile: 714-697-8046 > office/fax: 714-948-2382 | aim: nlpjunke > > ======================================================================= > This message is for the named person's use only. You must not, directly > or indirectly, use, disclose, distribute, print, or copy any part of > this message if you are not the intended recipient. > ======================================================================= > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Buy Wicket in Action: http://manning.com/dashorst Apache Wicket 1.3.0-beta3 is released Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.0-beta3/ --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]