1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.kuali.rice.kim.bo.entity.impl;
17
18 import java.util.Date;
19 import java.util.LinkedHashMap;
20
21 import javax.persistence.Column;
22 import javax.persistence.Entity;
23 import javax.persistence.FetchType;
24 import javax.persistence.Id;
25 import javax.persistence.JoinColumn;
26 import javax.persistence.ManyToOne;
27 import javax.persistence.Table;
28
29 import org.kuali.rice.kim.bo.entity.KimEntityCitizenship;
30 import org.kuali.rice.kim.bo.reference.CitizenshipStatus;
31 import org.kuali.rice.kim.bo.reference.impl.CitizenshipStatusImpl;
32
33
34
35
36 @Entity
37 @Table(name = "KRIM_ENTITY_CTZNSHP_T")
38 public class KimEntityCitizenshipImpl extends KimInactivatableEntityDataBase implements KimEntityCitizenship {
39
40 private static final long serialVersionUID = 1L;
41
42 @Id
43 @Column(name = "ENTITY_CTZNSHP_ID")
44 protected String entityCitizenshipId;
45
46 @Column(name = "ENTITY_ID")
47 protected String entityId;
48
49 @Column(name = "POSTAL_CNTRY_CD")
50 protected String countryCode;
51
52 @Column(name = "CTZNSHP_STAT_CD")
53 protected String citizenshipStatusCode;
54
55 @Column(name = "strt_dt")
56 protected Date startDate;
57
58 @Column(name = "end_dt")
59 protected Date endDate;
60
61 @ManyToOne(targetEntity=CitizenshipStatusImpl.class, fetch = FetchType.EAGER, cascade = {})
62 @JoinColumn(name = "CTZNSHP_STAT_CD", insertable = false, updatable = false)
63 protected CitizenshipStatus citizenshipType;
64
65
66
67
68
69
70
71 public String getCitizenshipStatusCode() {
72 return citizenshipStatusCode;
73 }
74
75
76
77
78 public Date getEndDate() {
79 return endDate;
80 }
81
82
83
84
85 public String getEntityCitizenshipId() {
86 return entityCitizenshipId;
87 }
88
89
90
91
92 public Date getStartDate() {
93 return startDate;
94 }
95
96
97
98
99 public void setCitizenshipStatusCode(String citizenshipStatusCode) {
100 this.citizenshipStatusCode = citizenshipStatusCode;
101 }
102
103
104
105
106 public void setEndDate(Date endDate) {
107 this.endDate = endDate;
108 }
109
110
111
112
113 public void setStartDate(Date startDate) {
114 this.startDate = startDate;
115 }
116
117
118
119
120 @Override
121 protected LinkedHashMap toStringMapper() {
122 LinkedHashMap m = new LinkedHashMap();
123 m.put( "entityCitizenshipId", entityCitizenshipId );
124 m.put( "countryCode", countryCode );
125 m.put( "citizenshipStatusCode", citizenshipStatusCode );
126 m.put( "startDate", startDate );
127 m.put( "endDate", endDate );
128 return m;
129 }
130
131 public String getEntityId() {
132 return this.entityId;
133 }
134
135 public void setEntityId(String entityId) {
136 this.entityId = entityId;
137 }
138
139 public String getCountryCode() {
140 return this.countryCode;
141 }
142
143 public void setCountryCode(String countryCode) {
144 this.countryCode = countryCode;
145 }
146
147 public CitizenshipStatus getCitizenshipType() {
148 return this.citizenshipType;
149 }
150
151 public void setCitizenshipType(CitizenshipStatus citizenshipType) {
152 this.citizenshipType = citizenshipType;
153 }
154
155 public void setEntityCitizenshipId(String entityCitizenshipId) {
156 this.entityCitizenshipId = entityCitizenshipId;
157 }
158
159 }