-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Unlazying an object
PostPosted: Thu Dec 02, 2004 10:21 am 
Newbie

Joined: Thu Oct 07, 2004 9:20 am
Posts: 11
I have an object, and I need to make sure that the object is fully loaded. By that I mean that there are no parts of the object that have been lazily not loaded yet.

Currently, I achieve this by walking all the components of the object. This works.

Does Hibernate have a mechanism for doing this automatically to an object? I don't want this to happen to all instances of a persistent class, just to a particular instance.

Thanks


Top
 Profile  
 
 Post subject:
PostPosted: Thu Dec 02, 2004 10:50 am 
Expert
Expert

Joined: Tue Oct 05, 2004 9:45 am
Posts: 263
i think
Code:
Hibernate.initialize()
does that ...

gtx
curio


Top
 Profile  
 
 Post subject: Deep Initialization
PostPosted: Thu Dec 02, 2004 11:00 am 
Newbie

Joined: Thu Oct 07, 2004 9:20 am
Posts: 11
Reading about Hibernate.initialize() in the doc and api doc, it appears that initialize loads one level of proxy objects. I am looking for something that initializes the full depth of an object.

By that I mean that if an A contains a collection of B's and each B contains a collection of C's, then I would like to initialize the A such that all the B's and C's are also initialized.

Maybe initialize does do this.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Dec 02, 2004 11:02 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 12:50 pm
Posts: 5130
Location: Melbourne, Australia
You can write such a thing yourself, making use of ClassMetadata


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.