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 super();
43 }
44
45 public String getVendorCampusCode() {
46
47 return vendorCampusCode;
48 }
49
50 public void setVendorCampusCode(String vendorCampusCode) {
51 this.vendorCampusCode = vendorCampusCode;
52 }
53
54 public Integer getVendorAddressGeneratedIdentifier() {
55
56 return vendorAddressGeneratedIdentifier;
57 }
58
59 public void setVendorAddressGeneratedIdentifier(Integer vendorAddressGeneratedIdentifier) {
60 this.vendorAddressGeneratedIdentifier = vendorAddressGeneratedIdentifier;
61 }
62
63 public boolean isActive() {
64
65 return active;
66 }
67
68 public void setActive(boolean active) {
69 this.active = active;
70 }
71
72 public VendorAddress getVendorAddress() {
73
74 return vendorAddress;
75 }
76
77
78
79
80
81
82
83 public void setVendorAddress(VendorAddress vendorAddress) {
84 this.vendorAddress = vendorAddress;
85 }
86
87 public Integer getVendorDefaultAddressGeneratedIdentifier() {
88
89 return vendorDefaultAddressGeneratedIdentifier;
90 }
91
92 public void setVendorDefaultAddressGeneratedIdentifier(Integer vendorDefaultAddressGeneratedIdentifier) {
93 this.vendorDefaultAddressGeneratedIdentifier = vendorDefaultAddressGeneratedIdentifier;
94 }
95
96 public boolean isEqualForRouting(Object toCompare) {
97 if ((ObjectUtils.isNull(toCompare)) || !(toCompare instanceof VendorDefaultAddress)) {
98
99 return false;
100 } else {
101 VendorDefaultAddress vda = (VendorDefaultAddress) toCompare;
102
103 return new EqualsBuilder().append(this.getVendorDefaultAddressGeneratedIdentifier(), vda.getVendorDefaultAddressGeneratedIdentifier()).append(this.getVendorAddressGeneratedIdentifier(), vda.getVendorAddressGeneratedIdentifier()).append(this.getVendorCampusCode(), vda.getVendorCampusCode()).isEquals();
104 }
105 }
106
107
108 }