Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » private-owned versus orphan-removal versus cascade-remove
private-owned versus orphan-removal versus cascade-remove [message #1069868] Tue, 16 July 2013 19:18
Roger Spall is currently offline Roger Spall
Messages: 17
Registered: January 2013
Junior Member
I am pretty sure I understand the differences between cascade-remove and orphan-remove...

orphan-remove implies cascade-remove, i.e. if you specify orphan-remove, then cascade-remove is implied whether you specify it or not. However, specifying cascade-remove does not imply orphan-remove, and applies to the entire relationship it is specified for. Meanwhile, orphan-remove refers to the individual items in a 1-1 or 1-many relationship. Of course if you delete the parent then all of the orphaned children are removed (the implies bit).

Ok, so how does private-owned fit into the picture? I know this is custom Eclipselink syntax, but how does it compare to cascade-remove and orphan-remove, and when should this be used versus the other declarations?

From what I can see, it has the same effect as orphan-removal="true", but this doesn't make sense as why would special syntax be added for something that is already in the specification - unless it was for an earlier version when orphan-remove wasn't available, and is therefore now deprecated.
Previous Topic:Abstract Entity without children
Next Topic:Understanding 1-many deletion cascading
Goto Forum:
  


Current Time: Wed Oct 22 15:34:12 GMT 2014

Powered by FUDForum. Page generated in 0.01474 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software