Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Can I get set<MyEntity> instead of Indirect Set in one to many relationship(Issue with retrieving children in one to many relation. Getting Indirect Set instead of set<myEntity>)
Can I get set<MyEntity> instead of Indirect Set in one to many relationship [message #997588] Tue, 08 January 2013 08:47 Go to next message
vamsi raghava is currently offline vamsi raghava
Messages: 2
Registered: December 2012
Junior Member
Hi,

I have self reference one-to-many relationship(children) in a Entity Domain. The getter method (getChildren()) returns Set<Domain>.

The children are loaded lazily.
When I call getChildren() what I am getting is actually IndirectSet.
The actual children can be accessed using "delegate".

I have a scenarion where I need to be able to access the children recursively using getChildren() not getDeligate()

Is that possible?

We are using eclipselink version 2.4.0
Re: Can I get set<MyEntity> instead of Indirect Set in one to many relationship [message #997692 is a reply to message #997588] Tue, 08 January 2013 10:03 Go to previous message
James Sutherland is currently offline James Sutherland
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

IndirectSet is a Set, so I don't see your issue? What kind of Set do you want, the point of the Set interface is that the implementation does not matter.

If you make the relationship EAGER it will use HashSet by default instead.


James : Wiki : Book : Blog : Twitter
Previous Topic:Odd Exception when retrieving a datarow
Next Topic:Can I use ClipseLink to work with Object-Relational datatypes(TYPSES, VARRAY, NESTED TABLES..)
Goto Forum:
  


Current Time: Thu Jul 24 16:01:20 EDT 2014

Powered by FUDForum. Page generated in 0.12241 seconds