1
2
3
4
5
6
7
8
9 package ejava.projects.eleague.dto;
10
11 import java.util.Date;
12 import javax.xml.bind.annotation.XmlAccessType;
13 import javax.xml.bind.annotation.XmlAccessorType;
14 import javax.xml.bind.annotation.XmlAttribute;
15 import javax.xml.bind.annotation.XmlElement;
16 import javax.xml.bind.annotation.XmlIDREF;
17 import javax.xml.bind.annotation.XmlRootElement;
18 import javax.xml.bind.annotation.XmlSchemaType;
19 import javax.xml.bind.annotation.XmlType;
20 import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
21
22
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 @XmlAccessorType(XmlAccessType.FIELD)
50 @XmlType(name = "", propOrder = {
51 "starts",
52 "duration",
53 "location",
54 "homeTeam",
55 "awayTeam",
56 "homeScore",
57 "awayScore"
58 })
59 @XmlRootElement(name = "contest")
60 public class Contest
61 extends ReferencedType
62 {
63
64 @XmlElement(type = String.class)
65 @XmlJavaTypeAdapter(Adapter2 .class)
66 @XmlSchemaType(name = "dateTime")
67 protected Date starts;
68 protected long duration;
69 @XmlIDREF
70 @XmlSchemaType(name = "IDREF")
71 protected Object location;
72 @XmlElement(required = true)
73 @XmlIDREF
74 @XmlSchemaType(name = "IDREF")
75 protected Object homeTeam;
76 @XmlElement(required = true)
77 @XmlIDREF
78 @XmlSchemaType(name = "IDREF")
79 protected Object awayTeam;
80 @XmlElement(type = String.class)
81 @XmlJavaTypeAdapter(Adapter4 .class)
82 @XmlSchemaType(name = "int")
83 protected Integer homeScore;
84 @XmlElement(type = String.class)
85 @XmlJavaTypeAdapter(Adapter4 .class)
86 @XmlSchemaType(name = "int")
87 protected Integer awayScore;
88 @XmlAttribute(name = "id", required = true)
89 protected long id;
90
91
92
93
94
95 public Contest() {
96 super();
97 }
98
99
100
101
102
103 public Contest(final String refid, final Date starts, final long duration, final Object location, final Object homeTeam, final Object awayTeam, final Integer homeScore, final Integer awayScore, final long id) {
104 super(refid);
105 this.starts = starts;
106 this.duration = duration;
107 this.location = location;
108 this.homeTeam = homeTeam;
109 this.awayTeam = awayTeam;
110 this.homeScore = homeScore;
111 this.awayScore = awayScore;
112 this.id = id;
113 }
114
115
116
117
118
119
120
121
122
123 public Date getStarts() {
124 return starts;
125 }
126
127
128
129
130
131
132
133
134
135 public void setStarts(Date value) {
136 this.starts = value;
137 }
138
139
140
141
142
143 public long getDuration() {
144 return duration;
145 }
146
147
148
149
150
151 public void setDuration(long value) {
152 this.duration = value;
153 }
154
155
156
157
158
159
160
161
162
163 public Object getLocation() {
164 return location;
165 }
166
167
168
169
170
171
172
173
174
175 public void setLocation(Object value) {
176 this.location = value;
177 }
178
179
180
181
182
183
184
185
186
187 public Object getHomeTeam() {
188 return homeTeam;
189 }
190
191
192
193
194
195
196
197
198
199 public void setHomeTeam(Object value) {
200 this.homeTeam = value;
201 }
202
203
204
205
206
207
208
209
210
211 public Object getAwayTeam() {
212 return awayTeam;
213 }
214
215
216
217
218
219
220
221
222
223 public void setAwayTeam(Object value) {
224 this.awayTeam = value;
225 }
226
227
228
229
230
231
232
233
234
235 public Integer getHomeScore() {
236 return homeScore;
237 }
238
239
240
241
242
243
244
245
246
247 public void setHomeScore(Integer value) {
248 this.homeScore = value;
249 }
250
251
252
253
254
255
256
257
258
259 public Integer getAwayScore() {
260 return awayScore;
261 }
262
263
264
265
266
267
268
269
270
271 public void setAwayScore(Integer value) {
272 this.awayScore = value;
273 }
274
275
276
277
278
279 public long getId() {
280 return id;
281 }
282
283
284
285
286
287 public void setId(long value) {
288 this.id = value;
289 }
290
291 }