| 483 |
rajveer |
1 |
/**
|
|
|
2 |
* Autogenerated by Thrift
|
|
|
3 |
*
|
|
|
4 |
* DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
|
|
|
5 |
*/
|
|
|
6 |
package in.shop2020.logistics;
|
|
|
7 |
|
|
|
8 |
import java.util.List;
|
|
|
9 |
import java.util.ArrayList;
|
|
|
10 |
import java.util.Map;
|
|
|
11 |
import java.util.HashMap;
|
|
|
12 |
import java.util.EnumMap;
|
|
|
13 |
import java.util.Set;
|
|
|
14 |
import java.util.HashSet;
|
|
|
15 |
import java.util.EnumSet;
|
|
|
16 |
import java.util.Collections;
|
|
|
17 |
import java.util.BitSet;
|
|
|
18 |
import java.util.Arrays;
|
|
|
19 |
import org.slf4j.Logger;
|
|
|
20 |
import org.slf4j.LoggerFactory;
|
|
|
21 |
|
|
|
22 |
import org.apache.thrift.*;
|
|
|
23 |
import org.apache.thrift.meta_data.*;
|
|
|
24 |
import org.apache.thrift.protocol.*;
|
|
|
25 |
|
|
|
26 |
public class LogisticsInfo implements TBase<LogisticsInfo._Fields>, java.io.Serializable, Cloneable, Comparable<LogisticsInfo> {
|
|
|
27 |
private static final TStruct STRUCT_DESC = new TStruct("LogisticsInfo");
|
|
|
28 |
|
| 648 |
chandransh |
29 |
private static final TField WAREHOUSE_ID_FIELD_DESC = new TField("warehouseId", TType.I64, (short)1);
|
|
|
30 |
private static final TField PROVIDER_ID_FIELD_DESC = new TField("providerId", TType.I64, (short)2);
|
|
|
31 |
private static final TField DELIVERY_TIME_FIELD_DESC = new TField("deliveryTime", TType.I64, (short)3);
|
|
|
32 |
private static final TField AIRWAY_BILLNO_FIELD_DESC = new TField("airway_billno", TType.STRING, (short)4);
|
| 483 |
rajveer |
33 |
|
| 648 |
chandransh |
34 |
private long warehouseId;
|
|
|
35 |
private long providerId;
|
|
|
36 |
private long deliveryTime;
|
| 510 |
rajveer |
37 |
private String airway_billno;
|
| 483 |
rajveer |
38 |
|
|
|
39 |
/** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
|
|
|
40 |
public enum _Fields implements TFieldIdEnum {
|
| 648 |
chandransh |
41 |
WAREHOUSE_ID((short)1, "warehouseId"),
|
|
|
42 |
PROVIDER_ID((short)2, "providerId"),
|
|
|
43 |
DELIVERY_TIME((short)3, "deliveryTime"),
|
|
|
44 |
AIRWAY_BILLNO((short)4, "airway_billno");
|
| 483 |
rajveer |
45 |
|
|
|
46 |
private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
|
|
|
47 |
private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
|
|
|
48 |
|
|
|
49 |
static {
|
|
|
50 |
for (_Fields field : EnumSet.allOf(_Fields.class)) {
|
|
|
51 |
byId.put((int)field._thriftId, field);
|
|
|
52 |
byName.put(field.getFieldName(), field);
|
|
|
53 |
}
|
|
|
54 |
}
|
|
|
55 |
|
|
|
56 |
/**
|
|
|
57 |
* Find the _Fields constant that matches fieldId, or null if its not found.
|
|
|
58 |
*/
|
|
|
59 |
public static _Fields findByThriftId(int fieldId) {
|
|
|
60 |
return byId.get(fieldId);
|
|
|
61 |
}
|
|
|
62 |
|
|
|
63 |
/**
|
|
|
64 |
* Find the _Fields constant that matches fieldId, throwing an exception
|
|
|
65 |
* if it is not found.
|
|
|
66 |
*/
|
|
|
67 |
public static _Fields findByThriftIdOrThrow(int fieldId) {
|
|
|
68 |
_Fields fields = findByThriftId(fieldId);
|
|
|
69 |
if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
|
|
|
70 |
return fields;
|
|
|
71 |
}
|
|
|
72 |
|
|
|
73 |
/**
|
|
|
74 |
* Find the _Fields constant that matches name, or null if its not found.
|
|
|
75 |
*/
|
|
|
76 |
public static _Fields findByName(String name) {
|
|
|
77 |
return byName.get(name);
|
|
|
78 |
}
|
|
|
79 |
|
|
|
80 |
private final short _thriftId;
|
|
|
81 |
private final String _fieldName;
|
|
|
82 |
|
|
|
83 |
_Fields(short thriftId, String fieldName) {
|
|
|
84 |
_thriftId = thriftId;
|
|
|
85 |
_fieldName = fieldName;
|
|
|
86 |
}
|
|
|
87 |
|
|
|
88 |
public short getThriftFieldId() {
|
|
|
89 |
return _thriftId;
|
|
|
90 |
}
|
|
|
91 |
|
|
|
92 |
public String getFieldName() {
|
|
|
93 |
return _fieldName;
|
|
|
94 |
}
|
|
|
95 |
}
|
|
|
96 |
|
|
|
97 |
// isset id assignments
|
| 648 |
chandransh |
98 |
private static final int __WAREHOUSEID_ISSET_ID = 0;
|
|
|
99 |
private static final int __PROVIDERID_ISSET_ID = 1;
|
|
|
100 |
private static final int __DELIVERYTIME_ISSET_ID = 2;
|
| 510 |
rajveer |
101 |
private BitSet __isset_bit_vector = new BitSet(3);
|
| 483 |
rajveer |
102 |
|
|
|
103 |
public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
|
| 648 |
chandransh |
104 |
put(_Fields.WAREHOUSE_ID, new FieldMetaData("warehouseId", TFieldRequirementType.DEFAULT,
|
| 483 |
rajveer |
105 |
new FieldValueMetaData(TType.I64)));
|
| 648 |
chandransh |
106 |
put(_Fields.PROVIDER_ID, new FieldMetaData("providerId", TFieldRequirementType.DEFAULT,
|
| 483 |
rajveer |
107 |
new FieldValueMetaData(TType.I64)));
|
| 648 |
chandransh |
108 |
put(_Fields.DELIVERY_TIME, new FieldMetaData("deliveryTime", TFieldRequirementType.DEFAULT,
|
|
|
109 |
new FieldValueMetaData(TType.I64)));
|
| 483 |
rajveer |
110 |
put(_Fields.AIRWAY_BILLNO, new FieldMetaData("airway_billno", TFieldRequirementType.DEFAULT,
|
| 510 |
rajveer |
111 |
new FieldValueMetaData(TType.STRING)));
|
| 483 |
rajveer |
112 |
}});
|
|
|
113 |
|
|
|
114 |
static {
|
|
|
115 |
FieldMetaData.addStructMetaDataMap(LogisticsInfo.class, metaDataMap);
|
|
|
116 |
}
|
|
|
117 |
|
|
|
118 |
public LogisticsInfo() {
|
|
|
119 |
}
|
|
|
120 |
|
|
|
121 |
public LogisticsInfo(
|
| 648 |
chandransh |
122 |
long warehouseId,
|
|
|
123 |
long providerId,
|
|
|
124 |
long deliveryTime,
|
|
|
125 |
String airway_billno)
|
| 483 |
rajveer |
126 |
{
|
|
|
127 |
this();
|
| 648 |
chandransh |
128 |
this.warehouseId = warehouseId;
|
|
|
129 |
setWarehouseIdIsSet(true);
|
|
|
130 |
this.providerId = providerId;
|
|
|
131 |
setProviderIdIsSet(true);
|
|
|
132 |
this.deliveryTime = deliveryTime;
|
|
|
133 |
setDeliveryTimeIsSet(true);
|
| 483 |
rajveer |
134 |
this.airway_billno = airway_billno;
|
|
|
135 |
}
|
|
|
136 |
|
|
|
137 |
/**
|
|
|
138 |
* Performs a deep copy on <i>other</i>.
|
|
|
139 |
*/
|
|
|
140 |
public LogisticsInfo(LogisticsInfo other) {
|
|
|
141 |
__isset_bit_vector.clear();
|
|
|
142 |
__isset_bit_vector.or(other.__isset_bit_vector);
|
| 648 |
chandransh |
143 |
this.warehouseId = other.warehouseId;
|
|
|
144 |
this.providerId = other.providerId;
|
|
|
145 |
this.deliveryTime = other.deliveryTime;
|
| 510 |
rajveer |
146 |
if (other.isSetAirway_billno()) {
|
|
|
147 |
this.airway_billno = other.airway_billno;
|
|
|
148 |
}
|
| 483 |
rajveer |
149 |
}
|
|
|
150 |
|
|
|
151 |
public LogisticsInfo deepCopy() {
|
|
|
152 |
return new LogisticsInfo(this);
|
|
|
153 |
}
|
|
|
154 |
|
|
|
155 |
@Deprecated
|
|
|
156 |
public LogisticsInfo clone() {
|
|
|
157 |
return new LogisticsInfo(this);
|
|
|
158 |
}
|
|
|
159 |
|
| 648 |
chandransh |
160 |
public long getWarehouseId() {
|
|
|
161 |
return this.warehouseId;
|
| 483 |
rajveer |
162 |
}
|
|
|
163 |
|
| 648 |
chandransh |
164 |
public LogisticsInfo setWarehouseId(long warehouseId) {
|
|
|
165 |
this.warehouseId = warehouseId;
|
|
|
166 |
setWarehouseIdIsSet(true);
|
| 483 |
rajveer |
167 |
return this;
|
|
|
168 |
}
|
|
|
169 |
|
| 648 |
chandransh |
170 |
public void unsetWarehouseId() {
|
|
|
171 |
__isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
|
| 483 |
rajveer |
172 |
}
|
|
|
173 |
|
| 648 |
chandransh |
174 |
/** Returns true if field warehouseId is set (has been asigned a value) and false otherwise */
|
|
|
175 |
public boolean isSetWarehouseId() {
|
|
|
176 |
return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
|
| 483 |
rajveer |
177 |
}
|
|
|
178 |
|
| 648 |
chandransh |
179 |
public void setWarehouseIdIsSet(boolean value) {
|
|
|
180 |
__isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
|
| 483 |
rajveer |
181 |
}
|
|
|
182 |
|
| 648 |
chandransh |
183 |
public long getProviderId() {
|
|
|
184 |
return this.providerId;
|
| 483 |
rajveer |
185 |
}
|
|
|
186 |
|
| 648 |
chandransh |
187 |
public LogisticsInfo setProviderId(long providerId) {
|
|
|
188 |
this.providerId = providerId;
|
|
|
189 |
setProviderIdIsSet(true);
|
| 483 |
rajveer |
190 |
return this;
|
|
|
191 |
}
|
|
|
192 |
|
| 648 |
chandransh |
193 |
public void unsetProviderId() {
|
|
|
194 |
__isset_bit_vector.clear(__PROVIDERID_ISSET_ID);
|
| 483 |
rajveer |
195 |
}
|
|
|
196 |
|
| 648 |
chandransh |
197 |
/** Returns true if field providerId is set (has been asigned a value) and false otherwise */
|
|
|
198 |
public boolean isSetProviderId() {
|
|
|
199 |
return __isset_bit_vector.get(__PROVIDERID_ISSET_ID);
|
| 483 |
rajveer |
200 |
}
|
|
|
201 |
|
| 648 |
chandransh |
202 |
public void setProviderIdIsSet(boolean value) {
|
|
|
203 |
__isset_bit_vector.set(__PROVIDERID_ISSET_ID, value);
|
| 483 |
rajveer |
204 |
}
|
|
|
205 |
|
| 648 |
chandransh |
206 |
public long getDeliveryTime() {
|
|
|
207 |
return this.deliveryTime;
|
|
|
208 |
}
|
|
|
209 |
|
|
|
210 |
public LogisticsInfo setDeliveryTime(long deliveryTime) {
|
|
|
211 |
this.deliveryTime = deliveryTime;
|
|
|
212 |
setDeliveryTimeIsSet(true);
|
|
|
213 |
return this;
|
|
|
214 |
}
|
|
|
215 |
|
|
|
216 |
public void unsetDeliveryTime() {
|
|
|
217 |
__isset_bit_vector.clear(__DELIVERYTIME_ISSET_ID);
|
|
|
218 |
}
|
|
|
219 |
|
|
|
220 |
/** Returns true if field deliveryTime is set (has been asigned a value) and false otherwise */
|
|
|
221 |
public boolean isSetDeliveryTime() {
|
|
|
222 |
return __isset_bit_vector.get(__DELIVERYTIME_ISSET_ID);
|
|
|
223 |
}
|
|
|
224 |
|
|
|
225 |
public void setDeliveryTimeIsSet(boolean value) {
|
|
|
226 |
__isset_bit_vector.set(__DELIVERYTIME_ISSET_ID, value);
|
|
|
227 |
}
|
|
|
228 |
|
| 510 |
rajveer |
229 |
public String getAirway_billno() {
|
| 483 |
rajveer |
230 |
return this.airway_billno;
|
|
|
231 |
}
|
|
|
232 |
|
| 510 |
rajveer |
233 |
public LogisticsInfo setAirway_billno(String airway_billno) {
|
| 483 |
rajveer |
234 |
this.airway_billno = airway_billno;
|
|
|
235 |
return this;
|
|
|
236 |
}
|
|
|
237 |
|
|
|
238 |
public void unsetAirway_billno() {
|
| 510 |
rajveer |
239 |
this.airway_billno = null;
|
| 483 |
rajveer |
240 |
}
|
|
|
241 |
|
|
|
242 |
/** Returns true if field airway_billno is set (has been asigned a value) and false otherwise */
|
|
|
243 |
public boolean isSetAirway_billno() {
|
| 510 |
rajveer |
244 |
return this.airway_billno != null;
|
| 483 |
rajveer |
245 |
}
|
|
|
246 |
|
|
|
247 |
public void setAirway_billnoIsSet(boolean value) {
|
| 510 |
rajveer |
248 |
if (!value) {
|
|
|
249 |
this.airway_billno = null;
|
|
|
250 |
}
|
| 483 |
rajveer |
251 |
}
|
|
|
252 |
|
|
|
253 |
public void setFieldValue(_Fields field, Object value) {
|
|
|
254 |
switch (field) {
|
|
|
255 |
case WAREHOUSE_ID:
|
|
|
256 |
if (value == null) {
|
| 648 |
chandransh |
257 |
unsetWarehouseId();
|
| 483 |
rajveer |
258 |
} else {
|
| 648 |
chandransh |
259 |
setWarehouseId((Long)value);
|
| 483 |
rajveer |
260 |
}
|
|
|
261 |
break;
|
|
|
262 |
|
|
|
263 |
case PROVIDER_ID:
|
|
|
264 |
if (value == null) {
|
| 648 |
chandransh |
265 |
unsetProviderId();
|
| 483 |
rajveer |
266 |
} else {
|
| 648 |
chandransh |
267 |
setProviderId((Long)value);
|
| 483 |
rajveer |
268 |
}
|
|
|
269 |
break;
|
|
|
270 |
|
| 648 |
chandransh |
271 |
case DELIVERY_TIME:
|
| 483 |
rajveer |
272 |
if (value == null) {
|
| 648 |
chandransh |
273 |
unsetDeliveryTime();
|
| 483 |
rajveer |
274 |
} else {
|
| 648 |
chandransh |
275 |
setDeliveryTime((Long)value);
|
| 483 |
rajveer |
276 |
}
|
|
|
277 |
break;
|
|
|
278 |
|
| 648 |
chandransh |
279 |
case AIRWAY_BILLNO:
|
| 483 |
rajveer |
280 |
if (value == null) {
|
| 648 |
chandransh |
281 |
unsetAirway_billno();
|
| 483 |
rajveer |
282 |
} else {
|
| 648 |
chandransh |
283 |
setAirway_billno((String)value);
|
| 483 |
rajveer |
284 |
}
|
|
|
285 |
break;
|
|
|
286 |
|
|
|
287 |
}
|
|
|
288 |
}
|
|
|
289 |
|
|
|
290 |
public void setFieldValue(int fieldID, Object value) {
|
|
|
291 |
setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
|
|
|
292 |
}
|
|
|
293 |
|
|
|
294 |
public Object getFieldValue(_Fields field) {
|
|
|
295 |
switch (field) {
|
|
|
296 |
case WAREHOUSE_ID:
|
| 648 |
chandransh |
297 |
return new Long(getWarehouseId());
|
| 483 |
rajveer |
298 |
|
|
|
299 |
case PROVIDER_ID:
|
| 648 |
chandransh |
300 |
return new Long(getProviderId());
|
| 483 |
rajveer |
301 |
|
| 648 |
chandransh |
302 |
case DELIVERY_TIME:
|
|
|
303 |
return new Long(getDeliveryTime());
|
|
|
304 |
|
| 483 |
rajveer |
305 |
case AIRWAY_BILLNO:
|
| 510 |
rajveer |
306 |
return getAirway_billno();
|
| 483 |
rajveer |
307 |
|
|
|
308 |
}
|
|
|
309 |
throw new IllegalStateException();
|
|
|
310 |
}
|
|
|
311 |
|
|
|
312 |
public Object getFieldValue(int fieldId) {
|
|
|
313 |
return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
|
|
|
314 |
}
|
|
|
315 |
|
|
|
316 |
/** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
|
|
|
317 |
public boolean isSet(_Fields field) {
|
|
|
318 |
switch (field) {
|
|
|
319 |
case WAREHOUSE_ID:
|
| 648 |
chandransh |
320 |
return isSetWarehouseId();
|
| 483 |
rajveer |
321 |
case PROVIDER_ID:
|
| 648 |
chandransh |
322 |
return isSetProviderId();
|
|
|
323 |
case DELIVERY_TIME:
|
|
|
324 |
return isSetDeliveryTime();
|
| 483 |
rajveer |
325 |
case AIRWAY_BILLNO:
|
|
|
326 |
return isSetAirway_billno();
|
|
|
327 |
}
|
|
|
328 |
throw new IllegalStateException();
|
|
|
329 |
}
|
|
|
330 |
|
|
|
331 |
public boolean isSet(int fieldID) {
|
|
|
332 |
return isSet(_Fields.findByThriftIdOrThrow(fieldID));
|
|
|
333 |
}
|
|
|
334 |
|
|
|
335 |
@Override
|
|
|
336 |
public boolean equals(Object that) {
|
|
|
337 |
if (that == null)
|
|
|
338 |
return false;
|
|
|
339 |
if (that instanceof LogisticsInfo)
|
|
|
340 |
return this.equals((LogisticsInfo)that);
|
|
|
341 |
return false;
|
|
|
342 |
}
|
|
|
343 |
|
|
|
344 |
public boolean equals(LogisticsInfo that) {
|
|
|
345 |
if (that == null)
|
|
|
346 |
return false;
|
|
|
347 |
|
| 648 |
chandransh |
348 |
boolean this_present_warehouseId = true;
|
|
|
349 |
boolean that_present_warehouseId = true;
|
|
|
350 |
if (this_present_warehouseId || that_present_warehouseId) {
|
|
|
351 |
if (!(this_present_warehouseId && that_present_warehouseId))
|
| 483 |
rajveer |
352 |
return false;
|
| 648 |
chandransh |
353 |
if (this.warehouseId != that.warehouseId)
|
| 483 |
rajveer |
354 |
return false;
|
|
|
355 |
}
|
|
|
356 |
|
| 648 |
chandransh |
357 |
boolean this_present_providerId = true;
|
|
|
358 |
boolean that_present_providerId = true;
|
|
|
359 |
if (this_present_providerId || that_present_providerId) {
|
|
|
360 |
if (!(this_present_providerId && that_present_providerId))
|
| 483 |
rajveer |
361 |
return false;
|
| 648 |
chandransh |
362 |
if (this.providerId != that.providerId)
|
| 483 |
rajveer |
363 |
return false;
|
|
|
364 |
}
|
|
|
365 |
|
| 648 |
chandransh |
366 |
boolean this_present_deliveryTime = true;
|
|
|
367 |
boolean that_present_deliveryTime = true;
|
|
|
368 |
if (this_present_deliveryTime || that_present_deliveryTime) {
|
|
|
369 |
if (!(this_present_deliveryTime && that_present_deliveryTime))
|
|
|
370 |
return false;
|
|
|
371 |
if (this.deliveryTime != that.deliveryTime)
|
|
|
372 |
return false;
|
|
|
373 |
}
|
|
|
374 |
|
| 510 |
rajveer |
375 |
boolean this_present_airway_billno = true && this.isSetAirway_billno();
|
|
|
376 |
boolean that_present_airway_billno = true && that.isSetAirway_billno();
|
| 483 |
rajveer |
377 |
if (this_present_airway_billno || that_present_airway_billno) {
|
|
|
378 |
if (!(this_present_airway_billno && that_present_airway_billno))
|
|
|
379 |
return false;
|
| 510 |
rajveer |
380 |
if (!this.airway_billno.equals(that.airway_billno))
|
| 483 |
rajveer |
381 |
return false;
|
|
|
382 |
}
|
|
|
383 |
|
|
|
384 |
return true;
|
|
|
385 |
}
|
|
|
386 |
|
|
|
387 |
@Override
|
|
|
388 |
public int hashCode() {
|
|
|
389 |
return 0;
|
|
|
390 |
}
|
|
|
391 |
|
|
|
392 |
public int compareTo(LogisticsInfo other) {
|
|
|
393 |
if (!getClass().equals(other.getClass())) {
|
|
|
394 |
return getClass().getName().compareTo(other.getClass().getName());
|
|
|
395 |
}
|
|
|
396 |
|
|
|
397 |
int lastComparison = 0;
|
|
|
398 |
LogisticsInfo typedOther = (LogisticsInfo)other;
|
|
|
399 |
|
| 648 |
chandransh |
400 |
lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(isSetWarehouseId());
|
| 483 |
rajveer |
401 |
if (lastComparison != 0) {
|
|
|
402 |
return lastComparison;
|
|
|
403 |
}
|
| 648 |
chandransh |
404 |
lastComparison = TBaseHelper.compareTo(warehouseId, typedOther.warehouseId);
|
| 483 |
rajveer |
405 |
if (lastComparison != 0) {
|
|
|
406 |
return lastComparison;
|
|
|
407 |
}
|
| 648 |
chandransh |
408 |
lastComparison = Boolean.valueOf(isSetProviderId()).compareTo(isSetProviderId());
|
| 483 |
rajveer |
409 |
if (lastComparison != 0) {
|
|
|
410 |
return lastComparison;
|
|
|
411 |
}
|
| 648 |
chandransh |
412 |
lastComparison = TBaseHelper.compareTo(providerId, typedOther.providerId);
|
| 483 |
rajveer |
413 |
if (lastComparison != 0) {
|
|
|
414 |
return lastComparison;
|
|
|
415 |
}
|
| 648 |
chandransh |
416 |
lastComparison = Boolean.valueOf(isSetDeliveryTime()).compareTo(isSetDeliveryTime());
|
| 483 |
rajveer |
417 |
if (lastComparison != 0) {
|
|
|
418 |
return lastComparison;
|
|
|
419 |
}
|
| 648 |
chandransh |
420 |
lastComparison = TBaseHelper.compareTo(deliveryTime, typedOther.deliveryTime);
|
| 483 |
rajveer |
421 |
if (lastComparison != 0) {
|
|
|
422 |
return lastComparison;
|
|
|
423 |
}
|
| 648 |
chandransh |
424 |
lastComparison = Boolean.valueOf(isSetAirway_billno()).compareTo(isSetAirway_billno());
|
| 483 |
rajveer |
425 |
if (lastComparison != 0) {
|
|
|
426 |
return lastComparison;
|
|
|
427 |
}
|
| 648 |
chandransh |
428 |
lastComparison = TBaseHelper.compareTo(airway_billno, typedOther.airway_billno);
|
| 483 |
rajveer |
429 |
if (lastComparison != 0) {
|
|
|
430 |
return lastComparison;
|
|
|
431 |
}
|
|
|
432 |
return 0;
|
|
|
433 |
}
|
|
|
434 |
|
|
|
435 |
public void read(TProtocol iprot) throws TException {
|
|
|
436 |
TField field;
|
|
|
437 |
iprot.readStructBegin();
|
|
|
438 |
while (true)
|
|
|
439 |
{
|
|
|
440 |
field = iprot.readFieldBegin();
|
|
|
441 |
if (field.type == TType.STOP) {
|
|
|
442 |
break;
|
|
|
443 |
}
|
|
|
444 |
_Fields fieldId = _Fields.findByThriftId(field.id);
|
|
|
445 |
if (fieldId == null) {
|
|
|
446 |
TProtocolUtil.skip(iprot, field.type);
|
|
|
447 |
} else {
|
|
|
448 |
switch (fieldId) {
|
|
|
449 |
case WAREHOUSE_ID:
|
|
|
450 |
if (field.type == TType.I64) {
|
| 648 |
chandransh |
451 |
this.warehouseId = iprot.readI64();
|
|
|
452 |
setWarehouseIdIsSet(true);
|
| 483 |
rajveer |
453 |
} else {
|
|
|
454 |
TProtocolUtil.skip(iprot, field.type);
|
|
|
455 |
}
|
|
|
456 |
break;
|
|
|
457 |
case PROVIDER_ID:
|
|
|
458 |
if (field.type == TType.I64) {
|
| 648 |
chandransh |
459 |
this.providerId = iprot.readI64();
|
|
|
460 |
setProviderIdIsSet(true);
|
| 483 |
rajveer |
461 |
} else {
|
|
|
462 |
TProtocolUtil.skip(iprot, field.type);
|
|
|
463 |
}
|
|
|
464 |
break;
|
| 648 |
chandransh |
465 |
case DELIVERY_TIME:
|
|
|
466 |
if (field.type == TType.I64) {
|
|
|
467 |
this.deliveryTime = iprot.readI64();
|
|
|
468 |
setDeliveryTimeIsSet(true);
|
| 483 |
rajveer |
469 |
} else {
|
|
|
470 |
TProtocolUtil.skip(iprot, field.type);
|
|
|
471 |
}
|
|
|
472 |
break;
|
| 648 |
chandransh |
473 |
case AIRWAY_BILLNO:
|
|
|
474 |
if (field.type == TType.STRING) {
|
|
|
475 |
this.airway_billno = iprot.readString();
|
| 483 |
rajveer |
476 |
} else {
|
|
|
477 |
TProtocolUtil.skip(iprot, field.type);
|
|
|
478 |
}
|
|
|
479 |
break;
|
|
|
480 |
}
|
|
|
481 |
iprot.readFieldEnd();
|
|
|
482 |
}
|
|
|
483 |
}
|
|
|
484 |
iprot.readStructEnd();
|
|
|
485 |
validate();
|
|
|
486 |
}
|
|
|
487 |
|
|
|
488 |
public void write(TProtocol oprot) throws TException {
|
|
|
489 |
validate();
|
|
|
490 |
|
|
|
491 |
oprot.writeStructBegin(STRUCT_DESC);
|
|
|
492 |
oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
|
| 648 |
chandransh |
493 |
oprot.writeI64(this.warehouseId);
|
| 483 |
rajveer |
494 |
oprot.writeFieldEnd();
|
|
|
495 |
oprot.writeFieldBegin(PROVIDER_ID_FIELD_DESC);
|
| 648 |
chandransh |
496 |
oprot.writeI64(this.providerId);
|
| 483 |
rajveer |
497 |
oprot.writeFieldEnd();
|
| 648 |
chandransh |
498 |
oprot.writeFieldBegin(DELIVERY_TIME_FIELD_DESC);
|
|
|
499 |
oprot.writeI64(this.deliveryTime);
|
|
|
500 |
oprot.writeFieldEnd();
|
| 510 |
rajveer |
501 |
if (this.airway_billno != null) {
|
|
|
502 |
oprot.writeFieldBegin(AIRWAY_BILLNO_FIELD_DESC);
|
|
|
503 |
oprot.writeString(this.airway_billno);
|
|
|
504 |
oprot.writeFieldEnd();
|
|
|
505 |
}
|
| 483 |
rajveer |
506 |
oprot.writeFieldStop();
|
|
|
507 |
oprot.writeStructEnd();
|
|
|
508 |
}
|
|
|
509 |
|
|
|
510 |
@Override
|
|
|
511 |
public String toString() {
|
|
|
512 |
StringBuilder sb = new StringBuilder("LogisticsInfo(");
|
|
|
513 |
boolean first = true;
|
|
|
514 |
|
| 648 |
chandransh |
515 |
sb.append("warehouseId:");
|
|
|
516 |
sb.append(this.warehouseId);
|
| 483 |
rajveer |
517 |
first = false;
|
|
|
518 |
if (!first) sb.append(", ");
|
| 648 |
chandransh |
519 |
sb.append("providerId:");
|
|
|
520 |
sb.append(this.providerId);
|
| 483 |
rajveer |
521 |
first = false;
|
|
|
522 |
if (!first) sb.append(", ");
|
| 648 |
chandransh |
523 |
sb.append("deliveryTime:");
|
|
|
524 |
sb.append(this.deliveryTime);
|
|
|
525 |
first = false;
|
|
|
526 |
if (!first) sb.append(", ");
|
| 483 |
rajveer |
527 |
sb.append("airway_billno:");
|
| 510 |
rajveer |
528 |
if (this.airway_billno == null) {
|
|
|
529 |
sb.append("null");
|
|
|
530 |
} else {
|
|
|
531 |
sb.append(this.airway_billno);
|
|
|
532 |
}
|
| 483 |
rajveer |
533 |
first = false;
|
|
|
534 |
sb.append(")");
|
|
|
535 |
return sb.toString();
|
|
|
536 |
}
|
|
|
537 |
|
|
|
538 |
public void validate() throws TException {
|
|
|
539 |
// check for required fields
|
|
|
540 |
}
|
|
|
541 |
|
|
|
542 |
}
|
|
|
543 |
|