Hi Eelco

It seems as the LoadableDetachableModel do not support setobject? What should I 
use instead?

-regards Nino

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Eelco Hillenius
Sent: 14. juli 2006 09:26
To: wicket-user@lists.sourceforge.net
Subject: Re: [Wicket-user] Playing with models:)

IModel#getObject is called anytime a component accesses it. Basically,
you should never depend on that method getting called a fixed number
of times; it is not designed for that. Typically if you need to do
heavy operations such as loading data from a database, you should use
detachable models. A good model for such things is
LoadableDetachableModel. the #load method is only called once a
request, and the loaded object is then reused throughout the request.
At the end of the request, the model is detached and the temporary
object is cleaned up.

Eelco


On 7/14/06, Nino Wael <[EMAIL PROTECTED]> wrote:
>
>
>
> Hah got your Attention there, though sadly enough its only abstractmodels.
>
>
>
> Im not sure when getObject are supposed to be called(what triggers a call).
>
>
>
> The following I can see are that my model are called on page construct(which
> makes sense to me). But on form submit the model are called two times, is
> that behaviour normal, also in what order are models called? My model are
> dependant on some of the other model on the page so I would always need for
> them to be updated first.
>
>
>
>
>
>
>
> Regards Nino
>
> -------------------------------------------------------------------------
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job
> easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
>
>
> _______________________________________________
> Wicket-user mailing list
> Wicket-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wicket-user
>
>
>


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user



-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to