I get a util.List of instances. each instance has its another collection. I want to initialize all instances of collections. Here is how do it.
Hibernate.initialize(parentList);
But when the session is closed. parentList’s objects’properties can be retrieved. But its collection’s instances’s properties cannot be retrieved. The way I initialize is wrong or any other problem is there? or how to initialize all instances.?
will just initialize objects in the list not association inside the list.
From the docs:
Edit: As per comment
Say if I had one
StudentEntity and every student Entity has a list ofCourseEntity. Then the student list can be initialized like this :