Ok it seems that my equals() method in DepartmentSection is failing which I am 
sure is the problem

    public boolean equals(Object object) {
  | 
  |             if (object == this) return true;
  |             if (!(object instanceof DepartmentSection)) return false;
  |             DepartmentSection other = (DepartmentSection)object;
  |             if (!(other.getDepartmentSectionId() == 
this.getDepartmentSectionId())) return false;
  |             return true;
  |             
  |     }

Its failing on the instanceof check.  I can't figure that one out.  I would 
assume that it would have something to do with the DepartmentSectionList 
declaration on the Department class but it all seems correct.

Here is the declaration


  | //Department Entity
  | 
  | @OneToMany(cascade = CascadeType.ALL, mappedBy = "department")
  |     private List<DepartmentSection> departmentSectionList = new 
ArrayList<DepartmentSection>();
  | 
  | 
  |     public List<DepartmentSection> getDepartmentSectionList() {
  |         return this.departmentSectionList;
  |     }
  | 
  |     public void setDepartmentSectionList(List<DepartmentSection> 
departmentSectionList) {
  |         this.departmentSectionList = departmentSectionList;
  |     }
  | 
  | 

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

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4079358
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to