Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
2820 chandransh 1
/**
3430 rajveer 2
 * Autogenerated by Thrift Compiler (0.7.0)
2820 chandransh 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;
3430 rajveer 18
import java.nio.ByteBuffer;
2820 chandransh 19
import java.util.Arrays;
20
import org.slf4j.Logger;
21
import org.slf4j.LoggerFactory;
22
 
23
public class WarehouseService {
24
 
3374 rajveer 25
  public interface Iface extends in.shop2020.generic.GenericService.Iface {
2820 chandransh 26
 
27
    /**
4496 mandeep.dh 28
     * Retrieves serialized inventory item given a serial number
2832 chandransh 29
     * 
4496 mandeep.dh 30
     * @param serialNumber
2832 chandransh 31
     */
4541 mandeep.dh 32
    public InventoryItem getInventoryItem(String serialNumber) throws WarehouseServiceException, org.apache.thrift.TException;
2832 chandransh 33
 
34
    /**
5361 mandeep.dh 35
     * Retrieves non-serialized inventory item from a given supplier
2820 chandransh 36
     * 
5530 mandeep.dh 37
     * @param itemNumber
4496 mandeep.dh 38
     * @param itemId
5530 mandeep.dh 39
     * @param fulfilmentWarehouseId
2820 chandransh 40
     */
5530 mandeep.dh 41
    public InventoryItem getNonSeralizedInventoryItem(String itemNumber, long itemId, long fulfilmentWarehouseId) throws WarehouseServiceException, org.apache.thrift.TException;
2820 chandransh 42
 
43
    /**
4496 mandeep.dh 44
     * Scan non-serialized items.
2820 chandransh 45
     * 
5361 mandeep.dh 46
     * @param inventoryItem
2820 chandransh 47
     * @param type
4496 mandeep.dh 48
     * @param quantity
5361 mandeep.dh 49
     * @param billingWarehouseId
2820 chandransh 50
     */
5361 mandeep.dh 51
    public void scan(InventoryItem inventoryItem, ScanType type, long quantity, long billingWarehouseId) throws WarehouseServiceException, org.apache.thrift.TException;
2820 chandransh 52
 
4496 mandeep.dh 53
    /**
54
     * Scan serialized items linked with an order. Returns its price.
55
     * 
4555 mandeep.dh 56
     * @param serialNumber
4496 mandeep.dh 57
     * @param type
58
     * @param orderId
5110 mandeep.dh 59
     * @param fulfilmentWarehouseId
60
     * @param quantity
61
     * @param billingWarehouseId
4496 mandeep.dh 62
     */
5110 mandeep.dh 63
    public InventoryItem scanSerializedItemForOrder(String serialNumber, ScanType type, long orderId, long fulfilmentWarehouseId, double quantity, long billingWarehouseId) throws WarehouseServiceException, org.apache.thrift.TException;
4496 mandeep.dh 64
 
65
    /**
66
     * Scan non-serialized items linked with an order.
67
     * 
5361 mandeep.dh 68
     * @param inventoryItem
4496 mandeep.dh 69
     * @param type
70
     * @param quantity
71
     * @param orderId
5110 mandeep.dh 72
     * @param fulfilmentWarehouseId
5361 mandeep.dh 73
     * @param billingWarehouseId
4496 mandeep.dh 74
     */
5361 mandeep.dh 75
    public InventoryItem scanForOrder(InventoryItem inventoryItem, ScanType type, long quantity, long orderId, long fulfilmentWarehouseId, long billingWarehouseId) throws WarehouseServiceException, org.apache.thrift.TException;
4496 mandeep.dh 76
 
77
    /**
78
     * Created item number to item id mapping
79
     * 
80
     * @param itemNumber
81
     * @param itemId
82
     */
83
    public void createItemNumberMapping(String itemNumber, long itemId) throws org.apache.thrift.TException;
84
 
4622 amit.gupta 85
    /**
86
     * Get itemNumber mappings for itemId
87
     * 
88
     * @param itemId
89
     */
90
    public List<String> getItemNumbers(long itemId) throws org.apache.thrift.TException;
91
 
5110 mandeep.dh 92
    /**
93
     * Gets item ids for a given item number
94
     * 
95
     * @param itemNumber
96
     */
97
    public List<Long> getItemIds(String itemNumber) throws org.apache.thrift.TException;
98
 
5185 mandeep.dh 99
    /**
100
     * Retrieves all inventory items given a last scan type
101
     * 
102
     * @param lastScanType
103
     */
104
    public List<InventoryItem> getInventoryItemsFromLastScanType(ScanType lastScanType) throws WarehouseServiceException, org.apache.thrift.TException;
105
 
106
    /**
107
     * Retrieves inventory item given a inventoryItem id
108
     * 
109
     * @param inventoryItemId
110
     */
111
    public InventoryItem getInventoryItemFromId(long inventoryItemId) throws WarehouseServiceException, org.apache.thrift.TException;
112
 
5372 mandeep.dh 113
    /**
114
     * Returns the purchase scans grouped by items for Purchase register reconciliation
115
     * 
116
     * @param startDate
117
     * @param endDate
118
     */
119
    public List<DetailedPurchaseScan> getPurchaseScans(long startDate, long endDate) throws org.apache.thrift.TException;
120
 
5496 mandeep.dh 121
    /**
122
     * Returns the invoices and the count of scans against on a given day.
123
     * 
124
     * @param date
125
     */
126
    public List<InvoiceScan> fetchScansPerInvoiceNumber(long date) throws org.apache.thrift.TException;
127
 
5620 mandeep.dh 128
    /**
129
     * Returns inventory item for a given order
130
     * 
131
     * @param orderId
132
     */
133
    public InventoryItem getInventoryItemFromOrder(long orderId) throws WarehouseServiceException, org.apache.thrift.TException;
134
 
5711 mandeep.dh 135
    /**
136
     * Fetches the stock inventory age week-wise
137
     */
138
    public List<InventoryAge> getInventoryAge() throws org.apache.thrift.TException;
139
 
6322 amar.kumar 140
    /**
141
     * Fetches the scanRecords for a given item for a given time interval
142
     * 
143
     * @param itemId
144
     * @param fromDate
145
     * @param toDate
146
     */
147
    public List<Scan> getInventoryScansForItem(long itemId, long fromDate, long toDate) throws org.apache.thrift.TException;
148
 
149
    /**
150
     * Fetches the scanRecords for a given serialNumber for a given time interval
151
     * 
152
     * @param serialNumber
153
     */
154
    public List<Scan> getScanRecordsForSerialNumber(long serialNumber) throws org.apache.thrift.TException;
155
 
6467 amar.kumar 156
    /**
6548 amar.kumar 157
     * Inserts outgoing scans for Returned Items and updates returnId in InventoryItems
6467 amar.kumar 158
     * 
159
     * @param saleReturnItems
160
     * @param vendorId
161
     */
162
    public void scanForPurchaseReturn(List<InventoryItem> saleReturnItems, long vendorId) throws WarehouseServiceException, org.apache.thrift.TException;
163
 
6548 amar.kumar 164
    /**
165
     * Inserts scans for lost Items and updates lastScanType in InventoryItems
166
     * 
167
     * @param lostItems
168
     * @param vendorId
169
     */
170
    public void scanForLostItem(List<InventoryItem> lostItems, long vendorId) throws WarehouseServiceException, org.apache.thrift.TException;
171
 
172
    /**
173
     * Get inventory count for available Serialized items in our warehouses using entries in ScanNew table
174
     */
175
    public List<InventoryAvailability> getCurrentSerializedInventoryByScans() throws org.apache.thrift.TException;
176
 
6630 amar.kumar 177
    /**
178
     * Get inventory count for available Serialized items in our warehouses using entries in ScanNew table
179
     */
180
    public List<InventoryAvailability> getCurrentNonSerializedInventoryByScans() throws org.apache.thrift.TException;
181
 
6762 amar.kumar 182
    /**
183
     * Get inventory for Serialized items in our warehouses at a given date using entries in ScanNew table
184
     * 
185
     * @param date
186
     */
187
    public List<InventoryAvailability> getHistoricSerializedInventoryByScans(long date) throws org.apache.thrift.TException;
188
 
189
    /**
190
     * Get inventory for Non Serialized items in our warehouses at a given date using entries in ScanNew table
191
     * 
192
     * @param date
193
     */
194
    public List<InventoryAvailability> getHistoricNonSerializedInventoryByScans(long date) throws org.apache.thrift.TException;
195
 
196
    /**
197
     * Insert Purchase/Scan Entries for product billed by Hotspot using OURS_EXTERNAL Billing
198
     * 
199
     * @param itemId
200
     * @param serialNumber
201
     * @param itemNumber
202
     * @param invoiceNumber
203
     * @param warehouseId
204
     * @param unitPrice
205
     * @param orderId
206
     */
207
    public InventoryItem scanForOursExternalSale(long itemId, String serialNumber, String itemNumber, String invoiceNumber, long warehouseId, double unitPrice, long orderId) throws WarehouseServiceException, org.apache.thrift.TException;
208
 
209
    /**
210
     * Insert Purchase_Ret Entries for product billed by Hotspot using OURS_EXTERNAL Billing
211
     * 
212
     * @param orderId
213
     * @param unitPrice
214
     */
215
    public void scanForOursExternalSaleReturn(long orderId, double unitPrice) throws org.apache.thrift.TException;
216
 
2820 chandransh 217
  }
218
 
3430 rajveer 219
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
220
 
4496 mandeep.dh 221
    public void getInventoryItem(String serialNumber, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventoryItem_call> resultHandler) throws org.apache.thrift.TException;
3430 rajveer 222
 
5530 mandeep.dh 223
    public void getNonSeralizedInventoryItem(String itemNumber, long itemId, long fulfilmentWarehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getNonSeralizedInventoryItem_call> resultHandler) throws org.apache.thrift.TException;
3430 rajveer 224
 
5361 mandeep.dh 225
    public void scan(InventoryItem inventoryItem, ScanType type, long quantity, long billingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.scan_call> resultHandler) throws org.apache.thrift.TException;
3430 rajveer 226
 
5110 mandeep.dh 227
    public void scanSerializedItemForOrder(String serialNumber, ScanType type, long orderId, long fulfilmentWarehouseId, double quantity, long billingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.scanSerializedItemForOrder_call> resultHandler) throws org.apache.thrift.TException;
4496 mandeep.dh 228
 
5361 mandeep.dh 229
    public void scanForOrder(InventoryItem inventoryItem, ScanType type, long quantity, long orderId, long fulfilmentWarehouseId, long billingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.scanForOrder_call> resultHandler) throws org.apache.thrift.TException;
4496 mandeep.dh 230
 
231
    public void createItemNumberMapping(String itemNumber, long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.createItemNumberMapping_call> resultHandler) throws org.apache.thrift.TException;
232
 
4622 amit.gupta 233
    public void getItemNumbers(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemNumbers_call> resultHandler) throws org.apache.thrift.TException;
234
 
5110 mandeep.dh 235
    public void getItemIds(String itemNumber, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemIds_call> resultHandler) throws org.apache.thrift.TException;
236
 
5185 mandeep.dh 237
    public void getInventoryItemsFromLastScanType(ScanType lastScanType, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventoryItemsFromLastScanType_call> resultHandler) throws org.apache.thrift.TException;
238
 
239
    public void getInventoryItemFromId(long inventoryItemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventoryItemFromId_call> resultHandler) throws org.apache.thrift.TException;
240
 
5372 mandeep.dh 241
    public void getPurchaseScans(long startDate, long endDate, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPurchaseScans_call> resultHandler) throws org.apache.thrift.TException;
242
 
5496 mandeep.dh 243
    public void fetchScansPerInvoiceNumber(long date, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.fetchScansPerInvoiceNumber_call> resultHandler) throws org.apache.thrift.TException;
244
 
5620 mandeep.dh 245
    public void getInventoryItemFromOrder(long orderId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventoryItemFromOrder_call> resultHandler) throws org.apache.thrift.TException;
246
 
5711 mandeep.dh 247
    public void getInventoryAge(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventoryAge_call> resultHandler) throws org.apache.thrift.TException;
248
 
6322 amar.kumar 249
    public void getInventoryScansForItem(long itemId, long fromDate, long toDate, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventoryScansForItem_call> resultHandler) throws org.apache.thrift.TException;
250
 
251
    public void getScanRecordsForSerialNumber(long serialNumber, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getScanRecordsForSerialNumber_call> resultHandler) throws org.apache.thrift.TException;
252
 
6467 amar.kumar 253
    public void scanForPurchaseReturn(List<InventoryItem> saleReturnItems, long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.scanForPurchaseReturn_call> resultHandler) throws org.apache.thrift.TException;
254
 
6548 amar.kumar 255
    public void scanForLostItem(List<InventoryItem> lostItems, long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.scanForLostItem_call> resultHandler) throws org.apache.thrift.TException;
256
 
257
    public void getCurrentSerializedInventoryByScans(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getCurrentSerializedInventoryByScans_call> resultHandler) throws org.apache.thrift.TException;
258
 
6630 amar.kumar 259
    public void getCurrentNonSerializedInventoryByScans(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getCurrentNonSerializedInventoryByScans_call> resultHandler) throws org.apache.thrift.TException;
260
 
6762 amar.kumar 261
    public void getHistoricSerializedInventoryByScans(long date, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getHistoricSerializedInventoryByScans_call> resultHandler) throws org.apache.thrift.TException;
262
 
263
    public void getHistoricNonSerializedInventoryByScans(long date, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getHistoricNonSerializedInventoryByScans_call> resultHandler) throws org.apache.thrift.TException;
264
 
265
    public void scanForOursExternalSale(long itemId, String serialNumber, String itemNumber, String invoiceNumber, long warehouseId, double unitPrice, long orderId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.scanForOursExternalSale_call> resultHandler) throws org.apache.thrift.TException;
266
 
267
    public void scanForOursExternalSaleReturn(long orderId, double unitPrice, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.scanForOursExternalSaleReturn_call> resultHandler) throws org.apache.thrift.TException;
268
 
3430 rajveer 269
  }
270
 
3374 rajveer 271
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
3430 rajveer 272
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
273
      public Factory() {}
274
      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
275
        return new Client(prot);
276
      }
277
      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
278
        return new Client(iprot, oprot);
279
      }
280
    }
281
 
282
    public Client(org.apache.thrift.protocol.TProtocol prot)
2820 chandransh 283
    {
3430 rajveer 284
      super(prot, prot);
2820 chandransh 285
    }
286
 
3430 rajveer 287
    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
3374 rajveer 288
      super(iprot, oprot);
2820 chandransh 289
    }
290
 
4541 mandeep.dh 291
    public InventoryItem getInventoryItem(String serialNumber) throws WarehouseServiceException, org.apache.thrift.TException
2832 chandransh 292
    {
4496 mandeep.dh 293
      send_getInventoryItem(serialNumber);
294
      return recv_getInventoryItem();
2832 chandransh 295
    }
296
 
4496 mandeep.dh 297
    public void send_getInventoryItem(String serialNumber) throws org.apache.thrift.TException
2832 chandransh 298
    {
4496 mandeep.dh 299
      getInventoryItem_args args = new getInventoryItem_args();
300
      args.setSerialNumber(serialNumber);
301
      sendBase("getInventoryItem", args);
2832 chandransh 302
    }
303
 
4541 mandeep.dh 304
    public InventoryItem recv_getInventoryItem() throws WarehouseServiceException, org.apache.thrift.TException
2832 chandransh 305
    {
4496 mandeep.dh 306
      getInventoryItem_result result = new getInventoryItem_result();
307
      receiveBase(result, "getInventoryItem");
2832 chandransh 308
      if (result.isSetSuccess()) {
309
        return result.success;
310
      }
4541 mandeep.dh 311
      if (result.wex != null) {
312
        throw result.wex;
313
      }
4496 mandeep.dh 314
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventoryItem failed: unknown result");
315
    }
316
 
5530 mandeep.dh 317
    public InventoryItem getNonSeralizedInventoryItem(String itemNumber, long itemId, long fulfilmentWarehouseId) throws WarehouseServiceException, org.apache.thrift.TException
4496 mandeep.dh 318
    {
5530 mandeep.dh 319
      send_getNonSeralizedInventoryItem(itemNumber, itemId, fulfilmentWarehouseId);
5361 mandeep.dh 320
      return recv_getNonSeralizedInventoryItem();
4496 mandeep.dh 321
    }
322
 
5530 mandeep.dh 323
    public void send_getNonSeralizedInventoryItem(String itemNumber, long itemId, long fulfilmentWarehouseId) throws org.apache.thrift.TException
4496 mandeep.dh 324
    {
5361 mandeep.dh 325
      getNonSeralizedInventoryItem_args args = new getNonSeralizedInventoryItem_args();
5530 mandeep.dh 326
      args.setItemNumber(itemNumber);
4496 mandeep.dh 327
      args.setItemId(itemId);
5530 mandeep.dh 328
      args.setFulfilmentWarehouseId(fulfilmentWarehouseId);
5361 mandeep.dh 329
      sendBase("getNonSeralizedInventoryItem", args);
4496 mandeep.dh 330
    }
331
 
5361 mandeep.dh 332
    public InventoryItem recv_getNonSeralizedInventoryItem() throws WarehouseServiceException, org.apache.thrift.TException
4496 mandeep.dh 333
    {
5361 mandeep.dh 334
      getNonSeralizedInventoryItem_result result = new getNonSeralizedInventoryItem_result();
335
      receiveBase(result, "getNonSeralizedInventoryItem");
4496 mandeep.dh 336
      if (result.isSetSuccess()) {
337
        return result.success;
2832 chandransh 338
      }
5361 mandeep.dh 339
      if (result.wex != null) {
340
        throw result.wex;
2820 chandransh 341
      }
5361 mandeep.dh 342
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getNonSeralizedInventoryItem failed: unknown result");
4496 mandeep.dh 343
    }
344
 
5361 mandeep.dh 345
    public void scan(InventoryItem inventoryItem, ScanType type, long quantity, long billingWarehouseId) throws WarehouseServiceException, org.apache.thrift.TException
2820 chandransh 346
    {
5361 mandeep.dh 347
      send_scan(inventoryItem, type, quantity, billingWarehouseId);
4496 mandeep.dh 348
      recv_scan();
3383 chandransh 349
    }
350
 
5361 mandeep.dh 351
    public void send_scan(InventoryItem inventoryItem, ScanType type, long quantity, long billingWarehouseId) throws org.apache.thrift.TException
3383 chandransh 352
    {
4496 mandeep.dh 353
      scan_args args = new scan_args();
5361 mandeep.dh 354
      args.setInventoryItem(inventoryItem);
4496 mandeep.dh 355
      args.setType(type);
356
      args.setQuantity(quantity);
5361 mandeep.dh 357
      args.setBillingWarehouseId(billingWarehouseId);
4496 mandeep.dh 358
      sendBase("scan", args);
3383 chandransh 359
    }
360
 
4496 mandeep.dh 361
    public void recv_scan() throws WarehouseServiceException, org.apache.thrift.TException
3383 chandransh 362
    {
4496 mandeep.dh 363
      scan_result result = new scan_result();
364
      receiveBase(result, "scan");
365
      if (result.wex != null) {
366
        throw result.wex;
367
      }
368
      return;
369
    }
370
 
5110 mandeep.dh 371
    public InventoryItem scanSerializedItemForOrder(String serialNumber, ScanType type, long orderId, long fulfilmentWarehouseId, double quantity, long billingWarehouseId) throws WarehouseServiceException, org.apache.thrift.TException
4496 mandeep.dh 372
    {
5110 mandeep.dh 373
      send_scanSerializedItemForOrder(serialNumber, type, orderId, fulfilmentWarehouseId, quantity, billingWarehouseId);
4496 mandeep.dh 374
      return recv_scanSerializedItemForOrder();
375
    }
376
 
5110 mandeep.dh 377
    public void send_scanSerializedItemForOrder(String serialNumber, ScanType type, long orderId, long fulfilmentWarehouseId, double quantity, long billingWarehouseId) throws org.apache.thrift.TException
4496 mandeep.dh 378
    {
379
      scanSerializedItemForOrder_args args = new scanSerializedItemForOrder_args();
4555 mandeep.dh 380
      args.setSerialNumber(serialNumber);
4496 mandeep.dh 381
      args.setType(type);
382
      args.setOrderId(orderId);
5110 mandeep.dh 383
      args.setFulfilmentWarehouseId(fulfilmentWarehouseId);
384
      args.setQuantity(quantity);
385
      args.setBillingWarehouseId(billingWarehouseId);
4496 mandeep.dh 386
      sendBase("scanSerializedItemForOrder", args);
387
    }
388
 
4555 mandeep.dh 389
    public InventoryItem recv_scanSerializedItemForOrder() throws WarehouseServiceException, org.apache.thrift.TException
4496 mandeep.dh 390
    {
391
      scanSerializedItemForOrder_result result = new scanSerializedItemForOrder_result();
392
      receiveBase(result, "scanSerializedItemForOrder");
3383 chandransh 393
      if (result.isSetSuccess()) {
394
        return result.success;
395
      }
396
      if (result.wex != null) {
397
        throw result.wex;
398
      }
4496 mandeep.dh 399
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "scanSerializedItemForOrder failed: unknown result");
3383 chandransh 400
    }
401
 
5361 mandeep.dh 402
    public InventoryItem scanForOrder(InventoryItem inventoryItem, ScanType type, long quantity, long orderId, long fulfilmentWarehouseId, long billingWarehouseId) throws WarehouseServiceException, org.apache.thrift.TException
3383 chandransh 403
    {
5361 mandeep.dh 404
      send_scanForOrder(inventoryItem, type, quantity, orderId, fulfilmentWarehouseId, billingWarehouseId);
405
      return recv_scanForOrder();
2820 chandransh 406
    }
407
 
5361 mandeep.dh 408
    public void send_scanForOrder(InventoryItem inventoryItem, ScanType type, long quantity, long orderId, long fulfilmentWarehouseId, long billingWarehouseId) throws org.apache.thrift.TException
2820 chandransh 409
    {
4496 mandeep.dh 410
      scanForOrder_args args = new scanForOrder_args();
5361 mandeep.dh 411
      args.setInventoryItem(inventoryItem);
3430 rajveer 412
      args.setType(type);
4496 mandeep.dh 413
      args.setQuantity(quantity);
414
      args.setOrderId(orderId);
5110 mandeep.dh 415
      args.setFulfilmentWarehouseId(fulfilmentWarehouseId);
5361 mandeep.dh 416
      args.setBillingWarehouseId(billingWarehouseId);
4496 mandeep.dh 417
      sendBase("scanForOrder", args);
2820 chandransh 418
    }
419
 
5361 mandeep.dh 420
    public InventoryItem recv_scanForOrder() throws WarehouseServiceException, org.apache.thrift.TException
2820 chandransh 421
    {
4496 mandeep.dh 422
      scanForOrder_result result = new scanForOrder_result();
423
      receiveBase(result, "scanForOrder");
5361 mandeep.dh 424
      if (result.isSetSuccess()) {
425
        return result.success;
426
      }
2820 chandransh 427
      if (result.wex != null) {
428
        throw result.wex;
429
      }
5361 mandeep.dh 430
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "scanForOrder failed: unknown result");
2820 chandransh 431
    }
432
 
4496 mandeep.dh 433
    public void createItemNumberMapping(String itemNumber, long itemId) throws org.apache.thrift.TException
2820 chandransh 434
    {
4496 mandeep.dh 435
      send_createItemNumberMapping(itemNumber, itemId);
436
      recv_createItemNumberMapping();
2820 chandransh 437
    }
438
 
4496 mandeep.dh 439
    public void send_createItemNumberMapping(String itemNumber, long itemId) throws org.apache.thrift.TException
2820 chandransh 440
    {
4496 mandeep.dh 441
      createItemNumberMapping_args args = new createItemNumberMapping_args();
3430 rajveer 442
      args.setItemNumber(itemNumber);
4496 mandeep.dh 443
      args.setItemId(itemId);
444
      sendBase("createItemNumberMapping", args);
2820 chandransh 445
    }
446
 
4496 mandeep.dh 447
    public void recv_createItemNumberMapping() throws org.apache.thrift.TException
2820 chandransh 448
    {
4496 mandeep.dh 449
      createItemNumberMapping_result result = new createItemNumberMapping_result();
450
      receiveBase(result, "createItemNumberMapping");
2820 chandransh 451
      return;
452
    }
453
 
4622 amit.gupta 454
    public List<String> getItemNumbers(long itemId) throws org.apache.thrift.TException
455
    {
456
      send_getItemNumbers(itemId);
457
      return recv_getItemNumbers();
458
    }
459
 
460
    public void send_getItemNumbers(long itemId) throws org.apache.thrift.TException
461
    {
462
      getItemNumbers_args args = new getItemNumbers_args();
463
      args.setItemId(itemId);
464
      sendBase("getItemNumbers", args);
465
    }
466
 
467
    public List<String> recv_getItemNumbers() throws org.apache.thrift.TException
468
    {
469
      getItemNumbers_result result = new getItemNumbers_result();
470
      receiveBase(result, "getItemNumbers");
471
      if (result.isSetSuccess()) {
472
        return result.success;
473
      }
474
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemNumbers failed: unknown result");
475
    }
476
 
5110 mandeep.dh 477
    public List<Long> getItemIds(String itemNumber) throws org.apache.thrift.TException
478
    {
479
      send_getItemIds(itemNumber);
480
      return recv_getItemIds();
481
    }
482
 
483
    public void send_getItemIds(String itemNumber) throws org.apache.thrift.TException
484
    {
485
      getItemIds_args args = new getItemIds_args();
486
      args.setItemNumber(itemNumber);
487
      sendBase("getItemIds", args);
488
    }
489
 
490
    public List<Long> recv_getItemIds() throws org.apache.thrift.TException
491
    {
492
      getItemIds_result result = new getItemIds_result();
493
      receiveBase(result, "getItemIds");
494
      if (result.isSetSuccess()) {
495
        return result.success;
496
      }
497
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemIds failed: unknown result");
498
    }
499
 
5185 mandeep.dh 500
    public List<InventoryItem> getInventoryItemsFromLastScanType(ScanType lastScanType) throws WarehouseServiceException, org.apache.thrift.TException
501
    {
502
      send_getInventoryItemsFromLastScanType(lastScanType);
503
      return recv_getInventoryItemsFromLastScanType();
504
    }
505
 
506
    public void send_getInventoryItemsFromLastScanType(ScanType lastScanType) throws org.apache.thrift.TException
507
    {
508
      getInventoryItemsFromLastScanType_args args = new getInventoryItemsFromLastScanType_args();
509
      args.setLastScanType(lastScanType);
510
      sendBase("getInventoryItemsFromLastScanType", args);
511
    }
512
 
513
    public List<InventoryItem> recv_getInventoryItemsFromLastScanType() throws WarehouseServiceException, org.apache.thrift.TException
514
    {
515
      getInventoryItemsFromLastScanType_result result = new getInventoryItemsFromLastScanType_result();
516
      receiveBase(result, "getInventoryItemsFromLastScanType");
517
      if (result.isSetSuccess()) {
518
        return result.success;
519
      }
520
      if (result.wex != null) {
521
        throw result.wex;
522
      }
523
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventoryItemsFromLastScanType failed: unknown result");
524
    }
525
 
526
    public InventoryItem getInventoryItemFromId(long inventoryItemId) throws WarehouseServiceException, org.apache.thrift.TException
527
    {
528
      send_getInventoryItemFromId(inventoryItemId);
529
      return recv_getInventoryItemFromId();
530
    }
531
 
532
    public void send_getInventoryItemFromId(long inventoryItemId) throws org.apache.thrift.TException
533
    {
534
      getInventoryItemFromId_args args = new getInventoryItemFromId_args();
535
      args.setInventoryItemId(inventoryItemId);
536
      sendBase("getInventoryItemFromId", args);
537
    }
538
 
539
    public InventoryItem recv_getInventoryItemFromId() throws WarehouseServiceException, org.apache.thrift.TException
540
    {
541
      getInventoryItemFromId_result result = new getInventoryItemFromId_result();
542
      receiveBase(result, "getInventoryItemFromId");
543
      if (result.isSetSuccess()) {
544
        return result.success;
545
      }
546
      if (result.wex != null) {
547
        throw result.wex;
548
      }
549
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventoryItemFromId failed: unknown result");
550
    }
551
 
5372 mandeep.dh 552
    public List<DetailedPurchaseScan> getPurchaseScans(long startDate, long endDate) throws org.apache.thrift.TException
553
    {
554
      send_getPurchaseScans(startDate, endDate);
555
      return recv_getPurchaseScans();
556
    }
557
 
558
    public void send_getPurchaseScans(long startDate, long endDate) throws org.apache.thrift.TException
559
    {
560
      getPurchaseScans_args args = new getPurchaseScans_args();
561
      args.setStartDate(startDate);
562
      args.setEndDate(endDate);
563
      sendBase("getPurchaseScans", args);
564
    }
565
 
566
    public List<DetailedPurchaseScan> recv_getPurchaseScans() throws org.apache.thrift.TException
567
    {
568
      getPurchaseScans_result result = new getPurchaseScans_result();
569
      receiveBase(result, "getPurchaseScans");
570
      if (result.isSetSuccess()) {
571
        return result.success;
572
      }
573
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPurchaseScans failed: unknown result");
574
    }
575
 
5496 mandeep.dh 576
    public List<InvoiceScan> fetchScansPerInvoiceNumber(long date) throws org.apache.thrift.TException
577
    {
578
      send_fetchScansPerInvoiceNumber(date);
579
      return recv_fetchScansPerInvoiceNumber();
580
    }
581
 
582
    public void send_fetchScansPerInvoiceNumber(long date) throws org.apache.thrift.TException
583
    {
584
      fetchScansPerInvoiceNumber_args args = new fetchScansPerInvoiceNumber_args();
585
      args.setDate(date);
586
      sendBase("fetchScansPerInvoiceNumber", args);
587
    }
588
 
589
    public List<InvoiceScan> recv_fetchScansPerInvoiceNumber() throws org.apache.thrift.TException
590
    {
591
      fetchScansPerInvoiceNumber_result result = new fetchScansPerInvoiceNumber_result();
592
      receiveBase(result, "fetchScansPerInvoiceNumber");
593
      if (result.isSetSuccess()) {
594
        return result.success;
595
      }
596
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "fetchScansPerInvoiceNumber failed: unknown result");
597
    }
598
 
5620 mandeep.dh 599
    public InventoryItem getInventoryItemFromOrder(long orderId) throws WarehouseServiceException, org.apache.thrift.TException
600
    {
601
      send_getInventoryItemFromOrder(orderId);
602
      return recv_getInventoryItemFromOrder();
603
    }
604
 
605
    public void send_getInventoryItemFromOrder(long orderId) throws org.apache.thrift.TException
606
    {
607
      getInventoryItemFromOrder_args args = new getInventoryItemFromOrder_args();
608
      args.setOrderId(orderId);
609
      sendBase("getInventoryItemFromOrder", args);
610
    }
611
 
612
    public InventoryItem recv_getInventoryItemFromOrder() throws WarehouseServiceException, org.apache.thrift.TException
613
    {
614
      getInventoryItemFromOrder_result result = new getInventoryItemFromOrder_result();
615
      receiveBase(result, "getInventoryItemFromOrder");
616
      if (result.isSetSuccess()) {
617
        return result.success;
618
      }
619
      if (result.we != null) {
620
        throw result.we;
621
      }
622
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventoryItemFromOrder failed: unknown result");
623
    }
624
 
5711 mandeep.dh 625
    public List<InventoryAge> getInventoryAge() throws org.apache.thrift.TException
626
    {
627
      send_getInventoryAge();
628
      return recv_getInventoryAge();
629
    }
630
 
631
    public void send_getInventoryAge() throws org.apache.thrift.TException
632
    {
633
      getInventoryAge_args args = new getInventoryAge_args();
634
      sendBase("getInventoryAge", args);
635
    }
636
 
637
    public List<InventoryAge> recv_getInventoryAge() throws org.apache.thrift.TException
638
    {
639
      getInventoryAge_result result = new getInventoryAge_result();
640
      receiveBase(result, "getInventoryAge");
641
      if (result.isSetSuccess()) {
642
        return result.success;
643
      }
644
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventoryAge failed: unknown result");
645
    }
646
 
6322 amar.kumar 647
    public List<Scan> getInventoryScansForItem(long itemId, long fromDate, long toDate) throws org.apache.thrift.TException
648
    {
649
      send_getInventoryScansForItem(itemId, fromDate, toDate);
650
      return recv_getInventoryScansForItem();
651
    }
652
 
653
    public void send_getInventoryScansForItem(long itemId, long fromDate, long toDate) throws org.apache.thrift.TException
654
    {
655
      getInventoryScansForItem_args args = new getInventoryScansForItem_args();
656
      args.setItemId(itemId);
657
      args.setFromDate(fromDate);
658
      args.setToDate(toDate);
659
      sendBase("getInventoryScansForItem", args);
660
    }
661
 
662
    public List<Scan> recv_getInventoryScansForItem() throws org.apache.thrift.TException
663
    {
664
      getInventoryScansForItem_result result = new getInventoryScansForItem_result();
665
      receiveBase(result, "getInventoryScansForItem");
666
      if (result.isSetSuccess()) {
667
        return result.success;
668
      }
669
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventoryScansForItem failed: unknown result");
670
    }
671
 
672
    public List<Scan> getScanRecordsForSerialNumber(long serialNumber) throws org.apache.thrift.TException
673
    {
674
      send_getScanRecordsForSerialNumber(serialNumber);
675
      return recv_getScanRecordsForSerialNumber();
676
    }
677
 
678
    public void send_getScanRecordsForSerialNumber(long serialNumber) throws org.apache.thrift.TException
679
    {
680
      getScanRecordsForSerialNumber_args args = new getScanRecordsForSerialNumber_args();
681
      args.setSerialNumber(serialNumber);
682
      sendBase("getScanRecordsForSerialNumber", args);
683
    }
684
 
685
    public List<Scan> recv_getScanRecordsForSerialNumber() throws org.apache.thrift.TException
686
    {
687
      getScanRecordsForSerialNumber_result result = new getScanRecordsForSerialNumber_result();
688
      receiveBase(result, "getScanRecordsForSerialNumber");
689
      if (result.isSetSuccess()) {
690
        return result.success;
691
      }
692
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getScanRecordsForSerialNumber failed: unknown result");
693
    }
694
 
6467 amar.kumar 695
    public void scanForPurchaseReturn(List<InventoryItem> saleReturnItems, long vendorId) throws WarehouseServiceException, org.apache.thrift.TException
696
    {
697
      send_scanForPurchaseReturn(saleReturnItems, vendorId);
698
      recv_scanForPurchaseReturn();
699
    }
700
 
701
    public void send_scanForPurchaseReturn(List<InventoryItem> saleReturnItems, long vendorId) throws org.apache.thrift.TException
702
    {
703
      scanForPurchaseReturn_args args = new scanForPurchaseReturn_args();
704
      args.setSaleReturnItems(saleReturnItems);
705
      args.setVendorId(vendorId);
706
      sendBase("scanForPurchaseReturn", args);
707
    }
708
 
709
    public void recv_scanForPurchaseReturn() throws WarehouseServiceException, org.apache.thrift.TException
710
    {
711
      scanForPurchaseReturn_result result = new scanForPurchaseReturn_result();
712
      receiveBase(result, "scanForPurchaseReturn");
713
      if (result.ex != null) {
714
        throw result.ex;
715
      }
716
      return;
717
    }
718
 
6548 amar.kumar 719
    public void scanForLostItem(List<InventoryItem> lostItems, long vendorId) throws WarehouseServiceException, org.apache.thrift.TException
720
    {
721
      send_scanForLostItem(lostItems, vendorId);
722
      recv_scanForLostItem();
723
    }
724
 
725
    public void send_scanForLostItem(List<InventoryItem> lostItems, long vendorId) throws org.apache.thrift.TException
726
    {
727
      scanForLostItem_args args = new scanForLostItem_args();
728
      args.setLostItems(lostItems);
729
      args.setVendorId(vendorId);
730
      sendBase("scanForLostItem", args);
731
    }
732
 
733
    public void recv_scanForLostItem() throws WarehouseServiceException, org.apache.thrift.TException
734
    {
735
      scanForLostItem_result result = new scanForLostItem_result();
736
      receiveBase(result, "scanForLostItem");
737
      if (result.ex != null) {
738
        throw result.ex;
739
      }
740
      return;
741
    }
742
 
743
    public List<InventoryAvailability> getCurrentSerializedInventoryByScans() throws org.apache.thrift.TException
744
    {
745
      send_getCurrentSerializedInventoryByScans();
746
      return recv_getCurrentSerializedInventoryByScans();
747
    }
748
 
749
    public void send_getCurrentSerializedInventoryByScans() throws org.apache.thrift.TException
750
    {
751
      getCurrentSerializedInventoryByScans_args args = new getCurrentSerializedInventoryByScans_args();
752
      sendBase("getCurrentSerializedInventoryByScans", args);
753
    }
754
 
755
    public List<InventoryAvailability> recv_getCurrentSerializedInventoryByScans() throws org.apache.thrift.TException
756
    {
757
      getCurrentSerializedInventoryByScans_result result = new getCurrentSerializedInventoryByScans_result();
758
      receiveBase(result, "getCurrentSerializedInventoryByScans");
759
      if (result.isSetSuccess()) {
760
        return result.success;
761
      }
762
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getCurrentSerializedInventoryByScans failed: unknown result");
763
    }
764
 
6630 amar.kumar 765
    public List<InventoryAvailability> getCurrentNonSerializedInventoryByScans() throws org.apache.thrift.TException
766
    {
767
      send_getCurrentNonSerializedInventoryByScans();
768
      return recv_getCurrentNonSerializedInventoryByScans();
769
    }
770
 
771
    public void send_getCurrentNonSerializedInventoryByScans() throws org.apache.thrift.TException
772
    {
773
      getCurrentNonSerializedInventoryByScans_args args = new getCurrentNonSerializedInventoryByScans_args();
774
      sendBase("getCurrentNonSerializedInventoryByScans", args);
775
    }
776
 
777
    public List<InventoryAvailability> recv_getCurrentNonSerializedInventoryByScans() throws org.apache.thrift.TException
778
    {
779
      getCurrentNonSerializedInventoryByScans_result result = new getCurrentNonSerializedInventoryByScans_result();
780
      receiveBase(result, "getCurrentNonSerializedInventoryByScans");
781
      if (result.isSetSuccess()) {
782
        return result.success;
783
      }
784
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getCurrentNonSerializedInventoryByScans failed: unknown result");
785
    }
786
 
6762 amar.kumar 787
    public List<InventoryAvailability> getHistoricSerializedInventoryByScans(long date) throws org.apache.thrift.TException
788
    {
789
      send_getHistoricSerializedInventoryByScans(date);
790
      return recv_getHistoricSerializedInventoryByScans();
791
    }
792
 
793
    public void send_getHistoricSerializedInventoryByScans(long date) throws org.apache.thrift.TException
794
    {
795
      getHistoricSerializedInventoryByScans_args args = new getHistoricSerializedInventoryByScans_args();
796
      args.setDate(date);
797
      sendBase("getHistoricSerializedInventoryByScans", args);
798
    }
799
 
800
    public List<InventoryAvailability> recv_getHistoricSerializedInventoryByScans() throws org.apache.thrift.TException
801
    {
802
      getHistoricSerializedInventoryByScans_result result = new getHistoricSerializedInventoryByScans_result();
803
      receiveBase(result, "getHistoricSerializedInventoryByScans");
804
      if (result.isSetSuccess()) {
805
        return result.success;
806
      }
807
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getHistoricSerializedInventoryByScans failed: unknown result");
808
    }
809
 
810
    public List<InventoryAvailability> getHistoricNonSerializedInventoryByScans(long date) throws org.apache.thrift.TException
811
    {
812
      send_getHistoricNonSerializedInventoryByScans(date);
813
      return recv_getHistoricNonSerializedInventoryByScans();
814
    }
815
 
816
    public void send_getHistoricNonSerializedInventoryByScans(long date) throws org.apache.thrift.TException
817
    {
818
      getHistoricNonSerializedInventoryByScans_args args = new getHistoricNonSerializedInventoryByScans_args();
819
      args.setDate(date);
820
      sendBase("getHistoricNonSerializedInventoryByScans", args);
821
    }
822
 
823
    public List<InventoryAvailability> recv_getHistoricNonSerializedInventoryByScans() throws org.apache.thrift.TException
824
    {
825
      getHistoricNonSerializedInventoryByScans_result result = new getHistoricNonSerializedInventoryByScans_result();
826
      receiveBase(result, "getHistoricNonSerializedInventoryByScans");
827
      if (result.isSetSuccess()) {
828
        return result.success;
829
      }
830
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getHistoricNonSerializedInventoryByScans failed: unknown result");
831
    }
832
 
833
    public InventoryItem scanForOursExternalSale(long itemId, String serialNumber, String itemNumber, String invoiceNumber, long warehouseId, double unitPrice, long orderId) throws WarehouseServiceException, org.apache.thrift.TException
834
    {
835
      send_scanForOursExternalSale(itemId, serialNumber, itemNumber, invoiceNumber, warehouseId, unitPrice, orderId);
836
      return recv_scanForOursExternalSale();
837
    }
838
 
839
    public void send_scanForOursExternalSale(long itemId, String serialNumber, String itemNumber, String invoiceNumber, long warehouseId, double unitPrice, long orderId) throws org.apache.thrift.TException
840
    {
841
      scanForOursExternalSale_args args = new scanForOursExternalSale_args();
842
      args.setItemId(itemId);
843
      args.setSerialNumber(serialNumber);
844
      args.setItemNumber(itemNumber);
845
      args.setInvoiceNumber(invoiceNumber);
846
      args.setWarehouseId(warehouseId);
847
      args.setUnitPrice(unitPrice);
848
      args.setOrderId(orderId);
849
      sendBase("scanForOursExternalSale", args);
850
    }
851
 
852
    public InventoryItem recv_scanForOursExternalSale() throws WarehouseServiceException, org.apache.thrift.TException
853
    {
854
      scanForOursExternalSale_result result = new scanForOursExternalSale_result();
855
      receiveBase(result, "scanForOursExternalSale");
856
      if (result.isSetSuccess()) {
857
        return result.success;
858
      }
859
      if (result.ex != null) {
860
        throw result.ex;
861
      }
862
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "scanForOursExternalSale failed: unknown result");
863
    }
864
 
865
    public void scanForOursExternalSaleReturn(long orderId, double unitPrice) throws org.apache.thrift.TException
866
    {
867
      send_scanForOursExternalSaleReturn(orderId, unitPrice);
868
      recv_scanForOursExternalSaleReturn();
869
    }
870
 
871
    public void send_scanForOursExternalSaleReturn(long orderId, double unitPrice) throws org.apache.thrift.TException
872
    {
873
      scanForOursExternalSaleReturn_args args = new scanForOursExternalSaleReturn_args();
874
      args.setOrderId(orderId);
875
      args.setUnitPrice(unitPrice);
876
      sendBase("scanForOursExternalSaleReturn", args);
877
    }
878
 
879
    public void recv_scanForOursExternalSaleReturn() throws org.apache.thrift.TException
880
    {
881
      scanForOursExternalSaleReturn_result result = new scanForOursExternalSaleReturn_result();
882
      receiveBase(result, "scanForOursExternalSaleReturn");
883
      return;
884
    }
885
 
2820 chandransh 886
  }
3430 rajveer 887
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
888
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
889
      private org.apache.thrift.async.TAsyncClientManager clientManager;
890
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
891
      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
892
        this.clientManager = clientManager;
893
        this.protocolFactory = protocolFactory;
894
      }
895
      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
896
        return new AsyncClient(protocolFactory, clientManager, transport);
897
      }
2820 chandransh 898
    }
899
 
3430 rajveer 900
    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
901
      super(protocolFactory, clientManager, transport);
902
    }
2820 chandransh 903
 
4496 mandeep.dh 904
    public void getInventoryItem(String serialNumber, org.apache.thrift.async.AsyncMethodCallback<getInventoryItem_call> resultHandler) throws org.apache.thrift.TException {
3430 rajveer 905
      checkReady();
4496 mandeep.dh 906
      getInventoryItem_call method_call = new getInventoryItem_call(serialNumber, resultHandler, this, ___protocolFactory, ___transport);
3430 rajveer 907
      this.___currentMethod = method_call;
908
      ___manager.call(method_call);
909
    }
910
 
4496 mandeep.dh 911
    public static class getInventoryItem_call extends org.apache.thrift.async.TAsyncMethodCall {
912
      private String serialNumber;
913
      public getInventoryItem_call(String serialNumber, org.apache.thrift.async.AsyncMethodCallback<getInventoryItem_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
3430 rajveer 914
        super(client, protocolFactory, transport, resultHandler, false);
4496 mandeep.dh 915
        this.serialNumber = serialNumber;
3430 rajveer 916
      }
917
 
918
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
4496 mandeep.dh 919
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventoryItem", org.apache.thrift.protocol.TMessageType.CALL, 0));
920
        getInventoryItem_args args = new getInventoryItem_args();
921
        args.setSerialNumber(serialNumber);
3430 rajveer 922
        args.write(prot);
923
        prot.writeMessageEnd();
924
      }
925
 
4541 mandeep.dh 926
      public InventoryItem getResult() throws WarehouseServiceException, org.apache.thrift.TException {
3430 rajveer 927
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
928
          throw new IllegalStateException("Method call not finished!");
929
        }
930
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
931
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
4496 mandeep.dh 932
        return (new Client(prot)).recv_getInventoryItem();
3430 rajveer 933
      }
934
    }
935
 
5530 mandeep.dh 936
    public void getNonSeralizedInventoryItem(String itemNumber, long itemId, long fulfilmentWarehouseId, org.apache.thrift.async.AsyncMethodCallback<getNonSeralizedInventoryItem_call> resultHandler) throws org.apache.thrift.TException {
3430 rajveer 937
      checkReady();
5530 mandeep.dh 938
      getNonSeralizedInventoryItem_call method_call = new getNonSeralizedInventoryItem_call(itemNumber, itemId, fulfilmentWarehouseId, resultHandler, this, ___protocolFactory, ___transport);
3430 rajveer 939
      this.___currentMethod = method_call;
940
      ___manager.call(method_call);
941
    }
942
 
5361 mandeep.dh 943
    public static class getNonSeralizedInventoryItem_call extends org.apache.thrift.async.TAsyncMethodCall {
5530 mandeep.dh 944
      private String itemNumber;
4496 mandeep.dh 945
      private long itemId;
5530 mandeep.dh 946
      private long fulfilmentWarehouseId;
947
      public getNonSeralizedInventoryItem_call(String itemNumber, long itemId, long fulfilmentWarehouseId, org.apache.thrift.async.AsyncMethodCallback<getNonSeralizedInventoryItem_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
3430 rajveer 948
        super(client, protocolFactory, transport, resultHandler, false);
5530 mandeep.dh 949
        this.itemNumber = itemNumber;
4496 mandeep.dh 950
        this.itemId = itemId;
5530 mandeep.dh 951
        this.fulfilmentWarehouseId = fulfilmentWarehouseId;
3430 rajveer 952
      }
953
 
954
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
5361 mandeep.dh 955
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getNonSeralizedInventoryItem", org.apache.thrift.protocol.TMessageType.CALL, 0));
956
        getNonSeralizedInventoryItem_args args = new getNonSeralizedInventoryItem_args();
5530 mandeep.dh 957
        args.setItemNumber(itemNumber);
4496 mandeep.dh 958
        args.setItemId(itemId);
5530 mandeep.dh 959
        args.setFulfilmentWarehouseId(fulfilmentWarehouseId);
3430 rajveer 960
        args.write(prot);
961
        prot.writeMessageEnd();
962
      }
963
 
5361 mandeep.dh 964
      public InventoryItem getResult() throws WarehouseServiceException, org.apache.thrift.TException {
3430 rajveer 965
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
966
          throw new IllegalStateException("Method call not finished!");
967
        }
968
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
969
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
5361 mandeep.dh 970
        return (new Client(prot)).recv_getNonSeralizedInventoryItem();
3430 rajveer 971
      }
972
    }
973
 
5361 mandeep.dh 974
    public void scan(InventoryItem inventoryItem, ScanType type, long quantity, long billingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<scan_call> resultHandler) throws org.apache.thrift.TException {
3430 rajveer 975
      checkReady();
5361 mandeep.dh 976
      scan_call method_call = new scan_call(inventoryItem, type, quantity, billingWarehouseId, resultHandler, this, ___protocolFactory, ___transport);
3430 rajveer 977
      this.___currentMethod = method_call;
978
      ___manager.call(method_call);
979
    }
980
 
4496 mandeep.dh 981
    public static class scan_call extends org.apache.thrift.async.TAsyncMethodCall {
5361 mandeep.dh 982
      private InventoryItem inventoryItem;
3430 rajveer 983
      private ScanType type;
4496 mandeep.dh 984
      private long quantity;
5361 mandeep.dh 985
      private long billingWarehouseId;
986
      public scan_call(InventoryItem inventoryItem, ScanType type, long quantity, long billingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<scan_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
3430 rajveer 987
        super(client, protocolFactory, transport, resultHandler, false);
5361 mandeep.dh 988
        this.inventoryItem = inventoryItem;
3430 rajveer 989
        this.type = type;
4496 mandeep.dh 990
        this.quantity = quantity;
5361 mandeep.dh 991
        this.billingWarehouseId = billingWarehouseId;
3430 rajveer 992
      }
993
 
994
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
4496 mandeep.dh 995
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("scan", org.apache.thrift.protocol.TMessageType.CALL, 0));
996
        scan_args args = new scan_args();
5361 mandeep.dh 997
        args.setInventoryItem(inventoryItem);
3430 rajveer 998
        args.setType(type);
4496 mandeep.dh 999
        args.setQuantity(quantity);
5361 mandeep.dh 1000
        args.setBillingWarehouseId(billingWarehouseId);
3430 rajveer 1001
        args.write(prot);
1002
        prot.writeMessageEnd();
1003
      }
1004
 
1005
      public void getResult() throws WarehouseServiceException, org.apache.thrift.TException {
1006
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1007
          throw new IllegalStateException("Method call not finished!");
1008
        }
1009
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1010
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
4496 mandeep.dh 1011
        (new Client(prot)).recv_scan();
3430 rajveer 1012
      }
1013
    }
1014
 
5110 mandeep.dh 1015
    public void scanSerializedItemForOrder(String serialNumber, ScanType type, long orderId, long fulfilmentWarehouseId, double quantity, long billingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<scanSerializedItemForOrder_call> resultHandler) throws org.apache.thrift.TException {
4496 mandeep.dh 1016
      checkReady();
5110 mandeep.dh 1017
      scanSerializedItemForOrder_call method_call = new scanSerializedItemForOrder_call(serialNumber, type, orderId, fulfilmentWarehouseId, quantity, billingWarehouseId, resultHandler, this, ___protocolFactory, ___transport);
4496 mandeep.dh 1018
      this.___currentMethod = method_call;
1019
      ___manager.call(method_call);
1020
    }
1021
 
1022
    public static class scanSerializedItemForOrder_call extends org.apache.thrift.async.TAsyncMethodCall {
4555 mandeep.dh 1023
      private String serialNumber;
4496 mandeep.dh 1024
      private ScanType type;
1025
      private long orderId;
5110 mandeep.dh 1026
      private long fulfilmentWarehouseId;
1027
      private double quantity;
1028
      private long billingWarehouseId;
1029
      public scanSerializedItemForOrder_call(String serialNumber, ScanType type, long orderId, long fulfilmentWarehouseId, double quantity, long billingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<scanSerializedItemForOrder_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
4496 mandeep.dh 1030
        super(client, protocolFactory, transport, resultHandler, false);
4555 mandeep.dh 1031
        this.serialNumber = serialNumber;
4496 mandeep.dh 1032
        this.type = type;
1033
        this.orderId = orderId;
5110 mandeep.dh 1034
        this.fulfilmentWarehouseId = fulfilmentWarehouseId;
1035
        this.quantity = quantity;
1036
        this.billingWarehouseId = billingWarehouseId;
4496 mandeep.dh 1037
      }
1038
 
1039
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1040
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("scanSerializedItemForOrder", org.apache.thrift.protocol.TMessageType.CALL, 0));
1041
        scanSerializedItemForOrder_args args = new scanSerializedItemForOrder_args();
4555 mandeep.dh 1042
        args.setSerialNumber(serialNumber);
4496 mandeep.dh 1043
        args.setType(type);
1044
        args.setOrderId(orderId);
5110 mandeep.dh 1045
        args.setFulfilmentWarehouseId(fulfilmentWarehouseId);
1046
        args.setQuantity(quantity);
1047
        args.setBillingWarehouseId(billingWarehouseId);
4496 mandeep.dh 1048
        args.write(prot);
1049
        prot.writeMessageEnd();
1050
      }
1051
 
4555 mandeep.dh 1052
      public InventoryItem getResult() throws WarehouseServiceException, org.apache.thrift.TException {
4496 mandeep.dh 1053
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1054
          throw new IllegalStateException("Method call not finished!");
1055
        }
1056
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1057
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1058
        return (new Client(prot)).recv_scanSerializedItemForOrder();
1059
      }
1060
    }
1061
 
5361 mandeep.dh 1062
    public void scanForOrder(InventoryItem inventoryItem, ScanType type, long quantity, long orderId, long fulfilmentWarehouseId, long billingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<scanForOrder_call> resultHandler) throws org.apache.thrift.TException {
4496 mandeep.dh 1063
      checkReady();
5361 mandeep.dh 1064
      scanForOrder_call method_call = new scanForOrder_call(inventoryItem, type, quantity, orderId, fulfilmentWarehouseId, billingWarehouseId, resultHandler, this, ___protocolFactory, ___transport);
4496 mandeep.dh 1065
      this.___currentMethod = method_call;
1066
      ___manager.call(method_call);
1067
    }
1068
 
1069
    public static class scanForOrder_call extends org.apache.thrift.async.TAsyncMethodCall {
5361 mandeep.dh 1070
      private InventoryItem inventoryItem;
4496 mandeep.dh 1071
      private ScanType type;
1072
      private long quantity;
1073
      private long orderId;
5110 mandeep.dh 1074
      private long fulfilmentWarehouseId;
5361 mandeep.dh 1075
      private long billingWarehouseId;
1076
      public scanForOrder_call(InventoryItem inventoryItem, ScanType type, long quantity, long orderId, long fulfilmentWarehouseId, long billingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<scanForOrder_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
4496 mandeep.dh 1077
        super(client, protocolFactory, transport, resultHandler, false);
5361 mandeep.dh 1078
        this.inventoryItem = inventoryItem;
4496 mandeep.dh 1079
        this.type = type;
1080
        this.quantity = quantity;
1081
        this.orderId = orderId;
5110 mandeep.dh 1082
        this.fulfilmentWarehouseId = fulfilmentWarehouseId;
5361 mandeep.dh 1083
        this.billingWarehouseId = billingWarehouseId;
4496 mandeep.dh 1084
      }
1085
 
1086
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1087
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("scanForOrder", org.apache.thrift.protocol.TMessageType.CALL, 0));
1088
        scanForOrder_args args = new scanForOrder_args();
5361 mandeep.dh 1089
        args.setInventoryItem(inventoryItem);
4496 mandeep.dh 1090
        args.setType(type);
1091
        args.setQuantity(quantity);
1092
        args.setOrderId(orderId);
5110 mandeep.dh 1093
        args.setFulfilmentWarehouseId(fulfilmentWarehouseId);
5361 mandeep.dh 1094
        args.setBillingWarehouseId(billingWarehouseId);
4496 mandeep.dh 1095
        args.write(prot);
1096
        prot.writeMessageEnd();
1097
      }
1098
 
5361 mandeep.dh 1099
      public InventoryItem getResult() throws WarehouseServiceException, org.apache.thrift.TException {
4496 mandeep.dh 1100
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1101
          throw new IllegalStateException("Method call not finished!");
1102
        }
1103
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1104
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
5361 mandeep.dh 1105
        return (new Client(prot)).recv_scanForOrder();
4496 mandeep.dh 1106
      }
1107
    }
1108
 
1109
    public void createItemNumberMapping(String itemNumber, long itemId, org.apache.thrift.async.AsyncMethodCallback<createItemNumberMapping_call> resultHandler) throws org.apache.thrift.TException {
1110
      checkReady();
1111
      createItemNumberMapping_call method_call = new createItemNumberMapping_call(itemNumber, itemId, resultHandler, this, ___protocolFactory, ___transport);
1112
      this.___currentMethod = method_call;
1113
      ___manager.call(method_call);
1114
    }
1115
 
1116
    public static class createItemNumberMapping_call extends org.apache.thrift.async.TAsyncMethodCall {
1117
      private String itemNumber;
1118
      private long itemId;
1119
      public createItemNumberMapping_call(String itemNumber, long itemId, org.apache.thrift.async.AsyncMethodCallback<createItemNumberMapping_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1120
        super(client, protocolFactory, transport, resultHandler, false);
1121
        this.itemNumber = itemNumber;
1122
        this.itemId = itemId;
1123
      }
1124
 
1125
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1126
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("createItemNumberMapping", org.apache.thrift.protocol.TMessageType.CALL, 0));
1127
        createItemNumberMapping_args args = new createItemNumberMapping_args();
1128
        args.setItemNumber(itemNumber);
1129
        args.setItemId(itemId);
1130
        args.write(prot);
1131
        prot.writeMessageEnd();
1132
      }
1133
 
1134
      public void getResult() throws org.apache.thrift.TException {
1135
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1136
          throw new IllegalStateException("Method call not finished!");
1137
        }
1138
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1139
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1140
        (new Client(prot)).recv_createItemNumberMapping();
1141
      }
1142
    }
1143
 
4622 amit.gupta 1144
    public void getItemNumbers(long itemId, org.apache.thrift.async.AsyncMethodCallback<getItemNumbers_call> resultHandler) throws org.apache.thrift.TException {
1145
      checkReady();
1146
      getItemNumbers_call method_call = new getItemNumbers_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1147
      this.___currentMethod = method_call;
1148
      ___manager.call(method_call);
1149
    }
1150
 
1151
    public static class getItemNumbers_call extends org.apache.thrift.async.TAsyncMethodCall {
1152
      private long itemId;
1153
      public getItemNumbers_call(long itemId, org.apache.thrift.async.AsyncMethodCallback<getItemNumbers_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1154
        super(client, protocolFactory, transport, resultHandler, false);
1155
        this.itemId = itemId;
1156
      }
1157
 
1158
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1159
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemNumbers", org.apache.thrift.protocol.TMessageType.CALL, 0));
1160
        getItemNumbers_args args = new getItemNumbers_args();
1161
        args.setItemId(itemId);
1162
        args.write(prot);
1163
        prot.writeMessageEnd();
1164
      }
1165
 
1166
      public List<String> getResult() throws org.apache.thrift.TException {
1167
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1168
          throw new IllegalStateException("Method call not finished!");
1169
        }
1170
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1171
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1172
        return (new Client(prot)).recv_getItemNumbers();
1173
      }
1174
    }
1175
 
5110 mandeep.dh 1176
    public void getItemIds(String itemNumber, org.apache.thrift.async.AsyncMethodCallback<getItemIds_call> resultHandler) throws org.apache.thrift.TException {
1177
      checkReady();
1178
      getItemIds_call method_call = new getItemIds_call(itemNumber, resultHandler, this, ___protocolFactory, ___transport);
1179
      this.___currentMethod = method_call;
1180
      ___manager.call(method_call);
1181
    }
1182
 
1183
    public static class getItemIds_call extends org.apache.thrift.async.TAsyncMethodCall {
1184
      private String itemNumber;
1185
      public getItemIds_call(String itemNumber, org.apache.thrift.async.AsyncMethodCallback<getItemIds_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1186
        super(client, protocolFactory, transport, resultHandler, false);
1187
        this.itemNumber = itemNumber;
1188
      }
1189
 
1190
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1191
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemIds", org.apache.thrift.protocol.TMessageType.CALL, 0));
1192
        getItemIds_args args = new getItemIds_args();
1193
        args.setItemNumber(itemNumber);
1194
        args.write(prot);
1195
        prot.writeMessageEnd();
1196
      }
1197
 
1198
      public List<Long> getResult() throws org.apache.thrift.TException {
1199
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1200
          throw new IllegalStateException("Method call not finished!");
1201
        }
1202
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1203
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1204
        return (new Client(prot)).recv_getItemIds();
1205
      }
1206
    }
1207
 
5185 mandeep.dh 1208
    public void getInventoryItemsFromLastScanType(ScanType lastScanType, org.apache.thrift.async.AsyncMethodCallback<getInventoryItemsFromLastScanType_call> resultHandler) throws org.apache.thrift.TException {
1209
      checkReady();
1210
      getInventoryItemsFromLastScanType_call method_call = new getInventoryItemsFromLastScanType_call(lastScanType, resultHandler, this, ___protocolFactory, ___transport);
1211
      this.___currentMethod = method_call;
1212
      ___manager.call(method_call);
1213
    }
1214
 
1215
    public static class getInventoryItemsFromLastScanType_call extends org.apache.thrift.async.TAsyncMethodCall {
1216
      private ScanType lastScanType;
1217
      public getInventoryItemsFromLastScanType_call(ScanType lastScanType, org.apache.thrift.async.AsyncMethodCallback<getInventoryItemsFromLastScanType_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1218
        super(client, protocolFactory, transport, resultHandler, false);
1219
        this.lastScanType = lastScanType;
1220
      }
1221
 
1222
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1223
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventoryItemsFromLastScanType", org.apache.thrift.protocol.TMessageType.CALL, 0));
1224
        getInventoryItemsFromLastScanType_args args = new getInventoryItemsFromLastScanType_args();
1225
        args.setLastScanType(lastScanType);
1226
        args.write(prot);
1227
        prot.writeMessageEnd();
1228
      }
1229
 
1230
      public List<InventoryItem> getResult() throws WarehouseServiceException, org.apache.thrift.TException {
1231
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1232
          throw new IllegalStateException("Method call not finished!");
1233
        }
1234
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1235
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1236
        return (new Client(prot)).recv_getInventoryItemsFromLastScanType();
1237
      }
1238
    }
1239
 
1240
    public void getInventoryItemFromId(long inventoryItemId, org.apache.thrift.async.AsyncMethodCallback<getInventoryItemFromId_call> resultHandler) throws org.apache.thrift.TException {
1241
      checkReady();
1242
      getInventoryItemFromId_call method_call = new getInventoryItemFromId_call(inventoryItemId, resultHandler, this, ___protocolFactory, ___transport);
1243
      this.___currentMethod = method_call;
1244
      ___manager.call(method_call);
1245
    }
1246
 
1247
    public static class getInventoryItemFromId_call extends org.apache.thrift.async.TAsyncMethodCall {
1248
      private long inventoryItemId;
1249
      public getInventoryItemFromId_call(long inventoryItemId, org.apache.thrift.async.AsyncMethodCallback<getInventoryItemFromId_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1250
        super(client, protocolFactory, transport, resultHandler, false);
1251
        this.inventoryItemId = inventoryItemId;
1252
      }
1253
 
1254
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1255
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventoryItemFromId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1256
        getInventoryItemFromId_args args = new getInventoryItemFromId_args();
1257
        args.setInventoryItemId(inventoryItemId);
1258
        args.write(prot);
1259
        prot.writeMessageEnd();
1260
      }
1261
 
1262
      public InventoryItem getResult() throws WarehouseServiceException, org.apache.thrift.TException {
1263
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1264
          throw new IllegalStateException("Method call not finished!");
1265
        }
1266
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1267
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1268
        return (new Client(prot)).recv_getInventoryItemFromId();
1269
      }
1270
    }
1271
 
5372 mandeep.dh 1272
    public void getPurchaseScans(long startDate, long endDate, org.apache.thrift.async.AsyncMethodCallback<getPurchaseScans_call> resultHandler) throws org.apache.thrift.TException {
1273
      checkReady();
1274
      getPurchaseScans_call method_call = new getPurchaseScans_call(startDate, endDate, resultHandler, this, ___protocolFactory, ___transport);
1275
      this.___currentMethod = method_call;
1276
      ___manager.call(method_call);
1277
    }
1278
 
1279
    public static class getPurchaseScans_call extends org.apache.thrift.async.TAsyncMethodCall {
1280
      private long startDate;
1281
      private long endDate;
1282
      public getPurchaseScans_call(long startDate, long endDate, org.apache.thrift.async.AsyncMethodCallback<getPurchaseScans_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1283
        super(client, protocolFactory, transport, resultHandler, false);
1284
        this.startDate = startDate;
1285
        this.endDate = endDate;
1286
      }
1287
 
1288
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1289
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPurchaseScans", org.apache.thrift.protocol.TMessageType.CALL, 0));
1290
        getPurchaseScans_args args = new getPurchaseScans_args();
1291
        args.setStartDate(startDate);
1292
        args.setEndDate(endDate);
1293
        args.write(prot);
1294
        prot.writeMessageEnd();
1295
      }
1296
 
1297
      public List<DetailedPurchaseScan> getResult() throws org.apache.thrift.TException {
1298
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1299
          throw new IllegalStateException("Method call not finished!");
1300
        }
1301
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1302
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1303
        return (new Client(prot)).recv_getPurchaseScans();
1304
      }
1305
    }
1306
 
5496 mandeep.dh 1307
    public void fetchScansPerInvoiceNumber(long date, org.apache.thrift.async.AsyncMethodCallback<fetchScansPerInvoiceNumber_call> resultHandler) throws org.apache.thrift.TException {
1308
      checkReady();
1309
      fetchScansPerInvoiceNumber_call method_call = new fetchScansPerInvoiceNumber_call(date, resultHandler, this, ___protocolFactory, ___transport);
1310
      this.___currentMethod = method_call;
1311
      ___manager.call(method_call);
1312
    }
1313
 
1314
    public static class fetchScansPerInvoiceNumber_call extends org.apache.thrift.async.TAsyncMethodCall {
1315
      private long date;
1316
      public fetchScansPerInvoiceNumber_call(long date, org.apache.thrift.async.AsyncMethodCallback<fetchScansPerInvoiceNumber_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1317
        super(client, protocolFactory, transport, resultHandler, false);
1318
        this.date = date;
1319
      }
1320
 
1321
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1322
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("fetchScansPerInvoiceNumber", org.apache.thrift.protocol.TMessageType.CALL, 0));
1323
        fetchScansPerInvoiceNumber_args args = new fetchScansPerInvoiceNumber_args();
1324
        args.setDate(date);
1325
        args.write(prot);
1326
        prot.writeMessageEnd();
1327
      }
1328
 
1329
      public List<InvoiceScan> getResult() throws org.apache.thrift.TException {
1330
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1331
          throw new IllegalStateException("Method call not finished!");
1332
        }
1333
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1334
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1335
        return (new Client(prot)).recv_fetchScansPerInvoiceNumber();
1336
      }
1337
    }
1338
 
5620 mandeep.dh 1339
    public void getInventoryItemFromOrder(long orderId, org.apache.thrift.async.AsyncMethodCallback<getInventoryItemFromOrder_call> resultHandler) throws org.apache.thrift.TException {
1340
      checkReady();
1341
      getInventoryItemFromOrder_call method_call = new getInventoryItemFromOrder_call(orderId, resultHandler, this, ___protocolFactory, ___transport);
1342
      this.___currentMethod = method_call;
1343
      ___manager.call(method_call);
1344
    }
1345
 
1346
    public static class getInventoryItemFromOrder_call extends org.apache.thrift.async.TAsyncMethodCall {
1347
      private long orderId;
1348
      public getInventoryItemFromOrder_call(long orderId, org.apache.thrift.async.AsyncMethodCallback<getInventoryItemFromOrder_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1349
        super(client, protocolFactory, transport, resultHandler, false);
1350
        this.orderId = orderId;
1351
      }
1352
 
1353
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1354
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventoryItemFromOrder", org.apache.thrift.protocol.TMessageType.CALL, 0));
1355
        getInventoryItemFromOrder_args args = new getInventoryItemFromOrder_args();
1356
        args.setOrderId(orderId);
1357
        args.write(prot);
1358
        prot.writeMessageEnd();
1359
      }
1360
 
1361
      public InventoryItem getResult() throws WarehouseServiceException, org.apache.thrift.TException {
1362
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1363
          throw new IllegalStateException("Method call not finished!");
1364
        }
1365
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1366
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1367
        return (new Client(prot)).recv_getInventoryItemFromOrder();
1368
      }
1369
    }
1370
 
5711 mandeep.dh 1371
    public void getInventoryAge(org.apache.thrift.async.AsyncMethodCallback<getInventoryAge_call> resultHandler) throws org.apache.thrift.TException {
1372
      checkReady();
1373
      getInventoryAge_call method_call = new getInventoryAge_call(resultHandler, this, ___protocolFactory, ___transport);
1374
      this.___currentMethod = method_call;
1375
      ___manager.call(method_call);
1376
    }
1377
 
1378
    public static class getInventoryAge_call extends org.apache.thrift.async.TAsyncMethodCall {
1379
      public getInventoryAge_call(org.apache.thrift.async.AsyncMethodCallback<getInventoryAge_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1380
        super(client, protocolFactory, transport, resultHandler, false);
1381
      }
1382
 
1383
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1384
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventoryAge", org.apache.thrift.protocol.TMessageType.CALL, 0));
1385
        getInventoryAge_args args = new getInventoryAge_args();
1386
        args.write(prot);
1387
        prot.writeMessageEnd();
1388
      }
1389
 
1390
      public List<InventoryAge> getResult() throws org.apache.thrift.TException {
1391
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1392
          throw new IllegalStateException("Method call not finished!");
1393
        }
1394
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1395
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1396
        return (new Client(prot)).recv_getInventoryAge();
1397
      }
1398
    }
1399
 
6322 amar.kumar 1400
    public void getInventoryScansForItem(long itemId, long fromDate, long toDate, org.apache.thrift.async.AsyncMethodCallback<getInventoryScansForItem_call> resultHandler) throws org.apache.thrift.TException {
1401
      checkReady();
1402
      getInventoryScansForItem_call method_call = new getInventoryScansForItem_call(itemId, fromDate, toDate, resultHandler, this, ___protocolFactory, ___transport);
1403
      this.___currentMethod = method_call;
1404
      ___manager.call(method_call);
1405
    }
1406
 
1407
    public static class getInventoryScansForItem_call extends org.apache.thrift.async.TAsyncMethodCall {
1408
      private long itemId;
1409
      private long fromDate;
1410
      private long toDate;
1411
      public getInventoryScansForItem_call(long itemId, long fromDate, long toDate, org.apache.thrift.async.AsyncMethodCallback<getInventoryScansForItem_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1412
        super(client, protocolFactory, transport, resultHandler, false);
1413
        this.itemId = itemId;
1414
        this.fromDate = fromDate;
1415
        this.toDate = toDate;
1416
      }
1417
 
1418
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1419
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventoryScansForItem", org.apache.thrift.protocol.TMessageType.CALL, 0));
1420
        getInventoryScansForItem_args args = new getInventoryScansForItem_args();
1421
        args.setItemId(itemId);
1422
        args.setFromDate(fromDate);
1423
        args.setToDate(toDate);
1424
        args.write(prot);
1425
        prot.writeMessageEnd();
1426
      }
1427
 
1428
      public List<Scan> getResult() throws org.apache.thrift.TException {
1429
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1430
          throw new IllegalStateException("Method call not finished!");
1431
        }
1432
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1433
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1434
        return (new Client(prot)).recv_getInventoryScansForItem();
1435
      }
1436
    }
1437
 
1438
    public void getScanRecordsForSerialNumber(long serialNumber, org.apache.thrift.async.AsyncMethodCallback<getScanRecordsForSerialNumber_call> resultHandler) throws org.apache.thrift.TException {
1439
      checkReady();
1440
      getScanRecordsForSerialNumber_call method_call = new getScanRecordsForSerialNumber_call(serialNumber, resultHandler, this, ___protocolFactory, ___transport);
1441
      this.___currentMethod = method_call;
1442
      ___manager.call(method_call);
1443
    }
1444
 
1445
    public static class getScanRecordsForSerialNumber_call extends org.apache.thrift.async.TAsyncMethodCall {
1446
      private long serialNumber;
1447
      public getScanRecordsForSerialNumber_call(long serialNumber, org.apache.thrift.async.AsyncMethodCallback<getScanRecordsForSerialNumber_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1448
        super(client, protocolFactory, transport, resultHandler, false);
1449
        this.serialNumber = serialNumber;
1450
      }
1451
 
1452
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1453
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getScanRecordsForSerialNumber", org.apache.thrift.protocol.TMessageType.CALL, 0));
1454
        getScanRecordsForSerialNumber_args args = new getScanRecordsForSerialNumber_args();
1455
        args.setSerialNumber(serialNumber);
1456
        args.write(prot);
1457
        prot.writeMessageEnd();
1458
      }
1459
 
1460
      public List<Scan> getResult() throws org.apache.thrift.TException {
1461
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1462
          throw new IllegalStateException("Method call not finished!");
1463
        }
1464
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1465
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1466
        return (new Client(prot)).recv_getScanRecordsForSerialNumber();
1467
      }
1468
    }
1469
 
6467 amar.kumar 1470
    public void scanForPurchaseReturn(List<InventoryItem> saleReturnItems, long vendorId, org.apache.thrift.async.AsyncMethodCallback<scanForPurchaseReturn_call> resultHandler) throws org.apache.thrift.TException {
1471
      checkReady();
1472
      scanForPurchaseReturn_call method_call = new scanForPurchaseReturn_call(saleReturnItems, vendorId, resultHandler, this, ___protocolFactory, ___transport);
1473
      this.___currentMethod = method_call;
1474
      ___manager.call(method_call);
1475
    }
1476
 
1477
    public static class scanForPurchaseReturn_call extends org.apache.thrift.async.TAsyncMethodCall {
1478
      private List<InventoryItem> saleReturnItems;
1479
      private long vendorId;
1480
      public scanForPurchaseReturn_call(List<InventoryItem> saleReturnItems, long vendorId, org.apache.thrift.async.AsyncMethodCallback<scanForPurchaseReturn_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1481
        super(client, protocolFactory, transport, resultHandler, false);
1482
        this.saleReturnItems = saleReturnItems;
1483
        this.vendorId = vendorId;
1484
      }
1485
 
1486
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1487
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("scanForPurchaseReturn", org.apache.thrift.protocol.TMessageType.CALL, 0));
1488
        scanForPurchaseReturn_args args = new scanForPurchaseReturn_args();
1489
        args.setSaleReturnItems(saleReturnItems);
1490
        args.setVendorId(vendorId);
1491
        args.write(prot);
1492
        prot.writeMessageEnd();
1493
      }
1494
 
1495
      public void getResult() throws WarehouseServiceException, org.apache.thrift.TException {
1496
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1497
          throw new IllegalStateException("Method call not finished!");
1498
        }
1499
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1500
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1501
        (new Client(prot)).recv_scanForPurchaseReturn();
1502
      }
1503
    }
1504
 
6548 amar.kumar 1505
    public void scanForLostItem(List<InventoryItem> lostItems, long vendorId, org.apache.thrift.async.AsyncMethodCallback<scanForLostItem_call> resultHandler) throws org.apache.thrift.TException {
1506
      checkReady();
1507
      scanForLostItem_call method_call = new scanForLostItem_call(lostItems, vendorId, resultHandler, this, ___protocolFactory, ___transport);
1508
      this.___currentMethod = method_call;
1509
      ___manager.call(method_call);
1510
    }
1511
 
1512
    public static class scanForLostItem_call extends org.apache.thrift.async.TAsyncMethodCall {
1513
      private List<InventoryItem> lostItems;
1514
      private long vendorId;
1515
      public scanForLostItem_call(List<InventoryItem> lostItems, long vendorId, org.apache.thrift.async.AsyncMethodCallback<scanForLostItem_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1516
        super(client, protocolFactory, transport, resultHandler, false);
1517
        this.lostItems = lostItems;
1518
        this.vendorId = vendorId;
1519
      }
1520
 
1521
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1522
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("scanForLostItem", org.apache.thrift.protocol.TMessageType.CALL, 0));
1523
        scanForLostItem_args args = new scanForLostItem_args();
1524
        args.setLostItems(lostItems);
1525
        args.setVendorId(vendorId);
1526
        args.write(prot);
1527
        prot.writeMessageEnd();
1528
      }
1529
 
1530
      public void getResult() throws WarehouseServiceException, org.apache.thrift.TException {
1531
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1532
          throw new IllegalStateException("Method call not finished!");
1533
        }
1534
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1535
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1536
        (new Client(prot)).recv_scanForLostItem();
1537
      }
1538
    }
1539
 
1540
    public void getCurrentSerializedInventoryByScans(org.apache.thrift.async.AsyncMethodCallback<getCurrentSerializedInventoryByScans_call> resultHandler) throws org.apache.thrift.TException {
1541
      checkReady();
1542
      getCurrentSerializedInventoryByScans_call method_call = new getCurrentSerializedInventoryByScans_call(resultHandler, this, ___protocolFactory, ___transport);
1543
      this.___currentMethod = method_call;
1544
      ___manager.call(method_call);
1545
    }
1546
 
1547
    public static class getCurrentSerializedInventoryByScans_call extends org.apache.thrift.async.TAsyncMethodCall {
1548
      public getCurrentSerializedInventoryByScans_call(org.apache.thrift.async.AsyncMethodCallback<getCurrentSerializedInventoryByScans_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1549
        super(client, protocolFactory, transport, resultHandler, false);
1550
      }
1551
 
1552
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1553
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getCurrentSerializedInventoryByScans", org.apache.thrift.protocol.TMessageType.CALL, 0));
1554
        getCurrentSerializedInventoryByScans_args args = new getCurrentSerializedInventoryByScans_args();
1555
        args.write(prot);
1556
        prot.writeMessageEnd();
1557
      }
1558
 
1559
      public List<InventoryAvailability> getResult() throws org.apache.thrift.TException {
1560
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1561
          throw new IllegalStateException("Method call not finished!");
1562
        }
1563
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1564
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1565
        return (new Client(prot)).recv_getCurrentSerializedInventoryByScans();
1566
      }
1567
    }
1568
 
6630 amar.kumar 1569
    public void getCurrentNonSerializedInventoryByScans(org.apache.thrift.async.AsyncMethodCallback<getCurrentNonSerializedInventoryByScans_call> resultHandler) throws org.apache.thrift.TException {
1570
      checkReady();
1571
      getCurrentNonSerializedInventoryByScans_call method_call = new getCurrentNonSerializedInventoryByScans_call(resultHandler, this, ___protocolFactory, ___transport);
1572
      this.___currentMethod = method_call;
1573
      ___manager.call(method_call);
1574
    }
1575
 
1576
    public static class getCurrentNonSerializedInventoryByScans_call extends org.apache.thrift.async.TAsyncMethodCall {
1577
      public getCurrentNonSerializedInventoryByScans_call(org.apache.thrift.async.AsyncMethodCallback<getCurrentNonSerializedInventoryByScans_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1578
        super(client, protocolFactory, transport, resultHandler, false);
1579
      }
1580
 
1581
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1582
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getCurrentNonSerializedInventoryByScans", org.apache.thrift.protocol.TMessageType.CALL, 0));
1583
        getCurrentNonSerializedInventoryByScans_args args = new getCurrentNonSerializedInventoryByScans_args();
1584
        args.write(prot);
1585
        prot.writeMessageEnd();
1586
      }
1587
 
1588
      public List<InventoryAvailability> getResult() throws org.apache.thrift.TException {
1589
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1590
          throw new IllegalStateException("Method call not finished!");
1591
        }
1592
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1593
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1594
        return (new Client(prot)).recv_getCurrentNonSerializedInventoryByScans();
1595
      }
1596
    }
1597
 
6762 amar.kumar 1598
    public void getHistoricSerializedInventoryByScans(long date, org.apache.thrift.async.AsyncMethodCallback<getHistoricSerializedInventoryByScans_call> resultHandler) throws org.apache.thrift.TException {
1599
      checkReady();
1600
      getHistoricSerializedInventoryByScans_call method_call = new getHistoricSerializedInventoryByScans_call(date, resultHandler, this, ___protocolFactory, ___transport);
1601
      this.___currentMethod = method_call;
1602
      ___manager.call(method_call);
1603
    }
1604
 
1605
    public static class getHistoricSerializedInventoryByScans_call extends org.apache.thrift.async.TAsyncMethodCall {
1606
      private long date;
1607
      public getHistoricSerializedInventoryByScans_call(long date, org.apache.thrift.async.AsyncMethodCallback<getHistoricSerializedInventoryByScans_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1608
        super(client, protocolFactory, transport, resultHandler, false);
1609
        this.date = date;
1610
      }
1611
 
1612
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1613
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getHistoricSerializedInventoryByScans", org.apache.thrift.protocol.TMessageType.CALL, 0));
1614
        getHistoricSerializedInventoryByScans_args args = new getHistoricSerializedInventoryByScans_args();
1615
        args.setDate(date);
1616
        args.write(prot);
1617
        prot.writeMessageEnd();
1618
      }
1619
 
1620
      public List<InventoryAvailability> getResult() throws org.apache.thrift.TException {
1621
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1622
          throw new IllegalStateException("Method call not finished!");
1623
        }
1624
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1625
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1626
        return (new Client(prot)).recv_getHistoricSerializedInventoryByScans();
1627
      }
1628
    }
1629
 
1630
    public void getHistoricNonSerializedInventoryByScans(long date, org.apache.thrift.async.AsyncMethodCallback<getHistoricNonSerializedInventoryByScans_call> resultHandler) throws org.apache.thrift.TException {
1631
      checkReady();
1632
      getHistoricNonSerializedInventoryByScans_call method_call = new getHistoricNonSerializedInventoryByScans_call(date, resultHandler, this, ___protocolFactory, ___transport);
1633
      this.___currentMethod = method_call;
1634
      ___manager.call(method_call);
1635
    }
1636
 
1637
    public static class getHistoricNonSerializedInventoryByScans_call extends org.apache.thrift.async.TAsyncMethodCall {
1638
      private long date;
1639
      public getHistoricNonSerializedInventoryByScans_call(long date, org.apache.thrift.async.AsyncMethodCallback<getHistoricNonSerializedInventoryByScans_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1640
        super(client, protocolFactory, transport, resultHandler, false);
1641
        this.date = date;
1642
      }
1643
 
1644
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1645
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getHistoricNonSerializedInventoryByScans", org.apache.thrift.protocol.TMessageType.CALL, 0));
1646
        getHistoricNonSerializedInventoryByScans_args args = new getHistoricNonSerializedInventoryByScans_args();
1647
        args.setDate(date);
1648
        args.write(prot);
1649
        prot.writeMessageEnd();
1650
      }
1651
 
1652
      public List<InventoryAvailability> getResult() throws org.apache.thrift.TException {
1653
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1654
          throw new IllegalStateException("Method call not finished!");
1655
        }
1656
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1657
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1658
        return (new Client(prot)).recv_getHistoricNonSerializedInventoryByScans();
1659
      }
1660
    }
1661
 
1662
    public void scanForOursExternalSale(long itemId, String serialNumber, String itemNumber, String invoiceNumber, long warehouseId, double unitPrice, long orderId, org.apache.thrift.async.AsyncMethodCallback<scanForOursExternalSale_call> resultHandler) throws org.apache.thrift.TException {
1663
      checkReady();
1664
      scanForOursExternalSale_call method_call = new scanForOursExternalSale_call(itemId, serialNumber, itemNumber, invoiceNumber, warehouseId, unitPrice, orderId, resultHandler, this, ___protocolFactory, ___transport);
1665
      this.___currentMethod = method_call;
1666
      ___manager.call(method_call);
1667
    }
1668
 
1669
    public static class scanForOursExternalSale_call extends org.apache.thrift.async.TAsyncMethodCall {
1670
      private long itemId;
1671
      private String serialNumber;
1672
      private String itemNumber;
1673
      private String invoiceNumber;
1674
      private long warehouseId;
1675
      private double unitPrice;
1676
      private long orderId;
1677
      public scanForOursExternalSale_call(long itemId, String serialNumber, String itemNumber, String invoiceNumber, long warehouseId, double unitPrice, long orderId, org.apache.thrift.async.AsyncMethodCallback<scanForOursExternalSale_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1678
        super(client, protocolFactory, transport, resultHandler, false);
1679
        this.itemId = itemId;
1680
        this.serialNumber = serialNumber;
1681
        this.itemNumber = itemNumber;
1682
        this.invoiceNumber = invoiceNumber;
1683
        this.warehouseId = warehouseId;
1684
        this.unitPrice = unitPrice;
1685
        this.orderId = orderId;
1686
      }
1687
 
1688
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1689
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("scanForOursExternalSale", org.apache.thrift.protocol.TMessageType.CALL, 0));
1690
        scanForOursExternalSale_args args = new scanForOursExternalSale_args();
1691
        args.setItemId(itemId);
1692
        args.setSerialNumber(serialNumber);
1693
        args.setItemNumber(itemNumber);
1694
        args.setInvoiceNumber(invoiceNumber);
1695
        args.setWarehouseId(warehouseId);
1696
        args.setUnitPrice(unitPrice);
1697
        args.setOrderId(orderId);
1698
        args.write(prot);
1699
        prot.writeMessageEnd();
1700
      }
1701
 
1702
      public InventoryItem getResult() throws WarehouseServiceException, org.apache.thrift.TException {
1703
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1704
          throw new IllegalStateException("Method call not finished!");
1705
        }
1706
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1707
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1708
        return (new Client(prot)).recv_scanForOursExternalSale();
1709
      }
1710
    }
1711
 
1712
    public void scanForOursExternalSaleReturn(long orderId, double unitPrice, org.apache.thrift.async.AsyncMethodCallback<scanForOursExternalSaleReturn_call> resultHandler) throws org.apache.thrift.TException {
1713
      checkReady();
1714
      scanForOursExternalSaleReturn_call method_call = new scanForOursExternalSaleReturn_call(orderId, unitPrice, resultHandler, this, ___protocolFactory, ___transport);
1715
      this.___currentMethod = method_call;
1716
      ___manager.call(method_call);
1717
    }
1718
 
1719
    public static class scanForOursExternalSaleReturn_call extends org.apache.thrift.async.TAsyncMethodCall {
1720
      private long orderId;
1721
      private double unitPrice;
1722
      public scanForOursExternalSaleReturn_call(long orderId, double unitPrice, org.apache.thrift.async.AsyncMethodCallback<scanForOursExternalSaleReturn_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1723
        super(client, protocolFactory, transport, resultHandler, false);
1724
        this.orderId = orderId;
1725
        this.unitPrice = unitPrice;
1726
      }
1727
 
1728
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1729
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("scanForOursExternalSaleReturn", org.apache.thrift.protocol.TMessageType.CALL, 0));
1730
        scanForOursExternalSaleReturn_args args = new scanForOursExternalSaleReturn_args();
1731
        args.setOrderId(orderId);
1732
        args.setUnitPrice(unitPrice);
1733
        args.write(prot);
1734
        prot.writeMessageEnd();
1735
      }
1736
 
1737
      public void getResult() throws org.apache.thrift.TException {
1738
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1739
          throw new IllegalStateException("Method call not finished!");
1740
        }
1741
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1742
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1743
        (new Client(prot)).recv_scanForOursExternalSaleReturn();
1744
      }
1745
    }
1746
 
3430 rajveer 1747
  }
1748
 
1749
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
1750
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
1751
    public Processor(I iface) {
1752
      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
1753
    }
1754
 
1755
    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
1756
      super(iface, getProcessMap(processMap));
1757
    }
1758
 
1759
    private static <I extends Iface> Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> getProcessMap(Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
4496 mandeep.dh 1760
      processMap.put("getInventoryItem", new getInventoryItem());
5361 mandeep.dh 1761
      processMap.put("getNonSeralizedInventoryItem", new getNonSeralizedInventoryItem());
4496 mandeep.dh 1762
      processMap.put("scan", new scan());
1763
      processMap.put("scanSerializedItemForOrder", new scanSerializedItemForOrder());
1764
      processMap.put("scanForOrder", new scanForOrder());
1765
      processMap.put("createItemNumberMapping", new createItemNumberMapping());
4622 amit.gupta 1766
      processMap.put("getItemNumbers", new getItemNumbers());
5110 mandeep.dh 1767
      processMap.put("getItemIds", new getItemIds());
5185 mandeep.dh 1768
      processMap.put("getInventoryItemsFromLastScanType", new getInventoryItemsFromLastScanType());
1769
      processMap.put("getInventoryItemFromId", new getInventoryItemFromId());
5372 mandeep.dh 1770
      processMap.put("getPurchaseScans", new getPurchaseScans());
5496 mandeep.dh 1771
      processMap.put("fetchScansPerInvoiceNumber", new fetchScansPerInvoiceNumber());
5620 mandeep.dh 1772
      processMap.put("getInventoryItemFromOrder", new getInventoryItemFromOrder());
5711 mandeep.dh 1773
      processMap.put("getInventoryAge", new getInventoryAge());
6322 amar.kumar 1774
      processMap.put("getInventoryScansForItem", new getInventoryScansForItem());
1775
      processMap.put("getScanRecordsForSerialNumber", new getScanRecordsForSerialNumber());
6467 amar.kumar 1776
      processMap.put("scanForPurchaseReturn", new scanForPurchaseReturn());
6548 amar.kumar 1777
      processMap.put("scanForLostItem", new scanForLostItem());
1778
      processMap.put("getCurrentSerializedInventoryByScans", new getCurrentSerializedInventoryByScans());
6630 amar.kumar 1779
      processMap.put("getCurrentNonSerializedInventoryByScans", new getCurrentNonSerializedInventoryByScans());
6762 amar.kumar 1780
      processMap.put("getHistoricSerializedInventoryByScans", new getHistoricSerializedInventoryByScans());
1781
      processMap.put("getHistoricNonSerializedInventoryByScans", new getHistoricNonSerializedInventoryByScans());
1782
      processMap.put("scanForOursExternalSale", new scanForOursExternalSale());
1783
      processMap.put("scanForOursExternalSaleReturn", new scanForOursExternalSaleReturn());
3430 rajveer 1784
      return processMap;
1785
    }
1786
 
4496 mandeep.dh 1787
    private static class getInventoryItem<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventoryItem_args> {
1788
      public getInventoryItem() {
1789
        super("getInventoryItem");
3430 rajveer 1790
      }
1791
 
4496 mandeep.dh 1792
      protected getInventoryItem_args getEmptyArgsInstance() {
1793
        return new getInventoryItem_args();
3430 rajveer 1794
      }
1795
 
4496 mandeep.dh 1796
      protected getInventoryItem_result getResult(I iface, getInventoryItem_args args) throws org.apache.thrift.TException {
1797
        getInventoryItem_result result = new getInventoryItem_result();
4541 mandeep.dh 1798
        try {
1799
          result.success = iface.getInventoryItem(args.serialNumber);
1800
        } catch (WarehouseServiceException wex) {
1801
          result.wex = wex;
1802
        }
3430 rajveer 1803
        return result;
2832 chandransh 1804
      }
1805
    }
1806
 
5361 mandeep.dh 1807
    private static class getNonSeralizedInventoryItem<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getNonSeralizedInventoryItem_args> {
1808
      public getNonSeralizedInventoryItem() {
1809
        super("getNonSeralizedInventoryItem");
3430 rajveer 1810
      }
1811
 
5361 mandeep.dh 1812
      protected getNonSeralizedInventoryItem_args getEmptyArgsInstance() {
1813
        return new getNonSeralizedInventoryItem_args();
3430 rajveer 1814
      }
1815
 
5361 mandeep.dh 1816
      protected getNonSeralizedInventoryItem_result getResult(I iface, getNonSeralizedInventoryItem_args args) throws org.apache.thrift.TException {
1817
        getNonSeralizedInventoryItem_result result = new getNonSeralizedInventoryItem_result();
1818
        try {
5530 mandeep.dh 1819
          result.success = iface.getNonSeralizedInventoryItem(args.itemNumber, args.itemId, args.fulfilmentWarehouseId);
5361 mandeep.dh 1820
        } catch (WarehouseServiceException wex) {
1821
          result.wex = wex;
1822
        }
3430 rajveer 1823
        return result;
2820 chandransh 1824
      }
1825
    }
1826
 
4496 mandeep.dh 1827
    private static class scan<I extends Iface> extends org.apache.thrift.ProcessFunction<I, scan_args> {
1828
      public scan() {
1829
        super("scan");
3430 rajveer 1830
      }
1831
 
4496 mandeep.dh 1832
      protected scan_args getEmptyArgsInstance() {
1833
        return new scan_args();
3430 rajveer 1834
      }
1835
 
4496 mandeep.dh 1836
      protected scan_result getResult(I iface, scan_args args) throws org.apache.thrift.TException {
1837
        scan_result result = new scan_result();
3383 chandransh 1838
        try {
5361 mandeep.dh 1839
          iface.scan(args.inventoryItem, args.type, args.quantity, args.billingWarehouseId);
3383 chandransh 1840
        } catch (WarehouseServiceException wex) {
1841
          result.wex = wex;
1842
        }
3430 rajveer 1843
        return result;
3383 chandransh 1844
      }
1845
    }
1846
 
4496 mandeep.dh 1847
    private static class scanSerializedItemForOrder<I extends Iface> extends org.apache.thrift.ProcessFunction<I, scanSerializedItemForOrder_args> {
1848
      public scanSerializedItemForOrder() {
1849
        super("scanSerializedItemForOrder");
3430 rajveer 1850
      }
1851
 
4496 mandeep.dh 1852
      protected scanSerializedItemForOrder_args getEmptyArgsInstance() {
1853
        return new scanSerializedItemForOrder_args();
3430 rajveer 1854
      }
1855
 
4496 mandeep.dh 1856
      protected scanSerializedItemForOrder_result getResult(I iface, scanSerializedItemForOrder_args args) throws org.apache.thrift.TException {
1857
        scanSerializedItemForOrder_result result = new scanSerializedItemForOrder_result();
2820 chandransh 1858
        try {
5110 mandeep.dh 1859
          result.success = iface.scanSerializedItemForOrder(args.serialNumber, args.type, args.orderId, args.fulfilmentWarehouseId, args.quantity, args.billingWarehouseId);
2820 chandransh 1860
        } catch (WarehouseServiceException wex) {
1861
          result.wex = wex;
1862
        }
3430 rajveer 1863
        return result;
2820 chandransh 1864
      }
1865
    }
1866
 
4496 mandeep.dh 1867
    private static class scanForOrder<I extends Iface> extends org.apache.thrift.ProcessFunction<I, scanForOrder_args> {
1868
      public scanForOrder() {
1869
        super("scanForOrder");
3430 rajveer 1870
      }
1871
 
4496 mandeep.dh 1872
      protected scanForOrder_args getEmptyArgsInstance() {
1873
        return new scanForOrder_args();
3430 rajveer 1874
      }
1875
 
4496 mandeep.dh 1876
      protected scanForOrder_result getResult(I iface, scanForOrder_args args) throws org.apache.thrift.TException {
1877
        scanForOrder_result result = new scanForOrder_result();
2820 chandransh 1878
        try {
5361 mandeep.dh 1879
          result.success = iface.scanForOrder(args.inventoryItem, args.type, args.quantity, args.orderId, args.fulfilmentWarehouseId, args.billingWarehouseId);
2820 chandransh 1880
        } catch (WarehouseServiceException wex) {
1881
          result.wex = wex;
1882
        }
3430 rajveer 1883
        return result;
2820 chandransh 1884
      }
1885
    }
1886
 
4496 mandeep.dh 1887
    private static class createItemNumberMapping<I extends Iface> extends org.apache.thrift.ProcessFunction<I, createItemNumberMapping_args> {
1888
      public createItemNumberMapping() {
1889
        super("createItemNumberMapping");
1890
      }
1891
 
1892
      protected createItemNumberMapping_args getEmptyArgsInstance() {
1893
        return new createItemNumberMapping_args();
1894
      }
1895
 
1896
      protected createItemNumberMapping_result getResult(I iface, createItemNumberMapping_args args) throws org.apache.thrift.TException {
1897
        createItemNumberMapping_result result = new createItemNumberMapping_result();
1898
        iface.createItemNumberMapping(args.itemNumber, args.itemId);
1899
        return result;
1900
      }
1901
    }
1902
 
4622 amit.gupta 1903
    private static class getItemNumbers<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemNumbers_args> {
1904
      public getItemNumbers() {
1905
        super("getItemNumbers");
1906
      }
1907
 
1908
      protected getItemNumbers_args getEmptyArgsInstance() {
1909
        return new getItemNumbers_args();
1910
      }
1911
 
1912
      protected getItemNumbers_result getResult(I iface, getItemNumbers_args args) throws org.apache.thrift.TException {
1913
        getItemNumbers_result result = new getItemNumbers_result();
1914
        result.success = iface.getItemNumbers(args.itemId);
1915
        return result;
1916
      }
1917
    }
1918
 
5110 mandeep.dh 1919
    private static class getItemIds<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemIds_args> {
1920
      public getItemIds() {
1921
        super("getItemIds");
1922
      }
1923
 
1924
      protected getItemIds_args getEmptyArgsInstance() {
1925
        return new getItemIds_args();
1926
      }
1927
 
1928
      protected getItemIds_result getResult(I iface, getItemIds_args args) throws org.apache.thrift.TException {
1929
        getItemIds_result result = new getItemIds_result();
1930
        result.success = iface.getItemIds(args.itemNumber);
1931
        return result;
1932
      }
1933
    }
1934
 
5185 mandeep.dh 1935
    private static class getInventoryItemsFromLastScanType<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventoryItemsFromLastScanType_args> {
1936
      public getInventoryItemsFromLastScanType() {
1937
        super("getInventoryItemsFromLastScanType");
1938
      }
1939
 
1940
      protected getInventoryItemsFromLastScanType_args getEmptyArgsInstance() {
1941
        return new getInventoryItemsFromLastScanType_args();
1942
      }
1943
 
1944
      protected getInventoryItemsFromLastScanType_result getResult(I iface, getInventoryItemsFromLastScanType_args args) throws org.apache.thrift.TException {
1945
        getInventoryItemsFromLastScanType_result result = new getInventoryItemsFromLastScanType_result();
1946
        try {
1947
          result.success = iface.getInventoryItemsFromLastScanType(args.lastScanType);
1948
        } catch (WarehouseServiceException wex) {
1949
          result.wex = wex;
1950
        }
1951
        return result;
1952
      }
1953
    }
1954
 
1955
    private static class getInventoryItemFromId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventoryItemFromId_args> {
1956
      public getInventoryItemFromId() {
1957
        super("getInventoryItemFromId");
1958
      }
1959
 
1960
      protected getInventoryItemFromId_args getEmptyArgsInstance() {
1961
        return new getInventoryItemFromId_args();
1962
      }
1963
 
1964
      protected getInventoryItemFromId_result getResult(I iface, getInventoryItemFromId_args args) throws org.apache.thrift.TException {
1965
        getInventoryItemFromId_result result = new getInventoryItemFromId_result();
1966
        try {
1967
          result.success = iface.getInventoryItemFromId(args.inventoryItemId);
1968
        } catch (WarehouseServiceException wex) {
1969
          result.wex = wex;
1970
        }
1971
        return result;
1972
      }
1973
    }
1974
 
5372 mandeep.dh 1975
    private static class getPurchaseScans<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPurchaseScans_args> {
1976
      public getPurchaseScans() {
1977
        super("getPurchaseScans");
1978
      }
1979
 
1980
      protected getPurchaseScans_args getEmptyArgsInstance() {
1981
        return new getPurchaseScans_args();
1982
      }
1983
 
1984
      protected getPurchaseScans_result getResult(I iface, getPurchaseScans_args args) throws org.apache.thrift.TException {
1985
        getPurchaseScans_result result = new getPurchaseScans_result();
1986
        result.success = iface.getPurchaseScans(args.startDate, args.endDate);
1987
        return result;
1988
      }
1989
    }
1990
 
5496 mandeep.dh 1991
    private static class fetchScansPerInvoiceNumber<I extends Iface> extends org.apache.thrift.ProcessFunction<I, fetchScansPerInvoiceNumber_args> {
1992
      public fetchScansPerInvoiceNumber() {
1993
        super("fetchScansPerInvoiceNumber");
1994
      }
1995
 
1996
      protected fetchScansPerInvoiceNumber_args getEmptyArgsInstance() {
1997
        return new fetchScansPerInvoiceNumber_args();
1998
      }
1999
 
2000
      protected fetchScansPerInvoiceNumber_result getResult(I iface, fetchScansPerInvoiceNumber_args args) throws org.apache.thrift.TException {
2001
        fetchScansPerInvoiceNumber_result result = new fetchScansPerInvoiceNumber_result();
2002
        result.success = iface.fetchScansPerInvoiceNumber(args.date);
2003
        return result;
2004
      }
2005
    }
2006
 
5620 mandeep.dh 2007
    private static class getInventoryItemFromOrder<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventoryItemFromOrder_args> {
2008
      public getInventoryItemFromOrder() {
2009
        super("getInventoryItemFromOrder");
2010
      }
2011
 
2012
      protected getInventoryItemFromOrder_args getEmptyArgsInstance() {
2013
        return new getInventoryItemFromOrder_args();
2014
      }
2015
 
2016
      protected getInventoryItemFromOrder_result getResult(I iface, getInventoryItemFromOrder_args args) throws org.apache.thrift.TException {
2017
        getInventoryItemFromOrder_result result = new getInventoryItemFromOrder_result();
2018
        try {
2019
          result.success = iface.getInventoryItemFromOrder(args.orderId);
2020
        } catch (WarehouseServiceException we) {
2021
          result.we = we;
2022
        }
2023
        return result;
2024
      }
2025
    }
2026
 
5711 mandeep.dh 2027
    private static class getInventoryAge<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventoryAge_args> {
2028
      public getInventoryAge() {
2029
        super("getInventoryAge");
2030
      }
2031
 
2032
      protected getInventoryAge_args getEmptyArgsInstance() {
2033
        return new getInventoryAge_args();
2034
      }
2035
 
2036
      protected getInventoryAge_result getResult(I iface, getInventoryAge_args args) throws org.apache.thrift.TException {
2037
        getInventoryAge_result result = new getInventoryAge_result();
2038
        result.success = iface.getInventoryAge();
2039
        return result;
2040
      }
2041
    }
2042
 
6322 amar.kumar 2043
    private static class getInventoryScansForItem<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventoryScansForItem_args> {
2044
      public getInventoryScansForItem() {
2045
        super("getInventoryScansForItem");
2046
      }
2047
 
2048
      protected getInventoryScansForItem_args getEmptyArgsInstance() {
2049
        return new getInventoryScansForItem_args();
2050
      }
2051
 
2052
      protected getInventoryScansForItem_result getResult(I iface, getInventoryScansForItem_args args) throws org.apache.thrift.TException {
2053
        getInventoryScansForItem_result result = new getInventoryScansForItem_result();
2054
        result.success = iface.getInventoryScansForItem(args.itemId, args.fromDate, args.toDate);
2055
        return result;
2056
      }
2057
    }
2058
 
2059
    private static class getScanRecordsForSerialNumber<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getScanRecordsForSerialNumber_args> {
2060
      public getScanRecordsForSerialNumber() {
2061
        super("getScanRecordsForSerialNumber");
2062
      }
2063
 
2064
      protected getScanRecordsForSerialNumber_args getEmptyArgsInstance() {
2065
        return new getScanRecordsForSerialNumber_args();
2066
      }
2067
 
2068
      protected getScanRecordsForSerialNumber_result getResult(I iface, getScanRecordsForSerialNumber_args args) throws org.apache.thrift.TException {
2069
        getScanRecordsForSerialNumber_result result = new getScanRecordsForSerialNumber_result();
2070
        result.success = iface.getScanRecordsForSerialNumber(args.serialNumber);
2071
        return result;
2072
      }
2073
    }
2074
 
6467 amar.kumar 2075
    private static class scanForPurchaseReturn<I extends Iface> extends org.apache.thrift.ProcessFunction<I, scanForPurchaseReturn_args> {
2076
      public scanForPurchaseReturn() {
2077
        super("scanForPurchaseReturn");
2078
      }
2079
 
2080
      protected scanForPurchaseReturn_args getEmptyArgsInstance() {
2081
        return new scanForPurchaseReturn_args();
2082
      }
2083
 
2084
      protected scanForPurchaseReturn_result getResult(I iface, scanForPurchaseReturn_args args) throws org.apache.thrift.TException {
2085
        scanForPurchaseReturn_result result = new scanForPurchaseReturn_result();
2086
        try {
2087
          iface.scanForPurchaseReturn(args.saleReturnItems, args.vendorId);
2088
        } catch (WarehouseServiceException ex) {
2089
          result.ex = ex;
2090
        }
2091
        return result;
2092
      }
2093
    }
2094
 
6548 amar.kumar 2095
    private static class scanForLostItem<I extends Iface> extends org.apache.thrift.ProcessFunction<I, scanForLostItem_args> {
2096
      public scanForLostItem() {
2097
        super("scanForLostItem");
2098
      }
2099
 
2100
      protected scanForLostItem_args getEmptyArgsInstance() {
2101
        return new scanForLostItem_args();
2102
      }
2103
 
2104
      protected scanForLostItem_result getResult(I iface, scanForLostItem_args args) throws org.apache.thrift.TException {
2105
        scanForLostItem_result result = new scanForLostItem_result();
2106
        try {
2107
          iface.scanForLostItem(args.lostItems, args.vendorId);
2108
        } catch (WarehouseServiceException ex) {
2109
          result.ex = ex;
2110
        }
2111
        return result;
2112
      }
2113
    }
2114
 
2115
    private static class getCurrentSerializedInventoryByScans<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getCurrentSerializedInventoryByScans_args> {
2116
      public getCurrentSerializedInventoryByScans() {
2117
        super("getCurrentSerializedInventoryByScans");
2118
      }
2119
 
2120
      protected getCurrentSerializedInventoryByScans_args getEmptyArgsInstance() {
2121
        return new getCurrentSerializedInventoryByScans_args();
2122
      }
2123
 
2124
      protected getCurrentSerializedInventoryByScans_result getResult(I iface, getCurrentSerializedInventoryByScans_args args) throws org.apache.thrift.TException {
2125
        getCurrentSerializedInventoryByScans_result result = new getCurrentSerializedInventoryByScans_result();
2126
        result.success = iface.getCurrentSerializedInventoryByScans();
2127
        return result;
2128
      }
2129
    }
2130
 
6630 amar.kumar 2131
    private static class getCurrentNonSerializedInventoryByScans<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getCurrentNonSerializedInventoryByScans_args> {
2132
      public getCurrentNonSerializedInventoryByScans() {
2133
        super("getCurrentNonSerializedInventoryByScans");
2134
      }
2135
 
2136
      protected getCurrentNonSerializedInventoryByScans_args getEmptyArgsInstance() {
2137
        return new getCurrentNonSerializedInventoryByScans_args();
2138
      }
2139
 
2140
      protected getCurrentNonSerializedInventoryByScans_result getResult(I iface, getCurrentNonSerializedInventoryByScans_args args) throws org.apache.thrift.TException {
2141
        getCurrentNonSerializedInventoryByScans_result result = new getCurrentNonSerializedInventoryByScans_result();
2142
        result.success = iface.getCurrentNonSerializedInventoryByScans();
2143
        return result;
2144
      }
2145
    }
2146
 
6762 amar.kumar 2147
    private static class getHistoricSerializedInventoryByScans<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getHistoricSerializedInventoryByScans_args> {
2148
      public getHistoricSerializedInventoryByScans() {
2149
        super("getHistoricSerializedInventoryByScans");
2150
      }
2151
 
2152
      protected getHistoricSerializedInventoryByScans_args getEmptyArgsInstance() {
2153
        return new getHistoricSerializedInventoryByScans_args();
2154
      }
2155
 
2156
      protected getHistoricSerializedInventoryByScans_result getResult(I iface, getHistoricSerializedInventoryByScans_args args) throws org.apache.thrift.TException {
2157
        getHistoricSerializedInventoryByScans_result result = new getHistoricSerializedInventoryByScans_result();
2158
        result.success = iface.getHistoricSerializedInventoryByScans(args.date);
2159
        return result;
2160
      }
2161
    }
2162
 
2163
    private static class getHistoricNonSerializedInventoryByScans<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getHistoricNonSerializedInventoryByScans_args> {
2164
      public getHistoricNonSerializedInventoryByScans() {
2165
        super("getHistoricNonSerializedInventoryByScans");
2166
      }
2167
 
2168
      protected getHistoricNonSerializedInventoryByScans_args getEmptyArgsInstance() {
2169
        return new getHistoricNonSerializedInventoryByScans_args();
2170
      }
2171
 
2172
      protected getHistoricNonSerializedInventoryByScans_result getResult(I iface, getHistoricNonSerializedInventoryByScans_args args) throws org.apache.thrift.TException {
2173
        getHistoricNonSerializedInventoryByScans_result result = new getHistoricNonSerializedInventoryByScans_result();
2174
        result.success = iface.getHistoricNonSerializedInventoryByScans(args.date);
2175
        return result;
2176
      }
2177
    }
2178
 
2179
    private static class scanForOursExternalSale<I extends Iface> extends org.apache.thrift.ProcessFunction<I, scanForOursExternalSale_args> {
2180
      public scanForOursExternalSale() {
2181
        super("scanForOursExternalSale");
2182
      }
2183
 
2184
      protected scanForOursExternalSale_args getEmptyArgsInstance() {
2185
        return new scanForOursExternalSale_args();
2186
      }
2187
 
2188
      protected scanForOursExternalSale_result getResult(I iface, scanForOursExternalSale_args args) throws org.apache.thrift.TException {
2189
        scanForOursExternalSale_result result = new scanForOursExternalSale_result();
2190
        try {
2191
          result.success = iface.scanForOursExternalSale(args.itemId, args.serialNumber, args.itemNumber, args.invoiceNumber, args.warehouseId, args.unitPrice, args.orderId);
2192
        } catch (WarehouseServiceException ex) {
2193
          result.ex = ex;
2194
        }
2195
        return result;
2196
      }
2197
    }
2198
 
2199
    private static class scanForOursExternalSaleReturn<I extends Iface> extends org.apache.thrift.ProcessFunction<I, scanForOursExternalSaleReturn_args> {
2200
      public scanForOursExternalSaleReturn() {
2201
        super("scanForOursExternalSaleReturn");
2202
      }
2203
 
2204
      protected scanForOursExternalSaleReturn_args getEmptyArgsInstance() {
2205
        return new scanForOursExternalSaleReturn_args();
2206
      }
2207
 
2208
      protected scanForOursExternalSaleReturn_result getResult(I iface, scanForOursExternalSaleReturn_args args) throws org.apache.thrift.TException {
2209
        scanForOursExternalSaleReturn_result result = new scanForOursExternalSaleReturn_result();
2210
        iface.scanForOursExternalSaleReturn(args.orderId, args.unitPrice);
2211
        return result;
2212
      }
2213
    }
2214
 
2820 chandransh 2215
  }
2216
 
4496 mandeep.dh 2217
  public static class getInventoryItem_args implements org.apache.thrift.TBase<getInventoryItem_args, getInventoryItem_args._Fields>, java.io.Serializable, Cloneable   {
2218
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryItem_args");
2832 chandransh 2219
 
4496 mandeep.dh 2220
    private static final org.apache.thrift.protocol.TField SERIAL_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("serialNumber", org.apache.thrift.protocol.TType.STRING, (short)1);
2832 chandransh 2221
 
4496 mandeep.dh 2222
    private String serialNumber; // required
2832 chandransh 2223
 
2224
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2225
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4496 mandeep.dh 2226
      SERIAL_NUMBER((short)1, "serialNumber");
2832 chandransh 2227
 
2228
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2229
 
2230
      static {
2231
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2232
          byName.put(field.getFieldName(), field);
2233
        }
2234
      }
2235
 
2236
      /**
2237
       * Find the _Fields constant that matches fieldId, or null if its not found.
2238
       */
2239
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2240
        switch(fieldId) {
4496 mandeep.dh 2241
          case 1: // SERIAL_NUMBER
2242
            return SERIAL_NUMBER;
3430 rajveer 2243
          default:
2244
            return null;
2245
        }
2832 chandransh 2246
      }
2247
 
2248
      /**
2249
       * Find the _Fields constant that matches fieldId, throwing an exception
2250
       * if it is not found.
2251
       */
2252
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2253
        _Fields fields = findByThriftId(fieldId);
2254
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2255
        return fields;
2256
      }
2257
 
2258
      /**
2259
       * Find the _Fields constant that matches name, or null if its not found.
2260
       */
2261
      public static _Fields findByName(String name) {
2262
        return byName.get(name);
2263
      }
2264
 
2265
      private final short _thriftId;
2266
      private final String _fieldName;
2267
 
2268
      _Fields(short thriftId, String fieldName) {
2269
        _thriftId = thriftId;
2270
        _fieldName = fieldName;
2271
      }
2272
 
2273
      public short getThriftFieldId() {
2274
        return _thriftId;
2275
      }
2276
 
2277
      public String getFieldName() {
2278
        return _fieldName;
2279
      }
2280
    }
2281
 
2282
    // isset id assignments
2283
 
3430 rajveer 2284
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2832 chandransh 2285
    static {
3430 rajveer 2286
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4496 mandeep.dh 2287
      tmpMap.put(_Fields.SERIAL_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("serialNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2288
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
3430 rajveer 2289
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4496 mandeep.dh 2290
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryItem_args.class, metaDataMap);
2832 chandransh 2291
    }
2292
 
4496 mandeep.dh 2293
    public getInventoryItem_args() {
2832 chandransh 2294
    }
2295
 
4496 mandeep.dh 2296
    public getInventoryItem_args(
2297
      String serialNumber)
2832 chandransh 2298
    {
2299
      this();
4496 mandeep.dh 2300
      this.serialNumber = serialNumber;
2832 chandransh 2301
    }
2302
 
2303
    /**
2304
     * Performs a deep copy on <i>other</i>.
2305
     */
4496 mandeep.dh 2306
    public getInventoryItem_args(getInventoryItem_args other) {
2307
      if (other.isSetSerialNumber()) {
2308
        this.serialNumber = other.serialNumber;
2309
      }
2832 chandransh 2310
    }
2311
 
4496 mandeep.dh 2312
    public getInventoryItem_args deepCopy() {
2313
      return new getInventoryItem_args(this);
2832 chandransh 2314
    }
2315
 
3430 rajveer 2316
    @Override
2317
    public void clear() {
4496 mandeep.dh 2318
      this.serialNumber = null;
2832 chandransh 2319
    }
2320
 
4496 mandeep.dh 2321
    public String getSerialNumber() {
2322
      return this.serialNumber;
2832 chandransh 2323
    }
2324
 
4496 mandeep.dh 2325
    public void setSerialNumber(String serialNumber) {
2326
      this.serialNumber = serialNumber;
2832 chandransh 2327
    }
2328
 
4496 mandeep.dh 2329
    public void unsetSerialNumber() {
2330
      this.serialNumber = null;
2832 chandransh 2331
    }
2332
 
4496 mandeep.dh 2333
    /** Returns true if field serialNumber is set (has been assigned a value) and false otherwise */
2334
    public boolean isSetSerialNumber() {
2335
      return this.serialNumber != null;
2832 chandransh 2336
    }
2337
 
4496 mandeep.dh 2338
    public void setSerialNumberIsSet(boolean value) {
2339
      if (!value) {
2340
        this.serialNumber = null;
2341
      }
2832 chandransh 2342
    }
2343
 
2344
    public void setFieldValue(_Fields field, Object value) {
2345
      switch (field) {
4496 mandeep.dh 2346
      case SERIAL_NUMBER:
2832 chandransh 2347
        if (value == null) {
4496 mandeep.dh 2348
          unsetSerialNumber();
2832 chandransh 2349
        } else {
4496 mandeep.dh 2350
          setSerialNumber((String)value);
2832 chandransh 2351
        }
2352
        break;
2353
 
2354
      }
2355
    }
2356
 
2357
    public Object getFieldValue(_Fields field) {
2358
      switch (field) {
4496 mandeep.dh 2359
      case SERIAL_NUMBER:
2360
        return getSerialNumber();
2832 chandransh 2361
 
2362
      }
2363
      throw new IllegalStateException();
2364
    }
2365
 
3430 rajveer 2366
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2367
    public boolean isSet(_Fields field) {
2368
      if (field == null) {
2369
        throw new IllegalArgumentException();
2370
      }
2832 chandransh 2371
 
2372
      switch (field) {
4496 mandeep.dh 2373
      case SERIAL_NUMBER:
2374
        return isSetSerialNumber();
2832 chandransh 2375
      }
2376
      throw new IllegalStateException();
2377
    }
2378
 
2379
    @Override
2380
    public boolean equals(Object that) {
2381
      if (that == null)
2382
        return false;
4496 mandeep.dh 2383
      if (that instanceof getInventoryItem_args)
2384
        return this.equals((getInventoryItem_args)that);
2832 chandransh 2385
      return false;
2386
    }
2387
 
4496 mandeep.dh 2388
    public boolean equals(getInventoryItem_args that) {
2832 chandransh 2389
      if (that == null)
2390
        return false;
2391
 
4496 mandeep.dh 2392
      boolean this_present_serialNumber = true && this.isSetSerialNumber();
2393
      boolean that_present_serialNumber = true && that.isSetSerialNumber();
2394
      if (this_present_serialNumber || that_present_serialNumber) {
2395
        if (!(this_present_serialNumber && that_present_serialNumber))
2832 chandransh 2396
          return false;
4496 mandeep.dh 2397
        if (!this.serialNumber.equals(that.serialNumber))
2832 chandransh 2398
          return false;
2399
      }
2400
 
2401
      return true;
2402
    }
2403
 
2404
    @Override
2405
    public int hashCode() {
2406
      return 0;
2407
    }
2408
 
4496 mandeep.dh 2409
    public int compareTo(getInventoryItem_args other) {
2832 chandransh 2410
      if (!getClass().equals(other.getClass())) {
2411
        return getClass().getName().compareTo(other.getClass().getName());
2412
      }
2413
 
2414
      int lastComparison = 0;
4496 mandeep.dh 2415
      getInventoryItem_args typedOther = (getInventoryItem_args)other;
2832 chandransh 2416
 
4496 mandeep.dh 2417
      lastComparison = Boolean.valueOf(isSetSerialNumber()).compareTo(typedOther.isSetSerialNumber());
2832 chandransh 2418
      if (lastComparison != 0) {
2419
        return lastComparison;
2420
      }
4496 mandeep.dh 2421
      if (isSetSerialNumber()) {
2422
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.serialNumber, typedOther.serialNumber);
3430 rajveer 2423
        if (lastComparison != 0) {
2424
          return lastComparison;
2425
        }
2832 chandransh 2426
      }
2427
      return 0;
2428
    }
2429
 
3430 rajveer 2430
    public _Fields fieldForId(int fieldId) {
2431
      return _Fields.findByThriftId(fieldId);
2432
    }
2433
 
2434
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2435
      org.apache.thrift.protocol.TField field;
2832 chandransh 2436
      iprot.readStructBegin();
2437
      while (true)
2438
      {
2439
        field = iprot.readFieldBegin();
3430 rajveer 2440
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2832 chandransh 2441
          break;
2442
        }
3430 rajveer 2443
        switch (field.id) {
4496 mandeep.dh 2444
          case 1: // SERIAL_NUMBER
2445
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
2446
              this.serialNumber = iprot.readString();
3430 rajveer 2447
            } else { 
2448
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2449
            }
2450
            break;
2451
          default:
2452
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2832 chandransh 2453
        }
3430 rajveer 2454
        iprot.readFieldEnd();
2832 chandransh 2455
      }
2456
      iprot.readStructEnd();
2457
      validate();
2458
    }
2459
 
3430 rajveer 2460
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2832 chandransh 2461
      validate();
2462
 
2463
      oprot.writeStructBegin(STRUCT_DESC);
4496 mandeep.dh 2464
      if (this.serialNumber != null) {
2465
        oprot.writeFieldBegin(SERIAL_NUMBER_FIELD_DESC);
2466
        oprot.writeString(this.serialNumber);
2467
        oprot.writeFieldEnd();
2468
      }
2832 chandransh 2469
      oprot.writeFieldStop();
2470
      oprot.writeStructEnd();
2471
    }
2472
 
2473
    @Override
2474
    public String toString() {
4496 mandeep.dh 2475
      StringBuilder sb = new StringBuilder("getInventoryItem_args(");
2832 chandransh 2476
      boolean first = true;
2477
 
4496 mandeep.dh 2478
      sb.append("serialNumber:");
2479
      if (this.serialNumber == null) {
2480
        sb.append("null");
2481
      } else {
2482
        sb.append(this.serialNumber);
2483
      }
2832 chandransh 2484
      first = false;
2485
      sb.append(")");
2486
      return sb.toString();
2487
    }
2488
 
3430 rajveer 2489
    public void validate() throws org.apache.thrift.TException {
2832 chandransh 2490
      // check for required fields
2491
    }
2492
 
3430 rajveer 2493
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
2494
      try {
2495
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
2496
      } catch (org.apache.thrift.TException te) {
2497
        throw new java.io.IOException(te);
2498
      }
2499
    }
2500
 
2501
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
2502
      try {
2503
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
2504
      } catch (org.apache.thrift.TException te) {
2505
        throw new java.io.IOException(te);
2506
      }
2507
    }
2508
 
2832 chandransh 2509
  }
2510
 
4496 mandeep.dh 2511
  public static class getInventoryItem_result implements org.apache.thrift.TBase<getInventoryItem_result, getInventoryItem_result._Fields>, java.io.Serializable, Cloneable   {
2512
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryItem_result");
2832 chandransh 2513
 
3430 rajveer 2514
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
4541 mandeep.dh 2515
    private static final org.apache.thrift.protocol.TField WEX_FIELD_DESC = new org.apache.thrift.protocol.TField("wex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
2832 chandransh 2516
 
4496 mandeep.dh 2517
    private InventoryItem success; // required
4541 mandeep.dh 2518
    private WarehouseServiceException wex; // required
2832 chandransh 2519
 
2520
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2521
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4541 mandeep.dh 2522
      SUCCESS((short)0, "success"),
2523
      WEX((short)1, "wex");
2832 chandransh 2524
 
2525
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2526
 
2527
      static {
2528
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2529
          byName.put(field.getFieldName(), field);
2530
        }
2531
      }
2532
 
2533
      /**
2534
       * Find the _Fields constant that matches fieldId, or null if its not found.
2535
       */
2536
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2537
        switch(fieldId) {
2538
          case 0: // SUCCESS
2539
            return SUCCESS;
4541 mandeep.dh 2540
          case 1: // WEX
2541
            return WEX;
3430 rajveer 2542
          default:
2543
            return null;
2544
        }
2832 chandransh 2545
      }
2546
 
2547
      /**
2548
       * Find the _Fields constant that matches fieldId, throwing an exception
2549
       * if it is not found.
2550
       */
2551
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2552
        _Fields fields = findByThriftId(fieldId);
2553
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2554
        return fields;
2555
      }
2556
 
2557
      /**
2558
       * Find the _Fields constant that matches name, or null if its not found.
2559
       */
2560
      public static _Fields findByName(String name) {
2561
        return byName.get(name);
2562
      }
2563
 
2564
      private final short _thriftId;
2565
      private final String _fieldName;
2566
 
2567
      _Fields(short thriftId, String fieldName) {
2568
        _thriftId = thriftId;
2569
        _fieldName = fieldName;
2570
      }
2571
 
2572
      public short getThriftFieldId() {
2573
        return _thriftId;
2574
      }
2575
 
2576
      public String getFieldName() {
2577
        return _fieldName;
2578
      }
2579
    }
2580
 
2581
    // isset id assignments
2582
 
3430 rajveer 2583
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2832 chandransh 2584
    static {
3430 rajveer 2585
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2586
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4496 mandeep.dh 2587
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class)));
4541 mandeep.dh 2588
      tmpMap.put(_Fields.WEX, new org.apache.thrift.meta_data.FieldMetaData("wex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2589
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3430 rajveer 2590
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4496 mandeep.dh 2591
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryItem_result.class, metaDataMap);
2832 chandransh 2592
    }
2593
 
4496 mandeep.dh 2594
    public getInventoryItem_result() {
2832 chandransh 2595
    }
2596
 
4496 mandeep.dh 2597
    public getInventoryItem_result(
4541 mandeep.dh 2598
      InventoryItem success,
2599
      WarehouseServiceException wex)
2832 chandransh 2600
    {
2601
      this();
2602
      this.success = success;
4541 mandeep.dh 2603
      this.wex = wex;
2832 chandransh 2604
    }
2605
 
2606
    /**
2607
     * Performs a deep copy on <i>other</i>.
2608
     */
4496 mandeep.dh 2609
    public getInventoryItem_result(getInventoryItem_result other) {
2832 chandransh 2610
      if (other.isSetSuccess()) {
4496 mandeep.dh 2611
        this.success = new InventoryItem(other.success);
2832 chandransh 2612
      }
4541 mandeep.dh 2613
      if (other.isSetWex()) {
2614
        this.wex = new WarehouseServiceException(other.wex);
2615
      }
2832 chandransh 2616
    }
2617
 
4496 mandeep.dh 2618
    public getInventoryItem_result deepCopy() {
2619
      return new getInventoryItem_result(this);
2832 chandransh 2620
    }
2621
 
3430 rajveer 2622
    @Override
2623
    public void clear() {
2624
      this.success = null;
4541 mandeep.dh 2625
      this.wex = null;
2832 chandransh 2626
    }
2627
 
4496 mandeep.dh 2628
    public InventoryItem getSuccess() {
2832 chandransh 2629
      return this.success;
2630
    }
2631
 
4496 mandeep.dh 2632
    public void setSuccess(InventoryItem success) {
2832 chandransh 2633
      this.success = success;
2634
    }
2635
 
2636
    public void unsetSuccess() {
2637
      this.success = null;
2638
    }
2639
 
3430 rajveer 2640
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2832 chandransh 2641
    public boolean isSetSuccess() {
2642
      return this.success != null;
2643
    }
2644
 
2645
    public void setSuccessIsSet(boolean value) {
2646
      if (!value) {
2647
        this.success = null;
2648
      }
2649
    }
2650
 
4541 mandeep.dh 2651
    public WarehouseServiceException getWex() {
2652
      return this.wex;
2653
    }
2654
 
2655
    public void setWex(WarehouseServiceException wex) {
2656
      this.wex = wex;
2657
    }
2658
 
2659
    public void unsetWex() {
2660
      this.wex = null;
2661
    }
2662
 
2663
    /** Returns true if field wex is set (has been assigned a value) and false otherwise */
2664
    public boolean isSetWex() {
2665
      return this.wex != null;
2666
    }
2667
 
2668
    public void setWexIsSet(boolean value) {
2669
      if (!value) {
2670
        this.wex = null;
2671
      }
2672
    }
2673
 
2832 chandransh 2674
    public void setFieldValue(_Fields field, Object value) {
2675
      switch (field) {
2676
      case SUCCESS:
2677
        if (value == null) {
2678
          unsetSuccess();
2679
        } else {
4496 mandeep.dh 2680
          setSuccess((InventoryItem)value);
2832 chandransh 2681
        }
2682
        break;
2683
 
4541 mandeep.dh 2684
      case WEX:
2685
        if (value == null) {
2686
          unsetWex();
2687
        } else {
2688
          setWex((WarehouseServiceException)value);
2689
        }
2690
        break;
2691
 
2832 chandransh 2692
      }
2693
    }
2694
 
2695
    public Object getFieldValue(_Fields field) {
2696
      switch (field) {
2697
      case SUCCESS:
2698
        return getSuccess();
2699
 
4541 mandeep.dh 2700
      case WEX:
2701
        return getWex();
2702
 
2832 chandransh 2703
      }
2704
      throw new IllegalStateException();
2705
    }
2706
 
3430 rajveer 2707
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2708
    public boolean isSet(_Fields field) {
2709
      if (field == null) {
2710
        throw new IllegalArgumentException();
2711
      }
2832 chandransh 2712
 
2713
      switch (field) {
2714
      case SUCCESS:
2715
        return isSetSuccess();
4541 mandeep.dh 2716
      case WEX:
2717
        return isSetWex();
2832 chandransh 2718
      }
2719
      throw new IllegalStateException();
2720
    }
2721
 
2722
    @Override
2723
    public boolean equals(Object that) {
2724
      if (that == null)
2725
        return false;
4496 mandeep.dh 2726
      if (that instanceof getInventoryItem_result)
2727
        return this.equals((getInventoryItem_result)that);
2832 chandransh 2728
      return false;
2729
    }
2730
 
4496 mandeep.dh 2731
    public boolean equals(getInventoryItem_result that) {
2832 chandransh 2732
      if (that == null)
2733
        return false;
2734
 
2735
      boolean this_present_success = true && this.isSetSuccess();
2736
      boolean that_present_success = true && that.isSetSuccess();
2737
      if (this_present_success || that_present_success) {
2738
        if (!(this_present_success && that_present_success))
2739
          return false;
2740
        if (!this.success.equals(that.success))
2741
          return false;
2742
      }
2743
 
4541 mandeep.dh 2744
      boolean this_present_wex = true && this.isSetWex();
2745
      boolean that_present_wex = true && that.isSetWex();
2746
      if (this_present_wex || that_present_wex) {
2747
        if (!(this_present_wex && that_present_wex))
2748
          return false;
2749
        if (!this.wex.equals(that.wex))
2750
          return false;
2751
      }
2752
 
2832 chandransh 2753
      return true;
2754
    }
2755
 
2756
    @Override
2757
    public int hashCode() {
2758
      return 0;
2759
    }
2760
 
4496 mandeep.dh 2761
    public int compareTo(getInventoryItem_result other) {
2832 chandransh 2762
      if (!getClass().equals(other.getClass())) {
2763
        return getClass().getName().compareTo(other.getClass().getName());
2764
      }
2765
 
2766
      int lastComparison = 0;
4496 mandeep.dh 2767
      getInventoryItem_result typedOther = (getInventoryItem_result)other;
2832 chandransh 2768
 
3430 rajveer 2769
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
2832 chandransh 2770
      if (lastComparison != 0) {
2771
        return lastComparison;
2772
      }
3430 rajveer 2773
      if (isSetSuccess()) {
2774
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
2775
        if (lastComparison != 0) {
2776
          return lastComparison;
2777
        }
2832 chandransh 2778
      }
4541 mandeep.dh 2779
      lastComparison = Boolean.valueOf(isSetWex()).compareTo(typedOther.isSetWex());
2780
      if (lastComparison != 0) {
2781
        return lastComparison;
2782
      }
2783
      if (isSetWex()) {
2784
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.wex, typedOther.wex);
2785
        if (lastComparison != 0) {
2786
          return lastComparison;
2787
        }
2788
      }
2832 chandransh 2789
      return 0;
2790
    }
2791
 
3430 rajveer 2792
    public _Fields fieldForId(int fieldId) {
2793
      return _Fields.findByThriftId(fieldId);
2794
    }
2795
 
2796
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2797
      org.apache.thrift.protocol.TField field;
2832 chandransh 2798
      iprot.readStructBegin();
2799
      while (true)
2800
      {
2801
        field = iprot.readFieldBegin();
3430 rajveer 2802
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2832 chandransh 2803
          break;
2804
        }
3430 rajveer 2805
        switch (field.id) {
2806
          case 0: // SUCCESS
2807
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4496 mandeep.dh 2808
              this.success = new InventoryItem();
3430 rajveer 2809
              this.success.read(iprot);
2810
            } else { 
2811
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2812
            }
2813
            break;
4541 mandeep.dh 2814
          case 1: // WEX
2815
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
2816
              this.wex = new WarehouseServiceException();
2817
              this.wex.read(iprot);
2818
            } else { 
2819
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2820
            }
2821
            break;
3430 rajveer 2822
          default:
2823
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2832 chandransh 2824
        }
3430 rajveer 2825
        iprot.readFieldEnd();
2832 chandransh 2826
      }
2827
      iprot.readStructEnd();
2828
      validate();
2829
    }
2830
 
3430 rajveer 2831
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2832 chandransh 2832
      oprot.writeStructBegin(STRUCT_DESC);
2833
 
2834
      if (this.isSetSuccess()) {
2835
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
2836
        this.success.write(oprot);
2837
        oprot.writeFieldEnd();
4541 mandeep.dh 2838
      } else if (this.isSetWex()) {
2839
        oprot.writeFieldBegin(WEX_FIELD_DESC);
2840
        this.wex.write(oprot);
2841
        oprot.writeFieldEnd();
2832 chandransh 2842
      }
2843
      oprot.writeFieldStop();
2844
      oprot.writeStructEnd();
2845
    }
2846
 
2847
    @Override
2848
    public String toString() {
4496 mandeep.dh 2849
      StringBuilder sb = new StringBuilder("getInventoryItem_result(");
2832 chandransh 2850
      boolean first = true;
2851
 
2852
      sb.append("success:");
2853
      if (this.success == null) {
2854
        sb.append("null");
2855
      } else {
2856
        sb.append(this.success);
2857
      }
2858
      first = false;
4541 mandeep.dh 2859
      if (!first) sb.append(", ");
2860
      sb.append("wex:");
2861
      if (this.wex == null) {
2862
        sb.append("null");
2863
      } else {
2864
        sb.append(this.wex);
2865
      }
2866
      first = false;
2832 chandransh 2867
      sb.append(")");
2868
      return sb.toString();
2869
    }
2870
 
3430 rajveer 2871
    public void validate() throws org.apache.thrift.TException {
2832 chandransh 2872
      // check for required fields
2873
    }
2874
 
3430 rajveer 2875
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
2876
      try {
2877
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
2878
      } catch (org.apache.thrift.TException te) {
2879
        throw new java.io.IOException(te);
2880
      }
2881
    }
2882
 
2883
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
2884
      try {
2885
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
2886
      } catch (org.apache.thrift.TException te) {
2887
        throw new java.io.IOException(te);
2888
      }
2889
    }
2890
 
2832 chandransh 2891
  }
2892
 
5361 mandeep.dh 2893
  public static class getNonSeralizedInventoryItem_args implements org.apache.thrift.TBase<getNonSeralizedInventoryItem_args, getNonSeralizedInventoryItem_args._Fields>, java.io.Serializable, Cloneable   {
2894
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getNonSeralizedInventoryItem_args");
2820 chandransh 2895
 
5530 mandeep.dh 2896
    private static final org.apache.thrift.protocol.TField ITEM_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("itemNumber", org.apache.thrift.protocol.TType.STRING, (short)1);
2897
    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)2);
2898
    private static final org.apache.thrift.protocol.TField FULFILMENT_WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("fulfilmentWarehouseId", org.apache.thrift.protocol.TType.I64, (short)3);
2820 chandransh 2899
 
5530 mandeep.dh 2900
    private String itemNumber; // required
4496 mandeep.dh 2901
    private long itemId; // required
5530 mandeep.dh 2902
    private long fulfilmentWarehouseId; // required
2820 chandransh 2903
 
2904
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2905
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5530 mandeep.dh 2906
      ITEM_NUMBER((short)1, "itemNumber"),
2907
      ITEM_ID((short)2, "itemId"),
2908
      FULFILMENT_WAREHOUSE_ID((short)3, "fulfilmentWarehouseId");
2820 chandransh 2909
 
2910
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2911
 
2912
      static {
2913
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2914
          byName.put(field.getFieldName(), field);
2915
        }
2916
      }
2917
 
2918
      /**
2919
       * Find the _Fields constant that matches fieldId, or null if its not found.
2920
       */
2921
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2922
        switch(fieldId) {
5530 mandeep.dh 2923
          case 1: // ITEM_NUMBER
2924
            return ITEM_NUMBER;
2925
          case 2: // ITEM_ID
4496 mandeep.dh 2926
            return ITEM_ID;
5530 mandeep.dh 2927
          case 3: // FULFILMENT_WAREHOUSE_ID
2928
            return FULFILMENT_WAREHOUSE_ID;
3430 rajveer 2929
          default:
2930
            return null;
2931
        }
2820 chandransh 2932
      }
2933
 
2934
      /**
2935
       * Find the _Fields constant that matches fieldId, throwing an exception
2936
       * if it is not found.
2937
       */
2938
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2939
        _Fields fields = findByThriftId(fieldId);
2940
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2941
        return fields;
2942
      }
2943
 
2944
      /**
2945
       * Find the _Fields constant that matches name, or null if its not found.
2946
       */
2947
      public static _Fields findByName(String name) {
2948
        return byName.get(name);
2949
      }
2950
 
2951
      private final short _thriftId;
2952
      private final String _fieldName;
2953
 
2954
      _Fields(short thriftId, String fieldName) {
2955
        _thriftId = thriftId;
2956
        _fieldName = fieldName;
2957
      }
2958
 
2959
      public short getThriftFieldId() {
2960
        return _thriftId;
2961
      }
2962
 
2963
      public String getFieldName() {
2964
        return _fieldName;
2965
      }
2966
    }
2967
 
2968
    // isset id assignments
4496 mandeep.dh 2969
    private static final int __ITEMID_ISSET_ID = 0;
5530 mandeep.dh 2970
    private static final int __FULFILMENTWAREHOUSEID_ISSET_ID = 1;
5361 mandeep.dh 2971
    private BitSet __isset_bit_vector = new BitSet(2);
2820 chandransh 2972
 
3430 rajveer 2973
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2820 chandransh 2974
    static {
3430 rajveer 2975
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5530 mandeep.dh 2976
      tmpMap.put(_Fields.ITEM_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("itemNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2977
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
4496 mandeep.dh 2978
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3430 rajveer 2979
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5530 mandeep.dh 2980
      tmpMap.put(_Fields.FULFILMENT_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("fulfilmentWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4496 mandeep.dh 2981
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3430 rajveer 2982
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5361 mandeep.dh 2983
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getNonSeralizedInventoryItem_args.class, metaDataMap);
2820 chandransh 2984
    }
2985
 
5361 mandeep.dh 2986
    public getNonSeralizedInventoryItem_args() {
2820 chandransh 2987
    }
2988
 
5361 mandeep.dh 2989
    public getNonSeralizedInventoryItem_args(
5530 mandeep.dh 2990
      String itemNumber,
4496 mandeep.dh 2991
      long itemId,
5530 mandeep.dh 2992
      long fulfilmentWarehouseId)
2820 chandransh 2993
    {
2994
      this();
5530 mandeep.dh 2995
      this.itemNumber = itemNumber;
4496 mandeep.dh 2996
      this.itemId = itemId;
2997
      setItemIdIsSet(true);
5530 mandeep.dh 2998
      this.fulfilmentWarehouseId = fulfilmentWarehouseId;
2999
      setFulfilmentWarehouseIdIsSet(true);
2820 chandransh 3000
    }
3001
 
3002
    /**
3003
     * Performs a deep copy on <i>other</i>.
3004
     */
5361 mandeep.dh 3005
    public getNonSeralizedInventoryItem_args(getNonSeralizedInventoryItem_args other) {
2820 chandransh 3006
      __isset_bit_vector.clear();
3007
      __isset_bit_vector.or(other.__isset_bit_vector);
5530 mandeep.dh 3008
      if (other.isSetItemNumber()) {
3009
        this.itemNumber = other.itemNumber;
3010
      }
4496 mandeep.dh 3011
      this.itemId = other.itemId;
5530 mandeep.dh 3012
      this.fulfilmentWarehouseId = other.fulfilmentWarehouseId;
2820 chandransh 3013
    }
3014
 
5361 mandeep.dh 3015
    public getNonSeralizedInventoryItem_args deepCopy() {
3016
      return new getNonSeralizedInventoryItem_args(this);
2820 chandransh 3017
    }
3018
 
3430 rajveer 3019
    @Override
3020
    public void clear() {
5530 mandeep.dh 3021
      this.itemNumber = null;
4496 mandeep.dh 3022
      setItemIdIsSet(false);
3023
      this.itemId = 0;
5530 mandeep.dh 3024
      setFulfilmentWarehouseIdIsSet(false);
3025
      this.fulfilmentWarehouseId = 0;
2820 chandransh 3026
    }
3027
 
5530 mandeep.dh 3028
    public String getItemNumber() {
3029
      return this.itemNumber;
3030
    }
3031
 
3032
    public void setItemNumber(String itemNumber) {
3033
      this.itemNumber = itemNumber;
3034
    }
3035
 
3036
    public void unsetItemNumber() {
3037
      this.itemNumber = null;
3038
    }
3039
 
3040
    /** Returns true if field itemNumber is set (has been assigned a value) and false otherwise */
3041
    public boolean isSetItemNumber() {
3042
      return this.itemNumber != null;
3043
    }
3044
 
3045
    public void setItemNumberIsSet(boolean value) {
3046
      if (!value) {
3047
        this.itemNumber = null;
3048
      }
3049
    }
3050
 
4496 mandeep.dh 3051
    public long getItemId() {
3052
      return this.itemId;
2820 chandransh 3053
    }
3054
 
4496 mandeep.dh 3055
    public void setItemId(long itemId) {
3056
      this.itemId = itemId;
3057
      setItemIdIsSet(true);
2820 chandransh 3058
    }
3059
 
4496 mandeep.dh 3060
    public void unsetItemId() {
3061
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
2820 chandransh 3062
    }
3063
 
4496 mandeep.dh 3064
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
3065
    public boolean isSetItemId() {
3066
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
2820 chandransh 3067
    }
3068
 
4496 mandeep.dh 3069
    public void setItemIdIsSet(boolean value) {
3070
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
2820 chandransh 3071
    }
3072
 
5530 mandeep.dh 3073
    public long getFulfilmentWarehouseId() {
3074
      return this.fulfilmentWarehouseId;
2820 chandransh 3075
    }
3076
 
5530 mandeep.dh 3077
    public void setFulfilmentWarehouseId(long fulfilmentWarehouseId) {
3078
      this.fulfilmentWarehouseId = fulfilmentWarehouseId;
3079
      setFulfilmentWarehouseIdIsSet(true);
2820 chandransh 3080
    }
3081
 
5530 mandeep.dh 3082
    public void unsetFulfilmentWarehouseId() {
3083
      __isset_bit_vector.clear(__FULFILMENTWAREHOUSEID_ISSET_ID);
2820 chandransh 3084
    }
3085
 
5530 mandeep.dh 3086
    /** Returns true if field fulfilmentWarehouseId is set (has been assigned a value) and false otherwise */
3087
    public boolean isSetFulfilmentWarehouseId() {
3088
      return __isset_bit_vector.get(__FULFILMENTWAREHOUSEID_ISSET_ID);
2820 chandransh 3089
    }
3090
 
5530 mandeep.dh 3091
    public void setFulfilmentWarehouseIdIsSet(boolean value) {
3092
      __isset_bit_vector.set(__FULFILMENTWAREHOUSEID_ISSET_ID, value);
2820 chandransh 3093
    }
3094
 
3095
    public void setFieldValue(_Fields field, Object value) {
3096
      switch (field) {
5530 mandeep.dh 3097
      case ITEM_NUMBER:
3098
        if (value == null) {
3099
          unsetItemNumber();
3100
        } else {
3101
          setItemNumber((String)value);
3102
        }
3103
        break;
3104
 
4496 mandeep.dh 3105
      case ITEM_ID:
2820 chandransh 3106
        if (value == null) {
4496 mandeep.dh 3107
          unsetItemId();
2820 chandransh 3108
        } else {
4496 mandeep.dh 3109
          setItemId((Long)value);
2820 chandransh 3110
        }
3111
        break;
3112
 
5530 mandeep.dh 3113
      case FULFILMENT_WAREHOUSE_ID:
2820 chandransh 3114
        if (value == null) {
5530 mandeep.dh 3115
          unsetFulfilmentWarehouseId();
2820 chandransh 3116
        } else {
5530 mandeep.dh 3117
          setFulfilmentWarehouseId((Long)value);
2820 chandransh 3118
        }
3119
        break;
3120
 
3121
      }
3122
    }
3123
 
3124
    public Object getFieldValue(_Fields field) {
3125
      switch (field) {
5530 mandeep.dh 3126
      case ITEM_NUMBER:
3127
        return getItemNumber();
3128
 
4496 mandeep.dh 3129
      case ITEM_ID:
3130
        return Long.valueOf(getItemId());
2820 chandransh 3131
 
5530 mandeep.dh 3132
      case FULFILMENT_WAREHOUSE_ID:
3133
        return Long.valueOf(getFulfilmentWarehouseId());
2820 chandransh 3134
 
3135
      }
3136
      throw new IllegalStateException();
3137
    }
3138
 
3430 rajveer 3139
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3140
    public boolean isSet(_Fields field) {
3141
      if (field == null) {
3142
        throw new IllegalArgumentException();
3143
      }
2820 chandransh 3144
 
3145
      switch (field) {
5530 mandeep.dh 3146
      case ITEM_NUMBER:
3147
        return isSetItemNumber();
4496 mandeep.dh 3148
      case ITEM_ID:
3149
        return isSetItemId();
5530 mandeep.dh 3150
      case FULFILMENT_WAREHOUSE_ID:
3151
        return isSetFulfilmentWarehouseId();
2820 chandransh 3152
      }
3153
      throw new IllegalStateException();
3154
    }
3155
 
3156
    @Override
3157
    public boolean equals(Object that) {
3158
      if (that == null)
3159
        return false;
5361 mandeep.dh 3160
      if (that instanceof getNonSeralizedInventoryItem_args)
3161
        return this.equals((getNonSeralizedInventoryItem_args)that);
2820 chandransh 3162
      return false;
3163
    }
3164
 
5361 mandeep.dh 3165
    public boolean equals(getNonSeralizedInventoryItem_args that) {
2820 chandransh 3166
      if (that == null)
3167
        return false;
3168
 
5530 mandeep.dh 3169
      boolean this_present_itemNumber = true && this.isSetItemNumber();
3170
      boolean that_present_itemNumber = true && that.isSetItemNumber();
3171
      if (this_present_itemNumber || that_present_itemNumber) {
3172
        if (!(this_present_itemNumber && that_present_itemNumber))
3173
          return false;
3174
        if (!this.itemNumber.equals(that.itemNumber))
3175
          return false;
3176
      }
3177
 
4496 mandeep.dh 3178
      boolean this_present_itemId = true;
3179
      boolean that_present_itemId = true;
3180
      if (this_present_itemId || that_present_itemId) {
3181
        if (!(this_present_itemId && that_present_itemId))
2820 chandransh 3182
          return false;
4496 mandeep.dh 3183
        if (this.itemId != that.itemId)
2820 chandransh 3184
          return false;
3185
      }
3186
 
5530 mandeep.dh 3187
      boolean this_present_fulfilmentWarehouseId = true;
3188
      boolean that_present_fulfilmentWarehouseId = true;
3189
      if (this_present_fulfilmentWarehouseId || that_present_fulfilmentWarehouseId) {
3190
        if (!(this_present_fulfilmentWarehouseId && that_present_fulfilmentWarehouseId))
2820 chandransh 3191
          return false;
5530 mandeep.dh 3192
        if (this.fulfilmentWarehouseId != that.fulfilmentWarehouseId)
2820 chandransh 3193
          return false;
3194
      }
3195
 
3196
      return true;
3197
    }
3198
 
3199
    @Override
3200
    public int hashCode() {
3201
      return 0;
3202
    }
3203
 
5361 mandeep.dh 3204
    public int compareTo(getNonSeralizedInventoryItem_args other) {
2820 chandransh 3205
      if (!getClass().equals(other.getClass())) {
3206
        return getClass().getName().compareTo(other.getClass().getName());
3207
      }
3208
 
3209
      int lastComparison = 0;
5361 mandeep.dh 3210
      getNonSeralizedInventoryItem_args typedOther = (getNonSeralizedInventoryItem_args)other;
2820 chandransh 3211
 
5530 mandeep.dh 3212
      lastComparison = Boolean.valueOf(isSetItemNumber()).compareTo(typedOther.isSetItemNumber());
3213
      if (lastComparison != 0) {
3214
        return lastComparison;
3215
      }
3216
      if (isSetItemNumber()) {
3217
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemNumber, typedOther.itemNumber);
3218
        if (lastComparison != 0) {
3219
          return lastComparison;
3220
        }
3221
      }
4496 mandeep.dh 3222
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
2820 chandransh 3223
      if (lastComparison != 0) {
3224
        return lastComparison;
3225
      }
4496 mandeep.dh 3226
      if (isSetItemId()) {
3227
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
3430 rajveer 3228
        if (lastComparison != 0) {
3229
          return lastComparison;
3230
        }
2820 chandransh 3231
      }
5530 mandeep.dh 3232
      lastComparison = Boolean.valueOf(isSetFulfilmentWarehouseId()).compareTo(typedOther.isSetFulfilmentWarehouseId());
2820 chandransh 3233
      if (lastComparison != 0) {
3234
        return lastComparison;
3235
      }
5530 mandeep.dh 3236
      if (isSetFulfilmentWarehouseId()) {
3237
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fulfilmentWarehouseId, typedOther.fulfilmentWarehouseId);
3430 rajveer 3238
        if (lastComparison != 0) {
3239
          return lastComparison;
3240
        }
2820 chandransh 3241
      }
3242
      return 0;
3243
    }
3244
 
3430 rajveer 3245
    public _Fields fieldForId(int fieldId) {
3246
      return _Fields.findByThriftId(fieldId);
3247
    }
3248
 
3249
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3250
      org.apache.thrift.protocol.TField field;
2820 chandransh 3251
      iprot.readStructBegin();
3252
      while (true)
3253
      {
3254
        field = iprot.readFieldBegin();
3430 rajveer 3255
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2820 chandransh 3256
          break;
3257
        }
3430 rajveer 3258
        switch (field.id) {
5530 mandeep.dh 3259
          case 1: // ITEM_NUMBER
3260
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
3261
              this.itemNumber = iprot.readString();
3262
            } else { 
3263
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3264
            }
3265
            break;
3266
          case 2: // ITEM_ID
3430 rajveer 3267
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4496 mandeep.dh 3268
              this.itemId = iprot.readI64();
3269
              setItemIdIsSet(true);
3430 rajveer 3270
            } else { 
3271
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3272
            }
3273
            break;
5530 mandeep.dh 3274
          case 3: // FULFILMENT_WAREHOUSE_ID
4496 mandeep.dh 3275
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5530 mandeep.dh 3276
              this.fulfilmentWarehouseId = iprot.readI64();
3277
              setFulfilmentWarehouseIdIsSet(true);
3430 rajveer 3278
            } else { 
3279
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3280
            }
3281
            break;
3282
          default:
3283
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2820 chandransh 3284
        }
3430 rajveer 3285
        iprot.readFieldEnd();
2820 chandransh 3286
      }
3287
      iprot.readStructEnd();
3288
      validate();
3289
    }
3290
 
3430 rajveer 3291
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2820 chandransh 3292
      validate();
3293
 
3294
      oprot.writeStructBegin(STRUCT_DESC);
5530 mandeep.dh 3295
      if (this.itemNumber != null) {
3296
        oprot.writeFieldBegin(ITEM_NUMBER_FIELD_DESC);
3297
        oprot.writeString(this.itemNumber);
3298
        oprot.writeFieldEnd();
3299
      }
4496 mandeep.dh 3300
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
3301
      oprot.writeI64(this.itemId);
2820 chandransh 3302
      oprot.writeFieldEnd();
5530 mandeep.dh 3303
      oprot.writeFieldBegin(FULFILMENT_WAREHOUSE_ID_FIELD_DESC);
3304
      oprot.writeI64(this.fulfilmentWarehouseId);
2820 chandransh 3305
      oprot.writeFieldEnd();
3306
      oprot.writeFieldStop();
3307
      oprot.writeStructEnd();
3308
    }
3309
 
3310
    @Override
3311
    public String toString() {
5361 mandeep.dh 3312
      StringBuilder sb = new StringBuilder("getNonSeralizedInventoryItem_args(");
2820 chandransh 3313
      boolean first = true;
3314
 
5530 mandeep.dh 3315
      sb.append("itemNumber:");
3316
      if (this.itemNumber == null) {
3317
        sb.append("null");
3318
      } else {
3319
        sb.append(this.itemNumber);
3320
      }
3321
      first = false;
3322
      if (!first) sb.append(", ");
4496 mandeep.dh 3323
      sb.append("itemId:");
3324
      sb.append(this.itemId);
2820 chandransh 3325
      first = false;
3326
      if (!first) sb.append(", ");
5530 mandeep.dh 3327
      sb.append("fulfilmentWarehouseId:");
3328
      sb.append(this.fulfilmentWarehouseId);
2820 chandransh 3329
      first = false;
3330
      sb.append(")");
3331
      return sb.toString();
3332
    }
3333
 
3430 rajveer 3334
    public void validate() throws org.apache.thrift.TException {
2820 chandransh 3335
      // check for required fields
3336
    }
3337
 
3430 rajveer 3338
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3339
      try {
3340
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3341
      } catch (org.apache.thrift.TException te) {
3342
        throw new java.io.IOException(te);
3343
      }
3344
    }
3345
 
3346
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3347
      try {
4496 mandeep.dh 3348
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
3349
        __isset_bit_vector = new BitSet(1);
3430 rajveer 3350
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3351
      } catch (org.apache.thrift.TException te) {
3352
        throw new java.io.IOException(te);
3353
      }
3354
    }
3355
 
2820 chandransh 3356
  }
3357
 
5361 mandeep.dh 3358
  public static class getNonSeralizedInventoryItem_result implements org.apache.thrift.TBase<getNonSeralizedInventoryItem_result, getNonSeralizedInventoryItem_result._Fields>, java.io.Serializable, Cloneable   {
3359
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getNonSeralizedInventoryItem_result");
2820 chandransh 3360
 
5361 mandeep.dh 3361
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
3362
    private static final org.apache.thrift.protocol.TField WEX_FIELD_DESC = new org.apache.thrift.protocol.TField("wex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
2820 chandransh 3363
 
5361 mandeep.dh 3364
    private InventoryItem success; // required
3365
    private WarehouseServiceException wex; // required
2820 chandransh 3366
 
3367
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3368
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5361 mandeep.dh 3369
      SUCCESS((short)0, "success"),
3370
      WEX((short)1, "wex");
2820 chandransh 3371
 
3372
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3373
 
3374
      static {
3375
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3376
          byName.put(field.getFieldName(), field);
3377
        }
3378
      }
3379
 
3380
      /**
3381
       * Find the _Fields constant that matches fieldId, or null if its not found.
3382
       */
3383
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3384
        switch(fieldId) {
3385
          case 0: // SUCCESS
3386
            return SUCCESS;
5361 mandeep.dh 3387
          case 1: // WEX
3388
            return WEX;
3430 rajveer 3389
          default:
3390
            return null;
3391
        }
2820 chandransh 3392
      }
3393
 
3394
      /**
3395
       * Find the _Fields constant that matches fieldId, throwing an exception
3396
       * if it is not found.
3397
       */
3398
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3399
        _Fields fields = findByThriftId(fieldId);
3400
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3401
        return fields;
3402
      }
3403
 
3404
      /**
3405
       * Find the _Fields constant that matches name, or null if its not found.
3406
       */
3407
      public static _Fields findByName(String name) {
3408
        return byName.get(name);
3409
      }
3410
 
3411
      private final short _thriftId;
3412
      private final String _fieldName;
3413
 
3414
      _Fields(short thriftId, String fieldName) {
3415
        _thriftId = thriftId;
3416
        _fieldName = fieldName;
3417
      }
3418
 
3419
      public short getThriftFieldId() {
3420
        return _thriftId;
3421
      }
3422
 
3423
      public String getFieldName() {
3424
        return _fieldName;
3425
      }
3426
    }
3427
 
3428
    // isset id assignments
3429
 
3430 rajveer 3430
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2820 chandransh 3431
    static {
3430 rajveer 3432
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3433
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5361 mandeep.dh 3434
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class)));
3435
      tmpMap.put(_Fields.WEX, new org.apache.thrift.meta_data.FieldMetaData("wex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3436
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3430 rajveer 3437
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5361 mandeep.dh 3438
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getNonSeralizedInventoryItem_result.class, metaDataMap);
2820 chandransh 3439
    }
3440
 
5361 mandeep.dh 3441
    public getNonSeralizedInventoryItem_result() {
2820 chandransh 3442
    }
3443
 
5361 mandeep.dh 3444
    public getNonSeralizedInventoryItem_result(
3445
      InventoryItem success,
3446
      WarehouseServiceException wex)
2820 chandransh 3447
    {
3448
      this();
3449
      this.success = success;
5361 mandeep.dh 3450
      this.wex = wex;
2820 chandransh 3451
    }
3452
 
3453
    /**
3454
     * Performs a deep copy on <i>other</i>.
3455
     */
5361 mandeep.dh 3456
    public getNonSeralizedInventoryItem_result(getNonSeralizedInventoryItem_result other) {
4496 mandeep.dh 3457
      if (other.isSetSuccess()) {
5361 mandeep.dh 3458
        this.success = new InventoryItem(other.success);
2820 chandransh 3459
      }
5361 mandeep.dh 3460
      if (other.isSetWex()) {
3461
        this.wex = new WarehouseServiceException(other.wex);
3462
      }
2820 chandransh 3463
    }
3464
 
5361 mandeep.dh 3465
    public getNonSeralizedInventoryItem_result deepCopy() {
3466
      return new getNonSeralizedInventoryItem_result(this);
2820 chandransh 3467
    }
3468
 
3430 rajveer 3469
    @Override
3470
    public void clear() {
4496 mandeep.dh 3471
      this.success = null;
5361 mandeep.dh 3472
      this.wex = null;
2820 chandransh 3473
    }
3474
 
5361 mandeep.dh 3475
    public InventoryItem getSuccess() {
2820 chandransh 3476
      return this.success;
3477
    }
3478
 
5361 mandeep.dh 3479
    public void setSuccess(InventoryItem success) {
2820 chandransh 3480
      this.success = success;
3481
    }
3482
 
3483
    public void unsetSuccess() {
4496 mandeep.dh 3484
      this.success = null;
2820 chandransh 3485
    }
3486
 
3430 rajveer 3487
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
2820 chandransh 3488
    public boolean isSetSuccess() {
4496 mandeep.dh 3489
      return this.success != null;
2820 chandransh 3490
    }
3491
 
3492
    public void setSuccessIsSet(boolean value) {
4496 mandeep.dh 3493
      if (!value) {
3494
        this.success = null;
3495
      }
2820 chandransh 3496
    }
3497
 
5361 mandeep.dh 3498
    public WarehouseServiceException getWex() {
3499
      return this.wex;
2820 chandransh 3500
    }
3501
 
5361 mandeep.dh 3502
    public void setWex(WarehouseServiceException wex) {
3503
      this.wex = wex;
2820 chandransh 3504
    }
3505
 
5361 mandeep.dh 3506
    public void unsetWex() {
3507
      this.wex = null;
2820 chandransh 3508
    }
3509
 
5361 mandeep.dh 3510
    /** Returns true if field wex is set (has been assigned a value) and false otherwise */
3511
    public boolean isSetWex() {
3512
      return this.wex != null;
2820 chandransh 3513
    }
3514
 
5361 mandeep.dh 3515
    public void setWexIsSet(boolean value) {
3516
      if (!value) {
3517
        this.wex = null;
2820 chandransh 3518
      }
3519
    }
3520
 
3521
    public void setFieldValue(_Fields field, Object value) {
3522
      switch (field) {
5361 mandeep.dh 3523
      case SUCCESS:
2820 chandransh 3524
        if (value == null) {
5361 mandeep.dh 3525
          unsetSuccess();
2820 chandransh 3526
        } else {
5361 mandeep.dh 3527
          setSuccess((InventoryItem)value);
2820 chandransh 3528
        }
3529
        break;
3530
 
5361 mandeep.dh 3531
      case WEX:
2820 chandransh 3532
        if (value == null) {
5361 mandeep.dh 3533
          unsetWex();
2820 chandransh 3534
        } else {
5361 mandeep.dh 3535
          setWex((WarehouseServiceException)value);
2820 chandransh 3536
        }
3537
        break;
3538
 
3539
      }
3540
    }
3541
 
3542
    public Object getFieldValue(_Fields field) {
3543
      switch (field) {
3544
      case SUCCESS:
4496 mandeep.dh 3545
        return getSuccess();
2820 chandransh 3546
 
5361 mandeep.dh 3547
      case WEX:
3548
        return getWex();
3549
 
2820 chandransh 3550
      }
3551
      throw new IllegalStateException();
3552
    }
3553
 
3430 rajveer 3554
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3555
    public boolean isSet(_Fields field) {
3556
      if (field == null) {
3557
        throw new IllegalArgumentException();
3558
      }
2820 chandransh 3559
 
3560
      switch (field) {
3561
      case SUCCESS:
3562
        return isSetSuccess();
5361 mandeep.dh 3563
      case WEX:
3564
        return isSetWex();
2820 chandransh 3565
      }
3566
      throw new IllegalStateException();
3567
    }
3568
 
3569
    @Override
3570
    public boolean equals(Object that) {
3571
      if (that == null)
3572
        return false;
5361 mandeep.dh 3573
      if (that instanceof getNonSeralizedInventoryItem_result)
3574
        return this.equals((getNonSeralizedInventoryItem_result)that);
2820 chandransh 3575
      return false;
3576
    }
3577
 
5361 mandeep.dh 3578
    public boolean equals(getNonSeralizedInventoryItem_result that) {
2820 chandransh 3579
      if (that == null)
3580
        return false;
3581
 
4496 mandeep.dh 3582
      boolean this_present_success = true && this.isSetSuccess();
3583
      boolean that_present_success = true && that.isSetSuccess();
2820 chandransh 3584
      if (this_present_success || that_present_success) {
3585
        if (!(this_present_success && that_present_success))
3586
          return false;
4496 mandeep.dh 3587
        if (!this.success.equals(that.success))
2820 chandransh 3588
          return false;
3589
      }
3590
 
5361 mandeep.dh 3591
      boolean this_present_wex = true && this.isSetWex();
3592
      boolean that_present_wex = true && that.isSetWex();
3593
      if (this_present_wex || that_present_wex) {
3594
        if (!(this_present_wex && that_present_wex))
4496 mandeep.dh 3595
          return false;
5361 mandeep.dh 3596
        if (!this.wex.equals(that.wex))
4496 mandeep.dh 3597
          return false;
3598
      }
3599
 
3600
      return true;
3601
    }
3602
 
3603
    @Override
3604
    public int hashCode() {
3605
      return 0;
3606
    }
3607
 
5361 mandeep.dh 3608
    public int compareTo(getNonSeralizedInventoryItem_result other) {
4496 mandeep.dh 3609
      if (!getClass().equals(other.getClass())) {
3610
        return getClass().getName().compareTo(other.getClass().getName());
3611
      }
3612
 
3613
      int lastComparison = 0;
5361 mandeep.dh 3614
      getNonSeralizedInventoryItem_result typedOther = (getNonSeralizedInventoryItem_result)other;
4496 mandeep.dh 3615
 
3616
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
3617
      if (lastComparison != 0) {
3618
        return lastComparison;
3619
      }
3620
      if (isSetSuccess()) {
3621
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3622
        if (lastComparison != 0) {
3623
          return lastComparison;
3624
        }
3625
      }
5361 mandeep.dh 3626
      lastComparison = Boolean.valueOf(isSetWex()).compareTo(typedOther.isSetWex());
2820 chandransh 3627
      if (lastComparison != 0) {
3628
        return lastComparison;
3629
      }
5361 mandeep.dh 3630
      if (isSetWex()) {
3631
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.wex, typedOther.wex);
3430 rajveer 3632
        if (lastComparison != 0) {
3633
          return lastComparison;
3634
        }
2820 chandransh 3635
      }
3636
      return 0;
3637
    }
3638
 
3430 rajveer 3639
    public _Fields fieldForId(int fieldId) {
3640
      return _Fields.findByThriftId(fieldId);
3641
    }
3642
 
3643
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3644
      org.apache.thrift.protocol.TField field;
2820 chandransh 3645
      iprot.readStructBegin();
3646
      while (true)
3647
      {
3648
        field = iprot.readFieldBegin();
3430 rajveer 3649
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2820 chandransh 3650
          break;
3651
        }
3430 rajveer 3652
        switch (field.id) {
5361 mandeep.dh 3653
          case 0: // SUCCESS
3654
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3655
              this.success = new InventoryItem();
3656
              this.success.read(iprot);
3430 rajveer 3657
            } else { 
3658
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3659
            }
3660
            break;
5361 mandeep.dh 3661
          case 1: // WEX
3662
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3663
              this.wex = new WarehouseServiceException();
3664
              this.wex.read(iprot);
4496 mandeep.dh 3665
            } else { 
3666
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3667
            }
3668
            break;
3669
          default:
3670
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3671
        }
3672
        iprot.readFieldEnd();
3673
      }
3674
      iprot.readStructEnd();
3675
      validate();
3676
    }
3677
 
3678
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3679
      oprot.writeStructBegin(STRUCT_DESC);
3680
 
3681
      if (this.isSetSuccess()) {
3682
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
5361 mandeep.dh 3683
        this.success.write(oprot);
4496 mandeep.dh 3684
        oprot.writeFieldEnd();
5361 mandeep.dh 3685
      } else if (this.isSetWex()) {
3686
        oprot.writeFieldBegin(WEX_FIELD_DESC);
3687
        this.wex.write(oprot);
3688
        oprot.writeFieldEnd();
4496 mandeep.dh 3689
      }
3690
      oprot.writeFieldStop();
3691
      oprot.writeStructEnd();
3692
    }
3693
 
3694
    @Override
3695
    public String toString() {
5361 mandeep.dh 3696
      StringBuilder sb = new StringBuilder("getNonSeralizedInventoryItem_result(");
4496 mandeep.dh 3697
      boolean first = true;
3698
 
3699
      sb.append("success:");
3700
      if (this.success == null) {
3701
        sb.append("null");
3702
      } else {
3703
        sb.append(this.success);
3704
      }
3705
      first = false;
5361 mandeep.dh 3706
      if (!first) sb.append(", ");
3707
      sb.append("wex:");
3708
      if (this.wex == null) {
3709
        sb.append("null");
3710
      } else {
3711
        sb.append(this.wex);
3712
      }
3713
      first = false;
4496 mandeep.dh 3714
      sb.append(")");
3715
      return sb.toString();
3716
    }
3717
 
3718
    public void validate() throws org.apache.thrift.TException {
3719
      // check for required fields
3720
    }
3721
 
3722
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3723
      try {
3724
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3725
      } catch (org.apache.thrift.TException te) {
3726
        throw new java.io.IOException(te);
3727
      }
3728
    }
3729
 
3730
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3731
      try {
3732
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3733
      } catch (org.apache.thrift.TException te) {
3734
        throw new java.io.IOException(te);
3735
      }
3736
    }
3737
 
3738
  }
3739
 
3740
  public static class scan_args implements org.apache.thrift.TBase<scan_args, scan_args._Fields>, java.io.Serializable, Cloneable   {
3741
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scan_args");
3383 chandransh 3742
 
5361 mandeep.dh 3743
    private static final org.apache.thrift.protocol.TField INVENTORY_ITEM_FIELD_DESC = new org.apache.thrift.protocol.TField("inventoryItem", org.apache.thrift.protocol.TType.STRUCT, (short)1);
4496 mandeep.dh 3744
    private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)2);
3745
    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)3);
5361 mandeep.dh 3746
    private static final org.apache.thrift.protocol.TField BILLING_WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("billingWarehouseId", org.apache.thrift.protocol.TType.I64, (short)4);
3383 chandransh 3747
 
5361 mandeep.dh 3748
    private InventoryItem inventoryItem; // required
4496 mandeep.dh 3749
    private ScanType type; // required
3750
    private long quantity; // required
5361 mandeep.dh 3751
    private long billingWarehouseId; // required
3383 chandransh 3752
 
3753
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3754
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5361 mandeep.dh 3755
      INVENTORY_ITEM((short)1, "inventoryItem"),
4496 mandeep.dh 3756
      /**
3757
       * 
3758
       * @see ScanType
3759
       */
3760
      TYPE((short)2, "type"),
3761
      QUANTITY((short)3, "quantity"),
5361 mandeep.dh 3762
      BILLING_WAREHOUSE_ID((short)4, "billingWarehouseId");
3383 chandransh 3763
 
3764
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3765
 
3766
      static {
3767
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3768
          byName.put(field.getFieldName(), field);
3769
        }
3770
      }
3771
 
3772
      /**
3773
       * Find the _Fields constant that matches fieldId, or null if its not found.
3774
       */
3775
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3776
        switch(fieldId) {
5361 mandeep.dh 3777
          case 1: // INVENTORY_ITEM
3778
            return INVENTORY_ITEM;
4496 mandeep.dh 3779
          case 2: // TYPE
3780
            return TYPE;
3781
          case 3: // QUANTITY
3782
            return QUANTITY;
5361 mandeep.dh 3783
          case 4: // BILLING_WAREHOUSE_ID
3784
            return BILLING_WAREHOUSE_ID;
3430 rajveer 3785
          default:
3786
            return null;
3787
        }
3383 chandransh 3788
      }
3789
 
3790
      /**
3791
       * Find the _Fields constant that matches fieldId, throwing an exception
3792
       * if it is not found.
3793
       */
3794
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3795
        _Fields fields = findByThriftId(fieldId);
3796
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3797
        return fields;
3798
      }
3799
 
3800
      /**
3801
       * Find the _Fields constant that matches name, or null if its not found.
3802
       */
3803
      public static _Fields findByName(String name) {
3804
        return byName.get(name);
3805
      }
3806
 
3807
      private final short _thriftId;
3808
      private final String _fieldName;
3809
 
3810
      _Fields(short thriftId, String fieldName) {
3811
        _thriftId = thriftId;
3812
        _fieldName = fieldName;
3813
      }
3814
 
3815
      public short getThriftFieldId() {
3816
        return _thriftId;
3817
      }
3818
 
3819
      public String getFieldName() {
3820
        return _fieldName;
3821
      }
3822
    }
3823
 
3824
    // isset id assignments
5361 mandeep.dh 3825
    private static final int __QUANTITY_ISSET_ID = 0;
3826
    private static final int __BILLINGWAREHOUSEID_ISSET_ID = 1;
3827
    private BitSet __isset_bit_vector = new BitSet(2);
3383 chandransh 3828
 
3430 rajveer 3829
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3383 chandransh 3830
    static {
3430 rajveer 3831
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5361 mandeep.dh 3832
      tmpMap.put(_Fields.INVENTORY_ITEM, new org.apache.thrift.meta_data.FieldMetaData("inventoryItem", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3833
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class)));
4496 mandeep.dh 3834
      tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3835
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ScanType.class)));
3836
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3837
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5361 mandeep.dh 3838
      tmpMap.put(_Fields.BILLING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("billingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4496 mandeep.dh 3839
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3430 rajveer 3840
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4496 mandeep.dh 3841
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scan_args.class, metaDataMap);
3383 chandransh 3842
    }
3843
 
4496 mandeep.dh 3844
    public scan_args() {
3383 chandransh 3845
    }
3846
 
4496 mandeep.dh 3847
    public scan_args(
5361 mandeep.dh 3848
      InventoryItem inventoryItem,
4496 mandeep.dh 3849
      ScanType type,
3850
      long quantity,
5361 mandeep.dh 3851
      long billingWarehouseId)
3383 chandransh 3852
    {
3853
      this();
5361 mandeep.dh 3854
      this.inventoryItem = inventoryItem;
4496 mandeep.dh 3855
      this.type = type;
3856
      this.quantity = quantity;
3857
      setQuantityIsSet(true);
5361 mandeep.dh 3858
      this.billingWarehouseId = billingWarehouseId;
3859
      setBillingWarehouseIdIsSet(true);
3383 chandransh 3860
    }
3861
 
3862
    /**
3863
     * Performs a deep copy on <i>other</i>.
3864
     */
4496 mandeep.dh 3865
    public scan_args(scan_args other) {
3383 chandransh 3866
      __isset_bit_vector.clear();
3867
      __isset_bit_vector.or(other.__isset_bit_vector);
5361 mandeep.dh 3868
      if (other.isSetInventoryItem()) {
3869
        this.inventoryItem = new InventoryItem(other.inventoryItem);
3870
      }
4496 mandeep.dh 3871
      if (other.isSetType()) {
3872
        this.type = other.type;
3873
      }
3874
      this.quantity = other.quantity;
5361 mandeep.dh 3875
      this.billingWarehouseId = other.billingWarehouseId;
3383 chandransh 3876
    }
3877
 
4496 mandeep.dh 3878
    public scan_args deepCopy() {
3879
      return new scan_args(this);
3383 chandransh 3880
    }
3881
 
3430 rajveer 3882
    @Override
3883
    public void clear() {
5361 mandeep.dh 3884
      this.inventoryItem = null;
4496 mandeep.dh 3885
      this.type = null;
3886
      setQuantityIsSet(false);
3887
      this.quantity = 0;
5361 mandeep.dh 3888
      setBillingWarehouseIdIsSet(false);
3889
      this.billingWarehouseId = 0;
3383 chandransh 3890
    }
3891
 
5361 mandeep.dh 3892
    public InventoryItem getInventoryItem() {
3893
      return this.inventoryItem;
3383 chandransh 3894
    }
3895
 
5361 mandeep.dh 3896
    public void setInventoryItem(InventoryItem inventoryItem) {
3897
      this.inventoryItem = inventoryItem;
3383 chandransh 3898
    }
3899
 
5361 mandeep.dh 3900
    public void unsetInventoryItem() {
3901
      this.inventoryItem = null;
3383 chandransh 3902
    }
3903
 
5361 mandeep.dh 3904
    /** Returns true if field inventoryItem is set (has been assigned a value) and false otherwise */
3905
    public boolean isSetInventoryItem() {
3906
      return this.inventoryItem != null;
3383 chandransh 3907
    }
3908
 
5361 mandeep.dh 3909
    public void setInventoryItemIsSet(boolean value) {
3910
      if (!value) {
3911
        this.inventoryItem = null;
3912
      }
3383 chandransh 3913
    }
3914
 
4496 mandeep.dh 3915
    /**
3916
     * 
3917
     * @see ScanType
3918
     */
3919
    public ScanType getType() {
3920
      return this.type;
3383 chandransh 3921
    }
3922
 
4496 mandeep.dh 3923
    /**
3924
     * 
3925
     * @see ScanType
3926
     */
3927
    public void setType(ScanType type) {
3928
      this.type = type;
3383 chandransh 3929
    }
3930
 
4496 mandeep.dh 3931
    public void unsetType() {
3932
      this.type = null;
3383 chandransh 3933
    }
3934
 
4496 mandeep.dh 3935
    /** Returns true if field type is set (has been assigned a value) and false otherwise */
3936
    public boolean isSetType() {
3937
      return this.type != null;
3383 chandransh 3938
    }
3939
 
4496 mandeep.dh 3940
    public void setTypeIsSet(boolean value) {
3941
      if (!value) {
3942
        this.type = null;
3943
      }
3383 chandransh 3944
    }
3945
 
4496 mandeep.dh 3946
    public long getQuantity() {
3947
      return this.quantity;
3948
    }
3949
 
3950
    public void setQuantity(long quantity) {
3951
      this.quantity = quantity;
3952
      setQuantityIsSet(true);
3953
    }
3954
 
3955
    public void unsetQuantity() {
3956
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
3957
    }
3958
 
3959
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
3960
    public boolean isSetQuantity() {
3961
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
3962
    }
3963
 
3964
    public void setQuantityIsSet(boolean value) {
3965
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
3966
    }
3967
 
5361 mandeep.dh 3968
    public long getBillingWarehouseId() {
3969
      return this.billingWarehouseId;
4496 mandeep.dh 3970
    }
3971
 
5361 mandeep.dh 3972
    public void setBillingWarehouseId(long billingWarehouseId) {
3973
      this.billingWarehouseId = billingWarehouseId;
3974
      setBillingWarehouseIdIsSet(true);
4496 mandeep.dh 3975
    }
3976
 
5361 mandeep.dh 3977
    public void unsetBillingWarehouseId() {
3978
      __isset_bit_vector.clear(__BILLINGWAREHOUSEID_ISSET_ID);
4496 mandeep.dh 3979
    }
3980
 
5361 mandeep.dh 3981
    /** Returns true if field billingWarehouseId is set (has been assigned a value) and false otherwise */
3982
    public boolean isSetBillingWarehouseId() {
3983
      return __isset_bit_vector.get(__BILLINGWAREHOUSEID_ISSET_ID);
4496 mandeep.dh 3984
    }
3985
 
5361 mandeep.dh 3986
    public void setBillingWarehouseIdIsSet(boolean value) {
3987
      __isset_bit_vector.set(__BILLINGWAREHOUSEID_ISSET_ID, value);
4496 mandeep.dh 3988
    }
3989
 
3383 chandransh 3990
    public void setFieldValue(_Fields field, Object value) {
3991
      switch (field) {
5361 mandeep.dh 3992
      case INVENTORY_ITEM:
3383 chandransh 3993
        if (value == null) {
5361 mandeep.dh 3994
          unsetInventoryItem();
3383 chandransh 3995
        } else {
5361 mandeep.dh 3996
          setInventoryItem((InventoryItem)value);
3383 chandransh 3997
        }
3998
        break;
3999
 
4496 mandeep.dh 4000
      case TYPE:
3383 chandransh 4001
        if (value == null) {
4496 mandeep.dh 4002
          unsetType();
3383 chandransh 4003
        } else {
4496 mandeep.dh 4004
          setType((ScanType)value);
3383 chandransh 4005
        }
4006
        break;
4007
 
4496 mandeep.dh 4008
      case QUANTITY:
4009
        if (value == null) {
4010
          unsetQuantity();
4011
        } else {
4012
          setQuantity((Long)value);
4013
        }
4014
        break;
4015
 
5361 mandeep.dh 4016
      case BILLING_WAREHOUSE_ID:
4496 mandeep.dh 4017
        if (value == null) {
5361 mandeep.dh 4018
          unsetBillingWarehouseId();
4496 mandeep.dh 4019
        } else {
5361 mandeep.dh 4020
          setBillingWarehouseId((Long)value);
4496 mandeep.dh 4021
        }
4022
        break;
4023
 
3383 chandransh 4024
      }
4025
    }
4026
 
4027
    public Object getFieldValue(_Fields field) {
4028
      switch (field) {
5361 mandeep.dh 4029
      case INVENTORY_ITEM:
4030
        return getInventoryItem();
3383 chandransh 4031
 
4496 mandeep.dh 4032
      case TYPE:
4033
        return getType();
3383 chandransh 4034
 
4496 mandeep.dh 4035
      case QUANTITY:
4036
        return Long.valueOf(getQuantity());
4037
 
5361 mandeep.dh 4038
      case BILLING_WAREHOUSE_ID:
4039
        return Long.valueOf(getBillingWarehouseId());
4496 mandeep.dh 4040
 
3383 chandransh 4041
      }
4042
      throw new IllegalStateException();
4043
    }
4044
 
3430 rajveer 4045
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4046
    public boolean isSet(_Fields field) {
4047
      if (field == null) {
4048
        throw new IllegalArgumentException();
4049
      }
3383 chandransh 4050
 
4051
      switch (field) {
5361 mandeep.dh 4052
      case INVENTORY_ITEM:
4053
        return isSetInventoryItem();
4496 mandeep.dh 4054
      case TYPE:
4055
        return isSetType();
4056
      case QUANTITY:
4057
        return isSetQuantity();
5361 mandeep.dh 4058
      case BILLING_WAREHOUSE_ID:
4059
        return isSetBillingWarehouseId();
3383 chandransh 4060
      }
4061
      throw new IllegalStateException();
4062
    }
4063
 
4064
    @Override
4065
    public boolean equals(Object that) {
4066
      if (that == null)
4067
        return false;
4496 mandeep.dh 4068
      if (that instanceof scan_args)
4069
        return this.equals((scan_args)that);
3383 chandransh 4070
      return false;
4071
    }
4072
 
4496 mandeep.dh 4073
    public boolean equals(scan_args that) {
3383 chandransh 4074
      if (that == null)
4075
        return false;
4076
 
5361 mandeep.dh 4077
      boolean this_present_inventoryItem = true && this.isSetInventoryItem();
4078
      boolean that_present_inventoryItem = true && that.isSetInventoryItem();
4079
      if (this_present_inventoryItem || that_present_inventoryItem) {
4080
        if (!(this_present_inventoryItem && that_present_inventoryItem))
3383 chandransh 4081
          return false;
5361 mandeep.dh 4082
        if (!this.inventoryItem.equals(that.inventoryItem))
3383 chandransh 4083
          return false;
4084
      }
4085
 
4496 mandeep.dh 4086
      boolean this_present_type = true && this.isSetType();
4087
      boolean that_present_type = true && that.isSetType();
4088
      if (this_present_type || that_present_type) {
4089
        if (!(this_present_type && that_present_type))
3383 chandransh 4090
          return false;
4496 mandeep.dh 4091
        if (!this.type.equals(that.type))
3383 chandransh 4092
          return false;
4093
      }
4094
 
4496 mandeep.dh 4095
      boolean this_present_quantity = true;
4096
      boolean that_present_quantity = true;
4097
      if (this_present_quantity || that_present_quantity) {
4098
        if (!(this_present_quantity && that_present_quantity))
4099
          return false;
4100
        if (this.quantity != that.quantity)
4101
          return false;
4102
      }
4103
 
5361 mandeep.dh 4104
      boolean this_present_billingWarehouseId = true;
4105
      boolean that_present_billingWarehouseId = true;
4106
      if (this_present_billingWarehouseId || that_present_billingWarehouseId) {
4107
        if (!(this_present_billingWarehouseId && that_present_billingWarehouseId))
4496 mandeep.dh 4108
          return false;
5361 mandeep.dh 4109
        if (this.billingWarehouseId != that.billingWarehouseId)
4496 mandeep.dh 4110
          return false;
4111
      }
4112
 
3383 chandransh 4113
      return true;
4114
    }
4115
 
4116
    @Override
4117
    public int hashCode() {
4118
      return 0;
4119
    }
4120
 
4496 mandeep.dh 4121
    public int compareTo(scan_args other) {
3383 chandransh 4122
      if (!getClass().equals(other.getClass())) {
4123
        return getClass().getName().compareTo(other.getClass().getName());
4124
      }
4125
 
4126
      int lastComparison = 0;
4496 mandeep.dh 4127
      scan_args typedOther = (scan_args)other;
3383 chandransh 4128
 
5361 mandeep.dh 4129
      lastComparison = Boolean.valueOf(isSetInventoryItem()).compareTo(typedOther.isSetInventoryItem());
3383 chandransh 4130
      if (lastComparison != 0) {
4131
        return lastComparison;
4132
      }
5361 mandeep.dh 4133
      if (isSetInventoryItem()) {
4134
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.inventoryItem, typedOther.inventoryItem);
3430 rajveer 4135
        if (lastComparison != 0) {
4136
          return lastComparison;
4137
        }
3383 chandransh 4138
      }
4496 mandeep.dh 4139
      lastComparison = Boolean.valueOf(isSetType()).compareTo(typedOther.isSetType());
3383 chandransh 4140
      if (lastComparison != 0) {
4141
        return lastComparison;
4142
      }
4496 mandeep.dh 4143
      if (isSetType()) {
4144
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, typedOther.type);
3430 rajveer 4145
        if (lastComparison != 0) {
4146
          return lastComparison;
4147
        }
3383 chandransh 4148
      }
4496 mandeep.dh 4149
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
4150
      if (lastComparison != 0) {
4151
        return lastComparison;
4152
      }
4153
      if (isSetQuantity()) {
4154
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
4155
        if (lastComparison != 0) {
4156
          return lastComparison;
4157
        }
4158
      }
5361 mandeep.dh 4159
      lastComparison = Boolean.valueOf(isSetBillingWarehouseId()).compareTo(typedOther.isSetBillingWarehouseId());
4496 mandeep.dh 4160
      if (lastComparison != 0) {
4161
        return lastComparison;
4162
      }
5361 mandeep.dh 4163
      if (isSetBillingWarehouseId()) {
4164
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.billingWarehouseId, typedOther.billingWarehouseId);
4496 mandeep.dh 4165
        if (lastComparison != 0) {
4166
          return lastComparison;
4167
        }
4168
      }
3383 chandransh 4169
      return 0;
4170
    }
4171
 
3430 rajveer 4172
    public _Fields fieldForId(int fieldId) {
4173
      return _Fields.findByThriftId(fieldId);
4174
    }
4175
 
4176
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4177
      org.apache.thrift.protocol.TField field;
3383 chandransh 4178
      iprot.readStructBegin();
4179
      while (true)
4180
      {
4181
        field = iprot.readFieldBegin();
3430 rajveer 4182
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3383 chandransh 4183
          break;
4184
        }
3430 rajveer 4185
        switch (field.id) {
5361 mandeep.dh 4186
          case 1: // INVENTORY_ITEM
4187
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4188
              this.inventoryItem = new InventoryItem();
4189
              this.inventoryItem.read(iprot);
3430 rajveer 4190
            } else { 
4191
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4192
            }
4193
            break;
4496 mandeep.dh 4194
          case 2: // TYPE
4195
            if (field.type == org.apache.thrift.protocol.TType.I32) {
4196
              this.type = ScanType.findByValue(iprot.readI32());
3430 rajveer 4197
            } else { 
4198
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4199
            }
4200
            break;
4496 mandeep.dh 4201
          case 3: // QUANTITY
4202
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4203
              this.quantity = iprot.readI64();
4204
              setQuantityIsSet(true);
4205
            } else { 
4206
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4207
            }
4208
            break;
5361 mandeep.dh 4209
          case 4: // BILLING_WAREHOUSE_ID
4496 mandeep.dh 4210
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5361 mandeep.dh 4211
              this.billingWarehouseId = iprot.readI64();
4212
              setBillingWarehouseIdIsSet(true);
4496 mandeep.dh 4213
            } else { 
4214
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4215
            }
4216
            break;
3430 rajveer 4217
          default:
4218
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3383 chandransh 4219
        }
3430 rajveer 4220
        iprot.readFieldEnd();
3383 chandransh 4221
      }
4222
      iprot.readStructEnd();
4223
      validate();
4224
    }
4225
 
3430 rajveer 4226
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3383 chandransh 4227
      validate();
4228
 
4229
      oprot.writeStructBegin(STRUCT_DESC);
5361 mandeep.dh 4230
      if (this.inventoryItem != null) {
4231
        oprot.writeFieldBegin(INVENTORY_ITEM_FIELD_DESC);
4232
        this.inventoryItem.write(oprot);
4233
        oprot.writeFieldEnd();
4234
      }
4496 mandeep.dh 4235
      if (this.type != null) {
4236
        oprot.writeFieldBegin(TYPE_FIELD_DESC);
4237
        oprot.writeI32(this.type.getValue());
4238
        oprot.writeFieldEnd();
4239
      }
4240
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
4241
      oprot.writeI64(this.quantity);
3383 chandransh 4242
      oprot.writeFieldEnd();
5361 mandeep.dh 4243
      oprot.writeFieldBegin(BILLING_WAREHOUSE_ID_FIELD_DESC);
4244
      oprot.writeI64(this.billingWarehouseId);
4496 mandeep.dh 4245
      oprot.writeFieldEnd();
3383 chandransh 4246
      oprot.writeFieldStop();
4247
      oprot.writeStructEnd();
4248
    }
4249
 
4250
    @Override
4251
    public String toString() {
4496 mandeep.dh 4252
      StringBuilder sb = new StringBuilder("scan_args(");
3383 chandransh 4253
      boolean first = true;
4254
 
5361 mandeep.dh 4255
      sb.append("inventoryItem:");
4256
      if (this.inventoryItem == null) {
4257
        sb.append("null");
4258
      } else {
4259
        sb.append(this.inventoryItem);
4260
      }
3383 chandransh 4261
      first = false;
4262
      if (!first) sb.append(", ");
4496 mandeep.dh 4263
      sb.append("type:");
4264
      if (this.type == null) {
4265
        sb.append("null");
4266
      } else {
4267
        sb.append(this.type);
4268
      }
3383 chandransh 4269
      first = false;
4496 mandeep.dh 4270
      if (!first) sb.append(", ");
4271
      sb.append("quantity:");
4272
      sb.append(this.quantity);
4273
      first = false;
4274
      if (!first) sb.append(", ");
5361 mandeep.dh 4275
      sb.append("billingWarehouseId:");
4276
      sb.append(this.billingWarehouseId);
4496 mandeep.dh 4277
      first = false;
3383 chandransh 4278
      sb.append(")");
4279
      return sb.toString();
4280
    }
4281
 
3430 rajveer 4282
    public void validate() throws org.apache.thrift.TException {
3383 chandransh 4283
      // check for required fields
4284
    }
4285
 
3430 rajveer 4286
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4287
      try {
4288
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4289
      } catch (org.apache.thrift.TException te) {
4290
        throw new java.io.IOException(te);
4291
      }
4292
    }
4293
 
4294
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4295
      try {
4496 mandeep.dh 4296
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
4297
        __isset_bit_vector = new BitSet(1);
3430 rajveer 4298
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4299
      } catch (org.apache.thrift.TException te) {
4300
        throw new java.io.IOException(te);
4301
      }
4302
    }
4303
 
3383 chandransh 4304
  }
4305
 
4496 mandeep.dh 4306
  public static class scan_result implements org.apache.thrift.TBase<scan_result, scan_result._Fields>, java.io.Serializable, Cloneable   {
4307
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scan_result");
3383 chandransh 4308
 
3430 rajveer 4309
    private static final org.apache.thrift.protocol.TField WEX_FIELD_DESC = new org.apache.thrift.protocol.TField("wex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
3383 chandransh 4310
 
3430 rajveer 4311
    private WarehouseServiceException wex; // required
3383 chandransh 4312
 
4313
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4314
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3383 chandransh 4315
      WEX((short)1, "wex");
4316
 
4317
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4318
 
4319
      static {
4320
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4321
          byName.put(field.getFieldName(), field);
4322
        }
4323
      }
4324
 
4325
      /**
4326
       * Find the _Fields constant that matches fieldId, or null if its not found.
4327
       */
4328
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4329
        switch(fieldId) {
4330
          case 1: // WEX
4331
            return WEX;
4332
          default:
4333
            return null;
4334
        }
3383 chandransh 4335
      }
4336
 
4337
      /**
4338
       * Find the _Fields constant that matches fieldId, throwing an exception
4339
       * if it is not found.
4340
       */
4341
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4342
        _Fields fields = findByThriftId(fieldId);
4343
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4344
        return fields;
4345
      }
4346
 
4347
      /**
4348
       * Find the _Fields constant that matches name, or null if its not found.
4349
       */
4350
      public static _Fields findByName(String name) {
4351
        return byName.get(name);
4352
      }
4353
 
4354
      private final short _thriftId;
4355
      private final String _fieldName;
4356
 
4357
      _Fields(short thriftId, String fieldName) {
4358
        _thriftId = thriftId;
4359
        _fieldName = fieldName;
4360
      }
4361
 
4362
      public short getThriftFieldId() {
4363
        return _thriftId;
4364
      }
4365
 
4366
      public String getFieldName() {
4367
        return _fieldName;
4368
      }
4369
    }
4370
 
4371
    // isset id assignments
4372
 
3430 rajveer 4373
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3383 chandransh 4374
    static {
3430 rajveer 4375
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4376
      tmpMap.put(_Fields.WEX, new org.apache.thrift.meta_data.FieldMetaData("wex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4377
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4378
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4496 mandeep.dh 4379
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scan_result.class, metaDataMap);
3383 chandransh 4380
    }
4381
 
4496 mandeep.dh 4382
    public scan_result() {
3383 chandransh 4383
    }
4384
 
4496 mandeep.dh 4385
    public scan_result(
3383 chandransh 4386
      WarehouseServiceException wex)
4387
    {
4388
      this();
4389
      this.wex = wex;
4390
    }
4391
 
4392
    /**
4393
     * Performs a deep copy on <i>other</i>.
4394
     */
4496 mandeep.dh 4395
    public scan_result(scan_result other) {
3383 chandransh 4396
      if (other.isSetWex()) {
4397
        this.wex = new WarehouseServiceException(other.wex);
4398
      }
4399
    }
4400
 
4496 mandeep.dh 4401
    public scan_result deepCopy() {
4402
      return new scan_result(this);
3383 chandransh 4403
    }
4404
 
3430 rajveer 4405
    @Override
4406
    public void clear() {
4407
      this.wex = null;
3383 chandransh 4408
    }
4409
 
4410
    public WarehouseServiceException getWex() {
4411
      return this.wex;
4412
    }
4413
 
3430 rajveer 4414
    public void setWex(WarehouseServiceException wex) {
3383 chandransh 4415
      this.wex = wex;
4416
    }
4417
 
4418
    public void unsetWex() {
4419
      this.wex = null;
4420
    }
4421
 
3430 rajveer 4422
    /** Returns true if field wex is set (has been assigned a value) and false otherwise */
3383 chandransh 4423
    public boolean isSetWex() {
4424
      return this.wex != null;
4425
    }
4426
 
4427
    public void setWexIsSet(boolean value) {
4428
      if (!value) {
4429
        this.wex = null;
4430
      }
4431
    }
4432
 
4433
    public void setFieldValue(_Fields field, Object value) {
4434
      switch (field) {
4435
      case WEX:
4436
        if (value == null) {
4437
          unsetWex();
4438
        } else {
4439
          setWex((WarehouseServiceException)value);
4440
        }
4441
        break;
4442
 
4443
      }
4444
    }
4445
 
4446
    public Object getFieldValue(_Fields field) {
4447
      switch (field) {
4448
      case WEX:
4449
        return getWex();
4450
 
4451
      }
4452
      throw new IllegalStateException();
4453
    }
4454
 
3430 rajveer 4455
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4456
    public boolean isSet(_Fields field) {
4457
      if (field == null) {
4458
        throw new IllegalArgumentException();
4459
      }
3383 chandransh 4460
 
4461
      switch (field) {
4462
      case WEX:
4463
        return isSetWex();
4464
      }
4465
      throw new IllegalStateException();
4466
    }
4467
 
4468
    @Override
4469
    public boolean equals(Object that) {
4470
      if (that == null)
4471
        return false;
4496 mandeep.dh 4472
      if (that instanceof scan_result)
4473
        return this.equals((scan_result)that);
3383 chandransh 4474
      return false;
4475
    }
4476
 
4496 mandeep.dh 4477
    public boolean equals(scan_result that) {
3383 chandransh 4478
      if (that == null)
4479
        return false;
4480
 
4481
      boolean this_present_wex = true && this.isSetWex();
4482
      boolean that_present_wex = true && that.isSetWex();
4483
      if (this_present_wex || that_present_wex) {
4484
        if (!(this_present_wex && that_present_wex))
4485
          return false;
4486
        if (!this.wex.equals(that.wex))
4487
          return false;
4488
      }
4489
 
4490
      return true;
4491
    }
4492
 
4493
    @Override
4494
    public int hashCode() {
4495
      return 0;
4496
    }
4497
 
4496 mandeep.dh 4498
    public int compareTo(scan_result other) {
3383 chandransh 4499
      if (!getClass().equals(other.getClass())) {
4500
        return getClass().getName().compareTo(other.getClass().getName());
4501
      }
4502
 
4503
      int lastComparison = 0;
4496 mandeep.dh 4504
      scan_result typedOther = (scan_result)other;
3383 chandransh 4505
 
3430 rajveer 4506
      lastComparison = Boolean.valueOf(isSetWex()).compareTo(typedOther.isSetWex());
3383 chandransh 4507
      if (lastComparison != 0) {
4508
        return lastComparison;
4509
      }
3430 rajveer 4510
      if (isSetWex()) {
4511
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.wex, typedOther.wex);
4512
        if (lastComparison != 0) {
4513
          return lastComparison;
4514
        }
3383 chandransh 4515
      }
4516
      return 0;
4517
    }
4518
 
3430 rajveer 4519
    public _Fields fieldForId(int fieldId) {
4520
      return _Fields.findByThriftId(fieldId);
4521
    }
4522
 
4523
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4524
      org.apache.thrift.protocol.TField field;
3383 chandransh 4525
      iprot.readStructBegin();
4526
      while (true)
4527
      {
4528
        field = iprot.readFieldBegin();
3430 rajveer 4529
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3383 chandransh 4530
          break;
4531
        }
3430 rajveer 4532
        switch (field.id) {
4533
          case 1: // WEX
4534
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4535
              this.wex = new WarehouseServiceException();
4536
              this.wex.read(iprot);
4537
            } else { 
4538
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4539
            }
4540
            break;
4541
          default:
4542
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3383 chandransh 4543
        }
3430 rajveer 4544
        iprot.readFieldEnd();
3383 chandransh 4545
      }
4546
      iprot.readStructEnd();
4547
      validate();
4548
    }
4549
 
3430 rajveer 4550
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3383 chandransh 4551
      oprot.writeStructBegin(STRUCT_DESC);
4552
 
4496 mandeep.dh 4553
      if (this.isSetWex()) {
3383 chandransh 4554
        oprot.writeFieldBegin(WEX_FIELD_DESC);
4555
        this.wex.write(oprot);
4556
        oprot.writeFieldEnd();
4557
      }
4558
      oprot.writeFieldStop();
4559
      oprot.writeStructEnd();
4560
    }
4561
 
4562
    @Override
4563
    public String toString() {
4496 mandeep.dh 4564
      StringBuilder sb = new StringBuilder("scan_result(");
3383 chandransh 4565
      boolean first = true;
4566
 
4567
      sb.append("wex:");
4568
      if (this.wex == null) {
4569
        sb.append("null");
4570
      } else {
4571
        sb.append(this.wex);
4572
      }
4573
      first = false;
4574
      sb.append(")");
4575
      return sb.toString();
4576
    }
4577
 
3430 rajveer 4578
    public void validate() throws org.apache.thrift.TException {
3383 chandransh 4579
      // check for required fields
4580
    }
4581
 
3430 rajveer 4582
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4583
      try {
4584
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4585
      } catch (org.apache.thrift.TException te) {
4586
        throw new java.io.IOException(te);
4587
      }
4588
    }
4589
 
4590
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4591
      try {
4592
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4593
      } catch (org.apache.thrift.TException te) {
4594
        throw new java.io.IOException(te);
4595
      }
4596
    }
4597
 
3383 chandransh 4598
  }
4599
 
4496 mandeep.dh 4600
  public static class scanSerializedItemForOrder_args implements org.apache.thrift.TBase<scanSerializedItemForOrder_args, scanSerializedItemForOrder_args._Fields>, java.io.Serializable, Cloneable   {
4601
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanSerializedItemForOrder_args");
2820 chandransh 4602
 
4555 mandeep.dh 4603
    private static final org.apache.thrift.protocol.TField SERIAL_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("serialNumber", org.apache.thrift.protocol.TType.STRING, (short)1);
4496 mandeep.dh 4604
    private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)2);
4605
    private static final org.apache.thrift.protocol.TField ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("orderId", org.apache.thrift.protocol.TType.I64, (short)3);
5110 mandeep.dh 4606
    private static final org.apache.thrift.protocol.TField FULFILMENT_WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("fulfilmentWarehouseId", org.apache.thrift.protocol.TType.I64, (short)4);
4607
    private static final org.apache.thrift.protocol.TField QUANTITY_FIELD_DESC = new org.apache.thrift.protocol.TField("quantity", org.apache.thrift.protocol.TType.DOUBLE, (short)5);
4608
    private static final org.apache.thrift.protocol.TField BILLING_WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("billingWarehouseId", org.apache.thrift.protocol.TType.I64, (short)6);
2820 chandransh 4609
 
4555 mandeep.dh 4610
    private String serialNumber; // required
3430 rajveer 4611
    private ScanType type; // required
4496 mandeep.dh 4612
    private long orderId; // required
5110 mandeep.dh 4613
    private long fulfilmentWarehouseId; // required
4614
    private double quantity; // required
4615
    private long billingWarehouseId; // required
2820 chandransh 4616
 
4617
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4618
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4555 mandeep.dh 4619
      SERIAL_NUMBER((short)1, "serialNumber"),
2820 chandransh 4620
      /**
4621
       * 
4622
       * @see ScanType
4623
       */
4496 mandeep.dh 4624
      TYPE((short)2, "type"),
4625
      ORDER_ID((short)3, "orderId"),
5110 mandeep.dh 4626
      FULFILMENT_WAREHOUSE_ID((short)4, "fulfilmentWarehouseId"),
4627
      QUANTITY((short)5, "quantity"),
4628
      BILLING_WAREHOUSE_ID((short)6, "billingWarehouseId");
2820 chandransh 4629
 
4630
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4631
 
4632
      static {
4633
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4634
          byName.put(field.getFieldName(), field);
4635
        }
4636
      }
4637
 
4638
      /**
4639
       * Find the _Fields constant that matches fieldId, or null if its not found.
4640
       */
4641
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4642
        switch(fieldId) {
4555 mandeep.dh 4643
          case 1: // SERIAL_NUMBER
4644
            return SERIAL_NUMBER;
4496 mandeep.dh 4645
          case 2: // TYPE
3430 rajveer 4646
            return TYPE;
4496 mandeep.dh 4647
          case 3: // ORDER_ID
4648
            return ORDER_ID;
5110 mandeep.dh 4649
          case 4: // FULFILMENT_WAREHOUSE_ID
4650
            return FULFILMENT_WAREHOUSE_ID;
4651
          case 5: // QUANTITY
4652
            return QUANTITY;
4653
          case 6: // BILLING_WAREHOUSE_ID
4654
            return BILLING_WAREHOUSE_ID;
3430 rajveer 4655
          default:
4656
            return null;
4657
        }
2820 chandransh 4658
      }
4659
 
4660
      /**
4661
       * Find the _Fields constant that matches fieldId, throwing an exception
4662
       * if it is not found.
4663
       */
4664
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4665
        _Fields fields = findByThriftId(fieldId);
4666
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4667
        return fields;
4668
      }
4669
 
4670
      /**
4671
       * Find the _Fields constant that matches name, or null if its not found.
4672
       */
4673
      public static _Fields findByName(String name) {
4674
        return byName.get(name);
4675
      }
4676
 
4677
      private final short _thriftId;
4678
      private final String _fieldName;
4679
 
4680
      _Fields(short thriftId, String fieldName) {
4681
        _thriftId = thriftId;
4682
        _fieldName = fieldName;
4683
      }
4684
 
4685
      public short getThriftFieldId() {
4686
        return _thriftId;
4687
      }
4688
 
4689
      public String getFieldName() {
4690
        return _fieldName;
4691
      }
4692
    }
4693
 
4694
    // isset id assignments
4555 mandeep.dh 4695
    private static final int __ORDERID_ISSET_ID = 0;
5110 mandeep.dh 4696
    private static final int __FULFILMENTWAREHOUSEID_ISSET_ID = 1;
4697
    private static final int __QUANTITY_ISSET_ID = 2;
4698
    private static final int __BILLINGWAREHOUSEID_ISSET_ID = 3;
4699
    private BitSet __isset_bit_vector = new BitSet(4);
2820 chandransh 4700
 
3430 rajveer 4701
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2820 chandransh 4702
    static {
3430 rajveer 4703
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4555 mandeep.dh 4704
      tmpMap.put(_Fields.SERIAL_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("serialNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4705
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
3430 rajveer 4706
      tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4707
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ScanType.class)));
4496 mandeep.dh 4708
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4709
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5110 mandeep.dh 4710
      tmpMap.put(_Fields.FULFILMENT_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("fulfilmentWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4496 mandeep.dh 4711
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5110 mandeep.dh 4712
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4713
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
4714
      tmpMap.put(_Fields.BILLING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("billingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4715
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3430 rajveer 4716
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4496 mandeep.dh 4717
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanSerializedItemForOrder_args.class, metaDataMap);
2820 chandransh 4718
    }
4719
 
4496 mandeep.dh 4720
    public scanSerializedItemForOrder_args() {
2820 chandransh 4721
    }
4722
 
4496 mandeep.dh 4723
    public scanSerializedItemForOrder_args(
4555 mandeep.dh 4724
      String serialNumber,
4496 mandeep.dh 4725
      ScanType type,
4726
      long orderId,
5110 mandeep.dh 4727
      long fulfilmentWarehouseId,
4728
      double quantity,
4729
      long billingWarehouseId)
2820 chandransh 4730
    {
4731
      this();
4555 mandeep.dh 4732
      this.serialNumber = serialNumber;
2820 chandransh 4733
      this.type = type;
4496 mandeep.dh 4734
      this.orderId = orderId;
4735
      setOrderIdIsSet(true);
5110 mandeep.dh 4736
      this.fulfilmentWarehouseId = fulfilmentWarehouseId;
4737
      setFulfilmentWarehouseIdIsSet(true);
4738
      this.quantity = quantity;
4739
      setQuantityIsSet(true);
4740
      this.billingWarehouseId = billingWarehouseId;
4741
      setBillingWarehouseIdIsSet(true);
2820 chandransh 4742
    }
4743
 
4744
    /**
4745
     * Performs a deep copy on <i>other</i>.
4746
     */
4496 mandeep.dh 4747
    public scanSerializedItemForOrder_args(scanSerializedItemForOrder_args other) {
2820 chandransh 4748
      __isset_bit_vector.clear();
4749
      __isset_bit_vector.or(other.__isset_bit_vector);
4555 mandeep.dh 4750
      if (other.isSetSerialNumber()) {
4751
        this.serialNumber = other.serialNumber;
4752
      }
2820 chandransh 4753
      if (other.isSetType()) {
4754
        this.type = other.type;
4755
      }
4496 mandeep.dh 4756
      this.orderId = other.orderId;
5110 mandeep.dh 4757
      this.fulfilmentWarehouseId = other.fulfilmentWarehouseId;
4758
      this.quantity = other.quantity;
4759
      this.billingWarehouseId = other.billingWarehouseId;
2820 chandransh 4760
    }
4761
 
4496 mandeep.dh 4762
    public scanSerializedItemForOrder_args deepCopy() {
4763
      return new scanSerializedItemForOrder_args(this);
2820 chandransh 4764
    }
4765
 
3430 rajveer 4766
    @Override
4767
    public void clear() {
4555 mandeep.dh 4768
      this.serialNumber = null;
3430 rajveer 4769
      this.type = null;
4496 mandeep.dh 4770
      setOrderIdIsSet(false);
4771
      this.orderId = 0;
5110 mandeep.dh 4772
      setFulfilmentWarehouseIdIsSet(false);
4773
      this.fulfilmentWarehouseId = 0;
4774
      setQuantityIsSet(false);
4775
      this.quantity = 0.0;
4776
      setBillingWarehouseIdIsSet(false);
4777
      this.billingWarehouseId = 0;
2820 chandransh 4778
    }
4779
 
4555 mandeep.dh 4780
    public String getSerialNumber() {
4781
      return this.serialNumber;
2820 chandransh 4782
    }
4783
 
4555 mandeep.dh 4784
    public void setSerialNumber(String serialNumber) {
4785
      this.serialNumber = serialNumber;
2820 chandransh 4786
    }
4787
 
4555 mandeep.dh 4788
    public void unsetSerialNumber() {
4789
      this.serialNumber = null;
2820 chandransh 4790
    }
4791
 
4555 mandeep.dh 4792
    /** Returns true if field serialNumber is set (has been assigned a value) and false otherwise */
4793
    public boolean isSetSerialNumber() {
4794
      return this.serialNumber != null;
2820 chandransh 4795
    }
4796
 
4555 mandeep.dh 4797
    public void setSerialNumberIsSet(boolean value) {
4798
      if (!value) {
4799
        this.serialNumber = null;
4800
      }
2820 chandransh 4801
    }
4802
 
4496 mandeep.dh 4803
    /**
4804
     * 
4805
     * @see ScanType
4806
     */
4807
    public ScanType getType() {
4808
      return this.type;
2820 chandransh 4809
    }
4810
 
4496 mandeep.dh 4811
    /**
4812
     * 
4813
     * @see ScanType
4814
     */
4815
    public void setType(ScanType type) {
4816
      this.type = type;
2820 chandransh 4817
    }
4818
 
4496 mandeep.dh 4819
    public void unsetType() {
4820
      this.type = null;
2820 chandransh 4821
    }
4822
 
4496 mandeep.dh 4823
    /** Returns true if field type is set (has been assigned a value) and false otherwise */
4824
    public boolean isSetType() {
4825
      return this.type != null;
2820 chandransh 4826
    }
4827
 
4496 mandeep.dh 4828
    public void setTypeIsSet(boolean value) {
2820 chandransh 4829
      if (!value) {
4496 mandeep.dh 4830
        this.type = null;
2820 chandransh 4831
      }
4832
    }
4833
 
4496 mandeep.dh 4834
    public long getOrderId() {
4835
      return this.orderId;
2820 chandransh 4836
    }
4837
 
4496 mandeep.dh 4838
    public void setOrderId(long orderId) {
4839
      this.orderId = orderId;
4840
      setOrderIdIsSet(true);
2820 chandransh 4841
    }
4842
 
4496 mandeep.dh 4843
    public void unsetOrderId() {
4844
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
2820 chandransh 4845
    }
4846
 
4496 mandeep.dh 4847
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
4848
    public boolean isSetOrderId() {
4849
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
2820 chandransh 4850
    }
4851
 
4496 mandeep.dh 4852
    public void setOrderIdIsSet(boolean value) {
4853
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
2820 chandransh 4854
    }
4855
 
5110 mandeep.dh 4856
    public long getFulfilmentWarehouseId() {
4857
      return this.fulfilmentWarehouseId;
2820 chandransh 4858
    }
4859
 
5110 mandeep.dh 4860
    public void setFulfilmentWarehouseId(long fulfilmentWarehouseId) {
4861
      this.fulfilmentWarehouseId = fulfilmentWarehouseId;
4862
      setFulfilmentWarehouseIdIsSet(true);
2820 chandransh 4863
    }
4864
 
5110 mandeep.dh 4865
    public void unsetFulfilmentWarehouseId() {
4866
      __isset_bit_vector.clear(__FULFILMENTWAREHOUSEID_ISSET_ID);
2820 chandransh 4867
    }
4868
 
5110 mandeep.dh 4869
    /** Returns true if field fulfilmentWarehouseId is set (has been assigned a value) and false otherwise */
4870
    public boolean isSetFulfilmentWarehouseId() {
4871
      return __isset_bit_vector.get(__FULFILMENTWAREHOUSEID_ISSET_ID);
2820 chandransh 4872
    }
4873
 
5110 mandeep.dh 4874
    public void setFulfilmentWarehouseIdIsSet(boolean value) {
4875
      __isset_bit_vector.set(__FULFILMENTWAREHOUSEID_ISSET_ID, value);
2820 chandransh 4876
    }
4877
 
5110 mandeep.dh 4878
    public double getQuantity() {
4879
      return this.quantity;
4880
    }
4881
 
4882
    public void setQuantity(double quantity) {
4883
      this.quantity = quantity;
4884
      setQuantityIsSet(true);
4885
    }
4886
 
4887
    public void unsetQuantity() {
4888
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
4889
    }
4890
 
4891
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
4892
    public boolean isSetQuantity() {
4893
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
4894
    }
4895
 
4896
    public void setQuantityIsSet(boolean value) {
4897
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
4898
    }
4899
 
4900
    public long getBillingWarehouseId() {
4901
      return this.billingWarehouseId;
4902
    }
4903
 
4904
    public void setBillingWarehouseId(long billingWarehouseId) {
4905
      this.billingWarehouseId = billingWarehouseId;
4906
      setBillingWarehouseIdIsSet(true);
4907
    }
4908
 
4909
    public void unsetBillingWarehouseId() {
4910
      __isset_bit_vector.clear(__BILLINGWAREHOUSEID_ISSET_ID);
4911
    }
4912
 
4913
    /** Returns true if field billingWarehouseId is set (has been assigned a value) and false otherwise */
4914
    public boolean isSetBillingWarehouseId() {
4915
      return __isset_bit_vector.get(__BILLINGWAREHOUSEID_ISSET_ID);
4916
    }
4917
 
4918
    public void setBillingWarehouseIdIsSet(boolean value) {
4919
      __isset_bit_vector.set(__BILLINGWAREHOUSEID_ISSET_ID, value);
4920
    }
4921
 
2820 chandransh 4922
    public void setFieldValue(_Fields field, Object value) {
4923
      switch (field) {
4555 mandeep.dh 4924
      case SERIAL_NUMBER:
2820 chandransh 4925
        if (value == null) {
4555 mandeep.dh 4926
          unsetSerialNumber();
2820 chandransh 4927
        } else {
4555 mandeep.dh 4928
          setSerialNumber((String)value);
2820 chandransh 4929
        }
4930
        break;
4931
 
4496 mandeep.dh 4932
      case TYPE:
2820 chandransh 4933
        if (value == null) {
4496 mandeep.dh 4934
          unsetType();
2820 chandransh 4935
        } else {
4496 mandeep.dh 4936
          setType((ScanType)value);
2820 chandransh 4937
        }
4938
        break;
4939
 
4496 mandeep.dh 4940
      case ORDER_ID:
2820 chandransh 4941
        if (value == null) {
4496 mandeep.dh 4942
          unsetOrderId();
2820 chandransh 4943
        } else {
4496 mandeep.dh 4944
          setOrderId((Long)value);
2820 chandransh 4945
        }
4946
        break;
4947
 
5110 mandeep.dh 4948
      case FULFILMENT_WAREHOUSE_ID:
2820 chandransh 4949
        if (value == null) {
5110 mandeep.dh 4950
          unsetFulfilmentWarehouseId();
2820 chandransh 4951
        } else {
5110 mandeep.dh 4952
          setFulfilmentWarehouseId((Long)value);
2820 chandransh 4953
        }
4954
        break;
4955
 
5110 mandeep.dh 4956
      case QUANTITY:
4957
        if (value == null) {
4958
          unsetQuantity();
4959
        } else {
4960
          setQuantity((Double)value);
4961
        }
4962
        break;
4963
 
4964
      case BILLING_WAREHOUSE_ID:
4965
        if (value == null) {
4966
          unsetBillingWarehouseId();
4967
        } else {
4968
          setBillingWarehouseId((Long)value);
4969
        }
4970
        break;
4971
 
2820 chandransh 4972
      }
4973
    }
4974
 
4975
    public Object getFieldValue(_Fields field) {
4976
      switch (field) {
4555 mandeep.dh 4977
      case SERIAL_NUMBER:
4978
        return getSerialNumber();
2820 chandransh 4979
 
4980
      case TYPE:
4981
        return getType();
4982
 
4496 mandeep.dh 4983
      case ORDER_ID:
4984
        return Long.valueOf(getOrderId());
4985
 
5110 mandeep.dh 4986
      case FULFILMENT_WAREHOUSE_ID:
4987
        return Long.valueOf(getFulfilmentWarehouseId());
4496 mandeep.dh 4988
 
5110 mandeep.dh 4989
      case QUANTITY:
4990
        return Double.valueOf(getQuantity());
4991
 
4992
      case BILLING_WAREHOUSE_ID:
4993
        return Long.valueOf(getBillingWarehouseId());
4994
 
2820 chandransh 4995
      }
4996
      throw new IllegalStateException();
4997
    }
4998
 
3430 rajveer 4999
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5000
    public boolean isSet(_Fields field) {
5001
      if (field == null) {
5002
        throw new IllegalArgumentException();
5003
      }
2820 chandransh 5004
 
5005
      switch (field) {
4555 mandeep.dh 5006
      case SERIAL_NUMBER:
5007
        return isSetSerialNumber();
2820 chandransh 5008
      case TYPE:
5009
        return isSetType();
4496 mandeep.dh 5010
      case ORDER_ID:
5011
        return isSetOrderId();
5110 mandeep.dh 5012
      case FULFILMENT_WAREHOUSE_ID:
5013
        return isSetFulfilmentWarehouseId();
5014
      case QUANTITY:
5015
        return isSetQuantity();
5016
      case BILLING_WAREHOUSE_ID:
5017
        return isSetBillingWarehouseId();
2820 chandransh 5018
      }
5019
      throw new IllegalStateException();
5020
    }
5021
 
5022
    @Override
5023
    public boolean equals(Object that) {
5024
      if (that == null)
5025
        return false;
4496 mandeep.dh 5026
      if (that instanceof scanSerializedItemForOrder_args)
5027
        return this.equals((scanSerializedItemForOrder_args)that);
2820 chandransh 5028
      return false;
5029
    }
5030
 
4496 mandeep.dh 5031
    public boolean equals(scanSerializedItemForOrder_args that) {
2820 chandransh 5032
      if (that == null)
5033
        return false;
5034
 
4555 mandeep.dh 5035
      boolean this_present_serialNumber = true && this.isSetSerialNumber();
5036
      boolean that_present_serialNumber = true && that.isSetSerialNumber();
5037
      if (this_present_serialNumber || that_present_serialNumber) {
5038
        if (!(this_present_serialNumber && that_present_serialNumber))
2820 chandransh 5039
          return false;
4555 mandeep.dh 5040
        if (!this.serialNumber.equals(that.serialNumber))
2820 chandransh 5041
          return false;
5042
      }
5043
 
4496 mandeep.dh 5044
      boolean this_present_type = true && this.isSetType();
5045
      boolean that_present_type = true && that.isSetType();
5046
      if (this_present_type || that_present_type) {
5047
        if (!(this_present_type && that_present_type))
2820 chandransh 5048
          return false;
4496 mandeep.dh 5049
        if (!this.type.equals(that.type))
2820 chandransh 5050
          return false;
5051
      }
5052
 
4496 mandeep.dh 5053
      boolean this_present_orderId = true;
5054
      boolean that_present_orderId = true;
5055
      if (this_present_orderId || that_present_orderId) {
5056
        if (!(this_present_orderId && that_present_orderId))
2820 chandransh 5057
          return false;
4496 mandeep.dh 5058
        if (this.orderId != that.orderId)
2820 chandransh 5059
          return false;
5060
      }
5061
 
5110 mandeep.dh 5062
      boolean this_present_fulfilmentWarehouseId = true;
5063
      boolean that_present_fulfilmentWarehouseId = true;
5064
      if (this_present_fulfilmentWarehouseId || that_present_fulfilmentWarehouseId) {
5065
        if (!(this_present_fulfilmentWarehouseId && that_present_fulfilmentWarehouseId))
2820 chandransh 5066
          return false;
5110 mandeep.dh 5067
        if (this.fulfilmentWarehouseId != that.fulfilmentWarehouseId)
2820 chandransh 5068
          return false;
5069
      }
5070
 
5110 mandeep.dh 5071
      boolean this_present_quantity = true;
5072
      boolean that_present_quantity = true;
5073
      if (this_present_quantity || that_present_quantity) {
5074
        if (!(this_present_quantity && that_present_quantity))
5075
          return false;
5076
        if (this.quantity != that.quantity)
5077
          return false;
5078
      }
5079
 
5080
      boolean this_present_billingWarehouseId = true;
5081
      boolean that_present_billingWarehouseId = true;
5082
      if (this_present_billingWarehouseId || that_present_billingWarehouseId) {
5083
        if (!(this_present_billingWarehouseId && that_present_billingWarehouseId))
5084
          return false;
5085
        if (this.billingWarehouseId != that.billingWarehouseId)
5086
          return false;
5087
      }
5088
 
2820 chandransh 5089
      return true;
5090
    }
5091
 
5092
    @Override
5093
    public int hashCode() {
5094
      return 0;
5095
    }
5096
 
4496 mandeep.dh 5097
    public int compareTo(scanSerializedItemForOrder_args other) {
2820 chandransh 5098
      if (!getClass().equals(other.getClass())) {
5099
        return getClass().getName().compareTo(other.getClass().getName());
5100
      }
5101
 
5102
      int lastComparison = 0;
4496 mandeep.dh 5103
      scanSerializedItemForOrder_args typedOther = (scanSerializedItemForOrder_args)other;
2820 chandransh 5104
 
4555 mandeep.dh 5105
      lastComparison = Boolean.valueOf(isSetSerialNumber()).compareTo(typedOther.isSetSerialNumber());
2820 chandransh 5106
      if (lastComparison != 0) {
5107
        return lastComparison;
5108
      }
4555 mandeep.dh 5109
      if (isSetSerialNumber()) {
5110
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.serialNumber, typedOther.serialNumber);
3430 rajveer 5111
        if (lastComparison != 0) {
5112
          return lastComparison;
5113
        }
2820 chandransh 5114
      }
4496 mandeep.dh 5115
      lastComparison = Boolean.valueOf(isSetType()).compareTo(typedOther.isSetType());
2820 chandransh 5116
      if (lastComparison != 0) {
5117
        return lastComparison;
5118
      }
4496 mandeep.dh 5119
      if (isSetType()) {
5120
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, typedOther.type);
3430 rajveer 5121
        if (lastComparison != 0) {
5122
          return lastComparison;
5123
        }
2820 chandransh 5124
      }
4496 mandeep.dh 5125
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
2820 chandransh 5126
      if (lastComparison != 0) {
5127
        return lastComparison;
5128
      }
4496 mandeep.dh 5129
      if (isSetOrderId()) {
5130
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
3430 rajveer 5131
        if (lastComparison != 0) {
5132
          return lastComparison;
5133
        }
2820 chandransh 5134
      }
5110 mandeep.dh 5135
      lastComparison = Boolean.valueOf(isSetFulfilmentWarehouseId()).compareTo(typedOther.isSetFulfilmentWarehouseId());
2820 chandransh 5136
      if (lastComparison != 0) {
5137
        return lastComparison;
5138
      }
5110 mandeep.dh 5139
      if (isSetFulfilmentWarehouseId()) {
5140
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fulfilmentWarehouseId, typedOther.fulfilmentWarehouseId);
3430 rajveer 5141
        if (lastComparison != 0) {
5142
          return lastComparison;
5143
        }
2820 chandransh 5144
      }
5110 mandeep.dh 5145
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
5146
      if (lastComparison != 0) {
5147
        return lastComparison;
5148
      }
5149
      if (isSetQuantity()) {
5150
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
5151
        if (lastComparison != 0) {
5152
          return lastComparison;
5153
        }
5154
      }
5155
      lastComparison = Boolean.valueOf(isSetBillingWarehouseId()).compareTo(typedOther.isSetBillingWarehouseId());
5156
      if (lastComparison != 0) {
5157
        return lastComparison;
5158
      }
5159
      if (isSetBillingWarehouseId()) {
5160
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.billingWarehouseId, typedOther.billingWarehouseId);
5161
        if (lastComparison != 0) {
5162
          return lastComparison;
5163
        }
5164
      }
2820 chandransh 5165
      return 0;
5166
    }
5167
 
3430 rajveer 5168
    public _Fields fieldForId(int fieldId) {
5169
      return _Fields.findByThriftId(fieldId);
5170
    }
5171
 
5172
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5173
      org.apache.thrift.protocol.TField field;
2820 chandransh 5174
      iprot.readStructBegin();
5175
      while (true)
5176
      {
5177
        field = iprot.readFieldBegin();
3430 rajveer 5178
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2820 chandransh 5179
          break;
5180
        }
3430 rajveer 5181
        switch (field.id) {
4555 mandeep.dh 5182
          case 1: // SERIAL_NUMBER
5183
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
5184
              this.serialNumber = iprot.readString();
3430 rajveer 5185
            } else { 
5186
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5187
            }
5188
            break;
4496 mandeep.dh 5189
          case 2: // TYPE
5190
            if (field.type == org.apache.thrift.protocol.TType.I32) {
5191
              this.type = ScanType.findByValue(iprot.readI32());
3430 rajveer 5192
            } else { 
5193
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5194
            }
5195
            break;
4496 mandeep.dh 5196
          case 3: // ORDER_ID
5197
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5198
              this.orderId = iprot.readI64();
5199
              setOrderIdIsSet(true);
3430 rajveer 5200
            } else { 
5201
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5202
            }
5203
            break;
5110 mandeep.dh 5204
          case 4: // FULFILMENT_WAREHOUSE_ID
4496 mandeep.dh 5205
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5110 mandeep.dh 5206
              this.fulfilmentWarehouseId = iprot.readI64();
5207
              setFulfilmentWarehouseIdIsSet(true);
3430 rajveer 5208
            } else { 
5209
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5210
            }
5211
            break;
5110 mandeep.dh 5212
          case 5: // QUANTITY
5213
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
5214
              this.quantity = iprot.readDouble();
5215
              setQuantityIsSet(true);
5216
            } else { 
5217
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5218
            }
5219
            break;
5220
          case 6: // BILLING_WAREHOUSE_ID
5221
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5222
              this.billingWarehouseId = iprot.readI64();
5223
              setBillingWarehouseIdIsSet(true);
5224
            } else { 
5225
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5226
            }
5227
            break;
3430 rajveer 5228
          default:
5229
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2820 chandransh 5230
        }
3430 rajveer 5231
        iprot.readFieldEnd();
2820 chandransh 5232
      }
5233
      iprot.readStructEnd();
5234
      validate();
5235
    }
5236
 
3430 rajveer 5237
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2820 chandransh 5238
      validate();
5239
 
5240
      oprot.writeStructBegin(STRUCT_DESC);
4555 mandeep.dh 5241
      if (this.serialNumber != null) {
5242
        oprot.writeFieldBegin(SERIAL_NUMBER_FIELD_DESC);
5243
        oprot.writeString(this.serialNumber);
5244
        oprot.writeFieldEnd();
5245
      }
2820 chandransh 5246
      if (this.type != null) {
5247
        oprot.writeFieldBegin(TYPE_FIELD_DESC);
5248
        oprot.writeI32(this.type.getValue());
5249
        oprot.writeFieldEnd();
5250
      }
4496 mandeep.dh 5251
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
5252
      oprot.writeI64(this.orderId);
5253
      oprot.writeFieldEnd();
5110 mandeep.dh 5254
      oprot.writeFieldBegin(FULFILMENT_WAREHOUSE_ID_FIELD_DESC);
5255
      oprot.writeI64(this.fulfilmentWarehouseId);
4496 mandeep.dh 5256
      oprot.writeFieldEnd();
5110 mandeep.dh 5257
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
5258
      oprot.writeDouble(this.quantity);
5259
      oprot.writeFieldEnd();
5260
      oprot.writeFieldBegin(BILLING_WAREHOUSE_ID_FIELD_DESC);
5261
      oprot.writeI64(this.billingWarehouseId);
5262
      oprot.writeFieldEnd();
2820 chandransh 5263
      oprot.writeFieldStop();
5264
      oprot.writeStructEnd();
5265
    }
5266
 
5267
    @Override
5268
    public String toString() {
4496 mandeep.dh 5269
      StringBuilder sb = new StringBuilder("scanSerializedItemForOrder_args(");
2820 chandransh 5270
      boolean first = true;
5271
 
4555 mandeep.dh 5272
      sb.append("serialNumber:");
5273
      if (this.serialNumber == null) {
5274
        sb.append("null");
5275
      } else {
5276
        sb.append(this.serialNumber);
5277
      }
2820 chandransh 5278
      first = false;
5279
      if (!first) sb.append(", ");
4496 mandeep.dh 5280
      sb.append("type:");
5281
      if (this.type == null) {
2820 chandransh 5282
        sb.append("null");
5283
      } else {
4496 mandeep.dh 5284
        sb.append(this.type);
2820 chandransh 5285
      }
5286
      first = false;
5287
      if (!first) sb.append(", ");
4496 mandeep.dh 5288
      sb.append("orderId:");
5289
      sb.append(this.orderId);
2820 chandransh 5290
      first = false;
5291
      if (!first) sb.append(", ");
5110 mandeep.dh 5292
      sb.append("fulfilmentWarehouseId:");
5293
      sb.append(this.fulfilmentWarehouseId);
2820 chandransh 5294
      first = false;
5110 mandeep.dh 5295
      if (!first) sb.append(", ");
5296
      sb.append("quantity:");
5297
      sb.append(this.quantity);
5298
      first = false;
5299
      if (!first) sb.append(", ");
5300
      sb.append("billingWarehouseId:");
5301
      sb.append(this.billingWarehouseId);
5302
      first = false;
2820 chandransh 5303
      sb.append(")");
5304
      return sb.toString();
5305
    }
5306
 
3430 rajveer 5307
    public void validate() throws org.apache.thrift.TException {
2820 chandransh 5308
      // check for required fields
5309
    }
5310
 
3430 rajveer 5311
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5312
      try {
5313
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5314
      } catch (org.apache.thrift.TException te) {
5315
        throw new java.io.IOException(te);
5316
      }
5317
    }
5318
 
5319
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5320
      try {
5321
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5322
      } catch (org.apache.thrift.TException te) {
5323
        throw new java.io.IOException(te);
5324
      }
5325
    }
5326
 
2820 chandransh 5327
  }
5328
 
4496 mandeep.dh 5329
  public static class scanSerializedItemForOrder_result implements org.apache.thrift.TBase<scanSerializedItemForOrder_result, scanSerializedItemForOrder_result._Fields>, java.io.Serializable, Cloneable   {
5330
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanSerializedItemForOrder_result");
2820 chandransh 5331
 
4555 mandeep.dh 5332
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
3430 rajveer 5333
    private static final org.apache.thrift.protocol.TField WEX_FIELD_DESC = new org.apache.thrift.protocol.TField("wex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
2820 chandransh 5334
 
4555 mandeep.dh 5335
    private InventoryItem success; // required
3430 rajveer 5336
    private WarehouseServiceException wex; // required
2820 chandransh 5337
 
5338
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 5339
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4496 mandeep.dh 5340
      SUCCESS((short)0, "success"),
2820 chandransh 5341
      WEX((short)1, "wex");
5342
 
5343
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5344
 
5345
      static {
5346
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5347
          byName.put(field.getFieldName(), field);
5348
        }
5349
      }
5350
 
5351
      /**
5352
       * Find the _Fields constant that matches fieldId, or null if its not found.
5353
       */
5354
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 5355
        switch(fieldId) {
4496 mandeep.dh 5356
          case 0: // SUCCESS
5357
            return SUCCESS;
3430 rajveer 5358
          case 1: // WEX
5359
            return WEX;
5360
          default:
5361
            return null;
5362
        }
2820 chandransh 5363
      }
5364
 
5365
      /**
5366
       * Find the _Fields constant that matches fieldId, throwing an exception
5367
       * if it is not found.
5368
       */
5369
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5370
        _Fields fields = findByThriftId(fieldId);
5371
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5372
        return fields;
5373
      }
5374
 
5375
      /**
5376
       * Find the _Fields constant that matches name, or null if its not found.
5377
       */
5378
      public static _Fields findByName(String name) {
5379
        return byName.get(name);
5380
      }
5381
 
5382
      private final short _thriftId;
5383
      private final String _fieldName;
5384
 
5385
      _Fields(short thriftId, String fieldName) {
5386
        _thriftId = thriftId;
5387
        _fieldName = fieldName;
5388
      }
5389
 
5390
      public short getThriftFieldId() {
5391
        return _thriftId;
5392
      }
5393
 
5394
      public String getFieldName() {
5395
        return _fieldName;
5396
      }
5397
    }
5398
 
5399
    // isset id assignments
5400
 
3430 rajveer 5401
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2820 chandransh 5402
    static {
3430 rajveer 5403
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4496 mandeep.dh 5404
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4555 mandeep.dh 5405
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class)));
3430 rajveer 5406
      tmpMap.put(_Fields.WEX, new org.apache.thrift.meta_data.FieldMetaData("wex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5407
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5408
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4496 mandeep.dh 5409
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanSerializedItemForOrder_result.class, metaDataMap);
2820 chandransh 5410
    }
5411
 
4496 mandeep.dh 5412
    public scanSerializedItemForOrder_result() {
2820 chandransh 5413
    }
5414
 
4496 mandeep.dh 5415
    public scanSerializedItemForOrder_result(
4555 mandeep.dh 5416
      InventoryItem success,
2820 chandransh 5417
      WarehouseServiceException wex)
5418
    {
5419
      this();
4496 mandeep.dh 5420
      this.success = success;
2820 chandransh 5421
      this.wex = wex;
5422
    }
5423
 
5424
    /**
5425
     * Performs a deep copy on <i>other</i>.
5426
     */
4496 mandeep.dh 5427
    public scanSerializedItemForOrder_result(scanSerializedItemForOrder_result other) {
4555 mandeep.dh 5428
      if (other.isSetSuccess()) {
5429
        this.success = new InventoryItem(other.success);
5430
      }
2820 chandransh 5431
      if (other.isSetWex()) {
5432
        this.wex = new WarehouseServiceException(other.wex);
5433
      }
5434
    }
5435
 
4496 mandeep.dh 5436
    public scanSerializedItemForOrder_result deepCopy() {
5437
      return new scanSerializedItemForOrder_result(this);
2820 chandransh 5438
    }
5439
 
3430 rajveer 5440
    @Override
5441
    public void clear() {
4555 mandeep.dh 5442
      this.success = null;
3430 rajveer 5443
      this.wex = null;
2820 chandransh 5444
    }
5445
 
4555 mandeep.dh 5446
    public InventoryItem getSuccess() {
4496 mandeep.dh 5447
      return this.success;
5448
    }
5449
 
4555 mandeep.dh 5450
    public void setSuccess(InventoryItem success) {
4496 mandeep.dh 5451
      this.success = success;
5452
    }
5453
 
5454
    public void unsetSuccess() {
4555 mandeep.dh 5455
      this.success = null;
4496 mandeep.dh 5456
    }
5457
 
5458
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
5459
    public boolean isSetSuccess() {
4555 mandeep.dh 5460
      return this.success != null;
4496 mandeep.dh 5461
    }
5462
 
5463
    public void setSuccessIsSet(boolean value) {
4555 mandeep.dh 5464
      if (!value) {
5465
        this.success = null;
5466
      }
4496 mandeep.dh 5467
    }
5468
 
2820 chandransh 5469
    public WarehouseServiceException getWex() {
5470
      return this.wex;
5471
    }
5472
 
3430 rajveer 5473
    public void setWex(WarehouseServiceException wex) {
2820 chandransh 5474
      this.wex = wex;
5475
    }
5476
 
5477
    public void unsetWex() {
5478
      this.wex = null;
5479
    }
5480
 
3430 rajveer 5481
    /** Returns true if field wex is set (has been assigned a value) and false otherwise */
2820 chandransh 5482
    public boolean isSetWex() {
5483
      return this.wex != null;
5484
    }
5485
 
5486
    public void setWexIsSet(boolean value) {
5487
      if (!value) {
5488
        this.wex = null;
5489
      }
5490
    }
5491
 
5492
    public void setFieldValue(_Fields field, Object value) {
5493
      switch (field) {
4496 mandeep.dh 5494
      case SUCCESS:
5495
        if (value == null) {
5496
          unsetSuccess();
5497
        } else {
4555 mandeep.dh 5498
          setSuccess((InventoryItem)value);
4496 mandeep.dh 5499
        }
5500
        break;
5501
 
2820 chandransh 5502
      case WEX:
5503
        if (value == null) {
5504
          unsetWex();
5505
        } else {
5506
          setWex((WarehouseServiceException)value);
5507
        }
5508
        break;
5509
 
5510
      }
5511
    }
5512
 
5513
    public Object getFieldValue(_Fields field) {
5514
      switch (field) {
4496 mandeep.dh 5515
      case SUCCESS:
4555 mandeep.dh 5516
        return getSuccess();
4496 mandeep.dh 5517
 
2820 chandransh 5518
      case WEX:
5519
        return getWex();
5520
 
5521
      }
5522
      throw new IllegalStateException();
5523
    }
5524
 
3430 rajveer 5525
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5526
    public boolean isSet(_Fields field) {
5527
      if (field == null) {
5528
        throw new IllegalArgumentException();
5529
      }
2820 chandransh 5530
 
5531
      switch (field) {
4496 mandeep.dh 5532
      case SUCCESS:
5533
        return isSetSuccess();
2820 chandransh 5534
      case WEX:
5535
        return isSetWex();
5536
      }
5537
      throw new IllegalStateException();
5538
    }
5539
 
5540
    @Override
5541
    public boolean equals(Object that) {
5542
      if (that == null)
5543
        return false;
4496 mandeep.dh 5544
      if (that instanceof scanSerializedItemForOrder_result)
5545
        return this.equals((scanSerializedItemForOrder_result)that);
2820 chandransh 5546
      return false;
5547
    }
5548
 
4496 mandeep.dh 5549
    public boolean equals(scanSerializedItemForOrder_result that) {
2820 chandransh 5550
      if (that == null)
5551
        return false;
5552
 
4555 mandeep.dh 5553
      boolean this_present_success = true && this.isSetSuccess();
5554
      boolean that_present_success = true && that.isSetSuccess();
4496 mandeep.dh 5555
      if (this_present_success || that_present_success) {
5556
        if (!(this_present_success && that_present_success))
5557
          return false;
4555 mandeep.dh 5558
        if (!this.success.equals(that.success))
4496 mandeep.dh 5559
          return false;
5560
      }
5561
 
2820 chandransh 5562
      boolean this_present_wex = true && this.isSetWex();
5563
      boolean that_present_wex = true && that.isSetWex();
5564
      if (this_present_wex || that_present_wex) {
5565
        if (!(this_present_wex && that_present_wex))
5566
          return false;
5567
        if (!this.wex.equals(that.wex))
5568
          return false;
5569
      }
5570
 
5571
      return true;
5572
    }
5573
 
5574
    @Override
5575
    public int hashCode() {
5576
      return 0;
5577
    }
5578
 
4496 mandeep.dh 5579
    public int compareTo(scanSerializedItemForOrder_result other) {
2820 chandransh 5580
      if (!getClass().equals(other.getClass())) {
5581
        return getClass().getName().compareTo(other.getClass().getName());
5582
      }
5583
 
5584
      int lastComparison = 0;
4496 mandeep.dh 5585
      scanSerializedItemForOrder_result typedOther = (scanSerializedItemForOrder_result)other;
2820 chandransh 5586
 
4496 mandeep.dh 5587
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
5588
      if (lastComparison != 0) {
5589
        return lastComparison;
5590
      }
5591
      if (isSetSuccess()) {
5592
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
5593
        if (lastComparison != 0) {
5594
          return lastComparison;
5595
        }
5596
      }
3430 rajveer 5597
      lastComparison = Boolean.valueOf(isSetWex()).compareTo(typedOther.isSetWex());
2820 chandransh 5598
      if (lastComparison != 0) {
5599
        return lastComparison;
5600
      }
3430 rajveer 5601
      if (isSetWex()) {
5602
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.wex, typedOther.wex);
5603
        if (lastComparison != 0) {
5604
          return lastComparison;
5605
        }
2820 chandransh 5606
      }
5607
      return 0;
5608
    }
5609
 
3430 rajveer 5610
    public _Fields fieldForId(int fieldId) {
5611
      return _Fields.findByThriftId(fieldId);
5612
    }
5613
 
5614
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5615
      org.apache.thrift.protocol.TField field;
2820 chandransh 5616
      iprot.readStructBegin();
5617
      while (true)
5618
      {
5619
        field = iprot.readFieldBegin();
3430 rajveer 5620
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2820 chandransh 5621
          break;
5622
        }
3430 rajveer 5623
        switch (field.id) {
4496 mandeep.dh 5624
          case 0: // SUCCESS
4555 mandeep.dh 5625
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5626
              this.success = new InventoryItem();
5627
              this.success.read(iprot);
4496 mandeep.dh 5628
            } else { 
5629
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5630
            }
5631
            break;
3430 rajveer 5632
          case 1: // WEX
5633
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5634
              this.wex = new WarehouseServiceException();
5635
              this.wex.read(iprot);
5636
            } else { 
5637
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5638
            }
5639
            break;
5640
          default:
5641
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2820 chandransh 5642
        }
3430 rajveer 5643
        iprot.readFieldEnd();
2820 chandransh 5644
      }
5645
      iprot.readStructEnd();
5646
      validate();
5647
    }
5648
 
3430 rajveer 5649
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2820 chandransh 5650
      oprot.writeStructBegin(STRUCT_DESC);
5651
 
4496 mandeep.dh 5652
      if (this.isSetSuccess()) {
5653
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
4555 mandeep.dh 5654
        this.success.write(oprot);
4496 mandeep.dh 5655
        oprot.writeFieldEnd();
5656
      } else if (this.isSetWex()) {
2820 chandransh 5657
        oprot.writeFieldBegin(WEX_FIELD_DESC);
5658
        this.wex.write(oprot);
5659
        oprot.writeFieldEnd();
5660
      }
5661
      oprot.writeFieldStop();
5662
      oprot.writeStructEnd();
5663
    }
5664
 
5665
    @Override
5666
    public String toString() {
4496 mandeep.dh 5667
      StringBuilder sb = new StringBuilder("scanSerializedItemForOrder_result(");
2820 chandransh 5668
      boolean first = true;
5669
 
4496 mandeep.dh 5670
      sb.append("success:");
4555 mandeep.dh 5671
      if (this.success == null) {
5672
        sb.append("null");
5673
      } else {
5674
        sb.append(this.success);
5675
      }
4496 mandeep.dh 5676
      first = false;
5677
      if (!first) sb.append(", ");
2820 chandransh 5678
      sb.append("wex:");
5679
      if (this.wex == null) {
5680
        sb.append("null");
5681
      } else {
5682
        sb.append(this.wex);
5683
      }
5684
      first = false;
5685
      sb.append(")");
5686
      return sb.toString();
5687
    }
5688
 
3430 rajveer 5689
    public void validate() throws org.apache.thrift.TException {
2820 chandransh 5690
      // check for required fields
5691
    }
5692
 
3430 rajveer 5693
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5694
      try {
5695
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5696
      } catch (org.apache.thrift.TException te) {
5697
        throw new java.io.IOException(te);
5698
      }
5699
    }
5700
 
5701
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5702
      try {
5703
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5704
      } catch (org.apache.thrift.TException te) {
5705
        throw new java.io.IOException(te);
5706
      }
5707
    }
5708
 
2820 chandransh 5709
  }
5710
 
4496 mandeep.dh 5711
  public static class scanForOrder_args implements org.apache.thrift.TBase<scanForOrder_args, scanForOrder_args._Fields>, java.io.Serializable, Cloneable   {
5712
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForOrder_args");
2820 chandransh 5713
 
5361 mandeep.dh 5714
    private static final org.apache.thrift.protocol.TField INVENTORY_ITEM_FIELD_DESC = new org.apache.thrift.protocol.TField("inventoryItem", org.apache.thrift.protocol.TType.STRUCT, (short)1);
4496 mandeep.dh 5715
    private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)2);
5716
    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)3);
5717
    private static final org.apache.thrift.protocol.TField ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("orderId", org.apache.thrift.protocol.TType.I64, (short)4);
5110 mandeep.dh 5718
    private static final org.apache.thrift.protocol.TField FULFILMENT_WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("fulfilmentWarehouseId", org.apache.thrift.protocol.TType.I64, (short)5);
5361 mandeep.dh 5719
    private static final org.apache.thrift.protocol.TField BILLING_WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("billingWarehouseId", org.apache.thrift.protocol.TType.I64, (short)6);
2820 chandransh 5720
 
5361 mandeep.dh 5721
    private InventoryItem inventoryItem; // required
3430 rajveer 5722
    private ScanType type; // required
4496 mandeep.dh 5723
    private long quantity; // required
5724
    private long orderId; // required
5110 mandeep.dh 5725
    private long fulfilmentWarehouseId; // required
5361 mandeep.dh 5726
    private long billingWarehouseId; // required
2820 chandransh 5727
 
5728
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 5729
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5361 mandeep.dh 5730
      INVENTORY_ITEM((short)1, "inventoryItem"),
2820 chandransh 5731
      /**
5732
       * 
5733
       * @see ScanType
5734
       */
4496 mandeep.dh 5735
      TYPE((short)2, "type"),
5736
      QUANTITY((short)3, "quantity"),
5737
      ORDER_ID((short)4, "orderId"),
5361 mandeep.dh 5738
      FULFILMENT_WAREHOUSE_ID((short)5, "fulfilmentWarehouseId"),
5739
      BILLING_WAREHOUSE_ID((short)6, "billingWarehouseId");
2820 chandransh 5740
 
5741
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5742
 
5743
      static {
5744
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5745
          byName.put(field.getFieldName(), field);
5746
        }
5747
      }
5748
 
5749
      /**
5750
       * Find the _Fields constant that matches fieldId, or null if its not found.
5751
       */
5752
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 5753
        switch(fieldId) {
5361 mandeep.dh 5754
          case 1: // INVENTORY_ITEM
5755
            return INVENTORY_ITEM;
4496 mandeep.dh 5756
          case 2: // TYPE
3430 rajveer 5757
            return TYPE;
4496 mandeep.dh 5758
          case 3: // QUANTITY
5759
            return QUANTITY;
5760
          case 4: // ORDER_ID
5761
            return ORDER_ID;
5110 mandeep.dh 5762
          case 5: // FULFILMENT_WAREHOUSE_ID
5763
            return FULFILMENT_WAREHOUSE_ID;
5361 mandeep.dh 5764
          case 6: // BILLING_WAREHOUSE_ID
5765
            return BILLING_WAREHOUSE_ID;
3430 rajveer 5766
          default:
5767
            return null;
5768
        }
2820 chandransh 5769
      }
5770
 
5771
      /**
5772
       * Find the _Fields constant that matches fieldId, throwing an exception
5773
       * if it is not found.
5774
       */
5775
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5776
        _Fields fields = findByThriftId(fieldId);
5777
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5778
        return fields;
5779
      }
5780
 
5781
      /**
5782
       * Find the _Fields constant that matches name, or null if its not found.
5783
       */
5784
      public static _Fields findByName(String name) {
5785
        return byName.get(name);
5786
      }
5787
 
5788
      private final short _thriftId;
5789
      private final String _fieldName;
5790
 
5791
      _Fields(short thriftId, String fieldName) {
5792
        _thriftId = thriftId;
5793
        _fieldName = fieldName;
5794
      }
5795
 
5796
      public short getThriftFieldId() {
5797
        return _thriftId;
5798
      }
5799
 
5800
      public String getFieldName() {
5801
        return _fieldName;
5802
      }
5803
    }
5804
 
5805
    // isset id assignments
5361 mandeep.dh 5806
    private static final int __QUANTITY_ISSET_ID = 0;
5807
    private static final int __ORDERID_ISSET_ID = 1;
5808
    private static final int __FULFILMENTWAREHOUSEID_ISSET_ID = 2;
5809
    private static final int __BILLINGWAREHOUSEID_ISSET_ID = 3;
4496 mandeep.dh 5810
    private BitSet __isset_bit_vector = new BitSet(4);
2820 chandransh 5811
 
3430 rajveer 5812
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2820 chandransh 5813
    static {
3430 rajveer 5814
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5361 mandeep.dh 5815
      tmpMap.put(_Fields.INVENTORY_ITEM, new org.apache.thrift.meta_data.FieldMetaData("inventoryItem", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5816
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class)));
3430 rajveer 5817
      tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5818
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ScanType.class)));
4496 mandeep.dh 5819
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5820
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5821
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5822
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5110 mandeep.dh 5823
      tmpMap.put(_Fields.FULFILMENT_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("fulfilmentWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4496 mandeep.dh 5824
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5361 mandeep.dh 5825
      tmpMap.put(_Fields.BILLING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("billingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5826
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3430 rajveer 5827
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4496 mandeep.dh 5828
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForOrder_args.class, metaDataMap);
2820 chandransh 5829
    }
5830
 
4496 mandeep.dh 5831
    public scanForOrder_args() {
2820 chandransh 5832
    }
5833
 
4496 mandeep.dh 5834
    public scanForOrder_args(
5361 mandeep.dh 5835
      InventoryItem inventoryItem,
4496 mandeep.dh 5836
      ScanType type,
5837
      long quantity,
5838
      long orderId,
5361 mandeep.dh 5839
      long fulfilmentWarehouseId,
5840
      long billingWarehouseId)
2820 chandransh 5841
    {
5842
      this();
5361 mandeep.dh 5843
      this.inventoryItem = inventoryItem;
2820 chandransh 5844
      this.type = type;
4496 mandeep.dh 5845
      this.quantity = quantity;
5846
      setQuantityIsSet(true);
5847
      this.orderId = orderId;
5848
      setOrderIdIsSet(true);
5110 mandeep.dh 5849
      this.fulfilmentWarehouseId = fulfilmentWarehouseId;
5850
      setFulfilmentWarehouseIdIsSet(true);
5361 mandeep.dh 5851
      this.billingWarehouseId = billingWarehouseId;
5852
      setBillingWarehouseIdIsSet(true);
2820 chandransh 5853
    }
5854
 
5855
    /**
5856
     * Performs a deep copy on <i>other</i>.
5857
     */
4496 mandeep.dh 5858
    public scanForOrder_args(scanForOrder_args other) {
5859
      __isset_bit_vector.clear();
5860
      __isset_bit_vector.or(other.__isset_bit_vector);
5361 mandeep.dh 5861
      if (other.isSetInventoryItem()) {
5862
        this.inventoryItem = new InventoryItem(other.inventoryItem);
5863
      }
2820 chandransh 5864
      if (other.isSetType()) {
5865
        this.type = other.type;
5866
      }
4496 mandeep.dh 5867
      this.quantity = other.quantity;
5868
      this.orderId = other.orderId;
5110 mandeep.dh 5869
      this.fulfilmentWarehouseId = other.fulfilmentWarehouseId;
5361 mandeep.dh 5870
      this.billingWarehouseId = other.billingWarehouseId;
2820 chandransh 5871
    }
5872
 
4496 mandeep.dh 5873
    public scanForOrder_args deepCopy() {
5874
      return new scanForOrder_args(this);
2820 chandransh 5875
    }
5876
 
3430 rajveer 5877
    @Override
5878
    public void clear() {
5361 mandeep.dh 5879
      this.inventoryItem = null;
3430 rajveer 5880
      this.type = null;
4496 mandeep.dh 5881
      setQuantityIsSet(false);
5882
      this.quantity = 0;
5883
      setOrderIdIsSet(false);
5884
      this.orderId = 0;
5110 mandeep.dh 5885
      setFulfilmentWarehouseIdIsSet(false);
5886
      this.fulfilmentWarehouseId = 0;
5361 mandeep.dh 5887
      setBillingWarehouseIdIsSet(false);
5888
      this.billingWarehouseId = 0;
2820 chandransh 5889
    }
5890
 
5361 mandeep.dh 5891
    public InventoryItem getInventoryItem() {
5892
      return this.inventoryItem;
2820 chandransh 5893
    }
5894
 
5361 mandeep.dh 5895
    public void setInventoryItem(InventoryItem inventoryItem) {
5896
      this.inventoryItem = inventoryItem;
2820 chandransh 5897
    }
5898
 
5361 mandeep.dh 5899
    public void unsetInventoryItem() {
5900
      this.inventoryItem = null;
2820 chandransh 5901
    }
5902
 
5361 mandeep.dh 5903
    /** Returns true if field inventoryItem is set (has been assigned a value) and false otherwise */
5904
    public boolean isSetInventoryItem() {
5905
      return this.inventoryItem != null;
2820 chandransh 5906
    }
5907
 
5361 mandeep.dh 5908
    public void setInventoryItemIsSet(boolean value) {
5909
      if (!value) {
5910
        this.inventoryItem = null;
5911
      }
2820 chandransh 5912
    }
5913
 
5914
    /**
5915
     * 
5916
     * @see ScanType
5917
     */
5918
    public ScanType getType() {
5919
      return this.type;
5920
    }
5921
 
5922
    /**
5923
     * 
5924
     * @see ScanType
5925
     */
3430 rajveer 5926
    public void setType(ScanType type) {
2820 chandransh 5927
      this.type = type;
5928
    }
5929
 
5930
    public void unsetType() {
5931
      this.type = null;
5932
    }
5933
 
3430 rajveer 5934
    /** Returns true if field type is set (has been assigned a value) and false otherwise */
2820 chandransh 5935
    public boolean isSetType() {
5936
      return this.type != null;
5937
    }
5938
 
5939
    public void setTypeIsSet(boolean value) {
5940
      if (!value) {
5941
        this.type = null;
5942
      }
5943
    }
5944
 
4496 mandeep.dh 5945
    public long getQuantity() {
5946
      return this.quantity;
5947
    }
5948
 
5949
    public void setQuantity(long quantity) {
5950
      this.quantity = quantity;
5951
      setQuantityIsSet(true);
5952
    }
5953
 
5954
    public void unsetQuantity() {
5955
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
5956
    }
5957
 
5958
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
5959
    public boolean isSetQuantity() {
5960
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
5961
    }
5962
 
5963
    public void setQuantityIsSet(boolean value) {
5964
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
5965
    }
5966
 
5967
    public long getOrderId() {
5968
      return this.orderId;
5969
    }
5970
 
5971
    public void setOrderId(long orderId) {
5972
      this.orderId = orderId;
5973
      setOrderIdIsSet(true);
5974
    }
5975
 
5976
    public void unsetOrderId() {
5977
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
5978
    }
5979
 
5980
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
5981
    public boolean isSetOrderId() {
5982
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
5983
    }
5984
 
5985
    public void setOrderIdIsSet(boolean value) {
5986
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
5987
    }
5988
 
5110 mandeep.dh 5989
    public long getFulfilmentWarehouseId() {
5990
      return this.fulfilmentWarehouseId;
4496 mandeep.dh 5991
    }
5992
 
5110 mandeep.dh 5993
    public void setFulfilmentWarehouseId(long fulfilmentWarehouseId) {
5994
      this.fulfilmentWarehouseId = fulfilmentWarehouseId;
5995
      setFulfilmentWarehouseIdIsSet(true);
4496 mandeep.dh 5996
    }
5997
 
5110 mandeep.dh 5998
    public void unsetFulfilmentWarehouseId() {
5999
      __isset_bit_vector.clear(__FULFILMENTWAREHOUSEID_ISSET_ID);
4496 mandeep.dh 6000
    }
6001
 
5110 mandeep.dh 6002
    /** Returns true if field fulfilmentWarehouseId is set (has been assigned a value) and false otherwise */
6003
    public boolean isSetFulfilmentWarehouseId() {
6004
      return __isset_bit_vector.get(__FULFILMENTWAREHOUSEID_ISSET_ID);
4496 mandeep.dh 6005
    }
6006
 
5110 mandeep.dh 6007
    public void setFulfilmentWarehouseIdIsSet(boolean value) {
6008
      __isset_bit_vector.set(__FULFILMENTWAREHOUSEID_ISSET_ID, value);
4496 mandeep.dh 6009
    }
6010
 
5361 mandeep.dh 6011
    public long getBillingWarehouseId() {
6012
      return this.billingWarehouseId;
6013
    }
6014
 
6015
    public void setBillingWarehouseId(long billingWarehouseId) {
6016
      this.billingWarehouseId = billingWarehouseId;
6017
      setBillingWarehouseIdIsSet(true);
6018
    }
6019
 
6020
    public void unsetBillingWarehouseId() {
6021
      __isset_bit_vector.clear(__BILLINGWAREHOUSEID_ISSET_ID);
6022
    }
6023
 
6024
    /** Returns true if field billingWarehouseId is set (has been assigned a value) and false otherwise */
6025
    public boolean isSetBillingWarehouseId() {
6026
      return __isset_bit_vector.get(__BILLINGWAREHOUSEID_ISSET_ID);
6027
    }
6028
 
6029
    public void setBillingWarehouseIdIsSet(boolean value) {
6030
      __isset_bit_vector.set(__BILLINGWAREHOUSEID_ISSET_ID, value);
6031
    }
6032
 
2820 chandransh 6033
    public void setFieldValue(_Fields field, Object value) {
6034
      switch (field) {
5361 mandeep.dh 6035
      case INVENTORY_ITEM:
2820 chandransh 6036
        if (value == null) {
5361 mandeep.dh 6037
          unsetInventoryItem();
2820 chandransh 6038
        } else {
5361 mandeep.dh 6039
          setInventoryItem((InventoryItem)value);
2820 chandransh 6040
        }
6041
        break;
6042
 
4496 mandeep.dh 6043
      case TYPE:
2820 chandransh 6044
        if (value == null) {
4496 mandeep.dh 6045
          unsetType();
2820 chandransh 6046
        } else {
4496 mandeep.dh 6047
          setType((ScanType)value);
2820 chandransh 6048
        }
6049
        break;
6050
 
4496 mandeep.dh 6051
      case QUANTITY:
2820 chandransh 6052
        if (value == null) {
4496 mandeep.dh 6053
          unsetQuantity();
2820 chandransh 6054
        } else {
4496 mandeep.dh 6055
          setQuantity((Long)value);
2820 chandransh 6056
        }
6057
        break;
6058
 
4496 mandeep.dh 6059
      case ORDER_ID:
6060
        if (value == null) {
6061
          unsetOrderId();
6062
        } else {
6063
          setOrderId((Long)value);
6064
        }
6065
        break;
6066
 
5110 mandeep.dh 6067
      case FULFILMENT_WAREHOUSE_ID:
4496 mandeep.dh 6068
        if (value == null) {
5110 mandeep.dh 6069
          unsetFulfilmentWarehouseId();
4496 mandeep.dh 6070
        } else {
5110 mandeep.dh 6071
          setFulfilmentWarehouseId((Long)value);
4496 mandeep.dh 6072
        }
6073
        break;
6074
 
5361 mandeep.dh 6075
      case BILLING_WAREHOUSE_ID:
6076
        if (value == null) {
6077
          unsetBillingWarehouseId();
6078
        } else {
6079
          setBillingWarehouseId((Long)value);
6080
        }
6081
        break;
6082
 
2820 chandransh 6083
      }
6084
    }
6085
 
6086
    public Object getFieldValue(_Fields field) {
6087
      switch (field) {
5361 mandeep.dh 6088
      case INVENTORY_ITEM:
6089
        return getInventoryItem();
2820 chandransh 6090
 
6091
      case TYPE:
6092
        return getType();
6093
 
4496 mandeep.dh 6094
      case QUANTITY:
6095
        return Long.valueOf(getQuantity());
6096
 
6097
      case ORDER_ID:
6098
        return Long.valueOf(getOrderId());
6099
 
5110 mandeep.dh 6100
      case FULFILMENT_WAREHOUSE_ID:
6101
        return Long.valueOf(getFulfilmentWarehouseId());
4496 mandeep.dh 6102
 
5361 mandeep.dh 6103
      case BILLING_WAREHOUSE_ID:
6104
        return Long.valueOf(getBillingWarehouseId());
6105
 
2820 chandransh 6106
      }
6107
      throw new IllegalStateException();
6108
    }
6109
 
3430 rajveer 6110
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6111
    public boolean isSet(_Fields field) {
6112
      if (field == null) {
6113
        throw new IllegalArgumentException();
6114
      }
2820 chandransh 6115
 
6116
      switch (field) {
5361 mandeep.dh 6117
      case INVENTORY_ITEM:
6118
        return isSetInventoryItem();
2820 chandransh 6119
      case TYPE:
6120
        return isSetType();
4496 mandeep.dh 6121
      case QUANTITY:
6122
        return isSetQuantity();
6123
      case ORDER_ID:
6124
        return isSetOrderId();
5110 mandeep.dh 6125
      case FULFILMENT_WAREHOUSE_ID:
6126
        return isSetFulfilmentWarehouseId();
5361 mandeep.dh 6127
      case BILLING_WAREHOUSE_ID:
6128
        return isSetBillingWarehouseId();
2820 chandransh 6129
      }
6130
      throw new IllegalStateException();
6131
    }
6132
 
6133
    @Override
6134
    public boolean equals(Object that) {
6135
      if (that == null)
6136
        return false;
4496 mandeep.dh 6137
      if (that instanceof scanForOrder_args)
6138
        return this.equals((scanForOrder_args)that);
2820 chandransh 6139
      return false;
6140
    }
6141
 
4496 mandeep.dh 6142
    public boolean equals(scanForOrder_args that) {
2820 chandransh 6143
      if (that == null)
6144
        return false;
6145
 
5361 mandeep.dh 6146
      boolean this_present_inventoryItem = true && this.isSetInventoryItem();
6147
      boolean that_present_inventoryItem = true && that.isSetInventoryItem();
6148
      if (this_present_inventoryItem || that_present_inventoryItem) {
6149
        if (!(this_present_inventoryItem && that_present_inventoryItem))
2820 chandransh 6150
          return false;
5361 mandeep.dh 6151
        if (!this.inventoryItem.equals(that.inventoryItem))
2820 chandransh 6152
          return false;
6153
      }
6154
 
6155
      boolean this_present_type = true && this.isSetType();
6156
      boolean that_present_type = true && that.isSetType();
6157
      if (this_present_type || that_present_type) {
6158
        if (!(this_present_type && that_present_type))
6159
          return false;
6160
        if (!this.type.equals(that.type))
6161
          return false;
6162
      }
6163
 
4496 mandeep.dh 6164
      boolean this_present_quantity = true;
6165
      boolean that_present_quantity = true;
6166
      if (this_present_quantity || that_present_quantity) {
6167
        if (!(this_present_quantity && that_present_quantity))
6168
          return false;
6169
        if (this.quantity != that.quantity)
6170
          return false;
6171
      }
6172
 
6173
      boolean this_present_orderId = true;
6174
      boolean that_present_orderId = true;
6175
      if (this_present_orderId || that_present_orderId) {
6176
        if (!(this_present_orderId && that_present_orderId))
6177
          return false;
6178
        if (this.orderId != that.orderId)
6179
          return false;
6180
      }
6181
 
5110 mandeep.dh 6182
      boolean this_present_fulfilmentWarehouseId = true;
6183
      boolean that_present_fulfilmentWarehouseId = true;
6184
      if (this_present_fulfilmentWarehouseId || that_present_fulfilmentWarehouseId) {
6185
        if (!(this_present_fulfilmentWarehouseId && that_present_fulfilmentWarehouseId))
4496 mandeep.dh 6186
          return false;
5110 mandeep.dh 6187
        if (this.fulfilmentWarehouseId != that.fulfilmentWarehouseId)
4496 mandeep.dh 6188
          return false;
6189
      }
6190
 
5361 mandeep.dh 6191
      boolean this_present_billingWarehouseId = true;
6192
      boolean that_present_billingWarehouseId = true;
6193
      if (this_present_billingWarehouseId || that_present_billingWarehouseId) {
6194
        if (!(this_present_billingWarehouseId && that_present_billingWarehouseId))
6195
          return false;
6196
        if (this.billingWarehouseId != that.billingWarehouseId)
6197
          return false;
6198
      }
6199
 
2820 chandransh 6200
      return true;
6201
    }
6202
 
6203
    @Override
6204
    public int hashCode() {
6205
      return 0;
6206
    }
6207
 
4496 mandeep.dh 6208
    public int compareTo(scanForOrder_args other) {
2820 chandransh 6209
      if (!getClass().equals(other.getClass())) {
6210
        return getClass().getName().compareTo(other.getClass().getName());
6211
      }
6212
 
6213
      int lastComparison = 0;
4496 mandeep.dh 6214
      scanForOrder_args typedOther = (scanForOrder_args)other;
2820 chandransh 6215
 
5361 mandeep.dh 6216
      lastComparison = Boolean.valueOf(isSetInventoryItem()).compareTo(typedOther.isSetInventoryItem());
2820 chandransh 6217
      if (lastComparison != 0) {
6218
        return lastComparison;
6219
      }
5361 mandeep.dh 6220
      if (isSetInventoryItem()) {
6221
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.inventoryItem, typedOther.inventoryItem);
3430 rajveer 6222
        if (lastComparison != 0) {
6223
          return lastComparison;
6224
        }
2820 chandransh 6225
      }
4496 mandeep.dh 6226
      lastComparison = Boolean.valueOf(isSetType()).compareTo(typedOther.isSetType());
2820 chandransh 6227
      if (lastComparison != 0) {
6228
        return lastComparison;
6229
      }
4496 mandeep.dh 6230
      if (isSetType()) {
6231
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, typedOther.type);
3430 rajveer 6232
        if (lastComparison != 0) {
6233
          return lastComparison;
6234
        }
2820 chandransh 6235
      }
4496 mandeep.dh 6236
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
2820 chandransh 6237
      if (lastComparison != 0) {
6238
        return lastComparison;
6239
      }
4496 mandeep.dh 6240
      if (isSetQuantity()) {
6241
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
3430 rajveer 6242
        if (lastComparison != 0) {
6243
          return lastComparison;
6244
        }
2820 chandransh 6245
      }
4496 mandeep.dh 6246
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
6247
      if (lastComparison != 0) {
6248
        return lastComparison;
6249
      }
6250
      if (isSetOrderId()) {
6251
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
6252
        if (lastComparison != 0) {
6253
          return lastComparison;
6254
        }
6255
      }
5110 mandeep.dh 6256
      lastComparison = Boolean.valueOf(isSetFulfilmentWarehouseId()).compareTo(typedOther.isSetFulfilmentWarehouseId());
4496 mandeep.dh 6257
      if (lastComparison != 0) {
6258
        return lastComparison;
6259
      }
5110 mandeep.dh 6260
      if (isSetFulfilmentWarehouseId()) {
6261
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fulfilmentWarehouseId, typedOther.fulfilmentWarehouseId);
4496 mandeep.dh 6262
        if (lastComparison != 0) {
6263
          return lastComparison;
6264
        }
6265
      }
5361 mandeep.dh 6266
      lastComparison = Boolean.valueOf(isSetBillingWarehouseId()).compareTo(typedOther.isSetBillingWarehouseId());
6267
      if (lastComparison != 0) {
6268
        return lastComparison;
6269
      }
6270
      if (isSetBillingWarehouseId()) {
6271
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.billingWarehouseId, typedOther.billingWarehouseId);
6272
        if (lastComparison != 0) {
6273
          return lastComparison;
6274
        }
6275
      }
2820 chandransh 6276
      return 0;
6277
    }
6278
 
3430 rajveer 6279
    public _Fields fieldForId(int fieldId) {
6280
      return _Fields.findByThriftId(fieldId);
6281
    }
6282
 
6283
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6284
      org.apache.thrift.protocol.TField field;
2820 chandransh 6285
      iprot.readStructBegin();
6286
      while (true)
6287
      {
6288
        field = iprot.readFieldBegin();
3430 rajveer 6289
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2820 chandransh 6290
          break;
6291
        }
3430 rajveer 6292
        switch (field.id) {
5361 mandeep.dh 6293
          case 1: // INVENTORY_ITEM
6294
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6295
              this.inventoryItem = new InventoryItem();
6296
              this.inventoryItem.read(iprot);
3430 rajveer 6297
            } else { 
6298
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6299
            }
6300
            break;
4496 mandeep.dh 6301
          case 2: // TYPE
6302
            if (field.type == org.apache.thrift.protocol.TType.I32) {
6303
              this.type = ScanType.findByValue(iprot.readI32());
3430 rajveer 6304
            } else { 
6305
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6306
            }
6307
            break;
4496 mandeep.dh 6308
          case 3: // QUANTITY
6309
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6310
              this.quantity = iprot.readI64();
6311
              setQuantityIsSet(true);
3430 rajveer 6312
            } else { 
6313
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6314
            }
6315
            break;
4496 mandeep.dh 6316
          case 4: // ORDER_ID
6317
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6318
              this.orderId = iprot.readI64();
6319
              setOrderIdIsSet(true);
6320
            } else { 
6321
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6322
            }
6323
            break;
5110 mandeep.dh 6324
          case 5: // FULFILMENT_WAREHOUSE_ID
4496 mandeep.dh 6325
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5110 mandeep.dh 6326
              this.fulfilmentWarehouseId = iprot.readI64();
6327
              setFulfilmentWarehouseIdIsSet(true);
4496 mandeep.dh 6328
            } else { 
6329
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6330
            }
6331
            break;
5361 mandeep.dh 6332
          case 6: // BILLING_WAREHOUSE_ID
6333
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6334
              this.billingWarehouseId = iprot.readI64();
6335
              setBillingWarehouseIdIsSet(true);
6336
            } else { 
6337
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6338
            }
6339
            break;
3430 rajveer 6340
          default:
6341
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2820 chandransh 6342
        }
3430 rajveer 6343
        iprot.readFieldEnd();
2820 chandransh 6344
      }
6345
      iprot.readStructEnd();
6346
      validate();
6347
    }
6348
 
3430 rajveer 6349
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2820 chandransh 6350
      validate();
6351
 
6352
      oprot.writeStructBegin(STRUCT_DESC);
5361 mandeep.dh 6353
      if (this.inventoryItem != null) {
6354
        oprot.writeFieldBegin(INVENTORY_ITEM_FIELD_DESC);
6355
        this.inventoryItem.write(oprot);
6356
        oprot.writeFieldEnd();
6357
      }
2820 chandransh 6358
      if (this.type != null) {
6359
        oprot.writeFieldBegin(TYPE_FIELD_DESC);
6360
        oprot.writeI32(this.type.getValue());
6361
        oprot.writeFieldEnd();
6362
      }
4496 mandeep.dh 6363
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
6364
      oprot.writeI64(this.quantity);
6365
      oprot.writeFieldEnd();
6366
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
6367
      oprot.writeI64(this.orderId);
6368
      oprot.writeFieldEnd();
5110 mandeep.dh 6369
      oprot.writeFieldBegin(FULFILMENT_WAREHOUSE_ID_FIELD_DESC);
6370
      oprot.writeI64(this.fulfilmentWarehouseId);
4496 mandeep.dh 6371
      oprot.writeFieldEnd();
5361 mandeep.dh 6372
      oprot.writeFieldBegin(BILLING_WAREHOUSE_ID_FIELD_DESC);
6373
      oprot.writeI64(this.billingWarehouseId);
6374
      oprot.writeFieldEnd();
2820 chandransh 6375
      oprot.writeFieldStop();
6376
      oprot.writeStructEnd();
6377
    }
6378
 
6379
    @Override
6380
    public String toString() {
4496 mandeep.dh 6381
      StringBuilder sb = new StringBuilder("scanForOrder_args(");
2820 chandransh 6382
      boolean first = true;
6383
 
5361 mandeep.dh 6384
      sb.append("inventoryItem:");
6385
      if (this.inventoryItem == null) {
6386
        sb.append("null");
6387
      } else {
6388
        sb.append(this.inventoryItem);
6389
      }
2820 chandransh 6390
      first = false;
6391
      if (!first) sb.append(", ");
6392
      sb.append("type:");
6393
      if (this.type == null) {
6394
        sb.append("null");
6395
      } else {
6396
        sb.append(this.type);
6397
      }
6398
      first = false;
4496 mandeep.dh 6399
      if (!first) sb.append(", ");
6400
      sb.append("quantity:");
6401
      sb.append(this.quantity);
6402
      first = false;
6403
      if (!first) sb.append(", ");
6404
      sb.append("orderId:");
6405
      sb.append(this.orderId);
6406
      first = false;
6407
      if (!first) sb.append(", ");
5110 mandeep.dh 6408
      sb.append("fulfilmentWarehouseId:");
6409
      sb.append(this.fulfilmentWarehouseId);
4496 mandeep.dh 6410
      first = false;
5361 mandeep.dh 6411
      if (!first) sb.append(", ");
6412
      sb.append("billingWarehouseId:");
6413
      sb.append(this.billingWarehouseId);
6414
      first = false;
2820 chandransh 6415
      sb.append(")");
6416
      return sb.toString();
6417
    }
6418
 
3430 rajveer 6419
    public void validate() throws org.apache.thrift.TException {
2820 chandransh 6420
      // check for required fields
6421
    }
6422
 
3430 rajveer 6423
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6424
      try {
6425
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6426
      } catch (org.apache.thrift.TException te) {
6427
        throw new java.io.IOException(te);
6428
      }
6429
    }
6430
 
6431
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6432
      try {
4496 mandeep.dh 6433
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
6434
        __isset_bit_vector = new BitSet(1);
3430 rajveer 6435
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6436
      } catch (org.apache.thrift.TException te) {
6437
        throw new java.io.IOException(te);
6438
      }
6439
    }
6440
 
2820 chandransh 6441
  }
6442
 
4496 mandeep.dh 6443
  public static class scanForOrder_result implements org.apache.thrift.TBase<scanForOrder_result, scanForOrder_result._Fields>, java.io.Serializable, Cloneable   {
6444
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForOrder_result");
2820 chandransh 6445
 
5361 mandeep.dh 6446
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
3430 rajveer 6447
    private static final org.apache.thrift.protocol.TField WEX_FIELD_DESC = new org.apache.thrift.protocol.TField("wex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
2820 chandransh 6448
 
5361 mandeep.dh 6449
    private InventoryItem success; // required
3430 rajveer 6450
    private WarehouseServiceException wex; // required
2820 chandransh 6451
 
6452
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 6453
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5361 mandeep.dh 6454
      SUCCESS((short)0, "success"),
2820 chandransh 6455
      WEX((short)1, "wex");
6456
 
6457
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6458
 
6459
      static {
6460
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6461
          byName.put(field.getFieldName(), field);
6462
        }
6463
      }
6464
 
6465
      /**
6466
       * Find the _Fields constant that matches fieldId, or null if its not found.
6467
       */
6468
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6469
        switch(fieldId) {
5361 mandeep.dh 6470
          case 0: // SUCCESS
6471
            return SUCCESS;
3430 rajveer 6472
          case 1: // WEX
6473
            return WEX;
6474
          default:
6475
            return null;
6476
        }
2820 chandransh 6477
      }
6478
 
6479
      /**
6480
       * Find the _Fields constant that matches fieldId, throwing an exception
6481
       * if it is not found.
6482
       */
6483
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6484
        _Fields fields = findByThriftId(fieldId);
6485
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6486
        return fields;
6487
      }
6488
 
6489
      /**
6490
       * Find the _Fields constant that matches name, or null if its not found.
6491
       */
6492
      public static _Fields findByName(String name) {
6493
        return byName.get(name);
6494
      }
6495
 
6496
      private final short _thriftId;
6497
      private final String _fieldName;
6498
 
6499
      _Fields(short thriftId, String fieldName) {
6500
        _thriftId = thriftId;
6501
        _fieldName = fieldName;
6502
      }
6503
 
6504
      public short getThriftFieldId() {
6505
        return _thriftId;
6506
      }
6507
 
6508
      public String getFieldName() {
6509
        return _fieldName;
6510
      }
6511
    }
6512
 
6513
    // isset id assignments
6514
 
3430 rajveer 6515
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2820 chandransh 6516
    static {
3430 rajveer 6517
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5361 mandeep.dh 6518
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6519
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class)));
3430 rajveer 6520
      tmpMap.put(_Fields.WEX, new org.apache.thrift.meta_data.FieldMetaData("wex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6521
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6522
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4496 mandeep.dh 6523
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForOrder_result.class, metaDataMap);
2820 chandransh 6524
    }
6525
 
4496 mandeep.dh 6526
    public scanForOrder_result() {
2820 chandransh 6527
    }
6528
 
4496 mandeep.dh 6529
    public scanForOrder_result(
5361 mandeep.dh 6530
      InventoryItem success,
2820 chandransh 6531
      WarehouseServiceException wex)
6532
    {
6533
      this();
5361 mandeep.dh 6534
      this.success = success;
2820 chandransh 6535
      this.wex = wex;
6536
    }
6537
 
6538
    /**
6539
     * Performs a deep copy on <i>other</i>.
6540
     */
4496 mandeep.dh 6541
    public scanForOrder_result(scanForOrder_result other) {
5361 mandeep.dh 6542
      if (other.isSetSuccess()) {
6543
        this.success = new InventoryItem(other.success);
6544
      }
2820 chandransh 6545
      if (other.isSetWex()) {
6546
        this.wex = new WarehouseServiceException(other.wex);
6547
      }
6548
    }
6549
 
4496 mandeep.dh 6550
    public scanForOrder_result deepCopy() {
6551
      return new scanForOrder_result(this);
2820 chandransh 6552
    }
6553
 
3430 rajveer 6554
    @Override
6555
    public void clear() {
5361 mandeep.dh 6556
      this.success = null;
3430 rajveer 6557
      this.wex = null;
2820 chandransh 6558
    }
6559
 
5361 mandeep.dh 6560
    public InventoryItem getSuccess() {
6561
      return this.success;
6562
    }
6563
 
6564
    public void setSuccess(InventoryItem success) {
6565
      this.success = success;
6566
    }
6567
 
6568
    public void unsetSuccess() {
6569
      this.success = null;
6570
    }
6571
 
6572
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
6573
    public boolean isSetSuccess() {
6574
      return this.success != null;
6575
    }
6576
 
6577
    public void setSuccessIsSet(boolean value) {
6578
      if (!value) {
6579
        this.success = null;
6580
      }
6581
    }
6582
 
2820 chandransh 6583
    public WarehouseServiceException getWex() {
6584
      return this.wex;
6585
    }
6586
 
3430 rajveer 6587
    public void setWex(WarehouseServiceException wex) {
2820 chandransh 6588
      this.wex = wex;
6589
    }
6590
 
6591
    public void unsetWex() {
6592
      this.wex = null;
6593
    }
6594
 
3430 rajveer 6595
    /** Returns true if field wex is set (has been assigned a value) and false otherwise */
2820 chandransh 6596
    public boolean isSetWex() {
6597
      return this.wex != null;
6598
    }
6599
 
6600
    public void setWexIsSet(boolean value) {
6601
      if (!value) {
6602
        this.wex = null;
6603
      }
6604
    }
6605
 
6606
    public void setFieldValue(_Fields field, Object value) {
6607
      switch (field) {
5361 mandeep.dh 6608
      case SUCCESS:
6609
        if (value == null) {
6610
          unsetSuccess();
6611
        } else {
6612
          setSuccess((InventoryItem)value);
6613
        }
6614
        break;
6615
 
2820 chandransh 6616
      case WEX:
6617
        if (value == null) {
6618
          unsetWex();
6619
        } else {
6620
          setWex((WarehouseServiceException)value);
6621
        }
6622
        break;
6623
 
6624
      }
6625
    }
6626
 
6627
    public Object getFieldValue(_Fields field) {
6628
      switch (field) {
5361 mandeep.dh 6629
      case SUCCESS:
6630
        return getSuccess();
6631
 
2820 chandransh 6632
      case WEX:
6633
        return getWex();
6634
 
6635
      }
6636
      throw new IllegalStateException();
6637
    }
6638
 
3430 rajveer 6639
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6640
    public boolean isSet(_Fields field) {
6641
      if (field == null) {
6642
        throw new IllegalArgumentException();
6643
      }
2820 chandransh 6644
 
6645
      switch (field) {
5361 mandeep.dh 6646
      case SUCCESS:
6647
        return isSetSuccess();
2820 chandransh 6648
      case WEX:
6649
        return isSetWex();
6650
      }
6651
      throw new IllegalStateException();
6652
    }
6653
 
6654
    @Override
6655
    public boolean equals(Object that) {
6656
      if (that == null)
6657
        return false;
4496 mandeep.dh 6658
      if (that instanceof scanForOrder_result)
6659
        return this.equals((scanForOrder_result)that);
2820 chandransh 6660
      return false;
6661
    }
6662
 
4496 mandeep.dh 6663
    public boolean equals(scanForOrder_result that) {
2820 chandransh 6664
      if (that == null)
6665
        return false;
6666
 
5361 mandeep.dh 6667
      boolean this_present_success = true && this.isSetSuccess();
6668
      boolean that_present_success = true && that.isSetSuccess();
6669
      if (this_present_success || that_present_success) {
6670
        if (!(this_present_success && that_present_success))
6671
          return false;
6672
        if (!this.success.equals(that.success))
6673
          return false;
6674
      }
6675
 
2820 chandransh 6676
      boolean this_present_wex = true && this.isSetWex();
6677
      boolean that_present_wex = true && that.isSetWex();
6678
      if (this_present_wex || that_present_wex) {
6679
        if (!(this_present_wex && that_present_wex))
6680
          return false;
6681
        if (!this.wex.equals(that.wex))
6682
          return false;
6683
      }
6684
 
6685
      return true;
6686
    }
6687
 
6688
    @Override
6689
    public int hashCode() {
6690
      return 0;
6691
    }
6692
 
4496 mandeep.dh 6693
    public int compareTo(scanForOrder_result other) {
2820 chandransh 6694
      if (!getClass().equals(other.getClass())) {
6695
        return getClass().getName().compareTo(other.getClass().getName());
6696
      }
6697
 
6698
      int lastComparison = 0;
4496 mandeep.dh 6699
      scanForOrder_result typedOther = (scanForOrder_result)other;
2820 chandransh 6700
 
5361 mandeep.dh 6701
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
6702
      if (lastComparison != 0) {
6703
        return lastComparison;
6704
      }
6705
      if (isSetSuccess()) {
6706
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
6707
        if (lastComparison != 0) {
6708
          return lastComparison;
6709
        }
6710
      }
3430 rajveer 6711
      lastComparison = Boolean.valueOf(isSetWex()).compareTo(typedOther.isSetWex());
2820 chandransh 6712
      if (lastComparison != 0) {
6713
        return lastComparison;
6714
      }
3430 rajveer 6715
      if (isSetWex()) {
6716
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.wex, typedOther.wex);
6717
        if (lastComparison != 0) {
6718
          return lastComparison;
6719
        }
2820 chandransh 6720
      }
6721
      return 0;
6722
    }
6723
 
3430 rajveer 6724
    public _Fields fieldForId(int fieldId) {
6725
      return _Fields.findByThriftId(fieldId);
6726
    }
6727
 
6728
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6729
      org.apache.thrift.protocol.TField field;
2820 chandransh 6730
      iprot.readStructBegin();
6731
      while (true)
6732
      {
6733
        field = iprot.readFieldBegin();
3430 rajveer 6734
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
2820 chandransh 6735
          break;
6736
        }
3430 rajveer 6737
        switch (field.id) {
5361 mandeep.dh 6738
          case 0: // SUCCESS
6739
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6740
              this.success = new InventoryItem();
6741
              this.success.read(iprot);
6742
            } else { 
6743
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6744
            }
6745
            break;
3430 rajveer 6746
          case 1: // WEX
6747
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6748
              this.wex = new WarehouseServiceException();
6749
              this.wex.read(iprot);
6750
            } else { 
6751
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6752
            }
6753
            break;
6754
          default:
6755
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2820 chandransh 6756
        }
3430 rajveer 6757
        iprot.readFieldEnd();
2820 chandransh 6758
      }
6759
      iprot.readStructEnd();
6760
      validate();
6761
    }
6762
 
3430 rajveer 6763
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2820 chandransh 6764
      oprot.writeStructBegin(STRUCT_DESC);
6765
 
5361 mandeep.dh 6766
      if (this.isSetSuccess()) {
6767
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
6768
        this.success.write(oprot);
6769
        oprot.writeFieldEnd();
6770
      } else if (this.isSetWex()) {
2820 chandransh 6771
        oprot.writeFieldBegin(WEX_FIELD_DESC);
6772
        this.wex.write(oprot);
6773
        oprot.writeFieldEnd();
6774
      }
6775
      oprot.writeFieldStop();
6776
      oprot.writeStructEnd();
6777
    }
6778
 
6779
    @Override
6780
    public String toString() {
4496 mandeep.dh 6781
      StringBuilder sb = new StringBuilder("scanForOrder_result(");
2820 chandransh 6782
      boolean first = true;
6783
 
5361 mandeep.dh 6784
      sb.append("success:");
6785
      if (this.success == null) {
6786
        sb.append("null");
6787
      } else {
6788
        sb.append(this.success);
6789
      }
6790
      first = false;
6791
      if (!first) sb.append(", ");
2820 chandransh 6792
      sb.append("wex:");
6793
      if (this.wex == null) {
6794
        sb.append("null");
6795
      } else {
6796
        sb.append(this.wex);
6797
      }
6798
      first = false;
6799
      sb.append(")");
6800
      return sb.toString();
6801
    }
6802
 
3430 rajveer 6803
    public void validate() throws org.apache.thrift.TException {
2820 chandransh 6804
      // check for required fields
6805
    }
6806
 
3430 rajveer 6807
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6808
      try {
6809
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6810
      } catch (org.apache.thrift.TException te) {
6811
        throw new java.io.IOException(te);
6812
      }
6813
    }
6814
 
6815
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6816
      try {
6817
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6818
      } catch (org.apache.thrift.TException te) {
6819
        throw new java.io.IOException(te);
6820
      }
6821
    }
6822
 
2820 chandransh 6823
  }
6824
 
4496 mandeep.dh 6825
  public static class createItemNumberMapping_args implements org.apache.thrift.TBase<createItemNumberMapping_args, createItemNumberMapping_args._Fields>, java.io.Serializable, Cloneable   {
6826
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createItemNumberMapping_args");
6827
 
6828
    private static final org.apache.thrift.protocol.TField ITEM_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("itemNumber", org.apache.thrift.protocol.TType.STRING, (short)1);
6829
    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)2);
6830
 
6831
    private String itemNumber; // required
6832
    private long itemId; // required
6833
 
6834
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6835
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6836
      ITEM_NUMBER((short)1, "itemNumber"),
6837
      ITEM_ID((short)2, "itemId");
6838
 
6839
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6840
 
6841
      static {
6842
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6843
          byName.put(field.getFieldName(), field);
6844
        }
6845
      }
6846
 
6847
      /**
6848
       * Find the _Fields constant that matches fieldId, or null if its not found.
6849
       */
6850
      public static _Fields findByThriftId(int fieldId) {
6851
        switch(fieldId) {
6852
          case 1: // ITEM_NUMBER
6853
            return ITEM_NUMBER;
6854
          case 2: // ITEM_ID
6855
            return ITEM_ID;
6856
          default:
6857
            return null;
6858
        }
6859
      }
6860
 
6861
      /**
6862
       * Find the _Fields constant that matches fieldId, throwing an exception
6863
       * if it is not found.
6864
       */
6865
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6866
        _Fields fields = findByThriftId(fieldId);
6867
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6868
        return fields;
6869
      }
6870
 
6871
      /**
6872
       * Find the _Fields constant that matches name, or null if its not found.
6873
       */
6874
      public static _Fields findByName(String name) {
6875
        return byName.get(name);
6876
      }
6877
 
6878
      private final short _thriftId;
6879
      private final String _fieldName;
6880
 
6881
      _Fields(short thriftId, String fieldName) {
6882
        _thriftId = thriftId;
6883
        _fieldName = fieldName;
6884
      }
6885
 
6886
      public short getThriftFieldId() {
6887
        return _thriftId;
6888
      }
6889
 
6890
      public String getFieldName() {
6891
        return _fieldName;
6892
      }
6893
    }
6894
 
6895
    // isset id assignments
6896
    private static final int __ITEMID_ISSET_ID = 0;
6897
    private BitSet __isset_bit_vector = new BitSet(1);
6898
 
6899
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6900
    static {
6901
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6902
      tmpMap.put(_Fields.ITEM_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("itemNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6903
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
6904
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6905
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6906
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6907
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createItemNumberMapping_args.class, metaDataMap);
6908
    }
6909
 
6910
    public createItemNumberMapping_args() {
6911
    }
6912
 
6913
    public createItemNumberMapping_args(
6914
      String itemNumber,
6915
      long itemId)
6916
    {
6917
      this();
6918
      this.itemNumber = itemNumber;
6919
      this.itemId = itemId;
6920
      setItemIdIsSet(true);
6921
    }
6922
 
6923
    /**
6924
     * Performs a deep copy on <i>other</i>.
6925
     */
6926
    public createItemNumberMapping_args(createItemNumberMapping_args other) {
6927
      __isset_bit_vector.clear();
6928
      __isset_bit_vector.or(other.__isset_bit_vector);
6929
      if (other.isSetItemNumber()) {
6930
        this.itemNumber = other.itemNumber;
6931
      }
6932
      this.itemId = other.itemId;
6933
    }
6934
 
6935
    public createItemNumberMapping_args deepCopy() {
6936
      return new createItemNumberMapping_args(this);
6937
    }
6938
 
6939
    @Override
6940
    public void clear() {
6941
      this.itemNumber = null;
6942
      setItemIdIsSet(false);
6943
      this.itemId = 0;
6944
    }
6945
 
6946
    public String getItemNumber() {
6947
      return this.itemNumber;
6948
    }
6949
 
6950
    public void setItemNumber(String itemNumber) {
6951
      this.itemNumber = itemNumber;
6952
    }
6953
 
6954
    public void unsetItemNumber() {
6955
      this.itemNumber = null;
6956
    }
6957
 
6958
    /** Returns true if field itemNumber is set (has been assigned a value) and false otherwise */
6959
    public boolean isSetItemNumber() {
6960
      return this.itemNumber != null;
6961
    }
6962
 
6963
    public void setItemNumberIsSet(boolean value) {
6964
      if (!value) {
6965
        this.itemNumber = null;
6966
      }
6967
    }
6968
 
6969
    public long getItemId() {
6970
      return this.itemId;
6971
    }
6972
 
6973
    public void setItemId(long itemId) {
6974
      this.itemId = itemId;
6975
      setItemIdIsSet(true);
6976
    }
6977
 
6978
    public void unsetItemId() {
6979
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
6980
    }
6981
 
6982
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
6983
    public boolean isSetItemId() {
6984
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
6985
    }
6986
 
6987
    public void setItemIdIsSet(boolean value) {
6988
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
6989
    }
6990
 
6991
    public void setFieldValue(_Fields field, Object value) {
6992
      switch (field) {
6993
      case ITEM_NUMBER:
6994
        if (value == null) {
6995
          unsetItemNumber();
6996
        } else {
6997
          setItemNumber((String)value);
6998
        }
6999
        break;
7000
 
7001
      case ITEM_ID:
7002
        if (value == null) {
7003
          unsetItemId();
7004
        } else {
7005
          setItemId((Long)value);
7006
        }
7007
        break;
7008
 
7009
      }
7010
    }
7011
 
7012
    public Object getFieldValue(_Fields field) {
7013
      switch (field) {
7014
      case ITEM_NUMBER:
7015
        return getItemNumber();
7016
 
7017
      case ITEM_ID:
7018
        return Long.valueOf(getItemId());
7019
 
7020
      }
7021
      throw new IllegalStateException();
7022
    }
7023
 
7024
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7025
    public boolean isSet(_Fields field) {
7026
      if (field == null) {
7027
        throw new IllegalArgumentException();
7028
      }
7029
 
7030
      switch (field) {
7031
      case ITEM_NUMBER:
7032
        return isSetItemNumber();
7033
      case ITEM_ID:
7034
        return isSetItemId();
7035
      }
7036
      throw new IllegalStateException();
7037
    }
7038
 
7039
    @Override
7040
    public boolean equals(Object that) {
7041
      if (that == null)
7042
        return false;
7043
      if (that instanceof createItemNumberMapping_args)
7044
        return this.equals((createItemNumberMapping_args)that);
7045
      return false;
7046
    }
7047
 
7048
    public boolean equals(createItemNumberMapping_args that) {
7049
      if (that == null)
7050
        return false;
7051
 
7052
      boolean this_present_itemNumber = true && this.isSetItemNumber();
7053
      boolean that_present_itemNumber = true && that.isSetItemNumber();
7054
      if (this_present_itemNumber || that_present_itemNumber) {
7055
        if (!(this_present_itemNumber && that_present_itemNumber))
7056
          return false;
7057
        if (!this.itemNumber.equals(that.itemNumber))
7058
          return false;
7059
      }
7060
 
7061
      boolean this_present_itemId = true;
7062
      boolean that_present_itemId = true;
7063
      if (this_present_itemId || that_present_itemId) {
7064
        if (!(this_present_itemId && that_present_itemId))
7065
          return false;
7066
        if (this.itemId != that.itemId)
7067
          return false;
7068
      }
7069
 
7070
      return true;
7071
    }
7072
 
7073
    @Override
7074
    public int hashCode() {
7075
      return 0;
7076
    }
7077
 
7078
    public int compareTo(createItemNumberMapping_args other) {
7079
      if (!getClass().equals(other.getClass())) {
7080
        return getClass().getName().compareTo(other.getClass().getName());
7081
      }
7082
 
7083
      int lastComparison = 0;
7084
      createItemNumberMapping_args typedOther = (createItemNumberMapping_args)other;
7085
 
7086
      lastComparison = Boolean.valueOf(isSetItemNumber()).compareTo(typedOther.isSetItemNumber());
7087
      if (lastComparison != 0) {
7088
        return lastComparison;
7089
      }
7090
      if (isSetItemNumber()) {
7091
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemNumber, typedOther.itemNumber);
7092
        if (lastComparison != 0) {
7093
          return lastComparison;
7094
        }
7095
      }
7096
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
7097
      if (lastComparison != 0) {
7098
        return lastComparison;
7099
      }
7100
      if (isSetItemId()) {
7101
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
7102
        if (lastComparison != 0) {
7103
          return lastComparison;
7104
        }
7105
      }
7106
      return 0;
7107
    }
7108
 
7109
    public _Fields fieldForId(int fieldId) {
7110
      return _Fields.findByThriftId(fieldId);
7111
    }
7112
 
7113
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7114
      org.apache.thrift.protocol.TField field;
7115
      iprot.readStructBegin();
7116
      while (true)
7117
      {
7118
        field = iprot.readFieldBegin();
7119
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7120
          break;
7121
        }
7122
        switch (field.id) {
7123
          case 1: // ITEM_NUMBER
7124
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
7125
              this.itemNumber = iprot.readString();
7126
            } else { 
7127
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7128
            }
7129
            break;
7130
          case 2: // ITEM_ID
7131
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7132
              this.itemId = iprot.readI64();
7133
              setItemIdIsSet(true);
7134
            } else { 
7135
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7136
            }
7137
            break;
7138
          default:
7139
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7140
        }
7141
        iprot.readFieldEnd();
7142
      }
7143
      iprot.readStructEnd();
7144
      validate();
7145
    }
7146
 
7147
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7148
      validate();
7149
 
7150
      oprot.writeStructBegin(STRUCT_DESC);
7151
      if (this.itemNumber != null) {
7152
        oprot.writeFieldBegin(ITEM_NUMBER_FIELD_DESC);
7153
        oprot.writeString(this.itemNumber);
7154
        oprot.writeFieldEnd();
7155
      }
7156
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
7157
      oprot.writeI64(this.itemId);
7158
      oprot.writeFieldEnd();
7159
      oprot.writeFieldStop();
7160
      oprot.writeStructEnd();
7161
    }
7162
 
7163
    @Override
7164
    public String toString() {
7165
      StringBuilder sb = new StringBuilder("createItemNumberMapping_args(");
7166
      boolean first = true;
7167
 
7168
      sb.append("itemNumber:");
7169
      if (this.itemNumber == null) {
7170
        sb.append("null");
7171
      } else {
7172
        sb.append(this.itemNumber);
7173
      }
7174
      first = false;
7175
      if (!first) sb.append(", ");
7176
      sb.append("itemId:");
7177
      sb.append(this.itemId);
7178
      first = false;
7179
      sb.append(")");
7180
      return sb.toString();
7181
    }
7182
 
7183
    public void validate() throws org.apache.thrift.TException {
7184
      // check for required fields
7185
    }
7186
 
7187
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7188
      try {
7189
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7190
      } catch (org.apache.thrift.TException te) {
7191
        throw new java.io.IOException(te);
7192
      }
7193
    }
7194
 
7195
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7196
      try {
7197
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7198
        __isset_bit_vector = new BitSet(1);
7199
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7200
      } catch (org.apache.thrift.TException te) {
7201
        throw new java.io.IOException(te);
7202
      }
7203
    }
7204
 
7205
  }
7206
 
7207
  public static class createItemNumberMapping_result implements org.apache.thrift.TBase<createItemNumberMapping_result, createItemNumberMapping_result._Fields>, java.io.Serializable, Cloneable   {
7208
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("createItemNumberMapping_result");
7209
 
7210
 
7211
 
7212
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7213
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7214
;
7215
 
7216
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7217
 
7218
      static {
7219
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7220
          byName.put(field.getFieldName(), field);
7221
        }
7222
      }
7223
 
7224
      /**
7225
       * Find the _Fields constant that matches fieldId, or null if its not found.
7226
       */
7227
      public static _Fields findByThriftId(int fieldId) {
7228
        switch(fieldId) {
7229
          default:
7230
            return null;
7231
        }
7232
      }
7233
 
7234
      /**
7235
       * Find the _Fields constant that matches fieldId, throwing an exception
7236
       * if it is not found.
7237
       */
7238
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7239
        _Fields fields = findByThriftId(fieldId);
7240
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7241
        return fields;
7242
      }
7243
 
7244
      /**
7245
       * Find the _Fields constant that matches name, or null if its not found.
7246
       */
7247
      public static _Fields findByName(String name) {
7248
        return byName.get(name);
7249
      }
7250
 
7251
      private final short _thriftId;
7252
      private final String _fieldName;
7253
 
7254
      _Fields(short thriftId, String fieldName) {
7255
        _thriftId = thriftId;
7256
        _fieldName = fieldName;
7257
      }
7258
 
7259
      public short getThriftFieldId() {
7260
        return _thriftId;
7261
      }
7262
 
7263
      public String getFieldName() {
7264
        return _fieldName;
7265
      }
7266
    }
7267
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7268
    static {
7269
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7270
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7271
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(createItemNumberMapping_result.class, metaDataMap);
7272
    }
7273
 
7274
    public createItemNumberMapping_result() {
7275
    }
7276
 
7277
    /**
7278
     * Performs a deep copy on <i>other</i>.
7279
     */
7280
    public createItemNumberMapping_result(createItemNumberMapping_result other) {
7281
    }
7282
 
7283
    public createItemNumberMapping_result deepCopy() {
7284
      return new createItemNumberMapping_result(this);
7285
    }
7286
 
7287
    @Override
7288
    public void clear() {
7289
    }
7290
 
7291
    public void setFieldValue(_Fields field, Object value) {
7292
      switch (field) {
7293
      }
7294
    }
7295
 
7296
    public Object getFieldValue(_Fields field) {
7297
      switch (field) {
7298
      }
7299
      throw new IllegalStateException();
7300
    }
7301
 
7302
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7303
    public boolean isSet(_Fields field) {
7304
      if (field == null) {
7305
        throw new IllegalArgumentException();
7306
      }
7307
 
7308
      switch (field) {
7309
      }
7310
      throw new IllegalStateException();
7311
    }
7312
 
7313
    @Override
7314
    public boolean equals(Object that) {
7315
      if (that == null)
7316
        return false;
7317
      if (that instanceof createItemNumberMapping_result)
7318
        return this.equals((createItemNumberMapping_result)that);
7319
      return false;
7320
    }
7321
 
7322
    public boolean equals(createItemNumberMapping_result that) {
7323
      if (that == null)
7324
        return false;
7325
 
7326
      return true;
7327
    }
7328
 
7329
    @Override
7330
    public int hashCode() {
7331
      return 0;
7332
    }
7333
 
7334
    public int compareTo(createItemNumberMapping_result other) {
7335
      if (!getClass().equals(other.getClass())) {
7336
        return getClass().getName().compareTo(other.getClass().getName());
7337
      }
7338
 
7339
      int lastComparison = 0;
7340
      createItemNumberMapping_result typedOther = (createItemNumberMapping_result)other;
7341
 
7342
      return 0;
7343
    }
7344
 
7345
    public _Fields fieldForId(int fieldId) {
7346
      return _Fields.findByThriftId(fieldId);
7347
    }
7348
 
7349
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7350
      org.apache.thrift.protocol.TField field;
7351
      iprot.readStructBegin();
7352
      while (true)
7353
      {
7354
        field = iprot.readFieldBegin();
7355
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7356
          break;
7357
        }
7358
        switch (field.id) {
7359
          default:
7360
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7361
        }
7362
        iprot.readFieldEnd();
7363
      }
7364
      iprot.readStructEnd();
7365
      validate();
7366
    }
7367
 
7368
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7369
      oprot.writeStructBegin(STRUCT_DESC);
7370
 
7371
      oprot.writeFieldStop();
7372
      oprot.writeStructEnd();
7373
    }
7374
 
7375
    @Override
7376
    public String toString() {
7377
      StringBuilder sb = new StringBuilder("createItemNumberMapping_result(");
7378
      boolean first = true;
7379
 
7380
      sb.append(")");
7381
      return sb.toString();
7382
    }
7383
 
7384
    public void validate() throws org.apache.thrift.TException {
7385
      // check for required fields
7386
    }
7387
 
7388
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7389
      try {
7390
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7391
      } catch (org.apache.thrift.TException te) {
7392
        throw new java.io.IOException(te);
7393
      }
7394
    }
7395
 
7396
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7397
      try {
7398
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7399
      } catch (org.apache.thrift.TException te) {
7400
        throw new java.io.IOException(te);
7401
      }
7402
    }
7403
 
7404
  }
7405
 
4622 amit.gupta 7406
  public static class getItemNumbers_args implements org.apache.thrift.TBase<getItemNumbers_args, getItemNumbers_args._Fields>, java.io.Serializable, Cloneable   {
7407
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemNumbers_args");
7408
 
7409
    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)1);
7410
 
7411
    private long itemId; // required
7412
 
7413
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7414
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7415
      ITEM_ID((short)1, "itemId");
7416
 
7417
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7418
 
7419
      static {
7420
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7421
          byName.put(field.getFieldName(), field);
7422
        }
7423
      }
7424
 
7425
      /**
7426
       * Find the _Fields constant that matches fieldId, or null if its not found.
7427
       */
7428
      public static _Fields findByThriftId(int fieldId) {
7429
        switch(fieldId) {
7430
          case 1: // ITEM_ID
7431
            return ITEM_ID;
7432
          default:
7433
            return null;
7434
        }
7435
      }
7436
 
7437
      /**
7438
       * Find the _Fields constant that matches fieldId, throwing an exception
7439
       * if it is not found.
7440
       */
7441
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7442
        _Fields fields = findByThriftId(fieldId);
7443
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7444
        return fields;
7445
      }
7446
 
7447
      /**
7448
       * Find the _Fields constant that matches name, or null if its not found.
7449
       */
7450
      public static _Fields findByName(String name) {
7451
        return byName.get(name);
7452
      }
7453
 
7454
      private final short _thriftId;
7455
      private final String _fieldName;
7456
 
7457
      _Fields(short thriftId, String fieldName) {
7458
        _thriftId = thriftId;
7459
        _fieldName = fieldName;
7460
      }
7461
 
7462
      public short getThriftFieldId() {
7463
        return _thriftId;
7464
      }
7465
 
7466
      public String getFieldName() {
7467
        return _fieldName;
7468
      }
7469
    }
7470
 
7471
    // isset id assignments
7472
    private static final int __ITEMID_ISSET_ID = 0;
7473
    private BitSet __isset_bit_vector = new BitSet(1);
7474
 
7475
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7476
    static {
7477
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7478
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7479
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7480
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7481
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemNumbers_args.class, metaDataMap);
7482
    }
7483
 
7484
    public getItemNumbers_args() {
7485
    }
7486
 
7487
    public getItemNumbers_args(
7488
      long itemId)
7489
    {
7490
      this();
7491
      this.itemId = itemId;
7492
      setItemIdIsSet(true);
7493
    }
7494
 
7495
    /**
7496
     * Performs a deep copy on <i>other</i>.
7497
     */
7498
    public getItemNumbers_args(getItemNumbers_args other) {
7499
      __isset_bit_vector.clear();
7500
      __isset_bit_vector.or(other.__isset_bit_vector);
7501
      this.itemId = other.itemId;
7502
    }
7503
 
7504
    public getItemNumbers_args deepCopy() {
7505
      return new getItemNumbers_args(this);
7506
    }
7507
 
7508
    @Override
7509
    public void clear() {
7510
      setItemIdIsSet(false);
7511
      this.itemId = 0;
7512
    }
7513
 
7514
    public long getItemId() {
7515
      return this.itemId;
7516
    }
7517
 
7518
    public void setItemId(long itemId) {
7519
      this.itemId = itemId;
7520
      setItemIdIsSet(true);
7521
    }
7522
 
7523
    public void unsetItemId() {
7524
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
7525
    }
7526
 
7527
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
7528
    public boolean isSetItemId() {
7529
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
7530
    }
7531
 
7532
    public void setItemIdIsSet(boolean value) {
7533
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
7534
    }
7535
 
7536
    public void setFieldValue(_Fields field, Object value) {
7537
      switch (field) {
7538
      case ITEM_ID:
7539
        if (value == null) {
7540
          unsetItemId();
7541
        } else {
7542
          setItemId((Long)value);
7543
        }
7544
        break;
7545
 
7546
      }
7547
    }
7548
 
7549
    public Object getFieldValue(_Fields field) {
7550
      switch (field) {
7551
      case ITEM_ID:
7552
        return Long.valueOf(getItemId());
7553
 
7554
      }
7555
      throw new IllegalStateException();
7556
    }
7557
 
7558
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7559
    public boolean isSet(_Fields field) {
7560
      if (field == null) {
7561
        throw new IllegalArgumentException();
7562
      }
7563
 
7564
      switch (field) {
7565
      case ITEM_ID:
7566
        return isSetItemId();
7567
      }
7568
      throw new IllegalStateException();
7569
    }
7570
 
7571
    @Override
7572
    public boolean equals(Object that) {
7573
      if (that == null)
7574
        return false;
7575
      if (that instanceof getItemNumbers_args)
7576
        return this.equals((getItemNumbers_args)that);
7577
      return false;
7578
    }
7579
 
7580
    public boolean equals(getItemNumbers_args that) {
7581
      if (that == null)
7582
        return false;
7583
 
7584
      boolean this_present_itemId = true;
7585
      boolean that_present_itemId = true;
7586
      if (this_present_itemId || that_present_itemId) {
7587
        if (!(this_present_itemId && that_present_itemId))
7588
          return false;
7589
        if (this.itemId != that.itemId)
7590
          return false;
7591
      }
7592
 
7593
      return true;
7594
    }
7595
 
7596
    @Override
7597
    public int hashCode() {
7598
      return 0;
7599
    }
7600
 
7601
    public int compareTo(getItemNumbers_args other) {
7602
      if (!getClass().equals(other.getClass())) {
7603
        return getClass().getName().compareTo(other.getClass().getName());
7604
      }
7605
 
7606
      int lastComparison = 0;
7607
      getItemNumbers_args typedOther = (getItemNumbers_args)other;
7608
 
7609
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
7610
      if (lastComparison != 0) {
7611
        return lastComparison;
7612
      }
7613
      if (isSetItemId()) {
7614
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
7615
        if (lastComparison != 0) {
7616
          return lastComparison;
7617
        }
7618
      }
7619
      return 0;
7620
    }
7621
 
7622
    public _Fields fieldForId(int fieldId) {
7623
      return _Fields.findByThriftId(fieldId);
7624
    }
7625
 
7626
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7627
      org.apache.thrift.protocol.TField field;
7628
      iprot.readStructBegin();
7629
      while (true)
7630
      {
7631
        field = iprot.readFieldBegin();
7632
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7633
          break;
7634
        }
7635
        switch (field.id) {
7636
          case 1: // ITEM_ID
7637
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7638
              this.itemId = iprot.readI64();
7639
              setItemIdIsSet(true);
7640
            } else { 
7641
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7642
            }
7643
            break;
7644
          default:
7645
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7646
        }
7647
        iprot.readFieldEnd();
7648
      }
7649
      iprot.readStructEnd();
7650
      validate();
7651
    }
7652
 
7653
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7654
      validate();
7655
 
7656
      oprot.writeStructBegin(STRUCT_DESC);
7657
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
7658
      oprot.writeI64(this.itemId);
7659
      oprot.writeFieldEnd();
7660
      oprot.writeFieldStop();
7661
      oprot.writeStructEnd();
7662
    }
7663
 
7664
    @Override
7665
    public String toString() {
7666
      StringBuilder sb = new StringBuilder("getItemNumbers_args(");
7667
      boolean first = true;
7668
 
7669
      sb.append("itemId:");
7670
      sb.append(this.itemId);
7671
      first = false;
7672
      sb.append(")");
7673
      return sb.toString();
7674
    }
7675
 
7676
    public void validate() throws org.apache.thrift.TException {
7677
      // check for required fields
7678
    }
7679
 
7680
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7681
      try {
7682
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7683
      } catch (org.apache.thrift.TException te) {
7684
        throw new java.io.IOException(te);
7685
      }
7686
    }
7687
 
7688
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7689
      try {
7690
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7691
        __isset_bit_vector = new BitSet(1);
7692
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7693
      } catch (org.apache.thrift.TException te) {
7694
        throw new java.io.IOException(te);
7695
      }
7696
    }
7697
 
7698
  }
7699
 
7700
  public static class getItemNumbers_result implements org.apache.thrift.TBase<getItemNumbers_result, getItemNumbers_result._Fields>, java.io.Serializable, Cloneable   {
7701
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemNumbers_result");
7702
 
7703
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
7704
 
7705
    private List<String> success; // required
7706
 
7707
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7708
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7709
      SUCCESS((short)0, "success");
7710
 
7711
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7712
 
7713
      static {
7714
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7715
          byName.put(field.getFieldName(), field);
7716
        }
7717
      }
7718
 
7719
      /**
7720
       * Find the _Fields constant that matches fieldId, or null if its not found.
7721
       */
7722
      public static _Fields findByThriftId(int fieldId) {
7723
        switch(fieldId) {
7724
          case 0: // SUCCESS
7725
            return SUCCESS;
7726
          default:
7727
            return null;
7728
        }
7729
      }
7730
 
7731
      /**
7732
       * Find the _Fields constant that matches fieldId, throwing an exception
7733
       * if it is not found.
7734
       */
7735
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7736
        _Fields fields = findByThriftId(fieldId);
7737
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7738
        return fields;
7739
      }
7740
 
7741
      /**
7742
       * Find the _Fields constant that matches name, or null if its not found.
7743
       */
7744
      public static _Fields findByName(String name) {
7745
        return byName.get(name);
7746
      }
7747
 
7748
      private final short _thriftId;
7749
      private final String _fieldName;
7750
 
7751
      _Fields(short thriftId, String fieldName) {
7752
        _thriftId = thriftId;
7753
        _fieldName = fieldName;
7754
      }
7755
 
7756
      public short getThriftFieldId() {
7757
        return _thriftId;
7758
      }
7759
 
7760
      public String getFieldName() {
7761
        return _fieldName;
7762
      }
7763
    }
7764
 
7765
    // isset id assignments
7766
 
7767
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7768
    static {
7769
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7770
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7771
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
7772
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
7773
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7774
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemNumbers_result.class, metaDataMap);
7775
    }
7776
 
7777
    public getItemNumbers_result() {
7778
    }
7779
 
7780
    public getItemNumbers_result(
7781
      List<String> success)
7782
    {
7783
      this();
7784
      this.success = success;
7785
    }
7786
 
7787
    /**
7788
     * Performs a deep copy on <i>other</i>.
7789
     */
7790
    public getItemNumbers_result(getItemNumbers_result other) {
7791
      if (other.isSetSuccess()) {
7792
        List<String> __this__success = new ArrayList<String>();
7793
        for (String other_element : other.success) {
7794
          __this__success.add(other_element);
7795
        }
7796
        this.success = __this__success;
7797
      }
7798
    }
7799
 
7800
    public getItemNumbers_result deepCopy() {
7801
      return new getItemNumbers_result(this);
7802
    }
7803
 
7804
    @Override
7805
    public void clear() {
7806
      this.success = null;
7807
    }
7808
 
7809
    public int getSuccessSize() {
7810
      return (this.success == null) ? 0 : this.success.size();
7811
    }
7812
 
7813
    public java.util.Iterator<String> getSuccessIterator() {
7814
      return (this.success == null) ? null : this.success.iterator();
7815
    }
7816
 
7817
    public void addToSuccess(String elem) {
7818
      if (this.success == null) {
7819
        this.success = new ArrayList<String>();
7820
      }
7821
      this.success.add(elem);
7822
    }
7823
 
7824
    public List<String> getSuccess() {
7825
      return this.success;
7826
    }
7827
 
7828
    public void setSuccess(List<String> success) {
7829
      this.success = success;
7830
    }
7831
 
7832
    public void unsetSuccess() {
7833
      this.success = null;
7834
    }
7835
 
7836
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
7837
    public boolean isSetSuccess() {
7838
      return this.success != null;
7839
    }
7840
 
7841
    public void setSuccessIsSet(boolean value) {
7842
      if (!value) {
7843
        this.success = null;
7844
      }
7845
    }
7846
 
7847
    public void setFieldValue(_Fields field, Object value) {
7848
      switch (field) {
7849
      case SUCCESS:
7850
        if (value == null) {
7851
          unsetSuccess();
7852
        } else {
7853
          setSuccess((List<String>)value);
7854
        }
7855
        break;
7856
 
7857
      }
7858
    }
7859
 
7860
    public Object getFieldValue(_Fields field) {
7861
      switch (field) {
7862
      case SUCCESS:
7863
        return getSuccess();
7864
 
7865
      }
7866
      throw new IllegalStateException();
7867
    }
7868
 
7869
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7870
    public boolean isSet(_Fields field) {
7871
      if (field == null) {
7872
        throw new IllegalArgumentException();
7873
      }
7874
 
7875
      switch (field) {
7876
      case SUCCESS:
7877
        return isSetSuccess();
7878
      }
7879
      throw new IllegalStateException();
7880
    }
7881
 
7882
    @Override
7883
    public boolean equals(Object that) {
7884
      if (that == null)
7885
        return false;
7886
      if (that instanceof getItemNumbers_result)
7887
        return this.equals((getItemNumbers_result)that);
7888
      return false;
7889
    }
7890
 
7891
    public boolean equals(getItemNumbers_result that) {
7892
      if (that == null)
7893
        return false;
7894
 
7895
      boolean this_present_success = true && this.isSetSuccess();
7896
      boolean that_present_success = true && that.isSetSuccess();
7897
      if (this_present_success || that_present_success) {
7898
        if (!(this_present_success && that_present_success))
7899
          return false;
7900
        if (!this.success.equals(that.success))
7901
          return false;
7902
      }
7903
 
7904
      return true;
7905
    }
7906
 
7907
    @Override
7908
    public int hashCode() {
7909
      return 0;
7910
    }
7911
 
7912
    public int compareTo(getItemNumbers_result other) {
7913
      if (!getClass().equals(other.getClass())) {
7914
        return getClass().getName().compareTo(other.getClass().getName());
7915
      }
7916
 
7917
      int lastComparison = 0;
7918
      getItemNumbers_result typedOther = (getItemNumbers_result)other;
7919
 
7920
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
7921
      if (lastComparison != 0) {
7922
        return lastComparison;
7923
      }
7924
      if (isSetSuccess()) {
7925
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
7926
        if (lastComparison != 0) {
7927
          return lastComparison;
7928
        }
7929
      }
7930
      return 0;
7931
    }
7932
 
7933
    public _Fields fieldForId(int fieldId) {
7934
      return _Fields.findByThriftId(fieldId);
7935
    }
7936
 
7937
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7938
      org.apache.thrift.protocol.TField field;
7939
      iprot.readStructBegin();
7940
      while (true)
7941
      {
7942
        field = iprot.readFieldBegin();
7943
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7944
          break;
7945
        }
7946
        switch (field.id) {
7947
          case 0: // SUCCESS
7948
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
7949
              {
5361 mandeep.dh 7950
                org.apache.thrift.protocol.TList _list0 = iprot.readListBegin();
7951
                this.success = new ArrayList<String>(_list0.size);
7952
                for (int _i1 = 0; _i1 < _list0.size; ++_i1)
4622 amit.gupta 7953
                {
5361 mandeep.dh 7954
                  String _elem2; // required
7955
                  _elem2 = iprot.readString();
7956
                  this.success.add(_elem2);
4622 amit.gupta 7957
                }
7958
                iprot.readListEnd();
7959
              }
7960
            } else { 
7961
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7962
            }
7963
            break;
7964
          default:
7965
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7966
        }
7967
        iprot.readFieldEnd();
7968
      }
7969
      iprot.readStructEnd();
7970
      validate();
7971
    }
7972
 
7973
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7974
      oprot.writeStructBegin(STRUCT_DESC);
7975
 
7976
      if (this.isSetSuccess()) {
7977
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
7978
        {
7979
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, this.success.size()));
5361 mandeep.dh 7980
          for (String _iter3 : this.success)
4622 amit.gupta 7981
          {
5361 mandeep.dh 7982
            oprot.writeString(_iter3);
4622 amit.gupta 7983
          }
7984
          oprot.writeListEnd();
7985
        }
7986
        oprot.writeFieldEnd();
7987
      }
7988
      oprot.writeFieldStop();
7989
      oprot.writeStructEnd();
7990
    }
7991
 
7992
    @Override
7993
    public String toString() {
7994
      StringBuilder sb = new StringBuilder("getItemNumbers_result(");
7995
      boolean first = true;
7996
 
7997
      sb.append("success:");
7998
      if (this.success == null) {
7999
        sb.append("null");
8000
      } else {
8001
        sb.append(this.success);
8002
      }
8003
      first = false;
8004
      sb.append(")");
8005
      return sb.toString();
8006
    }
8007
 
8008
    public void validate() throws org.apache.thrift.TException {
8009
      // check for required fields
8010
    }
8011
 
8012
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8013
      try {
8014
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8015
      } catch (org.apache.thrift.TException te) {
8016
        throw new java.io.IOException(te);
8017
      }
8018
    }
8019
 
8020
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8021
      try {
8022
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8023
      } catch (org.apache.thrift.TException te) {
8024
        throw new java.io.IOException(te);
8025
      }
8026
    }
8027
 
8028
  }
8029
 
5110 mandeep.dh 8030
  public static class getItemIds_args implements org.apache.thrift.TBase<getItemIds_args, getItemIds_args._Fields>, java.io.Serializable, Cloneable   {
8031
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemIds_args");
8032
 
8033
    private static final org.apache.thrift.protocol.TField ITEM_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("itemNumber", org.apache.thrift.protocol.TType.STRING, (short)1);
8034
 
8035
    private String itemNumber; // required
8036
 
8037
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8038
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8039
      ITEM_NUMBER((short)1, "itemNumber");
8040
 
8041
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8042
 
8043
      static {
8044
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8045
          byName.put(field.getFieldName(), field);
8046
        }
8047
      }
8048
 
8049
      /**
8050
       * Find the _Fields constant that matches fieldId, or null if its not found.
8051
       */
8052
      public static _Fields findByThriftId(int fieldId) {
8053
        switch(fieldId) {
8054
          case 1: // ITEM_NUMBER
8055
            return ITEM_NUMBER;
8056
          default:
8057
            return null;
8058
        }
8059
      }
8060
 
8061
      /**
8062
       * Find the _Fields constant that matches fieldId, throwing an exception
8063
       * if it is not found.
8064
       */
8065
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8066
        _Fields fields = findByThriftId(fieldId);
8067
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8068
        return fields;
8069
      }
8070
 
8071
      /**
8072
       * Find the _Fields constant that matches name, or null if its not found.
8073
       */
8074
      public static _Fields findByName(String name) {
8075
        return byName.get(name);
8076
      }
8077
 
8078
      private final short _thriftId;
8079
      private final String _fieldName;
8080
 
8081
      _Fields(short thriftId, String fieldName) {
8082
        _thriftId = thriftId;
8083
        _fieldName = fieldName;
8084
      }
8085
 
8086
      public short getThriftFieldId() {
8087
        return _thriftId;
8088
      }
8089
 
8090
      public String getFieldName() {
8091
        return _fieldName;
8092
      }
8093
    }
8094
 
8095
    // isset id assignments
8096
 
8097
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8098
    static {
8099
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8100
      tmpMap.put(_Fields.ITEM_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("itemNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8101
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
8102
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8103
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemIds_args.class, metaDataMap);
8104
    }
8105
 
8106
    public getItemIds_args() {
8107
    }
8108
 
8109
    public getItemIds_args(
8110
      String itemNumber)
8111
    {
8112
      this();
8113
      this.itemNumber = itemNumber;
8114
    }
8115
 
8116
    /**
8117
     * Performs a deep copy on <i>other</i>.
8118
     */
8119
    public getItemIds_args(getItemIds_args other) {
8120
      if (other.isSetItemNumber()) {
8121
        this.itemNumber = other.itemNumber;
8122
      }
8123
    }
8124
 
8125
    public getItemIds_args deepCopy() {
8126
      return new getItemIds_args(this);
8127
    }
8128
 
8129
    @Override
8130
    public void clear() {
8131
      this.itemNumber = null;
8132
    }
8133
 
8134
    public String getItemNumber() {
8135
      return this.itemNumber;
8136
    }
8137
 
8138
    public void setItemNumber(String itemNumber) {
8139
      this.itemNumber = itemNumber;
8140
    }
8141
 
8142
    public void unsetItemNumber() {
8143
      this.itemNumber = null;
8144
    }
8145
 
8146
    /** Returns true if field itemNumber is set (has been assigned a value) and false otherwise */
8147
    public boolean isSetItemNumber() {
8148
      return this.itemNumber != null;
8149
    }
8150
 
8151
    public void setItemNumberIsSet(boolean value) {
8152
      if (!value) {
8153
        this.itemNumber = null;
8154
      }
8155
    }
8156
 
8157
    public void setFieldValue(_Fields field, Object value) {
8158
      switch (field) {
8159
      case ITEM_NUMBER:
8160
        if (value == null) {
8161
          unsetItemNumber();
8162
        } else {
8163
          setItemNumber((String)value);
8164
        }
8165
        break;
8166
 
8167
      }
8168
    }
8169
 
8170
    public Object getFieldValue(_Fields field) {
8171
      switch (field) {
8172
      case ITEM_NUMBER:
8173
        return getItemNumber();
8174
 
8175
      }
8176
      throw new IllegalStateException();
8177
    }
8178
 
8179
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8180
    public boolean isSet(_Fields field) {
8181
      if (field == null) {
8182
        throw new IllegalArgumentException();
8183
      }
8184
 
8185
      switch (field) {
8186
      case ITEM_NUMBER:
8187
        return isSetItemNumber();
8188
      }
8189
      throw new IllegalStateException();
8190
    }
8191
 
8192
    @Override
8193
    public boolean equals(Object that) {
8194
      if (that == null)
8195
        return false;
8196
      if (that instanceof getItemIds_args)
8197
        return this.equals((getItemIds_args)that);
8198
      return false;
8199
    }
8200
 
8201
    public boolean equals(getItemIds_args that) {
8202
      if (that == null)
8203
        return false;
8204
 
8205
      boolean this_present_itemNumber = true && this.isSetItemNumber();
8206
      boolean that_present_itemNumber = true && that.isSetItemNumber();
8207
      if (this_present_itemNumber || that_present_itemNumber) {
8208
        if (!(this_present_itemNumber && that_present_itemNumber))
8209
          return false;
8210
        if (!this.itemNumber.equals(that.itemNumber))
8211
          return false;
8212
      }
8213
 
8214
      return true;
8215
    }
8216
 
8217
    @Override
8218
    public int hashCode() {
8219
      return 0;
8220
    }
8221
 
8222
    public int compareTo(getItemIds_args other) {
8223
      if (!getClass().equals(other.getClass())) {
8224
        return getClass().getName().compareTo(other.getClass().getName());
8225
      }
8226
 
8227
      int lastComparison = 0;
8228
      getItemIds_args typedOther = (getItemIds_args)other;
8229
 
8230
      lastComparison = Boolean.valueOf(isSetItemNumber()).compareTo(typedOther.isSetItemNumber());
8231
      if (lastComparison != 0) {
8232
        return lastComparison;
8233
      }
8234
      if (isSetItemNumber()) {
8235
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemNumber, typedOther.itemNumber);
8236
        if (lastComparison != 0) {
8237
          return lastComparison;
8238
        }
8239
      }
8240
      return 0;
8241
    }
8242
 
8243
    public _Fields fieldForId(int fieldId) {
8244
      return _Fields.findByThriftId(fieldId);
8245
    }
8246
 
8247
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8248
      org.apache.thrift.protocol.TField field;
8249
      iprot.readStructBegin();
8250
      while (true)
8251
      {
8252
        field = iprot.readFieldBegin();
8253
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8254
          break;
8255
        }
8256
        switch (field.id) {
8257
          case 1: // ITEM_NUMBER
8258
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8259
              this.itemNumber = iprot.readString();
8260
            } else { 
8261
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8262
            }
8263
            break;
8264
          default:
8265
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8266
        }
8267
        iprot.readFieldEnd();
8268
      }
8269
      iprot.readStructEnd();
8270
      validate();
8271
    }
8272
 
8273
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8274
      validate();
8275
 
8276
      oprot.writeStructBegin(STRUCT_DESC);
8277
      if (this.itemNumber != null) {
8278
        oprot.writeFieldBegin(ITEM_NUMBER_FIELD_DESC);
8279
        oprot.writeString(this.itemNumber);
8280
        oprot.writeFieldEnd();
8281
      }
8282
      oprot.writeFieldStop();
8283
      oprot.writeStructEnd();
8284
    }
8285
 
8286
    @Override
8287
    public String toString() {
8288
      StringBuilder sb = new StringBuilder("getItemIds_args(");
8289
      boolean first = true;
8290
 
8291
      sb.append("itemNumber:");
8292
      if (this.itemNumber == null) {
8293
        sb.append("null");
8294
      } else {
8295
        sb.append(this.itemNumber);
8296
      }
8297
      first = false;
8298
      sb.append(")");
8299
      return sb.toString();
8300
    }
8301
 
8302
    public void validate() throws org.apache.thrift.TException {
8303
      // check for required fields
8304
    }
8305
 
8306
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8307
      try {
8308
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8309
      } catch (org.apache.thrift.TException te) {
8310
        throw new java.io.IOException(te);
8311
      }
8312
    }
8313
 
8314
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8315
      try {
8316
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8317
      } catch (org.apache.thrift.TException te) {
8318
        throw new java.io.IOException(te);
8319
      }
8320
    }
8321
 
8322
  }
8323
 
8324
  public static class getItemIds_result implements org.apache.thrift.TBase<getItemIds_result, getItemIds_result._Fields>, java.io.Serializable, Cloneable   {
8325
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemIds_result");
8326
 
8327
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
8328
 
8329
    private List<Long> success; // required
8330
 
8331
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8332
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8333
      SUCCESS((short)0, "success");
8334
 
8335
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8336
 
8337
      static {
8338
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8339
          byName.put(field.getFieldName(), field);
8340
        }
8341
      }
8342
 
8343
      /**
8344
       * Find the _Fields constant that matches fieldId, or null if its not found.
8345
       */
8346
      public static _Fields findByThriftId(int fieldId) {
8347
        switch(fieldId) {
8348
          case 0: // SUCCESS
8349
            return SUCCESS;
8350
          default:
8351
            return null;
8352
        }
8353
      }
8354
 
8355
      /**
8356
       * Find the _Fields constant that matches fieldId, throwing an exception
8357
       * if it is not found.
8358
       */
8359
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8360
        _Fields fields = findByThriftId(fieldId);
8361
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8362
        return fields;
8363
      }
8364
 
8365
      /**
8366
       * Find the _Fields constant that matches name, or null if its not found.
8367
       */
8368
      public static _Fields findByName(String name) {
8369
        return byName.get(name);
8370
      }
8371
 
8372
      private final short _thriftId;
8373
      private final String _fieldName;
8374
 
8375
      _Fields(short thriftId, String fieldName) {
8376
        _thriftId = thriftId;
8377
        _fieldName = fieldName;
8378
      }
8379
 
8380
      public short getThriftFieldId() {
8381
        return _thriftId;
8382
      }
8383
 
8384
      public String getFieldName() {
8385
        return _fieldName;
8386
      }
8387
    }
8388
 
8389
    // isset id assignments
8390
 
8391
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8392
    static {
8393
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8394
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8395
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
8396
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
8397
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8398
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemIds_result.class, metaDataMap);
8399
    }
8400
 
8401
    public getItemIds_result() {
8402
    }
8403
 
8404
    public getItemIds_result(
8405
      List<Long> success)
8406
    {
8407
      this();
8408
      this.success = success;
8409
    }
8410
 
8411
    /**
8412
     * Performs a deep copy on <i>other</i>.
8413
     */
8414
    public getItemIds_result(getItemIds_result other) {
8415
      if (other.isSetSuccess()) {
8416
        List<Long> __this__success = new ArrayList<Long>();
8417
        for (Long other_element : other.success) {
8418
          __this__success.add(other_element);
8419
        }
8420
        this.success = __this__success;
8421
      }
8422
    }
8423
 
8424
    public getItemIds_result deepCopy() {
8425
      return new getItemIds_result(this);
8426
    }
8427
 
8428
    @Override
8429
    public void clear() {
8430
      this.success = null;
8431
    }
8432
 
8433
    public int getSuccessSize() {
8434
      return (this.success == null) ? 0 : this.success.size();
8435
    }
8436
 
8437
    public java.util.Iterator<Long> getSuccessIterator() {
8438
      return (this.success == null) ? null : this.success.iterator();
8439
    }
8440
 
8441
    public void addToSuccess(long elem) {
8442
      if (this.success == null) {
8443
        this.success = new ArrayList<Long>();
8444
      }
8445
      this.success.add(elem);
8446
    }
8447
 
8448
    public List<Long> getSuccess() {
8449
      return this.success;
8450
    }
8451
 
8452
    public void setSuccess(List<Long> success) {
8453
      this.success = success;
8454
    }
8455
 
8456
    public void unsetSuccess() {
8457
      this.success = null;
8458
    }
8459
 
8460
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
8461
    public boolean isSetSuccess() {
8462
      return this.success != null;
8463
    }
8464
 
8465
    public void setSuccessIsSet(boolean value) {
8466
      if (!value) {
8467
        this.success = null;
8468
      }
8469
    }
8470
 
8471
    public void setFieldValue(_Fields field, Object value) {
8472
      switch (field) {
8473
      case SUCCESS:
8474
        if (value == null) {
8475
          unsetSuccess();
8476
        } else {
8477
          setSuccess((List<Long>)value);
8478
        }
8479
        break;
8480
 
8481
      }
8482
    }
8483
 
8484
    public Object getFieldValue(_Fields field) {
8485
      switch (field) {
8486
      case SUCCESS:
8487
        return getSuccess();
8488
 
8489
      }
8490
      throw new IllegalStateException();
8491
    }
8492
 
8493
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8494
    public boolean isSet(_Fields field) {
8495
      if (field == null) {
8496
        throw new IllegalArgumentException();
8497
      }
8498
 
8499
      switch (field) {
8500
      case SUCCESS:
8501
        return isSetSuccess();
8502
      }
8503
      throw new IllegalStateException();
8504
    }
8505
 
8506
    @Override
8507
    public boolean equals(Object that) {
8508
      if (that == null)
8509
        return false;
8510
      if (that instanceof getItemIds_result)
8511
        return this.equals((getItemIds_result)that);
8512
      return false;
8513
    }
8514
 
8515
    public boolean equals(getItemIds_result that) {
8516
      if (that == null)
8517
        return false;
8518
 
8519
      boolean this_present_success = true && this.isSetSuccess();
8520
      boolean that_present_success = true && that.isSetSuccess();
8521
      if (this_present_success || that_present_success) {
8522
        if (!(this_present_success && that_present_success))
8523
          return false;
8524
        if (!this.success.equals(that.success))
8525
          return false;
8526
      }
8527
 
8528
      return true;
8529
    }
8530
 
8531
    @Override
8532
    public int hashCode() {
8533
      return 0;
8534
    }
8535
 
8536
    public int compareTo(getItemIds_result other) {
8537
      if (!getClass().equals(other.getClass())) {
8538
        return getClass().getName().compareTo(other.getClass().getName());
8539
      }
8540
 
8541
      int lastComparison = 0;
8542
      getItemIds_result typedOther = (getItemIds_result)other;
8543
 
8544
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
8545
      if (lastComparison != 0) {
8546
        return lastComparison;
8547
      }
8548
      if (isSetSuccess()) {
8549
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8550
        if (lastComparison != 0) {
8551
          return lastComparison;
8552
        }
8553
      }
8554
      return 0;
8555
    }
8556
 
8557
    public _Fields fieldForId(int fieldId) {
8558
      return _Fields.findByThriftId(fieldId);
8559
    }
8560
 
8561
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8562
      org.apache.thrift.protocol.TField field;
8563
      iprot.readStructBegin();
8564
      while (true)
8565
      {
8566
        field = iprot.readFieldBegin();
8567
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8568
          break;
8569
        }
8570
        switch (field.id) {
8571
          case 0: // SUCCESS
8572
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
8573
              {
5361 mandeep.dh 8574
                org.apache.thrift.protocol.TList _list4 = iprot.readListBegin();
8575
                this.success = new ArrayList<Long>(_list4.size);
8576
                for (int _i5 = 0; _i5 < _list4.size; ++_i5)
5110 mandeep.dh 8577
                {
5361 mandeep.dh 8578
                  long _elem6; // required
8579
                  _elem6 = iprot.readI64();
8580
                  this.success.add(_elem6);
5110 mandeep.dh 8581
                }
8582
                iprot.readListEnd();
8583
              }
8584
            } else { 
8585
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8586
            }
8587
            break;
8588
          default:
8589
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8590
        }
8591
        iprot.readFieldEnd();
8592
      }
8593
      iprot.readStructEnd();
8594
      validate();
8595
    }
8596
 
8597
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8598
      oprot.writeStructBegin(STRUCT_DESC);
8599
 
8600
      if (this.isSetSuccess()) {
8601
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8602
        {
8603
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
5361 mandeep.dh 8604
          for (long _iter7 : this.success)
5110 mandeep.dh 8605
          {
5361 mandeep.dh 8606
            oprot.writeI64(_iter7);
5110 mandeep.dh 8607
          }
8608
          oprot.writeListEnd();
8609
        }
8610
        oprot.writeFieldEnd();
8611
      }
8612
      oprot.writeFieldStop();
8613
      oprot.writeStructEnd();
8614
    }
8615
 
8616
    @Override
8617
    public String toString() {
8618
      StringBuilder sb = new StringBuilder("getItemIds_result(");
8619
      boolean first = true;
8620
 
8621
      sb.append("success:");
8622
      if (this.success == null) {
8623
        sb.append("null");
8624
      } else {
8625
        sb.append(this.success);
8626
      }
8627
      first = false;
8628
      sb.append(")");
8629
      return sb.toString();
8630
    }
8631
 
8632
    public void validate() throws org.apache.thrift.TException {
8633
      // check for required fields
8634
    }
8635
 
8636
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8637
      try {
8638
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8639
      } catch (org.apache.thrift.TException te) {
8640
        throw new java.io.IOException(te);
8641
      }
8642
    }
8643
 
8644
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8645
      try {
8646
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8647
      } catch (org.apache.thrift.TException te) {
8648
        throw new java.io.IOException(te);
8649
      }
8650
    }
8651
 
8652
  }
8653
 
5185 mandeep.dh 8654
  public static class getInventoryItemsFromLastScanType_args implements org.apache.thrift.TBase<getInventoryItemsFromLastScanType_args, getInventoryItemsFromLastScanType_args._Fields>, java.io.Serializable, Cloneable   {
8655
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryItemsFromLastScanType_args");
8656
 
8657
    private static final org.apache.thrift.protocol.TField LAST_SCAN_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("lastScanType", org.apache.thrift.protocol.TType.I32, (short)1);
8658
 
8659
    private ScanType lastScanType; // required
8660
 
8661
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8662
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8663
      /**
8664
       * 
8665
       * @see ScanType
8666
       */
8667
      LAST_SCAN_TYPE((short)1, "lastScanType");
8668
 
8669
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8670
 
8671
      static {
8672
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8673
          byName.put(field.getFieldName(), field);
8674
        }
8675
      }
8676
 
8677
      /**
8678
       * Find the _Fields constant that matches fieldId, or null if its not found.
8679
       */
8680
      public static _Fields findByThriftId(int fieldId) {
8681
        switch(fieldId) {
8682
          case 1: // LAST_SCAN_TYPE
8683
            return LAST_SCAN_TYPE;
8684
          default:
8685
            return null;
8686
        }
8687
      }
8688
 
8689
      /**
8690
       * Find the _Fields constant that matches fieldId, throwing an exception
8691
       * if it is not found.
8692
       */
8693
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8694
        _Fields fields = findByThriftId(fieldId);
8695
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8696
        return fields;
8697
      }
8698
 
8699
      /**
8700
       * Find the _Fields constant that matches name, or null if its not found.
8701
       */
8702
      public static _Fields findByName(String name) {
8703
        return byName.get(name);
8704
      }
8705
 
8706
      private final short _thriftId;
8707
      private final String _fieldName;
8708
 
8709
      _Fields(short thriftId, String fieldName) {
8710
        _thriftId = thriftId;
8711
        _fieldName = fieldName;
8712
      }
8713
 
8714
      public short getThriftFieldId() {
8715
        return _thriftId;
8716
      }
8717
 
8718
      public String getFieldName() {
8719
        return _fieldName;
8720
      }
8721
    }
8722
 
8723
    // isset id assignments
8724
 
8725
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8726
    static {
8727
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8728
      tmpMap.put(_Fields.LAST_SCAN_TYPE, new org.apache.thrift.meta_data.FieldMetaData("lastScanType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8729
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, ScanType.class)));
8730
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8731
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryItemsFromLastScanType_args.class, metaDataMap);
8732
    }
8733
 
8734
    public getInventoryItemsFromLastScanType_args() {
8735
    }
8736
 
8737
    public getInventoryItemsFromLastScanType_args(
8738
      ScanType lastScanType)
8739
    {
8740
      this();
8741
      this.lastScanType = lastScanType;
8742
    }
8743
 
8744
    /**
8745
     * Performs a deep copy on <i>other</i>.
8746
     */
8747
    public getInventoryItemsFromLastScanType_args(getInventoryItemsFromLastScanType_args other) {
8748
      if (other.isSetLastScanType()) {
8749
        this.lastScanType = other.lastScanType;
8750
      }
8751
    }
8752
 
8753
    public getInventoryItemsFromLastScanType_args deepCopy() {
8754
      return new getInventoryItemsFromLastScanType_args(this);
8755
    }
8756
 
8757
    @Override
8758
    public void clear() {
8759
      this.lastScanType = null;
8760
    }
8761
 
8762
    /**
8763
     * 
8764
     * @see ScanType
8765
     */
8766
    public ScanType getLastScanType() {
8767
      return this.lastScanType;
8768
    }
8769
 
8770
    /**
8771
     * 
8772
     * @see ScanType
8773
     */
8774
    public void setLastScanType(ScanType lastScanType) {
8775
      this.lastScanType = lastScanType;
8776
    }
8777
 
8778
    public void unsetLastScanType() {
8779
      this.lastScanType = null;
8780
    }
8781
 
8782
    /** Returns true if field lastScanType is set (has been assigned a value) and false otherwise */
8783
    public boolean isSetLastScanType() {
8784
      return this.lastScanType != null;
8785
    }
8786
 
8787
    public void setLastScanTypeIsSet(boolean value) {
8788
      if (!value) {
8789
        this.lastScanType = null;
8790
      }
8791
    }
8792
 
8793
    public void setFieldValue(_Fields field, Object value) {
8794
      switch (field) {
8795
      case LAST_SCAN_TYPE:
8796
        if (value == null) {
8797
          unsetLastScanType();
8798
        } else {
8799
          setLastScanType((ScanType)value);
8800
        }
8801
        break;
8802
 
8803
      }
8804
    }
8805
 
8806
    public Object getFieldValue(_Fields field) {
8807
      switch (field) {
8808
      case LAST_SCAN_TYPE:
8809
        return getLastScanType();
8810
 
8811
      }
8812
      throw new IllegalStateException();
8813
    }
8814
 
8815
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8816
    public boolean isSet(_Fields field) {
8817
      if (field == null) {
8818
        throw new IllegalArgumentException();
8819
      }
8820
 
8821
      switch (field) {
8822
      case LAST_SCAN_TYPE:
8823
        return isSetLastScanType();
8824
      }
8825
      throw new IllegalStateException();
8826
    }
8827
 
8828
    @Override
8829
    public boolean equals(Object that) {
8830
      if (that == null)
8831
        return false;
8832
      if (that instanceof getInventoryItemsFromLastScanType_args)
8833
        return this.equals((getInventoryItemsFromLastScanType_args)that);
8834
      return false;
8835
    }
8836
 
8837
    public boolean equals(getInventoryItemsFromLastScanType_args that) {
8838
      if (that == null)
8839
        return false;
8840
 
8841
      boolean this_present_lastScanType = true && this.isSetLastScanType();
8842
      boolean that_present_lastScanType = true && that.isSetLastScanType();
8843
      if (this_present_lastScanType || that_present_lastScanType) {
8844
        if (!(this_present_lastScanType && that_present_lastScanType))
8845
          return false;
8846
        if (!this.lastScanType.equals(that.lastScanType))
8847
          return false;
8848
      }
8849
 
8850
      return true;
8851
    }
8852
 
8853
    @Override
8854
    public int hashCode() {
8855
      return 0;
8856
    }
8857
 
8858
    public int compareTo(getInventoryItemsFromLastScanType_args other) {
8859
      if (!getClass().equals(other.getClass())) {
8860
        return getClass().getName().compareTo(other.getClass().getName());
8861
      }
8862
 
8863
      int lastComparison = 0;
8864
      getInventoryItemsFromLastScanType_args typedOther = (getInventoryItemsFromLastScanType_args)other;
8865
 
8866
      lastComparison = Boolean.valueOf(isSetLastScanType()).compareTo(typedOther.isSetLastScanType());
8867
      if (lastComparison != 0) {
8868
        return lastComparison;
8869
      }
8870
      if (isSetLastScanType()) {
8871
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.lastScanType, typedOther.lastScanType);
8872
        if (lastComparison != 0) {
8873
          return lastComparison;
8874
        }
8875
      }
8876
      return 0;
8877
    }
8878
 
8879
    public _Fields fieldForId(int fieldId) {
8880
      return _Fields.findByThriftId(fieldId);
8881
    }
8882
 
8883
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8884
      org.apache.thrift.protocol.TField field;
8885
      iprot.readStructBegin();
8886
      while (true)
8887
      {
8888
        field = iprot.readFieldBegin();
8889
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8890
          break;
8891
        }
8892
        switch (field.id) {
8893
          case 1: // LAST_SCAN_TYPE
8894
            if (field.type == org.apache.thrift.protocol.TType.I32) {
8895
              this.lastScanType = ScanType.findByValue(iprot.readI32());
8896
            } else { 
8897
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8898
            }
8899
            break;
8900
          default:
8901
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8902
        }
8903
        iprot.readFieldEnd();
8904
      }
8905
      iprot.readStructEnd();
8906
      validate();
8907
    }
8908
 
8909
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8910
      validate();
8911
 
8912
      oprot.writeStructBegin(STRUCT_DESC);
8913
      if (this.lastScanType != null) {
8914
        oprot.writeFieldBegin(LAST_SCAN_TYPE_FIELD_DESC);
8915
        oprot.writeI32(this.lastScanType.getValue());
8916
        oprot.writeFieldEnd();
8917
      }
8918
      oprot.writeFieldStop();
8919
      oprot.writeStructEnd();
8920
    }
8921
 
8922
    @Override
8923
    public String toString() {
8924
      StringBuilder sb = new StringBuilder("getInventoryItemsFromLastScanType_args(");
8925
      boolean first = true;
8926
 
8927
      sb.append("lastScanType:");
8928
      if (this.lastScanType == null) {
8929
        sb.append("null");
8930
      } else {
8931
        sb.append(this.lastScanType);
8932
      }
8933
      first = false;
8934
      sb.append(")");
8935
      return sb.toString();
8936
    }
8937
 
8938
    public void validate() throws org.apache.thrift.TException {
8939
      // check for required fields
8940
    }
8941
 
8942
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8943
      try {
8944
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8945
      } catch (org.apache.thrift.TException te) {
8946
        throw new java.io.IOException(te);
8947
      }
8948
    }
8949
 
8950
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8951
      try {
8952
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8953
      } catch (org.apache.thrift.TException te) {
8954
        throw new java.io.IOException(te);
8955
      }
8956
    }
8957
 
8958
  }
8959
 
8960
  public static class getInventoryItemsFromLastScanType_result implements org.apache.thrift.TBase<getInventoryItemsFromLastScanType_result, getInventoryItemsFromLastScanType_result._Fields>, java.io.Serializable, Cloneable   {
8961
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryItemsFromLastScanType_result");
8962
 
8963
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
8964
    private static final org.apache.thrift.protocol.TField WEX_FIELD_DESC = new org.apache.thrift.protocol.TField("wex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
8965
 
8966
    private List<InventoryItem> success; // required
8967
    private WarehouseServiceException wex; // required
8968
 
8969
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8970
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8971
      SUCCESS((short)0, "success"),
8972
      WEX((short)1, "wex");
8973
 
8974
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8975
 
8976
      static {
8977
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8978
          byName.put(field.getFieldName(), field);
8979
        }
8980
      }
8981
 
8982
      /**
8983
       * Find the _Fields constant that matches fieldId, or null if its not found.
8984
       */
8985
      public static _Fields findByThriftId(int fieldId) {
8986
        switch(fieldId) {
8987
          case 0: // SUCCESS
8988
            return SUCCESS;
8989
          case 1: // WEX
8990
            return WEX;
8991
          default:
8992
            return null;
8993
        }
8994
      }
8995
 
8996
      /**
8997
       * Find the _Fields constant that matches fieldId, throwing an exception
8998
       * if it is not found.
8999
       */
9000
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9001
        _Fields fields = findByThriftId(fieldId);
9002
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9003
        return fields;
9004
      }
9005
 
9006
      /**
9007
       * Find the _Fields constant that matches name, or null if its not found.
9008
       */
9009
      public static _Fields findByName(String name) {
9010
        return byName.get(name);
9011
      }
9012
 
9013
      private final short _thriftId;
9014
      private final String _fieldName;
9015
 
9016
      _Fields(short thriftId, String fieldName) {
9017
        _thriftId = thriftId;
9018
        _fieldName = fieldName;
9019
      }
9020
 
9021
      public short getThriftFieldId() {
9022
        return _thriftId;
9023
      }
9024
 
9025
      public String getFieldName() {
9026
        return _fieldName;
9027
      }
9028
    }
9029
 
9030
    // isset id assignments
9031
 
9032
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9033
    static {
9034
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9035
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9036
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9037
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class))));
9038
      tmpMap.put(_Fields.WEX, new org.apache.thrift.meta_data.FieldMetaData("wex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9039
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9040
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9041
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryItemsFromLastScanType_result.class, metaDataMap);
9042
    }
9043
 
9044
    public getInventoryItemsFromLastScanType_result() {
9045
    }
9046
 
9047
    public getInventoryItemsFromLastScanType_result(
9048
      List<InventoryItem> success,
9049
      WarehouseServiceException wex)
9050
    {
9051
      this();
9052
      this.success = success;
9053
      this.wex = wex;
9054
    }
9055
 
9056
    /**
9057
     * Performs a deep copy on <i>other</i>.
9058
     */
9059
    public getInventoryItemsFromLastScanType_result(getInventoryItemsFromLastScanType_result other) {
9060
      if (other.isSetSuccess()) {
9061
        List<InventoryItem> __this__success = new ArrayList<InventoryItem>();
9062
        for (InventoryItem other_element : other.success) {
9063
          __this__success.add(new InventoryItem(other_element));
9064
        }
9065
        this.success = __this__success;
9066
      }
9067
      if (other.isSetWex()) {
9068
        this.wex = new WarehouseServiceException(other.wex);
9069
      }
9070
    }
9071
 
9072
    public getInventoryItemsFromLastScanType_result deepCopy() {
9073
      return new getInventoryItemsFromLastScanType_result(this);
9074
    }
9075
 
9076
    @Override
9077
    public void clear() {
9078
      this.success = null;
9079
      this.wex = null;
9080
    }
9081
 
9082
    public int getSuccessSize() {
9083
      return (this.success == null) ? 0 : this.success.size();
9084
    }
9085
 
9086
    public java.util.Iterator<InventoryItem> getSuccessIterator() {
9087
      return (this.success == null) ? null : this.success.iterator();
9088
    }
9089
 
9090
    public void addToSuccess(InventoryItem elem) {
9091
      if (this.success == null) {
9092
        this.success = new ArrayList<InventoryItem>();
9093
      }
9094
      this.success.add(elem);
9095
    }
9096
 
9097
    public List<InventoryItem> getSuccess() {
9098
      return this.success;
9099
    }
9100
 
9101
    public void setSuccess(List<InventoryItem> success) {
9102
      this.success = success;
9103
    }
9104
 
9105
    public void unsetSuccess() {
9106
      this.success = null;
9107
    }
9108
 
9109
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9110
    public boolean isSetSuccess() {
9111
      return this.success != null;
9112
    }
9113
 
9114
    public void setSuccessIsSet(boolean value) {
9115
      if (!value) {
9116
        this.success = null;
9117
      }
9118
    }
9119
 
9120
    public WarehouseServiceException getWex() {
9121
      return this.wex;
9122
    }
9123
 
9124
    public void setWex(WarehouseServiceException wex) {
9125
      this.wex = wex;
9126
    }
9127
 
9128
    public void unsetWex() {
9129
      this.wex = null;
9130
    }
9131
 
9132
    /** Returns true if field wex is set (has been assigned a value) and false otherwise */
9133
    public boolean isSetWex() {
9134
      return this.wex != null;
9135
    }
9136
 
9137
    public void setWexIsSet(boolean value) {
9138
      if (!value) {
9139
        this.wex = null;
9140
      }
9141
    }
9142
 
9143
    public void setFieldValue(_Fields field, Object value) {
9144
      switch (field) {
9145
      case SUCCESS:
9146
        if (value == null) {
9147
          unsetSuccess();
9148
        } else {
9149
          setSuccess((List<InventoryItem>)value);
9150
        }
9151
        break;
9152
 
9153
      case WEX:
9154
        if (value == null) {
9155
          unsetWex();
9156
        } else {
9157
          setWex((WarehouseServiceException)value);
9158
        }
9159
        break;
9160
 
9161
      }
9162
    }
9163
 
9164
    public Object getFieldValue(_Fields field) {
9165
      switch (field) {
9166
      case SUCCESS:
9167
        return getSuccess();
9168
 
9169
      case WEX:
9170
        return getWex();
9171
 
9172
      }
9173
      throw new IllegalStateException();
9174
    }
9175
 
9176
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9177
    public boolean isSet(_Fields field) {
9178
      if (field == null) {
9179
        throw new IllegalArgumentException();
9180
      }
9181
 
9182
      switch (field) {
9183
      case SUCCESS:
9184
        return isSetSuccess();
9185
      case WEX:
9186
        return isSetWex();
9187
      }
9188
      throw new IllegalStateException();
9189
    }
9190
 
9191
    @Override
9192
    public boolean equals(Object that) {
9193
      if (that == null)
9194
        return false;
9195
      if (that instanceof getInventoryItemsFromLastScanType_result)
9196
        return this.equals((getInventoryItemsFromLastScanType_result)that);
9197
      return false;
9198
    }
9199
 
9200
    public boolean equals(getInventoryItemsFromLastScanType_result that) {
9201
      if (that == null)
9202
        return false;
9203
 
9204
      boolean this_present_success = true && this.isSetSuccess();
9205
      boolean that_present_success = true && that.isSetSuccess();
9206
      if (this_present_success || that_present_success) {
9207
        if (!(this_present_success && that_present_success))
9208
          return false;
9209
        if (!this.success.equals(that.success))
9210
          return false;
9211
      }
9212
 
9213
      boolean this_present_wex = true && this.isSetWex();
9214
      boolean that_present_wex = true && that.isSetWex();
9215
      if (this_present_wex || that_present_wex) {
9216
        if (!(this_present_wex && that_present_wex))
9217
          return false;
9218
        if (!this.wex.equals(that.wex))
9219
          return false;
9220
      }
9221
 
9222
      return true;
9223
    }
9224
 
9225
    @Override
9226
    public int hashCode() {
9227
      return 0;
9228
    }
9229
 
9230
    public int compareTo(getInventoryItemsFromLastScanType_result other) {
9231
      if (!getClass().equals(other.getClass())) {
9232
        return getClass().getName().compareTo(other.getClass().getName());
9233
      }
9234
 
9235
      int lastComparison = 0;
9236
      getInventoryItemsFromLastScanType_result typedOther = (getInventoryItemsFromLastScanType_result)other;
9237
 
9238
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
9239
      if (lastComparison != 0) {
9240
        return lastComparison;
9241
      }
9242
      if (isSetSuccess()) {
9243
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9244
        if (lastComparison != 0) {
9245
          return lastComparison;
9246
        }
9247
      }
9248
      lastComparison = Boolean.valueOf(isSetWex()).compareTo(typedOther.isSetWex());
9249
      if (lastComparison != 0) {
9250
        return lastComparison;
9251
      }
9252
      if (isSetWex()) {
9253
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.wex, typedOther.wex);
9254
        if (lastComparison != 0) {
9255
          return lastComparison;
9256
        }
9257
      }
9258
      return 0;
9259
    }
9260
 
9261
    public _Fields fieldForId(int fieldId) {
9262
      return _Fields.findByThriftId(fieldId);
9263
    }
9264
 
9265
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9266
      org.apache.thrift.protocol.TField field;
9267
      iprot.readStructBegin();
9268
      while (true)
9269
      {
9270
        field = iprot.readFieldBegin();
9271
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9272
          break;
9273
        }
9274
        switch (field.id) {
9275
          case 0: // SUCCESS
9276
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
9277
              {
5361 mandeep.dh 9278
                org.apache.thrift.protocol.TList _list8 = iprot.readListBegin();
9279
                this.success = new ArrayList<InventoryItem>(_list8.size);
9280
                for (int _i9 = 0; _i9 < _list8.size; ++_i9)
5185 mandeep.dh 9281
                {
5361 mandeep.dh 9282
                  InventoryItem _elem10; // required
9283
                  _elem10 = new InventoryItem();
9284
                  _elem10.read(iprot);
9285
                  this.success.add(_elem10);
5185 mandeep.dh 9286
                }
9287
                iprot.readListEnd();
9288
              }
9289
            } else { 
9290
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9291
            }
9292
            break;
9293
          case 1: // WEX
9294
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9295
              this.wex = new WarehouseServiceException();
9296
              this.wex.read(iprot);
9297
            } else { 
9298
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9299
            }
9300
            break;
9301
          default:
9302
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9303
        }
9304
        iprot.readFieldEnd();
9305
      }
9306
      iprot.readStructEnd();
9307
      validate();
9308
    }
9309
 
9310
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9311
      oprot.writeStructBegin(STRUCT_DESC);
9312
 
9313
      if (this.isSetSuccess()) {
9314
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9315
        {
9316
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
5361 mandeep.dh 9317
          for (InventoryItem _iter11 : this.success)
5185 mandeep.dh 9318
          {
5361 mandeep.dh 9319
            _iter11.write(oprot);
5185 mandeep.dh 9320
          }
9321
          oprot.writeListEnd();
9322
        }
9323
        oprot.writeFieldEnd();
9324
      } else if (this.isSetWex()) {
9325
        oprot.writeFieldBegin(WEX_FIELD_DESC);
9326
        this.wex.write(oprot);
9327
        oprot.writeFieldEnd();
9328
      }
9329
      oprot.writeFieldStop();
9330
      oprot.writeStructEnd();
9331
    }
9332
 
9333
    @Override
9334
    public String toString() {
9335
      StringBuilder sb = new StringBuilder("getInventoryItemsFromLastScanType_result(");
9336
      boolean first = true;
9337
 
9338
      sb.append("success:");
9339
      if (this.success == null) {
9340
        sb.append("null");
9341
      } else {
9342
        sb.append(this.success);
9343
      }
9344
      first = false;
9345
      if (!first) sb.append(", ");
9346
      sb.append("wex:");
9347
      if (this.wex == null) {
9348
        sb.append("null");
9349
      } else {
9350
        sb.append(this.wex);
9351
      }
9352
      first = false;
9353
      sb.append(")");
9354
      return sb.toString();
9355
    }
9356
 
9357
    public void validate() throws org.apache.thrift.TException {
9358
      // check for required fields
9359
    }
9360
 
9361
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9362
      try {
9363
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9364
      } catch (org.apache.thrift.TException te) {
9365
        throw new java.io.IOException(te);
9366
      }
9367
    }
9368
 
9369
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9370
      try {
9371
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9372
      } catch (org.apache.thrift.TException te) {
9373
        throw new java.io.IOException(te);
9374
      }
9375
    }
9376
 
9377
  }
9378
 
9379
  public static class getInventoryItemFromId_args implements org.apache.thrift.TBase<getInventoryItemFromId_args, getInventoryItemFromId_args._Fields>, java.io.Serializable, Cloneable   {
9380
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryItemFromId_args");
9381
 
9382
    private static final org.apache.thrift.protocol.TField INVENTORY_ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("inventoryItemId", org.apache.thrift.protocol.TType.I64, (short)1);
9383
 
9384
    private long inventoryItemId; // required
9385
 
9386
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9387
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9388
      INVENTORY_ITEM_ID((short)1, "inventoryItemId");
9389
 
9390
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9391
 
9392
      static {
9393
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9394
          byName.put(field.getFieldName(), field);
9395
        }
9396
      }
9397
 
9398
      /**
9399
       * Find the _Fields constant that matches fieldId, or null if its not found.
9400
       */
9401
      public static _Fields findByThriftId(int fieldId) {
9402
        switch(fieldId) {
9403
          case 1: // INVENTORY_ITEM_ID
9404
            return INVENTORY_ITEM_ID;
9405
          default:
9406
            return null;
9407
        }
9408
      }
9409
 
9410
      /**
9411
       * Find the _Fields constant that matches fieldId, throwing an exception
9412
       * if it is not found.
9413
       */
9414
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9415
        _Fields fields = findByThriftId(fieldId);
9416
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9417
        return fields;
9418
      }
9419
 
9420
      /**
9421
       * Find the _Fields constant that matches name, or null if its not found.
9422
       */
9423
      public static _Fields findByName(String name) {
9424
        return byName.get(name);
9425
      }
9426
 
9427
      private final short _thriftId;
9428
      private final String _fieldName;
9429
 
9430
      _Fields(short thriftId, String fieldName) {
9431
        _thriftId = thriftId;
9432
        _fieldName = fieldName;
9433
      }
9434
 
9435
      public short getThriftFieldId() {
9436
        return _thriftId;
9437
      }
9438
 
9439
      public String getFieldName() {
9440
        return _fieldName;
9441
      }
9442
    }
9443
 
9444
    // isset id assignments
9445
    private static final int __INVENTORYITEMID_ISSET_ID = 0;
9446
    private BitSet __isset_bit_vector = new BitSet(1);
9447
 
9448
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9449
    static {
9450
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9451
      tmpMap.put(_Fields.INVENTORY_ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("inventoryItemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9452
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
9453
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9454
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryItemFromId_args.class, metaDataMap);
9455
    }
9456
 
9457
    public getInventoryItemFromId_args() {
9458
    }
9459
 
9460
    public getInventoryItemFromId_args(
9461
      long inventoryItemId)
9462
    {
9463
      this();
9464
      this.inventoryItemId = inventoryItemId;
9465
      setInventoryItemIdIsSet(true);
9466
    }
9467
 
9468
    /**
9469
     * Performs a deep copy on <i>other</i>.
9470
     */
9471
    public getInventoryItemFromId_args(getInventoryItemFromId_args other) {
9472
      __isset_bit_vector.clear();
9473
      __isset_bit_vector.or(other.__isset_bit_vector);
9474
      this.inventoryItemId = other.inventoryItemId;
9475
    }
9476
 
9477
    public getInventoryItemFromId_args deepCopy() {
9478
      return new getInventoryItemFromId_args(this);
9479
    }
9480
 
9481
    @Override
9482
    public void clear() {
9483
      setInventoryItemIdIsSet(false);
9484
      this.inventoryItemId = 0;
9485
    }
9486
 
9487
    public long getInventoryItemId() {
9488
      return this.inventoryItemId;
9489
    }
9490
 
9491
    public void setInventoryItemId(long inventoryItemId) {
9492
      this.inventoryItemId = inventoryItemId;
9493
      setInventoryItemIdIsSet(true);
9494
    }
9495
 
9496
    public void unsetInventoryItemId() {
9497
      __isset_bit_vector.clear(__INVENTORYITEMID_ISSET_ID);
9498
    }
9499
 
9500
    /** Returns true if field inventoryItemId is set (has been assigned a value) and false otherwise */
9501
    public boolean isSetInventoryItemId() {
9502
      return __isset_bit_vector.get(__INVENTORYITEMID_ISSET_ID);
9503
    }
9504
 
9505
    public void setInventoryItemIdIsSet(boolean value) {
9506
      __isset_bit_vector.set(__INVENTORYITEMID_ISSET_ID, value);
9507
    }
9508
 
9509
    public void setFieldValue(_Fields field, Object value) {
9510
      switch (field) {
9511
      case INVENTORY_ITEM_ID:
9512
        if (value == null) {
9513
          unsetInventoryItemId();
9514
        } else {
9515
          setInventoryItemId((Long)value);
9516
        }
9517
        break;
9518
 
9519
      }
9520
    }
9521
 
9522
    public Object getFieldValue(_Fields field) {
9523
      switch (field) {
9524
      case INVENTORY_ITEM_ID:
9525
        return Long.valueOf(getInventoryItemId());
9526
 
9527
      }
9528
      throw new IllegalStateException();
9529
    }
9530
 
9531
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9532
    public boolean isSet(_Fields field) {
9533
      if (field == null) {
9534
        throw new IllegalArgumentException();
9535
      }
9536
 
9537
      switch (field) {
9538
      case INVENTORY_ITEM_ID:
9539
        return isSetInventoryItemId();
9540
      }
9541
      throw new IllegalStateException();
9542
    }
9543
 
9544
    @Override
9545
    public boolean equals(Object that) {
9546
      if (that == null)
9547
        return false;
9548
      if (that instanceof getInventoryItemFromId_args)
9549
        return this.equals((getInventoryItemFromId_args)that);
9550
      return false;
9551
    }
9552
 
9553
    public boolean equals(getInventoryItemFromId_args that) {
9554
      if (that == null)
9555
        return false;
9556
 
9557
      boolean this_present_inventoryItemId = true;
9558
      boolean that_present_inventoryItemId = true;
9559
      if (this_present_inventoryItemId || that_present_inventoryItemId) {
9560
        if (!(this_present_inventoryItemId && that_present_inventoryItemId))
9561
          return false;
9562
        if (this.inventoryItemId != that.inventoryItemId)
9563
          return false;
9564
      }
9565
 
9566
      return true;
9567
    }
9568
 
9569
    @Override
9570
    public int hashCode() {
9571
      return 0;
9572
    }
9573
 
9574
    public int compareTo(getInventoryItemFromId_args other) {
9575
      if (!getClass().equals(other.getClass())) {
9576
        return getClass().getName().compareTo(other.getClass().getName());
9577
      }
9578
 
9579
      int lastComparison = 0;
9580
      getInventoryItemFromId_args typedOther = (getInventoryItemFromId_args)other;
9581
 
9582
      lastComparison = Boolean.valueOf(isSetInventoryItemId()).compareTo(typedOther.isSetInventoryItemId());
9583
      if (lastComparison != 0) {
9584
        return lastComparison;
9585
      }
9586
      if (isSetInventoryItemId()) {
9587
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.inventoryItemId, typedOther.inventoryItemId);
9588
        if (lastComparison != 0) {
9589
          return lastComparison;
9590
        }
9591
      }
9592
      return 0;
9593
    }
9594
 
9595
    public _Fields fieldForId(int fieldId) {
9596
      return _Fields.findByThriftId(fieldId);
9597
    }
9598
 
9599
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9600
      org.apache.thrift.protocol.TField field;
9601
      iprot.readStructBegin();
9602
      while (true)
9603
      {
9604
        field = iprot.readFieldBegin();
9605
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9606
          break;
9607
        }
9608
        switch (field.id) {
9609
          case 1: // INVENTORY_ITEM_ID
9610
            if (field.type == org.apache.thrift.protocol.TType.I64) {
9611
              this.inventoryItemId = iprot.readI64();
9612
              setInventoryItemIdIsSet(true);
9613
            } else { 
9614
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9615
            }
9616
            break;
9617
          default:
9618
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9619
        }
9620
        iprot.readFieldEnd();
9621
      }
9622
      iprot.readStructEnd();
9623
      validate();
9624
    }
9625
 
9626
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9627
      validate();
9628
 
9629
      oprot.writeStructBegin(STRUCT_DESC);
9630
      oprot.writeFieldBegin(INVENTORY_ITEM_ID_FIELD_DESC);
9631
      oprot.writeI64(this.inventoryItemId);
9632
      oprot.writeFieldEnd();
9633
      oprot.writeFieldStop();
9634
      oprot.writeStructEnd();
9635
    }
9636
 
9637
    @Override
9638
    public String toString() {
9639
      StringBuilder sb = new StringBuilder("getInventoryItemFromId_args(");
9640
      boolean first = true;
9641
 
9642
      sb.append("inventoryItemId:");
9643
      sb.append(this.inventoryItemId);
9644
      first = false;
9645
      sb.append(")");
9646
      return sb.toString();
9647
    }
9648
 
9649
    public void validate() throws org.apache.thrift.TException {
9650
      // check for required fields
9651
    }
9652
 
9653
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9654
      try {
9655
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9656
      } catch (org.apache.thrift.TException te) {
9657
        throw new java.io.IOException(te);
9658
      }
9659
    }
9660
 
9661
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9662
      try {
5372 mandeep.dh 9663
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
9664
        __isset_bit_vector = new BitSet(1);
5185 mandeep.dh 9665
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9666
      } catch (org.apache.thrift.TException te) {
9667
        throw new java.io.IOException(te);
9668
      }
9669
    }
9670
 
9671
  }
9672
 
9673
  public static class getInventoryItemFromId_result implements org.apache.thrift.TBase<getInventoryItemFromId_result, getInventoryItemFromId_result._Fields>, java.io.Serializable, Cloneable   {
9674
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryItemFromId_result");
9675
 
9676
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
9677
    private static final org.apache.thrift.protocol.TField WEX_FIELD_DESC = new org.apache.thrift.protocol.TField("wex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
9678
 
9679
    private InventoryItem success; // required
9680
    private WarehouseServiceException wex; // required
9681
 
9682
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9683
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9684
      SUCCESS((short)0, "success"),
9685
      WEX((short)1, "wex");
9686
 
9687
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9688
 
9689
      static {
9690
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9691
          byName.put(field.getFieldName(), field);
9692
        }
9693
      }
9694
 
9695
      /**
9696
       * Find the _Fields constant that matches fieldId, or null if its not found.
9697
       */
9698
      public static _Fields findByThriftId(int fieldId) {
9699
        switch(fieldId) {
9700
          case 0: // SUCCESS
9701
            return SUCCESS;
9702
          case 1: // WEX
9703
            return WEX;
9704
          default:
9705
            return null;
9706
        }
9707
      }
9708
 
9709
      /**
9710
       * Find the _Fields constant that matches fieldId, throwing an exception
9711
       * if it is not found.
9712
       */
9713
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9714
        _Fields fields = findByThriftId(fieldId);
9715
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9716
        return fields;
9717
      }
9718
 
9719
      /**
9720
       * Find the _Fields constant that matches name, or null if its not found.
9721
       */
9722
      public static _Fields findByName(String name) {
9723
        return byName.get(name);
9724
      }
9725
 
9726
      private final short _thriftId;
9727
      private final String _fieldName;
9728
 
9729
      _Fields(short thriftId, String fieldName) {
9730
        _thriftId = thriftId;
9731
        _fieldName = fieldName;
9732
      }
9733
 
9734
      public short getThriftFieldId() {
9735
        return _thriftId;
9736
      }
9737
 
9738
      public String getFieldName() {
9739
        return _fieldName;
9740
      }
9741
    }
9742
 
9743
    // isset id assignments
9744
 
9745
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9746
    static {
9747
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9748
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9749
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class)));
9750
      tmpMap.put(_Fields.WEX, new org.apache.thrift.meta_data.FieldMetaData("wex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9751
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9752
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9753
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryItemFromId_result.class, metaDataMap);
9754
    }
9755
 
9756
    public getInventoryItemFromId_result() {
9757
    }
9758
 
9759
    public getInventoryItemFromId_result(
9760
      InventoryItem success,
9761
      WarehouseServiceException wex)
9762
    {
9763
      this();
9764
      this.success = success;
9765
      this.wex = wex;
9766
    }
9767
 
9768
    /**
9769
     * Performs a deep copy on <i>other</i>.
9770
     */
9771
    public getInventoryItemFromId_result(getInventoryItemFromId_result other) {
9772
      if (other.isSetSuccess()) {
9773
        this.success = new InventoryItem(other.success);
9774
      }
9775
      if (other.isSetWex()) {
9776
        this.wex = new WarehouseServiceException(other.wex);
9777
      }
9778
    }
9779
 
9780
    public getInventoryItemFromId_result deepCopy() {
9781
      return new getInventoryItemFromId_result(this);
9782
    }
9783
 
9784
    @Override
9785
    public void clear() {
9786
      this.success = null;
9787
      this.wex = null;
9788
    }
9789
 
9790
    public InventoryItem getSuccess() {
9791
      return this.success;
9792
    }
9793
 
9794
    public void setSuccess(InventoryItem success) {
9795
      this.success = success;
9796
    }
9797
 
9798
    public void unsetSuccess() {
9799
      this.success = null;
9800
    }
9801
 
9802
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9803
    public boolean isSetSuccess() {
9804
      return this.success != null;
9805
    }
9806
 
9807
    public void setSuccessIsSet(boolean value) {
9808
      if (!value) {
9809
        this.success = null;
9810
      }
9811
    }
9812
 
9813
    public WarehouseServiceException getWex() {
9814
      return this.wex;
9815
    }
9816
 
9817
    public void setWex(WarehouseServiceException wex) {
9818
      this.wex = wex;
9819
    }
9820
 
9821
    public void unsetWex() {
9822
      this.wex = null;
9823
    }
9824
 
9825
    /** Returns true if field wex is set (has been assigned a value) and false otherwise */
9826
    public boolean isSetWex() {
9827
      return this.wex != null;
9828
    }
9829
 
9830
    public void setWexIsSet(boolean value) {
9831
      if (!value) {
9832
        this.wex = null;
9833
      }
9834
    }
9835
 
9836
    public void setFieldValue(_Fields field, Object value) {
9837
      switch (field) {
9838
      case SUCCESS:
9839
        if (value == null) {
9840
          unsetSuccess();
9841
        } else {
9842
          setSuccess((InventoryItem)value);
9843
        }
9844
        break;
9845
 
9846
      case WEX:
9847
        if (value == null) {
9848
          unsetWex();
9849
        } else {
9850
          setWex((WarehouseServiceException)value);
9851
        }
9852
        break;
9853
 
9854
      }
9855
    }
9856
 
9857
    public Object getFieldValue(_Fields field) {
9858
      switch (field) {
9859
      case SUCCESS:
9860
        return getSuccess();
9861
 
9862
      case WEX:
9863
        return getWex();
9864
 
9865
      }
9866
      throw new IllegalStateException();
9867
    }
9868
 
9869
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9870
    public boolean isSet(_Fields field) {
9871
      if (field == null) {
9872
        throw new IllegalArgumentException();
9873
      }
9874
 
9875
      switch (field) {
9876
      case SUCCESS:
9877
        return isSetSuccess();
9878
      case WEX:
9879
        return isSetWex();
9880
      }
9881
      throw new IllegalStateException();
9882
    }
9883
 
9884
    @Override
9885
    public boolean equals(Object that) {
9886
      if (that == null)
9887
        return false;
9888
      if (that instanceof getInventoryItemFromId_result)
9889
        return this.equals((getInventoryItemFromId_result)that);
9890
      return false;
9891
    }
9892
 
9893
    public boolean equals(getInventoryItemFromId_result that) {
9894
      if (that == null)
9895
        return false;
9896
 
9897
      boolean this_present_success = true && this.isSetSuccess();
9898
      boolean that_present_success = true && that.isSetSuccess();
9899
      if (this_present_success || that_present_success) {
9900
        if (!(this_present_success && that_present_success))
9901
          return false;
9902
        if (!this.success.equals(that.success))
9903
          return false;
9904
      }
9905
 
9906
      boolean this_present_wex = true && this.isSetWex();
9907
      boolean that_present_wex = true && that.isSetWex();
9908
      if (this_present_wex || that_present_wex) {
9909
        if (!(this_present_wex && that_present_wex))
9910
          return false;
9911
        if (!this.wex.equals(that.wex))
9912
          return false;
9913
      }
9914
 
9915
      return true;
9916
    }
9917
 
9918
    @Override
9919
    public int hashCode() {
9920
      return 0;
9921
    }
9922
 
9923
    public int compareTo(getInventoryItemFromId_result other) {
9924
      if (!getClass().equals(other.getClass())) {
9925
        return getClass().getName().compareTo(other.getClass().getName());
9926
      }
9927
 
9928
      int lastComparison = 0;
9929
      getInventoryItemFromId_result typedOther = (getInventoryItemFromId_result)other;
9930
 
9931
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
9932
      if (lastComparison != 0) {
9933
        return lastComparison;
9934
      }
9935
      if (isSetSuccess()) {
9936
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9937
        if (lastComparison != 0) {
9938
          return lastComparison;
9939
        }
9940
      }
9941
      lastComparison = Boolean.valueOf(isSetWex()).compareTo(typedOther.isSetWex());
9942
      if (lastComparison != 0) {
9943
        return lastComparison;
9944
      }
9945
      if (isSetWex()) {
9946
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.wex, typedOther.wex);
9947
        if (lastComparison != 0) {
9948
          return lastComparison;
9949
        }
9950
      }
9951
      return 0;
9952
    }
9953
 
9954
    public _Fields fieldForId(int fieldId) {
9955
      return _Fields.findByThriftId(fieldId);
9956
    }
9957
 
9958
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9959
      org.apache.thrift.protocol.TField field;
9960
      iprot.readStructBegin();
9961
      while (true)
9962
      {
9963
        field = iprot.readFieldBegin();
9964
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9965
          break;
9966
        }
9967
        switch (field.id) {
9968
          case 0: // SUCCESS
9969
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9970
              this.success = new InventoryItem();
9971
              this.success.read(iprot);
9972
            } else { 
9973
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9974
            }
9975
            break;
9976
          case 1: // WEX
9977
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9978
              this.wex = new WarehouseServiceException();
9979
              this.wex.read(iprot);
9980
            } else { 
9981
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9982
            }
9983
            break;
9984
          default:
9985
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9986
        }
9987
        iprot.readFieldEnd();
9988
      }
9989
      iprot.readStructEnd();
9990
      validate();
9991
    }
9992
 
9993
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9994
      oprot.writeStructBegin(STRUCT_DESC);
9995
 
9996
      if (this.isSetSuccess()) {
9997
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9998
        this.success.write(oprot);
9999
        oprot.writeFieldEnd();
10000
      } else if (this.isSetWex()) {
10001
        oprot.writeFieldBegin(WEX_FIELD_DESC);
10002
        this.wex.write(oprot);
10003
        oprot.writeFieldEnd();
10004
      }
10005
      oprot.writeFieldStop();
10006
      oprot.writeStructEnd();
10007
    }
10008
 
10009
    @Override
10010
    public String toString() {
10011
      StringBuilder sb = new StringBuilder("getInventoryItemFromId_result(");
10012
      boolean first = true;
10013
 
10014
      sb.append("success:");
10015
      if (this.success == null) {
10016
        sb.append("null");
10017
      } else {
10018
        sb.append(this.success);
10019
      }
10020
      first = false;
10021
      if (!first) sb.append(", ");
10022
      sb.append("wex:");
10023
      if (this.wex == null) {
10024
        sb.append("null");
10025
      } else {
10026
        sb.append(this.wex);
10027
      }
10028
      first = false;
10029
      sb.append(")");
10030
      return sb.toString();
10031
    }
10032
 
10033
    public void validate() throws org.apache.thrift.TException {
10034
      // check for required fields
10035
    }
10036
 
10037
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10038
      try {
10039
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10040
      } catch (org.apache.thrift.TException te) {
10041
        throw new java.io.IOException(te);
10042
      }
10043
    }
10044
 
10045
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10046
      try {
10047
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10048
      } catch (org.apache.thrift.TException te) {
10049
        throw new java.io.IOException(te);
10050
      }
10051
    }
10052
 
10053
  }
10054
 
5372 mandeep.dh 10055
  public static class getPurchaseScans_args implements org.apache.thrift.TBase<getPurchaseScans_args, getPurchaseScans_args._Fields>, java.io.Serializable, Cloneable   {
10056
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPurchaseScans_args");
10057
 
10058
    private static final org.apache.thrift.protocol.TField START_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("startDate", org.apache.thrift.protocol.TType.I64, (short)1);
10059
    private static final org.apache.thrift.protocol.TField END_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("endDate", org.apache.thrift.protocol.TType.I64, (short)2);
10060
 
10061
    private long startDate; // required
10062
    private long endDate; // required
10063
 
10064
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10065
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10066
      START_DATE((short)1, "startDate"),
10067
      END_DATE((short)2, "endDate");
10068
 
10069
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10070
 
10071
      static {
10072
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10073
          byName.put(field.getFieldName(), field);
10074
        }
10075
      }
10076
 
10077
      /**
10078
       * Find the _Fields constant that matches fieldId, or null if its not found.
10079
       */
10080
      public static _Fields findByThriftId(int fieldId) {
10081
        switch(fieldId) {
10082
          case 1: // START_DATE
10083
            return START_DATE;
10084
          case 2: // END_DATE
10085
            return END_DATE;
10086
          default:
10087
            return null;
10088
        }
10089
      }
10090
 
10091
      /**
10092
       * Find the _Fields constant that matches fieldId, throwing an exception
10093
       * if it is not found.
10094
       */
10095
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10096
        _Fields fields = findByThriftId(fieldId);
10097
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10098
        return fields;
10099
      }
10100
 
10101
      /**
10102
       * Find the _Fields constant that matches name, or null if its not found.
10103
       */
10104
      public static _Fields findByName(String name) {
10105
        return byName.get(name);
10106
      }
10107
 
10108
      private final short _thriftId;
10109
      private final String _fieldName;
10110
 
10111
      _Fields(short thriftId, String fieldName) {
10112
        _thriftId = thriftId;
10113
        _fieldName = fieldName;
10114
      }
10115
 
10116
      public short getThriftFieldId() {
10117
        return _thriftId;
10118
      }
10119
 
10120
      public String getFieldName() {
10121
        return _fieldName;
10122
      }
10123
    }
10124
 
10125
    // isset id assignments
10126
    private static final int __STARTDATE_ISSET_ID = 0;
10127
    private static final int __ENDDATE_ISSET_ID = 1;
10128
    private BitSet __isset_bit_vector = new BitSet(2);
10129
 
10130
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10131
    static {
10132
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10133
      tmpMap.put(_Fields.START_DATE, new org.apache.thrift.meta_data.FieldMetaData("startDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10134
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10135
      tmpMap.put(_Fields.END_DATE, new org.apache.thrift.meta_data.FieldMetaData("endDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10136
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10137
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10138
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPurchaseScans_args.class, metaDataMap);
10139
    }
10140
 
10141
    public getPurchaseScans_args() {
10142
    }
10143
 
10144
    public getPurchaseScans_args(
10145
      long startDate,
10146
      long endDate)
10147
    {
10148
      this();
10149
      this.startDate = startDate;
10150
      setStartDateIsSet(true);
10151
      this.endDate = endDate;
10152
      setEndDateIsSet(true);
10153
    }
10154
 
10155
    /**
10156
     * Performs a deep copy on <i>other</i>.
10157
     */
10158
    public getPurchaseScans_args(getPurchaseScans_args other) {
10159
      __isset_bit_vector.clear();
10160
      __isset_bit_vector.or(other.__isset_bit_vector);
10161
      this.startDate = other.startDate;
10162
      this.endDate = other.endDate;
10163
    }
10164
 
10165
    public getPurchaseScans_args deepCopy() {
10166
      return new getPurchaseScans_args(this);
10167
    }
10168
 
10169
    @Override
10170
    public void clear() {
10171
      setStartDateIsSet(false);
10172
      this.startDate = 0;
10173
      setEndDateIsSet(false);
10174
      this.endDate = 0;
10175
    }
10176
 
10177
    public long getStartDate() {
10178
      return this.startDate;
10179
    }
10180
 
10181
    public void setStartDate(long startDate) {
10182
      this.startDate = startDate;
10183
      setStartDateIsSet(true);
10184
    }
10185
 
10186
    public void unsetStartDate() {
10187
      __isset_bit_vector.clear(__STARTDATE_ISSET_ID);
10188
    }
10189
 
10190
    /** Returns true if field startDate is set (has been assigned a value) and false otherwise */
10191
    public boolean isSetStartDate() {
10192
      return __isset_bit_vector.get(__STARTDATE_ISSET_ID);
10193
    }
10194
 
10195
    public void setStartDateIsSet(boolean value) {
10196
      __isset_bit_vector.set(__STARTDATE_ISSET_ID, value);
10197
    }
10198
 
10199
    public long getEndDate() {
10200
      return this.endDate;
10201
    }
10202
 
10203
    public void setEndDate(long endDate) {
10204
      this.endDate = endDate;
10205
      setEndDateIsSet(true);
10206
    }
10207
 
10208
    public void unsetEndDate() {
10209
      __isset_bit_vector.clear(__ENDDATE_ISSET_ID);
10210
    }
10211
 
10212
    /** Returns true if field endDate is set (has been assigned a value) and false otherwise */
10213
    public boolean isSetEndDate() {
10214
      return __isset_bit_vector.get(__ENDDATE_ISSET_ID);
10215
    }
10216
 
10217
    public void setEndDateIsSet(boolean value) {
10218
      __isset_bit_vector.set(__ENDDATE_ISSET_ID, value);
10219
    }
10220
 
10221
    public void setFieldValue(_Fields field, Object value) {
10222
      switch (field) {
10223
      case START_DATE:
10224
        if (value == null) {
10225
          unsetStartDate();
10226
        } else {
10227
          setStartDate((Long)value);
10228
        }
10229
        break;
10230
 
10231
      case END_DATE:
10232
        if (value == null) {
10233
          unsetEndDate();
10234
        } else {
10235
          setEndDate((Long)value);
10236
        }
10237
        break;
10238
 
10239
      }
10240
    }
10241
 
10242
    public Object getFieldValue(_Fields field) {
10243
      switch (field) {
10244
      case START_DATE:
10245
        return Long.valueOf(getStartDate());
10246
 
10247
      case END_DATE:
10248
        return Long.valueOf(getEndDate());
10249
 
10250
      }
10251
      throw new IllegalStateException();
10252
    }
10253
 
10254
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10255
    public boolean isSet(_Fields field) {
10256
      if (field == null) {
10257
        throw new IllegalArgumentException();
10258
      }
10259
 
10260
      switch (field) {
10261
      case START_DATE:
10262
        return isSetStartDate();
10263
      case END_DATE:
10264
        return isSetEndDate();
10265
      }
10266
      throw new IllegalStateException();
10267
    }
10268
 
10269
    @Override
10270
    public boolean equals(Object that) {
10271
      if (that == null)
10272
        return false;
10273
      if (that instanceof getPurchaseScans_args)
10274
        return this.equals((getPurchaseScans_args)that);
10275
      return false;
10276
    }
10277
 
10278
    public boolean equals(getPurchaseScans_args that) {
10279
      if (that == null)
10280
        return false;
10281
 
10282
      boolean this_present_startDate = true;
10283
      boolean that_present_startDate = true;
10284
      if (this_present_startDate || that_present_startDate) {
10285
        if (!(this_present_startDate && that_present_startDate))
10286
          return false;
10287
        if (this.startDate != that.startDate)
10288
          return false;
10289
      }
10290
 
10291
      boolean this_present_endDate = true;
10292
      boolean that_present_endDate = true;
10293
      if (this_present_endDate || that_present_endDate) {
10294
        if (!(this_present_endDate && that_present_endDate))
10295
          return false;
10296
        if (this.endDate != that.endDate)
10297
          return false;
10298
      }
10299
 
10300
      return true;
10301
    }
10302
 
10303
    @Override
10304
    public int hashCode() {
10305
      return 0;
10306
    }
10307
 
10308
    public int compareTo(getPurchaseScans_args other) {
10309
      if (!getClass().equals(other.getClass())) {
10310
        return getClass().getName().compareTo(other.getClass().getName());
10311
      }
10312
 
10313
      int lastComparison = 0;
10314
      getPurchaseScans_args typedOther = (getPurchaseScans_args)other;
10315
 
10316
      lastComparison = Boolean.valueOf(isSetStartDate()).compareTo(typedOther.isSetStartDate());
10317
      if (lastComparison != 0) {
10318
        return lastComparison;
10319
      }
10320
      if (isSetStartDate()) {
10321
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.startDate, typedOther.startDate);
10322
        if (lastComparison != 0) {
10323
          return lastComparison;
10324
        }
10325
      }
10326
      lastComparison = Boolean.valueOf(isSetEndDate()).compareTo(typedOther.isSetEndDate());
10327
      if (lastComparison != 0) {
10328
        return lastComparison;
10329
      }
10330
      if (isSetEndDate()) {
10331
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.endDate, typedOther.endDate);
10332
        if (lastComparison != 0) {
10333
          return lastComparison;
10334
        }
10335
      }
10336
      return 0;
10337
    }
10338
 
10339
    public _Fields fieldForId(int fieldId) {
10340
      return _Fields.findByThriftId(fieldId);
10341
    }
10342
 
10343
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10344
      org.apache.thrift.protocol.TField field;
10345
      iprot.readStructBegin();
10346
      while (true)
10347
      {
10348
        field = iprot.readFieldBegin();
10349
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10350
          break;
10351
        }
10352
        switch (field.id) {
10353
          case 1: // START_DATE
10354
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10355
              this.startDate = iprot.readI64();
10356
              setStartDateIsSet(true);
10357
            } else { 
10358
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10359
            }
10360
            break;
10361
          case 2: // END_DATE
10362
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10363
              this.endDate = iprot.readI64();
10364
              setEndDateIsSet(true);
10365
            } else { 
10366
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10367
            }
10368
            break;
10369
          default:
10370
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10371
        }
10372
        iprot.readFieldEnd();
10373
      }
10374
      iprot.readStructEnd();
10375
      validate();
10376
    }
10377
 
10378
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10379
      validate();
10380
 
10381
      oprot.writeStructBegin(STRUCT_DESC);
10382
      oprot.writeFieldBegin(START_DATE_FIELD_DESC);
10383
      oprot.writeI64(this.startDate);
10384
      oprot.writeFieldEnd();
10385
      oprot.writeFieldBegin(END_DATE_FIELD_DESC);
10386
      oprot.writeI64(this.endDate);
10387
      oprot.writeFieldEnd();
10388
      oprot.writeFieldStop();
10389
      oprot.writeStructEnd();
10390
    }
10391
 
10392
    @Override
10393
    public String toString() {
10394
      StringBuilder sb = new StringBuilder("getPurchaseScans_args(");
10395
      boolean first = true;
10396
 
10397
      sb.append("startDate:");
10398
      sb.append(this.startDate);
10399
      first = false;
10400
      if (!first) sb.append(", ");
10401
      sb.append("endDate:");
10402
      sb.append(this.endDate);
10403
      first = false;
10404
      sb.append(")");
10405
      return sb.toString();
10406
    }
10407
 
10408
    public void validate() throws org.apache.thrift.TException {
10409
      // check for required fields
10410
    }
10411
 
10412
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10413
      try {
10414
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10415
      } catch (org.apache.thrift.TException te) {
10416
        throw new java.io.IOException(te);
10417
      }
10418
    }
10419
 
10420
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10421
      try {
10422
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
10423
        __isset_bit_vector = new BitSet(1);
10424
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10425
      } catch (org.apache.thrift.TException te) {
10426
        throw new java.io.IOException(te);
10427
      }
10428
    }
10429
 
10430
  }
10431
 
10432
  public static class getPurchaseScans_result implements org.apache.thrift.TBase<getPurchaseScans_result, getPurchaseScans_result._Fields>, java.io.Serializable, Cloneable   {
10433
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPurchaseScans_result");
10434
 
10435
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
10436
 
10437
    private List<DetailedPurchaseScan> success; // required
10438
 
10439
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10440
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10441
      SUCCESS((short)0, "success");
10442
 
10443
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10444
 
10445
      static {
10446
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10447
          byName.put(field.getFieldName(), field);
10448
        }
10449
      }
10450
 
10451
      /**
10452
       * Find the _Fields constant that matches fieldId, or null if its not found.
10453
       */
10454
      public static _Fields findByThriftId(int fieldId) {
10455
        switch(fieldId) {
10456
          case 0: // SUCCESS
10457
            return SUCCESS;
10458
          default:
10459
            return null;
10460
        }
10461
      }
10462
 
10463
      /**
10464
       * Find the _Fields constant that matches fieldId, throwing an exception
10465
       * if it is not found.
10466
       */
10467
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10468
        _Fields fields = findByThriftId(fieldId);
10469
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10470
        return fields;
10471
      }
10472
 
10473
      /**
10474
       * Find the _Fields constant that matches name, or null if its not found.
10475
       */
10476
      public static _Fields findByName(String name) {
10477
        return byName.get(name);
10478
      }
10479
 
10480
      private final short _thriftId;
10481
      private final String _fieldName;
10482
 
10483
      _Fields(short thriftId, String fieldName) {
10484
        _thriftId = thriftId;
10485
        _fieldName = fieldName;
10486
      }
10487
 
10488
      public short getThriftFieldId() {
10489
        return _thriftId;
10490
      }
10491
 
10492
      public String getFieldName() {
10493
        return _fieldName;
10494
      }
10495
    }
10496
 
10497
    // isset id assignments
10498
 
10499
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10500
    static {
10501
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10502
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10503
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
10504
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, DetailedPurchaseScan.class))));
10505
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10506
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPurchaseScans_result.class, metaDataMap);
10507
    }
10508
 
10509
    public getPurchaseScans_result() {
10510
    }
10511
 
10512
    public getPurchaseScans_result(
10513
      List<DetailedPurchaseScan> success)
10514
    {
10515
      this();
10516
      this.success = success;
10517
    }
10518
 
10519
    /**
10520
     * Performs a deep copy on <i>other</i>.
10521
     */
10522
    public getPurchaseScans_result(getPurchaseScans_result other) {
10523
      if (other.isSetSuccess()) {
10524
        List<DetailedPurchaseScan> __this__success = new ArrayList<DetailedPurchaseScan>();
10525
        for (DetailedPurchaseScan other_element : other.success) {
10526
          __this__success.add(new DetailedPurchaseScan(other_element));
10527
        }
10528
        this.success = __this__success;
10529
      }
10530
    }
10531
 
10532
    public getPurchaseScans_result deepCopy() {
10533
      return new getPurchaseScans_result(this);
10534
    }
10535
 
10536
    @Override
10537
    public void clear() {
10538
      this.success = null;
10539
    }
10540
 
10541
    public int getSuccessSize() {
10542
      return (this.success == null) ? 0 : this.success.size();
10543
    }
10544
 
10545
    public java.util.Iterator<DetailedPurchaseScan> getSuccessIterator() {
10546
      return (this.success == null) ? null : this.success.iterator();
10547
    }
10548
 
10549
    public void addToSuccess(DetailedPurchaseScan elem) {
10550
      if (this.success == null) {
10551
        this.success = new ArrayList<DetailedPurchaseScan>();
10552
      }
10553
      this.success.add(elem);
10554
    }
10555
 
10556
    public List<DetailedPurchaseScan> getSuccess() {
10557
      return this.success;
10558
    }
10559
 
10560
    public void setSuccess(List<DetailedPurchaseScan> success) {
10561
      this.success = success;
10562
    }
10563
 
10564
    public void unsetSuccess() {
10565
      this.success = null;
10566
    }
10567
 
10568
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
10569
    public boolean isSetSuccess() {
10570
      return this.success != null;
10571
    }
10572
 
10573
    public void setSuccessIsSet(boolean value) {
10574
      if (!value) {
10575
        this.success = null;
10576
      }
10577
    }
10578
 
10579
    public void setFieldValue(_Fields field, Object value) {
10580
      switch (field) {
10581
      case SUCCESS:
10582
        if (value == null) {
10583
          unsetSuccess();
10584
        } else {
10585
          setSuccess((List<DetailedPurchaseScan>)value);
10586
        }
10587
        break;
10588
 
10589
      }
10590
    }
10591
 
10592
    public Object getFieldValue(_Fields field) {
10593
      switch (field) {
10594
      case SUCCESS:
10595
        return getSuccess();
10596
 
10597
      }
10598
      throw new IllegalStateException();
10599
    }
10600
 
10601
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10602
    public boolean isSet(_Fields field) {
10603
      if (field == null) {
10604
        throw new IllegalArgumentException();
10605
      }
10606
 
10607
      switch (field) {
10608
      case SUCCESS:
10609
        return isSetSuccess();
10610
      }
10611
      throw new IllegalStateException();
10612
    }
10613
 
10614
    @Override
10615
    public boolean equals(Object that) {
10616
      if (that == null)
10617
        return false;
10618
      if (that instanceof getPurchaseScans_result)
10619
        return this.equals((getPurchaseScans_result)that);
10620
      return false;
10621
    }
10622
 
10623
    public boolean equals(getPurchaseScans_result that) {
10624
      if (that == null)
10625
        return false;
10626
 
10627
      boolean this_present_success = true && this.isSetSuccess();
10628
      boolean that_present_success = true && that.isSetSuccess();
10629
      if (this_present_success || that_present_success) {
10630
        if (!(this_present_success && that_present_success))
10631
          return false;
10632
        if (!this.success.equals(that.success))
10633
          return false;
10634
      }
10635
 
10636
      return true;
10637
    }
10638
 
10639
    @Override
10640
    public int hashCode() {
10641
      return 0;
10642
    }
10643
 
10644
    public int compareTo(getPurchaseScans_result other) {
10645
      if (!getClass().equals(other.getClass())) {
10646
        return getClass().getName().compareTo(other.getClass().getName());
10647
      }
10648
 
10649
      int lastComparison = 0;
10650
      getPurchaseScans_result typedOther = (getPurchaseScans_result)other;
10651
 
10652
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10653
      if (lastComparison != 0) {
10654
        return lastComparison;
10655
      }
10656
      if (isSetSuccess()) {
10657
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10658
        if (lastComparison != 0) {
10659
          return lastComparison;
10660
        }
10661
      }
10662
      return 0;
10663
    }
10664
 
10665
    public _Fields fieldForId(int fieldId) {
10666
      return _Fields.findByThriftId(fieldId);
10667
    }
10668
 
10669
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10670
      org.apache.thrift.protocol.TField field;
10671
      iprot.readStructBegin();
10672
      while (true)
10673
      {
10674
        field = iprot.readFieldBegin();
10675
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10676
          break;
10677
        }
10678
        switch (field.id) {
10679
          case 0: // SUCCESS
10680
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
10681
              {
10682
                org.apache.thrift.protocol.TList _list12 = iprot.readListBegin();
10683
                this.success = new ArrayList<DetailedPurchaseScan>(_list12.size);
10684
                for (int _i13 = 0; _i13 < _list12.size; ++_i13)
10685
                {
10686
                  DetailedPurchaseScan _elem14; // required
10687
                  _elem14 = new DetailedPurchaseScan();
10688
                  _elem14.read(iprot);
10689
                  this.success.add(_elem14);
10690
                }
10691
                iprot.readListEnd();
10692
              }
10693
            } else { 
10694
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10695
            }
10696
            break;
10697
          default:
10698
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10699
        }
10700
        iprot.readFieldEnd();
10701
      }
10702
      iprot.readStructEnd();
10703
      validate();
10704
    }
10705
 
10706
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10707
      oprot.writeStructBegin(STRUCT_DESC);
10708
 
10709
      if (this.isSetSuccess()) {
10710
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10711
        {
10712
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
10713
          for (DetailedPurchaseScan _iter15 : this.success)
10714
          {
10715
            _iter15.write(oprot);
10716
          }
10717
          oprot.writeListEnd();
10718
        }
10719
        oprot.writeFieldEnd();
10720
      }
10721
      oprot.writeFieldStop();
10722
      oprot.writeStructEnd();
10723
    }
10724
 
10725
    @Override
10726
    public String toString() {
10727
      StringBuilder sb = new StringBuilder("getPurchaseScans_result(");
10728
      boolean first = true;
10729
 
10730
      sb.append("success:");
10731
      if (this.success == null) {
10732
        sb.append("null");
10733
      } else {
10734
        sb.append(this.success);
10735
      }
10736
      first = false;
10737
      sb.append(")");
10738
      return sb.toString();
10739
    }
10740
 
10741
    public void validate() throws org.apache.thrift.TException {
10742
      // check for required fields
10743
    }
10744
 
10745
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10746
      try {
10747
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10748
      } catch (org.apache.thrift.TException te) {
10749
        throw new java.io.IOException(te);
10750
      }
10751
    }
10752
 
10753
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10754
      try {
10755
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10756
      } catch (org.apache.thrift.TException te) {
10757
        throw new java.io.IOException(te);
10758
      }
10759
    }
10760
 
10761
  }
10762
 
5496 mandeep.dh 10763
  public static class fetchScansPerInvoiceNumber_args implements org.apache.thrift.TBase<fetchScansPerInvoiceNumber_args, fetchScansPerInvoiceNumber_args._Fields>, java.io.Serializable, Cloneable   {
10764
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("fetchScansPerInvoiceNumber_args");
10765
 
10766
    private static final org.apache.thrift.protocol.TField DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("date", org.apache.thrift.protocol.TType.I64, (short)1);
10767
 
10768
    private long date; // required
10769
 
10770
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10771
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10772
      DATE((short)1, "date");
10773
 
10774
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10775
 
10776
      static {
10777
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10778
          byName.put(field.getFieldName(), field);
10779
        }
10780
      }
10781
 
10782
      /**
10783
       * Find the _Fields constant that matches fieldId, or null if its not found.
10784
       */
10785
      public static _Fields findByThriftId(int fieldId) {
10786
        switch(fieldId) {
10787
          case 1: // DATE
10788
            return DATE;
10789
          default:
10790
            return null;
10791
        }
10792
      }
10793
 
10794
      /**
10795
       * Find the _Fields constant that matches fieldId, throwing an exception
10796
       * if it is not found.
10797
       */
10798
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10799
        _Fields fields = findByThriftId(fieldId);
10800
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10801
        return fields;
10802
      }
10803
 
10804
      /**
10805
       * Find the _Fields constant that matches name, or null if its not found.
10806
       */
10807
      public static _Fields findByName(String name) {
10808
        return byName.get(name);
10809
      }
10810
 
10811
      private final short _thriftId;
10812
      private final String _fieldName;
10813
 
10814
      _Fields(short thriftId, String fieldName) {
10815
        _thriftId = thriftId;
10816
        _fieldName = fieldName;
10817
      }
10818
 
10819
      public short getThriftFieldId() {
10820
        return _thriftId;
10821
      }
10822
 
10823
      public String getFieldName() {
10824
        return _fieldName;
10825
      }
10826
    }
10827
 
10828
    // isset id assignments
10829
    private static final int __DATE_ISSET_ID = 0;
10830
    private BitSet __isset_bit_vector = new BitSet(1);
10831
 
10832
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10833
    static {
10834
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10835
      tmpMap.put(_Fields.DATE, new org.apache.thrift.meta_data.FieldMetaData("date", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10836
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10837
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10838
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(fetchScansPerInvoiceNumber_args.class, metaDataMap);
10839
    }
10840
 
10841
    public fetchScansPerInvoiceNumber_args() {
10842
    }
10843
 
10844
    public fetchScansPerInvoiceNumber_args(
10845
      long date)
10846
    {
10847
      this();
10848
      this.date = date;
10849
      setDateIsSet(true);
10850
    }
10851
 
10852
    /**
10853
     * Performs a deep copy on <i>other</i>.
10854
     */
10855
    public fetchScansPerInvoiceNumber_args(fetchScansPerInvoiceNumber_args other) {
10856
      __isset_bit_vector.clear();
10857
      __isset_bit_vector.or(other.__isset_bit_vector);
10858
      this.date = other.date;
10859
    }
10860
 
10861
    public fetchScansPerInvoiceNumber_args deepCopy() {
10862
      return new fetchScansPerInvoiceNumber_args(this);
10863
    }
10864
 
10865
    @Override
10866
    public void clear() {
10867
      setDateIsSet(false);
10868
      this.date = 0;
10869
    }
10870
 
10871
    public long getDate() {
10872
      return this.date;
10873
    }
10874
 
10875
    public void setDate(long date) {
10876
      this.date = date;
10877
      setDateIsSet(true);
10878
    }
10879
 
10880
    public void unsetDate() {
10881
      __isset_bit_vector.clear(__DATE_ISSET_ID);
10882
    }
10883
 
10884
    /** Returns true if field date is set (has been assigned a value) and false otherwise */
10885
    public boolean isSetDate() {
10886
      return __isset_bit_vector.get(__DATE_ISSET_ID);
10887
    }
10888
 
10889
    public void setDateIsSet(boolean value) {
10890
      __isset_bit_vector.set(__DATE_ISSET_ID, value);
10891
    }
10892
 
10893
    public void setFieldValue(_Fields field, Object value) {
10894
      switch (field) {
10895
      case DATE:
10896
        if (value == null) {
10897
          unsetDate();
10898
        } else {
10899
          setDate((Long)value);
10900
        }
10901
        break;
10902
 
10903
      }
10904
    }
10905
 
10906
    public Object getFieldValue(_Fields field) {
10907
      switch (field) {
10908
      case DATE:
10909
        return Long.valueOf(getDate());
10910
 
10911
      }
10912
      throw new IllegalStateException();
10913
    }
10914
 
10915
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10916
    public boolean isSet(_Fields field) {
10917
      if (field == null) {
10918
        throw new IllegalArgumentException();
10919
      }
10920
 
10921
      switch (field) {
10922
      case DATE:
10923
        return isSetDate();
10924
      }
10925
      throw new IllegalStateException();
10926
    }
10927
 
10928
    @Override
10929
    public boolean equals(Object that) {
10930
      if (that == null)
10931
        return false;
10932
      if (that instanceof fetchScansPerInvoiceNumber_args)
10933
        return this.equals((fetchScansPerInvoiceNumber_args)that);
10934
      return false;
10935
    }
10936
 
10937
    public boolean equals(fetchScansPerInvoiceNumber_args that) {
10938
      if (that == null)
10939
        return false;
10940
 
10941
      boolean this_present_date = true;
10942
      boolean that_present_date = true;
10943
      if (this_present_date || that_present_date) {
10944
        if (!(this_present_date && that_present_date))
10945
          return false;
10946
        if (this.date != that.date)
10947
          return false;
10948
      }
10949
 
10950
      return true;
10951
    }
10952
 
10953
    @Override
10954
    public int hashCode() {
10955
      return 0;
10956
    }
10957
 
10958
    public int compareTo(fetchScansPerInvoiceNumber_args other) {
10959
      if (!getClass().equals(other.getClass())) {
10960
        return getClass().getName().compareTo(other.getClass().getName());
10961
      }
10962
 
10963
      int lastComparison = 0;
10964
      fetchScansPerInvoiceNumber_args typedOther = (fetchScansPerInvoiceNumber_args)other;
10965
 
10966
      lastComparison = Boolean.valueOf(isSetDate()).compareTo(typedOther.isSetDate());
10967
      if (lastComparison != 0) {
10968
        return lastComparison;
10969
      }
10970
      if (isSetDate()) {
10971
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.date, typedOther.date);
10972
        if (lastComparison != 0) {
10973
          return lastComparison;
10974
        }
10975
      }
10976
      return 0;
10977
    }
10978
 
10979
    public _Fields fieldForId(int fieldId) {
10980
      return _Fields.findByThriftId(fieldId);
10981
    }
10982
 
10983
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10984
      org.apache.thrift.protocol.TField field;
10985
      iprot.readStructBegin();
10986
      while (true)
10987
      {
10988
        field = iprot.readFieldBegin();
10989
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10990
          break;
10991
        }
10992
        switch (field.id) {
10993
          case 1: // DATE
10994
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10995
              this.date = iprot.readI64();
10996
              setDateIsSet(true);
10997
            } else { 
10998
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10999
            }
11000
            break;
11001
          default:
11002
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11003
        }
11004
        iprot.readFieldEnd();
11005
      }
11006
      iprot.readStructEnd();
11007
      validate();
11008
    }
11009
 
11010
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11011
      validate();
11012
 
11013
      oprot.writeStructBegin(STRUCT_DESC);
11014
      oprot.writeFieldBegin(DATE_FIELD_DESC);
11015
      oprot.writeI64(this.date);
11016
      oprot.writeFieldEnd();
11017
      oprot.writeFieldStop();
11018
      oprot.writeStructEnd();
11019
    }
11020
 
11021
    @Override
11022
    public String toString() {
11023
      StringBuilder sb = new StringBuilder("fetchScansPerInvoiceNumber_args(");
11024
      boolean first = true;
11025
 
11026
      sb.append("date:");
11027
      sb.append(this.date);
11028
      first = false;
11029
      sb.append(")");
11030
      return sb.toString();
11031
    }
11032
 
11033
    public void validate() throws org.apache.thrift.TException {
11034
      // check for required fields
11035
    }
11036
 
11037
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11038
      try {
11039
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11040
      } catch (org.apache.thrift.TException te) {
11041
        throw new java.io.IOException(te);
11042
      }
11043
    }
11044
 
11045
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11046
      try {
5711 mandeep.dh 11047
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
11048
        __isset_bit_vector = new BitSet(1);
5496 mandeep.dh 11049
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11050
      } catch (org.apache.thrift.TException te) {
11051
        throw new java.io.IOException(te);
11052
      }
11053
    }
11054
 
11055
  }
11056
 
11057
  public static class fetchScansPerInvoiceNumber_result implements org.apache.thrift.TBase<fetchScansPerInvoiceNumber_result, fetchScansPerInvoiceNumber_result._Fields>, java.io.Serializable, Cloneable   {
11058
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("fetchScansPerInvoiceNumber_result");
11059
 
11060
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
11061
 
11062
    private List<InvoiceScan> success; // required
11063
 
11064
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11065
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11066
      SUCCESS((short)0, "success");
11067
 
11068
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11069
 
11070
      static {
11071
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11072
          byName.put(field.getFieldName(), field);
11073
        }
11074
      }
11075
 
11076
      /**
11077
       * Find the _Fields constant that matches fieldId, or null if its not found.
11078
       */
11079
      public static _Fields findByThriftId(int fieldId) {
11080
        switch(fieldId) {
11081
          case 0: // SUCCESS
11082
            return SUCCESS;
11083
          default:
11084
            return null;
11085
        }
11086
      }
11087
 
11088
      /**
11089
       * Find the _Fields constant that matches fieldId, throwing an exception
11090
       * if it is not found.
11091
       */
11092
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11093
        _Fields fields = findByThriftId(fieldId);
11094
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11095
        return fields;
11096
      }
11097
 
11098
      /**
11099
       * Find the _Fields constant that matches name, or null if its not found.
11100
       */
11101
      public static _Fields findByName(String name) {
11102
        return byName.get(name);
11103
      }
11104
 
11105
      private final short _thriftId;
11106
      private final String _fieldName;
11107
 
11108
      _Fields(short thriftId, String fieldName) {
11109
        _thriftId = thriftId;
11110
        _fieldName = fieldName;
11111
      }
11112
 
11113
      public short getThriftFieldId() {
11114
        return _thriftId;
11115
      }
11116
 
11117
      public String getFieldName() {
11118
        return _fieldName;
11119
      }
11120
    }
11121
 
11122
    // isset id assignments
11123
 
11124
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11125
    static {
11126
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11127
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11128
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
11129
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InvoiceScan.class))));
11130
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11131
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(fetchScansPerInvoiceNumber_result.class, metaDataMap);
11132
    }
11133
 
11134
    public fetchScansPerInvoiceNumber_result() {
11135
    }
11136
 
11137
    public fetchScansPerInvoiceNumber_result(
11138
      List<InvoiceScan> success)
11139
    {
11140
      this();
11141
      this.success = success;
11142
    }
11143
 
11144
    /**
11145
     * Performs a deep copy on <i>other</i>.
11146
     */
11147
    public fetchScansPerInvoiceNumber_result(fetchScansPerInvoiceNumber_result other) {
11148
      if (other.isSetSuccess()) {
11149
        List<InvoiceScan> __this__success = new ArrayList<InvoiceScan>();
11150
        for (InvoiceScan other_element : other.success) {
11151
          __this__success.add(new InvoiceScan(other_element));
11152
        }
11153
        this.success = __this__success;
11154
      }
11155
    }
11156
 
11157
    public fetchScansPerInvoiceNumber_result deepCopy() {
11158
      return new fetchScansPerInvoiceNumber_result(this);
11159
    }
11160
 
11161
    @Override
11162
    public void clear() {
11163
      this.success = null;
11164
    }
11165
 
11166
    public int getSuccessSize() {
11167
      return (this.success == null) ? 0 : this.success.size();
11168
    }
11169
 
11170
    public java.util.Iterator<InvoiceScan> getSuccessIterator() {
11171
      return (this.success == null) ? null : this.success.iterator();
11172
    }
11173
 
11174
    public void addToSuccess(InvoiceScan elem) {
11175
      if (this.success == null) {
11176
        this.success = new ArrayList<InvoiceScan>();
11177
      }
11178
      this.success.add(elem);
11179
    }
11180
 
11181
    public List<InvoiceScan> getSuccess() {
11182
      return this.success;
11183
    }
11184
 
11185
    public void setSuccess(List<InvoiceScan> success) {
11186
      this.success = success;
11187
    }
11188
 
11189
    public void unsetSuccess() {
11190
      this.success = null;
11191
    }
11192
 
11193
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
11194
    public boolean isSetSuccess() {
11195
      return this.success != null;
11196
    }
11197
 
11198
    public void setSuccessIsSet(boolean value) {
11199
      if (!value) {
11200
        this.success = null;
11201
      }
11202
    }
11203
 
11204
    public void setFieldValue(_Fields field, Object value) {
11205
      switch (field) {
11206
      case SUCCESS:
11207
        if (value == null) {
11208
          unsetSuccess();
11209
        } else {
11210
          setSuccess((List<InvoiceScan>)value);
11211
        }
11212
        break;
11213
 
11214
      }
11215
    }
11216
 
11217
    public Object getFieldValue(_Fields field) {
11218
      switch (field) {
11219
      case SUCCESS:
11220
        return getSuccess();
11221
 
11222
      }
11223
      throw new IllegalStateException();
11224
    }
11225
 
11226
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11227
    public boolean isSet(_Fields field) {
11228
      if (field == null) {
11229
        throw new IllegalArgumentException();
11230
      }
11231
 
11232
      switch (field) {
11233
      case SUCCESS:
11234
        return isSetSuccess();
11235
      }
11236
      throw new IllegalStateException();
11237
    }
11238
 
11239
    @Override
11240
    public boolean equals(Object that) {
11241
      if (that == null)
11242
        return false;
11243
      if (that instanceof fetchScansPerInvoiceNumber_result)
11244
        return this.equals((fetchScansPerInvoiceNumber_result)that);
11245
      return false;
11246
    }
11247
 
11248
    public boolean equals(fetchScansPerInvoiceNumber_result that) {
11249
      if (that == null)
11250
        return false;
11251
 
11252
      boolean this_present_success = true && this.isSetSuccess();
11253
      boolean that_present_success = true && that.isSetSuccess();
11254
      if (this_present_success || that_present_success) {
11255
        if (!(this_present_success && that_present_success))
11256
          return false;
11257
        if (!this.success.equals(that.success))
11258
          return false;
11259
      }
11260
 
11261
      return true;
11262
    }
11263
 
11264
    @Override
11265
    public int hashCode() {
11266
      return 0;
11267
    }
11268
 
11269
    public int compareTo(fetchScansPerInvoiceNumber_result other) {
11270
      if (!getClass().equals(other.getClass())) {
11271
        return getClass().getName().compareTo(other.getClass().getName());
11272
      }
11273
 
11274
      int lastComparison = 0;
11275
      fetchScansPerInvoiceNumber_result typedOther = (fetchScansPerInvoiceNumber_result)other;
11276
 
11277
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
11278
      if (lastComparison != 0) {
11279
        return lastComparison;
11280
      }
11281
      if (isSetSuccess()) {
11282
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11283
        if (lastComparison != 0) {
11284
          return lastComparison;
11285
        }
11286
      }
11287
      return 0;
11288
    }
11289
 
11290
    public _Fields fieldForId(int fieldId) {
11291
      return _Fields.findByThriftId(fieldId);
11292
    }
11293
 
11294
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11295
      org.apache.thrift.protocol.TField field;
11296
      iprot.readStructBegin();
11297
      while (true)
11298
      {
11299
        field = iprot.readFieldBegin();
11300
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11301
          break;
11302
        }
11303
        switch (field.id) {
11304
          case 0: // SUCCESS
11305
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
11306
              {
11307
                org.apache.thrift.protocol.TList _list16 = iprot.readListBegin();
11308
                this.success = new ArrayList<InvoiceScan>(_list16.size);
11309
                for (int _i17 = 0; _i17 < _list16.size; ++_i17)
11310
                {
11311
                  InvoiceScan _elem18; // required
11312
                  _elem18 = new InvoiceScan();
11313
                  _elem18.read(iprot);
11314
                  this.success.add(_elem18);
11315
                }
11316
                iprot.readListEnd();
11317
              }
11318
            } else { 
11319
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11320
            }
11321
            break;
11322
          default:
11323
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11324
        }
11325
        iprot.readFieldEnd();
11326
      }
11327
      iprot.readStructEnd();
11328
      validate();
11329
    }
11330
 
11331
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11332
      oprot.writeStructBegin(STRUCT_DESC);
11333
 
11334
      if (this.isSetSuccess()) {
11335
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11336
        {
11337
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
11338
          for (InvoiceScan _iter19 : this.success)
11339
          {
11340
            _iter19.write(oprot);
11341
          }
11342
          oprot.writeListEnd();
11343
        }
11344
        oprot.writeFieldEnd();
11345
      }
11346
      oprot.writeFieldStop();
11347
      oprot.writeStructEnd();
11348
    }
11349
 
11350
    @Override
11351
    public String toString() {
11352
      StringBuilder sb = new StringBuilder("fetchScansPerInvoiceNumber_result(");
11353
      boolean first = true;
11354
 
11355
      sb.append("success:");
11356
      if (this.success == null) {
11357
        sb.append("null");
11358
      } else {
11359
        sb.append(this.success);
11360
      }
11361
      first = false;
11362
      sb.append(")");
11363
      return sb.toString();
11364
    }
11365
 
11366
    public void validate() throws org.apache.thrift.TException {
11367
      // check for required fields
11368
    }
11369
 
11370
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11371
      try {
11372
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11373
      } catch (org.apache.thrift.TException te) {
11374
        throw new java.io.IOException(te);
11375
      }
11376
    }
11377
 
11378
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11379
      try {
11380
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11381
      } catch (org.apache.thrift.TException te) {
11382
        throw new java.io.IOException(te);
11383
      }
11384
    }
11385
 
11386
  }
11387
 
5620 mandeep.dh 11388
  public static class getInventoryItemFromOrder_args implements org.apache.thrift.TBase<getInventoryItemFromOrder_args, getInventoryItemFromOrder_args._Fields>, java.io.Serializable, Cloneable   {
11389
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryItemFromOrder_args");
11390
 
11391
    private static final org.apache.thrift.protocol.TField ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("orderId", org.apache.thrift.protocol.TType.I64, (short)1);
11392
 
11393
    private long orderId; // required
11394
 
11395
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11396
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11397
      ORDER_ID((short)1, "orderId");
11398
 
11399
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11400
 
11401
      static {
11402
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11403
          byName.put(field.getFieldName(), field);
11404
        }
11405
      }
11406
 
11407
      /**
11408
       * Find the _Fields constant that matches fieldId, or null if its not found.
11409
       */
11410
      public static _Fields findByThriftId(int fieldId) {
11411
        switch(fieldId) {
11412
          case 1: // ORDER_ID
11413
            return ORDER_ID;
11414
          default:
11415
            return null;
11416
        }
11417
      }
11418
 
11419
      /**
11420
       * Find the _Fields constant that matches fieldId, throwing an exception
11421
       * if it is not found.
11422
       */
11423
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11424
        _Fields fields = findByThriftId(fieldId);
11425
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11426
        return fields;
11427
      }
11428
 
11429
      /**
11430
       * Find the _Fields constant that matches name, or null if its not found.
11431
       */
11432
      public static _Fields findByName(String name) {
11433
        return byName.get(name);
11434
      }
11435
 
11436
      private final short _thriftId;
11437
      private final String _fieldName;
11438
 
11439
      _Fields(short thriftId, String fieldName) {
11440
        _thriftId = thriftId;
11441
        _fieldName = fieldName;
11442
      }
11443
 
11444
      public short getThriftFieldId() {
11445
        return _thriftId;
11446
      }
11447
 
11448
      public String getFieldName() {
11449
        return _fieldName;
11450
      }
11451
    }
11452
 
11453
    // isset id assignments
11454
    private static final int __ORDERID_ISSET_ID = 0;
11455
    private BitSet __isset_bit_vector = new BitSet(1);
11456
 
11457
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11458
    static {
11459
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11460
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11461
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11462
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11463
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryItemFromOrder_args.class, metaDataMap);
11464
    }
11465
 
11466
    public getInventoryItemFromOrder_args() {
11467
    }
11468
 
11469
    public getInventoryItemFromOrder_args(
11470
      long orderId)
11471
    {
11472
      this();
11473
      this.orderId = orderId;
11474
      setOrderIdIsSet(true);
11475
    }
11476
 
11477
    /**
11478
     * Performs a deep copy on <i>other</i>.
11479
     */
11480
    public getInventoryItemFromOrder_args(getInventoryItemFromOrder_args other) {
11481
      __isset_bit_vector.clear();
11482
      __isset_bit_vector.or(other.__isset_bit_vector);
11483
      this.orderId = other.orderId;
11484
    }
11485
 
11486
    public getInventoryItemFromOrder_args deepCopy() {
11487
      return new getInventoryItemFromOrder_args(this);
11488
    }
11489
 
11490
    @Override
11491
    public void clear() {
11492
      setOrderIdIsSet(false);
11493
      this.orderId = 0;
11494
    }
11495
 
11496
    public long getOrderId() {
11497
      return this.orderId;
11498
    }
11499
 
11500
    public void setOrderId(long orderId) {
11501
      this.orderId = orderId;
11502
      setOrderIdIsSet(true);
11503
    }
11504
 
11505
    public void unsetOrderId() {
11506
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
11507
    }
11508
 
11509
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
11510
    public boolean isSetOrderId() {
11511
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
11512
    }
11513
 
11514
    public void setOrderIdIsSet(boolean value) {
11515
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
11516
    }
11517
 
11518
    public void setFieldValue(_Fields field, Object value) {
11519
      switch (field) {
11520
      case ORDER_ID:
11521
        if (value == null) {
11522
          unsetOrderId();
11523
        } else {
11524
          setOrderId((Long)value);
11525
        }
11526
        break;
11527
 
11528
      }
11529
    }
11530
 
11531
    public Object getFieldValue(_Fields field) {
11532
      switch (field) {
11533
      case ORDER_ID:
11534
        return Long.valueOf(getOrderId());
11535
 
11536
      }
11537
      throw new IllegalStateException();
11538
    }
11539
 
11540
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11541
    public boolean isSet(_Fields field) {
11542
      if (field == null) {
11543
        throw new IllegalArgumentException();
11544
      }
11545
 
11546
      switch (field) {
11547
      case ORDER_ID:
11548
        return isSetOrderId();
11549
      }
11550
      throw new IllegalStateException();
11551
    }
11552
 
11553
    @Override
11554
    public boolean equals(Object that) {
11555
      if (that == null)
11556
        return false;
11557
      if (that instanceof getInventoryItemFromOrder_args)
11558
        return this.equals((getInventoryItemFromOrder_args)that);
11559
      return false;
11560
    }
11561
 
11562
    public boolean equals(getInventoryItemFromOrder_args that) {
11563
      if (that == null)
11564
        return false;
11565
 
11566
      boolean this_present_orderId = true;
11567
      boolean that_present_orderId = true;
11568
      if (this_present_orderId || that_present_orderId) {
11569
        if (!(this_present_orderId && that_present_orderId))
11570
          return false;
11571
        if (this.orderId != that.orderId)
11572
          return false;
11573
      }
11574
 
11575
      return true;
11576
    }
11577
 
11578
    @Override
11579
    public int hashCode() {
11580
      return 0;
11581
    }
11582
 
11583
    public int compareTo(getInventoryItemFromOrder_args other) {
11584
      if (!getClass().equals(other.getClass())) {
11585
        return getClass().getName().compareTo(other.getClass().getName());
11586
      }
11587
 
11588
      int lastComparison = 0;
11589
      getInventoryItemFromOrder_args typedOther = (getInventoryItemFromOrder_args)other;
11590
 
11591
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
11592
      if (lastComparison != 0) {
11593
        return lastComparison;
11594
      }
11595
      if (isSetOrderId()) {
11596
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
11597
        if (lastComparison != 0) {
11598
          return lastComparison;
11599
        }
11600
      }
11601
      return 0;
11602
    }
11603
 
11604
    public _Fields fieldForId(int fieldId) {
11605
      return _Fields.findByThriftId(fieldId);
11606
    }
11607
 
11608
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11609
      org.apache.thrift.protocol.TField field;
11610
      iprot.readStructBegin();
11611
      while (true)
11612
      {
11613
        field = iprot.readFieldBegin();
11614
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11615
          break;
11616
        }
11617
        switch (field.id) {
11618
          case 1: // ORDER_ID
11619
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11620
              this.orderId = iprot.readI64();
11621
              setOrderIdIsSet(true);
11622
            } else { 
11623
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11624
            }
11625
            break;
11626
          default:
11627
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11628
        }
11629
        iprot.readFieldEnd();
11630
      }
11631
      iprot.readStructEnd();
11632
      validate();
11633
    }
11634
 
11635
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11636
      validate();
11637
 
11638
      oprot.writeStructBegin(STRUCT_DESC);
11639
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
11640
      oprot.writeI64(this.orderId);
11641
      oprot.writeFieldEnd();
11642
      oprot.writeFieldStop();
11643
      oprot.writeStructEnd();
11644
    }
11645
 
11646
    @Override
11647
    public String toString() {
11648
      StringBuilder sb = new StringBuilder("getInventoryItemFromOrder_args(");
11649
      boolean first = true;
11650
 
11651
      sb.append("orderId:");
11652
      sb.append(this.orderId);
11653
      first = false;
11654
      sb.append(")");
11655
      return sb.toString();
11656
    }
11657
 
11658
    public void validate() throws org.apache.thrift.TException {
11659
      // check for required fields
11660
    }
11661
 
11662
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11663
      try {
11664
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11665
      } catch (org.apache.thrift.TException te) {
11666
        throw new java.io.IOException(te);
11667
      }
11668
    }
11669
 
11670
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11671
      try {
11672
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
11673
        __isset_bit_vector = new BitSet(1);
11674
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11675
      } catch (org.apache.thrift.TException te) {
11676
        throw new java.io.IOException(te);
11677
      }
11678
    }
11679
 
11680
  }
11681
 
11682
  public static class getInventoryItemFromOrder_result implements org.apache.thrift.TBase<getInventoryItemFromOrder_result, getInventoryItemFromOrder_result._Fields>, java.io.Serializable, Cloneable   {
11683
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryItemFromOrder_result");
11684
 
11685
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
11686
    private static final org.apache.thrift.protocol.TField WE_FIELD_DESC = new org.apache.thrift.protocol.TField("we", org.apache.thrift.protocol.TType.STRUCT, (short)1);
11687
 
11688
    private InventoryItem success; // required
11689
    private WarehouseServiceException we; // required
11690
 
11691
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11692
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11693
      SUCCESS((short)0, "success"),
11694
      WE((short)1, "we");
11695
 
11696
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11697
 
11698
      static {
11699
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11700
          byName.put(field.getFieldName(), field);
11701
        }
11702
      }
11703
 
11704
      /**
11705
       * Find the _Fields constant that matches fieldId, or null if its not found.
11706
       */
11707
      public static _Fields findByThriftId(int fieldId) {
11708
        switch(fieldId) {
11709
          case 0: // SUCCESS
11710
            return SUCCESS;
11711
          case 1: // WE
11712
            return WE;
11713
          default:
11714
            return null;
11715
        }
11716
      }
11717
 
11718
      /**
11719
       * Find the _Fields constant that matches fieldId, throwing an exception
11720
       * if it is not found.
11721
       */
11722
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11723
        _Fields fields = findByThriftId(fieldId);
11724
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11725
        return fields;
11726
      }
11727
 
11728
      /**
11729
       * Find the _Fields constant that matches name, or null if its not found.
11730
       */
11731
      public static _Fields findByName(String name) {
11732
        return byName.get(name);
11733
      }
11734
 
11735
      private final short _thriftId;
11736
      private final String _fieldName;
11737
 
11738
      _Fields(short thriftId, String fieldName) {
11739
        _thriftId = thriftId;
11740
        _fieldName = fieldName;
11741
      }
11742
 
11743
      public short getThriftFieldId() {
11744
        return _thriftId;
11745
      }
11746
 
11747
      public String getFieldName() {
11748
        return _fieldName;
11749
      }
11750
    }
11751
 
11752
    // isset id assignments
11753
 
11754
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11755
    static {
11756
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11757
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11758
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class)));
11759
      tmpMap.put(_Fields.WE, new org.apache.thrift.meta_data.FieldMetaData("we", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11760
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
11761
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11762
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryItemFromOrder_result.class, metaDataMap);
11763
    }
11764
 
11765
    public getInventoryItemFromOrder_result() {
11766
    }
11767
 
11768
    public getInventoryItemFromOrder_result(
11769
      InventoryItem success,
11770
      WarehouseServiceException we)
11771
    {
11772
      this();
11773
      this.success = success;
11774
      this.we = we;
11775
    }
11776
 
11777
    /**
11778
     * Performs a deep copy on <i>other</i>.
11779
     */
11780
    public getInventoryItemFromOrder_result(getInventoryItemFromOrder_result other) {
11781
      if (other.isSetSuccess()) {
11782
        this.success = new InventoryItem(other.success);
11783
      }
11784
      if (other.isSetWe()) {
11785
        this.we = new WarehouseServiceException(other.we);
11786
      }
11787
    }
11788
 
11789
    public getInventoryItemFromOrder_result deepCopy() {
11790
      return new getInventoryItemFromOrder_result(this);
11791
    }
11792
 
11793
    @Override
11794
    public void clear() {
11795
      this.success = null;
11796
      this.we = null;
11797
    }
11798
 
11799
    public InventoryItem getSuccess() {
11800
      return this.success;
11801
    }
11802
 
11803
    public void setSuccess(InventoryItem success) {
11804
      this.success = success;
11805
    }
11806
 
11807
    public void unsetSuccess() {
11808
      this.success = null;
11809
    }
11810
 
11811
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
11812
    public boolean isSetSuccess() {
11813
      return this.success != null;
11814
    }
11815
 
11816
    public void setSuccessIsSet(boolean value) {
11817
      if (!value) {
11818
        this.success = null;
11819
      }
11820
    }
11821
 
11822
    public WarehouseServiceException getWe() {
11823
      return this.we;
11824
    }
11825
 
11826
    public void setWe(WarehouseServiceException we) {
11827
      this.we = we;
11828
    }
11829
 
11830
    public void unsetWe() {
11831
      this.we = null;
11832
    }
11833
 
11834
    /** Returns true if field we is set (has been assigned a value) and false otherwise */
11835
    public boolean isSetWe() {
11836
      return this.we != null;
11837
    }
11838
 
11839
    public void setWeIsSet(boolean value) {
11840
      if (!value) {
11841
        this.we = null;
11842
      }
11843
    }
11844
 
11845
    public void setFieldValue(_Fields field, Object value) {
11846
      switch (field) {
11847
      case SUCCESS:
11848
        if (value == null) {
11849
          unsetSuccess();
11850
        } else {
11851
          setSuccess((InventoryItem)value);
11852
        }
11853
        break;
11854
 
11855
      case WE:
11856
        if (value == null) {
11857
          unsetWe();
11858
        } else {
11859
          setWe((WarehouseServiceException)value);
11860
        }
11861
        break;
11862
 
11863
      }
11864
    }
11865
 
11866
    public Object getFieldValue(_Fields field) {
11867
      switch (field) {
11868
      case SUCCESS:
11869
        return getSuccess();
11870
 
11871
      case WE:
11872
        return getWe();
11873
 
11874
      }
11875
      throw new IllegalStateException();
11876
    }
11877
 
11878
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11879
    public boolean isSet(_Fields field) {
11880
      if (field == null) {
11881
        throw new IllegalArgumentException();
11882
      }
11883
 
11884
      switch (field) {
11885
      case SUCCESS:
11886
        return isSetSuccess();
11887
      case WE:
11888
        return isSetWe();
11889
      }
11890
      throw new IllegalStateException();
11891
    }
11892
 
11893
    @Override
11894
    public boolean equals(Object that) {
11895
      if (that == null)
11896
        return false;
11897
      if (that instanceof getInventoryItemFromOrder_result)
11898
        return this.equals((getInventoryItemFromOrder_result)that);
11899
      return false;
11900
    }
11901
 
11902
    public boolean equals(getInventoryItemFromOrder_result that) {
11903
      if (that == null)
11904
        return false;
11905
 
11906
      boolean this_present_success = true && this.isSetSuccess();
11907
      boolean that_present_success = true && that.isSetSuccess();
11908
      if (this_present_success || that_present_success) {
11909
        if (!(this_present_success && that_present_success))
11910
          return false;
11911
        if (!this.success.equals(that.success))
11912
          return false;
11913
      }
11914
 
11915
      boolean this_present_we = true && this.isSetWe();
11916
      boolean that_present_we = true && that.isSetWe();
11917
      if (this_present_we || that_present_we) {
11918
        if (!(this_present_we && that_present_we))
11919
          return false;
11920
        if (!this.we.equals(that.we))
11921
          return false;
11922
      }
11923
 
11924
      return true;
11925
    }
11926
 
11927
    @Override
11928
    public int hashCode() {
11929
      return 0;
11930
    }
11931
 
11932
    public int compareTo(getInventoryItemFromOrder_result other) {
11933
      if (!getClass().equals(other.getClass())) {
11934
        return getClass().getName().compareTo(other.getClass().getName());
11935
      }
11936
 
11937
      int lastComparison = 0;
11938
      getInventoryItemFromOrder_result typedOther = (getInventoryItemFromOrder_result)other;
11939
 
11940
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
11941
      if (lastComparison != 0) {
11942
        return lastComparison;
11943
      }
11944
      if (isSetSuccess()) {
11945
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11946
        if (lastComparison != 0) {
11947
          return lastComparison;
11948
        }
11949
      }
11950
      lastComparison = Boolean.valueOf(isSetWe()).compareTo(typedOther.isSetWe());
11951
      if (lastComparison != 0) {
11952
        return lastComparison;
11953
      }
11954
      if (isSetWe()) {
11955
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.we, typedOther.we);
11956
        if (lastComparison != 0) {
11957
          return lastComparison;
11958
        }
11959
      }
11960
      return 0;
11961
    }
11962
 
11963
    public _Fields fieldForId(int fieldId) {
11964
      return _Fields.findByThriftId(fieldId);
11965
    }
11966
 
11967
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11968
      org.apache.thrift.protocol.TField field;
11969
      iprot.readStructBegin();
11970
      while (true)
11971
      {
11972
        field = iprot.readFieldBegin();
11973
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11974
          break;
11975
        }
11976
        switch (field.id) {
11977
          case 0: // SUCCESS
11978
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11979
              this.success = new InventoryItem();
11980
              this.success.read(iprot);
11981
            } else { 
11982
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11983
            }
11984
            break;
11985
          case 1: // WE
11986
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11987
              this.we = new WarehouseServiceException();
11988
              this.we.read(iprot);
11989
            } else { 
11990
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11991
            }
11992
            break;
11993
          default:
11994
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11995
        }
11996
        iprot.readFieldEnd();
11997
      }
11998
      iprot.readStructEnd();
11999
      validate();
12000
    }
12001
 
12002
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12003
      oprot.writeStructBegin(STRUCT_DESC);
12004
 
12005
      if (this.isSetSuccess()) {
12006
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
12007
        this.success.write(oprot);
12008
        oprot.writeFieldEnd();
12009
      } else if (this.isSetWe()) {
12010
        oprot.writeFieldBegin(WE_FIELD_DESC);
12011
        this.we.write(oprot);
12012
        oprot.writeFieldEnd();
12013
      }
12014
      oprot.writeFieldStop();
12015
      oprot.writeStructEnd();
12016
    }
12017
 
12018
    @Override
12019
    public String toString() {
12020
      StringBuilder sb = new StringBuilder("getInventoryItemFromOrder_result(");
12021
      boolean first = true;
12022
 
12023
      sb.append("success:");
12024
      if (this.success == null) {
12025
        sb.append("null");
12026
      } else {
12027
        sb.append(this.success);
12028
      }
12029
      first = false;
12030
      if (!first) sb.append(", ");
12031
      sb.append("we:");
12032
      if (this.we == null) {
12033
        sb.append("null");
12034
      } else {
12035
        sb.append(this.we);
12036
      }
12037
      first = false;
12038
      sb.append(")");
12039
      return sb.toString();
12040
    }
12041
 
12042
    public void validate() throws org.apache.thrift.TException {
12043
      // check for required fields
12044
    }
12045
 
12046
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12047
      try {
12048
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12049
      } catch (org.apache.thrift.TException te) {
12050
        throw new java.io.IOException(te);
12051
      }
12052
    }
12053
 
12054
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12055
      try {
12056
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12057
      } catch (org.apache.thrift.TException te) {
12058
        throw new java.io.IOException(te);
12059
      }
12060
    }
12061
 
12062
  }
12063
 
5711 mandeep.dh 12064
  public static class getInventoryAge_args implements org.apache.thrift.TBase<getInventoryAge_args, getInventoryAge_args._Fields>, java.io.Serializable, Cloneable   {
12065
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryAge_args");
12066
 
12067
 
12068
 
12069
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12070
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12071
;
12072
 
12073
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12074
 
12075
      static {
12076
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12077
          byName.put(field.getFieldName(), field);
12078
        }
12079
      }
12080
 
12081
      /**
12082
       * Find the _Fields constant that matches fieldId, or null if its not found.
12083
       */
12084
      public static _Fields findByThriftId(int fieldId) {
12085
        switch(fieldId) {
12086
          default:
12087
            return null;
12088
        }
12089
      }
12090
 
12091
      /**
12092
       * Find the _Fields constant that matches fieldId, throwing an exception
12093
       * if it is not found.
12094
       */
12095
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12096
        _Fields fields = findByThriftId(fieldId);
12097
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12098
        return fields;
12099
      }
12100
 
12101
      /**
12102
       * Find the _Fields constant that matches name, or null if its not found.
12103
       */
12104
      public static _Fields findByName(String name) {
12105
        return byName.get(name);
12106
      }
12107
 
12108
      private final short _thriftId;
12109
      private final String _fieldName;
12110
 
12111
      _Fields(short thriftId, String fieldName) {
12112
        _thriftId = thriftId;
12113
        _fieldName = fieldName;
12114
      }
12115
 
12116
      public short getThriftFieldId() {
12117
        return _thriftId;
12118
      }
12119
 
12120
      public String getFieldName() {
12121
        return _fieldName;
12122
      }
12123
    }
12124
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12125
    static {
12126
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12127
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12128
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryAge_args.class, metaDataMap);
12129
    }
12130
 
12131
    public getInventoryAge_args() {
12132
    }
12133
 
12134
    /**
12135
     * Performs a deep copy on <i>other</i>.
12136
     */
12137
    public getInventoryAge_args(getInventoryAge_args other) {
12138
    }
12139
 
12140
    public getInventoryAge_args deepCopy() {
12141
      return new getInventoryAge_args(this);
12142
    }
12143
 
12144
    @Override
12145
    public void clear() {
12146
    }
12147
 
12148
    public void setFieldValue(_Fields field, Object value) {
12149
      switch (field) {
12150
      }
12151
    }
12152
 
12153
    public Object getFieldValue(_Fields field) {
12154
      switch (field) {
12155
      }
12156
      throw new IllegalStateException();
12157
    }
12158
 
12159
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12160
    public boolean isSet(_Fields field) {
12161
      if (field == null) {
12162
        throw new IllegalArgumentException();
12163
      }
12164
 
12165
      switch (field) {
12166
      }
12167
      throw new IllegalStateException();
12168
    }
12169
 
12170
    @Override
12171
    public boolean equals(Object that) {
12172
      if (that == null)
12173
        return false;
12174
      if (that instanceof getInventoryAge_args)
12175
        return this.equals((getInventoryAge_args)that);
12176
      return false;
12177
    }
12178
 
12179
    public boolean equals(getInventoryAge_args that) {
12180
      if (that == null)
12181
        return false;
12182
 
12183
      return true;
12184
    }
12185
 
12186
    @Override
12187
    public int hashCode() {
12188
      return 0;
12189
    }
12190
 
12191
    public int compareTo(getInventoryAge_args other) {
12192
      if (!getClass().equals(other.getClass())) {
12193
        return getClass().getName().compareTo(other.getClass().getName());
12194
      }
12195
 
12196
      int lastComparison = 0;
12197
      getInventoryAge_args typedOther = (getInventoryAge_args)other;
12198
 
12199
      return 0;
12200
    }
12201
 
12202
    public _Fields fieldForId(int fieldId) {
12203
      return _Fields.findByThriftId(fieldId);
12204
    }
12205
 
12206
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12207
      org.apache.thrift.protocol.TField field;
12208
      iprot.readStructBegin();
12209
      while (true)
12210
      {
12211
        field = iprot.readFieldBegin();
12212
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12213
          break;
12214
        }
12215
        switch (field.id) {
12216
          default:
12217
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12218
        }
12219
        iprot.readFieldEnd();
12220
      }
12221
      iprot.readStructEnd();
12222
      validate();
12223
    }
12224
 
12225
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12226
      validate();
12227
 
12228
      oprot.writeStructBegin(STRUCT_DESC);
12229
      oprot.writeFieldStop();
12230
      oprot.writeStructEnd();
12231
    }
12232
 
12233
    @Override
12234
    public String toString() {
12235
      StringBuilder sb = new StringBuilder("getInventoryAge_args(");
12236
      boolean first = true;
12237
 
12238
      sb.append(")");
12239
      return sb.toString();
12240
    }
12241
 
12242
    public void validate() throws org.apache.thrift.TException {
12243
      // check for required fields
12244
    }
12245
 
12246
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12247
      try {
12248
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12249
      } catch (org.apache.thrift.TException te) {
12250
        throw new java.io.IOException(te);
12251
      }
12252
    }
12253
 
12254
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12255
      try {
12256
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12257
      } catch (org.apache.thrift.TException te) {
12258
        throw new java.io.IOException(te);
12259
      }
12260
    }
12261
 
12262
  }
12263
 
12264
  public static class getInventoryAge_result implements org.apache.thrift.TBase<getInventoryAge_result, getInventoryAge_result._Fields>, java.io.Serializable, Cloneable   {
12265
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryAge_result");
12266
 
12267
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
12268
 
12269
    private List<InventoryAge> success; // required
12270
 
12271
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12272
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12273
      SUCCESS((short)0, "success");
12274
 
12275
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12276
 
12277
      static {
12278
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12279
          byName.put(field.getFieldName(), field);
12280
        }
12281
      }
12282
 
12283
      /**
12284
       * Find the _Fields constant that matches fieldId, or null if its not found.
12285
       */
12286
      public static _Fields findByThriftId(int fieldId) {
12287
        switch(fieldId) {
12288
          case 0: // SUCCESS
12289
            return SUCCESS;
12290
          default:
12291
            return null;
12292
        }
12293
      }
12294
 
12295
      /**
12296
       * Find the _Fields constant that matches fieldId, throwing an exception
12297
       * if it is not found.
12298
       */
12299
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12300
        _Fields fields = findByThriftId(fieldId);
12301
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12302
        return fields;
12303
      }
12304
 
12305
      /**
12306
       * Find the _Fields constant that matches name, or null if its not found.
12307
       */
12308
      public static _Fields findByName(String name) {
12309
        return byName.get(name);
12310
      }
12311
 
12312
      private final short _thriftId;
12313
      private final String _fieldName;
12314
 
12315
      _Fields(short thriftId, String fieldName) {
12316
        _thriftId = thriftId;
12317
        _fieldName = fieldName;
12318
      }
12319
 
12320
      public short getThriftFieldId() {
12321
        return _thriftId;
12322
      }
12323
 
12324
      public String getFieldName() {
12325
        return _fieldName;
12326
      }
12327
    }
12328
 
12329
    // isset id assignments
12330
 
12331
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12332
    static {
12333
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12334
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12335
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
12336
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryAge.class))));
12337
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12338
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryAge_result.class, metaDataMap);
12339
    }
12340
 
12341
    public getInventoryAge_result() {
12342
    }
12343
 
12344
    public getInventoryAge_result(
12345
      List<InventoryAge> success)
12346
    {
12347
      this();
12348
      this.success = success;
12349
    }
12350
 
12351
    /**
12352
     * Performs a deep copy on <i>other</i>.
12353
     */
12354
    public getInventoryAge_result(getInventoryAge_result other) {
12355
      if (other.isSetSuccess()) {
12356
        List<InventoryAge> __this__success = new ArrayList<InventoryAge>();
12357
        for (InventoryAge other_element : other.success) {
12358
          __this__success.add(new InventoryAge(other_element));
12359
        }
12360
        this.success = __this__success;
12361
      }
12362
    }
12363
 
12364
    public getInventoryAge_result deepCopy() {
12365
      return new getInventoryAge_result(this);
12366
    }
12367
 
12368
    @Override
12369
    public void clear() {
12370
      this.success = null;
12371
    }
12372
 
12373
    public int getSuccessSize() {
12374
      return (this.success == null) ? 0 : this.success.size();
12375
    }
12376
 
12377
    public java.util.Iterator<InventoryAge> getSuccessIterator() {
12378
      return (this.success == null) ? null : this.success.iterator();
12379
    }
12380
 
12381
    public void addToSuccess(InventoryAge elem) {
12382
      if (this.success == null) {
12383
        this.success = new ArrayList<InventoryAge>();
12384
      }
12385
      this.success.add(elem);
12386
    }
12387
 
12388
    public List<InventoryAge> getSuccess() {
12389
      return this.success;
12390
    }
12391
 
12392
    public void setSuccess(List<InventoryAge> success) {
12393
      this.success = success;
12394
    }
12395
 
12396
    public void unsetSuccess() {
12397
      this.success = null;
12398
    }
12399
 
12400
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
12401
    public boolean isSetSuccess() {
12402
      return this.success != null;
12403
    }
12404
 
12405
    public void setSuccessIsSet(boolean value) {
12406
      if (!value) {
12407
        this.success = null;
12408
      }
12409
    }
12410
 
12411
    public void setFieldValue(_Fields field, Object value) {
12412
      switch (field) {
12413
      case SUCCESS:
12414
        if (value == null) {
12415
          unsetSuccess();
12416
        } else {
12417
          setSuccess((List<InventoryAge>)value);
12418
        }
12419
        break;
12420
 
12421
      }
12422
    }
12423
 
12424
    public Object getFieldValue(_Fields field) {
12425
      switch (field) {
12426
      case SUCCESS:
12427
        return getSuccess();
12428
 
12429
      }
12430
      throw new IllegalStateException();
12431
    }
12432
 
12433
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12434
    public boolean isSet(_Fields field) {
12435
      if (field == null) {
12436
        throw new IllegalArgumentException();
12437
      }
12438
 
12439
      switch (field) {
12440
      case SUCCESS:
12441
        return isSetSuccess();
12442
      }
12443
      throw new IllegalStateException();
12444
    }
12445
 
12446
    @Override
12447
    public boolean equals(Object that) {
12448
      if (that == null)
12449
        return false;
12450
      if (that instanceof getInventoryAge_result)
12451
        return this.equals((getInventoryAge_result)that);
12452
      return false;
12453
    }
12454
 
12455
    public boolean equals(getInventoryAge_result that) {
12456
      if (that == null)
12457
        return false;
12458
 
12459
      boolean this_present_success = true && this.isSetSuccess();
12460
      boolean that_present_success = true && that.isSetSuccess();
12461
      if (this_present_success || that_present_success) {
12462
        if (!(this_present_success && that_present_success))
12463
          return false;
12464
        if (!this.success.equals(that.success))
12465
          return false;
12466
      }
12467
 
12468
      return true;
12469
    }
12470
 
12471
    @Override
12472
    public int hashCode() {
12473
      return 0;
12474
    }
12475
 
12476
    public int compareTo(getInventoryAge_result other) {
12477
      if (!getClass().equals(other.getClass())) {
12478
        return getClass().getName().compareTo(other.getClass().getName());
12479
      }
12480
 
12481
      int lastComparison = 0;
12482
      getInventoryAge_result typedOther = (getInventoryAge_result)other;
12483
 
12484
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
12485
      if (lastComparison != 0) {
12486
        return lastComparison;
12487
      }
12488
      if (isSetSuccess()) {
12489
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
12490
        if (lastComparison != 0) {
12491
          return lastComparison;
12492
        }
12493
      }
12494
      return 0;
12495
    }
12496
 
12497
    public _Fields fieldForId(int fieldId) {
12498
      return _Fields.findByThriftId(fieldId);
12499
    }
12500
 
12501
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12502
      org.apache.thrift.protocol.TField field;
12503
      iprot.readStructBegin();
12504
      while (true)
12505
      {
12506
        field = iprot.readFieldBegin();
12507
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12508
          break;
12509
        }
12510
        switch (field.id) {
12511
          case 0: // SUCCESS
12512
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
12513
              {
12514
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
12515
                this.success = new ArrayList<InventoryAge>(_list20.size);
12516
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
12517
                {
12518
                  InventoryAge _elem22; // required
12519
                  _elem22 = new InventoryAge();
12520
                  _elem22.read(iprot);
12521
                  this.success.add(_elem22);
12522
                }
12523
                iprot.readListEnd();
12524
              }
12525
            } else { 
12526
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12527
            }
12528
            break;
12529
          default:
12530
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12531
        }
12532
        iprot.readFieldEnd();
12533
      }
12534
      iprot.readStructEnd();
12535
      validate();
12536
    }
12537
 
12538
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12539
      oprot.writeStructBegin(STRUCT_DESC);
12540
 
12541
      if (this.isSetSuccess()) {
12542
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
12543
        {
12544
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
12545
          for (InventoryAge _iter23 : this.success)
12546
          {
12547
            _iter23.write(oprot);
12548
          }
12549
          oprot.writeListEnd();
12550
        }
12551
        oprot.writeFieldEnd();
12552
      }
12553
      oprot.writeFieldStop();
12554
      oprot.writeStructEnd();
12555
    }
12556
 
12557
    @Override
12558
    public String toString() {
12559
      StringBuilder sb = new StringBuilder("getInventoryAge_result(");
12560
      boolean first = true;
12561
 
12562
      sb.append("success:");
12563
      if (this.success == null) {
12564
        sb.append("null");
12565
      } else {
12566
        sb.append(this.success);
12567
      }
12568
      first = false;
12569
      sb.append(")");
12570
      return sb.toString();
12571
    }
12572
 
12573
    public void validate() throws org.apache.thrift.TException {
12574
      // check for required fields
12575
    }
12576
 
12577
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12578
      try {
12579
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12580
      } catch (org.apache.thrift.TException te) {
12581
        throw new java.io.IOException(te);
12582
      }
12583
    }
12584
 
12585
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12586
      try {
12587
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12588
      } catch (org.apache.thrift.TException te) {
12589
        throw new java.io.IOException(te);
12590
      }
12591
    }
12592
 
12593
  }
12594
 
6322 amar.kumar 12595
  public static class getInventoryScansForItem_args implements org.apache.thrift.TBase<getInventoryScansForItem_args, getInventoryScansForItem_args._Fields>, java.io.Serializable, Cloneable   {
12596
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryScansForItem_args");
12597
 
12598
    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)1);
12599
    private static final org.apache.thrift.protocol.TField FROM_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("fromDate", org.apache.thrift.protocol.TType.I64, (short)2);
12600
    private static final org.apache.thrift.protocol.TField TO_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("toDate", org.apache.thrift.protocol.TType.I64, (short)3);
12601
 
12602
    private long itemId; // required
12603
    private long fromDate; // required
12604
    private long toDate; // required
12605
 
12606
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12607
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12608
      ITEM_ID((short)1, "itemId"),
12609
      FROM_DATE((short)2, "fromDate"),
12610
      TO_DATE((short)3, "toDate");
12611
 
12612
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12613
 
12614
      static {
12615
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12616
          byName.put(field.getFieldName(), field);
12617
        }
12618
      }
12619
 
12620
      /**
12621
       * Find the _Fields constant that matches fieldId, or null if its not found.
12622
       */
12623
      public static _Fields findByThriftId(int fieldId) {
12624
        switch(fieldId) {
12625
          case 1: // ITEM_ID
12626
            return ITEM_ID;
12627
          case 2: // FROM_DATE
12628
            return FROM_DATE;
12629
          case 3: // TO_DATE
12630
            return TO_DATE;
12631
          default:
12632
            return null;
12633
        }
12634
      }
12635
 
12636
      /**
12637
       * Find the _Fields constant that matches fieldId, throwing an exception
12638
       * if it is not found.
12639
       */
12640
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12641
        _Fields fields = findByThriftId(fieldId);
12642
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12643
        return fields;
12644
      }
12645
 
12646
      /**
12647
       * Find the _Fields constant that matches name, or null if its not found.
12648
       */
12649
      public static _Fields findByName(String name) {
12650
        return byName.get(name);
12651
      }
12652
 
12653
      private final short _thriftId;
12654
      private final String _fieldName;
12655
 
12656
      _Fields(short thriftId, String fieldName) {
12657
        _thriftId = thriftId;
12658
        _fieldName = fieldName;
12659
      }
12660
 
12661
      public short getThriftFieldId() {
12662
        return _thriftId;
12663
      }
12664
 
12665
      public String getFieldName() {
12666
        return _fieldName;
12667
      }
12668
    }
12669
 
12670
    // isset id assignments
12671
    private static final int __ITEMID_ISSET_ID = 0;
12672
    private static final int __FROMDATE_ISSET_ID = 1;
12673
    private static final int __TODATE_ISSET_ID = 2;
12674
    private BitSet __isset_bit_vector = new BitSet(3);
12675
 
12676
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12677
    static {
12678
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12679
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12680
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12681
      tmpMap.put(_Fields.FROM_DATE, new org.apache.thrift.meta_data.FieldMetaData("fromDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12682
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12683
      tmpMap.put(_Fields.TO_DATE, new org.apache.thrift.meta_data.FieldMetaData("toDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12684
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12685
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12686
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryScansForItem_args.class, metaDataMap);
12687
    }
12688
 
12689
    public getInventoryScansForItem_args() {
12690
    }
12691
 
12692
    public getInventoryScansForItem_args(
12693
      long itemId,
12694
      long fromDate,
12695
      long toDate)
12696
    {
12697
      this();
12698
      this.itemId = itemId;
12699
      setItemIdIsSet(true);
12700
      this.fromDate = fromDate;
12701
      setFromDateIsSet(true);
12702
      this.toDate = toDate;
12703
      setToDateIsSet(true);
12704
    }
12705
 
12706
    /**
12707
     * Performs a deep copy on <i>other</i>.
12708
     */
12709
    public getInventoryScansForItem_args(getInventoryScansForItem_args other) {
12710
      __isset_bit_vector.clear();
12711
      __isset_bit_vector.or(other.__isset_bit_vector);
12712
      this.itemId = other.itemId;
12713
      this.fromDate = other.fromDate;
12714
      this.toDate = other.toDate;
12715
    }
12716
 
12717
    public getInventoryScansForItem_args deepCopy() {
12718
      return new getInventoryScansForItem_args(this);
12719
    }
12720
 
12721
    @Override
12722
    public void clear() {
12723
      setItemIdIsSet(false);
12724
      this.itemId = 0;
12725
      setFromDateIsSet(false);
12726
      this.fromDate = 0;
12727
      setToDateIsSet(false);
12728
      this.toDate = 0;
12729
    }
12730
 
12731
    public long getItemId() {
12732
      return this.itemId;
12733
    }
12734
 
12735
    public void setItemId(long itemId) {
12736
      this.itemId = itemId;
12737
      setItemIdIsSet(true);
12738
    }
12739
 
12740
    public void unsetItemId() {
12741
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
12742
    }
12743
 
12744
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
12745
    public boolean isSetItemId() {
12746
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
12747
    }
12748
 
12749
    public void setItemIdIsSet(boolean value) {
12750
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
12751
    }
12752
 
12753
    public long getFromDate() {
12754
      return this.fromDate;
12755
    }
12756
 
12757
    public void setFromDate(long fromDate) {
12758
      this.fromDate = fromDate;
12759
      setFromDateIsSet(true);
12760
    }
12761
 
12762
    public void unsetFromDate() {
12763
      __isset_bit_vector.clear(__FROMDATE_ISSET_ID);
12764
    }
12765
 
12766
    /** Returns true if field fromDate is set (has been assigned a value) and false otherwise */
12767
    public boolean isSetFromDate() {
12768
      return __isset_bit_vector.get(__FROMDATE_ISSET_ID);
12769
    }
12770
 
12771
    public void setFromDateIsSet(boolean value) {
12772
      __isset_bit_vector.set(__FROMDATE_ISSET_ID, value);
12773
    }
12774
 
12775
    public long getToDate() {
12776
      return this.toDate;
12777
    }
12778
 
12779
    public void setToDate(long toDate) {
12780
      this.toDate = toDate;
12781
      setToDateIsSet(true);
12782
    }
12783
 
12784
    public void unsetToDate() {
12785
      __isset_bit_vector.clear(__TODATE_ISSET_ID);
12786
    }
12787
 
12788
    /** Returns true if field toDate is set (has been assigned a value) and false otherwise */
12789
    public boolean isSetToDate() {
12790
      return __isset_bit_vector.get(__TODATE_ISSET_ID);
12791
    }
12792
 
12793
    public void setToDateIsSet(boolean value) {
12794
      __isset_bit_vector.set(__TODATE_ISSET_ID, value);
12795
    }
12796
 
12797
    public void setFieldValue(_Fields field, Object value) {
12798
      switch (field) {
12799
      case ITEM_ID:
12800
        if (value == null) {
12801
          unsetItemId();
12802
        } else {
12803
          setItemId((Long)value);
12804
        }
12805
        break;
12806
 
12807
      case FROM_DATE:
12808
        if (value == null) {
12809
          unsetFromDate();
12810
        } else {
12811
          setFromDate((Long)value);
12812
        }
12813
        break;
12814
 
12815
      case TO_DATE:
12816
        if (value == null) {
12817
          unsetToDate();
12818
        } else {
12819
          setToDate((Long)value);
12820
        }
12821
        break;
12822
 
12823
      }
12824
    }
12825
 
12826
    public Object getFieldValue(_Fields field) {
12827
      switch (field) {
12828
      case ITEM_ID:
12829
        return Long.valueOf(getItemId());
12830
 
12831
      case FROM_DATE:
12832
        return Long.valueOf(getFromDate());
12833
 
12834
      case TO_DATE:
12835
        return Long.valueOf(getToDate());
12836
 
12837
      }
12838
      throw new IllegalStateException();
12839
    }
12840
 
12841
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12842
    public boolean isSet(_Fields field) {
12843
      if (field == null) {
12844
        throw new IllegalArgumentException();
12845
      }
12846
 
12847
      switch (field) {
12848
      case ITEM_ID:
12849
        return isSetItemId();
12850
      case FROM_DATE:
12851
        return isSetFromDate();
12852
      case TO_DATE:
12853
        return isSetToDate();
12854
      }
12855
      throw new IllegalStateException();
12856
    }
12857
 
12858
    @Override
12859
    public boolean equals(Object that) {
12860
      if (that == null)
12861
        return false;
12862
      if (that instanceof getInventoryScansForItem_args)
12863
        return this.equals((getInventoryScansForItem_args)that);
12864
      return false;
12865
    }
12866
 
12867
    public boolean equals(getInventoryScansForItem_args that) {
12868
      if (that == null)
12869
        return false;
12870
 
12871
      boolean this_present_itemId = true;
12872
      boolean that_present_itemId = true;
12873
      if (this_present_itemId || that_present_itemId) {
12874
        if (!(this_present_itemId && that_present_itemId))
12875
          return false;
12876
        if (this.itemId != that.itemId)
12877
          return false;
12878
      }
12879
 
12880
      boolean this_present_fromDate = true;
12881
      boolean that_present_fromDate = true;
12882
      if (this_present_fromDate || that_present_fromDate) {
12883
        if (!(this_present_fromDate && that_present_fromDate))
12884
          return false;
12885
        if (this.fromDate != that.fromDate)
12886
          return false;
12887
      }
12888
 
12889
      boolean this_present_toDate = true;
12890
      boolean that_present_toDate = true;
12891
      if (this_present_toDate || that_present_toDate) {
12892
        if (!(this_present_toDate && that_present_toDate))
12893
          return false;
12894
        if (this.toDate != that.toDate)
12895
          return false;
12896
      }
12897
 
12898
      return true;
12899
    }
12900
 
12901
    @Override
12902
    public int hashCode() {
12903
      return 0;
12904
    }
12905
 
12906
    public int compareTo(getInventoryScansForItem_args other) {
12907
      if (!getClass().equals(other.getClass())) {
12908
        return getClass().getName().compareTo(other.getClass().getName());
12909
      }
12910
 
12911
      int lastComparison = 0;
12912
      getInventoryScansForItem_args typedOther = (getInventoryScansForItem_args)other;
12913
 
12914
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
12915
      if (lastComparison != 0) {
12916
        return lastComparison;
12917
      }
12918
      if (isSetItemId()) {
12919
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
12920
        if (lastComparison != 0) {
12921
          return lastComparison;
12922
        }
12923
      }
12924
      lastComparison = Boolean.valueOf(isSetFromDate()).compareTo(typedOther.isSetFromDate());
12925
      if (lastComparison != 0) {
12926
        return lastComparison;
12927
      }
12928
      if (isSetFromDate()) {
12929
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromDate, typedOther.fromDate);
12930
        if (lastComparison != 0) {
12931
          return lastComparison;
12932
        }
12933
      }
12934
      lastComparison = Boolean.valueOf(isSetToDate()).compareTo(typedOther.isSetToDate());
12935
      if (lastComparison != 0) {
12936
        return lastComparison;
12937
      }
12938
      if (isSetToDate()) {
12939
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toDate, typedOther.toDate);
12940
        if (lastComparison != 0) {
12941
          return lastComparison;
12942
        }
12943
      }
12944
      return 0;
12945
    }
12946
 
12947
    public _Fields fieldForId(int fieldId) {
12948
      return _Fields.findByThriftId(fieldId);
12949
    }
12950
 
12951
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12952
      org.apache.thrift.protocol.TField field;
12953
      iprot.readStructBegin();
12954
      while (true)
12955
      {
12956
        field = iprot.readFieldBegin();
12957
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12958
          break;
12959
        }
12960
        switch (field.id) {
12961
          case 1: // ITEM_ID
12962
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12963
              this.itemId = iprot.readI64();
12964
              setItemIdIsSet(true);
12965
            } else { 
12966
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12967
            }
12968
            break;
12969
          case 2: // FROM_DATE
12970
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12971
              this.fromDate = iprot.readI64();
12972
              setFromDateIsSet(true);
12973
            } else { 
12974
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12975
            }
12976
            break;
12977
          case 3: // TO_DATE
12978
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12979
              this.toDate = iprot.readI64();
12980
              setToDateIsSet(true);
12981
            } else { 
12982
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12983
            }
12984
            break;
12985
          default:
12986
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12987
        }
12988
        iprot.readFieldEnd();
12989
      }
12990
      iprot.readStructEnd();
12991
      validate();
12992
    }
12993
 
12994
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12995
      validate();
12996
 
12997
      oprot.writeStructBegin(STRUCT_DESC);
12998
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
12999
      oprot.writeI64(this.itemId);
13000
      oprot.writeFieldEnd();
13001
      oprot.writeFieldBegin(FROM_DATE_FIELD_DESC);
13002
      oprot.writeI64(this.fromDate);
13003
      oprot.writeFieldEnd();
13004
      oprot.writeFieldBegin(TO_DATE_FIELD_DESC);
13005
      oprot.writeI64(this.toDate);
13006
      oprot.writeFieldEnd();
13007
      oprot.writeFieldStop();
13008
      oprot.writeStructEnd();
13009
    }
13010
 
13011
    @Override
13012
    public String toString() {
13013
      StringBuilder sb = new StringBuilder("getInventoryScansForItem_args(");
13014
      boolean first = true;
13015
 
13016
      sb.append("itemId:");
13017
      sb.append(this.itemId);
13018
      first = false;
13019
      if (!first) sb.append(", ");
13020
      sb.append("fromDate:");
13021
      sb.append(this.fromDate);
13022
      first = false;
13023
      if (!first) sb.append(", ");
13024
      sb.append("toDate:");
13025
      sb.append(this.toDate);
13026
      first = false;
13027
      sb.append(")");
13028
      return sb.toString();
13029
    }
13030
 
13031
    public void validate() throws org.apache.thrift.TException {
13032
      // check for required fields
13033
    }
13034
 
13035
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13036
      try {
13037
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13038
      } catch (org.apache.thrift.TException te) {
13039
        throw new java.io.IOException(te);
13040
      }
13041
    }
13042
 
13043
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13044
      try {
13045
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13046
      } catch (org.apache.thrift.TException te) {
13047
        throw new java.io.IOException(te);
13048
      }
13049
    }
13050
 
13051
  }
13052
 
13053
  public static class getInventoryScansForItem_result implements org.apache.thrift.TBase<getInventoryScansForItem_result, getInventoryScansForItem_result._Fields>, java.io.Serializable, Cloneable   {
13054
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventoryScansForItem_result");
13055
 
13056
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
13057
 
13058
    private List<Scan> success; // required
13059
 
13060
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13061
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13062
      SUCCESS((short)0, "success");
13063
 
13064
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13065
 
13066
      static {
13067
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13068
          byName.put(field.getFieldName(), field);
13069
        }
13070
      }
13071
 
13072
      /**
13073
       * Find the _Fields constant that matches fieldId, or null if its not found.
13074
       */
13075
      public static _Fields findByThriftId(int fieldId) {
13076
        switch(fieldId) {
13077
          case 0: // SUCCESS
13078
            return SUCCESS;
13079
          default:
13080
            return null;
13081
        }
13082
      }
13083
 
13084
      /**
13085
       * Find the _Fields constant that matches fieldId, throwing an exception
13086
       * if it is not found.
13087
       */
13088
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13089
        _Fields fields = findByThriftId(fieldId);
13090
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13091
        return fields;
13092
      }
13093
 
13094
      /**
13095
       * Find the _Fields constant that matches name, or null if its not found.
13096
       */
13097
      public static _Fields findByName(String name) {
13098
        return byName.get(name);
13099
      }
13100
 
13101
      private final short _thriftId;
13102
      private final String _fieldName;
13103
 
13104
      _Fields(short thriftId, String fieldName) {
13105
        _thriftId = thriftId;
13106
        _fieldName = fieldName;
13107
      }
13108
 
13109
      public short getThriftFieldId() {
13110
        return _thriftId;
13111
      }
13112
 
13113
      public String getFieldName() {
13114
        return _fieldName;
13115
      }
13116
    }
13117
 
13118
    // isset id assignments
13119
 
13120
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13121
    static {
13122
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13123
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13124
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
13125
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Scan.class))));
13126
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13127
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventoryScansForItem_result.class, metaDataMap);
13128
    }
13129
 
13130
    public getInventoryScansForItem_result() {
13131
    }
13132
 
13133
    public getInventoryScansForItem_result(
13134
      List<Scan> success)
13135
    {
13136
      this();
13137
      this.success = success;
13138
    }
13139
 
13140
    /**
13141
     * Performs a deep copy on <i>other</i>.
13142
     */
13143
    public getInventoryScansForItem_result(getInventoryScansForItem_result other) {
13144
      if (other.isSetSuccess()) {
13145
        List<Scan> __this__success = new ArrayList<Scan>();
13146
        for (Scan other_element : other.success) {
13147
          __this__success.add(new Scan(other_element));
13148
        }
13149
        this.success = __this__success;
13150
      }
13151
    }
13152
 
13153
    public getInventoryScansForItem_result deepCopy() {
13154
      return new getInventoryScansForItem_result(this);
13155
    }
13156
 
13157
    @Override
13158
    public void clear() {
13159
      this.success = null;
13160
    }
13161
 
13162
    public int getSuccessSize() {
13163
      return (this.success == null) ? 0 : this.success.size();
13164
    }
13165
 
13166
    public java.util.Iterator<Scan> getSuccessIterator() {
13167
      return (this.success == null) ? null : this.success.iterator();
13168
    }
13169
 
13170
    public void addToSuccess(Scan elem) {
13171
      if (this.success == null) {
13172
        this.success = new ArrayList<Scan>();
13173
      }
13174
      this.success.add(elem);
13175
    }
13176
 
13177
    public List<Scan> getSuccess() {
13178
      return this.success;
13179
    }
13180
 
13181
    public void setSuccess(List<Scan> success) {
13182
      this.success = success;
13183
    }
13184
 
13185
    public void unsetSuccess() {
13186
      this.success = null;
13187
    }
13188
 
13189
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13190
    public boolean isSetSuccess() {
13191
      return this.success != null;
13192
    }
13193
 
13194
    public void setSuccessIsSet(boolean value) {
13195
      if (!value) {
13196
        this.success = null;
13197
      }
13198
    }
13199
 
13200
    public void setFieldValue(_Fields field, Object value) {
13201
      switch (field) {
13202
      case SUCCESS:
13203
        if (value == null) {
13204
          unsetSuccess();
13205
        } else {
13206
          setSuccess((List<Scan>)value);
13207
        }
13208
        break;
13209
 
13210
      }
13211
    }
13212
 
13213
    public Object getFieldValue(_Fields field) {
13214
      switch (field) {
13215
      case SUCCESS:
13216
        return getSuccess();
13217
 
13218
      }
13219
      throw new IllegalStateException();
13220
    }
13221
 
13222
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13223
    public boolean isSet(_Fields field) {
13224
      if (field == null) {
13225
        throw new IllegalArgumentException();
13226
      }
13227
 
13228
      switch (field) {
13229
      case SUCCESS:
13230
        return isSetSuccess();
13231
      }
13232
      throw new IllegalStateException();
13233
    }
13234
 
13235
    @Override
13236
    public boolean equals(Object that) {
13237
      if (that == null)
13238
        return false;
13239
      if (that instanceof getInventoryScansForItem_result)
13240
        return this.equals((getInventoryScansForItem_result)that);
13241
      return false;
13242
    }
13243
 
13244
    public boolean equals(getInventoryScansForItem_result that) {
13245
      if (that == null)
13246
        return false;
13247
 
13248
      boolean this_present_success = true && this.isSetSuccess();
13249
      boolean that_present_success = true && that.isSetSuccess();
13250
      if (this_present_success || that_present_success) {
13251
        if (!(this_present_success && that_present_success))
13252
          return false;
13253
        if (!this.success.equals(that.success))
13254
          return false;
13255
      }
13256
 
13257
      return true;
13258
    }
13259
 
13260
    @Override
13261
    public int hashCode() {
13262
      return 0;
13263
    }
13264
 
13265
    public int compareTo(getInventoryScansForItem_result other) {
13266
      if (!getClass().equals(other.getClass())) {
13267
        return getClass().getName().compareTo(other.getClass().getName());
13268
      }
13269
 
13270
      int lastComparison = 0;
13271
      getInventoryScansForItem_result typedOther = (getInventoryScansForItem_result)other;
13272
 
13273
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13274
      if (lastComparison != 0) {
13275
        return lastComparison;
13276
      }
13277
      if (isSetSuccess()) {
13278
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13279
        if (lastComparison != 0) {
13280
          return lastComparison;
13281
        }
13282
      }
13283
      return 0;
13284
    }
13285
 
13286
    public _Fields fieldForId(int fieldId) {
13287
      return _Fields.findByThriftId(fieldId);
13288
    }
13289
 
13290
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13291
      org.apache.thrift.protocol.TField field;
13292
      iprot.readStructBegin();
13293
      while (true)
13294
      {
13295
        field = iprot.readFieldBegin();
13296
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13297
          break;
13298
        }
13299
        switch (field.id) {
13300
          case 0: // SUCCESS
13301
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
13302
              {
13303
                org.apache.thrift.protocol.TList _list24 = iprot.readListBegin();
13304
                this.success = new ArrayList<Scan>(_list24.size);
13305
                for (int _i25 = 0; _i25 < _list24.size; ++_i25)
13306
                {
13307
                  Scan _elem26; // required
13308
                  _elem26 = new Scan();
13309
                  _elem26.read(iprot);
13310
                  this.success.add(_elem26);
13311
                }
13312
                iprot.readListEnd();
13313
              }
13314
            } else { 
13315
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13316
            }
13317
            break;
13318
          default:
13319
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13320
        }
13321
        iprot.readFieldEnd();
13322
      }
13323
      iprot.readStructEnd();
13324
      validate();
13325
    }
13326
 
13327
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13328
      oprot.writeStructBegin(STRUCT_DESC);
13329
 
13330
      if (this.isSetSuccess()) {
13331
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
13332
        {
13333
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
13334
          for (Scan _iter27 : this.success)
13335
          {
13336
            _iter27.write(oprot);
13337
          }
13338
          oprot.writeListEnd();
13339
        }
13340
        oprot.writeFieldEnd();
13341
      }
13342
      oprot.writeFieldStop();
13343
      oprot.writeStructEnd();
13344
    }
13345
 
13346
    @Override
13347
    public String toString() {
13348
      StringBuilder sb = new StringBuilder("getInventoryScansForItem_result(");
13349
      boolean first = true;
13350
 
13351
      sb.append("success:");
13352
      if (this.success == null) {
13353
        sb.append("null");
13354
      } else {
13355
        sb.append(this.success);
13356
      }
13357
      first = false;
13358
      sb.append(")");
13359
      return sb.toString();
13360
    }
13361
 
13362
    public void validate() throws org.apache.thrift.TException {
13363
      // check for required fields
13364
    }
13365
 
13366
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13367
      try {
13368
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13369
      } catch (org.apache.thrift.TException te) {
13370
        throw new java.io.IOException(te);
13371
      }
13372
    }
13373
 
13374
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13375
      try {
13376
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13377
      } catch (org.apache.thrift.TException te) {
13378
        throw new java.io.IOException(te);
13379
      }
13380
    }
13381
 
13382
  }
13383
 
13384
  public static class getScanRecordsForSerialNumber_args implements org.apache.thrift.TBase<getScanRecordsForSerialNumber_args, getScanRecordsForSerialNumber_args._Fields>, java.io.Serializable, Cloneable   {
13385
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getScanRecordsForSerialNumber_args");
13386
 
13387
    private static final org.apache.thrift.protocol.TField SERIAL_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("serialNumber", org.apache.thrift.protocol.TType.I64, (short)1);
13388
 
13389
    private long serialNumber; // required
13390
 
13391
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13392
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13393
      SERIAL_NUMBER((short)1, "serialNumber");
13394
 
13395
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13396
 
13397
      static {
13398
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13399
          byName.put(field.getFieldName(), field);
13400
        }
13401
      }
13402
 
13403
      /**
13404
       * Find the _Fields constant that matches fieldId, or null if its not found.
13405
       */
13406
      public static _Fields findByThriftId(int fieldId) {
13407
        switch(fieldId) {
13408
          case 1: // SERIAL_NUMBER
13409
            return SERIAL_NUMBER;
13410
          default:
13411
            return null;
13412
        }
13413
      }
13414
 
13415
      /**
13416
       * Find the _Fields constant that matches fieldId, throwing an exception
13417
       * if it is not found.
13418
       */
13419
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13420
        _Fields fields = findByThriftId(fieldId);
13421
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13422
        return fields;
13423
      }
13424
 
13425
      /**
13426
       * Find the _Fields constant that matches name, or null if its not found.
13427
       */
13428
      public static _Fields findByName(String name) {
13429
        return byName.get(name);
13430
      }
13431
 
13432
      private final short _thriftId;
13433
      private final String _fieldName;
13434
 
13435
      _Fields(short thriftId, String fieldName) {
13436
        _thriftId = thriftId;
13437
        _fieldName = fieldName;
13438
      }
13439
 
13440
      public short getThriftFieldId() {
13441
        return _thriftId;
13442
      }
13443
 
13444
      public String getFieldName() {
13445
        return _fieldName;
13446
      }
13447
    }
13448
 
13449
    // isset id assignments
13450
    private static final int __SERIALNUMBER_ISSET_ID = 0;
13451
    private BitSet __isset_bit_vector = new BitSet(1);
13452
 
13453
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13454
    static {
13455
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13456
      tmpMap.put(_Fields.SERIAL_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("serialNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13457
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13458
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13459
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getScanRecordsForSerialNumber_args.class, metaDataMap);
13460
    }
13461
 
13462
    public getScanRecordsForSerialNumber_args() {
13463
    }
13464
 
13465
    public getScanRecordsForSerialNumber_args(
13466
      long serialNumber)
13467
    {
13468
      this();
13469
      this.serialNumber = serialNumber;
13470
      setSerialNumberIsSet(true);
13471
    }
13472
 
13473
    /**
13474
     * Performs a deep copy on <i>other</i>.
13475
     */
13476
    public getScanRecordsForSerialNumber_args(getScanRecordsForSerialNumber_args other) {
13477
      __isset_bit_vector.clear();
13478
      __isset_bit_vector.or(other.__isset_bit_vector);
13479
      this.serialNumber = other.serialNumber;
13480
    }
13481
 
13482
    public getScanRecordsForSerialNumber_args deepCopy() {
13483
      return new getScanRecordsForSerialNumber_args(this);
13484
    }
13485
 
13486
    @Override
13487
    public void clear() {
13488
      setSerialNumberIsSet(false);
13489
      this.serialNumber = 0;
13490
    }
13491
 
13492
    public long getSerialNumber() {
13493
      return this.serialNumber;
13494
    }
13495
 
13496
    public void setSerialNumber(long serialNumber) {
13497
      this.serialNumber = serialNumber;
13498
      setSerialNumberIsSet(true);
13499
    }
13500
 
13501
    public void unsetSerialNumber() {
13502
      __isset_bit_vector.clear(__SERIALNUMBER_ISSET_ID);
13503
    }
13504
 
13505
    /** Returns true if field serialNumber is set (has been assigned a value) and false otherwise */
13506
    public boolean isSetSerialNumber() {
13507
      return __isset_bit_vector.get(__SERIALNUMBER_ISSET_ID);
13508
    }
13509
 
13510
    public void setSerialNumberIsSet(boolean value) {
13511
      __isset_bit_vector.set(__SERIALNUMBER_ISSET_ID, value);
13512
    }
13513
 
13514
    public void setFieldValue(_Fields field, Object value) {
13515
      switch (field) {
13516
      case SERIAL_NUMBER:
13517
        if (value == null) {
13518
          unsetSerialNumber();
13519
        } else {
13520
          setSerialNumber((Long)value);
13521
        }
13522
        break;
13523
 
13524
      }
13525
    }
13526
 
13527
    public Object getFieldValue(_Fields field) {
13528
      switch (field) {
13529
      case SERIAL_NUMBER:
13530
        return Long.valueOf(getSerialNumber());
13531
 
13532
      }
13533
      throw new IllegalStateException();
13534
    }
13535
 
13536
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13537
    public boolean isSet(_Fields field) {
13538
      if (field == null) {
13539
        throw new IllegalArgumentException();
13540
      }
13541
 
13542
      switch (field) {
13543
      case SERIAL_NUMBER:
13544
        return isSetSerialNumber();
13545
      }
13546
      throw new IllegalStateException();
13547
    }
13548
 
13549
    @Override
13550
    public boolean equals(Object that) {
13551
      if (that == null)
13552
        return false;
13553
      if (that instanceof getScanRecordsForSerialNumber_args)
13554
        return this.equals((getScanRecordsForSerialNumber_args)that);
13555
      return false;
13556
    }
13557
 
13558
    public boolean equals(getScanRecordsForSerialNumber_args that) {
13559
      if (that == null)
13560
        return false;
13561
 
13562
      boolean this_present_serialNumber = true;
13563
      boolean that_present_serialNumber = true;
13564
      if (this_present_serialNumber || that_present_serialNumber) {
13565
        if (!(this_present_serialNumber && that_present_serialNumber))
13566
          return false;
13567
        if (this.serialNumber != that.serialNumber)
13568
          return false;
13569
      }
13570
 
13571
      return true;
13572
    }
13573
 
13574
    @Override
13575
    public int hashCode() {
13576
      return 0;
13577
    }
13578
 
13579
    public int compareTo(getScanRecordsForSerialNumber_args other) {
13580
      if (!getClass().equals(other.getClass())) {
13581
        return getClass().getName().compareTo(other.getClass().getName());
13582
      }
13583
 
13584
      int lastComparison = 0;
13585
      getScanRecordsForSerialNumber_args typedOther = (getScanRecordsForSerialNumber_args)other;
13586
 
13587
      lastComparison = Boolean.valueOf(isSetSerialNumber()).compareTo(typedOther.isSetSerialNumber());
13588
      if (lastComparison != 0) {
13589
        return lastComparison;
13590
      }
13591
      if (isSetSerialNumber()) {
13592
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.serialNumber, typedOther.serialNumber);
13593
        if (lastComparison != 0) {
13594
          return lastComparison;
13595
        }
13596
      }
13597
      return 0;
13598
    }
13599
 
13600
    public _Fields fieldForId(int fieldId) {
13601
      return _Fields.findByThriftId(fieldId);
13602
    }
13603
 
13604
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13605
      org.apache.thrift.protocol.TField field;
13606
      iprot.readStructBegin();
13607
      while (true)
13608
      {
13609
        field = iprot.readFieldBegin();
13610
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13611
          break;
13612
        }
13613
        switch (field.id) {
13614
          case 1: // SERIAL_NUMBER
13615
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13616
              this.serialNumber = iprot.readI64();
13617
              setSerialNumberIsSet(true);
13618
            } else { 
13619
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13620
            }
13621
            break;
13622
          default:
13623
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13624
        }
13625
        iprot.readFieldEnd();
13626
      }
13627
      iprot.readStructEnd();
13628
      validate();
13629
    }
13630
 
13631
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13632
      validate();
13633
 
13634
      oprot.writeStructBegin(STRUCT_DESC);
13635
      oprot.writeFieldBegin(SERIAL_NUMBER_FIELD_DESC);
13636
      oprot.writeI64(this.serialNumber);
13637
      oprot.writeFieldEnd();
13638
      oprot.writeFieldStop();
13639
      oprot.writeStructEnd();
13640
    }
13641
 
13642
    @Override
13643
    public String toString() {
13644
      StringBuilder sb = new StringBuilder("getScanRecordsForSerialNumber_args(");
13645
      boolean first = true;
13646
 
13647
      sb.append("serialNumber:");
13648
      sb.append(this.serialNumber);
13649
      first = false;
13650
      sb.append(")");
13651
      return sb.toString();
13652
    }
13653
 
13654
    public void validate() throws org.apache.thrift.TException {
13655
      // check for required fields
13656
    }
13657
 
13658
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13659
      try {
13660
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13661
      } catch (org.apache.thrift.TException te) {
13662
        throw new java.io.IOException(te);
13663
      }
13664
    }
13665
 
13666
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13667
      try {
13668
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
13669
        __isset_bit_vector = new BitSet(1);
13670
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13671
      } catch (org.apache.thrift.TException te) {
13672
        throw new java.io.IOException(te);
13673
      }
13674
    }
13675
 
13676
  }
13677
 
13678
  public static class getScanRecordsForSerialNumber_result implements org.apache.thrift.TBase<getScanRecordsForSerialNumber_result, getScanRecordsForSerialNumber_result._Fields>, java.io.Serializable, Cloneable   {
13679
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getScanRecordsForSerialNumber_result");
13680
 
13681
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
13682
 
13683
    private List<Scan> success; // required
13684
 
13685
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13686
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13687
      SUCCESS((short)0, "success");
13688
 
13689
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13690
 
13691
      static {
13692
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13693
          byName.put(field.getFieldName(), field);
13694
        }
13695
      }
13696
 
13697
      /**
13698
       * Find the _Fields constant that matches fieldId, or null if its not found.
13699
       */
13700
      public static _Fields findByThriftId(int fieldId) {
13701
        switch(fieldId) {
13702
          case 0: // SUCCESS
13703
            return SUCCESS;
13704
          default:
13705
            return null;
13706
        }
13707
      }
13708
 
13709
      /**
13710
       * Find the _Fields constant that matches fieldId, throwing an exception
13711
       * if it is not found.
13712
       */
13713
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13714
        _Fields fields = findByThriftId(fieldId);
13715
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13716
        return fields;
13717
      }
13718
 
13719
      /**
13720
       * Find the _Fields constant that matches name, or null if its not found.
13721
       */
13722
      public static _Fields findByName(String name) {
13723
        return byName.get(name);
13724
      }
13725
 
13726
      private final short _thriftId;
13727
      private final String _fieldName;
13728
 
13729
      _Fields(short thriftId, String fieldName) {
13730
        _thriftId = thriftId;
13731
        _fieldName = fieldName;
13732
      }
13733
 
13734
      public short getThriftFieldId() {
13735
        return _thriftId;
13736
      }
13737
 
13738
      public String getFieldName() {
13739
        return _fieldName;
13740
      }
13741
    }
13742
 
13743
    // isset id assignments
13744
 
13745
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13746
    static {
13747
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13748
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13749
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
13750
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Scan.class))));
13751
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13752
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getScanRecordsForSerialNumber_result.class, metaDataMap);
13753
    }
13754
 
13755
    public getScanRecordsForSerialNumber_result() {
13756
    }
13757
 
13758
    public getScanRecordsForSerialNumber_result(
13759
      List<Scan> success)
13760
    {
13761
      this();
13762
      this.success = success;
13763
    }
13764
 
13765
    /**
13766
     * Performs a deep copy on <i>other</i>.
13767
     */
13768
    public getScanRecordsForSerialNumber_result(getScanRecordsForSerialNumber_result other) {
13769
      if (other.isSetSuccess()) {
13770
        List<Scan> __this__success = new ArrayList<Scan>();
13771
        for (Scan other_element : other.success) {
13772
          __this__success.add(new Scan(other_element));
13773
        }
13774
        this.success = __this__success;
13775
      }
13776
    }
13777
 
13778
    public getScanRecordsForSerialNumber_result deepCopy() {
13779
      return new getScanRecordsForSerialNumber_result(this);
13780
    }
13781
 
13782
    @Override
13783
    public void clear() {
13784
      this.success = null;
13785
    }
13786
 
13787
    public int getSuccessSize() {
13788
      return (this.success == null) ? 0 : this.success.size();
13789
    }
13790
 
13791
    public java.util.Iterator<Scan> getSuccessIterator() {
13792
      return (this.success == null) ? null : this.success.iterator();
13793
    }
13794
 
13795
    public void addToSuccess(Scan elem) {
13796
      if (this.success == null) {
13797
        this.success = new ArrayList<Scan>();
13798
      }
13799
      this.success.add(elem);
13800
    }
13801
 
13802
    public List<Scan> getSuccess() {
13803
      return this.success;
13804
    }
13805
 
13806
    public void setSuccess(List<Scan> success) {
13807
      this.success = success;
13808
    }
13809
 
13810
    public void unsetSuccess() {
13811
      this.success = null;
13812
    }
13813
 
13814
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13815
    public boolean isSetSuccess() {
13816
      return this.success != null;
13817
    }
13818
 
13819
    public void setSuccessIsSet(boolean value) {
13820
      if (!value) {
13821
        this.success = null;
13822
      }
13823
    }
13824
 
13825
    public void setFieldValue(_Fields field, Object value) {
13826
      switch (field) {
13827
      case SUCCESS:
13828
        if (value == null) {
13829
          unsetSuccess();
13830
        } else {
13831
          setSuccess((List<Scan>)value);
13832
        }
13833
        break;
13834
 
13835
      }
13836
    }
13837
 
13838
    public Object getFieldValue(_Fields field) {
13839
      switch (field) {
13840
      case SUCCESS:
13841
        return getSuccess();
13842
 
13843
      }
13844
      throw new IllegalStateException();
13845
    }
13846
 
13847
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13848
    public boolean isSet(_Fields field) {
13849
      if (field == null) {
13850
        throw new IllegalArgumentException();
13851
      }
13852
 
13853
      switch (field) {
13854
      case SUCCESS:
13855
        return isSetSuccess();
13856
      }
13857
      throw new IllegalStateException();
13858
    }
13859
 
13860
    @Override
13861
    public boolean equals(Object that) {
13862
      if (that == null)
13863
        return false;
13864
      if (that instanceof getScanRecordsForSerialNumber_result)
13865
        return this.equals((getScanRecordsForSerialNumber_result)that);
13866
      return false;
13867
    }
13868
 
13869
    public boolean equals(getScanRecordsForSerialNumber_result that) {
13870
      if (that == null)
13871
        return false;
13872
 
13873
      boolean this_present_success = true && this.isSetSuccess();
13874
      boolean that_present_success = true && that.isSetSuccess();
13875
      if (this_present_success || that_present_success) {
13876
        if (!(this_present_success && that_present_success))
13877
          return false;
13878
        if (!this.success.equals(that.success))
13879
          return false;
13880
      }
13881
 
13882
      return true;
13883
    }
13884
 
13885
    @Override
13886
    public int hashCode() {
13887
      return 0;
13888
    }
13889
 
13890
    public int compareTo(getScanRecordsForSerialNumber_result other) {
13891
      if (!getClass().equals(other.getClass())) {
13892
        return getClass().getName().compareTo(other.getClass().getName());
13893
      }
13894
 
13895
      int lastComparison = 0;
13896
      getScanRecordsForSerialNumber_result typedOther = (getScanRecordsForSerialNumber_result)other;
13897
 
13898
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13899
      if (lastComparison != 0) {
13900
        return lastComparison;
13901
      }
13902
      if (isSetSuccess()) {
13903
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13904
        if (lastComparison != 0) {
13905
          return lastComparison;
13906
        }
13907
      }
13908
      return 0;
13909
    }
13910
 
13911
    public _Fields fieldForId(int fieldId) {
13912
      return _Fields.findByThriftId(fieldId);
13913
    }
13914
 
13915
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13916
      org.apache.thrift.protocol.TField field;
13917
      iprot.readStructBegin();
13918
      while (true)
13919
      {
13920
        field = iprot.readFieldBegin();
13921
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13922
          break;
13923
        }
13924
        switch (field.id) {
13925
          case 0: // SUCCESS
13926
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
13927
              {
13928
                org.apache.thrift.protocol.TList _list28 = iprot.readListBegin();
13929
                this.success = new ArrayList<Scan>(_list28.size);
13930
                for (int _i29 = 0; _i29 < _list28.size; ++_i29)
13931
                {
13932
                  Scan _elem30; // required
13933
                  _elem30 = new Scan();
13934
                  _elem30.read(iprot);
13935
                  this.success.add(_elem30);
13936
                }
13937
                iprot.readListEnd();
13938
              }
13939
            } else { 
13940
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13941
            }
13942
            break;
13943
          default:
13944
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13945
        }
13946
        iprot.readFieldEnd();
13947
      }
13948
      iprot.readStructEnd();
13949
      validate();
13950
    }
13951
 
13952
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13953
      oprot.writeStructBegin(STRUCT_DESC);
13954
 
13955
      if (this.isSetSuccess()) {
13956
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
13957
        {
13958
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
13959
          for (Scan _iter31 : this.success)
13960
          {
13961
            _iter31.write(oprot);
13962
          }
13963
          oprot.writeListEnd();
13964
        }
13965
        oprot.writeFieldEnd();
13966
      }
13967
      oprot.writeFieldStop();
13968
      oprot.writeStructEnd();
13969
    }
13970
 
13971
    @Override
13972
    public String toString() {
13973
      StringBuilder sb = new StringBuilder("getScanRecordsForSerialNumber_result(");
13974
      boolean first = true;
13975
 
13976
      sb.append("success:");
13977
      if (this.success == null) {
13978
        sb.append("null");
13979
      } else {
13980
        sb.append(this.success);
13981
      }
13982
      first = false;
13983
      sb.append(")");
13984
      return sb.toString();
13985
    }
13986
 
13987
    public void validate() throws org.apache.thrift.TException {
13988
      // check for required fields
13989
    }
13990
 
13991
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13992
      try {
13993
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13994
      } catch (org.apache.thrift.TException te) {
13995
        throw new java.io.IOException(te);
13996
      }
13997
    }
13998
 
13999
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14000
      try {
14001
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14002
      } catch (org.apache.thrift.TException te) {
14003
        throw new java.io.IOException(te);
14004
      }
14005
    }
14006
 
14007
  }
14008
 
6467 amar.kumar 14009
  public static class scanForPurchaseReturn_args implements org.apache.thrift.TBase<scanForPurchaseReturn_args, scanForPurchaseReturn_args._Fields>, java.io.Serializable, Cloneable   {
14010
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForPurchaseReturn_args");
14011
 
14012
    private static final org.apache.thrift.protocol.TField SALE_RETURN_ITEMS_FIELD_DESC = new org.apache.thrift.protocol.TField("saleReturnItems", org.apache.thrift.protocol.TType.LIST, (short)1);
14013
    private static final org.apache.thrift.protocol.TField VENDOR_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("vendorId", org.apache.thrift.protocol.TType.I64, (short)2);
14014
 
14015
    private List<InventoryItem> saleReturnItems; // required
14016
    private long vendorId; // required
14017
 
14018
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14019
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14020
      SALE_RETURN_ITEMS((short)1, "saleReturnItems"),
14021
      VENDOR_ID((short)2, "vendorId");
14022
 
14023
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14024
 
14025
      static {
14026
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14027
          byName.put(field.getFieldName(), field);
14028
        }
14029
      }
14030
 
14031
      /**
14032
       * Find the _Fields constant that matches fieldId, or null if its not found.
14033
       */
14034
      public static _Fields findByThriftId(int fieldId) {
14035
        switch(fieldId) {
14036
          case 1: // SALE_RETURN_ITEMS
14037
            return SALE_RETURN_ITEMS;
14038
          case 2: // VENDOR_ID
14039
            return VENDOR_ID;
14040
          default:
14041
            return null;
14042
        }
14043
      }
14044
 
14045
      /**
14046
       * Find the _Fields constant that matches fieldId, throwing an exception
14047
       * if it is not found.
14048
       */
14049
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14050
        _Fields fields = findByThriftId(fieldId);
14051
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14052
        return fields;
14053
      }
14054
 
14055
      /**
14056
       * Find the _Fields constant that matches name, or null if its not found.
14057
       */
14058
      public static _Fields findByName(String name) {
14059
        return byName.get(name);
14060
      }
14061
 
14062
      private final short _thriftId;
14063
      private final String _fieldName;
14064
 
14065
      _Fields(short thriftId, String fieldName) {
14066
        _thriftId = thriftId;
14067
        _fieldName = fieldName;
14068
      }
14069
 
14070
      public short getThriftFieldId() {
14071
        return _thriftId;
14072
      }
14073
 
14074
      public String getFieldName() {
14075
        return _fieldName;
14076
      }
14077
    }
14078
 
14079
    // isset id assignments
14080
    private static final int __VENDORID_ISSET_ID = 0;
14081
    private BitSet __isset_bit_vector = new BitSet(1);
14082
 
14083
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14084
    static {
14085
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14086
      tmpMap.put(_Fields.SALE_RETURN_ITEMS, new org.apache.thrift.meta_data.FieldMetaData("saleReturnItems", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14087
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
14088
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class))));
14089
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14090
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14091
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14092
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForPurchaseReturn_args.class, metaDataMap);
14093
    }
14094
 
14095
    public scanForPurchaseReturn_args() {
14096
    }
14097
 
14098
    public scanForPurchaseReturn_args(
14099
      List<InventoryItem> saleReturnItems,
14100
      long vendorId)
14101
    {
14102
      this();
14103
      this.saleReturnItems = saleReturnItems;
14104
      this.vendorId = vendorId;
14105
      setVendorIdIsSet(true);
14106
    }
14107
 
14108
    /**
14109
     * Performs a deep copy on <i>other</i>.
14110
     */
14111
    public scanForPurchaseReturn_args(scanForPurchaseReturn_args other) {
14112
      __isset_bit_vector.clear();
14113
      __isset_bit_vector.or(other.__isset_bit_vector);
14114
      if (other.isSetSaleReturnItems()) {
14115
        List<InventoryItem> __this__saleReturnItems = new ArrayList<InventoryItem>();
14116
        for (InventoryItem other_element : other.saleReturnItems) {
14117
          __this__saleReturnItems.add(new InventoryItem(other_element));
14118
        }
14119
        this.saleReturnItems = __this__saleReturnItems;
14120
      }
14121
      this.vendorId = other.vendorId;
14122
    }
14123
 
14124
    public scanForPurchaseReturn_args deepCopy() {
14125
      return new scanForPurchaseReturn_args(this);
14126
    }
14127
 
14128
    @Override
14129
    public void clear() {
14130
      this.saleReturnItems = null;
14131
      setVendorIdIsSet(false);
14132
      this.vendorId = 0;
14133
    }
14134
 
14135
    public int getSaleReturnItemsSize() {
14136
      return (this.saleReturnItems == null) ? 0 : this.saleReturnItems.size();
14137
    }
14138
 
14139
    public java.util.Iterator<InventoryItem> getSaleReturnItemsIterator() {
14140
      return (this.saleReturnItems == null) ? null : this.saleReturnItems.iterator();
14141
    }
14142
 
14143
    public void addToSaleReturnItems(InventoryItem elem) {
14144
      if (this.saleReturnItems == null) {
14145
        this.saleReturnItems = new ArrayList<InventoryItem>();
14146
      }
14147
      this.saleReturnItems.add(elem);
14148
    }
14149
 
14150
    public List<InventoryItem> getSaleReturnItems() {
14151
      return this.saleReturnItems;
14152
    }
14153
 
14154
    public void setSaleReturnItems(List<InventoryItem> saleReturnItems) {
14155
      this.saleReturnItems = saleReturnItems;
14156
    }
14157
 
14158
    public void unsetSaleReturnItems() {
14159
      this.saleReturnItems = null;
14160
    }
14161
 
14162
    /** Returns true if field saleReturnItems is set (has been assigned a value) and false otherwise */
14163
    public boolean isSetSaleReturnItems() {
14164
      return this.saleReturnItems != null;
14165
    }
14166
 
14167
    public void setSaleReturnItemsIsSet(boolean value) {
14168
      if (!value) {
14169
        this.saleReturnItems = null;
14170
      }
14171
    }
14172
 
14173
    public long getVendorId() {
14174
      return this.vendorId;
14175
    }
14176
 
14177
    public void setVendorId(long vendorId) {
14178
      this.vendorId = vendorId;
14179
      setVendorIdIsSet(true);
14180
    }
14181
 
14182
    public void unsetVendorId() {
14183
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
14184
    }
14185
 
14186
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
14187
    public boolean isSetVendorId() {
14188
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
14189
    }
14190
 
14191
    public void setVendorIdIsSet(boolean value) {
14192
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
14193
    }
14194
 
14195
    public void setFieldValue(_Fields field, Object value) {
14196
      switch (field) {
14197
      case SALE_RETURN_ITEMS:
14198
        if (value == null) {
14199
          unsetSaleReturnItems();
14200
        } else {
14201
          setSaleReturnItems((List<InventoryItem>)value);
14202
        }
14203
        break;
14204
 
14205
      case VENDOR_ID:
14206
        if (value == null) {
14207
          unsetVendorId();
14208
        } else {
14209
          setVendorId((Long)value);
14210
        }
14211
        break;
14212
 
14213
      }
14214
    }
14215
 
14216
    public Object getFieldValue(_Fields field) {
14217
      switch (field) {
14218
      case SALE_RETURN_ITEMS:
14219
        return getSaleReturnItems();
14220
 
14221
      case VENDOR_ID:
14222
        return Long.valueOf(getVendorId());
14223
 
14224
      }
14225
      throw new IllegalStateException();
14226
    }
14227
 
14228
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14229
    public boolean isSet(_Fields field) {
14230
      if (field == null) {
14231
        throw new IllegalArgumentException();
14232
      }
14233
 
14234
      switch (field) {
14235
      case SALE_RETURN_ITEMS:
14236
        return isSetSaleReturnItems();
14237
      case VENDOR_ID:
14238
        return isSetVendorId();
14239
      }
14240
      throw new IllegalStateException();
14241
    }
14242
 
14243
    @Override
14244
    public boolean equals(Object that) {
14245
      if (that == null)
14246
        return false;
14247
      if (that instanceof scanForPurchaseReturn_args)
14248
        return this.equals((scanForPurchaseReturn_args)that);
14249
      return false;
14250
    }
14251
 
14252
    public boolean equals(scanForPurchaseReturn_args that) {
14253
      if (that == null)
14254
        return false;
14255
 
14256
      boolean this_present_saleReturnItems = true && this.isSetSaleReturnItems();
14257
      boolean that_present_saleReturnItems = true && that.isSetSaleReturnItems();
14258
      if (this_present_saleReturnItems || that_present_saleReturnItems) {
14259
        if (!(this_present_saleReturnItems && that_present_saleReturnItems))
14260
          return false;
14261
        if (!this.saleReturnItems.equals(that.saleReturnItems))
14262
          return false;
14263
      }
14264
 
14265
      boolean this_present_vendorId = true;
14266
      boolean that_present_vendorId = true;
14267
      if (this_present_vendorId || that_present_vendorId) {
14268
        if (!(this_present_vendorId && that_present_vendorId))
14269
          return false;
14270
        if (this.vendorId != that.vendorId)
14271
          return false;
14272
      }
14273
 
14274
      return true;
14275
    }
14276
 
14277
    @Override
14278
    public int hashCode() {
14279
      return 0;
14280
    }
14281
 
14282
    public int compareTo(scanForPurchaseReturn_args other) {
14283
      if (!getClass().equals(other.getClass())) {
14284
        return getClass().getName().compareTo(other.getClass().getName());
14285
      }
14286
 
14287
      int lastComparison = 0;
14288
      scanForPurchaseReturn_args typedOther = (scanForPurchaseReturn_args)other;
14289
 
14290
      lastComparison = Boolean.valueOf(isSetSaleReturnItems()).compareTo(typedOther.isSetSaleReturnItems());
14291
      if (lastComparison != 0) {
14292
        return lastComparison;
14293
      }
14294
      if (isSetSaleReturnItems()) {
14295
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.saleReturnItems, typedOther.saleReturnItems);
14296
        if (lastComparison != 0) {
14297
          return lastComparison;
14298
        }
14299
      }
14300
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
14301
      if (lastComparison != 0) {
14302
        return lastComparison;
14303
      }
14304
      if (isSetVendorId()) {
14305
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
14306
        if (lastComparison != 0) {
14307
          return lastComparison;
14308
        }
14309
      }
14310
      return 0;
14311
    }
14312
 
14313
    public _Fields fieldForId(int fieldId) {
14314
      return _Fields.findByThriftId(fieldId);
14315
    }
14316
 
14317
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14318
      org.apache.thrift.protocol.TField field;
14319
      iprot.readStructBegin();
14320
      while (true)
14321
      {
14322
        field = iprot.readFieldBegin();
14323
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14324
          break;
14325
        }
14326
        switch (field.id) {
14327
          case 1: // SALE_RETURN_ITEMS
14328
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
14329
              {
14330
                org.apache.thrift.protocol.TList _list32 = iprot.readListBegin();
14331
                this.saleReturnItems = new ArrayList<InventoryItem>(_list32.size);
14332
                for (int _i33 = 0; _i33 < _list32.size; ++_i33)
14333
                {
14334
                  InventoryItem _elem34; // required
14335
                  _elem34 = new InventoryItem();
14336
                  _elem34.read(iprot);
14337
                  this.saleReturnItems.add(_elem34);
14338
                }
14339
                iprot.readListEnd();
14340
              }
14341
            } else { 
14342
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14343
            }
14344
            break;
14345
          case 2: // VENDOR_ID
14346
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14347
              this.vendorId = iprot.readI64();
14348
              setVendorIdIsSet(true);
14349
            } else { 
14350
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14351
            }
14352
            break;
14353
          default:
14354
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14355
        }
14356
        iprot.readFieldEnd();
14357
      }
14358
      iprot.readStructEnd();
14359
      validate();
14360
    }
14361
 
14362
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14363
      validate();
14364
 
14365
      oprot.writeStructBegin(STRUCT_DESC);
14366
      if (this.saleReturnItems != null) {
14367
        oprot.writeFieldBegin(SALE_RETURN_ITEMS_FIELD_DESC);
14368
        {
14369
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.saleReturnItems.size()));
14370
          for (InventoryItem _iter35 : this.saleReturnItems)
14371
          {
14372
            _iter35.write(oprot);
14373
          }
14374
          oprot.writeListEnd();
14375
        }
14376
        oprot.writeFieldEnd();
14377
      }
14378
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
14379
      oprot.writeI64(this.vendorId);
14380
      oprot.writeFieldEnd();
14381
      oprot.writeFieldStop();
14382
      oprot.writeStructEnd();
14383
    }
14384
 
14385
    @Override
14386
    public String toString() {
14387
      StringBuilder sb = new StringBuilder("scanForPurchaseReturn_args(");
14388
      boolean first = true;
14389
 
14390
      sb.append("saleReturnItems:");
14391
      if (this.saleReturnItems == null) {
14392
        sb.append("null");
14393
      } else {
14394
        sb.append(this.saleReturnItems);
14395
      }
14396
      first = false;
14397
      if (!first) sb.append(", ");
14398
      sb.append("vendorId:");
14399
      sb.append(this.vendorId);
14400
      first = false;
14401
      sb.append(")");
14402
      return sb.toString();
14403
    }
14404
 
14405
    public void validate() throws org.apache.thrift.TException {
14406
      // check for required fields
14407
    }
14408
 
14409
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14410
      try {
14411
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14412
      } catch (org.apache.thrift.TException te) {
14413
        throw new java.io.IOException(te);
14414
      }
14415
    }
14416
 
14417
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14418
      try {
14419
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14420
      } catch (org.apache.thrift.TException te) {
14421
        throw new java.io.IOException(te);
14422
      }
14423
    }
14424
 
14425
  }
14426
 
14427
  public static class scanForPurchaseReturn_result implements org.apache.thrift.TBase<scanForPurchaseReturn_result, scanForPurchaseReturn_result._Fields>, java.io.Serializable, Cloneable   {
14428
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForPurchaseReturn_result");
14429
 
14430
    private static final org.apache.thrift.protocol.TField EX_FIELD_DESC = new org.apache.thrift.protocol.TField("ex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
14431
 
14432
    private WarehouseServiceException ex; // required
14433
 
14434
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14435
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14436
      EX((short)1, "ex");
14437
 
14438
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14439
 
14440
      static {
14441
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14442
          byName.put(field.getFieldName(), field);
14443
        }
14444
      }
14445
 
14446
      /**
14447
       * Find the _Fields constant that matches fieldId, or null if its not found.
14448
       */
14449
      public static _Fields findByThriftId(int fieldId) {
14450
        switch(fieldId) {
14451
          case 1: // EX
14452
            return EX;
14453
          default:
14454
            return null;
14455
        }
14456
      }
14457
 
14458
      /**
14459
       * Find the _Fields constant that matches fieldId, throwing an exception
14460
       * if it is not found.
14461
       */
14462
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14463
        _Fields fields = findByThriftId(fieldId);
14464
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14465
        return fields;
14466
      }
14467
 
14468
      /**
14469
       * Find the _Fields constant that matches name, or null if its not found.
14470
       */
14471
      public static _Fields findByName(String name) {
14472
        return byName.get(name);
14473
      }
14474
 
14475
      private final short _thriftId;
14476
      private final String _fieldName;
14477
 
14478
      _Fields(short thriftId, String fieldName) {
14479
        _thriftId = thriftId;
14480
        _fieldName = fieldName;
14481
      }
14482
 
14483
      public short getThriftFieldId() {
14484
        return _thriftId;
14485
      }
14486
 
14487
      public String getFieldName() {
14488
        return _fieldName;
14489
      }
14490
    }
14491
 
14492
    // isset id assignments
14493
 
14494
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14495
    static {
14496
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14497
      tmpMap.put(_Fields.EX, new org.apache.thrift.meta_data.FieldMetaData("ex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14498
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
14499
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14500
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForPurchaseReturn_result.class, metaDataMap);
14501
    }
14502
 
14503
    public scanForPurchaseReturn_result() {
14504
    }
14505
 
14506
    public scanForPurchaseReturn_result(
14507
      WarehouseServiceException ex)
14508
    {
14509
      this();
14510
      this.ex = ex;
14511
    }
14512
 
14513
    /**
14514
     * Performs a deep copy on <i>other</i>.
14515
     */
14516
    public scanForPurchaseReturn_result(scanForPurchaseReturn_result other) {
14517
      if (other.isSetEx()) {
14518
        this.ex = new WarehouseServiceException(other.ex);
14519
      }
14520
    }
14521
 
14522
    public scanForPurchaseReturn_result deepCopy() {
14523
      return new scanForPurchaseReturn_result(this);
14524
    }
14525
 
14526
    @Override
14527
    public void clear() {
14528
      this.ex = null;
14529
    }
14530
 
14531
    public WarehouseServiceException getEx() {
14532
      return this.ex;
14533
    }
14534
 
14535
    public void setEx(WarehouseServiceException ex) {
14536
      this.ex = ex;
14537
    }
14538
 
14539
    public void unsetEx() {
14540
      this.ex = null;
14541
    }
14542
 
14543
    /** Returns true if field ex is set (has been assigned a value) and false otherwise */
14544
    public boolean isSetEx() {
14545
      return this.ex != null;
14546
    }
14547
 
14548
    public void setExIsSet(boolean value) {
14549
      if (!value) {
14550
        this.ex = null;
14551
      }
14552
    }
14553
 
14554
    public void setFieldValue(_Fields field, Object value) {
14555
      switch (field) {
14556
      case EX:
14557
        if (value == null) {
14558
          unsetEx();
14559
        } else {
14560
          setEx((WarehouseServiceException)value);
14561
        }
14562
        break;
14563
 
14564
      }
14565
    }
14566
 
14567
    public Object getFieldValue(_Fields field) {
14568
      switch (field) {
14569
      case EX:
14570
        return getEx();
14571
 
14572
      }
14573
      throw new IllegalStateException();
14574
    }
14575
 
14576
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14577
    public boolean isSet(_Fields field) {
14578
      if (field == null) {
14579
        throw new IllegalArgumentException();
14580
      }
14581
 
14582
      switch (field) {
14583
      case EX:
14584
        return isSetEx();
14585
      }
14586
      throw new IllegalStateException();
14587
    }
14588
 
14589
    @Override
14590
    public boolean equals(Object that) {
14591
      if (that == null)
14592
        return false;
14593
      if (that instanceof scanForPurchaseReturn_result)
14594
        return this.equals((scanForPurchaseReturn_result)that);
14595
      return false;
14596
    }
14597
 
14598
    public boolean equals(scanForPurchaseReturn_result that) {
14599
      if (that == null)
14600
        return false;
14601
 
14602
      boolean this_present_ex = true && this.isSetEx();
14603
      boolean that_present_ex = true && that.isSetEx();
14604
      if (this_present_ex || that_present_ex) {
14605
        if (!(this_present_ex && that_present_ex))
14606
          return false;
14607
        if (!this.ex.equals(that.ex))
14608
          return false;
14609
      }
14610
 
14611
      return true;
14612
    }
14613
 
14614
    @Override
14615
    public int hashCode() {
14616
      return 0;
14617
    }
14618
 
14619
    public int compareTo(scanForPurchaseReturn_result other) {
14620
      if (!getClass().equals(other.getClass())) {
14621
        return getClass().getName().compareTo(other.getClass().getName());
14622
      }
14623
 
14624
      int lastComparison = 0;
14625
      scanForPurchaseReturn_result typedOther = (scanForPurchaseReturn_result)other;
14626
 
14627
      lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx());
14628
      if (lastComparison != 0) {
14629
        return lastComparison;
14630
      }
14631
      if (isSetEx()) {
14632
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex);
14633
        if (lastComparison != 0) {
14634
          return lastComparison;
14635
        }
14636
      }
14637
      return 0;
14638
    }
14639
 
14640
    public _Fields fieldForId(int fieldId) {
14641
      return _Fields.findByThriftId(fieldId);
14642
    }
14643
 
14644
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14645
      org.apache.thrift.protocol.TField field;
14646
      iprot.readStructBegin();
14647
      while (true)
14648
      {
14649
        field = iprot.readFieldBegin();
14650
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14651
          break;
14652
        }
14653
        switch (field.id) {
14654
          case 1: // EX
14655
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
14656
              this.ex = new WarehouseServiceException();
14657
              this.ex.read(iprot);
14658
            } else { 
14659
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14660
            }
14661
            break;
14662
          default:
14663
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14664
        }
14665
        iprot.readFieldEnd();
14666
      }
14667
      iprot.readStructEnd();
14668
      validate();
14669
    }
14670
 
14671
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14672
      oprot.writeStructBegin(STRUCT_DESC);
14673
 
14674
      if (this.isSetEx()) {
14675
        oprot.writeFieldBegin(EX_FIELD_DESC);
14676
        this.ex.write(oprot);
14677
        oprot.writeFieldEnd();
14678
      }
14679
      oprot.writeFieldStop();
14680
      oprot.writeStructEnd();
14681
    }
14682
 
14683
    @Override
14684
    public String toString() {
14685
      StringBuilder sb = new StringBuilder("scanForPurchaseReturn_result(");
14686
      boolean first = true;
14687
 
14688
      sb.append("ex:");
14689
      if (this.ex == null) {
14690
        sb.append("null");
14691
      } else {
14692
        sb.append(this.ex);
14693
      }
14694
      first = false;
14695
      sb.append(")");
14696
      return sb.toString();
14697
    }
14698
 
14699
    public void validate() throws org.apache.thrift.TException {
14700
      // check for required fields
14701
    }
14702
 
14703
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14704
      try {
14705
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14706
      } catch (org.apache.thrift.TException te) {
14707
        throw new java.io.IOException(te);
14708
      }
14709
    }
14710
 
14711
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14712
      try {
14713
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14714
      } catch (org.apache.thrift.TException te) {
14715
        throw new java.io.IOException(te);
14716
      }
14717
    }
14718
 
14719
  }
14720
 
6548 amar.kumar 14721
  public static class scanForLostItem_args implements org.apache.thrift.TBase<scanForLostItem_args, scanForLostItem_args._Fields>, java.io.Serializable, Cloneable   {
14722
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForLostItem_args");
14723
 
14724
    private static final org.apache.thrift.protocol.TField LOST_ITEMS_FIELD_DESC = new org.apache.thrift.protocol.TField("lostItems", org.apache.thrift.protocol.TType.LIST, (short)1);
14725
    private static final org.apache.thrift.protocol.TField VENDOR_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("vendorId", org.apache.thrift.protocol.TType.I64, (short)2);
14726
 
14727
    private List<InventoryItem> lostItems; // required
14728
    private long vendorId; // required
14729
 
14730
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14731
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14732
      LOST_ITEMS((short)1, "lostItems"),
14733
      VENDOR_ID((short)2, "vendorId");
14734
 
14735
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14736
 
14737
      static {
14738
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14739
          byName.put(field.getFieldName(), field);
14740
        }
14741
      }
14742
 
14743
      /**
14744
       * Find the _Fields constant that matches fieldId, or null if its not found.
14745
       */
14746
      public static _Fields findByThriftId(int fieldId) {
14747
        switch(fieldId) {
14748
          case 1: // LOST_ITEMS
14749
            return LOST_ITEMS;
14750
          case 2: // VENDOR_ID
14751
            return VENDOR_ID;
14752
          default:
14753
            return null;
14754
        }
14755
      }
14756
 
14757
      /**
14758
       * Find the _Fields constant that matches fieldId, throwing an exception
14759
       * if it is not found.
14760
       */
14761
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14762
        _Fields fields = findByThriftId(fieldId);
14763
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14764
        return fields;
14765
      }
14766
 
14767
      /**
14768
       * Find the _Fields constant that matches name, or null if its not found.
14769
       */
14770
      public static _Fields findByName(String name) {
14771
        return byName.get(name);
14772
      }
14773
 
14774
      private final short _thriftId;
14775
      private final String _fieldName;
14776
 
14777
      _Fields(short thriftId, String fieldName) {
14778
        _thriftId = thriftId;
14779
        _fieldName = fieldName;
14780
      }
14781
 
14782
      public short getThriftFieldId() {
14783
        return _thriftId;
14784
      }
14785
 
14786
      public String getFieldName() {
14787
        return _fieldName;
14788
      }
14789
    }
14790
 
14791
    // isset id assignments
14792
    private static final int __VENDORID_ISSET_ID = 0;
14793
    private BitSet __isset_bit_vector = new BitSet(1);
14794
 
14795
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14796
    static {
14797
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14798
      tmpMap.put(_Fields.LOST_ITEMS, new org.apache.thrift.meta_data.FieldMetaData("lostItems", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14799
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
14800
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class))));
14801
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14802
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14803
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14804
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForLostItem_args.class, metaDataMap);
14805
    }
14806
 
14807
    public scanForLostItem_args() {
14808
    }
14809
 
14810
    public scanForLostItem_args(
14811
      List<InventoryItem> lostItems,
14812
      long vendorId)
14813
    {
14814
      this();
14815
      this.lostItems = lostItems;
14816
      this.vendorId = vendorId;
14817
      setVendorIdIsSet(true);
14818
    }
14819
 
14820
    /**
14821
     * Performs a deep copy on <i>other</i>.
14822
     */
14823
    public scanForLostItem_args(scanForLostItem_args other) {
14824
      __isset_bit_vector.clear();
14825
      __isset_bit_vector.or(other.__isset_bit_vector);
14826
      if (other.isSetLostItems()) {
14827
        List<InventoryItem> __this__lostItems = new ArrayList<InventoryItem>();
14828
        for (InventoryItem other_element : other.lostItems) {
14829
          __this__lostItems.add(new InventoryItem(other_element));
14830
        }
14831
        this.lostItems = __this__lostItems;
14832
      }
14833
      this.vendorId = other.vendorId;
14834
    }
14835
 
14836
    public scanForLostItem_args deepCopy() {
14837
      return new scanForLostItem_args(this);
14838
    }
14839
 
14840
    @Override
14841
    public void clear() {
14842
      this.lostItems = null;
14843
      setVendorIdIsSet(false);
14844
      this.vendorId = 0;
14845
    }
14846
 
14847
    public int getLostItemsSize() {
14848
      return (this.lostItems == null) ? 0 : this.lostItems.size();
14849
    }
14850
 
14851
    public java.util.Iterator<InventoryItem> getLostItemsIterator() {
14852
      return (this.lostItems == null) ? null : this.lostItems.iterator();
14853
    }
14854
 
14855
    public void addToLostItems(InventoryItem elem) {
14856
      if (this.lostItems == null) {
14857
        this.lostItems = new ArrayList<InventoryItem>();
14858
      }
14859
      this.lostItems.add(elem);
14860
    }
14861
 
14862
    public List<InventoryItem> getLostItems() {
14863
      return this.lostItems;
14864
    }
14865
 
14866
    public void setLostItems(List<InventoryItem> lostItems) {
14867
      this.lostItems = lostItems;
14868
    }
14869
 
14870
    public void unsetLostItems() {
14871
      this.lostItems = null;
14872
    }
14873
 
14874
    /** Returns true if field lostItems is set (has been assigned a value) and false otherwise */
14875
    public boolean isSetLostItems() {
14876
      return this.lostItems != null;
14877
    }
14878
 
14879
    public void setLostItemsIsSet(boolean value) {
14880
      if (!value) {
14881
        this.lostItems = null;
14882
      }
14883
    }
14884
 
14885
    public long getVendorId() {
14886
      return this.vendorId;
14887
    }
14888
 
14889
    public void setVendorId(long vendorId) {
14890
      this.vendorId = vendorId;
14891
      setVendorIdIsSet(true);
14892
    }
14893
 
14894
    public void unsetVendorId() {
14895
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
14896
    }
14897
 
14898
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
14899
    public boolean isSetVendorId() {
14900
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
14901
    }
14902
 
14903
    public void setVendorIdIsSet(boolean value) {
14904
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
14905
    }
14906
 
14907
    public void setFieldValue(_Fields field, Object value) {
14908
      switch (field) {
14909
      case LOST_ITEMS:
14910
        if (value == null) {
14911
          unsetLostItems();
14912
        } else {
14913
          setLostItems((List<InventoryItem>)value);
14914
        }
14915
        break;
14916
 
14917
      case VENDOR_ID:
14918
        if (value == null) {
14919
          unsetVendorId();
14920
        } else {
14921
          setVendorId((Long)value);
14922
        }
14923
        break;
14924
 
14925
      }
14926
    }
14927
 
14928
    public Object getFieldValue(_Fields field) {
14929
      switch (field) {
14930
      case LOST_ITEMS:
14931
        return getLostItems();
14932
 
14933
      case VENDOR_ID:
14934
        return Long.valueOf(getVendorId());
14935
 
14936
      }
14937
      throw new IllegalStateException();
14938
    }
14939
 
14940
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14941
    public boolean isSet(_Fields field) {
14942
      if (field == null) {
14943
        throw new IllegalArgumentException();
14944
      }
14945
 
14946
      switch (field) {
14947
      case LOST_ITEMS:
14948
        return isSetLostItems();
14949
      case VENDOR_ID:
14950
        return isSetVendorId();
14951
      }
14952
      throw new IllegalStateException();
14953
    }
14954
 
14955
    @Override
14956
    public boolean equals(Object that) {
14957
      if (that == null)
14958
        return false;
14959
      if (that instanceof scanForLostItem_args)
14960
        return this.equals((scanForLostItem_args)that);
14961
      return false;
14962
    }
14963
 
14964
    public boolean equals(scanForLostItem_args that) {
14965
      if (that == null)
14966
        return false;
14967
 
14968
      boolean this_present_lostItems = true && this.isSetLostItems();
14969
      boolean that_present_lostItems = true && that.isSetLostItems();
14970
      if (this_present_lostItems || that_present_lostItems) {
14971
        if (!(this_present_lostItems && that_present_lostItems))
14972
          return false;
14973
        if (!this.lostItems.equals(that.lostItems))
14974
          return false;
14975
      }
14976
 
14977
      boolean this_present_vendorId = true;
14978
      boolean that_present_vendorId = true;
14979
      if (this_present_vendorId || that_present_vendorId) {
14980
        if (!(this_present_vendorId && that_present_vendorId))
14981
          return false;
14982
        if (this.vendorId != that.vendorId)
14983
          return false;
14984
      }
14985
 
14986
      return true;
14987
    }
14988
 
14989
    @Override
14990
    public int hashCode() {
14991
      return 0;
14992
    }
14993
 
14994
    public int compareTo(scanForLostItem_args other) {
14995
      if (!getClass().equals(other.getClass())) {
14996
        return getClass().getName().compareTo(other.getClass().getName());
14997
      }
14998
 
14999
      int lastComparison = 0;
15000
      scanForLostItem_args typedOther = (scanForLostItem_args)other;
15001
 
15002
      lastComparison = Boolean.valueOf(isSetLostItems()).compareTo(typedOther.isSetLostItems());
15003
      if (lastComparison != 0) {
15004
        return lastComparison;
15005
      }
15006
      if (isSetLostItems()) {
15007
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.lostItems, typedOther.lostItems);
15008
        if (lastComparison != 0) {
15009
          return lastComparison;
15010
        }
15011
      }
15012
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
15013
      if (lastComparison != 0) {
15014
        return lastComparison;
15015
      }
15016
      if (isSetVendorId()) {
15017
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
15018
        if (lastComparison != 0) {
15019
          return lastComparison;
15020
        }
15021
      }
15022
      return 0;
15023
    }
15024
 
15025
    public _Fields fieldForId(int fieldId) {
15026
      return _Fields.findByThriftId(fieldId);
15027
    }
15028
 
15029
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15030
      org.apache.thrift.protocol.TField field;
15031
      iprot.readStructBegin();
15032
      while (true)
15033
      {
15034
        field = iprot.readFieldBegin();
15035
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15036
          break;
15037
        }
15038
        switch (field.id) {
15039
          case 1: // LOST_ITEMS
15040
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
15041
              {
15042
                org.apache.thrift.protocol.TList _list36 = iprot.readListBegin();
15043
                this.lostItems = new ArrayList<InventoryItem>(_list36.size);
15044
                for (int _i37 = 0; _i37 < _list36.size; ++_i37)
15045
                {
15046
                  InventoryItem _elem38; // required
15047
                  _elem38 = new InventoryItem();
15048
                  _elem38.read(iprot);
15049
                  this.lostItems.add(_elem38);
15050
                }
15051
                iprot.readListEnd();
15052
              }
15053
            } else { 
15054
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15055
            }
15056
            break;
15057
          case 2: // VENDOR_ID
15058
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15059
              this.vendorId = iprot.readI64();
15060
              setVendorIdIsSet(true);
15061
            } else { 
15062
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15063
            }
15064
            break;
15065
          default:
15066
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15067
        }
15068
        iprot.readFieldEnd();
15069
      }
15070
      iprot.readStructEnd();
15071
      validate();
15072
    }
15073
 
15074
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15075
      validate();
15076
 
15077
      oprot.writeStructBegin(STRUCT_DESC);
15078
      if (this.lostItems != null) {
15079
        oprot.writeFieldBegin(LOST_ITEMS_FIELD_DESC);
15080
        {
15081
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.lostItems.size()));
15082
          for (InventoryItem _iter39 : this.lostItems)
15083
          {
15084
            _iter39.write(oprot);
15085
          }
15086
          oprot.writeListEnd();
15087
        }
15088
        oprot.writeFieldEnd();
15089
      }
15090
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
15091
      oprot.writeI64(this.vendorId);
15092
      oprot.writeFieldEnd();
15093
      oprot.writeFieldStop();
15094
      oprot.writeStructEnd();
15095
    }
15096
 
15097
    @Override
15098
    public String toString() {
15099
      StringBuilder sb = new StringBuilder("scanForLostItem_args(");
15100
      boolean first = true;
15101
 
15102
      sb.append("lostItems:");
15103
      if (this.lostItems == null) {
15104
        sb.append("null");
15105
      } else {
15106
        sb.append(this.lostItems);
15107
      }
15108
      first = false;
15109
      if (!first) sb.append(", ");
15110
      sb.append("vendorId:");
15111
      sb.append(this.vendorId);
15112
      first = false;
15113
      sb.append(")");
15114
      return sb.toString();
15115
    }
15116
 
15117
    public void validate() throws org.apache.thrift.TException {
15118
      // check for required fields
15119
    }
15120
 
15121
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15122
      try {
15123
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15124
      } catch (org.apache.thrift.TException te) {
15125
        throw new java.io.IOException(te);
15126
      }
15127
    }
15128
 
15129
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15130
      try {
15131
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15132
      } catch (org.apache.thrift.TException te) {
15133
        throw new java.io.IOException(te);
15134
      }
15135
    }
15136
 
15137
  }
15138
 
15139
  public static class scanForLostItem_result implements org.apache.thrift.TBase<scanForLostItem_result, scanForLostItem_result._Fields>, java.io.Serializable, Cloneable   {
15140
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForLostItem_result");
15141
 
15142
    private static final org.apache.thrift.protocol.TField EX_FIELD_DESC = new org.apache.thrift.protocol.TField("ex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
15143
 
15144
    private WarehouseServiceException ex; // required
15145
 
15146
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15147
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15148
      EX((short)1, "ex");
15149
 
15150
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15151
 
15152
      static {
15153
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15154
          byName.put(field.getFieldName(), field);
15155
        }
15156
      }
15157
 
15158
      /**
15159
       * Find the _Fields constant that matches fieldId, or null if its not found.
15160
       */
15161
      public static _Fields findByThriftId(int fieldId) {
15162
        switch(fieldId) {
15163
          case 1: // EX
15164
            return EX;
15165
          default:
15166
            return null;
15167
        }
15168
      }
15169
 
15170
      /**
15171
       * Find the _Fields constant that matches fieldId, throwing an exception
15172
       * if it is not found.
15173
       */
15174
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15175
        _Fields fields = findByThriftId(fieldId);
15176
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15177
        return fields;
15178
      }
15179
 
15180
      /**
15181
       * Find the _Fields constant that matches name, or null if its not found.
15182
       */
15183
      public static _Fields findByName(String name) {
15184
        return byName.get(name);
15185
      }
15186
 
15187
      private final short _thriftId;
15188
      private final String _fieldName;
15189
 
15190
      _Fields(short thriftId, String fieldName) {
15191
        _thriftId = thriftId;
15192
        _fieldName = fieldName;
15193
      }
15194
 
15195
      public short getThriftFieldId() {
15196
        return _thriftId;
15197
      }
15198
 
15199
      public String getFieldName() {
15200
        return _fieldName;
15201
      }
15202
    }
15203
 
15204
    // isset id assignments
15205
 
15206
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15207
    static {
15208
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15209
      tmpMap.put(_Fields.EX, new org.apache.thrift.meta_data.FieldMetaData("ex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15210
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
15211
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15212
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForLostItem_result.class, metaDataMap);
15213
    }
15214
 
15215
    public scanForLostItem_result() {
15216
    }
15217
 
15218
    public scanForLostItem_result(
15219
      WarehouseServiceException ex)
15220
    {
15221
      this();
15222
      this.ex = ex;
15223
    }
15224
 
15225
    /**
15226
     * Performs a deep copy on <i>other</i>.
15227
     */
15228
    public scanForLostItem_result(scanForLostItem_result other) {
15229
      if (other.isSetEx()) {
15230
        this.ex = new WarehouseServiceException(other.ex);
15231
      }
15232
    }
15233
 
15234
    public scanForLostItem_result deepCopy() {
15235
      return new scanForLostItem_result(this);
15236
    }
15237
 
15238
    @Override
15239
    public void clear() {
15240
      this.ex = null;
15241
    }
15242
 
15243
    public WarehouseServiceException getEx() {
15244
      return this.ex;
15245
    }
15246
 
15247
    public void setEx(WarehouseServiceException ex) {
15248
      this.ex = ex;
15249
    }
15250
 
15251
    public void unsetEx() {
15252
      this.ex = null;
15253
    }
15254
 
15255
    /** Returns true if field ex is set (has been assigned a value) and false otherwise */
15256
    public boolean isSetEx() {
15257
      return this.ex != null;
15258
    }
15259
 
15260
    public void setExIsSet(boolean value) {
15261
      if (!value) {
15262
        this.ex = null;
15263
      }
15264
    }
15265
 
15266
    public void setFieldValue(_Fields field, Object value) {
15267
      switch (field) {
15268
      case EX:
15269
        if (value == null) {
15270
          unsetEx();
15271
        } else {
15272
          setEx((WarehouseServiceException)value);
15273
        }
15274
        break;
15275
 
15276
      }
15277
    }
15278
 
15279
    public Object getFieldValue(_Fields field) {
15280
      switch (field) {
15281
      case EX:
15282
        return getEx();
15283
 
15284
      }
15285
      throw new IllegalStateException();
15286
    }
15287
 
15288
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15289
    public boolean isSet(_Fields field) {
15290
      if (field == null) {
15291
        throw new IllegalArgumentException();
15292
      }
15293
 
15294
      switch (field) {
15295
      case EX:
15296
        return isSetEx();
15297
      }
15298
      throw new IllegalStateException();
15299
    }
15300
 
15301
    @Override
15302
    public boolean equals(Object that) {
15303
      if (that == null)
15304
        return false;
15305
      if (that instanceof scanForLostItem_result)
15306
        return this.equals((scanForLostItem_result)that);
15307
      return false;
15308
    }
15309
 
15310
    public boolean equals(scanForLostItem_result that) {
15311
      if (that == null)
15312
        return false;
15313
 
15314
      boolean this_present_ex = true && this.isSetEx();
15315
      boolean that_present_ex = true && that.isSetEx();
15316
      if (this_present_ex || that_present_ex) {
15317
        if (!(this_present_ex && that_present_ex))
15318
          return false;
15319
        if (!this.ex.equals(that.ex))
15320
          return false;
15321
      }
15322
 
15323
      return true;
15324
    }
15325
 
15326
    @Override
15327
    public int hashCode() {
15328
      return 0;
15329
    }
15330
 
15331
    public int compareTo(scanForLostItem_result other) {
15332
      if (!getClass().equals(other.getClass())) {
15333
        return getClass().getName().compareTo(other.getClass().getName());
15334
      }
15335
 
15336
      int lastComparison = 0;
15337
      scanForLostItem_result typedOther = (scanForLostItem_result)other;
15338
 
15339
      lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx());
15340
      if (lastComparison != 0) {
15341
        return lastComparison;
15342
      }
15343
      if (isSetEx()) {
15344
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex);
15345
        if (lastComparison != 0) {
15346
          return lastComparison;
15347
        }
15348
      }
15349
      return 0;
15350
    }
15351
 
15352
    public _Fields fieldForId(int fieldId) {
15353
      return _Fields.findByThriftId(fieldId);
15354
    }
15355
 
15356
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15357
      org.apache.thrift.protocol.TField field;
15358
      iprot.readStructBegin();
15359
      while (true)
15360
      {
15361
        field = iprot.readFieldBegin();
15362
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15363
          break;
15364
        }
15365
        switch (field.id) {
15366
          case 1: // EX
15367
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15368
              this.ex = new WarehouseServiceException();
15369
              this.ex.read(iprot);
15370
            } else { 
15371
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15372
            }
15373
            break;
15374
          default:
15375
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15376
        }
15377
        iprot.readFieldEnd();
15378
      }
15379
      iprot.readStructEnd();
15380
      validate();
15381
    }
15382
 
15383
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15384
      oprot.writeStructBegin(STRUCT_DESC);
15385
 
15386
      if (this.isSetEx()) {
15387
        oprot.writeFieldBegin(EX_FIELD_DESC);
15388
        this.ex.write(oprot);
15389
        oprot.writeFieldEnd();
15390
      }
15391
      oprot.writeFieldStop();
15392
      oprot.writeStructEnd();
15393
    }
15394
 
15395
    @Override
15396
    public String toString() {
15397
      StringBuilder sb = new StringBuilder("scanForLostItem_result(");
15398
      boolean first = true;
15399
 
15400
      sb.append("ex:");
15401
      if (this.ex == null) {
15402
        sb.append("null");
15403
      } else {
15404
        sb.append(this.ex);
15405
      }
15406
      first = false;
15407
      sb.append(")");
15408
      return sb.toString();
15409
    }
15410
 
15411
    public void validate() throws org.apache.thrift.TException {
15412
      // check for required fields
15413
    }
15414
 
15415
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15416
      try {
15417
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15418
      } catch (org.apache.thrift.TException te) {
15419
        throw new java.io.IOException(te);
15420
      }
15421
    }
15422
 
15423
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15424
      try {
15425
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15426
      } catch (org.apache.thrift.TException te) {
15427
        throw new java.io.IOException(te);
15428
      }
15429
    }
15430
 
15431
  }
15432
 
15433
  public static class getCurrentSerializedInventoryByScans_args implements org.apache.thrift.TBase<getCurrentSerializedInventoryByScans_args, getCurrentSerializedInventoryByScans_args._Fields>, java.io.Serializable, Cloneable   {
15434
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getCurrentSerializedInventoryByScans_args");
15435
 
15436
 
15437
 
15438
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15439
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15440
;
15441
 
15442
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15443
 
15444
      static {
15445
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15446
          byName.put(field.getFieldName(), field);
15447
        }
15448
      }
15449
 
15450
      /**
15451
       * Find the _Fields constant that matches fieldId, or null if its not found.
15452
       */
15453
      public static _Fields findByThriftId(int fieldId) {
15454
        switch(fieldId) {
15455
          default:
15456
            return null;
15457
        }
15458
      }
15459
 
15460
      /**
15461
       * Find the _Fields constant that matches fieldId, throwing an exception
15462
       * if it is not found.
15463
       */
15464
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15465
        _Fields fields = findByThriftId(fieldId);
15466
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15467
        return fields;
15468
      }
15469
 
15470
      /**
15471
       * Find the _Fields constant that matches name, or null if its not found.
15472
       */
15473
      public static _Fields findByName(String name) {
15474
        return byName.get(name);
15475
      }
15476
 
15477
      private final short _thriftId;
15478
      private final String _fieldName;
15479
 
15480
      _Fields(short thriftId, String fieldName) {
15481
        _thriftId = thriftId;
15482
        _fieldName = fieldName;
15483
      }
15484
 
15485
      public short getThriftFieldId() {
15486
        return _thriftId;
15487
      }
15488
 
15489
      public String getFieldName() {
15490
        return _fieldName;
15491
      }
15492
    }
15493
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15494
    static {
15495
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15496
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15497
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getCurrentSerializedInventoryByScans_args.class, metaDataMap);
15498
    }
15499
 
15500
    public getCurrentSerializedInventoryByScans_args() {
15501
    }
15502
 
15503
    /**
15504
     * Performs a deep copy on <i>other</i>.
15505
     */
15506
    public getCurrentSerializedInventoryByScans_args(getCurrentSerializedInventoryByScans_args other) {
15507
    }
15508
 
15509
    public getCurrentSerializedInventoryByScans_args deepCopy() {
15510
      return new getCurrentSerializedInventoryByScans_args(this);
15511
    }
15512
 
15513
    @Override
15514
    public void clear() {
15515
    }
15516
 
15517
    public void setFieldValue(_Fields field, Object value) {
15518
      switch (field) {
15519
      }
15520
    }
15521
 
15522
    public Object getFieldValue(_Fields field) {
15523
      switch (field) {
15524
      }
15525
      throw new IllegalStateException();
15526
    }
15527
 
15528
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15529
    public boolean isSet(_Fields field) {
15530
      if (field == null) {
15531
        throw new IllegalArgumentException();
15532
      }
15533
 
15534
      switch (field) {
15535
      }
15536
      throw new IllegalStateException();
15537
    }
15538
 
15539
    @Override
15540
    public boolean equals(Object that) {
15541
      if (that == null)
15542
        return false;
15543
      if (that instanceof getCurrentSerializedInventoryByScans_args)
15544
        return this.equals((getCurrentSerializedInventoryByScans_args)that);
15545
      return false;
15546
    }
15547
 
15548
    public boolean equals(getCurrentSerializedInventoryByScans_args that) {
15549
      if (that == null)
15550
        return false;
15551
 
15552
      return true;
15553
    }
15554
 
15555
    @Override
15556
    public int hashCode() {
15557
      return 0;
15558
    }
15559
 
15560
    public int compareTo(getCurrentSerializedInventoryByScans_args other) {
15561
      if (!getClass().equals(other.getClass())) {
15562
        return getClass().getName().compareTo(other.getClass().getName());
15563
      }
15564
 
15565
      int lastComparison = 0;
15566
      getCurrentSerializedInventoryByScans_args typedOther = (getCurrentSerializedInventoryByScans_args)other;
15567
 
15568
      return 0;
15569
    }
15570
 
15571
    public _Fields fieldForId(int fieldId) {
15572
      return _Fields.findByThriftId(fieldId);
15573
    }
15574
 
15575
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15576
      org.apache.thrift.protocol.TField field;
15577
      iprot.readStructBegin();
15578
      while (true)
15579
      {
15580
        field = iprot.readFieldBegin();
15581
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15582
          break;
15583
        }
15584
        switch (field.id) {
15585
          default:
15586
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15587
        }
15588
        iprot.readFieldEnd();
15589
      }
15590
      iprot.readStructEnd();
15591
      validate();
15592
    }
15593
 
15594
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15595
      validate();
15596
 
15597
      oprot.writeStructBegin(STRUCT_DESC);
15598
      oprot.writeFieldStop();
15599
      oprot.writeStructEnd();
15600
    }
15601
 
15602
    @Override
15603
    public String toString() {
15604
      StringBuilder sb = new StringBuilder("getCurrentSerializedInventoryByScans_args(");
15605
      boolean first = true;
15606
 
15607
      sb.append(")");
15608
      return sb.toString();
15609
    }
15610
 
15611
    public void validate() throws org.apache.thrift.TException {
15612
      // check for required fields
15613
    }
15614
 
15615
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15616
      try {
15617
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15618
      } catch (org.apache.thrift.TException te) {
15619
        throw new java.io.IOException(te);
15620
      }
15621
    }
15622
 
15623
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15624
      try {
15625
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15626
      } catch (org.apache.thrift.TException te) {
15627
        throw new java.io.IOException(te);
15628
      }
15629
    }
15630
 
15631
  }
15632
 
15633
  public static class getCurrentSerializedInventoryByScans_result implements org.apache.thrift.TBase<getCurrentSerializedInventoryByScans_result, getCurrentSerializedInventoryByScans_result._Fields>, java.io.Serializable, Cloneable   {
15634
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getCurrentSerializedInventoryByScans_result");
15635
 
15636
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
15637
 
15638
    private List<InventoryAvailability> success; // required
15639
 
15640
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15641
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15642
      SUCCESS((short)0, "success");
15643
 
15644
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15645
 
15646
      static {
15647
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15648
          byName.put(field.getFieldName(), field);
15649
        }
15650
      }
15651
 
15652
      /**
15653
       * Find the _Fields constant that matches fieldId, or null if its not found.
15654
       */
15655
      public static _Fields findByThriftId(int fieldId) {
15656
        switch(fieldId) {
15657
          case 0: // SUCCESS
15658
            return SUCCESS;
15659
          default:
15660
            return null;
15661
        }
15662
      }
15663
 
15664
      /**
15665
       * Find the _Fields constant that matches fieldId, throwing an exception
15666
       * if it is not found.
15667
       */
15668
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15669
        _Fields fields = findByThriftId(fieldId);
15670
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15671
        return fields;
15672
      }
15673
 
15674
      /**
15675
       * Find the _Fields constant that matches name, or null if its not found.
15676
       */
15677
      public static _Fields findByName(String name) {
15678
        return byName.get(name);
15679
      }
15680
 
15681
      private final short _thriftId;
15682
      private final String _fieldName;
15683
 
15684
      _Fields(short thriftId, String fieldName) {
15685
        _thriftId = thriftId;
15686
        _fieldName = fieldName;
15687
      }
15688
 
15689
      public short getThriftFieldId() {
15690
        return _thriftId;
15691
      }
15692
 
15693
      public String getFieldName() {
15694
        return _fieldName;
15695
      }
15696
    }
15697
 
15698
    // isset id assignments
15699
 
15700
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15701
    static {
15702
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15703
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15704
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
15705
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryAvailability.class))));
15706
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15707
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getCurrentSerializedInventoryByScans_result.class, metaDataMap);
15708
    }
15709
 
15710
    public getCurrentSerializedInventoryByScans_result() {
15711
    }
15712
 
15713
    public getCurrentSerializedInventoryByScans_result(
15714
      List<InventoryAvailability> success)
15715
    {
15716
      this();
15717
      this.success = success;
15718
    }
15719
 
15720
    /**
15721
     * Performs a deep copy on <i>other</i>.
15722
     */
15723
    public getCurrentSerializedInventoryByScans_result(getCurrentSerializedInventoryByScans_result other) {
15724
      if (other.isSetSuccess()) {
15725
        List<InventoryAvailability> __this__success = new ArrayList<InventoryAvailability>();
15726
        for (InventoryAvailability other_element : other.success) {
15727
          __this__success.add(new InventoryAvailability(other_element));
15728
        }
15729
        this.success = __this__success;
15730
      }
15731
    }
15732
 
15733
    public getCurrentSerializedInventoryByScans_result deepCopy() {
15734
      return new getCurrentSerializedInventoryByScans_result(this);
15735
    }
15736
 
15737
    @Override
15738
    public void clear() {
15739
      this.success = null;
15740
    }
15741
 
15742
    public int getSuccessSize() {
15743
      return (this.success == null) ? 0 : this.success.size();
15744
    }
15745
 
15746
    public java.util.Iterator<InventoryAvailability> getSuccessIterator() {
15747
      return (this.success == null) ? null : this.success.iterator();
15748
    }
15749
 
15750
    public void addToSuccess(InventoryAvailability elem) {
15751
      if (this.success == null) {
15752
        this.success = new ArrayList<InventoryAvailability>();
15753
      }
15754
      this.success.add(elem);
15755
    }
15756
 
15757
    public List<InventoryAvailability> getSuccess() {
15758
      return this.success;
15759
    }
15760
 
15761
    public void setSuccess(List<InventoryAvailability> success) {
15762
      this.success = success;
15763
    }
15764
 
15765
    public void unsetSuccess() {
15766
      this.success = null;
15767
    }
15768
 
15769
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
15770
    public boolean isSetSuccess() {
15771
      return this.success != null;
15772
    }
15773
 
15774
    public void setSuccessIsSet(boolean value) {
15775
      if (!value) {
15776
        this.success = null;
15777
      }
15778
    }
15779
 
15780
    public void setFieldValue(_Fields field, Object value) {
15781
      switch (field) {
15782
      case SUCCESS:
15783
        if (value == null) {
15784
          unsetSuccess();
15785
        } else {
15786
          setSuccess((List<InventoryAvailability>)value);
15787
        }
15788
        break;
15789
 
15790
      }
15791
    }
15792
 
15793
    public Object getFieldValue(_Fields field) {
15794
      switch (field) {
15795
      case SUCCESS:
15796
        return getSuccess();
15797
 
15798
      }
15799
      throw new IllegalStateException();
15800
    }
15801
 
15802
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15803
    public boolean isSet(_Fields field) {
15804
      if (field == null) {
15805
        throw new IllegalArgumentException();
15806
      }
15807
 
15808
      switch (field) {
15809
      case SUCCESS:
15810
        return isSetSuccess();
15811
      }
15812
      throw new IllegalStateException();
15813
    }
15814
 
15815
    @Override
15816
    public boolean equals(Object that) {
15817
      if (that == null)
15818
        return false;
15819
      if (that instanceof getCurrentSerializedInventoryByScans_result)
15820
        return this.equals((getCurrentSerializedInventoryByScans_result)that);
15821
      return false;
15822
    }
15823
 
15824
    public boolean equals(getCurrentSerializedInventoryByScans_result that) {
15825
      if (that == null)
15826
        return false;
15827
 
15828
      boolean this_present_success = true && this.isSetSuccess();
15829
      boolean that_present_success = true && that.isSetSuccess();
15830
      if (this_present_success || that_present_success) {
15831
        if (!(this_present_success && that_present_success))
15832
          return false;
15833
        if (!this.success.equals(that.success))
15834
          return false;
15835
      }
15836
 
15837
      return true;
15838
    }
15839
 
15840
    @Override
15841
    public int hashCode() {
15842
      return 0;
15843
    }
15844
 
15845
    public int compareTo(getCurrentSerializedInventoryByScans_result other) {
15846
      if (!getClass().equals(other.getClass())) {
15847
        return getClass().getName().compareTo(other.getClass().getName());
15848
      }
15849
 
15850
      int lastComparison = 0;
15851
      getCurrentSerializedInventoryByScans_result typedOther = (getCurrentSerializedInventoryByScans_result)other;
15852
 
15853
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
15854
      if (lastComparison != 0) {
15855
        return lastComparison;
15856
      }
15857
      if (isSetSuccess()) {
15858
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
15859
        if (lastComparison != 0) {
15860
          return lastComparison;
15861
        }
15862
      }
15863
      return 0;
15864
    }
15865
 
15866
    public _Fields fieldForId(int fieldId) {
15867
      return _Fields.findByThriftId(fieldId);
15868
    }
15869
 
15870
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15871
      org.apache.thrift.protocol.TField field;
15872
      iprot.readStructBegin();
15873
      while (true)
15874
      {
15875
        field = iprot.readFieldBegin();
15876
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15877
          break;
15878
        }
15879
        switch (field.id) {
15880
          case 0: // SUCCESS
15881
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
15882
              {
15883
                org.apache.thrift.protocol.TList _list40 = iprot.readListBegin();
15884
                this.success = new ArrayList<InventoryAvailability>(_list40.size);
15885
                for (int _i41 = 0; _i41 < _list40.size; ++_i41)
15886
                {
15887
                  InventoryAvailability _elem42; // required
15888
                  _elem42 = new InventoryAvailability();
15889
                  _elem42.read(iprot);
15890
                  this.success.add(_elem42);
15891
                }
15892
                iprot.readListEnd();
15893
              }
15894
            } else { 
15895
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15896
            }
15897
            break;
15898
          default:
15899
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15900
        }
15901
        iprot.readFieldEnd();
15902
      }
15903
      iprot.readStructEnd();
15904
      validate();
15905
    }
15906
 
15907
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15908
      oprot.writeStructBegin(STRUCT_DESC);
15909
 
15910
      if (this.isSetSuccess()) {
15911
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
15912
        {
15913
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
15914
          for (InventoryAvailability _iter43 : this.success)
15915
          {
15916
            _iter43.write(oprot);
15917
          }
15918
          oprot.writeListEnd();
15919
        }
15920
        oprot.writeFieldEnd();
15921
      }
15922
      oprot.writeFieldStop();
15923
      oprot.writeStructEnd();
15924
    }
15925
 
15926
    @Override
15927
    public String toString() {
15928
      StringBuilder sb = new StringBuilder("getCurrentSerializedInventoryByScans_result(");
15929
      boolean first = true;
15930
 
15931
      sb.append("success:");
15932
      if (this.success == null) {
15933
        sb.append("null");
15934
      } else {
15935
        sb.append(this.success);
15936
      }
15937
      first = false;
15938
      sb.append(")");
15939
      return sb.toString();
15940
    }
15941
 
15942
    public void validate() throws org.apache.thrift.TException {
15943
      // check for required fields
15944
    }
15945
 
15946
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15947
      try {
15948
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15949
      } catch (org.apache.thrift.TException te) {
15950
        throw new java.io.IOException(te);
15951
      }
15952
    }
15953
 
15954
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15955
      try {
15956
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15957
      } catch (org.apache.thrift.TException te) {
15958
        throw new java.io.IOException(te);
15959
      }
15960
    }
15961
 
15962
  }
15963
 
6630 amar.kumar 15964
  public static class getCurrentNonSerializedInventoryByScans_args implements org.apache.thrift.TBase<getCurrentNonSerializedInventoryByScans_args, getCurrentNonSerializedInventoryByScans_args._Fields>, java.io.Serializable, Cloneable   {
15965
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getCurrentNonSerializedInventoryByScans_args");
15966
 
15967
 
15968
 
15969
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15970
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15971
;
15972
 
15973
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15974
 
15975
      static {
15976
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15977
          byName.put(field.getFieldName(), field);
15978
        }
15979
      }
15980
 
15981
      /**
15982
       * Find the _Fields constant that matches fieldId, or null if its not found.
15983
       */
15984
      public static _Fields findByThriftId(int fieldId) {
15985
        switch(fieldId) {
15986
          default:
15987
            return null;
15988
        }
15989
      }
15990
 
15991
      /**
15992
       * Find the _Fields constant that matches fieldId, throwing an exception
15993
       * if it is not found.
15994
       */
15995
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15996
        _Fields fields = findByThriftId(fieldId);
15997
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15998
        return fields;
15999
      }
16000
 
16001
      /**
16002
       * Find the _Fields constant that matches name, or null if its not found.
16003
       */
16004
      public static _Fields findByName(String name) {
16005
        return byName.get(name);
16006
      }
16007
 
16008
      private final short _thriftId;
16009
      private final String _fieldName;
16010
 
16011
      _Fields(short thriftId, String fieldName) {
16012
        _thriftId = thriftId;
16013
        _fieldName = fieldName;
16014
      }
16015
 
16016
      public short getThriftFieldId() {
16017
        return _thriftId;
16018
      }
16019
 
16020
      public String getFieldName() {
16021
        return _fieldName;
16022
      }
16023
    }
16024
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16025
    static {
16026
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16027
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16028
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getCurrentNonSerializedInventoryByScans_args.class, metaDataMap);
16029
    }
16030
 
16031
    public getCurrentNonSerializedInventoryByScans_args() {
16032
    }
16033
 
16034
    /**
16035
     * Performs a deep copy on <i>other</i>.
16036
     */
16037
    public getCurrentNonSerializedInventoryByScans_args(getCurrentNonSerializedInventoryByScans_args other) {
16038
    }
16039
 
16040
    public getCurrentNonSerializedInventoryByScans_args deepCopy() {
16041
      return new getCurrentNonSerializedInventoryByScans_args(this);
16042
    }
16043
 
16044
    @Override
16045
    public void clear() {
16046
    }
16047
 
16048
    public void setFieldValue(_Fields field, Object value) {
16049
      switch (field) {
16050
      }
16051
    }
16052
 
16053
    public Object getFieldValue(_Fields field) {
16054
      switch (field) {
16055
      }
16056
      throw new IllegalStateException();
16057
    }
16058
 
16059
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16060
    public boolean isSet(_Fields field) {
16061
      if (field == null) {
16062
        throw new IllegalArgumentException();
16063
      }
16064
 
16065
      switch (field) {
16066
      }
16067
      throw new IllegalStateException();
16068
    }
16069
 
16070
    @Override
16071
    public boolean equals(Object that) {
16072
      if (that == null)
16073
        return false;
16074
      if (that instanceof getCurrentNonSerializedInventoryByScans_args)
16075
        return this.equals((getCurrentNonSerializedInventoryByScans_args)that);
16076
      return false;
16077
    }
16078
 
16079
    public boolean equals(getCurrentNonSerializedInventoryByScans_args that) {
16080
      if (that == null)
16081
        return false;
16082
 
16083
      return true;
16084
    }
16085
 
16086
    @Override
16087
    public int hashCode() {
16088
      return 0;
16089
    }
16090
 
16091
    public int compareTo(getCurrentNonSerializedInventoryByScans_args other) {
16092
      if (!getClass().equals(other.getClass())) {
16093
        return getClass().getName().compareTo(other.getClass().getName());
16094
      }
16095
 
16096
      int lastComparison = 0;
16097
      getCurrentNonSerializedInventoryByScans_args typedOther = (getCurrentNonSerializedInventoryByScans_args)other;
16098
 
16099
      return 0;
16100
    }
16101
 
16102
    public _Fields fieldForId(int fieldId) {
16103
      return _Fields.findByThriftId(fieldId);
16104
    }
16105
 
16106
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16107
      org.apache.thrift.protocol.TField field;
16108
      iprot.readStructBegin();
16109
      while (true)
16110
      {
16111
        field = iprot.readFieldBegin();
16112
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16113
          break;
16114
        }
16115
        switch (field.id) {
16116
          default:
16117
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16118
        }
16119
        iprot.readFieldEnd();
16120
      }
16121
      iprot.readStructEnd();
16122
      validate();
16123
    }
16124
 
16125
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16126
      validate();
16127
 
16128
      oprot.writeStructBegin(STRUCT_DESC);
16129
      oprot.writeFieldStop();
16130
      oprot.writeStructEnd();
16131
    }
16132
 
16133
    @Override
16134
    public String toString() {
16135
      StringBuilder sb = new StringBuilder("getCurrentNonSerializedInventoryByScans_args(");
16136
      boolean first = true;
16137
 
16138
      sb.append(")");
16139
      return sb.toString();
16140
    }
16141
 
16142
    public void validate() throws org.apache.thrift.TException {
16143
      // check for required fields
16144
    }
16145
 
16146
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16147
      try {
16148
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16149
      } catch (org.apache.thrift.TException te) {
16150
        throw new java.io.IOException(te);
16151
      }
16152
    }
16153
 
16154
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16155
      try {
16156
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16157
      } catch (org.apache.thrift.TException te) {
16158
        throw new java.io.IOException(te);
16159
      }
16160
    }
16161
 
16162
  }
16163
 
16164
  public static class getCurrentNonSerializedInventoryByScans_result implements org.apache.thrift.TBase<getCurrentNonSerializedInventoryByScans_result, getCurrentNonSerializedInventoryByScans_result._Fields>, java.io.Serializable, Cloneable   {
16165
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getCurrentNonSerializedInventoryByScans_result");
16166
 
16167
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
16168
 
16169
    private List<InventoryAvailability> success; // required
16170
 
16171
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16172
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16173
      SUCCESS((short)0, "success");
16174
 
16175
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16176
 
16177
      static {
16178
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16179
          byName.put(field.getFieldName(), field);
16180
        }
16181
      }
16182
 
16183
      /**
16184
       * Find the _Fields constant that matches fieldId, or null if its not found.
16185
       */
16186
      public static _Fields findByThriftId(int fieldId) {
16187
        switch(fieldId) {
16188
          case 0: // SUCCESS
16189
            return SUCCESS;
16190
          default:
16191
            return null;
16192
        }
16193
      }
16194
 
16195
      /**
16196
       * Find the _Fields constant that matches fieldId, throwing an exception
16197
       * if it is not found.
16198
       */
16199
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16200
        _Fields fields = findByThriftId(fieldId);
16201
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16202
        return fields;
16203
      }
16204
 
16205
      /**
16206
       * Find the _Fields constant that matches name, or null if its not found.
16207
       */
16208
      public static _Fields findByName(String name) {
16209
        return byName.get(name);
16210
      }
16211
 
16212
      private final short _thriftId;
16213
      private final String _fieldName;
16214
 
16215
      _Fields(short thriftId, String fieldName) {
16216
        _thriftId = thriftId;
16217
        _fieldName = fieldName;
16218
      }
16219
 
16220
      public short getThriftFieldId() {
16221
        return _thriftId;
16222
      }
16223
 
16224
      public String getFieldName() {
16225
        return _fieldName;
16226
      }
16227
    }
16228
 
16229
    // isset id assignments
16230
 
16231
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16232
    static {
16233
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16234
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16235
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
16236
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryAvailability.class))));
16237
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16238
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getCurrentNonSerializedInventoryByScans_result.class, metaDataMap);
16239
    }
16240
 
16241
    public getCurrentNonSerializedInventoryByScans_result() {
16242
    }
16243
 
16244
    public getCurrentNonSerializedInventoryByScans_result(
16245
      List<InventoryAvailability> success)
16246
    {
16247
      this();
16248
      this.success = success;
16249
    }
16250
 
16251
    /**
16252
     * Performs a deep copy on <i>other</i>.
16253
     */
16254
    public getCurrentNonSerializedInventoryByScans_result(getCurrentNonSerializedInventoryByScans_result other) {
16255
      if (other.isSetSuccess()) {
16256
        List<InventoryAvailability> __this__success = new ArrayList<InventoryAvailability>();
16257
        for (InventoryAvailability other_element : other.success) {
16258
          __this__success.add(new InventoryAvailability(other_element));
16259
        }
16260
        this.success = __this__success;
16261
      }
16262
    }
16263
 
16264
    public getCurrentNonSerializedInventoryByScans_result deepCopy() {
16265
      return new getCurrentNonSerializedInventoryByScans_result(this);
16266
    }
16267
 
16268
    @Override
16269
    public void clear() {
16270
      this.success = null;
16271
    }
16272
 
16273
    public int getSuccessSize() {
16274
      return (this.success == null) ? 0 : this.success.size();
16275
    }
16276
 
16277
    public java.util.Iterator<InventoryAvailability> getSuccessIterator() {
16278
      return (this.success == null) ? null : this.success.iterator();
16279
    }
16280
 
16281
    public void addToSuccess(InventoryAvailability elem) {
16282
      if (this.success == null) {
16283
        this.success = new ArrayList<InventoryAvailability>();
16284
      }
16285
      this.success.add(elem);
16286
    }
16287
 
16288
    public List<InventoryAvailability> getSuccess() {
16289
      return this.success;
16290
    }
16291
 
16292
    public void setSuccess(List<InventoryAvailability> success) {
16293
      this.success = success;
16294
    }
16295
 
16296
    public void unsetSuccess() {
16297
      this.success = null;
16298
    }
16299
 
16300
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
16301
    public boolean isSetSuccess() {
16302
      return this.success != null;
16303
    }
16304
 
16305
    public void setSuccessIsSet(boolean value) {
16306
      if (!value) {
16307
        this.success = null;
16308
      }
16309
    }
16310
 
16311
    public void setFieldValue(_Fields field, Object value) {
16312
      switch (field) {
16313
      case SUCCESS:
16314
        if (value == null) {
16315
          unsetSuccess();
16316
        } else {
16317
          setSuccess((List<InventoryAvailability>)value);
16318
        }
16319
        break;
16320
 
16321
      }
16322
    }
16323
 
16324
    public Object getFieldValue(_Fields field) {
16325
      switch (field) {
16326
      case SUCCESS:
16327
        return getSuccess();
16328
 
16329
      }
16330
      throw new IllegalStateException();
16331
    }
16332
 
16333
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16334
    public boolean isSet(_Fields field) {
16335
      if (field == null) {
16336
        throw new IllegalArgumentException();
16337
      }
16338
 
16339
      switch (field) {
16340
      case SUCCESS:
16341
        return isSetSuccess();
16342
      }
16343
      throw new IllegalStateException();
16344
    }
16345
 
16346
    @Override
16347
    public boolean equals(Object that) {
16348
      if (that == null)
16349
        return false;
16350
      if (that instanceof getCurrentNonSerializedInventoryByScans_result)
16351
        return this.equals((getCurrentNonSerializedInventoryByScans_result)that);
16352
      return false;
16353
    }
16354
 
16355
    public boolean equals(getCurrentNonSerializedInventoryByScans_result that) {
16356
      if (that == null)
16357
        return false;
16358
 
16359
      boolean this_present_success = true && this.isSetSuccess();
16360
      boolean that_present_success = true && that.isSetSuccess();
16361
      if (this_present_success || that_present_success) {
16362
        if (!(this_present_success && that_present_success))
16363
          return false;
16364
        if (!this.success.equals(that.success))
16365
          return false;
16366
      }
16367
 
16368
      return true;
16369
    }
16370
 
16371
    @Override
16372
    public int hashCode() {
16373
      return 0;
16374
    }
16375
 
16376
    public int compareTo(getCurrentNonSerializedInventoryByScans_result other) {
16377
      if (!getClass().equals(other.getClass())) {
16378
        return getClass().getName().compareTo(other.getClass().getName());
16379
      }
16380
 
16381
      int lastComparison = 0;
16382
      getCurrentNonSerializedInventoryByScans_result typedOther = (getCurrentNonSerializedInventoryByScans_result)other;
16383
 
16384
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
16385
      if (lastComparison != 0) {
16386
        return lastComparison;
16387
      }
16388
      if (isSetSuccess()) {
16389
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
16390
        if (lastComparison != 0) {
16391
          return lastComparison;
16392
        }
16393
      }
16394
      return 0;
16395
    }
16396
 
16397
    public _Fields fieldForId(int fieldId) {
16398
      return _Fields.findByThriftId(fieldId);
16399
    }
16400
 
16401
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16402
      org.apache.thrift.protocol.TField field;
16403
      iprot.readStructBegin();
16404
      while (true)
16405
      {
16406
        field = iprot.readFieldBegin();
16407
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16408
          break;
16409
        }
16410
        switch (field.id) {
16411
          case 0: // SUCCESS
16412
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
16413
              {
16414
                org.apache.thrift.protocol.TList _list44 = iprot.readListBegin();
16415
                this.success = new ArrayList<InventoryAvailability>(_list44.size);
16416
                for (int _i45 = 0; _i45 < _list44.size; ++_i45)
16417
                {
16418
                  InventoryAvailability _elem46; // required
16419
                  _elem46 = new InventoryAvailability();
16420
                  _elem46.read(iprot);
16421
                  this.success.add(_elem46);
16422
                }
16423
                iprot.readListEnd();
16424
              }
16425
            } else { 
16426
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16427
            }
16428
            break;
16429
          default:
16430
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16431
        }
16432
        iprot.readFieldEnd();
16433
      }
16434
      iprot.readStructEnd();
16435
      validate();
16436
    }
16437
 
16438
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16439
      oprot.writeStructBegin(STRUCT_DESC);
16440
 
16441
      if (this.isSetSuccess()) {
16442
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
16443
        {
16444
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
16445
          for (InventoryAvailability _iter47 : this.success)
16446
          {
16447
            _iter47.write(oprot);
16448
          }
16449
          oprot.writeListEnd();
16450
        }
16451
        oprot.writeFieldEnd();
16452
      }
16453
      oprot.writeFieldStop();
16454
      oprot.writeStructEnd();
16455
    }
16456
 
16457
    @Override
16458
    public String toString() {
16459
      StringBuilder sb = new StringBuilder("getCurrentNonSerializedInventoryByScans_result(");
16460
      boolean first = true;
16461
 
16462
      sb.append("success:");
16463
      if (this.success == null) {
16464
        sb.append("null");
16465
      } else {
16466
        sb.append(this.success);
16467
      }
16468
      first = false;
16469
      sb.append(")");
16470
      return sb.toString();
16471
    }
16472
 
16473
    public void validate() throws org.apache.thrift.TException {
16474
      // check for required fields
16475
    }
16476
 
16477
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16478
      try {
16479
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16480
      } catch (org.apache.thrift.TException te) {
16481
        throw new java.io.IOException(te);
16482
      }
16483
    }
16484
 
16485
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16486
      try {
16487
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16488
      } catch (org.apache.thrift.TException te) {
16489
        throw new java.io.IOException(te);
16490
      }
16491
    }
16492
 
16493
  }
16494
 
6762 amar.kumar 16495
  public static class getHistoricSerializedInventoryByScans_args implements org.apache.thrift.TBase<getHistoricSerializedInventoryByScans_args, getHistoricSerializedInventoryByScans_args._Fields>, java.io.Serializable, Cloneable   {
16496
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getHistoricSerializedInventoryByScans_args");
16497
 
16498
    private static final org.apache.thrift.protocol.TField DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("date", org.apache.thrift.protocol.TType.I64, (short)1);
16499
 
16500
    private long date; // required
16501
 
16502
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16503
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16504
      DATE((short)1, "date");
16505
 
16506
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16507
 
16508
      static {
16509
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16510
          byName.put(field.getFieldName(), field);
16511
        }
16512
      }
16513
 
16514
      /**
16515
       * Find the _Fields constant that matches fieldId, or null if its not found.
16516
       */
16517
      public static _Fields findByThriftId(int fieldId) {
16518
        switch(fieldId) {
16519
          case 1: // DATE
16520
            return DATE;
16521
          default:
16522
            return null;
16523
        }
16524
      }
16525
 
16526
      /**
16527
       * Find the _Fields constant that matches fieldId, throwing an exception
16528
       * if it is not found.
16529
       */
16530
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16531
        _Fields fields = findByThriftId(fieldId);
16532
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16533
        return fields;
16534
      }
16535
 
16536
      /**
16537
       * Find the _Fields constant that matches name, or null if its not found.
16538
       */
16539
      public static _Fields findByName(String name) {
16540
        return byName.get(name);
16541
      }
16542
 
16543
      private final short _thriftId;
16544
      private final String _fieldName;
16545
 
16546
      _Fields(short thriftId, String fieldName) {
16547
        _thriftId = thriftId;
16548
        _fieldName = fieldName;
16549
      }
16550
 
16551
      public short getThriftFieldId() {
16552
        return _thriftId;
16553
      }
16554
 
16555
      public String getFieldName() {
16556
        return _fieldName;
16557
      }
16558
    }
16559
 
16560
    // isset id assignments
16561
    private static final int __DATE_ISSET_ID = 0;
16562
    private BitSet __isset_bit_vector = new BitSet(1);
16563
 
16564
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16565
    static {
16566
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16567
      tmpMap.put(_Fields.DATE, new org.apache.thrift.meta_data.FieldMetaData("date", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16568
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
16569
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16570
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getHistoricSerializedInventoryByScans_args.class, metaDataMap);
16571
    }
16572
 
16573
    public getHistoricSerializedInventoryByScans_args() {
16574
    }
16575
 
16576
    public getHistoricSerializedInventoryByScans_args(
16577
      long date)
16578
    {
16579
      this();
16580
      this.date = date;
16581
      setDateIsSet(true);
16582
    }
16583
 
16584
    /**
16585
     * Performs a deep copy on <i>other</i>.
16586
     */
16587
    public getHistoricSerializedInventoryByScans_args(getHistoricSerializedInventoryByScans_args other) {
16588
      __isset_bit_vector.clear();
16589
      __isset_bit_vector.or(other.__isset_bit_vector);
16590
      this.date = other.date;
16591
    }
16592
 
16593
    public getHistoricSerializedInventoryByScans_args deepCopy() {
16594
      return new getHistoricSerializedInventoryByScans_args(this);
16595
    }
16596
 
16597
    @Override
16598
    public void clear() {
16599
      setDateIsSet(false);
16600
      this.date = 0;
16601
    }
16602
 
16603
    public long getDate() {
16604
      return this.date;
16605
    }
16606
 
16607
    public void setDate(long date) {
16608
      this.date = date;
16609
      setDateIsSet(true);
16610
    }
16611
 
16612
    public void unsetDate() {
16613
      __isset_bit_vector.clear(__DATE_ISSET_ID);
16614
    }
16615
 
16616
    /** Returns true if field date is set (has been assigned a value) and false otherwise */
16617
    public boolean isSetDate() {
16618
      return __isset_bit_vector.get(__DATE_ISSET_ID);
16619
    }
16620
 
16621
    public void setDateIsSet(boolean value) {
16622
      __isset_bit_vector.set(__DATE_ISSET_ID, value);
16623
    }
16624
 
16625
    public void setFieldValue(_Fields field, Object value) {
16626
      switch (field) {
16627
      case DATE:
16628
        if (value == null) {
16629
          unsetDate();
16630
        } else {
16631
          setDate((Long)value);
16632
        }
16633
        break;
16634
 
16635
      }
16636
    }
16637
 
16638
    public Object getFieldValue(_Fields field) {
16639
      switch (field) {
16640
      case DATE:
16641
        return Long.valueOf(getDate());
16642
 
16643
      }
16644
      throw new IllegalStateException();
16645
    }
16646
 
16647
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16648
    public boolean isSet(_Fields field) {
16649
      if (field == null) {
16650
        throw new IllegalArgumentException();
16651
      }
16652
 
16653
      switch (field) {
16654
      case DATE:
16655
        return isSetDate();
16656
      }
16657
      throw new IllegalStateException();
16658
    }
16659
 
16660
    @Override
16661
    public boolean equals(Object that) {
16662
      if (that == null)
16663
        return false;
16664
      if (that instanceof getHistoricSerializedInventoryByScans_args)
16665
        return this.equals((getHistoricSerializedInventoryByScans_args)that);
16666
      return false;
16667
    }
16668
 
16669
    public boolean equals(getHistoricSerializedInventoryByScans_args that) {
16670
      if (that == null)
16671
        return false;
16672
 
16673
      boolean this_present_date = true;
16674
      boolean that_present_date = true;
16675
      if (this_present_date || that_present_date) {
16676
        if (!(this_present_date && that_present_date))
16677
          return false;
16678
        if (this.date != that.date)
16679
          return false;
16680
      }
16681
 
16682
      return true;
16683
    }
16684
 
16685
    @Override
16686
    public int hashCode() {
16687
      return 0;
16688
    }
16689
 
16690
    public int compareTo(getHistoricSerializedInventoryByScans_args other) {
16691
      if (!getClass().equals(other.getClass())) {
16692
        return getClass().getName().compareTo(other.getClass().getName());
16693
      }
16694
 
16695
      int lastComparison = 0;
16696
      getHistoricSerializedInventoryByScans_args typedOther = (getHistoricSerializedInventoryByScans_args)other;
16697
 
16698
      lastComparison = Boolean.valueOf(isSetDate()).compareTo(typedOther.isSetDate());
16699
      if (lastComparison != 0) {
16700
        return lastComparison;
16701
      }
16702
      if (isSetDate()) {
16703
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.date, typedOther.date);
16704
        if (lastComparison != 0) {
16705
          return lastComparison;
16706
        }
16707
      }
16708
      return 0;
16709
    }
16710
 
16711
    public _Fields fieldForId(int fieldId) {
16712
      return _Fields.findByThriftId(fieldId);
16713
    }
16714
 
16715
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16716
      org.apache.thrift.protocol.TField field;
16717
      iprot.readStructBegin();
16718
      while (true)
16719
      {
16720
        field = iprot.readFieldBegin();
16721
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16722
          break;
16723
        }
16724
        switch (field.id) {
16725
          case 1: // DATE
16726
            if (field.type == org.apache.thrift.protocol.TType.I64) {
16727
              this.date = iprot.readI64();
16728
              setDateIsSet(true);
16729
            } else { 
16730
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16731
            }
16732
            break;
16733
          default:
16734
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16735
        }
16736
        iprot.readFieldEnd();
16737
      }
16738
      iprot.readStructEnd();
16739
      validate();
16740
    }
16741
 
16742
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16743
      validate();
16744
 
16745
      oprot.writeStructBegin(STRUCT_DESC);
16746
      oprot.writeFieldBegin(DATE_FIELD_DESC);
16747
      oprot.writeI64(this.date);
16748
      oprot.writeFieldEnd();
16749
      oprot.writeFieldStop();
16750
      oprot.writeStructEnd();
16751
    }
16752
 
16753
    @Override
16754
    public String toString() {
16755
      StringBuilder sb = new StringBuilder("getHistoricSerializedInventoryByScans_args(");
16756
      boolean first = true;
16757
 
16758
      sb.append("date:");
16759
      sb.append(this.date);
16760
      first = false;
16761
      sb.append(")");
16762
      return sb.toString();
16763
    }
16764
 
16765
    public void validate() throws org.apache.thrift.TException {
16766
      // check for required fields
16767
    }
16768
 
16769
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16770
      try {
16771
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16772
      } catch (org.apache.thrift.TException te) {
16773
        throw new java.io.IOException(te);
16774
      }
16775
    }
16776
 
16777
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16778
      try {
16779
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16780
      } catch (org.apache.thrift.TException te) {
16781
        throw new java.io.IOException(te);
16782
      }
16783
    }
16784
 
16785
  }
16786
 
16787
  public static class getHistoricSerializedInventoryByScans_result implements org.apache.thrift.TBase<getHistoricSerializedInventoryByScans_result, getHistoricSerializedInventoryByScans_result._Fields>, java.io.Serializable, Cloneable   {
16788
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getHistoricSerializedInventoryByScans_result");
16789
 
16790
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
16791
 
16792
    private List<InventoryAvailability> success; // required
16793
 
16794
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16795
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16796
      SUCCESS((short)0, "success");
16797
 
16798
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16799
 
16800
      static {
16801
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16802
          byName.put(field.getFieldName(), field);
16803
        }
16804
      }
16805
 
16806
      /**
16807
       * Find the _Fields constant that matches fieldId, or null if its not found.
16808
       */
16809
      public static _Fields findByThriftId(int fieldId) {
16810
        switch(fieldId) {
16811
          case 0: // SUCCESS
16812
            return SUCCESS;
16813
          default:
16814
            return null;
16815
        }
16816
      }
16817
 
16818
      /**
16819
       * Find the _Fields constant that matches fieldId, throwing an exception
16820
       * if it is not found.
16821
       */
16822
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16823
        _Fields fields = findByThriftId(fieldId);
16824
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16825
        return fields;
16826
      }
16827
 
16828
      /**
16829
       * Find the _Fields constant that matches name, or null if its not found.
16830
       */
16831
      public static _Fields findByName(String name) {
16832
        return byName.get(name);
16833
      }
16834
 
16835
      private final short _thriftId;
16836
      private final String _fieldName;
16837
 
16838
      _Fields(short thriftId, String fieldName) {
16839
        _thriftId = thriftId;
16840
        _fieldName = fieldName;
16841
      }
16842
 
16843
      public short getThriftFieldId() {
16844
        return _thriftId;
16845
      }
16846
 
16847
      public String getFieldName() {
16848
        return _fieldName;
16849
      }
16850
    }
16851
 
16852
    // isset id assignments
16853
 
16854
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16855
    static {
16856
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16857
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16858
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
16859
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryAvailability.class))));
16860
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16861
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getHistoricSerializedInventoryByScans_result.class, metaDataMap);
16862
    }
16863
 
16864
    public getHistoricSerializedInventoryByScans_result() {
16865
    }
16866
 
16867
    public getHistoricSerializedInventoryByScans_result(
16868
      List<InventoryAvailability> success)
16869
    {
16870
      this();
16871
      this.success = success;
16872
    }
16873
 
16874
    /**
16875
     * Performs a deep copy on <i>other</i>.
16876
     */
16877
    public getHistoricSerializedInventoryByScans_result(getHistoricSerializedInventoryByScans_result other) {
16878
      if (other.isSetSuccess()) {
16879
        List<InventoryAvailability> __this__success = new ArrayList<InventoryAvailability>();
16880
        for (InventoryAvailability other_element : other.success) {
16881
          __this__success.add(new InventoryAvailability(other_element));
16882
        }
16883
        this.success = __this__success;
16884
      }
16885
    }
16886
 
16887
    public getHistoricSerializedInventoryByScans_result deepCopy() {
16888
      return new getHistoricSerializedInventoryByScans_result(this);
16889
    }
16890
 
16891
    @Override
16892
    public void clear() {
16893
      this.success = null;
16894
    }
16895
 
16896
    public int getSuccessSize() {
16897
      return (this.success == null) ? 0 : this.success.size();
16898
    }
16899
 
16900
    public java.util.Iterator<InventoryAvailability> getSuccessIterator() {
16901
      return (this.success == null) ? null : this.success.iterator();
16902
    }
16903
 
16904
    public void addToSuccess(InventoryAvailability elem) {
16905
      if (this.success == null) {
16906
        this.success = new ArrayList<InventoryAvailability>();
16907
      }
16908
      this.success.add(elem);
16909
    }
16910
 
16911
    public List<InventoryAvailability> getSuccess() {
16912
      return this.success;
16913
    }
16914
 
16915
    public void setSuccess(List<InventoryAvailability> success) {
16916
      this.success = success;
16917
    }
16918
 
16919
    public void unsetSuccess() {
16920
      this.success = null;
16921
    }
16922
 
16923
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
16924
    public boolean isSetSuccess() {
16925
      return this.success != null;
16926
    }
16927
 
16928
    public void setSuccessIsSet(boolean value) {
16929
      if (!value) {
16930
        this.success = null;
16931
      }
16932
    }
16933
 
16934
    public void setFieldValue(_Fields field, Object value) {
16935
      switch (field) {
16936
      case SUCCESS:
16937
        if (value == null) {
16938
          unsetSuccess();
16939
        } else {
16940
          setSuccess((List<InventoryAvailability>)value);
16941
        }
16942
        break;
16943
 
16944
      }
16945
    }
16946
 
16947
    public Object getFieldValue(_Fields field) {
16948
      switch (field) {
16949
      case SUCCESS:
16950
        return getSuccess();
16951
 
16952
      }
16953
      throw new IllegalStateException();
16954
    }
16955
 
16956
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16957
    public boolean isSet(_Fields field) {
16958
      if (field == null) {
16959
        throw new IllegalArgumentException();
16960
      }
16961
 
16962
      switch (field) {
16963
      case SUCCESS:
16964
        return isSetSuccess();
16965
      }
16966
      throw new IllegalStateException();
16967
    }
16968
 
16969
    @Override
16970
    public boolean equals(Object that) {
16971
      if (that == null)
16972
        return false;
16973
      if (that instanceof getHistoricSerializedInventoryByScans_result)
16974
        return this.equals((getHistoricSerializedInventoryByScans_result)that);
16975
      return false;
16976
    }
16977
 
16978
    public boolean equals(getHistoricSerializedInventoryByScans_result that) {
16979
      if (that == null)
16980
        return false;
16981
 
16982
      boolean this_present_success = true && this.isSetSuccess();
16983
      boolean that_present_success = true && that.isSetSuccess();
16984
      if (this_present_success || that_present_success) {
16985
        if (!(this_present_success && that_present_success))
16986
          return false;
16987
        if (!this.success.equals(that.success))
16988
          return false;
16989
      }
16990
 
16991
      return true;
16992
    }
16993
 
16994
    @Override
16995
    public int hashCode() {
16996
      return 0;
16997
    }
16998
 
16999
    public int compareTo(getHistoricSerializedInventoryByScans_result other) {
17000
      if (!getClass().equals(other.getClass())) {
17001
        return getClass().getName().compareTo(other.getClass().getName());
17002
      }
17003
 
17004
      int lastComparison = 0;
17005
      getHistoricSerializedInventoryByScans_result typedOther = (getHistoricSerializedInventoryByScans_result)other;
17006
 
17007
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17008
      if (lastComparison != 0) {
17009
        return lastComparison;
17010
      }
17011
      if (isSetSuccess()) {
17012
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17013
        if (lastComparison != 0) {
17014
          return lastComparison;
17015
        }
17016
      }
17017
      return 0;
17018
    }
17019
 
17020
    public _Fields fieldForId(int fieldId) {
17021
      return _Fields.findByThriftId(fieldId);
17022
    }
17023
 
17024
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17025
      org.apache.thrift.protocol.TField field;
17026
      iprot.readStructBegin();
17027
      while (true)
17028
      {
17029
        field = iprot.readFieldBegin();
17030
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17031
          break;
17032
        }
17033
        switch (field.id) {
17034
          case 0: // SUCCESS
17035
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
17036
              {
17037
                org.apache.thrift.protocol.TList _list48 = iprot.readListBegin();
17038
                this.success = new ArrayList<InventoryAvailability>(_list48.size);
17039
                for (int _i49 = 0; _i49 < _list48.size; ++_i49)
17040
                {
17041
                  InventoryAvailability _elem50; // required
17042
                  _elem50 = new InventoryAvailability();
17043
                  _elem50.read(iprot);
17044
                  this.success.add(_elem50);
17045
                }
17046
                iprot.readListEnd();
17047
              }
17048
            } else { 
17049
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17050
            }
17051
            break;
17052
          default:
17053
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17054
        }
17055
        iprot.readFieldEnd();
17056
      }
17057
      iprot.readStructEnd();
17058
      validate();
17059
    }
17060
 
17061
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17062
      oprot.writeStructBegin(STRUCT_DESC);
17063
 
17064
      if (this.isSetSuccess()) {
17065
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17066
        {
17067
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
17068
          for (InventoryAvailability _iter51 : this.success)
17069
          {
17070
            _iter51.write(oprot);
17071
          }
17072
          oprot.writeListEnd();
17073
        }
17074
        oprot.writeFieldEnd();
17075
      }
17076
      oprot.writeFieldStop();
17077
      oprot.writeStructEnd();
17078
    }
17079
 
17080
    @Override
17081
    public String toString() {
17082
      StringBuilder sb = new StringBuilder("getHistoricSerializedInventoryByScans_result(");
17083
      boolean first = true;
17084
 
17085
      sb.append("success:");
17086
      if (this.success == null) {
17087
        sb.append("null");
17088
      } else {
17089
        sb.append(this.success);
17090
      }
17091
      first = false;
17092
      sb.append(")");
17093
      return sb.toString();
17094
    }
17095
 
17096
    public void validate() throws org.apache.thrift.TException {
17097
      // check for required fields
17098
    }
17099
 
17100
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17101
      try {
17102
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17103
      } catch (org.apache.thrift.TException te) {
17104
        throw new java.io.IOException(te);
17105
      }
17106
    }
17107
 
17108
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17109
      try {
17110
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17111
      } catch (org.apache.thrift.TException te) {
17112
        throw new java.io.IOException(te);
17113
      }
17114
    }
17115
 
17116
  }
17117
 
17118
  public static class getHistoricNonSerializedInventoryByScans_args implements org.apache.thrift.TBase<getHistoricNonSerializedInventoryByScans_args, getHistoricNonSerializedInventoryByScans_args._Fields>, java.io.Serializable, Cloneable   {
17119
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getHistoricNonSerializedInventoryByScans_args");
17120
 
17121
    private static final org.apache.thrift.protocol.TField DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("date", org.apache.thrift.protocol.TType.I64, (short)1);
17122
 
17123
    private long date; // required
17124
 
17125
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17126
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17127
      DATE((short)1, "date");
17128
 
17129
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17130
 
17131
      static {
17132
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17133
          byName.put(field.getFieldName(), field);
17134
        }
17135
      }
17136
 
17137
      /**
17138
       * Find the _Fields constant that matches fieldId, or null if its not found.
17139
       */
17140
      public static _Fields findByThriftId(int fieldId) {
17141
        switch(fieldId) {
17142
          case 1: // DATE
17143
            return DATE;
17144
          default:
17145
            return null;
17146
        }
17147
      }
17148
 
17149
      /**
17150
       * Find the _Fields constant that matches fieldId, throwing an exception
17151
       * if it is not found.
17152
       */
17153
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17154
        _Fields fields = findByThriftId(fieldId);
17155
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17156
        return fields;
17157
      }
17158
 
17159
      /**
17160
       * Find the _Fields constant that matches name, or null if its not found.
17161
       */
17162
      public static _Fields findByName(String name) {
17163
        return byName.get(name);
17164
      }
17165
 
17166
      private final short _thriftId;
17167
      private final String _fieldName;
17168
 
17169
      _Fields(short thriftId, String fieldName) {
17170
        _thriftId = thriftId;
17171
        _fieldName = fieldName;
17172
      }
17173
 
17174
      public short getThriftFieldId() {
17175
        return _thriftId;
17176
      }
17177
 
17178
      public String getFieldName() {
17179
        return _fieldName;
17180
      }
17181
    }
17182
 
17183
    // isset id assignments
17184
    private static final int __DATE_ISSET_ID = 0;
17185
    private BitSet __isset_bit_vector = new BitSet(1);
17186
 
17187
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17188
    static {
17189
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17190
      tmpMap.put(_Fields.DATE, new org.apache.thrift.meta_data.FieldMetaData("date", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17191
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17192
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17193
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getHistoricNonSerializedInventoryByScans_args.class, metaDataMap);
17194
    }
17195
 
17196
    public getHistoricNonSerializedInventoryByScans_args() {
17197
    }
17198
 
17199
    public getHistoricNonSerializedInventoryByScans_args(
17200
      long date)
17201
    {
17202
      this();
17203
      this.date = date;
17204
      setDateIsSet(true);
17205
    }
17206
 
17207
    /**
17208
     * Performs a deep copy on <i>other</i>.
17209
     */
17210
    public getHistoricNonSerializedInventoryByScans_args(getHistoricNonSerializedInventoryByScans_args other) {
17211
      __isset_bit_vector.clear();
17212
      __isset_bit_vector.or(other.__isset_bit_vector);
17213
      this.date = other.date;
17214
    }
17215
 
17216
    public getHistoricNonSerializedInventoryByScans_args deepCopy() {
17217
      return new getHistoricNonSerializedInventoryByScans_args(this);
17218
    }
17219
 
17220
    @Override
17221
    public void clear() {
17222
      setDateIsSet(false);
17223
      this.date = 0;
17224
    }
17225
 
17226
    public long getDate() {
17227
      return this.date;
17228
    }
17229
 
17230
    public void setDate(long date) {
17231
      this.date = date;
17232
      setDateIsSet(true);
17233
    }
17234
 
17235
    public void unsetDate() {
17236
      __isset_bit_vector.clear(__DATE_ISSET_ID);
17237
    }
17238
 
17239
    /** Returns true if field date is set (has been assigned a value) and false otherwise */
17240
    public boolean isSetDate() {
17241
      return __isset_bit_vector.get(__DATE_ISSET_ID);
17242
    }
17243
 
17244
    public void setDateIsSet(boolean value) {
17245
      __isset_bit_vector.set(__DATE_ISSET_ID, value);
17246
    }
17247
 
17248
    public void setFieldValue(_Fields field, Object value) {
17249
      switch (field) {
17250
      case DATE:
17251
        if (value == null) {
17252
          unsetDate();
17253
        } else {
17254
          setDate((Long)value);
17255
        }
17256
        break;
17257
 
17258
      }
17259
    }
17260
 
17261
    public Object getFieldValue(_Fields field) {
17262
      switch (field) {
17263
      case DATE:
17264
        return Long.valueOf(getDate());
17265
 
17266
      }
17267
      throw new IllegalStateException();
17268
    }
17269
 
17270
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17271
    public boolean isSet(_Fields field) {
17272
      if (field == null) {
17273
        throw new IllegalArgumentException();
17274
      }
17275
 
17276
      switch (field) {
17277
      case DATE:
17278
        return isSetDate();
17279
      }
17280
      throw new IllegalStateException();
17281
    }
17282
 
17283
    @Override
17284
    public boolean equals(Object that) {
17285
      if (that == null)
17286
        return false;
17287
      if (that instanceof getHistoricNonSerializedInventoryByScans_args)
17288
        return this.equals((getHistoricNonSerializedInventoryByScans_args)that);
17289
      return false;
17290
    }
17291
 
17292
    public boolean equals(getHistoricNonSerializedInventoryByScans_args that) {
17293
      if (that == null)
17294
        return false;
17295
 
17296
      boolean this_present_date = true;
17297
      boolean that_present_date = true;
17298
      if (this_present_date || that_present_date) {
17299
        if (!(this_present_date && that_present_date))
17300
          return false;
17301
        if (this.date != that.date)
17302
          return false;
17303
      }
17304
 
17305
      return true;
17306
    }
17307
 
17308
    @Override
17309
    public int hashCode() {
17310
      return 0;
17311
    }
17312
 
17313
    public int compareTo(getHistoricNonSerializedInventoryByScans_args other) {
17314
      if (!getClass().equals(other.getClass())) {
17315
        return getClass().getName().compareTo(other.getClass().getName());
17316
      }
17317
 
17318
      int lastComparison = 0;
17319
      getHistoricNonSerializedInventoryByScans_args typedOther = (getHistoricNonSerializedInventoryByScans_args)other;
17320
 
17321
      lastComparison = Boolean.valueOf(isSetDate()).compareTo(typedOther.isSetDate());
17322
      if (lastComparison != 0) {
17323
        return lastComparison;
17324
      }
17325
      if (isSetDate()) {
17326
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.date, typedOther.date);
17327
        if (lastComparison != 0) {
17328
          return lastComparison;
17329
        }
17330
      }
17331
      return 0;
17332
    }
17333
 
17334
    public _Fields fieldForId(int fieldId) {
17335
      return _Fields.findByThriftId(fieldId);
17336
    }
17337
 
17338
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17339
      org.apache.thrift.protocol.TField field;
17340
      iprot.readStructBegin();
17341
      while (true)
17342
      {
17343
        field = iprot.readFieldBegin();
17344
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17345
          break;
17346
        }
17347
        switch (field.id) {
17348
          case 1: // DATE
17349
            if (field.type == org.apache.thrift.protocol.TType.I64) {
17350
              this.date = iprot.readI64();
17351
              setDateIsSet(true);
17352
            } else { 
17353
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17354
            }
17355
            break;
17356
          default:
17357
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17358
        }
17359
        iprot.readFieldEnd();
17360
      }
17361
      iprot.readStructEnd();
17362
      validate();
17363
    }
17364
 
17365
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17366
      validate();
17367
 
17368
      oprot.writeStructBegin(STRUCT_DESC);
17369
      oprot.writeFieldBegin(DATE_FIELD_DESC);
17370
      oprot.writeI64(this.date);
17371
      oprot.writeFieldEnd();
17372
      oprot.writeFieldStop();
17373
      oprot.writeStructEnd();
17374
    }
17375
 
17376
    @Override
17377
    public String toString() {
17378
      StringBuilder sb = new StringBuilder("getHistoricNonSerializedInventoryByScans_args(");
17379
      boolean first = true;
17380
 
17381
      sb.append("date:");
17382
      sb.append(this.date);
17383
      first = false;
17384
      sb.append(")");
17385
      return sb.toString();
17386
    }
17387
 
17388
    public void validate() throws org.apache.thrift.TException {
17389
      // check for required fields
17390
    }
17391
 
17392
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17393
      try {
17394
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17395
      } catch (org.apache.thrift.TException te) {
17396
        throw new java.io.IOException(te);
17397
      }
17398
    }
17399
 
17400
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17401
      try {
17402
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
17403
        __isset_bit_vector = new BitSet(1);
17404
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17405
      } catch (org.apache.thrift.TException te) {
17406
        throw new java.io.IOException(te);
17407
      }
17408
    }
17409
 
17410
  }
17411
 
17412
  public static class getHistoricNonSerializedInventoryByScans_result implements org.apache.thrift.TBase<getHistoricNonSerializedInventoryByScans_result, getHistoricNonSerializedInventoryByScans_result._Fields>, java.io.Serializable, Cloneable   {
17413
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getHistoricNonSerializedInventoryByScans_result");
17414
 
17415
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.LIST, (short)0);
17416
 
17417
    private List<InventoryAvailability> success; // required
17418
 
17419
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17420
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17421
      SUCCESS((short)0, "success");
17422
 
17423
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17424
 
17425
      static {
17426
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17427
          byName.put(field.getFieldName(), field);
17428
        }
17429
      }
17430
 
17431
      /**
17432
       * Find the _Fields constant that matches fieldId, or null if its not found.
17433
       */
17434
      public static _Fields findByThriftId(int fieldId) {
17435
        switch(fieldId) {
17436
          case 0: // SUCCESS
17437
            return SUCCESS;
17438
          default:
17439
            return null;
17440
        }
17441
      }
17442
 
17443
      /**
17444
       * Find the _Fields constant that matches fieldId, throwing an exception
17445
       * if it is not found.
17446
       */
17447
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17448
        _Fields fields = findByThriftId(fieldId);
17449
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17450
        return fields;
17451
      }
17452
 
17453
      /**
17454
       * Find the _Fields constant that matches name, or null if its not found.
17455
       */
17456
      public static _Fields findByName(String name) {
17457
        return byName.get(name);
17458
      }
17459
 
17460
      private final short _thriftId;
17461
      private final String _fieldName;
17462
 
17463
      _Fields(short thriftId, String fieldName) {
17464
        _thriftId = thriftId;
17465
        _fieldName = fieldName;
17466
      }
17467
 
17468
      public short getThriftFieldId() {
17469
        return _thriftId;
17470
      }
17471
 
17472
      public String getFieldName() {
17473
        return _fieldName;
17474
      }
17475
    }
17476
 
17477
    // isset id assignments
17478
 
17479
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17480
    static {
17481
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17482
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17483
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
17484
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryAvailability.class))));
17485
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17486
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getHistoricNonSerializedInventoryByScans_result.class, metaDataMap);
17487
    }
17488
 
17489
    public getHistoricNonSerializedInventoryByScans_result() {
17490
    }
17491
 
17492
    public getHistoricNonSerializedInventoryByScans_result(
17493
      List<InventoryAvailability> success)
17494
    {
17495
      this();
17496
      this.success = success;
17497
    }
17498
 
17499
    /**
17500
     * Performs a deep copy on <i>other</i>.
17501
     */
17502
    public getHistoricNonSerializedInventoryByScans_result(getHistoricNonSerializedInventoryByScans_result other) {
17503
      if (other.isSetSuccess()) {
17504
        List<InventoryAvailability> __this__success = new ArrayList<InventoryAvailability>();
17505
        for (InventoryAvailability other_element : other.success) {
17506
          __this__success.add(new InventoryAvailability(other_element));
17507
        }
17508
        this.success = __this__success;
17509
      }
17510
    }
17511
 
17512
    public getHistoricNonSerializedInventoryByScans_result deepCopy() {
17513
      return new getHistoricNonSerializedInventoryByScans_result(this);
17514
    }
17515
 
17516
    @Override
17517
    public void clear() {
17518
      this.success = null;
17519
    }
17520
 
17521
    public int getSuccessSize() {
17522
      return (this.success == null) ? 0 : this.success.size();
17523
    }
17524
 
17525
    public java.util.Iterator<InventoryAvailability> getSuccessIterator() {
17526
      return (this.success == null) ? null : this.success.iterator();
17527
    }
17528
 
17529
    public void addToSuccess(InventoryAvailability elem) {
17530
      if (this.success == null) {
17531
        this.success = new ArrayList<InventoryAvailability>();
17532
      }
17533
      this.success.add(elem);
17534
    }
17535
 
17536
    public List<InventoryAvailability> getSuccess() {
17537
      return this.success;
17538
    }
17539
 
17540
    public void setSuccess(List<InventoryAvailability> success) {
17541
      this.success = success;
17542
    }
17543
 
17544
    public void unsetSuccess() {
17545
      this.success = null;
17546
    }
17547
 
17548
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17549
    public boolean isSetSuccess() {
17550
      return this.success != null;
17551
    }
17552
 
17553
    public void setSuccessIsSet(boolean value) {
17554
      if (!value) {
17555
        this.success = null;
17556
      }
17557
    }
17558
 
17559
    public void setFieldValue(_Fields field, Object value) {
17560
      switch (field) {
17561
      case SUCCESS:
17562
        if (value == null) {
17563
          unsetSuccess();
17564
        } else {
17565
          setSuccess((List<InventoryAvailability>)value);
17566
        }
17567
        break;
17568
 
17569
      }
17570
    }
17571
 
17572
    public Object getFieldValue(_Fields field) {
17573
      switch (field) {
17574
      case SUCCESS:
17575
        return getSuccess();
17576
 
17577
      }
17578
      throw new IllegalStateException();
17579
    }
17580
 
17581
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17582
    public boolean isSet(_Fields field) {
17583
      if (field == null) {
17584
        throw new IllegalArgumentException();
17585
      }
17586
 
17587
      switch (field) {
17588
      case SUCCESS:
17589
        return isSetSuccess();
17590
      }
17591
      throw new IllegalStateException();
17592
    }
17593
 
17594
    @Override
17595
    public boolean equals(Object that) {
17596
      if (that == null)
17597
        return false;
17598
      if (that instanceof getHistoricNonSerializedInventoryByScans_result)
17599
        return this.equals((getHistoricNonSerializedInventoryByScans_result)that);
17600
      return false;
17601
    }
17602
 
17603
    public boolean equals(getHistoricNonSerializedInventoryByScans_result that) {
17604
      if (that == null)
17605
        return false;
17606
 
17607
      boolean this_present_success = true && this.isSetSuccess();
17608
      boolean that_present_success = true && that.isSetSuccess();
17609
      if (this_present_success || that_present_success) {
17610
        if (!(this_present_success && that_present_success))
17611
          return false;
17612
        if (!this.success.equals(that.success))
17613
          return false;
17614
      }
17615
 
17616
      return true;
17617
    }
17618
 
17619
    @Override
17620
    public int hashCode() {
17621
      return 0;
17622
    }
17623
 
17624
    public int compareTo(getHistoricNonSerializedInventoryByScans_result other) {
17625
      if (!getClass().equals(other.getClass())) {
17626
        return getClass().getName().compareTo(other.getClass().getName());
17627
      }
17628
 
17629
      int lastComparison = 0;
17630
      getHistoricNonSerializedInventoryByScans_result typedOther = (getHistoricNonSerializedInventoryByScans_result)other;
17631
 
17632
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17633
      if (lastComparison != 0) {
17634
        return lastComparison;
17635
      }
17636
      if (isSetSuccess()) {
17637
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17638
        if (lastComparison != 0) {
17639
          return lastComparison;
17640
        }
17641
      }
17642
      return 0;
17643
    }
17644
 
17645
    public _Fields fieldForId(int fieldId) {
17646
      return _Fields.findByThriftId(fieldId);
17647
    }
17648
 
17649
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17650
      org.apache.thrift.protocol.TField field;
17651
      iprot.readStructBegin();
17652
      while (true)
17653
      {
17654
        field = iprot.readFieldBegin();
17655
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17656
          break;
17657
        }
17658
        switch (field.id) {
17659
          case 0: // SUCCESS
17660
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
17661
              {
17662
                org.apache.thrift.protocol.TList _list52 = iprot.readListBegin();
17663
                this.success = new ArrayList<InventoryAvailability>(_list52.size);
17664
                for (int _i53 = 0; _i53 < _list52.size; ++_i53)
17665
                {
17666
                  InventoryAvailability _elem54; // required
17667
                  _elem54 = new InventoryAvailability();
17668
                  _elem54.read(iprot);
17669
                  this.success.add(_elem54);
17670
                }
17671
                iprot.readListEnd();
17672
              }
17673
            } else { 
17674
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17675
            }
17676
            break;
17677
          default:
17678
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17679
        }
17680
        iprot.readFieldEnd();
17681
      }
17682
      iprot.readStructEnd();
17683
      validate();
17684
    }
17685
 
17686
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17687
      oprot.writeStructBegin(STRUCT_DESC);
17688
 
17689
      if (this.isSetSuccess()) {
17690
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17691
        {
17692
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
17693
          for (InventoryAvailability _iter55 : this.success)
17694
          {
17695
            _iter55.write(oprot);
17696
          }
17697
          oprot.writeListEnd();
17698
        }
17699
        oprot.writeFieldEnd();
17700
      }
17701
      oprot.writeFieldStop();
17702
      oprot.writeStructEnd();
17703
    }
17704
 
17705
    @Override
17706
    public String toString() {
17707
      StringBuilder sb = new StringBuilder("getHistoricNonSerializedInventoryByScans_result(");
17708
      boolean first = true;
17709
 
17710
      sb.append("success:");
17711
      if (this.success == null) {
17712
        sb.append("null");
17713
      } else {
17714
        sb.append(this.success);
17715
      }
17716
      first = false;
17717
      sb.append(")");
17718
      return sb.toString();
17719
    }
17720
 
17721
    public void validate() throws org.apache.thrift.TException {
17722
      // check for required fields
17723
    }
17724
 
17725
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17726
      try {
17727
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17728
      } catch (org.apache.thrift.TException te) {
17729
        throw new java.io.IOException(te);
17730
      }
17731
    }
17732
 
17733
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17734
      try {
17735
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17736
      } catch (org.apache.thrift.TException te) {
17737
        throw new java.io.IOException(te);
17738
      }
17739
    }
17740
 
17741
  }
17742
 
17743
  public static class scanForOursExternalSale_args implements org.apache.thrift.TBase<scanForOursExternalSale_args, scanForOursExternalSale_args._Fields>, java.io.Serializable, Cloneable   {
17744
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForOursExternalSale_args");
17745
 
17746
    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)1);
17747
    private static final org.apache.thrift.protocol.TField SERIAL_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("serialNumber", org.apache.thrift.protocol.TType.STRING, (short)2);
17748
    private static final org.apache.thrift.protocol.TField ITEM_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("itemNumber", org.apache.thrift.protocol.TType.STRING, (short)3);
17749
    private static final org.apache.thrift.protocol.TField INVOICE_NUMBER_FIELD_DESC = new org.apache.thrift.protocol.TField("invoiceNumber", org.apache.thrift.protocol.TType.STRING, (short)4);
17750
    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)5);
17751
    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)6);
17752
    private static final org.apache.thrift.protocol.TField ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("orderId", org.apache.thrift.protocol.TType.I64, (short)7);
17753
 
17754
    private long itemId; // required
17755
    private String serialNumber; // required
17756
    private String itemNumber; // required
17757
    private String invoiceNumber; // required
17758
    private long warehouseId; // required
17759
    private double unitPrice; // required
17760
    private long orderId; // required
17761
 
17762
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17763
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17764
      ITEM_ID((short)1, "itemId"),
17765
      SERIAL_NUMBER((short)2, "serialNumber"),
17766
      ITEM_NUMBER((short)3, "itemNumber"),
17767
      INVOICE_NUMBER((short)4, "invoiceNumber"),
17768
      WAREHOUSE_ID((short)5, "warehouseId"),
17769
      UNIT_PRICE((short)6, "unitPrice"),
17770
      ORDER_ID((short)7, "orderId");
17771
 
17772
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17773
 
17774
      static {
17775
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17776
          byName.put(field.getFieldName(), field);
17777
        }
17778
      }
17779
 
17780
      /**
17781
       * Find the _Fields constant that matches fieldId, or null if its not found.
17782
       */
17783
      public static _Fields findByThriftId(int fieldId) {
17784
        switch(fieldId) {
17785
          case 1: // ITEM_ID
17786
            return ITEM_ID;
17787
          case 2: // SERIAL_NUMBER
17788
            return SERIAL_NUMBER;
17789
          case 3: // ITEM_NUMBER
17790
            return ITEM_NUMBER;
17791
          case 4: // INVOICE_NUMBER
17792
            return INVOICE_NUMBER;
17793
          case 5: // WAREHOUSE_ID
17794
            return WAREHOUSE_ID;
17795
          case 6: // UNIT_PRICE
17796
            return UNIT_PRICE;
17797
          case 7: // ORDER_ID
17798
            return ORDER_ID;
17799
          default:
17800
            return null;
17801
        }
17802
      }
17803
 
17804
      /**
17805
       * Find the _Fields constant that matches fieldId, throwing an exception
17806
       * if it is not found.
17807
       */
17808
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17809
        _Fields fields = findByThriftId(fieldId);
17810
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17811
        return fields;
17812
      }
17813
 
17814
      /**
17815
       * Find the _Fields constant that matches name, or null if its not found.
17816
       */
17817
      public static _Fields findByName(String name) {
17818
        return byName.get(name);
17819
      }
17820
 
17821
      private final short _thriftId;
17822
      private final String _fieldName;
17823
 
17824
      _Fields(short thriftId, String fieldName) {
17825
        _thriftId = thriftId;
17826
        _fieldName = fieldName;
17827
      }
17828
 
17829
      public short getThriftFieldId() {
17830
        return _thriftId;
17831
      }
17832
 
17833
      public String getFieldName() {
17834
        return _fieldName;
17835
      }
17836
    }
17837
 
17838
    // isset id assignments
17839
    private static final int __ITEMID_ISSET_ID = 0;
17840
    private static final int __WAREHOUSEID_ISSET_ID = 1;
17841
    private static final int __UNITPRICE_ISSET_ID = 2;
17842
    private static final int __ORDERID_ISSET_ID = 3;
17843
    private BitSet __isset_bit_vector = new BitSet(4);
17844
 
17845
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17846
    static {
17847
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17848
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17849
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17850
      tmpMap.put(_Fields.SERIAL_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("serialNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17851
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
17852
      tmpMap.put(_Fields.ITEM_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("itemNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17853
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
17854
      tmpMap.put(_Fields.INVOICE_NUMBER, new org.apache.thrift.meta_data.FieldMetaData("invoiceNumber", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17855
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
17856
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17857
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17858
      tmpMap.put(_Fields.UNIT_PRICE, new org.apache.thrift.meta_data.FieldMetaData("unitPrice", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17859
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
17860
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17861
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17862
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17863
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForOursExternalSale_args.class, metaDataMap);
17864
    }
17865
 
17866
    public scanForOursExternalSale_args() {
17867
    }
17868
 
17869
    public scanForOursExternalSale_args(
17870
      long itemId,
17871
      String serialNumber,
17872
      String itemNumber,
17873
      String invoiceNumber,
17874
      long warehouseId,
17875
      double unitPrice,
17876
      long orderId)
17877
    {
17878
      this();
17879
      this.itemId = itemId;
17880
      setItemIdIsSet(true);
17881
      this.serialNumber = serialNumber;
17882
      this.itemNumber = itemNumber;
17883
      this.invoiceNumber = invoiceNumber;
17884
      this.warehouseId = warehouseId;
17885
      setWarehouseIdIsSet(true);
17886
      this.unitPrice = unitPrice;
17887
      setUnitPriceIsSet(true);
17888
      this.orderId = orderId;
17889
      setOrderIdIsSet(true);
17890
    }
17891
 
17892
    /**
17893
     * Performs a deep copy on <i>other</i>.
17894
     */
17895
    public scanForOursExternalSale_args(scanForOursExternalSale_args other) {
17896
      __isset_bit_vector.clear();
17897
      __isset_bit_vector.or(other.__isset_bit_vector);
17898
      this.itemId = other.itemId;
17899
      if (other.isSetSerialNumber()) {
17900
        this.serialNumber = other.serialNumber;
17901
      }
17902
      if (other.isSetItemNumber()) {
17903
        this.itemNumber = other.itemNumber;
17904
      }
17905
      if (other.isSetInvoiceNumber()) {
17906
        this.invoiceNumber = other.invoiceNumber;
17907
      }
17908
      this.warehouseId = other.warehouseId;
17909
      this.unitPrice = other.unitPrice;
17910
      this.orderId = other.orderId;
17911
    }
17912
 
17913
    public scanForOursExternalSale_args deepCopy() {
17914
      return new scanForOursExternalSale_args(this);
17915
    }
17916
 
17917
    @Override
17918
    public void clear() {
17919
      setItemIdIsSet(false);
17920
      this.itemId = 0;
17921
      this.serialNumber = null;
17922
      this.itemNumber = null;
17923
      this.invoiceNumber = null;
17924
      setWarehouseIdIsSet(false);
17925
      this.warehouseId = 0;
17926
      setUnitPriceIsSet(false);
17927
      this.unitPrice = 0.0;
17928
      setOrderIdIsSet(false);
17929
      this.orderId = 0;
17930
    }
17931
 
17932
    public long getItemId() {
17933
      return this.itemId;
17934
    }
17935
 
17936
    public void setItemId(long itemId) {
17937
      this.itemId = itemId;
17938
      setItemIdIsSet(true);
17939
    }
17940
 
17941
    public void unsetItemId() {
17942
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
17943
    }
17944
 
17945
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
17946
    public boolean isSetItemId() {
17947
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
17948
    }
17949
 
17950
    public void setItemIdIsSet(boolean value) {
17951
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
17952
    }
17953
 
17954
    public String getSerialNumber() {
17955
      return this.serialNumber;
17956
    }
17957
 
17958
    public void setSerialNumber(String serialNumber) {
17959
      this.serialNumber = serialNumber;
17960
    }
17961
 
17962
    public void unsetSerialNumber() {
17963
      this.serialNumber = null;
17964
    }
17965
 
17966
    /** Returns true if field serialNumber is set (has been assigned a value) and false otherwise */
17967
    public boolean isSetSerialNumber() {
17968
      return this.serialNumber != null;
17969
    }
17970
 
17971
    public void setSerialNumberIsSet(boolean value) {
17972
      if (!value) {
17973
        this.serialNumber = null;
17974
      }
17975
    }
17976
 
17977
    public String getItemNumber() {
17978
      return this.itemNumber;
17979
    }
17980
 
17981
    public void setItemNumber(String itemNumber) {
17982
      this.itemNumber = itemNumber;
17983
    }
17984
 
17985
    public void unsetItemNumber() {
17986
      this.itemNumber = null;
17987
    }
17988
 
17989
    /** Returns true if field itemNumber is set (has been assigned a value) and false otherwise */
17990
    public boolean isSetItemNumber() {
17991
      return this.itemNumber != null;
17992
    }
17993
 
17994
    public void setItemNumberIsSet(boolean value) {
17995
      if (!value) {
17996
        this.itemNumber = null;
17997
      }
17998
    }
17999
 
18000
    public String getInvoiceNumber() {
18001
      return this.invoiceNumber;
18002
    }
18003
 
18004
    public void setInvoiceNumber(String invoiceNumber) {
18005
      this.invoiceNumber = invoiceNumber;
18006
    }
18007
 
18008
    public void unsetInvoiceNumber() {
18009
      this.invoiceNumber = null;
18010
    }
18011
 
18012
    /** Returns true if field invoiceNumber is set (has been assigned a value) and false otherwise */
18013
    public boolean isSetInvoiceNumber() {
18014
      return this.invoiceNumber != null;
18015
    }
18016
 
18017
    public void setInvoiceNumberIsSet(boolean value) {
18018
      if (!value) {
18019
        this.invoiceNumber = null;
18020
      }
18021
    }
18022
 
18023
    public long getWarehouseId() {
18024
      return this.warehouseId;
18025
    }
18026
 
18027
    public void setWarehouseId(long warehouseId) {
18028
      this.warehouseId = warehouseId;
18029
      setWarehouseIdIsSet(true);
18030
    }
18031
 
18032
    public void unsetWarehouseId() {
18033
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
18034
    }
18035
 
18036
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
18037
    public boolean isSetWarehouseId() {
18038
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
18039
    }
18040
 
18041
    public void setWarehouseIdIsSet(boolean value) {
18042
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
18043
    }
18044
 
18045
    public double getUnitPrice() {
18046
      return this.unitPrice;
18047
    }
18048
 
18049
    public void setUnitPrice(double unitPrice) {
18050
      this.unitPrice = unitPrice;
18051
      setUnitPriceIsSet(true);
18052
    }
18053
 
18054
    public void unsetUnitPrice() {
18055
      __isset_bit_vector.clear(__UNITPRICE_ISSET_ID);
18056
    }
18057
 
18058
    /** Returns true if field unitPrice is set (has been assigned a value) and false otherwise */
18059
    public boolean isSetUnitPrice() {
18060
      return __isset_bit_vector.get(__UNITPRICE_ISSET_ID);
18061
    }
18062
 
18063
    public void setUnitPriceIsSet(boolean value) {
18064
      __isset_bit_vector.set(__UNITPRICE_ISSET_ID, value);
18065
    }
18066
 
18067
    public long getOrderId() {
18068
      return this.orderId;
18069
    }
18070
 
18071
    public void setOrderId(long orderId) {
18072
      this.orderId = orderId;
18073
      setOrderIdIsSet(true);
18074
    }
18075
 
18076
    public void unsetOrderId() {
18077
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
18078
    }
18079
 
18080
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
18081
    public boolean isSetOrderId() {
18082
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
18083
    }
18084
 
18085
    public void setOrderIdIsSet(boolean value) {
18086
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
18087
    }
18088
 
18089
    public void setFieldValue(_Fields field, Object value) {
18090
      switch (field) {
18091
      case ITEM_ID:
18092
        if (value == null) {
18093
          unsetItemId();
18094
        } else {
18095
          setItemId((Long)value);
18096
        }
18097
        break;
18098
 
18099
      case SERIAL_NUMBER:
18100
        if (value == null) {
18101
          unsetSerialNumber();
18102
        } else {
18103
          setSerialNumber((String)value);
18104
        }
18105
        break;
18106
 
18107
      case ITEM_NUMBER:
18108
        if (value == null) {
18109
          unsetItemNumber();
18110
        } else {
18111
          setItemNumber((String)value);
18112
        }
18113
        break;
18114
 
18115
      case INVOICE_NUMBER:
18116
        if (value == null) {
18117
          unsetInvoiceNumber();
18118
        } else {
18119
          setInvoiceNumber((String)value);
18120
        }
18121
        break;
18122
 
18123
      case WAREHOUSE_ID:
18124
        if (value == null) {
18125
          unsetWarehouseId();
18126
        } else {
18127
          setWarehouseId((Long)value);
18128
        }
18129
        break;
18130
 
18131
      case UNIT_PRICE:
18132
        if (value == null) {
18133
          unsetUnitPrice();
18134
        } else {
18135
          setUnitPrice((Double)value);
18136
        }
18137
        break;
18138
 
18139
      case ORDER_ID:
18140
        if (value == null) {
18141
          unsetOrderId();
18142
        } else {
18143
          setOrderId((Long)value);
18144
        }
18145
        break;
18146
 
18147
      }
18148
    }
18149
 
18150
    public Object getFieldValue(_Fields field) {
18151
      switch (field) {
18152
      case ITEM_ID:
18153
        return Long.valueOf(getItemId());
18154
 
18155
      case SERIAL_NUMBER:
18156
        return getSerialNumber();
18157
 
18158
      case ITEM_NUMBER:
18159
        return getItemNumber();
18160
 
18161
      case INVOICE_NUMBER:
18162
        return getInvoiceNumber();
18163
 
18164
      case WAREHOUSE_ID:
18165
        return Long.valueOf(getWarehouseId());
18166
 
18167
      case UNIT_PRICE:
18168
        return Double.valueOf(getUnitPrice());
18169
 
18170
      case ORDER_ID:
18171
        return Long.valueOf(getOrderId());
18172
 
18173
      }
18174
      throw new IllegalStateException();
18175
    }
18176
 
18177
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18178
    public boolean isSet(_Fields field) {
18179
      if (field == null) {
18180
        throw new IllegalArgumentException();
18181
      }
18182
 
18183
      switch (field) {
18184
      case ITEM_ID:
18185
        return isSetItemId();
18186
      case SERIAL_NUMBER:
18187
        return isSetSerialNumber();
18188
      case ITEM_NUMBER:
18189
        return isSetItemNumber();
18190
      case INVOICE_NUMBER:
18191
        return isSetInvoiceNumber();
18192
      case WAREHOUSE_ID:
18193
        return isSetWarehouseId();
18194
      case UNIT_PRICE:
18195
        return isSetUnitPrice();
18196
      case ORDER_ID:
18197
        return isSetOrderId();
18198
      }
18199
      throw new IllegalStateException();
18200
    }
18201
 
18202
    @Override
18203
    public boolean equals(Object that) {
18204
      if (that == null)
18205
        return false;
18206
      if (that instanceof scanForOursExternalSale_args)
18207
        return this.equals((scanForOursExternalSale_args)that);
18208
      return false;
18209
    }
18210
 
18211
    public boolean equals(scanForOursExternalSale_args that) {
18212
      if (that == null)
18213
        return false;
18214
 
18215
      boolean this_present_itemId = true;
18216
      boolean that_present_itemId = true;
18217
      if (this_present_itemId || that_present_itemId) {
18218
        if (!(this_present_itemId && that_present_itemId))
18219
          return false;
18220
        if (this.itemId != that.itemId)
18221
          return false;
18222
      }
18223
 
18224
      boolean this_present_serialNumber = true && this.isSetSerialNumber();
18225
      boolean that_present_serialNumber = true && that.isSetSerialNumber();
18226
      if (this_present_serialNumber || that_present_serialNumber) {
18227
        if (!(this_present_serialNumber && that_present_serialNumber))
18228
          return false;
18229
        if (!this.serialNumber.equals(that.serialNumber))
18230
          return false;
18231
      }
18232
 
18233
      boolean this_present_itemNumber = true && this.isSetItemNumber();
18234
      boolean that_present_itemNumber = true && that.isSetItemNumber();
18235
      if (this_present_itemNumber || that_present_itemNumber) {
18236
        if (!(this_present_itemNumber && that_present_itemNumber))
18237
          return false;
18238
        if (!this.itemNumber.equals(that.itemNumber))
18239
          return false;
18240
      }
18241
 
18242
      boolean this_present_invoiceNumber = true && this.isSetInvoiceNumber();
18243
      boolean that_present_invoiceNumber = true && that.isSetInvoiceNumber();
18244
      if (this_present_invoiceNumber || that_present_invoiceNumber) {
18245
        if (!(this_present_invoiceNumber && that_present_invoiceNumber))
18246
          return false;
18247
        if (!this.invoiceNumber.equals(that.invoiceNumber))
18248
          return false;
18249
      }
18250
 
18251
      boolean this_present_warehouseId = true;
18252
      boolean that_present_warehouseId = true;
18253
      if (this_present_warehouseId || that_present_warehouseId) {
18254
        if (!(this_present_warehouseId && that_present_warehouseId))
18255
          return false;
18256
        if (this.warehouseId != that.warehouseId)
18257
          return false;
18258
      }
18259
 
18260
      boolean this_present_unitPrice = true;
18261
      boolean that_present_unitPrice = true;
18262
      if (this_present_unitPrice || that_present_unitPrice) {
18263
        if (!(this_present_unitPrice && that_present_unitPrice))
18264
          return false;
18265
        if (this.unitPrice != that.unitPrice)
18266
          return false;
18267
      }
18268
 
18269
      boolean this_present_orderId = true;
18270
      boolean that_present_orderId = true;
18271
      if (this_present_orderId || that_present_orderId) {
18272
        if (!(this_present_orderId && that_present_orderId))
18273
          return false;
18274
        if (this.orderId != that.orderId)
18275
          return false;
18276
      }
18277
 
18278
      return true;
18279
    }
18280
 
18281
    @Override
18282
    public int hashCode() {
18283
      return 0;
18284
    }
18285
 
18286
    public int compareTo(scanForOursExternalSale_args other) {
18287
      if (!getClass().equals(other.getClass())) {
18288
        return getClass().getName().compareTo(other.getClass().getName());
18289
      }
18290
 
18291
      int lastComparison = 0;
18292
      scanForOursExternalSale_args typedOther = (scanForOursExternalSale_args)other;
18293
 
18294
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
18295
      if (lastComparison != 0) {
18296
        return lastComparison;
18297
      }
18298
      if (isSetItemId()) {
18299
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
18300
        if (lastComparison != 0) {
18301
          return lastComparison;
18302
        }
18303
      }
18304
      lastComparison = Boolean.valueOf(isSetSerialNumber()).compareTo(typedOther.isSetSerialNumber());
18305
      if (lastComparison != 0) {
18306
        return lastComparison;
18307
      }
18308
      if (isSetSerialNumber()) {
18309
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.serialNumber, typedOther.serialNumber);
18310
        if (lastComparison != 0) {
18311
          return lastComparison;
18312
        }
18313
      }
18314
      lastComparison = Boolean.valueOf(isSetItemNumber()).compareTo(typedOther.isSetItemNumber());
18315
      if (lastComparison != 0) {
18316
        return lastComparison;
18317
      }
18318
      if (isSetItemNumber()) {
18319
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemNumber, typedOther.itemNumber);
18320
        if (lastComparison != 0) {
18321
          return lastComparison;
18322
        }
18323
      }
18324
      lastComparison = Boolean.valueOf(isSetInvoiceNumber()).compareTo(typedOther.isSetInvoiceNumber());
18325
      if (lastComparison != 0) {
18326
        return lastComparison;
18327
      }
18328
      if (isSetInvoiceNumber()) {
18329
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.invoiceNumber, typedOther.invoiceNumber);
18330
        if (lastComparison != 0) {
18331
          return lastComparison;
18332
        }
18333
      }
18334
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
18335
      if (lastComparison != 0) {
18336
        return lastComparison;
18337
      }
18338
      if (isSetWarehouseId()) {
18339
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
18340
        if (lastComparison != 0) {
18341
          return lastComparison;
18342
        }
18343
      }
18344
      lastComparison = Boolean.valueOf(isSetUnitPrice()).compareTo(typedOther.isSetUnitPrice());
18345
      if (lastComparison != 0) {
18346
        return lastComparison;
18347
      }
18348
      if (isSetUnitPrice()) {
18349
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.unitPrice, typedOther.unitPrice);
18350
        if (lastComparison != 0) {
18351
          return lastComparison;
18352
        }
18353
      }
18354
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
18355
      if (lastComparison != 0) {
18356
        return lastComparison;
18357
      }
18358
      if (isSetOrderId()) {
18359
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
18360
        if (lastComparison != 0) {
18361
          return lastComparison;
18362
        }
18363
      }
18364
      return 0;
18365
    }
18366
 
18367
    public _Fields fieldForId(int fieldId) {
18368
      return _Fields.findByThriftId(fieldId);
18369
    }
18370
 
18371
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18372
      org.apache.thrift.protocol.TField field;
18373
      iprot.readStructBegin();
18374
      while (true)
18375
      {
18376
        field = iprot.readFieldBegin();
18377
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18378
          break;
18379
        }
18380
        switch (field.id) {
18381
          case 1: // ITEM_ID
18382
            if (field.type == org.apache.thrift.protocol.TType.I64) {
18383
              this.itemId = iprot.readI64();
18384
              setItemIdIsSet(true);
18385
            } else { 
18386
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18387
            }
18388
            break;
18389
          case 2: // SERIAL_NUMBER
18390
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
18391
              this.serialNumber = iprot.readString();
18392
            } else { 
18393
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18394
            }
18395
            break;
18396
          case 3: // ITEM_NUMBER
18397
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
18398
              this.itemNumber = iprot.readString();
18399
            } else { 
18400
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18401
            }
18402
            break;
18403
          case 4: // INVOICE_NUMBER
18404
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
18405
              this.invoiceNumber = iprot.readString();
18406
            } else { 
18407
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18408
            }
18409
            break;
18410
          case 5: // WAREHOUSE_ID
18411
            if (field.type == org.apache.thrift.protocol.TType.I64) {
18412
              this.warehouseId = iprot.readI64();
18413
              setWarehouseIdIsSet(true);
18414
            } else { 
18415
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18416
            }
18417
            break;
18418
          case 6: // UNIT_PRICE
18419
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
18420
              this.unitPrice = iprot.readDouble();
18421
              setUnitPriceIsSet(true);
18422
            } else { 
18423
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18424
            }
18425
            break;
18426
          case 7: // ORDER_ID
18427
            if (field.type == org.apache.thrift.protocol.TType.I64) {
18428
              this.orderId = iprot.readI64();
18429
              setOrderIdIsSet(true);
18430
            } else { 
18431
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18432
            }
18433
            break;
18434
          default:
18435
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18436
        }
18437
        iprot.readFieldEnd();
18438
      }
18439
      iprot.readStructEnd();
18440
      validate();
18441
    }
18442
 
18443
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18444
      validate();
18445
 
18446
      oprot.writeStructBegin(STRUCT_DESC);
18447
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
18448
      oprot.writeI64(this.itemId);
18449
      oprot.writeFieldEnd();
18450
      if (this.serialNumber != null) {
18451
        oprot.writeFieldBegin(SERIAL_NUMBER_FIELD_DESC);
18452
        oprot.writeString(this.serialNumber);
18453
        oprot.writeFieldEnd();
18454
      }
18455
      if (this.itemNumber != null) {
18456
        oprot.writeFieldBegin(ITEM_NUMBER_FIELD_DESC);
18457
        oprot.writeString(this.itemNumber);
18458
        oprot.writeFieldEnd();
18459
      }
18460
      if (this.invoiceNumber != null) {
18461
        oprot.writeFieldBegin(INVOICE_NUMBER_FIELD_DESC);
18462
        oprot.writeString(this.invoiceNumber);
18463
        oprot.writeFieldEnd();
18464
      }
18465
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
18466
      oprot.writeI64(this.warehouseId);
18467
      oprot.writeFieldEnd();
18468
      oprot.writeFieldBegin(UNIT_PRICE_FIELD_DESC);
18469
      oprot.writeDouble(this.unitPrice);
18470
      oprot.writeFieldEnd();
18471
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
18472
      oprot.writeI64(this.orderId);
18473
      oprot.writeFieldEnd();
18474
      oprot.writeFieldStop();
18475
      oprot.writeStructEnd();
18476
    }
18477
 
18478
    @Override
18479
    public String toString() {
18480
      StringBuilder sb = new StringBuilder("scanForOursExternalSale_args(");
18481
      boolean first = true;
18482
 
18483
      sb.append("itemId:");
18484
      sb.append(this.itemId);
18485
      first = false;
18486
      if (!first) sb.append(", ");
18487
      sb.append("serialNumber:");
18488
      if (this.serialNumber == null) {
18489
        sb.append("null");
18490
      } else {
18491
        sb.append(this.serialNumber);
18492
      }
18493
      first = false;
18494
      if (!first) sb.append(", ");
18495
      sb.append("itemNumber:");
18496
      if (this.itemNumber == null) {
18497
        sb.append("null");
18498
      } else {
18499
        sb.append(this.itemNumber);
18500
      }
18501
      first = false;
18502
      if (!first) sb.append(", ");
18503
      sb.append("invoiceNumber:");
18504
      if (this.invoiceNumber == null) {
18505
        sb.append("null");
18506
      } else {
18507
        sb.append(this.invoiceNumber);
18508
      }
18509
      first = false;
18510
      if (!first) sb.append(", ");
18511
      sb.append("warehouseId:");
18512
      sb.append(this.warehouseId);
18513
      first = false;
18514
      if (!first) sb.append(", ");
18515
      sb.append("unitPrice:");
18516
      sb.append(this.unitPrice);
18517
      first = false;
18518
      if (!first) sb.append(", ");
18519
      sb.append("orderId:");
18520
      sb.append(this.orderId);
18521
      first = false;
18522
      sb.append(")");
18523
      return sb.toString();
18524
    }
18525
 
18526
    public void validate() throws org.apache.thrift.TException {
18527
      // check for required fields
18528
    }
18529
 
18530
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18531
      try {
18532
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18533
      } catch (org.apache.thrift.TException te) {
18534
        throw new java.io.IOException(te);
18535
      }
18536
    }
18537
 
18538
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18539
      try {
18540
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
18541
        __isset_bit_vector = new BitSet(1);
18542
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18543
      } catch (org.apache.thrift.TException te) {
18544
        throw new java.io.IOException(te);
18545
      }
18546
    }
18547
 
18548
  }
18549
 
18550
  public static class scanForOursExternalSale_result implements org.apache.thrift.TBase<scanForOursExternalSale_result, scanForOursExternalSale_result._Fields>, java.io.Serializable, Cloneable   {
18551
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForOursExternalSale_result");
18552
 
18553
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
18554
    private static final org.apache.thrift.protocol.TField EX_FIELD_DESC = new org.apache.thrift.protocol.TField("ex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
18555
 
18556
    private InventoryItem success; // required
18557
    private WarehouseServiceException ex; // required
18558
 
18559
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18560
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18561
      SUCCESS((short)0, "success"),
18562
      EX((short)1, "ex");
18563
 
18564
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18565
 
18566
      static {
18567
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18568
          byName.put(field.getFieldName(), field);
18569
        }
18570
      }
18571
 
18572
      /**
18573
       * Find the _Fields constant that matches fieldId, or null if its not found.
18574
       */
18575
      public static _Fields findByThriftId(int fieldId) {
18576
        switch(fieldId) {
18577
          case 0: // SUCCESS
18578
            return SUCCESS;
18579
          case 1: // EX
18580
            return EX;
18581
          default:
18582
            return null;
18583
        }
18584
      }
18585
 
18586
      /**
18587
       * Find the _Fields constant that matches fieldId, throwing an exception
18588
       * if it is not found.
18589
       */
18590
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18591
        _Fields fields = findByThriftId(fieldId);
18592
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18593
        return fields;
18594
      }
18595
 
18596
      /**
18597
       * Find the _Fields constant that matches name, or null if its not found.
18598
       */
18599
      public static _Fields findByName(String name) {
18600
        return byName.get(name);
18601
      }
18602
 
18603
      private final short _thriftId;
18604
      private final String _fieldName;
18605
 
18606
      _Fields(short thriftId, String fieldName) {
18607
        _thriftId = thriftId;
18608
        _fieldName = fieldName;
18609
      }
18610
 
18611
      public short getThriftFieldId() {
18612
        return _thriftId;
18613
      }
18614
 
18615
      public String getFieldName() {
18616
        return _fieldName;
18617
      }
18618
    }
18619
 
18620
    // isset id assignments
18621
 
18622
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18623
    static {
18624
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18625
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18626
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, InventoryItem.class)));
18627
      tmpMap.put(_Fields.EX, new org.apache.thrift.meta_data.FieldMetaData("ex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18628
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
18629
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18630
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForOursExternalSale_result.class, metaDataMap);
18631
    }
18632
 
18633
    public scanForOursExternalSale_result() {
18634
    }
18635
 
18636
    public scanForOursExternalSale_result(
18637
      InventoryItem success,
18638
      WarehouseServiceException ex)
18639
    {
18640
      this();
18641
      this.success = success;
18642
      this.ex = ex;
18643
    }
18644
 
18645
    /**
18646
     * Performs a deep copy on <i>other</i>.
18647
     */
18648
    public scanForOursExternalSale_result(scanForOursExternalSale_result other) {
18649
      if (other.isSetSuccess()) {
18650
        this.success = new InventoryItem(other.success);
18651
      }
18652
      if (other.isSetEx()) {
18653
        this.ex = new WarehouseServiceException(other.ex);
18654
      }
18655
    }
18656
 
18657
    public scanForOursExternalSale_result deepCopy() {
18658
      return new scanForOursExternalSale_result(this);
18659
    }
18660
 
18661
    @Override
18662
    public void clear() {
18663
      this.success = null;
18664
      this.ex = null;
18665
    }
18666
 
18667
    public InventoryItem getSuccess() {
18668
      return this.success;
18669
    }
18670
 
18671
    public void setSuccess(InventoryItem success) {
18672
      this.success = success;
18673
    }
18674
 
18675
    public void unsetSuccess() {
18676
      this.success = null;
18677
    }
18678
 
18679
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
18680
    public boolean isSetSuccess() {
18681
      return this.success != null;
18682
    }
18683
 
18684
    public void setSuccessIsSet(boolean value) {
18685
      if (!value) {
18686
        this.success = null;
18687
      }
18688
    }
18689
 
18690
    public WarehouseServiceException getEx() {
18691
      return this.ex;
18692
    }
18693
 
18694
    public void setEx(WarehouseServiceException ex) {
18695
      this.ex = ex;
18696
    }
18697
 
18698
    public void unsetEx() {
18699
      this.ex = null;
18700
    }
18701
 
18702
    /** Returns true if field ex is set (has been assigned a value) and false otherwise */
18703
    public boolean isSetEx() {
18704
      return this.ex != null;
18705
    }
18706
 
18707
    public void setExIsSet(boolean value) {
18708
      if (!value) {
18709
        this.ex = null;
18710
      }
18711
    }
18712
 
18713
    public void setFieldValue(_Fields field, Object value) {
18714
      switch (field) {
18715
      case SUCCESS:
18716
        if (value == null) {
18717
          unsetSuccess();
18718
        } else {
18719
          setSuccess((InventoryItem)value);
18720
        }
18721
        break;
18722
 
18723
      case EX:
18724
        if (value == null) {
18725
          unsetEx();
18726
        } else {
18727
          setEx((WarehouseServiceException)value);
18728
        }
18729
        break;
18730
 
18731
      }
18732
    }
18733
 
18734
    public Object getFieldValue(_Fields field) {
18735
      switch (field) {
18736
      case SUCCESS:
18737
        return getSuccess();
18738
 
18739
      case EX:
18740
        return getEx();
18741
 
18742
      }
18743
      throw new IllegalStateException();
18744
    }
18745
 
18746
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18747
    public boolean isSet(_Fields field) {
18748
      if (field == null) {
18749
        throw new IllegalArgumentException();
18750
      }
18751
 
18752
      switch (field) {
18753
      case SUCCESS:
18754
        return isSetSuccess();
18755
      case EX:
18756
        return isSetEx();
18757
      }
18758
      throw new IllegalStateException();
18759
    }
18760
 
18761
    @Override
18762
    public boolean equals(Object that) {
18763
      if (that == null)
18764
        return false;
18765
      if (that instanceof scanForOursExternalSale_result)
18766
        return this.equals((scanForOursExternalSale_result)that);
18767
      return false;
18768
    }
18769
 
18770
    public boolean equals(scanForOursExternalSale_result that) {
18771
      if (that == null)
18772
        return false;
18773
 
18774
      boolean this_present_success = true && this.isSetSuccess();
18775
      boolean that_present_success = true && that.isSetSuccess();
18776
      if (this_present_success || that_present_success) {
18777
        if (!(this_present_success && that_present_success))
18778
          return false;
18779
        if (!this.success.equals(that.success))
18780
          return false;
18781
      }
18782
 
18783
      boolean this_present_ex = true && this.isSetEx();
18784
      boolean that_present_ex = true && that.isSetEx();
18785
      if (this_present_ex || that_present_ex) {
18786
        if (!(this_present_ex && that_present_ex))
18787
          return false;
18788
        if (!this.ex.equals(that.ex))
18789
          return false;
18790
      }
18791
 
18792
      return true;
18793
    }
18794
 
18795
    @Override
18796
    public int hashCode() {
18797
      return 0;
18798
    }
18799
 
18800
    public int compareTo(scanForOursExternalSale_result other) {
18801
      if (!getClass().equals(other.getClass())) {
18802
        return getClass().getName().compareTo(other.getClass().getName());
18803
      }
18804
 
18805
      int lastComparison = 0;
18806
      scanForOursExternalSale_result typedOther = (scanForOursExternalSale_result)other;
18807
 
18808
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
18809
      if (lastComparison != 0) {
18810
        return lastComparison;
18811
      }
18812
      if (isSetSuccess()) {
18813
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
18814
        if (lastComparison != 0) {
18815
          return lastComparison;
18816
        }
18817
      }
18818
      lastComparison = Boolean.valueOf(isSetEx()).compareTo(typedOther.isSetEx());
18819
      if (lastComparison != 0) {
18820
        return lastComparison;
18821
      }
18822
      if (isSetEx()) {
18823
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.ex, typedOther.ex);
18824
        if (lastComparison != 0) {
18825
          return lastComparison;
18826
        }
18827
      }
18828
      return 0;
18829
    }
18830
 
18831
    public _Fields fieldForId(int fieldId) {
18832
      return _Fields.findByThriftId(fieldId);
18833
    }
18834
 
18835
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18836
      org.apache.thrift.protocol.TField field;
18837
      iprot.readStructBegin();
18838
      while (true)
18839
      {
18840
        field = iprot.readFieldBegin();
18841
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18842
          break;
18843
        }
18844
        switch (field.id) {
18845
          case 0: // SUCCESS
18846
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
18847
              this.success = new InventoryItem();
18848
              this.success.read(iprot);
18849
            } else { 
18850
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18851
            }
18852
            break;
18853
          case 1: // EX
18854
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
18855
              this.ex = new WarehouseServiceException();
18856
              this.ex.read(iprot);
18857
            } else { 
18858
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18859
            }
18860
            break;
18861
          default:
18862
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18863
        }
18864
        iprot.readFieldEnd();
18865
      }
18866
      iprot.readStructEnd();
18867
      validate();
18868
    }
18869
 
18870
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18871
      oprot.writeStructBegin(STRUCT_DESC);
18872
 
18873
      if (this.isSetSuccess()) {
18874
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
18875
        this.success.write(oprot);
18876
        oprot.writeFieldEnd();
18877
      } else if (this.isSetEx()) {
18878
        oprot.writeFieldBegin(EX_FIELD_DESC);
18879
        this.ex.write(oprot);
18880
        oprot.writeFieldEnd();
18881
      }
18882
      oprot.writeFieldStop();
18883
      oprot.writeStructEnd();
18884
    }
18885
 
18886
    @Override
18887
    public String toString() {
18888
      StringBuilder sb = new StringBuilder("scanForOursExternalSale_result(");
18889
      boolean first = true;
18890
 
18891
      sb.append("success:");
18892
      if (this.success == null) {
18893
        sb.append("null");
18894
      } else {
18895
        sb.append(this.success);
18896
      }
18897
      first = false;
18898
      if (!first) sb.append(", ");
18899
      sb.append("ex:");
18900
      if (this.ex == null) {
18901
        sb.append("null");
18902
      } else {
18903
        sb.append(this.ex);
18904
      }
18905
      first = false;
18906
      sb.append(")");
18907
      return sb.toString();
18908
    }
18909
 
18910
    public void validate() throws org.apache.thrift.TException {
18911
      // check for required fields
18912
    }
18913
 
18914
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18915
      try {
18916
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18917
      } catch (org.apache.thrift.TException te) {
18918
        throw new java.io.IOException(te);
18919
      }
18920
    }
18921
 
18922
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18923
      try {
18924
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18925
      } catch (org.apache.thrift.TException te) {
18926
        throw new java.io.IOException(te);
18927
      }
18928
    }
18929
 
18930
  }
18931
 
18932
  public static class scanForOursExternalSaleReturn_args implements org.apache.thrift.TBase<scanForOursExternalSaleReturn_args, scanForOursExternalSaleReturn_args._Fields>, java.io.Serializable, Cloneable   {
18933
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForOursExternalSaleReturn_args");
18934
 
18935
    private static final org.apache.thrift.protocol.TField ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("orderId", org.apache.thrift.protocol.TType.I64, (short)1);
18936
    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)2);
18937
 
18938
    private long orderId; // required
18939
    private double unitPrice; // required
18940
 
18941
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18942
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18943
      ORDER_ID((short)1, "orderId"),
18944
      UNIT_PRICE((short)2, "unitPrice");
18945
 
18946
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18947
 
18948
      static {
18949
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18950
          byName.put(field.getFieldName(), field);
18951
        }
18952
      }
18953
 
18954
      /**
18955
       * Find the _Fields constant that matches fieldId, or null if its not found.
18956
       */
18957
      public static _Fields findByThriftId(int fieldId) {
18958
        switch(fieldId) {
18959
          case 1: // ORDER_ID
18960
            return ORDER_ID;
18961
          case 2: // UNIT_PRICE
18962
            return UNIT_PRICE;
18963
          default:
18964
            return null;
18965
        }
18966
      }
18967
 
18968
      /**
18969
       * Find the _Fields constant that matches fieldId, throwing an exception
18970
       * if it is not found.
18971
       */
18972
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18973
        _Fields fields = findByThriftId(fieldId);
18974
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18975
        return fields;
18976
      }
18977
 
18978
      /**
18979
       * Find the _Fields constant that matches name, or null if its not found.
18980
       */
18981
      public static _Fields findByName(String name) {
18982
        return byName.get(name);
18983
      }
18984
 
18985
      private final short _thriftId;
18986
      private final String _fieldName;
18987
 
18988
      _Fields(short thriftId, String fieldName) {
18989
        _thriftId = thriftId;
18990
        _fieldName = fieldName;
18991
      }
18992
 
18993
      public short getThriftFieldId() {
18994
        return _thriftId;
18995
      }
18996
 
18997
      public String getFieldName() {
18998
        return _fieldName;
18999
      }
19000
    }
19001
 
19002
    // isset id assignments
19003
    private static final int __ORDERID_ISSET_ID = 0;
19004
    private static final int __UNITPRICE_ISSET_ID = 1;
19005
    private BitSet __isset_bit_vector = new BitSet(2);
19006
 
19007
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19008
    static {
19009
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19010
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19011
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
19012
      tmpMap.put(_Fields.UNIT_PRICE, new org.apache.thrift.meta_data.FieldMetaData("unitPrice", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19013
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
19014
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19015
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForOursExternalSaleReturn_args.class, metaDataMap);
19016
    }
19017
 
19018
    public scanForOursExternalSaleReturn_args() {
19019
    }
19020
 
19021
    public scanForOursExternalSaleReturn_args(
19022
      long orderId,
19023
      double unitPrice)
19024
    {
19025
      this();
19026
      this.orderId = orderId;
19027
      setOrderIdIsSet(true);
19028
      this.unitPrice = unitPrice;
19029
      setUnitPriceIsSet(true);
19030
    }
19031
 
19032
    /**
19033
     * Performs a deep copy on <i>other</i>.
19034
     */
19035
    public scanForOursExternalSaleReturn_args(scanForOursExternalSaleReturn_args other) {
19036
      __isset_bit_vector.clear();
19037
      __isset_bit_vector.or(other.__isset_bit_vector);
19038
      this.orderId = other.orderId;
19039
      this.unitPrice = other.unitPrice;
19040
    }
19041
 
19042
    public scanForOursExternalSaleReturn_args deepCopy() {
19043
      return new scanForOursExternalSaleReturn_args(this);
19044
    }
19045
 
19046
    @Override
19047
    public void clear() {
19048
      setOrderIdIsSet(false);
19049
      this.orderId = 0;
19050
      setUnitPriceIsSet(false);
19051
      this.unitPrice = 0.0;
19052
    }
19053
 
19054
    public long getOrderId() {
19055
      return this.orderId;
19056
    }
19057
 
19058
    public void setOrderId(long orderId) {
19059
      this.orderId = orderId;
19060
      setOrderIdIsSet(true);
19061
    }
19062
 
19063
    public void unsetOrderId() {
19064
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
19065
    }
19066
 
19067
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
19068
    public boolean isSetOrderId() {
19069
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
19070
    }
19071
 
19072
    public void setOrderIdIsSet(boolean value) {
19073
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
19074
    }
19075
 
19076
    public double getUnitPrice() {
19077
      return this.unitPrice;
19078
    }
19079
 
19080
    public void setUnitPrice(double unitPrice) {
19081
      this.unitPrice = unitPrice;
19082
      setUnitPriceIsSet(true);
19083
    }
19084
 
19085
    public void unsetUnitPrice() {
19086
      __isset_bit_vector.clear(__UNITPRICE_ISSET_ID);
19087
    }
19088
 
19089
    /** Returns true if field unitPrice is set (has been assigned a value) and false otherwise */
19090
    public boolean isSetUnitPrice() {
19091
      return __isset_bit_vector.get(__UNITPRICE_ISSET_ID);
19092
    }
19093
 
19094
    public void setUnitPriceIsSet(boolean value) {
19095
      __isset_bit_vector.set(__UNITPRICE_ISSET_ID, value);
19096
    }
19097
 
19098
    public void setFieldValue(_Fields field, Object value) {
19099
      switch (field) {
19100
      case ORDER_ID:
19101
        if (value == null) {
19102
          unsetOrderId();
19103
        } else {
19104
          setOrderId((Long)value);
19105
        }
19106
        break;
19107
 
19108
      case UNIT_PRICE:
19109
        if (value == null) {
19110
          unsetUnitPrice();
19111
        } else {
19112
          setUnitPrice((Double)value);
19113
        }
19114
        break;
19115
 
19116
      }
19117
    }
19118
 
19119
    public Object getFieldValue(_Fields field) {
19120
      switch (field) {
19121
      case ORDER_ID:
19122
        return Long.valueOf(getOrderId());
19123
 
19124
      case UNIT_PRICE:
19125
        return Double.valueOf(getUnitPrice());
19126
 
19127
      }
19128
      throw new IllegalStateException();
19129
    }
19130
 
19131
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19132
    public boolean isSet(_Fields field) {
19133
      if (field == null) {
19134
        throw new IllegalArgumentException();
19135
      }
19136
 
19137
      switch (field) {
19138
      case ORDER_ID:
19139
        return isSetOrderId();
19140
      case UNIT_PRICE:
19141
        return isSetUnitPrice();
19142
      }
19143
      throw new IllegalStateException();
19144
    }
19145
 
19146
    @Override
19147
    public boolean equals(Object that) {
19148
      if (that == null)
19149
        return false;
19150
      if (that instanceof scanForOursExternalSaleReturn_args)
19151
        return this.equals((scanForOursExternalSaleReturn_args)that);
19152
      return false;
19153
    }
19154
 
19155
    public boolean equals(scanForOursExternalSaleReturn_args that) {
19156
      if (that == null)
19157
        return false;
19158
 
19159
      boolean this_present_orderId = true;
19160
      boolean that_present_orderId = true;
19161
      if (this_present_orderId || that_present_orderId) {
19162
        if (!(this_present_orderId && that_present_orderId))
19163
          return false;
19164
        if (this.orderId != that.orderId)
19165
          return false;
19166
      }
19167
 
19168
      boolean this_present_unitPrice = true;
19169
      boolean that_present_unitPrice = true;
19170
      if (this_present_unitPrice || that_present_unitPrice) {
19171
        if (!(this_present_unitPrice && that_present_unitPrice))
19172
          return false;
19173
        if (this.unitPrice != that.unitPrice)
19174
          return false;
19175
      }
19176
 
19177
      return true;
19178
    }
19179
 
19180
    @Override
19181
    public int hashCode() {
19182
      return 0;
19183
    }
19184
 
19185
    public int compareTo(scanForOursExternalSaleReturn_args other) {
19186
      if (!getClass().equals(other.getClass())) {
19187
        return getClass().getName().compareTo(other.getClass().getName());
19188
      }
19189
 
19190
      int lastComparison = 0;
19191
      scanForOursExternalSaleReturn_args typedOther = (scanForOursExternalSaleReturn_args)other;
19192
 
19193
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
19194
      if (lastComparison != 0) {
19195
        return lastComparison;
19196
      }
19197
      if (isSetOrderId()) {
19198
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
19199
        if (lastComparison != 0) {
19200
          return lastComparison;
19201
        }
19202
      }
19203
      lastComparison = Boolean.valueOf(isSetUnitPrice()).compareTo(typedOther.isSetUnitPrice());
19204
      if (lastComparison != 0) {
19205
        return lastComparison;
19206
      }
19207
      if (isSetUnitPrice()) {
19208
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.unitPrice, typedOther.unitPrice);
19209
        if (lastComparison != 0) {
19210
          return lastComparison;
19211
        }
19212
      }
19213
      return 0;
19214
    }
19215
 
19216
    public _Fields fieldForId(int fieldId) {
19217
      return _Fields.findByThriftId(fieldId);
19218
    }
19219
 
19220
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19221
      org.apache.thrift.protocol.TField field;
19222
      iprot.readStructBegin();
19223
      while (true)
19224
      {
19225
        field = iprot.readFieldBegin();
19226
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19227
          break;
19228
        }
19229
        switch (field.id) {
19230
          case 1: // ORDER_ID
19231
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19232
              this.orderId = iprot.readI64();
19233
              setOrderIdIsSet(true);
19234
            } else { 
19235
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19236
            }
19237
            break;
19238
          case 2: // UNIT_PRICE
19239
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
19240
              this.unitPrice = iprot.readDouble();
19241
              setUnitPriceIsSet(true);
19242
            } else { 
19243
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19244
            }
19245
            break;
19246
          default:
19247
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19248
        }
19249
        iprot.readFieldEnd();
19250
      }
19251
      iprot.readStructEnd();
19252
      validate();
19253
    }
19254
 
19255
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19256
      validate();
19257
 
19258
      oprot.writeStructBegin(STRUCT_DESC);
19259
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
19260
      oprot.writeI64(this.orderId);
19261
      oprot.writeFieldEnd();
19262
      oprot.writeFieldBegin(UNIT_PRICE_FIELD_DESC);
19263
      oprot.writeDouble(this.unitPrice);
19264
      oprot.writeFieldEnd();
19265
      oprot.writeFieldStop();
19266
      oprot.writeStructEnd();
19267
    }
19268
 
19269
    @Override
19270
    public String toString() {
19271
      StringBuilder sb = new StringBuilder("scanForOursExternalSaleReturn_args(");
19272
      boolean first = true;
19273
 
19274
      sb.append("orderId:");
19275
      sb.append(this.orderId);
19276
      first = false;
19277
      if (!first) sb.append(", ");
19278
      sb.append("unitPrice:");
19279
      sb.append(this.unitPrice);
19280
      first = false;
19281
      sb.append(")");
19282
      return sb.toString();
19283
    }
19284
 
19285
    public void validate() throws org.apache.thrift.TException {
19286
      // check for required fields
19287
    }
19288
 
19289
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19290
      try {
19291
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19292
      } catch (org.apache.thrift.TException te) {
19293
        throw new java.io.IOException(te);
19294
      }
19295
    }
19296
 
19297
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19298
      try {
19299
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19300
      } catch (org.apache.thrift.TException te) {
19301
        throw new java.io.IOException(te);
19302
      }
19303
    }
19304
 
19305
  }
19306
 
19307
  public static class scanForOursExternalSaleReturn_result implements org.apache.thrift.TBase<scanForOursExternalSaleReturn_result, scanForOursExternalSaleReturn_result._Fields>, java.io.Serializable, Cloneable   {
19308
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("scanForOursExternalSaleReturn_result");
19309
 
19310
 
19311
 
19312
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19313
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19314
;
19315
 
19316
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19317
 
19318
      static {
19319
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19320
          byName.put(field.getFieldName(), field);
19321
        }
19322
      }
19323
 
19324
      /**
19325
       * Find the _Fields constant that matches fieldId, or null if its not found.
19326
       */
19327
      public static _Fields findByThriftId(int fieldId) {
19328
        switch(fieldId) {
19329
          default:
19330
            return null;
19331
        }
19332
      }
19333
 
19334
      /**
19335
       * Find the _Fields constant that matches fieldId, throwing an exception
19336
       * if it is not found.
19337
       */
19338
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19339
        _Fields fields = findByThriftId(fieldId);
19340
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19341
        return fields;
19342
      }
19343
 
19344
      /**
19345
       * Find the _Fields constant that matches name, or null if its not found.
19346
       */
19347
      public static _Fields findByName(String name) {
19348
        return byName.get(name);
19349
      }
19350
 
19351
      private final short _thriftId;
19352
      private final String _fieldName;
19353
 
19354
      _Fields(short thriftId, String fieldName) {
19355
        _thriftId = thriftId;
19356
        _fieldName = fieldName;
19357
      }
19358
 
19359
      public short getThriftFieldId() {
19360
        return _thriftId;
19361
      }
19362
 
19363
      public String getFieldName() {
19364
        return _fieldName;
19365
      }
19366
    }
19367
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19368
    static {
19369
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19370
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19371
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(scanForOursExternalSaleReturn_result.class, metaDataMap);
19372
    }
19373
 
19374
    public scanForOursExternalSaleReturn_result() {
19375
    }
19376
 
19377
    /**
19378
     * Performs a deep copy on <i>other</i>.
19379
     */
19380
    public scanForOursExternalSaleReturn_result(scanForOursExternalSaleReturn_result other) {
19381
    }
19382
 
19383
    public scanForOursExternalSaleReturn_result deepCopy() {
19384
      return new scanForOursExternalSaleReturn_result(this);
19385
    }
19386
 
19387
    @Override
19388
    public void clear() {
19389
    }
19390
 
19391
    public void setFieldValue(_Fields field, Object value) {
19392
      switch (field) {
19393
      }
19394
    }
19395
 
19396
    public Object getFieldValue(_Fields field) {
19397
      switch (field) {
19398
      }
19399
      throw new IllegalStateException();
19400
    }
19401
 
19402
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19403
    public boolean isSet(_Fields field) {
19404
      if (field == null) {
19405
        throw new IllegalArgumentException();
19406
      }
19407
 
19408
      switch (field) {
19409
      }
19410
      throw new IllegalStateException();
19411
    }
19412
 
19413
    @Override
19414
    public boolean equals(Object that) {
19415
      if (that == null)
19416
        return false;
19417
      if (that instanceof scanForOursExternalSaleReturn_result)
19418
        return this.equals((scanForOursExternalSaleReturn_result)that);
19419
      return false;
19420
    }
19421
 
19422
    public boolean equals(scanForOursExternalSaleReturn_result that) {
19423
      if (that == null)
19424
        return false;
19425
 
19426
      return true;
19427
    }
19428
 
19429
    @Override
19430
    public int hashCode() {
19431
      return 0;
19432
    }
19433
 
19434
    public int compareTo(scanForOursExternalSaleReturn_result other) {
19435
      if (!getClass().equals(other.getClass())) {
19436
        return getClass().getName().compareTo(other.getClass().getName());
19437
      }
19438
 
19439
      int lastComparison = 0;
19440
      scanForOursExternalSaleReturn_result typedOther = (scanForOursExternalSaleReturn_result)other;
19441
 
19442
      return 0;
19443
    }
19444
 
19445
    public _Fields fieldForId(int fieldId) {
19446
      return _Fields.findByThriftId(fieldId);
19447
    }
19448
 
19449
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19450
      org.apache.thrift.protocol.TField field;
19451
      iprot.readStructBegin();
19452
      while (true)
19453
      {
19454
        field = iprot.readFieldBegin();
19455
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19456
          break;
19457
        }
19458
        switch (field.id) {
19459
          default:
19460
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19461
        }
19462
        iprot.readFieldEnd();
19463
      }
19464
      iprot.readStructEnd();
19465
      validate();
19466
    }
19467
 
19468
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19469
      oprot.writeStructBegin(STRUCT_DESC);
19470
 
19471
      oprot.writeFieldStop();
19472
      oprot.writeStructEnd();
19473
    }
19474
 
19475
    @Override
19476
    public String toString() {
19477
      StringBuilder sb = new StringBuilder("scanForOursExternalSaleReturn_result(");
19478
      boolean first = true;
19479
 
19480
      sb.append(")");
19481
      return sb.toString();
19482
    }
19483
 
19484
    public void validate() throws org.apache.thrift.TException {
19485
      // check for required fields
19486
    }
19487
 
19488
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19489
      try {
19490
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19491
      } catch (org.apache.thrift.TException te) {
19492
        throw new java.io.IOException(te);
19493
      }
19494
    }
19495
 
19496
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19497
      try {
19498
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19499
      } catch (org.apache.thrift.TException te) {
19500
        throw new java.io.IOException(te);
19501
      }
19502
    }
19503
 
19504
  }
19505
 
2820 chandransh 19506
}