1 | |
|
2 | |
|
3 | |
|
4 | |
|
5 | |
|
6 | |
|
7 | |
|
8 | |
|
9 | |
|
10 | |
|
11 | |
|
12 | |
|
13 | |
|
14 | |
|
15 | |
|
16 | |
package edu.sampleu.financial.bo; |
17 | |
|
18 | |
import org.apache.commons.lang.builder.EqualsBuilder; |
19 | |
import org.kuali.rice.core.api.mo.common.active.MutableInactivatable; |
20 | |
import org.kuali.rice.krad.bo.PersistableBusinessObjectBase; |
21 | |
import org.kuali.rice.krad.util.ObjectUtils; |
22 | |
|
23 | |
|
24 | |
|
25 | |
|
26 | |
|
27 | |
|
28 | |
|
29 | |
public class VendorDefaultAddress extends PersistableBusinessObjectBase implements MutableInactivatable { |
30 | |
|
31 | |
private Integer vendorDefaultAddressGeneratedIdentifier; |
32 | |
private Integer vendorAddressGeneratedIdentifier; |
33 | |
private String vendorCampusCode; |
34 | |
private boolean active; |
35 | |
|
36 | |
private VendorAddress vendorAddress; |
37 | |
|
38 | |
|
39 | |
|
40 | |
|
41 | |
public VendorDefaultAddress() { |
42 | 0 | super(); |
43 | 0 | } |
44 | |
|
45 | |
public String getVendorCampusCode() { |
46 | |
|
47 | 0 | return vendorCampusCode; |
48 | |
} |
49 | |
|
50 | |
public void setVendorCampusCode(String vendorCampusCode) { |
51 | 0 | this.vendorCampusCode = vendorCampusCode; |
52 | 0 | } |
53 | |
|
54 | |
public Integer getVendorAddressGeneratedIdentifier() { |
55 | |
|
56 | 0 | return vendorAddressGeneratedIdentifier; |
57 | |
} |
58 | |
|
59 | |
public void setVendorAddressGeneratedIdentifier(Integer vendorAddressGeneratedIdentifier) { |
60 | 0 | this.vendorAddressGeneratedIdentifier = vendorAddressGeneratedIdentifier; |
61 | 0 | } |
62 | |
|
63 | |
public boolean isActive() { |
64 | |
|
65 | 0 | return active; |
66 | |
} |
67 | |
|
68 | |
public void setActive(boolean active) { |
69 | 0 | this.active = active; |
70 | 0 | } |
71 | |
|
72 | |
public VendorAddress getVendorAddress() { |
73 | |
|
74 | 0 | return vendorAddress; |
75 | |
} |
76 | |
|
77 | |
|
78 | |
|
79 | |
|
80 | |
|
81 | |
|
82 | |
|
83 | |
public void setVendorAddress(VendorAddress vendorAddress) { |
84 | 0 | this.vendorAddress = vendorAddress; |
85 | 0 | } |
86 | |
|
87 | |
public Integer getVendorDefaultAddressGeneratedIdentifier() { |
88 | |
|
89 | 0 | return vendorDefaultAddressGeneratedIdentifier; |
90 | |
} |
91 | |
|
92 | |
public void setVendorDefaultAddressGeneratedIdentifier(Integer vendorDefaultAddressGeneratedIdentifier) { |
93 | 0 | this.vendorDefaultAddressGeneratedIdentifier = vendorDefaultAddressGeneratedIdentifier; |
94 | 0 | } |
95 | |
|
96 | |
public boolean isEqualForRouting(Object toCompare) { |
97 | 0 | if ((ObjectUtils.isNull(toCompare)) || !(toCompare instanceof VendorDefaultAddress)) { |
98 | |
|
99 | 0 | return false; |
100 | |
} else { |
101 | 0 | VendorDefaultAddress vda = (VendorDefaultAddress) toCompare; |
102 | |
|
103 | 0 | return new EqualsBuilder().append(this.getVendorDefaultAddressGeneratedIdentifier(), vda.getVendorDefaultAddressGeneratedIdentifier()).append(this.getVendorAddressGeneratedIdentifier(), vda.getVendorAddressGeneratedIdentifier()).append(this.getVendorCampusCode(), vda.getVendorCampusCode()).isEquals(); |
104 | |
} |
105 | |
} |
106 | |
|
107 | |
|
108 | |
} |