1
2
3
4
5
6
7
8
9 package ejava.projects.esales.dto;
10
11 import java.util.ArrayList;
12 import java.util.Date;
13 import java.util.List;
14 import javax.xml.bind.annotation.XmlAccessType;
15 import javax.xml.bind.annotation.XmlAccessorType;
16 import javax.xml.bind.annotation.XmlElement;
17 import javax.xml.bind.annotation.XmlIDREF;
18 import javax.xml.bind.annotation.XmlList;
19 import javax.xml.bind.annotation.XmlRootElement;
20 import javax.xml.bind.annotation.XmlSchemaType;
21 import javax.xml.bind.annotation.XmlType;
22 import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51 @XmlAccessorType(XmlAccessType.FIELD)
52 @XmlType(name = "", propOrder = {
53 "login",
54 "firstName",
55 "middleName",
56 "lastName",
57 "email",
58 "startDate",
59 "endDate",
60 "address"
61 })
62 @XmlRootElement(name = "account")
63 public class Account
64 extends ReferencedType
65 {
66
67 @XmlElement(required = true)
68 protected String login;
69 @XmlElement(required = true)
70 protected String firstName;
71 @XmlElement(required = true)
72 protected String middleName;
73 @XmlElement(required = true)
74 protected String lastName;
75 @XmlElement(required = true)
76 protected String email;
77 @XmlElement(required = true, type = String.class)
78 @XmlJavaTypeAdapter(Adapter3 .class)
79 @XmlSchemaType(name = "date")
80 protected Date startDate;
81 @XmlElement(type = String.class)
82 @XmlJavaTypeAdapter(Adapter3 .class)
83 @XmlSchemaType(name = "date")
84 protected Date endDate;
85 @XmlList
86 @XmlIDREF
87 @XmlSchemaType(name = "IDREFS")
88 protected List<Object> address;
89
90
91
92
93
94 public Account() {
95 super();
96 }
97
98
99
100
101
102 public Account(final String refid, final String login, final String firstName, final String middleName, final String lastName, final String email, final Date startDate, final Date endDate, final List<Object> address) {
103 super(refid);
104 this.login = login;
105 this.firstName = firstName;
106 this.middleName = middleName;
107 this.lastName = lastName;
108 this.email = email;
109 this.startDate = startDate;
110 this.endDate = endDate;
111 this.address = address;
112 }
113
114
115
116
117
118
119
120
121
122 public String getLogin() {
123 return login;
124 }
125
126
127
128
129
130
131
132
133
134 public void setLogin(String value) {
135 this.login = value;
136 }
137
138
139
140
141
142
143
144
145
146 public String getFirstName() {
147 return firstName;
148 }
149
150
151
152
153
154
155
156
157
158 public void setFirstName(String value) {
159 this.firstName = value;
160 }
161
162
163
164
165
166
167
168
169
170 public String getMiddleName() {
171 return middleName;
172 }
173
174
175
176
177
178
179
180
181
182 public void setMiddleName(String value) {
183 this.middleName = value;
184 }
185
186
187
188
189
190
191
192
193
194 public String getLastName() {
195 return lastName;
196 }
197
198
199
200
201
202
203
204
205
206 public void setLastName(String value) {
207 this.lastName = value;
208 }
209
210
211
212
213
214
215
216
217
218 public String getEmail() {
219 return email;
220 }
221
222
223
224
225
226
227
228
229
230 public void setEmail(String value) {
231 this.email = value;
232 }
233
234
235
236
237
238
239
240
241
242 public Date getStartDate() {
243 return startDate;
244 }
245
246
247
248
249
250
251
252
253
254 public void setStartDate(Date value) {
255 this.startDate = value;
256 }
257
258
259
260
261
262
263
264
265
266 public Date getEndDate() {
267 return endDate;
268 }
269
270
271
272
273
274
275
276
277
278 public void setEndDate(Date value) {
279 this.endDate = value;
280 }
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304 public List<Object> getAddress() {
305 if (address == null) {
306 address = new ArrayList<Object>();
307 }
308 return this.address;
309 }
310
311 }