[jboss-user] [EJB 3.0] - Re: CascadeType is misbehaving!

fhh do-not-reply at jboss.com
Fri Mar 30 09:38:06 EDT 2007


Your ERM is completly broken:

  | public String getParent() {
  |         return parent;
  |     }
  | 
  |     public void setParent(String parent) {
  |         this.parent = parent;
  |     }
  | 

If you want a bidirectional relationship you want to return the referenced object not its id:


  | public A get Parent() {
  |    return a;
  | }
  | 
  | public setParent(A a) {
  |   this.a = a
  | }
  | 


Regards

Felix


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4033166#4033166

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4033166



More information about the jboss-user mailing list