- First, i get the collection from 'attached' parent. For e.g Set
children = parent.getChildren() - Add the new Child object. Of course please save the Child object first. children.add(newChild).
- Remove the 'selected' existing Child object. children.remove(removedChild)
- Finally, save the Parent object.
It is kind of fundamental. However sometimes we may get confused due to whatever reasons.
No comments:
Post a Comment