1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.springframework.batch.sample.domain.football;
18
19 import java.io.Serializable;
20
21 public class Game implements Serializable {
22
23 private String id;
24 private int year;
25 private String team;
26 private int week;
27 private String opponent;
28 private int completes;
29 private int attempts;
30 private int passingYards;
31 private int passingTd;
32 private int interceptions;
33 private int rushes;
34 private int rushYards;
35 private int receptions;
36 private int receptionYards;
37 private int totalTd;
38
39
40
41 public String getId() {
42 return id;
43 }
44
45
46
47 public int getYear() {
48 return year;
49 }
50
51
52
53 public String getTeam() {
54 return team;
55 }
56
57
58
59 public int getWeek() {
60 return week;
61 }
62
63
64
65 public String getOpponent() {
66 return opponent;
67 }
68
69
70
71 public int getCompletes() {
72 return completes;
73 }
74
75
76
77 public int getAttempts() {
78 return attempts;
79 }
80
81
82
83 public int getPassingYards() {
84 return passingYards;
85 }
86
87
88
89 public int getPassingTd() {
90 return passingTd;
91 }
92
93
94
95 public int getInterceptions() {
96 return interceptions;
97 }
98
99
100
101 public int getRushes() {
102 return rushes;
103 }
104
105
106
107 public int getRushYards() {
108 return rushYards;
109 }
110
111
112
113 public int getReceptions() {
114 return receptions;
115 }
116
117
118
119 public int getReceptionYards() {
120 return receptionYards;
121 }
122
123
124
125 public int getTotalTd() {
126 return totalTd;
127 }
128
129
130
131 public void setId(String id) {
132 this.id = id;
133 }
134
135
136
137 public void setYear(int year) {
138 this.year = year;
139 }
140
141
142
143 public void setTeam(String team) {
144 this.team = team;
145 }
146
147
148
149 public void setWeek(int week) {
150 this.week = week;
151 }
152
153
154
155 public void setOpponent(String opponent) {
156 this.opponent = opponent;
157 }
158
159
160
161 public void setCompletes(int completes) {
162 this.completes = completes;
163 }
164
165
166
167 public void setAttempts(int attempts) {
168 this.attempts = attempts;
169 }
170
171
172
173 public void setPassingYards(int passingYards) {
174 this.passingYards = passingYards;
175 }
176
177
178
179 public void setPassingTd(int passingTd) {
180 this.passingTd = passingTd;
181 }
182
183
184
185 public void setInterceptions(int interceptions) {
186 this.interceptions = interceptions;
187 }
188
189
190
191 public void setRushes(int rushes) {
192 this.rushes = rushes;
193 }
194
195
196
197 public void setRushYards(int rushYards) {
198 this.rushYards = rushYards;
199 }
200
201
202
203 public void setReceptions(int receptions) {
204 this.receptions = receptions;
205 }
206
207
208
209 public void setReceptionYards(int receptionYards) {
210 this.receptionYards = receptionYards;
211 }
212
213
214
215 public void setTotalTd(int totalTd) {
216 this.totalTd = totalTd;
217 }
218
219
220 public String toString() {
221
222 return "Game: ID=" + id + " " + team + " vs. " + opponent +
223 " - " + year;
224 }
225
226 @Override
227 public int hashCode() {
228 final int prime = 31;
229 int result = 1;
230 result = prime * result + ((id == null) ? 0 : id.hashCode());
231 return result;
232 }
233 @Override
234 public boolean equals(Object obj) {
235 if (this == obj)
236 return true;
237 if (obj == null)
238 return false;
239 if (getClass() != obj.getClass())
240 return false;
241 Game other = (Game) obj;
242 if (id == null) {
243 if (other.id != null)
244 return false;
245 }
246 else if (!id.equals(other.id))
247 return false;
248 return true;
249 }
250
251 }