[jboss-user] [JBoss Seam] - Re: Two browser tabs : basic question
dkane
do-not-reply at jboss.com
Mon Dec 17 07:36:41 EST 2007
"damianharvey" wrote : How do you do your delete? Something like this?myList.remove(selectedObject);
| | entityManager.remove(selectedObject)
|
Not quite. First operator myList.remove(selectedObject) is the same.
What comes to second : my list of records is actually a collection of entity beans referred by @OneToMany annotation in another entity bean (with CascadeType.PERSIST).
So in order to remove entity from database, I remove it from collection and Hibernate takes care of underlying deletion.
I don't consider that as a key difference though.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4113366#4113366
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4113366
More information about the jboss-user
mailing list