KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > tigris > scarab > om > Condition


1
2 package org.tigris.scarab.om;
3
4
5 import org.apache.torque.om.Persistent;
6
7 /**
8  * You should add additional methods to this class to meet the
9  * application requirements. This class will only be generated as
10  * long as it does not already exist in the output directory.
11  */

12 public class Condition
13     extends org.tigris.scarab.om.BaseCondition
14     implements Persistent
15 {
16     public boolean equals(Condition cond)
17     {
18         boolean bRdo = false;
19         Integer JavaDoc attr1 = this.getAttributeId();
20         Integer JavaDoc attr2 = cond.getAttributeId();
21         if ((attr1 != null && attr2 != null && attr1.intValue() == attr2.intValue()) ||
22                 attr1 == attr2)
23         {
24             attr1 = this.getOptionId();
25             attr2 = cond.getOptionId();
26             if ((attr1 != null && attr2 != null && attr1.intValue() == attr2.intValue()) ||
27                     attr1 == attr2)
28             {
29                 attr1 = this.getModuleId();
30                 attr2 = cond.getModuleId();
31                 if ((attr1 != null && attr2 != null && attr1.intValue() == attr2.intValue()) ||
32                         attr1 == attr2)
33                 {
34                     attr1 = this.getIssueTypeId();
35                     attr2 = cond.getIssueTypeId();
36                     if ((attr1 != null && attr2 != null && attr1.intValue() == attr2.intValue()) ||
37                             attr1 == attr2)
38                     {
39                         bRdo = true;
40                     }
41                 }
42             }
43         }
44         return bRdo;
45     }
46     
47     public boolean equals(Object JavaDoc obj)
48     {
49         return this.equals((Condition)obj);
50     }
51 }
52
Popular Tags