I dont have custom classloader but I do have custom resource loader, not sure
if that is relevant.
Ok here is the custom WebSession class and relevant method
public class NeobitsWebSession
extends WebSession
{
...
/**
* Constructor
*
* @param webapp
* @param request
*/
public NeobitsWebSession(Application webapp, Request request)
{
super(request);
setApplication(webapp);
}
/**
* Covariant for Session.get()
* @return
*/
public static NeobitsWebSession get()
{
return (NeobitsWebSession)Session.get();
}
....
Here is the Custom WebApplication
public class NeobitsWebApp
extends WebApplication
{
.....
@Override
public Session newSession(Request request, Response response)
{
return new NeobitsWebSession(this, request);
}
...
}
Timo Rantalaiho wrote:
>
> On Thu, 24 Jul 2008, Ritz123 wrote:
>> I have a custom Session object which is registered in the custom
>> WebApplication class as newSession method override.
>
> Is your custom session class extending Session or WebSession?
>
>> The session object overrides static Session.get() method returning custom
>
> But static methods cannot be overriden in Java, can they?
>
>> java.lang.ClassCastException: com.neobits.web.NeobitsWebSession
>> at com.neobits.web.NeobitsWebSession.get(NeobitsWebSession.java:51)
>> at
>> com.neobits.web.pages.ViewCartPage$CartDetailsFragment$CheckoutButton.onSubmit(ViewCartPage.java:330)
>
> Could you show those lines of code?
>
> Best wishes,
> Timo
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
--
View this message in context:
http://www.nabble.com/Session.get-covariant-override-and-back-button-issue--tp18644053p18655699.html
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]