heh. make sure all your listviews override getlistitemmodel()
otherwise you can run into all kinds of problems if you use listview
to select items not just display them...
-igor
On Thu, Mar 13, 2008 at 8:38 AM, Maurice Marrink <[EMAIL PROTECTED]> wrote:
> I believe refreshingview has better support for reusing items but in
> our apps we hardly ever use refreshingview. both are suitable for use
> with hibernate.
>
> Maurice
>
>
>
> On Thu, Mar 13, 2008 at 4:35 PM, carloc <[EMAIL PROTECTED]> wrote:
> >
> > What should I use when I am accessing hibernate?
> > Should I use a ListView or should I use a refreshing view?\
> > In the api it says to use refreshingview instead of using listview when
> > using database collections
> > what is better to use?
> >
> >
> >
> > carloc wrote:
> > >
> > > Hi everyone,
> > >
> > > I have been reading wicket in action recently and I have seen pitfalls
> of
> > > hibernate section.
> > > I was wondering about the stuff about hibernate and memory leaks due to
> > > hibernate proxy objects maintaining a reference to the session with
> > > them....
> > >
> > >
> > > Am I doing this wrong then?
> > > @SpringBean
> > > private UserService userService;
> > >
> > > add(new ListView("user", userService.findUsers() {
> > > })
> > >
> > > is this wrong? I'm using it directly meaning it will be stored in the
> page
> > > store right?
> > >
> > > should i be doing this instead?
> > >
> > > LoadableDetachableModel model = new LoadableDetachablemodel() {
> > > Object load() {
> > > return usrService.findUsers()
> > > }
> > >
> > > }
> > > }
> > >
> > > add(new ListView("listView", model)) {
> > > }
> > >
> > > this is to avoid storing the users in the session...
> > > will doing the first one actually result in a memory leak?
> > >
> > > thanks
> > >
> >
> > --
> > View this message in context:
> http://www.nabble.com/Wicket%2C-Hibernate-and-Models-tp16025532p16028751.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]
> >
> >
>
> ---------------------------------------------------------------------
> 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]