Subversion Repositories SmartDukaan

Rev

Rev 12620 | Rev 23400 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
5372 mandeep.dh 1
/**
2
 * Autogenerated by Thrift Compiler (0.7.0)
3
 *
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
 */
6
package in.shop2020.warehouse;
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.nio.ByteBuffer;
19
import java.util.Arrays;
20
import org.slf4j.Logger;
21
import org.slf4j.LoggerFactory;
22
 
23
public class DetailedPurchaseScan implements org.apache.thrift.TBase<DetailedPurchaseScan, DetailedPurchaseScan._Fields>, java.io.Serializable, Cloneable {
24
  private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("DetailedPurchaseScan");
25
 
26
  private static final org.apache.thrift.protocol.TField PURCHASE_ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("purchaseOrderId", org.apache.thrift.protocol.TType.I64, (short)1);
27
  private static final org.apache.thrift.protocol.TField PO_CREATED_AT_FIELD_DESC = new org.apache.thrift.protocol.TField("poCreatedAt", org.apache.thrift.protocol.TType.I64, (short)2);
28
  private static final org.apache.thrift.protocol.TField SUPPLIER_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("supplierName", org.apache.thrift.protocol.TType.STRING, (short)3);
29
  private static final org.apache.thrift.protocol.TField INVOICE_NUMBERS_FIELD_DESC = new org.apache.thrift.protocol.TField("invoiceNumbers", org.apache.thrift.protocol.TType.STRING, (short)4);
6494 amar.kumar 30
  private static final org.apache.thrift.protocol.TField RECEIVED_BY_FIELD_DESC = new org.apache.thrift.protocol.TField("receivedBy", org.apache.thrift.protocol.TType.STRING, (short)5);
31
  private static final org.apache.thrift.protocol.TField ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("itemId", org.apache.thrift.protocol.TType.I64, (short)6);
32
  private static final org.apache.thrift.protocol.TField BRAND_FIELD_DESC = new org.apache.thrift.protocol.TField("brand", org.apache.thrift.protocol.TType.STRING, (short)7);
33
  private static final org.apache.thrift.protocol.TField MODEL_NAME_FIELD_DESC = new org.apache.thrift.protocol.TField("modelName", org.apache.thrift.protocol.TType.STRING, (short)8);
34
  private static final org.apache.thrift.protocol.TField MODEL_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("modelNumber", org.apache.thrift.protocol.TType.STRING, (short)9);
35
  private static final org.apache.thrift.protocol.TField COLOR_FIELD_DESC = new org.apache.thrift.protocol.TField("color", org.apache.thrift.protocol.TType.STRING, (short)10);
36
  private static final org.apache.thrift.protocol.TField UNIT_PRICE_FIELD_DESC = new org.apache.thrift.protocol.TField("unitPrice", org.apache.thrift.protocol.TType.DOUBLE, (short)11);
37
  private static final org.apache.thrift.protocol.TField QUANTITY_FIELD_DESC = new org.apache.thrift.protocol.TField("quantity", org.apache.thrift.protocol.TType.I64, (short)12);
38
  private static final org.apache.thrift.protocol.TField PURCHASE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("purchaseId", org.apache.thrift.protocol.TType.I64, (short)13);
39
  private static final org.apache.thrift.protocol.TField PURCHASED_AT_FIELD_DESC = new org.apache.thrift.protocol.TField("purchasedAt", org.apache.thrift.protocol.TType.I64, (short)14);
7672 rajveer 40
  private static final org.apache.thrift.protocol.TField NLC_FIELD_DESC = new org.apache.thrift.protocol.TField("nlc", org.apache.thrift.protocol.TType.DOUBLE, (short)15);
8580 amar.kumar 41
  private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouseId", org.apache.thrift.protocol.TType.I64, (short)16);
9433 amar.kumar 42
  private static final org.apache.thrift.protocol.TField TAX_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("taxType", org.apache.thrift.protocol.TType.I64, (short)17);
11219 manish.sha 43
  private static final org.apache.thrift.protocol.TField INVOICE_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("invoiceDate", org.apache.thrift.protocol.TType.I64, (short)18);
12620 amit.gupta 44
  private static final org.apache.thrift.protocol.TField MRP_FIELD_DESC = new org.apache.thrift.protocol.TField("mrp", org.apache.thrift.protocol.TType.DOUBLE, (short)19);
12800 manish.sha 45
  private static final org.apache.thrift.protocol.TField PURCHASE_COMMENTS_FIELD_DESC = new org.apache.thrift.protocol.TField("purchaseComments", org.apache.thrift.protocol.TType.STRING, (short)20);
5372 mandeep.dh 46
 
47
  private long purchaseOrderId; // required
48
  private long poCreatedAt; // required
49
  private String supplierName; // required
50
  private String invoiceNumbers; // required
6494 amar.kumar 51
  private String receivedBy; // required
5372 mandeep.dh 52
  private long itemId; // required
5545 mandeep.dh 53
  private String brand; // required
54
  private String modelName; // required
55
  private String modelNumber; // required
56
  private String color; // required
5372 mandeep.dh 57
  private double unitPrice; // required
58
  private long quantity; // required
6361 rajveer 59
  private long purchaseId; // required
60
  private long purchasedAt; // required
7672 rajveer 61
  private double nlc; // required
8580 amar.kumar 62
  private long warehouseId; // required
9433 amar.kumar 63
  private long taxType; // required
11219 manish.sha 64
  private long invoiceDate; // required
12620 amit.gupta 65
  private double mrp; // required
12800 manish.sha 66
  private String purchaseComments; // required
5372 mandeep.dh 67
 
68
  /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
69
  public enum _Fields implements org.apache.thrift.TFieldIdEnum {
70
    PURCHASE_ORDER_ID((short)1, "purchaseOrderId"),
71
    PO_CREATED_AT((short)2, "poCreatedAt"),
72
    SUPPLIER_NAME((short)3, "supplierName"),
73
    INVOICE_NUMBERS((short)4, "invoiceNumbers"),
6494 amar.kumar 74
    RECEIVED_BY((short)5, "receivedBy"),
75
    ITEM_ID((short)6, "itemId"),
76
    BRAND((short)7, "brand"),
77
    MODEL_NAME((short)8, "modelName"),
78
    MODEL_NUMBER((short)9, "modelNumber"),
79
    COLOR((short)10, "color"),
80
    UNIT_PRICE((short)11, "unitPrice"),
81
    QUANTITY((short)12, "quantity"),
82
    PURCHASE_ID((short)13, "purchaseId"),
7672 rajveer 83
    PURCHASED_AT((short)14, "purchasedAt"),
8580 amar.kumar 84
    NLC((short)15, "nlc"),
9433 amar.kumar 85
    WAREHOUSE_ID((short)16, "warehouseId"),
11219 manish.sha 86
    TAX_TYPE((short)17, "taxType"),
12620 amit.gupta 87
    INVOICE_DATE((short)18, "invoiceDate"),
12800 manish.sha 88
    MRP((short)19, "mrp"),
89
    PURCHASE_COMMENTS((short)20, "purchaseComments");
5372 mandeep.dh 90
 
91
    private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
92
 
93
    static {
94
      for (_Fields field : EnumSet.allOf(_Fields.class)) {
95
        byName.put(field.getFieldName(), field);
96
      }
97
    }
98
 
99
    /**
100
     * Find the _Fields constant that matches fieldId, or null if its not found.
101
     */
102
    public static _Fields findByThriftId(int fieldId) {
103
      switch(fieldId) {
104
        case 1: // PURCHASE_ORDER_ID
105
          return PURCHASE_ORDER_ID;
106
        case 2: // PO_CREATED_AT
107
          return PO_CREATED_AT;
108
        case 3: // SUPPLIER_NAME
109
          return SUPPLIER_NAME;
110
        case 4: // INVOICE_NUMBERS
111
          return INVOICE_NUMBERS;
6494 amar.kumar 112
        case 5: // RECEIVED_BY
113
          return RECEIVED_BY;
114
        case 6: // ITEM_ID
5372 mandeep.dh 115
          return ITEM_ID;
6494 amar.kumar 116
        case 7: // BRAND
5545 mandeep.dh 117
          return BRAND;
6494 amar.kumar 118
        case 8: // MODEL_NAME
5545 mandeep.dh 119
          return MODEL_NAME;
6494 amar.kumar 120
        case 9: // MODEL_NUMBER
5545 mandeep.dh 121
          return MODEL_NUMBER;
6494 amar.kumar 122
        case 10: // COLOR
5545 mandeep.dh 123
          return COLOR;
6494 amar.kumar 124
        case 11: // UNIT_PRICE
5372 mandeep.dh 125
          return UNIT_PRICE;
6494 amar.kumar 126
        case 12: // QUANTITY
5372 mandeep.dh 127
          return QUANTITY;
6494 amar.kumar 128
        case 13: // PURCHASE_ID
6361 rajveer 129
          return PURCHASE_ID;
6494 amar.kumar 130
        case 14: // PURCHASED_AT
6361 rajveer 131
          return PURCHASED_AT;
7672 rajveer 132
        case 15: // NLC
133
          return NLC;
8580 amar.kumar 134
        case 16: // WAREHOUSE_ID
135
          return WAREHOUSE_ID;
9433 amar.kumar 136
        case 17: // TAX_TYPE
137
          return TAX_TYPE;
11219 manish.sha 138
        case 18: // INVOICE_DATE
139
          return INVOICE_DATE;
12620 amit.gupta 140
        case 19: // MRP
141
          return MRP;
12800 manish.sha 142
        case 20: // PURCHASE_COMMENTS
143
          return PURCHASE_COMMENTS;
5372 mandeep.dh 144
        default:
145
          return null;
146
      }
147
    }
148
 
149
    /**
150
     * Find the _Fields constant that matches fieldId, throwing an exception
151
     * if it is not found.
152
     */
153
    public static _Fields findByThriftIdOrThrow(int fieldId) {
154
      _Fields fields = findByThriftId(fieldId);
155
      if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
156
      return fields;
157
    }
158
 
159
    /**
160
     * Find the _Fields constant that matches name, or null if its not found.
161
     */
162
    public static _Fields findByName(String name) {
163
      return byName.get(name);
164
    }
165
 
166
    private final short _thriftId;
167
    private final String _fieldName;
168
 
169
    _Fields(short thriftId, String fieldName) {
170
      _thriftId = thriftId;
171
      _fieldName = fieldName;
172
    }
173
 
174
    public short getThriftFieldId() {
175
      return _thriftId;
176
    }
177
 
178
    public String getFieldName() {
179
      return _fieldName;
180
    }
181
  }
182
 
183
  // isset id assignments
184
  private static final int __PURCHASEORDERID_ISSET_ID = 0;
185
  private static final int __POCREATEDAT_ISSET_ID = 1;
186
  private static final int __ITEMID_ISSET_ID = 2;
187
  private static final int __UNITPRICE_ISSET_ID = 3;
188
  private static final int __QUANTITY_ISSET_ID = 4;
6361 rajveer 189
  private static final int __PURCHASEID_ISSET_ID = 5;
190
  private static final int __PURCHASEDAT_ISSET_ID = 6;
7672 rajveer 191
  private static final int __NLC_ISSET_ID = 7;
8580 amar.kumar 192
  private static final int __WAREHOUSEID_ISSET_ID = 8;
9433 amar.kumar 193
  private static final int __TAXTYPE_ISSET_ID = 9;
11219 manish.sha 194
  private static final int __INVOICEDATE_ISSET_ID = 10;
12620 amit.gupta 195
  private static final int __MRP_ISSET_ID = 11;
196
  private BitSet __isset_bit_vector = new BitSet(12);
5372 mandeep.dh 197
 
198
  public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
199
  static {
200
    Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
201
    tmpMap.put(_Fields.PURCHASE_ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("purchaseOrderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
202
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
203
    tmpMap.put(_Fields.PO_CREATED_AT, new org.apache.thrift.meta_data.FieldMetaData("poCreatedAt", org.apache.thrift.TFieldRequirementType.DEFAULT, 
204
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
205
    tmpMap.put(_Fields.SUPPLIER_NAME, new org.apache.thrift.meta_data.FieldMetaData("supplierName", org.apache.thrift.TFieldRequirementType.DEFAULT, 
206
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
207
    tmpMap.put(_Fields.INVOICE_NUMBERS, new org.apache.thrift.meta_data.FieldMetaData("invoiceNumbers", org.apache.thrift.TFieldRequirementType.DEFAULT, 
208
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
6494 amar.kumar 209
    tmpMap.put(_Fields.RECEIVED_BY, new org.apache.thrift.meta_data.FieldMetaData("receivedBy", org.apache.thrift.TFieldRequirementType.DEFAULT, 
210
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
5372 mandeep.dh 211
    tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
212
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5545 mandeep.dh 213
    tmpMap.put(_Fields.BRAND, new org.apache.thrift.meta_data.FieldMetaData("brand", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5372 mandeep.dh 214
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
5545 mandeep.dh 215
    tmpMap.put(_Fields.MODEL_NAME, new org.apache.thrift.meta_data.FieldMetaData("modelName", org.apache.thrift.TFieldRequirementType.DEFAULT, 
216
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
217
    tmpMap.put(_Fields.MODEL_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("modelNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
218
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
219
    tmpMap.put(_Fields.COLOR, new org.apache.thrift.meta_data.FieldMetaData("color", org.apache.thrift.TFieldRequirementType.DEFAULT, 
220
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
5372 mandeep.dh 221
    tmpMap.put(_Fields.UNIT_PRICE, new org.apache.thrift.meta_data.FieldMetaData("unitPrice", org.apache.thrift.TFieldRequirementType.DEFAULT, 
222
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
223
    tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
224
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6361 rajveer 225
    tmpMap.put(_Fields.PURCHASE_ID, new org.apache.thrift.meta_data.FieldMetaData("purchaseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
226
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
227
    tmpMap.put(_Fields.PURCHASED_AT, new org.apache.thrift.meta_data.FieldMetaData("purchasedAt", org.apache.thrift.TFieldRequirementType.DEFAULT, 
228
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7672 rajveer 229
    tmpMap.put(_Fields.NLC, new org.apache.thrift.meta_data.FieldMetaData("nlc", org.apache.thrift.TFieldRequirementType.DEFAULT, 
230
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
8580 amar.kumar 231
    tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
232
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
9433 amar.kumar 233
    tmpMap.put(_Fields.TAX_TYPE, new org.apache.thrift.meta_data.FieldMetaData("taxType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
234
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11219 manish.sha 235
    tmpMap.put(_Fields.INVOICE_DATE, new org.apache.thrift.meta_data.FieldMetaData("invoiceDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
236
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12620 amit.gupta 237
    tmpMap.put(_Fields.MRP, new org.apache.thrift.meta_data.FieldMetaData("mrp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
238
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
12800 manish.sha 239
    tmpMap.put(_Fields.PURCHASE_COMMENTS, new org.apache.thrift.meta_data.FieldMetaData("purchaseComments", org.apache.thrift.TFieldRequirementType.DEFAULT, 
240
        new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
5372 mandeep.dh 241
    metaDataMap = Collections.unmodifiableMap(tmpMap);
242
    org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(DetailedPurchaseScan.class, metaDataMap);
243
  }
244
 
245
  public DetailedPurchaseScan() {
246
  }
247
 
248
  public DetailedPurchaseScan(
249
    long purchaseOrderId,
250
    long poCreatedAt,
251
    String supplierName,
252
    String invoiceNumbers,
6494 amar.kumar 253
    String receivedBy,
5372 mandeep.dh 254
    long itemId,
5545 mandeep.dh 255
    String brand,
256
    String modelName,
257
    String modelNumber,
258
    String color,
5372 mandeep.dh 259
    double unitPrice,
6361 rajveer 260
    long quantity,
261
    long purchaseId,
7672 rajveer 262
    long purchasedAt,
8580 amar.kumar 263
    double nlc,
9433 amar.kumar 264
    long warehouseId,
11219 manish.sha 265
    long taxType,
12620 amit.gupta 266
    long invoiceDate,
12800 manish.sha 267
    double mrp,
268
    String purchaseComments)
5372 mandeep.dh 269
  {
270
    this();
271
    this.purchaseOrderId = purchaseOrderId;
272
    setPurchaseOrderIdIsSet(true);
273
    this.poCreatedAt = poCreatedAt;
274
    setPoCreatedAtIsSet(true);
275
    this.supplierName = supplierName;
276
    this.invoiceNumbers = invoiceNumbers;
6494 amar.kumar 277
    this.receivedBy = receivedBy;
5372 mandeep.dh 278
    this.itemId = itemId;
279
    setItemIdIsSet(true);
5545 mandeep.dh 280
    this.brand = brand;
281
    this.modelName = modelName;
282
    this.modelNumber = modelNumber;
283
    this.color = color;
5372 mandeep.dh 284
    this.unitPrice = unitPrice;
285
    setUnitPriceIsSet(true);
286
    this.quantity = quantity;
287
    setQuantityIsSet(true);
6361 rajveer 288
    this.purchaseId = purchaseId;
289
    setPurchaseIdIsSet(true);
290
    this.purchasedAt = purchasedAt;
291
    setPurchasedAtIsSet(true);
7672 rajveer 292
    this.nlc = nlc;
293
    setNlcIsSet(true);
8580 amar.kumar 294
    this.warehouseId = warehouseId;
295
    setWarehouseIdIsSet(true);
9433 amar.kumar 296
    this.taxType = taxType;
297
    setTaxTypeIsSet(true);
11219 manish.sha 298
    this.invoiceDate = invoiceDate;
299
    setInvoiceDateIsSet(true);
12620 amit.gupta 300
    this.mrp = mrp;
301
    setMrpIsSet(true);
12800 manish.sha 302
    this.purchaseComments = purchaseComments;
5372 mandeep.dh 303
  }
304
 
305
  /**
306
   * Performs a deep copy on <i>other</i>.
307
   */
308
  public DetailedPurchaseScan(DetailedPurchaseScan other) {
309
    __isset_bit_vector.clear();
310
    __isset_bit_vector.or(other.__isset_bit_vector);
311
    this.purchaseOrderId = other.purchaseOrderId;
312
    this.poCreatedAt = other.poCreatedAt;
313
    if (other.isSetSupplierName()) {
314
      this.supplierName = other.supplierName;
315
    }
316
    if (other.isSetInvoiceNumbers()) {
317
      this.invoiceNumbers = other.invoiceNumbers;
318
    }
6494 amar.kumar 319
    if (other.isSetReceivedBy()) {
320
      this.receivedBy = other.receivedBy;
321
    }
5372 mandeep.dh 322
    this.itemId = other.itemId;
5545 mandeep.dh 323
    if (other.isSetBrand()) {
324
      this.brand = other.brand;
5372 mandeep.dh 325
    }
5545 mandeep.dh 326
    if (other.isSetModelName()) {
327
      this.modelName = other.modelName;
328
    }
329
    if (other.isSetModelNumber()) {
330
      this.modelNumber = other.modelNumber;
331
    }
332
    if (other.isSetColor()) {
333
      this.color = other.color;
334
    }
5372 mandeep.dh 335
    this.unitPrice = other.unitPrice;
336
    this.quantity = other.quantity;
6361 rajveer 337
    this.purchaseId = other.purchaseId;
338
    this.purchasedAt = other.purchasedAt;
7672 rajveer 339
    this.nlc = other.nlc;
8580 amar.kumar 340
    this.warehouseId = other.warehouseId;
9433 amar.kumar 341
    this.taxType = other.taxType;
11219 manish.sha 342
    this.invoiceDate = other.invoiceDate;
12620 amit.gupta 343
    this.mrp = other.mrp;
12800 manish.sha 344
    if (other.isSetPurchaseComments()) {
345
      this.purchaseComments = other.purchaseComments;
346
    }
5372 mandeep.dh 347
  }
348
 
349
  public DetailedPurchaseScan deepCopy() {
350
    return new DetailedPurchaseScan(this);
351
  }
352
 
353
  @Override
354
  public void clear() {
355
    setPurchaseOrderIdIsSet(false);
356
    this.purchaseOrderId = 0;
357
    setPoCreatedAtIsSet(false);
358
    this.poCreatedAt = 0;
359
    this.supplierName = null;
360
    this.invoiceNumbers = null;
6494 amar.kumar 361
    this.receivedBy = null;
5372 mandeep.dh 362
    setItemIdIsSet(false);
363
    this.itemId = 0;
5545 mandeep.dh 364
    this.brand = null;
365
    this.modelName = null;
366
    this.modelNumber = null;
367
    this.color = null;
5372 mandeep.dh 368
    setUnitPriceIsSet(false);
369
    this.unitPrice = 0.0;
370
    setQuantityIsSet(false);
371
    this.quantity = 0;
6361 rajveer 372
    setPurchaseIdIsSet(false);
373
    this.purchaseId = 0;
374
    setPurchasedAtIsSet(false);
375
    this.purchasedAt = 0;
7672 rajveer 376
    setNlcIsSet(false);
377
    this.nlc = 0.0;
8580 amar.kumar 378
    setWarehouseIdIsSet(false);
379
    this.warehouseId = 0;
9433 amar.kumar 380
    setTaxTypeIsSet(false);
381
    this.taxType = 0;
11219 manish.sha 382
    setInvoiceDateIsSet(false);
383
    this.invoiceDate = 0;
12620 amit.gupta 384
    setMrpIsSet(false);
385
    this.mrp = 0.0;
12800 manish.sha 386
    this.purchaseComments = null;
5372 mandeep.dh 387
  }
388
 
389
  public long getPurchaseOrderId() {
390
    return this.purchaseOrderId;
391
  }
392
 
393
  public void setPurchaseOrderId(long purchaseOrderId) {
394
    this.purchaseOrderId = purchaseOrderId;
395
    setPurchaseOrderIdIsSet(true);
396
  }
397
 
398
  public void unsetPurchaseOrderId() {
399
    __isset_bit_vector.clear(__PURCHASEORDERID_ISSET_ID);
400
  }
401
 
402
  /** Returns true if field purchaseOrderId is set (has been assigned a value) and false otherwise */
403
  public boolean isSetPurchaseOrderId() {
404
    return __isset_bit_vector.get(__PURCHASEORDERID_ISSET_ID);
405
  }
406
 
407
  public void setPurchaseOrderIdIsSet(boolean value) {
408
    __isset_bit_vector.set(__PURCHASEORDERID_ISSET_ID, value);
409
  }
410
 
411
  public long getPoCreatedAt() {
412
    return this.poCreatedAt;
413
  }
414
 
415
  public void setPoCreatedAt(long poCreatedAt) {
416
    this.poCreatedAt = poCreatedAt;
417
    setPoCreatedAtIsSet(true);
418
  }
419
 
420
  public void unsetPoCreatedAt() {
421
    __isset_bit_vector.clear(__POCREATEDAT_ISSET_ID);
422
  }
423
 
424
  /** Returns true if field poCreatedAt is set (has been assigned a value) and false otherwise */
425
  public boolean isSetPoCreatedAt() {
426
    return __isset_bit_vector.get(__POCREATEDAT_ISSET_ID);
427
  }
428
 
429
  public void setPoCreatedAtIsSet(boolean value) {
430
    __isset_bit_vector.set(__POCREATEDAT_ISSET_ID, value);
431
  }
432
 
433
  public String getSupplierName() {
434
    return this.supplierName;
435
  }
436
 
437
  public void setSupplierName(String supplierName) {
438
    this.supplierName = supplierName;
439
  }
440
 
441
  public void unsetSupplierName() {
442
    this.supplierName = null;
443
  }
444
 
445
  /** Returns true if field supplierName is set (has been assigned a value) and false otherwise */
446
  public boolean isSetSupplierName() {
447
    return this.supplierName != null;
448
  }
449
 
450
  public void setSupplierNameIsSet(boolean value) {
451
    if (!value) {
452
      this.supplierName = null;
453
    }
454
  }
455
 
456
  public String getInvoiceNumbers() {
457
    return this.invoiceNumbers;
458
  }
459
 
460
  public void setInvoiceNumbers(String invoiceNumbers) {
461
    this.invoiceNumbers = invoiceNumbers;
462
  }
463
 
464
  public void unsetInvoiceNumbers() {
465
    this.invoiceNumbers = null;
466
  }
467
 
468
  /** Returns true if field invoiceNumbers is set (has been assigned a value) and false otherwise */
469
  public boolean isSetInvoiceNumbers() {
470
    return this.invoiceNumbers != null;
471
  }
472
 
473
  public void setInvoiceNumbersIsSet(boolean value) {
474
    if (!value) {
475
      this.invoiceNumbers = null;
476
    }
477
  }
478
 
6494 amar.kumar 479
  public String getReceivedBy() {
480
    return this.receivedBy;
481
  }
482
 
483
  public void setReceivedBy(String receivedBy) {
484
    this.receivedBy = receivedBy;
485
  }
486
 
487
  public void unsetReceivedBy() {
488
    this.receivedBy = null;
489
  }
490
 
491
  /** Returns true if field receivedBy is set (has been assigned a value) and false otherwise */
492
  public boolean isSetReceivedBy() {
493
    return this.receivedBy != null;
494
  }
495
 
496
  public void setReceivedByIsSet(boolean value) {
497
    if (!value) {
498
      this.receivedBy = null;
499
    }
500
  }
501
 
5372 mandeep.dh 502
  public long getItemId() {
503
    return this.itemId;
504
  }
505
 
506
  public void setItemId(long itemId) {
507
    this.itemId = itemId;
508
    setItemIdIsSet(true);
509
  }
510
 
511
  public void unsetItemId() {
512
    __isset_bit_vector.clear(__ITEMID_ISSET_ID);
513
  }
514
 
515
  /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
516
  public boolean isSetItemId() {
517
    return __isset_bit_vector.get(__ITEMID_ISSET_ID);
518
  }
519
 
520
  public void setItemIdIsSet(boolean value) {
521
    __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
522
  }
523
 
5545 mandeep.dh 524
  public String getBrand() {
525
    return this.brand;
5372 mandeep.dh 526
  }
527
 
5545 mandeep.dh 528
  public void setBrand(String brand) {
529
    this.brand = brand;
5372 mandeep.dh 530
  }
531
 
5545 mandeep.dh 532
  public void unsetBrand() {
533
    this.brand = null;
5372 mandeep.dh 534
  }
535
 
5545 mandeep.dh 536
  /** Returns true if field brand is set (has been assigned a value) and false otherwise */
537
  public boolean isSetBrand() {
538
    return this.brand != null;
5372 mandeep.dh 539
  }
540
 
5545 mandeep.dh 541
  public void setBrandIsSet(boolean value) {
5372 mandeep.dh 542
    if (!value) {
5545 mandeep.dh 543
      this.brand = null;
5372 mandeep.dh 544
    }
545
  }
546
 
5545 mandeep.dh 547
  public String getModelName() {
548
    return this.modelName;
549
  }
550
 
551
  public void setModelName(String modelName) {
552
    this.modelName = modelName;
553
  }
554
 
555
  public void unsetModelName() {
556
    this.modelName = null;
557
  }
558
 
559
  /** Returns true if field modelName is set (has been assigned a value) and false otherwise */
560
  public boolean isSetModelName() {
561
    return this.modelName != null;
562
  }
563
 
564
  public void setModelNameIsSet(boolean value) {
565
    if (!value) {
566
      this.modelName = null;
567
    }
568
  }
569
 
570
  public String getModelNumber() {
571
    return this.modelNumber;
572
  }
573
 
574
  public void setModelNumber(String modelNumber) {
575
    this.modelNumber = modelNumber;
576
  }
577
 
578
  public void unsetModelNumber() {
579
    this.modelNumber = null;
580
  }
581
 
582
  /** Returns true if field modelNumber is set (has been assigned a value) and false otherwise */
583
  public boolean isSetModelNumber() {
584
    return this.modelNumber != null;
585
  }
586
 
587
  public void setModelNumberIsSet(boolean value) {
588
    if (!value) {
589
      this.modelNumber = null;
590
    }
591
  }
592
 
593
  public String getColor() {
594
    return this.color;
595
  }
596
 
597
  public void setColor(String color) {
598
    this.color = color;
599
  }
600
 
601
  public void unsetColor() {
602
    this.color = null;
603
  }
604
 
605
  /** Returns true if field color is set (has been assigned a value) and false otherwise */
606
  public boolean isSetColor() {
607
    return this.color != null;
608
  }
609
 
610
  public void setColorIsSet(boolean value) {
611
    if (!value) {
612
      this.color = null;
613
    }
614
  }
615
 
5372 mandeep.dh 616
  public double getUnitPrice() {
617
    return this.unitPrice;
618
  }
619
 
620
  public void setUnitPrice(double unitPrice) {
621
    this.unitPrice = unitPrice;
622
    setUnitPriceIsSet(true);
623
  }
624
 
625
  public void unsetUnitPrice() {
626
    __isset_bit_vector.clear(__UNITPRICE_ISSET_ID);
627
  }
628
 
629
  /** Returns true if field unitPrice is set (has been assigned a value) and false otherwise */
630
  public boolean isSetUnitPrice() {
631
    return __isset_bit_vector.get(__UNITPRICE_ISSET_ID);
632
  }
633
 
634
  public void setUnitPriceIsSet(boolean value) {
635
    __isset_bit_vector.set(__UNITPRICE_ISSET_ID, value);
636
  }
637
 
638
  public long getQuantity() {
639
    return this.quantity;
640
  }
641
 
642
  public void setQuantity(long quantity) {
643
    this.quantity = quantity;
644
    setQuantityIsSet(true);
645
  }
646
 
647
  public void unsetQuantity() {
648
    __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
649
  }
650
 
651
  /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
652
  public boolean isSetQuantity() {
653
    return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
654
  }
655
 
656
  public void setQuantityIsSet(boolean value) {
657
    __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
658
  }
659
 
6361 rajveer 660
  public long getPurchaseId() {
661
    return this.purchaseId;
662
  }
663
 
664
  public void setPurchaseId(long purchaseId) {
665
    this.purchaseId = purchaseId;
666
    setPurchaseIdIsSet(true);
667
  }
668
 
669
  public void unsetPurchaseId() {
670
    __isset_bit_vector.clear(__PURCHASEID_ISSET_ID);
671
  }
672
 
673
  /** Returns true if field purchaseId is set (has been assigned a value) and false otherwise */
674
  public boolean isSetPurchaseId() {
675
    return __isset_bit_vector.get(__PURCHASEID_ISSET_ID);
676
  }
677
 
678
  public void setPurchaseIdIsSet(boolean value) {
679
    __isset_bit_vector.set(__PURCHASEID_ISSET_ID, value);
680
  }
681
 
682
  public long getPurchasedAt() {
683
    return this.purchasedAt;
684
  }
685
 
686
  public void setPurchasedAt(long purchasedAt) {
687
    this.purchasedAt = purchasedAt;
688
    setPurchasedAtIsSet(true);
689
  }
690
 
691
  public void unsetPurchasedAt() {
692
    __isset_bit_vector.clear(__PURCHASEDAT_ISSET_ID);
693
  }
694
 
695
  /** Returns true if field purchasedAt is set (has been assigned a value) and false otherwise */
696
  public boolean isSetPurchasedAt() {
697
    return __isset_bit_vector.get(__PURCHASEDAT_ISSET_ID);
698
  }
699
 
700
  public void setPurchasedAtIsSet(boolean value) {
701
    __isset_bit_vector.set(__PURCHASEDAT_ISSET_ID, value);
702
  }
703
 
7672 rajveer 704
  public double getNlc() {
705
    return this.nlc;
706
  }
707
 
708
  public void setNlc(double nlc) {
709
    this.nlc = nlc;
710
    setNlcIsSet(true);
711
  }
712
 
713
  public void unsetNlc() {
714
    __isset_bit_vector.clear(__NLC_ISSET_ID);
715
  }
716
 
717
  /** Returns true if field nlc is set (has been assigned a value) and false otherwise */
718
  public boolean isSetNlc() {
719
    return __isset_bit_vector.get(__NLC_ISSET_ID);
720
  }
721
 
722
  public void setNlcIsSet(boolean value) {
723
    __isset_bit_vector.set(__NLC_ISSET_ID, value);
724
  }
725
 
8580 amar.kumar 726
  public long getWarehouseId() {
727
    return this.warehouseId;
728
  }
729
 
730
  public void setWarehouseId(long warehouseId) {
731
    this.warehouseId = warehouseId;
732
    setWarehouseIdIsSet(true);
733
  }
734
 
735
  public void unsetWarehouseId() {
736
    __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
737
  }
738
 
739
  /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
740
  public boolean isSetWarehouseId() {
741
    return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
742
  }
743
 
744
  public void setWarehouseIdIsSet(boolean value) {
745
    __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
746
  }
747
 
9433 amar.kumar 748
  public long getTaxType() {
749
    return this.taxType;
750
  }
751
 
752
  public void setTaxType(long taxType) {
753
    this.taxType = taxType;
754
    setTaxTypeIsSet(true);
755
  }
756
 
757
  public void unsetTaxType() {
758
    __isset_bit_vector.clear(__TAXTYPE_ISSET_ID);
759
  }
760
 
761
  /** Returns true if field taxType is set (has been assigned a value) and false otherwise */
762
  public boolean isSetTaxType() {
763
    return __isset_bit_vector.get(__TAXTYPE_ISSET_ID);
764
  }
765
 
766
  public void setTaxTypeIsSet(boolean value) {
767
    __isset_bit_vector.set(__TAXTYPE_ISSET_ID, value);
768
  }
769
 
11219 manish.sha 770
  public long getInvoiceDate() {
771
    return this.invoiceDate;
772
  }
773
 
774
  public void setInvoiceDate(long invoiceDate) {
775
    this.invoiceDate = invoiceDate;
776
    setInvoiceDateIsSet(true);
777
  }
778
 
779
  public void unsetInvoiceDate() {
780
    __isset_bit_vector.clear(__INVOICEDATE_ISSET_ID);
781
  }
782
 
783
  /** Returns true if field invoiceDate is set (has been assigned a value) and false otherwise */
784
  public boolean isSetInvoiceDate() {
785
    return __isset_bit_vector.get(__INVOICEDATE_ISSET_ID);
786
  }
787
 
788
  public void setInvoiceDateIsSet(boolean value) {
789
    __isset_bit_vector.set(__INVOICEDATE_ISSET_ID, value);
790
  }
791
 
12620 amit.gupta 792
  public double getMrp() {
793
    return this.mrp;
794
  }
795
 
796
  public void setMrp(double mrp) {
797
    this.mrp = mrp;
798
    setMrpIsSet(true);
799
  }
800
 
801
  public void unsetMrp() {
802
    __isset_bit_vector.clear(__MRP_ISSET_ID);
803
  }
804
 
805
  /** Returns true if field mrp is set (has been assigned a value) and false otherwise */
806
  public boolean isSetMrp() {
807
    return __isset_bit_vector.get(__MRP_ISSET_ID);
808
  }
809
 
810
  public void setMrpIsSet(boolean value) {
811
    __isset_bit_vector.set(__MRP_ISSET_ID, value);
812
  }
813
 
12800 manish.sha 814
  public String getPurchaseComments() {
815
    return this.purchaseComments;
816
  }
817
 
818
  public void setPurchaseComments(String purchaseComments) {
819
    this.purchaseComments = purchaseComments;
820
  }
821
 
822
  public void unsetPurchaseComments() {
823
    this.purchaseComments = null;
824
  }
825
 
826
  /** Returns true if field purchaseComments is set (has been assigned a value) and false otherwise */
827
  public boolean isSetPurchaseComments() {
828
    return this.purchaseComments != null;
829
  }
830
 
831
  public void setPurchaseCommentsIsSet(boolean value) {
832
    if (!value) {
833
      this.purchaseComments = null;
834
    }
835
  }
836
 
5372 mandeep.dh 837
  public void setFieldValue(_Fields field, Object value) {
838
    switch (field) {
839
    case PURCHASE_ORDER_ID:
840
      if (value == null) {
841
        unsetPurchaseOrderId();
842
      } else {
843
        setPurchaseOrderId((Long)value);
844
      }
845
      break;
846
 
847
    case PO_CREATED_AT:
848
      if (value == null) {
849
        unsetPoCreatedAt();
850
      } else {
851
        setPoCreatedAt((Long)value);
852
      }
853
      break;
854
 
855
    case SUPPLIER_NAME:
856
      if (value == null) {
857
        unsetSupplierName();
858
      } else {
859
        setSupplierName((String)value);
860
      }
861
      break;
862
 
863
    case INVOICE_NUMBERS:
864
      if (value == null) {
865
        unsetInvoiceNumbers();
866
      } else {
867
        setInvoiceNumbers((String)value);
868
      }
869
      break;
870
 
6494 amar.kumar 871
    case RECEIVED_BY:
872
      if (value == null) {
873
        unsetReceivedBy();
874
      } else {
875
        setReceivedBy((String)value);
876
      }
877
      break;
878
 
5372 mandeep.dh 879
    case ITEM_ID:
880
      if (value == null) {
881
        unsetItemId();
882
      } else {
883
        setItemId((Long)value);
884
      }
885
      break;
886
 
5545 mandeep.dh 887
    case BRAND:
5372 mandeep.dh 888
      if (value == null) {
5545 mandeep.dh 889
        unsetBrand();
5372 mandeep.dh 890
      } else {
5545 mandeep.dh 891
        setBrand((String)value);
5372 mandeep.dh 892
      }
893
      break;
894
 
5545 mandeep.dh 895
    case MODEL_NAME:
896
      if (value == null) {
897
        unsetModelName();
898
      } else {
899
        setModelName((String)value);
900
      }
901
      break;
902
 
903
    case MODEL_NUMBER:
904
      if (value == null) {
905
        unsetModelNumber();
906
      } else {
907
        setModelNumber((String)value);
908
      }
909
      break;
910
 
911
    case COLOR:
912
      if (value == null) {
913
        unsetColor();
914
      } else {
915
        setColor((String)value);
916
      }
917
      break;
918
 
5372 mandeep.dh 919
    case UNIT_PRICE:
920
      if (value == null) {
921
        unsetUnitPrice();
922
      } else {
923
        setUnitPrice((Double)value);
924
      }
925
      break;
926
 
927
    case QUANTITY:
928
      if (value == null) {
929
        unsetQuantity();
930
      } else {
931
        setQuantity((Long)value);
932
      }
933
      break;
934
 
6361 rajveer 935
    case PURCHASE_ID:
936
      if (value == null) {
937
        unsetPurchaseId();
938
      } else {
939
        setPurchaseId((Long)value);
940
      }
941
      break;
942
 
943
    case PURCHASED_AT:
944
      if (value == null) {
945
        unsetPurchasedAt();
946
      } else {
947
        setPurchasedAt((Long)value);
948
      }
949
      break;
950
 
7672 rajveer 951
    case NLC:
952
      if (value == null) {
953
        unsetNlc();
954
      } else {
955
        setNlc((Double)value);
956
      }
957
      break;
958
 
8580 amar.kumar 959
    case WAREHOUSE_ID:
960
      if (value == null) {
961
        unsetWarehouseId();
962
      } else {
963
        setWarehouseId((Long)value);
964
      }
965
      break;
966
 
9433 amar.kumar 967
    case TAX_TYPE:
968
      if (value == null) {
969
        unsetTaxType();
970
      } else {
971
        setTaxType((Long)value);
972
      }
973
      break;
974
 
11219 manish.sha 975
    case INVOICE_DATE:
976
      if (value == null) {
977
        unsetInvoiceDate();
978
      } else {
979
        setInvoiceDate((Long)value);
980
      }
981
      break;
982
 
12620 amit.gupta 983
    case MRP:
984
      if (value == null) {
985
        unsetMrp();
986
      } else {
987
        setMrp((Double)value);
988
      }
989
      break;
990
 
12800 manish.sha 991
    case PURCHASE_COMMENTS:
992
      if (value == null) {
993
        unsetPurchaseComments();
994
      } else {
995
        setPurchaseComments((String)value);
996
      }
997
      break;
998
 
5372 mandeep.dh 999
    }
1000
  }
1001
 
1002
  public Object getFieldValue(_Fields field) {
1003
    switch (field) {
1004
    case PURCHASE_ORDER_ID:
1005
      return Long.valueOf(getPurchaseOrderId());
1006
 
1007
    case PO_CREATED_AT:
1008
      return Long.valueOf(getPoCreatedAt());
1009
 
1010
    case SUPPLIER_NAME:
1011
      return getSupplierName();
1012
 
1013
    case INVOICE_NUMBERS:
1014
      return getInvoiceNumbers();
1015
 
6494 amar.kumar 1016
    case RECEIVED_BY:
1017
      return getReceivedBy();
1018
 
5372 mandeep.dh 1019
    case ITEM_ID:
1020
      return Long.valueOf(getItemId());
1021
 
5545 mandeep.dh 1022
    case BRAND:
1023
      return getBrand();
5372 mandeep.dh 1024
 
5545 mandeep.dh 1025
    case MODEL_NAME:
1026
      return getModelName();
1027
 
1028
    case MODEL_NUMBER:
1029
      return getModelNumber();
1030
 
1031
    case COLOR:
1032
      return getColor();
1033
 
5372 mandeep.dh 1034
    case UNIT_PRICE:
1035
      return Double.valueOf(getUnitPrice());
1036
 
1037
    case QUANTITY:
1038
      return Long.valueOf(getQuantity());
1039
 
6361 rajveer 1040
    case PURCHASE_ID:
1041
      return Long.valueOf(getPurchaseId());
1042
 
1043
    case PURCHASED_AT:
1044
      return Long.valueOf(getPurchasedAt());
1045
 
7672 rajveer 1046
    case NLC:
1047
      return Double.valueOf(getNlc());
1048
 
8580 amar.kumar 1049
    case WAREHOUSE_ID:
1050
      return Long.valueOf(getWarehouseId());
1051
 
9433 amar.kumar 1052
    case TAX_TYPE:
1053
      return Long.valueOf(getTaxType());
1054
 
11219 manish.sha 1055
    case INVOICE_DATE:
1056
      return Long.valueOf(getInvoiceDate());
1057
 
12620 amit.gupta 1058
    case MRP:
1059
      return Double.valueOf(getMrp());
1060
 
12800 manish.sha 1061
    case PURCHASE_COMMENTS:
1062
      return getPurchaseComments();
1063
 
5372 mandeep.dh 1064
    }
1065
    throw new IllegalStateException();
1066
  }
1067
 
1068
  /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
1069
  public boolean isSet(_Fields field) {
1070
    if (field == null) {
1071
      throw new IllegalArgumentException();
1072
    }
1073
 
1074
    switch (field) {
1075
    case PURCHASE_ORDER_ID:
1076
      return isSetPurchaseOrderId();
1077
    case PO_CREATED_AT:
1078
      return isSetPoCreatedAt();
1079
    case SUPPLIER_NAME:
1080
      return isSetSupplierName();
1081
    case INVOICE_NUMBERS:
1082
      return isSetInvoiceNumbers();
6494 amar.kumar 1083
    case RECEIVED_BY:
1084
      return isSetReceivedBy();
5372 mandeep.dh 1085
    case ITEM_ID:
1086
      return isSetItemId();
5545 mandeep.dh 1087
    case BRAND:
1088
      return isSetBrand();
1089
    case MODEL_NAME:
1090
      return isSetModelName();
1091
    case MODEL_NUMBER:
1092
      return isSetModelNumber();
1093
    case COLOR:
1094
      return isSetColor();
5372 mandeep.dh 1095
    case UNIT_PRICE:
1096
      return isSetUnitPrice();
1097
    case QUANTITY:
1098
      return isSetQuantity();
6361 rajveer 1099
    case PURCHASE_ID:
1100
      return isSetPurchaseId();
1101
    case PURCHASED_AT:
1102
      return isSetPurchasedAt();
7672 rajveer 1103
    case NLC:
1104
      return isSetNlc();
8580 amar.kumar 1105
    case WAREHOUSE_ID:
1106
      return isSetWarehouseId();
9433 amar.kumar 1107
    case TAX_TYPE:
1108
      return isSetTaxType();
11219 manish.sha 1109
    case INVOICE_DATE:
1110
      return isSetInvoiceDate();
12620 amit.gupta 1111
    case MRP:
1112
      return isSetMrp();
12800 manish.sha 1113
    case PURCHASE_COMMENTS:
1114
      return isSetPurchaseComments();
5372 mandeep.dh 1115
    }
1116
    throw new IllegalStateException();
1117
  }
1118
 
1119
  @Override
1120
  public boolean equals(Object that) {
1121
    if (that == null)
1122
      return false;
1123
    if (that instanceof DetailedPurchaseScan)
1124
      return this.equals((DetailedPurchaseScan)that);
1125
    return false;
1126
  }
1127
 
1128
  public boolean equals(DetailedPurchaseScan that) {
1129
    if (that == null)
1130
      return false;
1131
 
1132
    boolean this_present_purchaseOrderId = true;
1133
    boolean that_present_purchaseOrderId = true;
1134
    if (this_present_purchaseOrderId || that_present_purchaseOrderId) {
1135
      if (!(this_present_purchaseOrderId && that_present_purchaseOrderId))
1136
        return false;
1137
      if (this.purchaseOrderId != that.purchaseOrderId)
1138
        return false;
1139
    }
1140
 
1141
    boolean this_present_poCreatedAt = true;
1142
    boolean that_present_poCreatedAt = true;
1143
    if (this_present_poCreatedAt || that_present_poCreatedAt) {
1144
      if (!(this_present_poCreatedAt && that_present_poCreatedAt))
1145
        return false;
1146
      if (this.poCreatedAt != that.poCreatedAt)
1147
        return false;
1148
    }
1149
 
1150
    boolean this_present_supplierName = true && this.isSetSupplierName();
1151
    boolean that_present_supplierName = true && that.isSetSupplierName();
1152
    if (this_present_supplierName || that_present_supplierName) {
1153
      if (!(this_present_supplierName && that_present_supplierName))
1154
        return false;
1155
      if (!this.supplierName.equals(that.supplierName))
1156
        return false;
1157
    }
1158
 
1159
    boolean this_present_invoiceNumbers = true && this.isSetInvoiceNumbers();
1160
    boolean that_present_invoiceNumbers = true && that.isSetInvoiceNumbers();
1161
    if (this_present_invoiceNumbers || that_present_invoiceNumbers) {
1162
      if (!(this_present_invoiceNumbers && that_present_invoiceNumbers))
1163
        return false;
1164
      if (!this.invoiceNumbers.equals(that.invoiceNumbers))
1165
        return false;
1166
    }
1167
 
6494 amar.kumar 1168
    boolean this_present_receivedBy = true && this.isSetReceivedBy();
1169
    boolean that_present_receivedBy = true && that.isSetReceivedBy();
1170
    if (this_present_receivedBy || that_present_receivedBy) {
1171
      if (!(this_present_receivedBy && that_present_receivedBy))
1172
        return false;
1173
      if (!this.receivedBy.equals(that.receivedBy))
1174
        return false;
1175
    }
1176
 
5372 mandeep.dh 1177
    boolean this_present_itemId = true;
1178
    boolean that_present_itemId = true;
1179
    if (this_present_itemId || that_present_itemId) {
1180
      if (!(this_present_itemId && that_present_itemId))
1181
        return false;
1182
      if (this.itemId != that.itemId)
1183
        return false;
1184
    }
1185
 
5545 mandeep.dh 1186
    boolean this_present_brand = true && this.isSetBrand();
1187
    boolean that_present_brand = true && that.isSetBrand();
1188
    if (this_present_brand || that_present_brand) {
1189
      if (!(this_present_brand && that_present_brand))
5372 mandeep.dh 1190
        return false;
5545 mandeep.dh 1191
      if (!this.brand.equals(that.brand))
5372 mandeep.dh 1192
        return false;
1193
    }
1194
 
5545 mandeep.dh 1195
    boolean this_present_modelName = true && this.isSetModelName();
1196
    boolean that_present_modelName = true && that.isSetModelName();
1197
    if (this_present_modelName || that_present_modelName) {
1198
      if (!(this_present_modelName && that_present_modelName))
1199
        return false;
1200
      if (!this.modelName.equals(that.modelName))
1201
        return false;
1202
    }
1203
 
1204
    boolean this_present_modelNumber = true && this.isSetModelNumber();
1205
    boolean that_present_modelNumber = true && that.isSetModelNumber();
1206
    if (this_present_modelNumber || that_present_modelNumber) {
1207
      if (!(this_present_modelNumber && that_present_modelNumber))
1208
        return false;
1209
      if (!this.modelNumber.equals(that.modelNumber))
1210
        return false;
1211
    }
1212
 
1213
    boolean this_present_color = true && this.isSetColor();
1214
    boolean that_present_color = true && that.isSetColor();
1215
    if (this_present_color || that_present_color) {
1216
      if (!(this_present_color && that_present_color))
1217
        return false;
1218
      if (!this.color.equals(that.color))
1219
        return false;
1220
    }
1221
 
5372 mandeep.dh 1222
    boolean this_present_unitPrice = true;
1223
    boolean that_present_unitPrice = true;
1224
    if (this_present_unitPrice || that_present_unitPrice) {
1225
      if (!(this_present_unitPrice && that_present_unitPrice))
1226
        return false;
1227
      if (this.unitPrice != that.unitPrice)
1228
        return false;
1229
    }
1230
 
1231
    boolean this_present_quantity = true;
1232
    boolean that_present_quantity = true;
1233
    if (this_present_quantity || that_present_quantity) {
1234
      if (!(this_present_quantity && that_present_quantity))
1235
        return false;
1236
      if (this.quantity != that.quantity)
1237
        return false;
1238
    }
1239
 
6361 rajveer 1240
    boolean this_present_purchaseId = true;
1241
    boolean that_present_purchaseId = true;
1242
    if (this_present_purchaseId || that_present_purchaseId) {
1243
      if (!(this_present_purchaseId && that_present_purchaseId))
1244
        return false;
1245
      if (this.purchaseId != that.purchaseId)
1246
        return false;
1247
    }
1248
 
1249
    boolean this_present_purchasedAt = true;
1250
    boolean that_present_purchasedAt = true;
1251
    if (this_present_purchasedAt || that_present_purchasedAt) {
1252
      if (!(this_present_purchasedAt && that_present_purchasedAt))
1253
        return false;
1254
      if (this.purchasedAt != that.purchasedAt)
1255
        return false;
1256
    }
1257
 
7672 rajveer 1258
    boolean this_present_nlc = true;
1259
    boolean that_present_nlc = true;
1260
    if (this_present_nlc || that_present_nlc) {
1261
      if (!(this_present_nlc && that_present_nlc))
1262
        return false;
1263
      if (this.nlc != that.nlc)
1264
        return false;
1265
    }
1266
 
8580 amar.kumar 1267
    boolean this_present_warehouseId = true;
1268
    boolean that_present_warehouseId = true;
1269
    if (this_present_warehouseId || that_present_warehouseId) {
1270
      if (!(this_present_warehouseId && that_present_warehouseId))
1271
        return false;
1272
      if (this.warehouseId != that.warehouseId)
1273
        return false;
1274
    }
1275
 
9433 amar.kumar 1276
    boolean this_present_taxType = true;
1277
    boolean that_present_taxType = true;
1278
    if (this_present_taxType || that_present_taxType) {
1279
      if (!(this_present_taxType && that_present_taxType))
1280
        return false;
1281
      if (this.taxType != that.taxType)
1282
        return false;
1283
    }
1284
 
11219 manish.sha 1285
    boolean this_present_invoiceDate = true;
1286
    boolean that_present_invoiceDate = true;
1287
    if (this_present_invoiceDate || that_present_invoiceDate) {
1288
      if (!(this_present_invoiceDate && that_present_invoiceDate))
1289
        return false;
1290
      if (this.invoiceDate != that.invoiceDate)
1291
        return false;
1292
    }
1293
 
12620 amit.gupta 1294
    boolean this_present_mrp = true;
1295
    boolean that_present_mrp = true;
1296
    if (this_present_mrp || that_present_mrp) {
1297
      if (!(this_present_mrp && that_present_mrp))
1298
        return false;
1299
      if (this.mrp != that.mrp)
1300
        return false;
1301
    }
1302
 
12800 manish.sha 1303
    boolean this_present_purchaseComments = true && this.isSetPurchaseComments();
1304
    boolean that_present_purchaseComments = true && that.isSetPurchaseComments();
1305
    if (this_present_purchaseComments || that_present_purchaseComments) {
1306
      if (!(this_present_purchaseComments && that_present_purchaseComments))
1307
        return false;
1308
      if (!this.purchaseComments.equals(that.purchaseComments))
1309
        return false;
1310
    }
1311
 
5372 mandeep.dh 1312
    return true;
1313
  }
1314
 
1315
  @Override
1316
  public int hashCode() {
1317
    return 0;
1318
  }
1319
 
1320
  public int compareTo(DetailedPurchaseScan other) {
1321
    if (!getClass().equals(other.getClass())) {
1322
      return getClass().getName().compareTo(other.getClass().getName());
1323
    }
1324
 
1325
    int lastComparison = 0;
1326
    DetailedPurchaseScan typedOther = (DetailedPurchaseScan)other;
1327
 
1328
    lastComparison = Boolean.valueOf(isSetPurchaseOrderId()).compareTo(typedOther.isSetPurchaseOrderId());
1329
    if (lastComparison != 0) {
1330
      return lastComparison;
1331
    }
1332
    if (isSetPurchaseOrderId()) {
1333
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.purchaseOrderId, typedOther.purchaseOrderId);
1334
      if (lastComparison != 0) {
1335
        return lastComparison;
1336
      }
1337
    }
1338
    lastComparison = Boolean.valueOf(isSetPoCreatedAt()).compareTo(typedOther.isSetPoCreatedAt());
1339
    if (lastComparison != 0) {
1340
      return lastComparison;
1341
    }
1342
    if (isSetPoCreatedAt()) {
1343
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.poCreatedAt, typedOther.poCreatedAt);
1344
      if (lastComparison != 0) {
1345
        return lastComparison;
1346
      }
1347
    }
1348
    lastComparison = Boolean.valueOf(isSetSupplierName()).compareTo(typedOther.isSetSupplierName());
1349
    if (lastComparison != 0) {
1350
      return lastComparison;
1351
    }
1352
    if (isSetSupplierName()) {
1353
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.supplierName, typedOther.supplierName);
1354
      if (lastComparison != 0) {
1355
        return lastComparison;
1356
      }
1357
    }
1358
    lastComparison = Boolean.valueOf(isSetInvoiceNumbers()).compareTo(typedOther.isSetInvoiceNumbers());
1359
    if (lastComparison != 0) {
1360
      return lastComparison;
1361
    }
1362
    if (isSetInvoiceNumbers()) {
1363
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.invoiceNumbers, typedOther.invoiceNumbers);
1364
      if (lastComparison != 0) {
1365
        return lastComparison;
1366
      }
1367
    }
6494 amar.kumar 1368
    lastComparison = Boolean.valueOf(isSetReceivedBy()).compareTo(typedOther.isSetReceivedBy());
1369
    if (lastComparison != 0) {
1370
      return lastComparison;
1371
    }
1372
    if (isSetReceivedBy()) {
1373
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.receivedBy, typedOther.receivedBy);
1374
      if (lastComparison != 0) {
1375
        return lastComparison;
1376
      }
1377
    }
5372 mandeep.dh 1378
    lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
1379
    if (lastComparison != 0) {
1380
      return lastComparison;
1381
    }
1382
    if (isSetItemId()) {
1383
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
1384
      if (lastComparison != 0) {
1385
        return lastComparison;
1386
      }
1387
    }
5545 mandeep.dh 1388
    lastComparison = Boolean.valueOf(isSetBrand()).compareTo(typedOther.isSetBrand());
5372 mandeep.dh 1389
    if (lastComparison != 0) {
1390
      return lastComparison;
1391
    }
5545 mandeep.dh 1392
    if (isSetBrand()) {
1393
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.brand, typedOther.brand);
5372 mandeep.dh 1394
      if (lastComparison != 0) {
1395
        return lastComparison;
1396
      }
1397
    }
5545 mandeep.dh 1398
    lastComparison = Boolean.valueOf(isSetModelName()).compareTo(typedOther.isSetModelName());
1399
    if (lastComparison != 0) {
1400
      return lastComparison;
1401
    }
1402
    if (isSetModelName()) {
1403
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.modelName, typedOther.modelName);
1404
      if (lastComparison != 0) {
1405
        return lastComparison;
1406
      }
1407
    }
1408
    lastComparison = Boolean.valueOf(isSetModelNumber()).compareTo(typedOther.isSetModelNumber());
1409
    if (lastComparison != 0) {
1410
      return lastComparison;
1411
    }
1412
    if (isSetModelNumber()) {
1413
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.modelNumber, typedOther.modelNumber);
1414
      if (lastComparison != 0) {
1415
        return lastComparison;
1416
      }
1417
    }
1418
    lastComparison = Boolean.valueOf(isSetColor()).compareTo(typedOther.isSetColor());
1419
    if (lastComparison != 0) {
1420
      return lastComparison;
1421
    }
1422
    if (isSetColor()) {
1423
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.color, typedOther.color);
1424
      if (lastComparison != 0) {
1425
        return lastComparison;
1426
      }
1427
    }
5372 mandeep.dh 1428
    lastComparison = Boolean.valueOf(isSetUnitPrice()).compareTo(typedOther.isSetUnitPrice());
1429
    if (lastComparison != 0) {
1430
      return lastComparison;
1431
    }
1432
    if (isSetUnitPrice()) {
1433
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.unitPrice, typedOther.unitPrice);
1434
      if (lastComparison != 0) {
1435
        return lastComparison;
1436
      }
1437
    }
1438
    lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
1439
    if (lastComparison != 0) {
1440
      return lastComparison;
1441
    }
1442
    if (isSetQuantity()) {
1443
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
1444
      if (lastComparison != 0) {
1445
        return lastComparison;
1446
      }
1447
    }
6361 rajveer 1448
    lastComparison = Boolean.valueOf(isSetPurchaseId()).compareTo(typedOther.isSetPurchaseId());
1449
    if (lastComparison != 0) {
1450
      return lastComparison;
1451
    }
1452
    if (isSetPurchaseId()) {
1453
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.purchaseId, typedOther.purchaseId);
1454
      if (lastComparison != 0) {
1455
        return lastComparison;
1456
      }
1457
    }
1458
    lastComparison = Boolean.valueOf(isSetPurchasedAt()).compareTo(typedOther.isSetPurchasedAt());
1459
    if (lastComparison != 0) {
1460
      return lastComparison;
1461
    }
1462
    if (isSetPurchasedAt()) {
1463
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.purchasedAt, typedOther.purchasedAt);
1464
      if (lastComparison != 0) {
1465
        return lastComparison;
1466
      }
1467
    }
7672 rajveer 1468
    lastComparison = Boolean.valueOf(isSetNlc()).compareTo(typedOther.isSetNlc());
1469
    if (lastComparison != 0) {
1470
      return lastComparison;
1471
    }
1472
    if (isSetNlc()) {
1473
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.nlc, typedOther.nlc);
1474
      if (lastComparison != 0) {
1475
        return lastComparison;
1476
      }
1477
    }
8580 amar.kumar 1478
    lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
1479
    if (lastComparison != 0) {
1480
      return lastComparison;
1481
    }
1482
    if (isSetWarehouseId()) {
1483
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
1484
      if (lastComparison != 0) {
1485
        return lastComparison;
1486
      }
1487
    }
9433 amar.kumar 1488
    lastComparison = Boolean.valueOf(isSetTaxType()).compareTo(typedOther.isSetTaxType());
1489
    if (lastComparison != 0) {
1490
      return lastComparison;
1491
    }
1492
    if (isSetTaxType()) {
1493
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.taxType, typedOther.taxType);
1494
      if (lastComparison != 0) {
1495
        return lastComparison;
1496
      }
1497
    }
11219 manish.sha 1498
    lastComparison = Boolean.valueOf(isSetInvoiceDate()).compareTo(typedOther.isSetInvoiceDate());
1499
    if (lastComparison != 0) {
1500
      return lastComparison;
1501
    }
1502
    if (isSetInvoiceDate()) {
1503
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.invoiceDate, typedOther.invoiceDate);
1504
      if (lastComparison != 0) {
1505
        return lastComparison;
1506
      }
1507
    }
12620 amit.gupta 1508
    lastComparison = Boolean.valueOf(isSetMrp()).compareTo(typedOther.isSetMrp());
1509
    if (lastComparison != 0) {
1510
      return lastComparison;
1511
    }
1512
    if (isSetMrp()) {
1513
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.mrp, typedOther.mrp);
1514
      if (lastComparison != 0) {
1515
        return lastComparison;
1516
      }
1517
    }
12800 manish.sha 1518
    lastComparison = Boolean.valueOf(isSetPurchaseComments()).compareTo(typedOther.isSetPurchaseComments());
1519
    if (lastComparison != 0) {
1520
      return lastComparison;
1521
    }
1522
    if (isSetPurchaseComments()) {
1523
      lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.purchaseComments, typedOther.purchaseComments);
1524
      if (lastComparison != 0) {
1525
        return lastComparison;
1526
      }
1527
    }
5372 mandeep.dh 1528
    return 0;
1529
  }
1530
 
1531
  public _Fields fieldForId(int fieldId) {
1532
    return _Fields.findByThriftId(fieldId);
1533
  }
1534
 
1535
  public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
1536
    org.apache.thrift.protocol.TField field;
1537
    iprot.readStructBegin();
1538
    while (true)
1539
    {
1540
      field = iprot.readFieldBegin();
1541
      if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1542
        break;
1543
      }
1544
      switch (field.id) {
1545
        case 1: // PURCHASE_ORDER_ID
1546
          if (field.type == org.apache.thrift.protocol.TType.I64) {
1547
            this.purchaseOrderId = iprot.readI64();
1548
            setPurchaseOrderIdIsSet(true);
1549
          } else { 
1550
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1551
          }
1552
          break;
1553
        case 2: // PO_CREATED_AT
1554
          if (field.type == org.apache.thrift.protocol.TType.I64) {
1555
            this.poCreatedAt = iprot.readI64();
1556
            setPoCreatedAtIsSet(true);
1557
          } else { 
1558
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1559
          }
1560
          break;
1561
        case 3: // SUPPLIER_NAME
1562
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
1563
            this.supplierName = iprot.readString();
1564
          } else { 
1565
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1566
          }
1567
          break;
1568
        case 4: // INVOICE_NUMBERS
1569
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
1570
            this.invoiceNumbers = iprot.readString();
1571
          } else { 
1572
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1573
          }
1574
          break;
6494 amar.kumar 1575
        case 5: // RECEIVED_BY
1576
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
1577
            this.receivedBy = iprot.readString();
1578
          } else { 
1579
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1580
          }
1581
          break;
1582
        case 6: // ITEM_ID
5372 mandeep.dh 1583
          if (field.type == org.apache.thrift.protocol.TType.I64) {
1584
            this.itemId = iprot.readI64();
1585
            setItemIdIsSet(true);
1586
          } else { 
1587
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1588
          }
1589
          break;
6494 amar.kumar 1590
        case 7: // BRAND
5372 mandeep.dh 1591
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
5545 mandeep.dh 1592
            this.brand = iprot.readString();
5372 mandeep.dh 1593
          } else { 
1594
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1595
          }
1596
          break;
6494 amar.kumar 1597
        case 8: // MODEL_NAME
5545 mandeep.dh 1598
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
1599
            this.modelName = iprot.readString();
1600
          } else { 
1601
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1602
          }
1603
          break;
6494 amar.kumar 1604
        case 9: // MODEL_NUMBER
5545 mandeep.dh 1605
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
1606
            this.modelNumber = iprot.readString();
1607
          } else { 
1608
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1609
          }
1610
          break;
6494 amar.kumar 1611
        case 10: // COLOR
5545 mandeep.dh 1612
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
1613
            this.color = iprot.readString();
1614
          } else { 
1615
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1616
          }
1617
          break;
6494 amar.kumar 1618
        case 11: // UNIT_PRICE
5372 mandeep.dh 1619
          if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
1620
            this.unitPrice = iprot.readDouble();
1621
            setUnitPriceIsSet(true);
1622
          } else { 
1623
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1624
          }
1625
          break;
6494 amar.kumar 1626
        case 12: // QUANTITY
5372 mandeep.dh 1627
          if (field.type == org.apache.thrift.protocol.TType.I64) {
1628
            this.quantity = iprot.readI64();
1629
            setQuantityIsSet(true);
1630
          } else { 
1631
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1632
          }
1633
          break;
6494 amar.kumar 1634
        case 13: // PURCHASE_ID
6361 rajveer 1635
          if (field.type == org.apache.thrift.protocol.TType.I64) {
1636
            this.purchaseId = iprot.readI64();
1637
            setPurchaseIdIsSet(true);
1638
          } else { 
1639
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1640
          }
1641
          break;
6494 amar.kumar 1642
        case 14: // PURCHASED_AT
6361 rajveer 1643
          if (field.type == org.apache.thrift.protocol.TType.I64) {
1644
            this.purchasedAt = iprot.readI64();
1645
            setPurchasedAtIsSet(true);
1646
          } else { 
1647
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1648
          }
1649
          break;
7672 rajveer 1650
        case 15: // NLC
1651
          if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
1652
            this.nlc = iprot.readDouble();
1653
            setNlcIsSet(true);
1654
          } else { 
1655
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1656
          }
1657
          break;
8580 amar.kumar 1658
        case 16: // WAREHOUSE_ID
1659
          if (field.type == org.apache.thrift.protocol.TType.I64) {
1660
            this.warehouseId = iprot.readI64();
1661
            setWarehouseIdIsSet(true);
1662
          } else { 
1663
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1664
          }
1665
          break;
9433 amar.kumar 1666
        case 17: // TAX_TYPE
1667
          if (field.type == org.apache.thrift.protocol.TType.I64) {
1668
            this.taxType = iprot.readI64();
1669
            setTaxTypeIsSet(true);
1670
          } else { 
1671
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1672
          }
1673
          break;
11219 manish.sha 1674
        case 18: // INVOICE_DATE
1675
          if (field.type == org.apache.thrift.protocol.TType.I64) {
1676
            this.invoiceDate = iprot.readI64();
1677
            setInvoiceDateIsSet(true);
1678
          } else { 
1679
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1680
          }
1681
          break;
12620 amit.gupta 1682
        case 19: // MRP
1683
          if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
1684
            this.mrp = iprot.readDouble();
1685
            setMrpIsSet(true);
1686
          } else { 
1687
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1688
          }
1689
          break;
12800 manish.sha 1690
        case 20: // PURCHASE_COMMENTS
1691
          if (field.type == org.apache.thrift.protocol.TType.STRING) {
1692
            this.purchaseComments = iprot.readString();
1693
          } else { 
1694
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1695
          }
1696
          break;
5372 mandeep.dh 1697
        default:
1698
          org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1699
      }
1700
      iprot.readFieldEnd();
1701
    }
1702
    iprot.readStructEnd();
1703
    validate();
1704
  }
1705
 
1706
  public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1707
    validate();
1708
 
1709
    oprot.writeStructBegin(STRUCT_DESC);
1710
    oprot.writeFieldBegin(PURCHASE_ORDER_ID_FIELD_DESC);
1711
    oprot.writeI64(this.purchaseOrderId);
1712
    oprot.writeFieldEnd();
1713
    oprot.writeFieldBegin(PO_CREATED_AT_FIELD_DESC);
1714
    oprot.writeI64(this.poCreatedAt);
1715
    oprot.writeFieldEnd();
1716
    if (this.supplierName != null) {
1717
      oprot.writeFieldBegin(SUPPLIER_NAME_FIELD_DESC);
1718
      oprot.writeString(this.supplierName);
1719
      oprot.writeFieldEnd();
1720
    }
1721
    if (this.invoiceNumbers != null) {
1722
      oprot.writeFieldBegin(INVOICE_NUMBERS_FIELD_DESC);
1723
      oprot.writeString(this.invoiceNumbers);
1724
      oprot.writeFieldEnd();
1725
    }
6494 amar.kumar 1726
    if (this.receivedBy != null) {
1727
      oprot.writeFieldBegin(RECEIVED_BY_FIELD_DESC);
1728
      oprot.writeString(this.receivedBy);
1729
      oprot.writeFieldEnd();
1730
    }
5372 mandeep.dh 1731
    oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
1732
    oprot.writeI64(this.itemId);
1733
    oprot.writeFieldEnd();
5545 mandeep.dh 1734
    if (this.brand != null) {
1735
      oprot.writeFieldBegin(BRAND_FIELD_DESC);
1736
      oprot.writeString(this.brand);
5372 mandeep.dh 1737
      oprot.writeFieldEnd();
1738
    }
5545 mandeep.dh 1739
    if (this.modelName != null) {
1740
      oprot.writeFieldBegin(MODEL_NAME_FIELD_DESC);
1741
      oprot.writeString(this.modelName);
1742
      oprot.writeFieldEnd();
1743
    }
1744
    if (this.modelNumber != null) {
1745
      oprot.writeFieldBegin(MODEL_NUMBER_FIELD_DESC);
1746
      oprot.writeString(this.modelNumber);
1747
      oprot.writeFieldEnd();
1748
    }
1749
    if (this.color != null) {
1750
      oprot.writeFieldBegin(COLOR_FIELD_DESC);
1751
      oprot.writeString(this.color);
1752
      oprot.writeFieldEnd();
1753
    }
5372 mandeep.dh 1754
    oprot.writeFieldBegin(UNIT_PRICE_FIELD_DESC);
1755
    oprot.writeDouble(this.unitPrice);
1756
    oprot.writeFieldEnd();
1757
    oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
1758
    oprot.writeI64(this.quantity);
1759
    oprot.writeFieldEnd();
6361 rajveer 1760
    oprot.writeFieldBegin(PURCHASE_ID_FIELD_DESC);
1761
    oprot.writeI64(this.purchaseId);
1762
    oprot.writeFieldEnd();
1763
    oprot.writeFieldBegin(PURCHASED_AT_FIELD_DESC);
1764
    oprot.writeI64(this.purchasedAt);
1765
    oprot.writeFieldEnd();
7672 rajveer 1766
    oprot.writeFieldBegin(NLC_FIELD_DESC);
1767
    oprot.writeDouble(this.nlc);
1768
    oprot.writeFieldEnd();
8580 amar.kumar 1769
    oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
1770
    oprot.writeI64(this.warehouseId);
1771
    oprot.writeFieldEnd();
9433 amar.kumar 1772
    oprot.writeFieldBegin(TAX_TYPE_FIELD_DESC);
1773
    oprot.writeI64(this.taxType);
1774
    oprot.writeFieldEnd();
11219 manish.sha 1775
    oprot.writeFieldBegin(INVOICE_DATE_FIELD_DESC);
1776
    oprot.writeI64(this.invoiceDate);
1777
    oprot.writeFieldEnd();
12620 amit.gupta 1778
    oprot.writeFieldBegin(MRP_FIELD_DESC);
1779
    oprot.writeDouble(this.mrp);
1780
    oprot.writeFieldEnd();
12800 manish.sha 1781
    if (this.purchaseComments != null) {
1782
      oprot.writeFieldBegin(PURCHASE_COMMENTS_FIELD_DESC);
1783
      oprot.writeString(this.purchaseComments);
1784
      oprot.writeFieldEnd();
1785
    }
5372 mandeep.dh 1786
    oprot.writeFieldStop();
1787
    oprot.writeStructEnd();
1788
  }
1789
 
1790
  @Override
1791
  public String toString() {
1792
    StringBuilder sb = new StringBuilder("DetailedPurchaseScan(");
1793
    boolean first = true;
1794
 
1795
    sb.append("purchaseOrderId:");
1796
    sb.append(this.purchaseOrderId);
1797
    first = false;
1798
    if (!first) sb.append(", ");
1799
    sb.append("poCreatedAt:");
1800
    sb.append(this.poCreatedAt);
1801
    first = false;
1802
    if (!first) sb.append(", ");
1803
    sb.append("supplierName:");
1804
    if (this.supplierName == null) {
1805
      sb.append("null");
1806
    } else {
1807
      sb.append(this.supplierName);
1808
    }
1809
    first = false;
1810
    if (!first) sb.append(", ");
1811
    sb.append("invoiceNumbers:");
1812
    if (this.invoiceNumbers == null) {
1813
      sb.append("null");
1814
    } else {
1815
      sb.append(this.invoiceNumbers);
1816
    }
1817
    first = false;
1818
    if (!first) sb.append(", ");
6494 amar.kumar 1819
    sb.append("receivedBy:");
1820
    if (this.receivedBy == null) {
1821
      sb.append("null");
1822
    } else {
1823
      sb.append(this.receivedBy);
1824
    }
1825
    first = false;
1826
    if (!first) sb.append(", ");
5372 mandeep.dh 1827
    sb.append("itemId:");
1828
    sb.append(this.itemId);
1829
    first = false;
1830
    if (!first) sb.append(", ");
5545 mandeep.dh 1831
    sb.append("brand:");
1832
    if (this.brand == null) {
5372 mandeep.dh 1833
      sb.append("null");
1834
    } else {
5545 mandeep.dh 1835
      sb.append(this.brand);
5372 mandeep.dh 1836
    }
1837
    first = false;
1838
    if (!first) sb.append(", ");
5545 mandeep.dh 1839
    sb.append("modelName:");
1840
    if (this.modelName == null) {
1841
      sb.append("null");
1842
    } else {
1843
      sb.append(this.modelName);
1844
    }
1845
    first = false;
1846
    if (!first) sb.append(", ");
1847
    sb.append("modelNumber:");
1848
    if (this.modelNumber == null) {
1849
      sb.append("null");
1850
    } else {
1851
      sb.append(this.modelNumber);
1852
    }
1853
    first = false;
1854
    if (!first) sb.append(", ");
1855
    sb.append("color:");
1856
    if (this.color == null) {
1857
      sb.append("null");
1858
    } else {
1859
      sb.append(this.color);
1860
    }
1861
    first = false;
1862
    if (!first) sb.append(", ");
5372 mandeep.dh 1863
    sb.append("unitPrice:");
1864
    sb.append(this.unitPrice);
1865
    first = false;
1866
    if (!first) sb.append(", ");
1867
    sb.append("quantity:");
1868
    sb.append(this.quantity);
1869
    first = false;
6361 rajveer 1870
    if (!first) sb.append(", ");
1871
    sb.append("purchaseId:");
1872
    sb.append(this.purchaseId);
1873
    first = false;
1874
    if (!first) sb.append(", ");
1875
    sb.append("purchasedAt:");
1876
    sb.append(this.purchasedAt);
1877
    first = false;
7672 rajveer 1878
    if (!first) sb.append(", ");
1879
    sb.append("nlc:");
1880
    sb.append(this.nlc);
1881
    first = false;
8580 amar.kumar 1882
    if (!first) sb.append(", ");
1883
    sb.append("warehouseId:");
1884
    sb.append(this.warehouseId);
1885
    first = false;
9433 amar.kumar 1886
    if (!first) sb.append(", ");
1887
    sb.append("taxType:");
1888
    sb.append(this.taxType);
1889
    first = false;
11219 manish.sha 1890
    if (!first) sb.append(", ");
1891
    sb.append("invoiceDate:");
1892
    sb.append(this.invoiceDate);
1893
    first = false;
12620 amit.gupta 1894
    if (!first) sb.append(", ");
1895
    sb.append("mrp:");
1896
    sb.append(this.mrp);
1897
    first = false;
12800 manish.sha 1898
    if (!first) sb.append(", ");
1899
    sb.append("purchaseComments:");
1900
    if (this.purchaseComments == null) {
1901
      sb.append("null");
1902
    } else {
1903
      sb.append(this.purchaseComments);
1904
    }
1905
    first = false;
5372 mandeep.dh 1906
    sb.append(")");
1907
    return sb.toString();
1908
  }
1909
 
1910
  public void validate() throws org.apache.thrift.TException {
1911
    // check for required fields
1912
  }
1913
 
1914
  private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
1915
    try {
1916
      write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
1917
    } catch (org.apache.thrift.TException te) {
1918
      throw new java.io.IOException(te);
1919
    }
1920
  }
1921
 
1922
  private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
1923
    try {
1924
      // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
1925
      __isset_bit_vector = new BitSet(1);
1926
      read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
1927
    } catch (org.apache.thrift.TException te) {
1928
      throw new java.io.IOException(te);
1929
    }
1930
  }
1931
 
1932
}
1933