Subversion Repositories SmartDukaan

Rev

Rev 1013 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1013 Rev 3430
Line 1... Line 1...
1
/**
1
/**
2
 * Autogenerated by Thrift
2
 * Autogenerated by Thrift Compiler (0.7.0)
3
 *
3
 *
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
 */
5
 */
6
package in.shop2020.model.v1.catalog;
6
package in.shop2020.model.v1.catalog;
7
 
7
 
Line 13... Line 13...
13
import java.util.Set;
13
import java.util.Set;
14
import java.util.HashSet;
14
import java.util.HashSet;
15
import java.util.EnumSet;
15
import java.util.EnumSet;
16
import java.util.Collections;
16
import java.util.Collections;
17
import java.util.BitSet;
17
import java.util.BitSet;
-
 
18
import java.nio.ByteBuffer;
18
import java.util.Arrays;
19
import java.util.Arrays;
19
import org.slf4j.Logger;
20
import org.slf4j.Logger;
20
import org.slf4j.LoggerFactory;
21
import org.slf4j.LoggerFactory;
21
 
22
 
22
import org.apache.thrift.*;
-
 
23
import org.apache.thrift.meta_data.*;
-
 
24
import org.apache.thrift.protocol.*;
-
 
25
 
-
 
26
public class ItemInventoryHistory implements TBase<ItemInventoryHistory._Fields>, java.io.Serializable, Cloneable, Comparable<ItemInventoryHistory> {
23
public class ItemInventoryHistory implements org.apache.thrift.TBase<ItemInventoryHistory, ItemInventoryHistory._Fields>, java.io.Serializable, Cloneable {
27
  private static final TStruct STRUCT_DESC = new TStruct("ItemInventoryHistory");
24
  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("ItemInventoryHistory");
28
 
25
 
29
  private static final TField ITEM_ID_FIELD_DESC = new TField("item_id", TType.I64, (short)1);
26
  private static final org.apache.thrift.protocol.TField ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("item_id", org.apache.thrift.protocol.TType.I64, (short)1);
30
  private static final TField WAREHOUSE_ID_FIELD_DESC = new TField("warehouse_id", TType.I64, (short)2);
27
  private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouse_id", org.apache.thrift.protocol.TType.I64, (short)2);
31
  private static final TField TIMESTAMP_FIELD_DESC = new TField("timestamp", TType.I64, (short)3);
28
  private static final org.apache.thrift.protocol.TField TIMESTAMP_FIELD_DESC = new org.apache.thrift.protocol.TField("timestamp", org.apache.thrift.protocol.TType.I64, (short)3);
32
  private static final TField AVAILABILITY_FIELD_DESC = new TField("availability", TType.I64, (short)4);
29
  private static final org.apache.thrift.protocol.TField AVAILABILITY_FIELD_DESC = new org.apache.thrift.protocol.TField("availability", org.apache.thrift.protocol.TType.I64, (short)4);
33
 
30
 
34
  private long item_id;
31
  private long item_id; // required
35
  private long warehouse_id;
32
  private long warehouse_id; // required
36
  private long timestamp;
33
  private long timestamp; // required
37
  private long availability;
34
  private long availability; // required
38
 
35
 
39
  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
36
  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
40
  public enum _Fields implements TFieldIdEnum {
37
  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
41
    ITEM_ID((short)1, "item_id"),
38
    ITEM_ID((short)1, "item_id"),
42
    WAREHOUSE_ID((short)2, "warehouse_id"),
39
    WAREHOUSE_ID((short)2, "warehouse_id"),
43
    TIMESTAMP((short)3, "timestamp"),
40
    TIMESTAMP((short)3, "timestamp"),
44
    AVAILABILITY((short)4, "availability");
41
    AVAILABILITY((short)4, "availability");
45
 
42
 
46
    private static final Map<Integer, _Fields> byId = new HashMap<Integer, _Fields>();
-
 
47
    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
43
    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
48
 
44
 
49
    static {
45
    static {
50
      for (_Fields field : EnumSet.allOf(_Fields.class)) {
46
      for (_Fields field : EnumSet.allOf(_Fields.class)) {
51
        byId.put((int)field._thriftId, field);
-
 
52
        byName.put(field.getFieldName(), field);
47
        byName.put(field.getFieldName(), field);
53
      }
48
      }
54
    }
49
    }
55
 
50
 
56
    /**
51
    /**
57
     * Find the _Fields constant that matches fieldId, or null if its not found.
52
     * Find the _Fields constant that matches fieldId, or null if its not found.
58
     */
53
     */
59
    public static _Fields findByThriftId(int fieldId) {
54
    public static _Fields findByThriftId(int fieldId) {
60
      return byId.get(fieldId);
55
      switch(fieldId) {
-
 
56
        case 1: // ITEM_ID
-
 
57
          return ITEM_ID;
-
 
58
        case 2: // WAREHOUSE_ID
-
 
59
          return WAREHOUSE_ID;
-
 
60
        case 3: // TIMESTAMP
-
 
61
          return TIMESTAMP;
-
 
62
        case 4: // AVAILABILITY
-
 
63
          return AVAILABILITY;
-
 
64
        default:
-
 
65
          return null;
-
 
66
      }
61
    }
67
    }
62
 
68
 
63
    /**
69
    /**
64
     * Find the _Fields constant that matches fieldId, throwing an exception
70
     * Find the _Fields constant that matches fieldId, throwing an exception
65
     * if it is not found.
71
     * if it is not found.
Line 99... Line 105...
99
  private static final int __WAREHOUSE_ID_ISSET_ID = 1;
105
  private static final int __WAREHOUSE_ID_ISSET_ID = 1;
100
  private static final int __TIMESTAMP_ISSET_ID = 2;
106
  private static final int __TIMESTAMP_ISSET_ID = 2;
101
  private static final int __AVAILABILITY_ISSET_ID = 3;
107
  private static final int __AVAILABILITY_ISSET_ID = 3;
102
  private BitSet __isset_bit_vector = new BitSet(4);
108
  private BitSet __isset_bit_vector = new BitSet(4);
103
 
109
 
104
  public static final Map<_Fields, FieldMetaData> metaDataMap = Collections.unmodifiableMap(new EnumMap<_Fields, FieldMetaData>(_Fields.class) {{
110
  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
105
    put(_Fields.ITEM_ID, new FieldMetaData("item_id", TFieldRequirementType.DEFAULT, 
-
 
106
        new FieldValueMetaData(TType.I64)));
-
 
107
    put(_Fields.WAREHOUSE_ID, new FieldMetaData("warehouse_id", TFieldRequirementType.DEFAULT, 
-
 
108
        new FieldValueMetaData(TType.I64)));
-
 
109
    put(_Fields.TIMESTAMP, new FieldMetaData("timestamp", TFieldRequirementType.DEFAULT, 
-
 
110
        new FieldValueMetaData(TType.I64)));
-
 
111
    put(_Fields.AVAILABILITY, new FieldMetaData("availability", TFieldRequirementType.DEFAULT, 
-
 
112
        new FieldValueMetaData(TType.I64)));
-
 
113
  }});
-
 
114
 
-
 
115
  static {
111
  static {
-
 
112
    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
-
 
113
    tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
114
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
115
    tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
116
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
117
    tmpMap.put(_Fields.TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("timestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
118
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
119
    tmpMap.put(_Fields.AVAILABILITY, new org.apache.thrift.meta_data.FieldMetaData("availability", org.apache.thrift.TFieldRequirementType.DEFAULT, 
-
 
120
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
-
 
121
    metaDataMap = Collections.unmodifiableMap(tmpMap);
116
    FieldMetaData.addStructMetaDataMap(ItemInventoryHistory.class, metaDataMap);
122
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(ItemInventoryHistory.class, metaDataMap);
117
  }
123
  }
118
 
124
 
119
  public ItemInventoryHistory() {
125
  public ItemInventoryHistory() {
120
  }
126
  }
121
 
127
 
Line 150... Line 156...
150
 
156
 
151
  public ItemInventoryHistory deepCopy() {
157
  public ItemInventoryHistory deepCopy() {
152
    return new ItemInventoryHistory(this);
158
    return new ItemInventoryHistory(this);
153
  }
159
  }
154
 
160
 
155
  @Deprecated
161
  @Override
156
  public ItemInventoryHistory clone() {
162
  public void clear() {
-
 
163
    setItem_idIsSet(false);
-
 
164
    this.item_id = 0;
-
 
165
    setWarehouse_idIsSet(false);
-
 
166
    this.warehouse_id = 0;
157
    return new ItemInventoryHistory(this);
167
    setTimestampIsSet(false);
-
 
168
    this.timestamp = 0;
-
 
169
    setAvailabilityIsSet(false);
-
 
170
    this.availability = 0;
158
  }
171
  }
159
 
172
 
160
  public long getItem_id() {
173
  public long getItem_id() {
161
    return this.item_id;
174
    return this.item_id;
162
  }
175
  }
163
 
176
 
164
  public ItemInventoryHistory setItem_id(long item_id) {
177
  public void setItem_id(long item_id) {
165
    this.item_id = item_id;
178
    this.item_id = item_id;
166
    setItem_idIsSet(true);
179
    setItem_idIsSet(true);
167
    return this;
-
 
168
  }
180
  }
169
 
181
 
170
  public void unsetItem_id() {
182
  public void unsetItem_id() {
171
    __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
183
    __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
172
  }
184
  }
173
 
185
 
174
  /** Returns true if field item_id is set (has been asigned a value) and false otherwise */
186
  /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
175
  public boolean isSetItem_id() {
187
  public boolean isSetItem_id() {
176
    return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
188
    return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
177
  }
189
  }
178
 
190
 
179
  public void setItem_idIsSet(boolean value) {
191
  public void setItem_idIsSet(boolean value) {
Line 182... Line 194...
182
 
194
 
183
  public long getWarehouse_id() {
195
  public long getWarehouse_id() {
184
    return this.warehouse_id;
196
    return this.warehouse_id;
185
  }
197
  }
186
 
198
 
187
  public ItemInventoryHistory setWarehouse_id(long warehouse_id) {
199
  public void setWarehouse_id(long warehouse_id) {
188
    this.warehouse_id = warehouse_id;
200
    this.warehouse_id = warehouse_id;
189
    setWarehouse_idIsSet(true);
201
    setWarehouse_idIsSet(true);
190
    return this;
-
 
191
  }
202
  }
192
 
203
 
193
  public void unsetWarehouse_id() {
204
  public void unsetWarehouse_id() {
194
    __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
205
    __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
195
  }
206
  }
196
 
207
 
197
  /** Returns true if field warehouse_id is set (has been asigned a value) and false otherwise */
208
  /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
198
  public boolean isSetWarehouse_id() {
209
  public boolean isSetWarehouse_id() {
199
    return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
210
    return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
200
  }
211
  }
201
 
212
 
202
  public void setWarehouse_idIsSet(boolean value) {
213
  public void setWarehouse_idIsSet(boolean value) {
Line 205... Line 216...
205
 
216
 
206
  public long getTimestamp() {
217
  public long getTimestamp() {
207
    return this.timestamp;
218
    return this.timestamp;
208
  }
219
  }
209
 
220
 
210
  public ItemInventoryHistory setTimestamp(long timestamp) {
221
  public void setTimestamp(long timestamp) {
211
    this.timestamp = timestamp;
222
    this.timestamp = timestamp;
212
    setTimestampIsSet(true);
223
    setTimestampIsSet(true);
213
    return this;
-
 
214
  }
224
  }
215
 
225
 
216
  public void unsetTimestamp() {
226
  public void unsetTimestamp() {
217
    __isset_bit_vector.clear(__TIMESTAMP_ISSET_ID);
227
    __isset_bit_vector.clear(__TIMESTAMP_ISSET_ID);
218
  }
228
  }
219
 
229
 
220
  /** Returns true if field timestamp is set (has been asigned a value) and false otherwise */
230
  /** Returns true if field timestamp is set (has been assigned a value) and false otherwise */
221
  public boolean isSetTimestamp() {
231
  public boolean isSetTimestamp() {
222
    return __isset_bit_vector.get(__TIMESTAMP_ISSET_ID);
232
    return __isset_bit_vector.get(__TIMESTAMP_ISSET_ID);
223
  }
233
  }
224
 
234
 
225
  public void setTimestampIsSet(boolean value) {
235
  public void setTimestampIsSet(boolean value) {
Line 228... Line 238...
228
 
238
 
229
  public long getAvailability() {
239
  public long getAvailability() {
230
    return this.availability;
240
    return this.availability;
231
  }
241
  }
232
 
242
 
233
  public ItemInventoryHistory setAvailability(long availability) {
243
  public void setAvailability(long availability) {
234
    this.availability = availability;
244
    this.availability = availability;
235
    setAvailabilityIsSet(true);
245
    setAvailabilityIsSet(true);
236
    return this;
-
 
237
  }
246
  }
238
 
247
 
239
  public void unsetAvailability() {
248
  public void unsetAvailability() {
240
    __isset_bit_vector.clear(__AVAILABILITY_ISSET_ID);
249
    __isset_bit_vector.clear(__AVAILABILITY_ISSET_ID);
241
  }
250
  }
242
 
251
 
243
  /** Returns true if field availability is set (has been asigned a value) and false otherwise */
252
  /** Returns true if field availability is set (has been assigned a value) and false otherwise */
244
  public boolean isSetAvailability() {
253
  public boolean isSetAvailability() {
245
    return __isset_bit_vector.get(__AVAILABILITY_ISSET_ID);
254
    return __isset_bit_vector.get(__AVAILABILITY_ISSET_ID);
246
  }
255
  }
247
 
256
 
248
  public void setAvailabilityIsSet(boolean value) {
257
  public void setAvailabilityIsSet(boolean value) {
Line 284... Line 293...
284
      break;
293
      break;
285
 
294
 
286
    }
295
    }
287
  }
296
  }
288
 
297
 
289
  public void setFieldValue(int fieldID, Object value) {
-
 
290
    setFieldValue(_Fields.findByThriftIdOrThrow(fieldID), value);
-
 
291
  }
-
 
292
 
-
 
293
  public Object getFieldValue(_Fields field) {
298
  public Object getFieldValue(_Fields field) {
294
    switch (field) {
299
    switch (field) {
295
    case ITEM_ID:
300
    case ITEM_ID:
296
      return new Long(getItem_id());
301
      return Long.valueOf(getItem_id());
297
 
302
 
298
    case WAREHOUSE_ID:
303
    case WAREHOUSE_ID:
299
      return new Long(getWarehouse_id());
304
      return Long.valueOf(getWarehouse_id());
300
 
305
 
301
    case TIMESTAMP:
306
    case TIMESTAMP:
302
      return new Long(getTimestamp());
307
      return Long.valueOf(getTimestamp());
303
 
308
 
304
    case AVAILABILITY:
309
    case AVAILABILITY:
305
      return new Long(getAvailability());
310
      return Long.valueOf(getAvailability());
306
 
311
 
307
    }
312
    }
308
    throw new IllegalStateException();
313
    throw new IllegalStateException();
309
  }
314
  }
310
 
315
 
311
  public Object getFieldValue(int fieldId) {
-
 
312
    return getFieldValue(_Fields.findByThriftIdOrThrow(fieldId));
-
 
313
  }
-
 
314
 
-
 
315
  /** Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise */
316
  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
316
  public boolean isSet(_Fields field) {
317
  public boolean isSet(_Fields field) {
-
 
318
    if (field == null) {
-
 
319
      throw new IllegalArgumentException();
-
 
320
    }
-
 
321
 
317
    switch (field) {
322
    switch (field) {
318
    case ITEM_ID:
323
    case ITEM_ID:
319
      return isSetItem_id();
324
      return isSetItem_id();
320
    case WAREHOUSE_ID:
325
    case WAREHOUSE_ID:
321
      return isSetWarehouse_id();
326
      return isSetWarehouse_id();
Line 325... Line 330...
325
      return isSetAvailability();
330
      return isSetAvailability();
326
    }
331
    }
327
    throw new IllegalStateException();
332
    throw new IllegalStateException();
328
  }
333
  }
329
 
334
 
330
  public boolean isSet(int fieldID) {
-
 
331
    return isSet(_Fields.findByThriftIdOrThrow(fieldID));
-
 
332
  }
-
 
333
 
-
 
334
  @Override
335
  @Override
335
  public boolean equals(Object that) {
336
  public boolean equals(Object that) {
336
    if (that == null)
337
    if (that == null)
337
      return false;
338
      return false;
338
    if (that instanceof ItemInventoryHistory)
339
    if (that instanceof ItemInventoryHistory)
Line 394... Line 395...
394
    }
395
    }
395
 
396
 
396
    int lastComparison = 0;
397
    int lastComparison = 0;
397
    ItemInventoryHistory typedOther = (ItemInventoryHistory)other;
398
    ItemInventoryHistory typedOther = (ItemInventoryHistory)other;
398
 
399
 
399
    lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(isSetItem_id());
400
    lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
400
    if (lastComparison != 0) {
401
    if (lastComparison != 0) {
401
      return lastComparison;
402
      return lastComparison;
402
    }
403
    }
-
 
404
    if (isSetItem_id()) {
403
    lastComparison = TBaseHelper.compareTo(item_id, typedOther.item_id);
405
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
404
    if (lastComparison != 0) {
406
      if (lastComparison != 0) {
405
      return lastComparison;
407
        return lastComparison;
-
 
408
      }
406
    }
409
    }
407
    lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(isSetWarehouse_id());
410
    lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
408
    if (lastComparison != 0) {
411
    if (lastComparison != 0) {
409
      return lastComparison;
412
      return lastComparison;
410
    }
413
    }
-
 
414
    if (isSetWarehouse_id()) {
411
    lastComparison = TBaseHelper.compareTo(warehouse_id, typedOther.warehouse_id);
415
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
412
    if (lastComparison != 0) {
416
      if (lastComparison != 0) {
413
      return lastComparison;
417
        return lastComparison;
-
 
418
      }
414
    }
419
    }
415
    lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(isSetTimestamp());
420
    lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(typedOther.isSetTimestamp());
416
    if (lastComparison != 0) {
421
    if (lastComparison != 0) {
417
      return lastComparison;
422
      return lastComparison;
418
    }
423
    }
-
 
424
    if (isSetTimestamp()) {
419
    lastComparison = TBaseHelper.compareTo(timestamp, typedOther.timestamp);
425
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.timestamp, typedOther.timestamp);
420
    if (lastComparison != 0) {
426
      if (lastComparison != 0) {
421
      return lastComparison;
427
        return lastComparison;
-
 
428
      }
422
    }
429
    }
423
    lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(isSetAvailability());
430
    lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(typedOther.isSetAvailability());
424
    if (lastComparison != 0) {
431
    if (lastComparison != 0) {
425
      return lastComparison;
432
      return lastComparison;
426
    }
433
    }
-
 
434
    if (isSetAvailability()) {
427
    lastComparison = TBaseHelper.compareTo(availability, typedOther.availability);
435
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.availability, typedOther.availability);
428
    if (lastComparison != 0) {
436
      if (lastComparison != 0) {
429
      return lastComparison;
437
        return lastComparison;
-
 
438
      }
430
    }
439
    }
431
    return 0;
440
    return 0;
432
  }
441
  }
433
 
442
 
-
 
443
  public _Fields fieldForId(int fieldId) {
-
 
444
    return _Fields.findByThriftId(fieldId);
-
 
445
  }
-
 
446
 
434
  public void read(TProtocol iprot) throws TException {
447
  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
435
    TField field;
448
    org.apache.thrift.protocol.TField field;
436
    iprot.readStructBegin();
449
    iprot.readStructBegin();
437
    while (true)
450
    while (true)
438
    {
451
    {
439
      field = iprot.readFieldBegin();
452
      field = iprot.readFieldBegin();
440
      if (field.type == TType.STOP) { 
453
      if (field.type == org.apache.thrift.protocol.TType.STOP) { 
441
        break;
454
        break;
442
      }
455
      }
443
      _Fields fieldId = _Fields.findByThriftId(field.id);
-
 
444
      if (fieldId == null) {
-
 
445
        TProtocolUtil.skip(iprot, field.type);
-
 
446
      } else {
-
 
447
        switch (fieldId) {
456
      switch (field.id) {
448
          case ITEM_ID:
457
        case 1: // ITEM_ID
449
            if (field.type == TType.I64) {
458
          if (field.type == org.apache.thrift.protocol.TType.I64) {
450
              this.item_id = iprot.readI64();
459
            this.item_id = iprot.readI64();
451
              setItem_idIsSet(true);
460
            setItem_idIsSet(true);
452
            } else { 
461
          } else { 
453
              TProtocolUtil.skip(iprot, field.type);
462
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
454
            }
463
          }
455
            break;
464
          break;
456
          case WAREHOUSE_ID:
465
        case 2: // WAREHOUSE_ID
457
            if (field.type == TType.I64) {
466
          if (field.type == org.apache.thrift.protocol.TType.I64) {
458
              this.warehouse_id = iprot.readI64();
467
            this.warehouse_id = iprot.readI64();
459
              setWarehouse_idIsSet(true);
468
            setWarehouse_idIsSet(true);
460
            } else { 
469
          } else { 
461
              TProtocolUtil.skip(iprot, field.type);
470
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
462
            }
471
          }
463
            break;
472
          break;
464
          case TIMESTAMP:
473
        case 3: // TIMESTAMP
465
            if (field.type == TType.I64) {
474
          if (field.type == org.apache.thrift.protocol.TType.I64) {
466
              this.timestamp = iprot.readI64();
475
            this.timestamp = iprot.readI64();
467
              setTimestampIsSet(true);
476
            setTimestampIsSet(true);
468
            } else { 
477
          } else { 
469
              TProtocolUtil.skip(iprot, field.type);
478
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
470
            }
479
          }
471
            break;
480
          break;
472
          case AVAILABILITY:
481
        case 4: // AVAILABILITY
473
            if (field.type == TType.I64) {
482
          if (field.type == org.apache.thrift.protocol.TType.I64) {
474
              this.availability = iprot.readI64();
483
            this.availability = iprot.readI64();
475
              setAvailabilityIsSet(true);
484
            setAvailabilityIsSet(true);
476
            } else { 
485
          } else { 
477
              TProtocolUtil.skip(iprot, field.type);
486
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
478
            }
487
          }
479
            break;
488
          break;
480
        }
489
        default:
481
        iprot.readFieldEnd();
490
          org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
482
      }
491
      }
-
 
492
      iprot.readFieldEnd();
483
    }
493
    }
484
    iprot.readStructEnd();
494
    iprot.readStructEnd();
485
    validate();
495
    validate();
486
  }
496
  }
487
 
497
 
488
  public void write(TProtocol oprot) throws TException {
498
  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
489
    validate();
499
    validate();
490
 
500
 
491
    oprot.writeStructBegin(STRUCT_DESC);
501
    oprot.writeStructBegin(STRUCT_DESC);
492
    oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
502
    oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
493
    oprot.writeI64(this.item_id);
503
    oprot.writeI64(this.item_id);
Line 527... Line 537...
527
    first = false;
537
    first = false;
528
    sb.append(")");
538
    sb.append(")");
529
    return sb.toString();
539
    return sb.toString();
530
  }
540
  }
531
 
541
 
532
  public void validate() throws TException {
542
  public void validate() throws org.apache.thrift.TException {
533
    // check for required fields
543
    // check for required fields
534
  }
544
  }
535
 
545
 
-
 
546
  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
-
 
547
    try {
-
 
548
      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
-
 
549
    } catch (org.apache.thrift.TException te) {
-
 
550
      throw new java.io.IOException(te);
-
 
551
    }
-
 
552
  }
-
 
553
 
-
 
554
  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
-
 
555
    try {
-
 
556
      // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
-
 
557
      __isset_bit_vector = new BitSet(1);
-
 
558
      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
-
 
559
    } catch (org.apache.thrift.TException te) {
-
 
560
      throw new java.io.IOException(te);
-
 
561
    }
-
 
562
  }
-
 
563
 
536
}
564
}
537
 
565