Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
KimEntityNameInfo |
|
| 1.03125;1.031 |
1 | /* | |
2 | * Copyright 2007-2009 The Kuali Foundation | |
3 | * | |
4 | * Licensed under the Educational Community License, Version 2.0 (the "License"); | |
5 | * you may not use this file except in compliance with the License. | |
6 | * You may obtain a copy of the License at | |
7 | * | |
8 | * http://www.opensource.org/licenses/ecl2.php | |
9 | * | |
10 | * Unless required by applicable law or agreed to in writing, software | |
11 | * distributed under the License is distributed on an "AS IS" BASIS, | |
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
13 | * See the License for the specific language governing permissions and | |
14 | * limitations under the License. | |
15 | */ | |
16 | package org.kuali.rice.kim.bo.entity.dto; | |
17 | ||
18 | import java.io.Serializable; | |
19 | ||
20 | import org.kuali.rice.kim.bo.entity.KimEntityName; | |
21 | ||
22 | /** | |
23 | * @author Kuali Rice Team (rice.collab@kuali.org) | |
24 | */ | |
25 | public class KimEntityNameInfo extends KimDefaultableInfo implements KimEntityName, Serializable { | |
26 | ||
27 | private static final long serialVersionUID = 1L; | |
28 | ||
29 | protected String entityNameId; | |
30 | protected String nameTypeCode; | |
31 | protected String firstName; | |
32 | protected String firstNameUnmasked; | |
33 | protected String middleName; | |
34 | protected String middleNameUnmasked; | |
35 | protected String lastName; | |
36 | protected String lastNameUnmasked; | |
37 | protected String title; | |
38 | protected String titleUnmasked; | |
39 | protected String suffix; | |
40 | protected String suffixUnmasked; | |
41 | ||
42 | 0 | protected boolean suppressName = false; |
43 | ||
44 | protected String formattedName; | |
45 | protected String formattedNameUnmasked; | |
46 | ||
47 | /** | |
48 | * construct an empty {@link KimEntityNameInfo} | |
49 | */ | |
50 | public KimEntityNameInfo() { | |
51 | 0 | super(); |
52 | 0 | active = true; |
53 | 0 | } |
54 | ||
55 | /** | |
56 | * construct a {@link KimEntityNameInfo} derived from the given {@link KimEntityName} | |
57 | */ | |
58 | public KimEntityNameInfo( KimEntityName name ) { | |
59 | 0 | this(); |
60 | 0 | if ( name != null ) { |
61 | 0 | this.entityNameId = name.getEntityNameId(); |
62 | 0 | this.nameTypeCode = name.getNameTypeCode(); |
63 | 0 | this.firstName = name.getFirstName(); |
64 | 0 | this.firstNameUnmasked = name.getFirstNameUnmasked(); |
65 | 0 | this.middleName = name.getMiddleName(); |
66 | 0 | this.middleNameUnmasked = name.getMiddleNameUnmasked(); |
67 | 0 | this.lastName = name.getLastName(); |
68 | 0 | this.lastNameUnmasked = name.getLastNameUnmasked(); |
69 | 0 | this.title = name.getTitle(); |
70 | 0 | this.titleUnmasked = name.getTitleUnmasked(); |
71 | 0 | this.suffix = name.getSuffix(); |
72 | 0 | this.suffixUnmasked = name.getSuffixUnmasked(); |
73 | 0 | this.active = name.isActive(); |
74 | 0 | this.dflt = name.isDefault(); |
75 | 0 | this.suppressName = name.isSuppressName(); |
76 | ||
77 | 0 | this.formattedName = name.getFormattedName(); |
78 | 0 | this.formattedNameUnmasked = name.getFormattedNameUnmasked(); |
79 | } | |
80 | 0 | } |
81 | ||
82 | /** | |
83 | * {@inheritDoc} | |
84 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getEntityNameId() | |
85 | */ | |
86 | public String getEntityNameId() { | |
87 | 0 | return entityNameId; |
88 | } | |
89 | ||
90 | /** | |
91 | * @param entityNameId the entityNameId to set | |
92 | */ | |
93 | public void setEntityNameId(String entityNameId) { | |
94 | 0 | this.entityNameId = entityNameId; |
95 | 0 | } |
96 | ||
97 | /** | |
98 | * {@inheritDoc} | |
99 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getNameTypeCode() | |
100 | */ | |
101 | public String getNameTypeCode() { | |
102 | 0 | return nameTypeCode; |
103 | } | |
104 | ||
105 | /** | |
106 | * @param nameTypeCode the nameTypeCode to set | |
107 | */ | |
108 | public void setNameTypeCode(String nameTypeCode) { | |
109 | 0 | this.nameTypeCode = nameTypeCode; |
110 | 0 | } |
111 | ||
112 | /** | |
113 | * {@inheritDoc} | |
114 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getFirstName() | |
115 | */ | |
116 | public String getFirstName() { | |
117 | 0 | return firstName; |
118 | } | |
119 | ||
120 | /** | |
121 | * @param firstName the firstName to set | |
122 | */ | |
123 | public void setFirstName(String firstName) { | |
124 | 0 | this.firstName = firstName; |
125 | 0 | } |
126 | ||
127 | /** | |
128 | * {@inheritDoc} | |
129 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getFirstNameUnmasked() | |
130 | */ | |
131 | public String getFirstNameUnmasked() { | |
132 | 0 | return firstNameUnmasked; |
133 | } | |
134 | ||
135 | /** | |
136 | * @param firstNameUnmasked the firstNameUnmasked to set | |
137 | */ | |
138 | public void setFirstNameUnmasked(String firstNameUnmasked) { | |
139 | 0 | this.firstNameUnmasked = firstNameUnmasked; |
140 | 0 | } |
141 | ||
142 | /** | |
143 | * {@inheritDoc} | |
144 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getMiddleName() | |
145 | */ | |
146 | public String getMiddleName() { | |
147 | 0 | return middleName; |
148 | } | |
149 | ||
150 | /** | |
151 | * @param middleName the middleName to set | |
152 | */ | |
153 | public void setMiddleName(String middleName) { | |
154 | 0 | this.middleName = middleName; |
155 | 0 | } |
156 | ||
157 | /** | |
158 | * {@inheritDoc} | |
159 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getMiddleNameUnmasked() | |
160 | */ | |
161 | public String getMiddleNameUnmasked() { | |
162 | 0 | return middleNameUnmasked; |
163 | } | |
164 | ||
165 | /** | |
166 | * @param middleNameUnmasked the middleNameUnmasked to set | |
167 | */ | |
168 | public void setMiddleNameUnmasked(String middleNameUnmasked) { | |
169 | 0 | this.middleNameUnmasked = middleNameUnmasked; |
170 | 0 | } |
171 | ||
172 | /** | |
173 | * {@inheritDoc} | |
174 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getLastName() | |
175 | */ | |
176 | public String getLastName() { | |
177 | 0 | return lastName; |
178 | } | |
179 | ||
180 | /** | |
181 | * @param lastName the lastName to set | |
182 | */ | |
183 | public void setLastName(String lastName) { | |
184 | 0 | this.lastName = lastName; |
185 | 0 | } |
186 | ||
187 | /** | |
188 | * {@inheritDoc} | |
189 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getLastNameUnmasked() | |
190 | */ | |
191 | public String getLastNameUnmasked() { | |
192 | 0 | return lastNameUnmasked; |
193 | } | |
194 | ||
195 | /** | |
196 | * @param lastNameUnmasked the lastNameUnmasked to set | |
197 | */ | |
198 | public void setLastNameUnmasked(String lastNameUnmasked) { | |
199 | 0 | this.lastNameUnmasked = lastNameUnmasked; |
200 | 0 | } |
201 | ||
202 | /** | |
203 | * {@inheritDoc} | |
204 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getTitle() | |
205 | */ | |
206 | public String getTitle() { | |
207 | 0 | return title; |
208 | } | |
209 | ||
210 | /** | |
211 | * @param title the title to set | |
212 | */ | |
213 | public void setTitle(String title) { | |
214 | 0 | this.title = title; |
215 | 0 | } |
216 | ||
217 | /** | |
218 | * {@inheritDoc} | |
219 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getTitleUnmasked() | |
220 | */ | |
221 | public String getTitleUnmasked() { | |
222 | 0 | return titleUnmasked; |
223 | } | |
224 | ||
225 | /** | |
226 | * @param titleUnmasked the titleUnmasked to set | |
227 | */ | |
228 | public void setTitleUnmasked(String titleUnmasked) { | |
229 | 0 | this.titleUnmasked = titleUnmasked; |
230 | 0 | } |
231 | ||
232 | /** | |
233 | * {@inheritDoc} | |
234 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getSuffix() | |
235 | */ | |
236 | public String getSuffix() { | |
237 | 0 | return suffix; |
238 | } | |
239 | ||
240 | /** | |
241 | * @param suffix the suffix to set | |
242 | */ | |
243 | public void setSuffix(String suffix) { | |
244 | 0 | this.suffix = suffix; |
245 | 0 | } |
246 | ||
247 | /** | |
248 | * {@inheritDoc} | |
249 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getSuffixUnmasked() | |
250 | */ | |
251 | public String getSuffixUnmasked() { | |
252 | 0 | return suffixUnmasked; |
253 | } | |
254 | ||
255 | /** | |
256 | * @param suffixUnmasked the suffixUnmasked to set | |
257 | */ | |
258 | public void setSuffixUnmasked(String suffixUnmasked) { | |
259 | 0 | this.suffixUnmasked = suffixUnmasked; |
260 | 0 | } |
261 | ||
262 | /** | |
263 | * {@inheritDoc} | |
264 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#isSuppressName() | |
265 | */ | |
266 | public boolean isSuppressName() { | |
267 | 0 | return this.suppressName; |
268 | } | |
269 | ||
270 | /** | |
271 | * @param suppressName the suppressName to set | |
272 | */ | |
273 | public void setSuppressName(boolean suppressName) { | |
274 | 0 | this.suppressName = suppressName; |
275 | 0 | } |
276 | ||
277 | /** | |
278 | * {@inheritDoc} | |
279 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getFormattedName() | |
280 | */ | |
281 | public String getFormattedName() { | |
282 | 0 | return formattedName; |
283 | } | |
284 | ||
285 | /** | |
286 | * @param formattedName the formattedName to set | |
287 | */ | |
288 | public void setFormattedName(String formattedName) { | |
289 | 0 | this.formattedName = formattedName; |
290 | 0 | } |
291 | ||
292 | /** | |
293 | * {@inheritDoc} | |
294 | * @see org.kuali.rice.kim.bo.entity.KimEntityName#getFormattedNameUnmasked() | |
295 | */ | |
296 | public String getFormattedNameUnmasked() { | |
297 | 0 | return formattedNameUnmasked; |
298 | } | |
299 | ||
300 | /** | |
301 | * @param formattedNameUnmasked the formattedNameUnmasked to set | |
302 | */ | |
303 | public void setFormattedNameUnmasked(String formattedNameUnmasked) { | |
304 | 0 | this.formattedNameUnmasked = formattedNameUnmasked; |
305 | 0 | } |
306 | ||
307 | } |