Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
5945 mandeep.dh 1
/**
2
 * Autogenerated by Thrift Compiler (0.7.0)
3
 *
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
 */
6
package in.shop2020.model.v1.inventory;
7
 
8
import java.util.List;
9
import java.util.ArrayList;
10
import java.util.Map;
11
import java.util.HashMap;
12
import java.util.EnumMap;
13
import java.util.Set;
14
import java.util.HashSet;
15
import java.util.EnumSet;
16
import java.util.Collections;
17
import java.util.BitSet;
18
import java.nio.ByteBuffer;
19
import java.util.Arrays;
20
import org.slf4j.Logger;
21
import org.slf4j.LoggerFactory;
22
 
23
public class InventoryService {
24
 
25
  public interface Iface extends in.shop2020.generic.GenericService.Iface {
26
 
27
    public long addWarehouse(Warehouse warehouse) throws InventoryServiceException, org.apache.thrift.TException;
28
 
29
    /**
30
     * add a new vendor
31
     * 
32
     * @param vendor
33
     */
34
    public long addVendor(Vendor vendor) throws InventoryServiceException, org.apache.thrift.TException;
35
 
36
    /**
37
     * Stores the incremental warehouse updates of items.
38
     * 
39
     * @param warehouse_id
40
     * @param timestamp
41
     * @param availability
42
     */
43
    public void updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException;
44
 
45
    /**
46
     * Stores the final inventory stocks of items.
47
     * 
48
     * @param warehouse_id
49
     * @param timestamp
50
     * @param availability
51
     */
52
    public void updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException;
53
 
54
    /**
55
     * Add the inventory to existing stock.
56
     * 
57
     * @param itemId
58
     * @param warehouseId
59
     * @param quantity
60
     */
61
    public void addInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException;
62
 
63
    public void retireWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException;
64
 
65
    public ItemInventory getItemInventoryByItemId(long item_id) throws InventoryServiceException, org.apache.thrift.TException;
66
 
67
    public long getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws InventoryServiceException, org.apache.thrift.TException;
68
 
69
    /**
70
     * Determines the warehouse that should be used to fulfil an order for the given item.
71
     * It first checks all the warehouses which are in the logistics location given by the
72
     * warehouse_loc parameter. If none of the warehouses there have any inventory, then the
73
     * preferred warehouse for the item is used.
74
     * 
75
     * Returns an ordered list of size 4 with following elements in the given order:
76
     * 1. Id of the fulfillment warehouse which was finally picked up.
77
     * 2. Expected delay added by the category manager.
78
     * 3. Id of the billing warehouse which was finally picked up.
79
     * 
80
     * @param itemId
5978 rajveer 81
     * @param sourceId
5945 mandeep.dh 82
     */
5978 rajveer 83
    public List<Long> getItemAvailabilityAtLocation(long itemId, long sourceId) throws InventoryServiceException, org.apache.thrift.TException;
5945 mandeep.dh 84
 
85
    public List<Warehouse> getAllWarehouses(boolean isActive) throws InventoryServiceException, org.apache.thrift.TException;
86
 
87
    /**
88
     * Returns the warehouse with the given id.
89
     * 
90
     * @param warehouse_id
91
     */
92
    public Warehouse getWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException;
93
 
94
    public List<Long> getAllItemsForWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException;
95
 
96
    /**
5978 rajveer 97
     * Depending on reservation in the table, verify if we can bill this order or not.
5967 rajveer 98
     * 
99
     * @param itemId
100
     * @param warehouseId
101
     * @param sourceId
102
     * @param orderId
103
     */
104
    public boolean isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId) throws org.apache.thrift.TException;
105
 
106
    /**
5945 mandeep.dh 107
     * Increases the reservation count for an item in a warehouse. Should always succeed normally.
108
     * 
109
     * @param itemId
110
     * @param warehouseId
5967 rajveer 111
     * @param sourceId
112
     * @param orderId
113
     * @param createdTimestamp
114
     * @param promisedShippingTimestamp
5945 mandeep.dh 115
     * @param quantity
116
     */
5967 rajveer 117
    public boolean reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity) throws InventoryServiceException, org.apache.thrift.TException;
5945 mandeep.dh 118
 
119
    /**
120
     * Decreases the reservation count for an item in a warehouse. Should always succeed normally.
121
     * 
122
     * @param itemId
123
     * @param warehouseId
5967 rajveer 124
     * @param sourceId
125
     * @param orderId
5945 mandeep.dh 126
     * @param quantity
127
     */
5967 rajveer 128
    public boolean reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity) throws InventoryServiceException, org.apache.thrift.TException;
5945 mandeep.dh 129
 
130
    /**
131
     * Returns the pricing information of an item associated with the vendor of the given warehouse.
132
     * Raises an exception if either the item, vendor or the associated pricing information can't be found.
133
     * 
134
     * @param itemId
135
     * @param vendorId
136
     */
137
    public VendorItemPricing getItemPricing(long itemId, long vendorId) throws InventoryServiceException, org.apache.thrift.TException;
138
 
139
    /**
140
     * Returns the list of vendor pricing information of an item.
141
     * Raises an exception if item not found corresponding to itemId
142
     * 
143
     * @param itemId
144
     */
145
    public List<VendorItemPricing> getAllItemPricing(long itemId) throws InventoryServiceException, org.apache.thrift.TException;
146
 
147
    /**
148
     * Adds vendor prices corresponding to the item. If pricing already exists then updates the prices.
149
     * Raises an exception if either the item or vendor can't be found corresponding to their ids.
150
     * 
151
     * @param vendorItemPricing
152
     */
153
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing) throws InventoryServiceException, org.apache.thrift.TException;
154
 
155
    /**
156
     * Returns a vendor given its id
157
     * 
158
     * @param vendorId
159
     */
160
    public Vendor getVendor(long vendorId) throws org.apache.thrift.TException;
161
 
162
    /**
163
     * Return list of all vendors
164
     */
165
    public List<Vendor> getAllVendors() throws org.apache.thrift.TException;
166
 
167
    /**
168
     * Adds VendorItemMapping. Updates VendorItemMapping if exists corresponding to the item key.
169
     * 
170
     * @param key
171
     * @param vendorItemMapping
172
     */
173
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws InventoryServiceException, org.apache.thrift.TException;
174
 
175
    /**
176
     * Returns the list of vendor item mapping corresponding to itemId passed as parameter.
177
     * Raises an exception if item not found corresponding to itemId
178
     * 
179
     * @param itemId
180
     */
181
    public List<VendorItemMapping> getVendorItemMappings(long itemId) throws InventoryServiceException, org.apache.thrift.TException;
182
 
183
    /**
184
     * Returns a list of inventory stock for items for which there are pending orders for the given vendor.
185
     * 
186
     * @param vendorid
187
     */
188
    public List<AvailableAndReservedStock> getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException;
189
 
190
    /**
191
     * This method returns all warehouses for a given warehosueType, inventoryType, vendor, billingWarehouse and shippingWarehouse.
192
     * getWarehouses(WarehouseType.OURS, InventoryType.GOOD, 3, 7, 7) would return ours warehouse with GOOD type inventory for vendor 1 for billing warehouse 7 and shipping warehouse 7
193
     * getWarehouses(WarehouseType.OURS, InventoryType.GOOD, 3, 7, 7) would return ours warehouse with GOOD type inventory for vendor 3 for billing warehouse 7 and shipping warehouse 7
194
     *    getWarehouses(null, null, 3, 7, 7) would return all type warehouses with all type inventory for vendor 3 for billing warehouse 7 and shipping warehouse 7
195
     *    getWarehouses(null, null, 0, 0, 7) would return all type warehouses with all type inventory for all vendors for all billing warehouses at shipping warehouse 7
196
     * 
197
     * @param warehouseType
198
     * @param inventoryType
199
     * @param vendorId
200
     * @param billingWarehouseId
201
     * @param shippingWarehouseId
202
     */
203
    public List<Warehouse> getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException;
204
 
205
    /**
206
     * Resets availability of an item to the quantity mentioned in a warehouse.
207
     * 
208
     * @param itemKey
209
     * @param vendorId
210
     * @param quantity
211
     * @param warehouseId
212
     */
213
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws InventoryServiceException, org.apache.thrift.TException;
214
 
215
    /**
216
     * Resets availability of a warehouse to zero.
217
     * 
218
     * @param warehouseId
219
     */
220
    public void resetAvailabilityForWarehouse(long warehouseId) throws InventoryServiceException, org.apache.thrift.TException;
221
 
222
    /**
223
     * Returns the list of item keys which need to be processed for a given warehouse.
224
     * This is currently used by Support application to send item keys whose inventory needs
225
     * to be updated from PLB
226
     * 
227
     * @param warehouseId
228
     */
229
    public List<String> getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException;
230
 
231
    /**
232
     * Marks/Deletes missed inventory updates for a given key and warehouse.
233
     * This generally happens when updates from PLB are applied on the currentinventorysnapshot for an item
234
     * 
235
     * @param itemKey
236
     * @param warehouseId
237
     */
238
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException;
239
 
240
    /**
241
     * Returns all the item key mappings that have been ignored until date. Value of map has the warehouse id
242
     * and the timestamp from where alert was raised.
243
     */
244
    public Map<String,Map<Long,Long>> getIgnoredItemKeys() throws org.apache.thrift.TException;
245
 
246
    /**
247
     * Add the BAD type inventory to existing stock.
248
     * 
249
     * @param itemId
250
     * @param warehouseId
251
     * @param quantity
252
     */
253
    public void addBadInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException;
254
 
255
    /**
256
     * Returns all shipping locations
257
     */
258
    public List<Warehouse> getShippingLocations() throws org.apache.thrift.TException;
259
 
260
    /**
261
     * Fetches all the vendor item mappings present.
262
     */
263
    public List<VendorItemMapping> getAllVendorItemMappings() throws org.apache.thrift.TException;
264
 
265
    /**
266
     * Gets items' inventory for a warehouse
267
     * If warehouse is passed as zero, items' inventory across all warehouses is sent
268
     * 
269
     * @param warehouseId
270
     */
271
    public Map<Long,ItemInventory> getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException;
272
 
273
    /**
274
     * Clear item availability cache.
275
     */
276
    public void clearItemAvailabilityCache() throws org.apache.thrift.TException;
277
 
278
    public void updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException;
279
 
6096 amit.gupta 280
    public void clearItemAvailabilityCacheForItem(long item_id) throws org.apache.thrift.TException;
281
 
5945 mandeep.dh 282
  }
283
 
284
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
285
 
286
    public void addWarehouse(Warehouse warehouse, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addWarehouse_call> resultHandler) throws org.apache.thrift.TException;
287
 
288
    public void addVendor(Vendor vendor, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendor_call> resultHandler) throws org.apache.thrift.TException;
289
 
290
    public void updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updateInventoryHistory_call> resultHandler) throws org.apache.thrift.TException;
291
 
292
    public void updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updateInventory_call> resultHandler) throws org.apache.thrift.TException;
293
 
294
    public void addInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addInventory_call> resultHandler) throws org.apache.thrift.TException;
295
 
296
    public void retireWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.retireWarehouse_call> resultHandler) throws org.apache.thrift.TException;
297
 
298
    public void getItemInventoryByItemId(long item_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemInventoryByItemId_call> resultHandler) throws org.apache.thrift.TException;
299
 
300
    public void getItemAvailibilityAtWarehouse(long warehouse_id, long item_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemAvailibilityAtWarehouse_call> resultHandler) throws org.apache.thrift.TException;
301
 
5978 rajveer 302
    public void getItemAvailabilityAtLocation(long itemId, long sourceId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemAvailabilityAtLocation_call> resultHandler) throws org.apache.thrift.TException;
5945 mandeep.dh 303
 
304
    public void getAllWarehouses(boolean isActive, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllWarehouses_call> resultHandler) throws org.apache.thrift.TException;
305
 
306
    public void getWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getWarehouse_call> resultHandler) throws org.apache.thrift.TException;
307
 
308
    public void getAllItemsForWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllItemsForWarehouse_call> resultHandler) throws org.apache.thrift.TException;
309
 
5967 rajveer 310
    public void isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.isOrderBillable_call> resultHandler) throws org.apache.thrift.TException;
5945 mandeep.dh 311
 
5967 rajveer 312
    public void reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.reserveItemInWarehouse_call> resultHandler) throws org.apache.thrift.TException;
5945 mandeep.dh 313
 
5967 rajveer 314
    public void reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.reduceReservationCount_call> resultHandler) throws org.apache.thrift.TException;
315
 
5945 mandeep.dh 316
    public void getItemPricing(long itemId, long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemPricing_call> resultHandler) throws org.apache.thrift.TException;
317
 
318
    public void getAllItemPricing(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllItemPricing_call> resultHandler) throws org.apache.thrift.TException;
319
 
320
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendorItemPricing_call> resultHandler) throws org.apache.thrift.TException;
321
 
322
    public void getVendor(long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getVendor_call> resultHandler) throws org.apache.thrift.TException;
323
 
324
    public void getAllVendors(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllVendors_call> resultHandler) throws org.apache.thrift.TException;
325
 
326
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendorItemMapping_call> resultHandler) throws org.apache.thrift.TException;
327
 
328
    public void getVendorItemMappings(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException;
329
 
330
    public void getPendingOrdersInventory(long vendorid, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPendingOrdersInventory_call> resultHandler) throws org.apache.thrift.TException;
331
 
332
    public void getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getWarehouses_call> resultHandler) throws org.apache.thrift.TException;
333
 
334
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.resetAvailability_call> resultHandler) throws org.apache.thrift.TException;
335
 
336
    public void resetAvailabilityForWarehouse(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.resetAvailabilityForWarehouse_call> resultHandler) throws org.apache.thrift.TException;
337
 
338
    public void getItemKeysToBeProcessed(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemKeysToBeProcessed_call> resultHandler) throws org.apache.thrift.TException;
339
 
340
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.markMissedInventoryUpdatesAsProcessed_call> resultHandler) throws org.apache.thrift.TException;
341
 
342
    public void getIgnoredItemKeys(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getIgnoredItemKeys_call> resultHandler) throws org.apache.thrift.TException;
343
 
344
    public void addBadInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addBadInventory_call> resultHandler) throws org.apache.thrift.TException;
345
 
346
    public void getShippingLocations(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getShippingLocations_call> resultHandler) throws org.apache.thrift.TException;
347
 
348
    public void getAllVendorItemMappings(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException;
349
 
350
    public void getInventorySnapshot(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventorySnapshot_call> resultHandler) throws org.apache.thrift.TException;
351
 
352
    public void clearItemAvailabilityCache(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.clearItemAvailabilityCache_call> resultHandler) throws org.apache.thrift.TException;
353
 
354
    public void updateVendorString(long warehouseId, String vendorString, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updateVendorString_call> resultHandler) throws org.apache.thrift.TException;
355
 
6096 amit.gupta 356
    public void clearItemAvailabilityCacheForItem(long item_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.clearItemAvailabilityCacheForItem_call> resultHandler) throws org.apache.thrift.TException;
357
 
5945 mandeep.dh 358
  }
359
 
360
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
361
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
362
      public Factory() {}
363
      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
364
        return new Client(prot);
365
      }
366
      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
367
        return new Client(iprot, oprot);
368
      }
369
    }
370
 
371
    public Client(org.apache.thrift.protocol.TProtocol prot)
372
    {
373
      super(prot, prot);
374
    }
375
 
376
    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
377
      super(iprot, oprot);
378
    }
379
 
380
    public long addWarehouse(Warehouse warehouse) throws InventoryServiceException, org.apache.thrift.TException
381
    {
382
      send_addWarehouse(warehouse);
383
      return recv_addWarehouse();
384
    }
385
 
386
    public void send_addWarehouse(Warehouse warehouse) throws org.apache.thrift.TException
387
    {
388
      addWarehouse_args args = new addWarehouse_args();
389
      args.setWarehouse(warehouse);
390
      sendBase("addWarehouse", args);
391
    }
392
 
393
    public long recv_addWarehouse() throws InventoryServiceException, org.apache.thrift.TException
394
    {
395
      addWarehouse_result result = new addWarehouse_result();
396
      receiveBase(result, "addWarehouse");
397
      if (result.isSetSuccess()) {
398
        return result.success;
399
      }
400
      if (result.cex != null) {
401
        throw result.cex;
402
      }
403
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addWarehouse failed: unknown result");
404
    }
405
 
406
    public long addVendor(Vendor vendor) throws InventoryServiceException, org.apache.thrift.TException
407
    {
408
      send_addVendor(vendor);
409
      return recv_addVendor();
410
    }
411
 
412
    public void send_addVendor(Vendor vendor) throws org.apache.thrift.TException
413
    {
414
      addVendor_args args = new addVendor_args();
415
      args.setVendor(vendor);
416
      sendBase("addVendor", args);
417
    }
418
 
419
    public long recv_addVendor() throws InventoryServiceException, org.apache.thrift.TException
420
    {
421
      addVendor_result result = new addVendor_result();
422
      receiveBase(result, "addVendor");
423
      if (result.isSetSuccess()) {
424
        return result.success;
425
      }
426
      if (result.cex != null) {
427
        throw result.cex;
428
      }
429
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addVendor failed: unknown result");
430
    }
431
 
432
    public void updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException
433
    {
434
      send_updateInventoryHistory(warehouse_id, timestamp, availability);
435
      recv_updateInventoryHistory();
436
    }
437
 
438
    public void send_updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws org.apache.thrift.TException
439
    {
440
      updateInventoryHistory_args args = new updateInventoryHistory_args();
441
      args.setWarehouse_id(warehouse_id);
442
      args.setTimestamp(timestamp);
443
      args.setAvailability(availability);
444
      sendBase("updateInventoryHistory", args);
445
    }
446
 
447
    public void recv_updateInventoryHistory() throws InventoryServiceException, org.apache.thrift.TException
448
    {
449
      updateInventoryHistory_result result = new updateInventoryHistory_result();
450
      receiveBase(result, "updateInventoryHistory");
451
      if (result.cex != null) {
452
        throw result.cex;
453
      }
454
      return;
455
    }
456
 
457
    public void updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException
458
    {
459
      send_updateInventory(warehouse_id, timestamp, availability);
460
      recv_updateInventory();
461
    }
462
 
463
    public void send_updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws org.apache.thrift.TException
464
    {
465
      updateInventory_args args = new updateInventory_args();
466
      args.setWarehouse_id(warehouse_id);
467
      args.setTimestamp(timestamp);
468
      args.setAvailability(availability);
469
      sendBase("updateInventory", args);
470
    }
471
 
472
    public void recv_updateInventory() throws InventoryServiceException, org.apache.thrift.TException
473
    {
474
      updateInventory_result result = new updateInventory_result();
475
      receiveBase(result, "updateInventory");
476
      if (result.cex != null) {
477
        throw result.cex;
478
      }
479
      return;
480
    }
481
 
482
    public void addInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException
483
    {
484
      send_addInventory(itemId, warehouseId, quantity);
485
      recv_addInventory();
486
    }
487
 
488
    public void send_addInventory(long itemId, long warehouseId, long quantity) throws org.apache.thrift.TException
489
    {
490
      addInventory_args args = new addInventory_args();
491
      args.setItemId(itemId);
492
      args.setWarehouseId(warehouseId);
493
      args.setQuantity(quantity);
494
      sendBase("addInventory", args);
495
    }
496
 
497
    public void recv_addInventory() throws InventoryServiceException, org.apache.thrift.TException
498
    {
499
      addInventory_result result = new addInventory_result();
500
      receiveBase(result, "addInventory");
501
      if (result.cex != null) {
502
        throw result.cex;
503
      }
504
      return;
505
    }
506
 
507
    public void retireWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
508
    {
509
      send_retireWarehouse(warehouse_id);
510
      recv_retireWarehouse();
511
    }
512
 
513
    public void send_retireWarehouse(long warehouse_id) throws org.apache.thrift.TException
514
    {
515
      retireWarehouse_args args = new retireWarehouse_args();
516
      args.setWarehouse_id(warehouse_id);
517
      sendBase("retireWarehouse", args);
518
    }
519
 
520
    public void recv_retireWarehouse() throws InventoryServiceException, org.apache.thrift.TException
521
    {
522
      retireWarehouse_result result = new retireWarehouse_result();
523
      receiveBase(result, "retireWarehouse");
524
      if (result.cex != null) {
525
        throw result.cex;
526
      }
527
      return;
528
    }
529
 
530
    public ItemInventory getItemInventoryByItemId(long item_id) throws InventoryServiceException, org.apache.thrift.TException
531
    {
532
      send_getItemInventoryByItemId(item_id);
533
      return recv_getItemInventoryByItemId();
534
    }
535
 
536
    public void send_getItemInventoryByItemId(long item_id) throws org.apache.thrift.TException
537
    {
538
      getItemInventoryByItemId_args args = new getItemInventoryByItemId_args();
539
      args.setItem_id(item_id);
540
      sendBase("getItemInventoryByItemId", args);
541
    }
542
 
543
    public ItemInventory recv_getItemInventoryByItemId() throws InventoryServiceException, org.apache.thrift.TException
544
    {
545
      getItemInventoryByItemId_result result = new getItemInventoryByItemId_result();
546
      receiveBase(result, "getItemInventoryByItemId");
547
      if (result.isSetSuccess()) {
548
        return result.success;
549
      }
550
      if (result.cex != null) {
551
        throw result.cex;
552
      }
553
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemInventoryByItemId failed: unknown result");
554
    }
555
 
556
    public long getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws InventoryServiceException, org.apache.thrift.TException
557
    {
558
      send_getItemAvailibilityAtWarehouse(warehouse_id, item_id);
559
      return recv_getItemAvailibilityAtWarehouse();
560
    }
561
 
562
    public void send_getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws org.apache.thrift.TException
563
    {
564
      getItemAvailibilityAtWarehouse_args args = new getItemAvailibilityAtWarehouse_args();
565
      args.setWarehouse_id(warehouse_id);
566
      args.setItem_id(item_id);
567
      sendBase("getItemAvailibilityAtWarehouse", args);
568
    }
569
 
570
    public long recv_getItemAvailibilityAtWarehouse() throws InventoryServiceException, org.apache.thrift.TException
571
    {
572
      getItemAvailibilityAtWarehouse_result result = new getItemAvailibilityAtWarehouse_result();
573
      receiveBase(result, "getItemAvailibilityAtWarehouse");
574
      if (result.isSetSuccess()) {
575
        return result.success;
576
      }
577
      if (result.cex != null) {
578
        throw result.cex;
579
      }
580
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemAvailibilityAtWarehouse failed: unknown result");
581
    }
582
 
5978 rajveer 583
    public List<Long> getItemAvailabilityAtLocation(long itemId, long sourceId) throws InventoryServiceException, org.apache.thrift.TException
5945 mandeep.dh 584
    {
5978 rajveer 585
      send_getItemAvailabilityAtLocation(itemId, sourceId);
5945 mandeep.dh 586
      return recv_getItemAvailabilityAtLocation();
587
    }
588
 
5978 rajveer 589
    public void send_getItemAvailabilityAtLocation(long itemId, long sourceId) throws org.apache.thrift.TException
5945 mandeep.dh 590
    {
591
      getItemAvailabilityAtLocation_args args = new getItemAvailabilityAtLocation_args();
592
      args.setItemId(itemId);
5978 rajveer 593
      args.setSourceId(sourceId);
5945 mandeep.dh 594
      sendBase("getItemAvailabilityAtLocation", args);
595
    }
596
 
597
    public List<Long> recv_getItemAvailabilityAtLocation() throws InventoryServiceException, org.apache.thrift.TException
598
    {
599
      getItemAvailabilityAtLocation_result result = new getItemAvailabilityAtLocation_result();
600
      receiveBase(result, "getItemAvailabilityAtLocation");
601
      if (result.isSetSuccess()) {
602
        return result.success;
603
      }
604
      if (result.isex != null) {
605
        throw result.isex;
606
      }
607
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemAvailabilityAtLocation failed: unknown result");
608
    }
609
 
610
    public List<Warehouse> getAllWarehouses(boolean isActive) throws InventoryServiceException, org.apache.thrift.TException
611
    {
612
      send_getAllWarehouses(isActive);
613
      return recv_getAllWarehouses();
614
    }
615
 
616
    public void send_getAllWarehouses(boolean isActive) throws org.apache.thrift.TException
617
    {
618
      getAllWarehouses_args args = new getAllWarehouses_args();
619
      args.setIsActive(isActive);
620
      sendBase("getAllWarehouses", args);
621
    }
622
 
623
    public List<Warehouse> recv_getAllWarehouses() throws InventoryServiceException, org.apache.thrift.TException
624
    {
625
      getAllWarehouses_result result = new getAllWarehouses_result();
626
      receiveBase(result, "getAllWarehouses");
627
      if (result.isSetSuccess()) {
628
        return result.success;
629
      }
630
      if (result.cex != null) {
631
        throw result.cex;
632
      }
633
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllWarehouses failed: unknown result");
634
    }
635
 
636
    public Warehouse getWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
637
    {
638
      send_getWarehouse(warehouse_id);
639
      return recv_getWarehouse();
640
    }
641
 
642
    public void send_getWarehouse(long warehouse_id) throws org.apache.thrift.TException
643
    {
644
      getWarehouse_args args = new getWarehouse_args();
645
      args.setWarehouse_id(warehouse_id);
646
      sendBase("getWarehouse", args);
647
    }
648
 
649
    public Warehouse recv_getWarehouse() throws InventoryServiceException, org.apache.thrift.TException
650
    {
651
      getWarehouse_result result = new getWarehouse_result();
652
      receiveBase(result, "getWarehouse");
653
      if (result.isSetSuccess()) {
654
        return result.success;
655
      }
656
      if (result.cex != null) {
657
        throw result.cex;
658
      }
659
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getWarehouse failed: unknown result");
660
    }
661
 
662
    public List<Long> getAllItemsForWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
663
    {
664
      send_getAllItemsForWarehouse(warehouse_id);
665
      return recv_getAllItemsForWarehouse();
666
    }
667
 
668
    public void send_getAllItemsForWarehouse(long warehouse_id) throws org.apache.thrift.TException
669
    {
670
      getAllItemsForWarehouse_args args = new getAllItemsForWarehouse_args();
671
      args.setWarehouse_id(warehouse_id);
672
      sendBase("getAllItemsForWarehouse", args);
673
    }
674
 
675
    public List<Long> recv_getAllItemsForWarehouse() throws InventoryServiceException, org.apache.thrift.TException
676
    {
677
      getAllItemsForWarehouse_result result = new getAllItemsForWarehouse_result();
678
      receiveBase(result, "getAllItemsForWarehouse");
679
      if (result.isSetSuccess()) {
680
        return result.success;
681
      }
682
      if (result.cex != null) {
683
        throw result.cex;
684
      }
685
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllItemsForWarehouse failed: unknown result");
686
    }
687
 
5967 rajveer 688
    public boolean isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId) throws org.apache.thrift.TException
5945 mandeep.dh 689
    {
5967 rajveer 690
      send_isOrderBillable(itemId, warehouseId, sourceId, orderId);
691
      return recv_isOrderBillable();
692
    }
693
 
694
    public void send_isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId) throws org.apache.thrift.TException
695
    {
696
      isOrderBillable_args args = new isOrderBillable_args();
697
      args.setItemId(itemId);
698
      args.setWarehouseId(warehouseId);
699
      args.setSourceId(sourceId);
700
      args.setOrderId(orderId);
701
      sendBase("isOrderBillable", args);
702
    }
703
 
704
    public boolean recv_isOrderBillable() throws org.apache.thrift.TException
705
    {
706
      isOrderBillable_result result = new isOrderBillable_result();
707
      receiveBase(result, "isOrderBillable");
708
      if (result.isSetSuccess()) {
709
        return result.success;
710
      }
711
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "isOrderBillable failed: unknown result");
712
    }
713
 
714
    public boolean reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity) throws InventoryServiceException, org.apache.thrift.TException
715
    {
716
      send_reserveItemInWarehouse(itemId, warehouseId, sourceId, orderId, createdTimestamp, promisedShippingTimestamp, quantity);
5945 mandeep.dh 717
      return recv_reserveItemInWarehouse();
718
    }
719
 
5967 rajveer 720
    public void send_reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity) throws org.apache.thrift.TException
5945 mandeep.dh 721
    {
722
      reserveItemInWarehouse_args args = new reserveItemInWarehouse_args();
723
      args.setItemId(itemId);
724
      args.setWarehouseId(warehouseId);
5967 rajveer 725
      args.setSourceId(sourceId);
726
      args.setOrderId(orderId);
727
      args.setCreatedTimestamp(createdTimestamp);
728
      args.setPromisedShippingTimestamp(promisedShippingTimestamp);
5945 mandeep.dh 729
      args.setQuantity(quantity);
730
      sendBase("reserveItemInWarehouse", args);
731
    }
732
 
733
    public boolean recv_reserveItemInWarehouse() throws InventoryServiceException, org.apache.thrift.TException
734
    {
735
      reserveItemInWarehouse_result result = new reserveItemInWarehouse_result();
736
      receiveBase(result, "reserveItemInWarehouse");
737
      if (result.isSetSuccess()) {
738
        return result.success;
739
      }
740
      if (result.cex != null) {
741
        throw result.cex;
742
      }
743
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "reserveItemInWarehouse failed: unknown result");
744
    }
745
 
5967 rajveer 746
    public boolean reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity) throws InventoryServiceException, org.apache.thrift.TException
5945 mandeep.dh 747
    {
5967 rajveer 748
      send_reduceReservationCount(itemId, warehouseId, sourceId, orderId, quantity);
5945 mandeep.dh 749
      return recv_reduceReservationCount();
750
    }
751
 
5967 rajveer 752
    public void send_reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity) throws org.apache.thrift.TException
5945 mandeep.dh 753
    {
754
      reduceReservationCount_args args = new reduceReservationCount_args();
755
      args.setItemId(itemId);
756
      args.setWarehouseId(warehouseId);
5967 rajveer 757
      args.setSourceId(sourceId);
758
      args.setOrderId(orderId);
5945 mandeep.dh 759
      args.setQuantity(quantity);
760
      sendBase("reduceReservationCount", args);
761
    }
762
 
763
    public boolean recv_reduceReservationCount() throws InventoryServiceException, org.apache.thrift.TException
764
    {
765
      reduceReservationCount_result result = new reduceReservationCount_result();
766
      receiveBase(result, "reduceReservationCount");
767
      if (result.isSetSuccess()) {
768
        return result.success;
769
      }
770
      if (result.cex != null) {
771
        throw result.cex;
772
      }
773
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "reduceReservationCount failed: unknown result");
774
    }
775
 
776
    public VendorItemPricing getItemPricing(long itemId, long vendorId) throws InventoryServiceException, org.apache.thrift.TException
777
    {
778
      send_getItemPricing(itemId, vendorId);
779
      return recv_getItemPricing();
780
    }
781
 
782
    public void send_getItemPricing(long itemId, long vendorId) throws org.apache.thrift.TException
783
    {
784
      getItemPricing_args args = new getItemPricing_args();
785
      args.setItemId(itemId);
786
      args.setVendorId(vendorId);
787
      sendBase("getItemPricing", args);
788
    }
789
 
790
    public VendorItemPricing recv_getItemPricing() throws InventoryServiceException, org.apache.thrift.TException
791
    {
792
      getItemPricing_result result = new getItemPricing_result();
793
      receiveBase(result, "getItemPricing");
794
      if (result.isSetSuccess()) {
795
        return result.success;
796
      }
797
      if (result.cex != null) {
798
        throw result.cex;
799
      }
800
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemPricing failed: unknown result");
801
    }
802
 
803
    public List<VendorItemPricing> getAllItemPricing(long itemId) throws InventoryServiceException, org.apache.thrift.TException
804
    {
805
      send_getAllItemPricing(itemId);
806
      return recv_getAllItemPricing();
807
    }
808
 
809
    public void send_getAllItemPricing(long itemId) throws org.apache.thrift.TException
810
    {
811
      getAllItemPricing_args args = new getAllItemPricing_args();
812
      args.setItemId(itemId);
813
      sendBase("getAllItemPricing", args);
814
    }
815
 
816
    public List<VendorItemPricing> recv_getAllItemPricing() throws InventoryServiceException, org.apache.thrift.TException
817
    {
818
      getAllItemPricing_result result = new getAllItemPricing_result();
819
      receiveBase(result, "getAllItemPricing");
820
      if (result.isSetSuccess()) {
821
        return result.success;
822
      }
823
      if (result.cex != null) {
824
        throw result.cex;
825
      }
826
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllItemPricing failed: unknown result");
827
    }
828
 
829
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing) throws InventoryServiceException, org.apache.thrift.TException
830
    {
831
      send_addVendorItemPricing(vendorItemPricing);
832
      recv_addVendorItemPricing();
833
    }
834
 
835
    public void send_addVendorItemPricing(VendorItemPricing vendorItemPricing) throws org.apache.thrift.TException
836
    {
837
      addVendorItemPricing_args args = new addVendorItemPricing_args();
838
      args.setVendorItemPricing(vendorItemPricing);
839
      sendBase("addVendorItemPricing", args);
840
    }
841
 
842
    public void recv_addVendorItemPricing() throws InventoryServiceException, org.apache.thrift.TException
843
    {
844
      addVendorItemPricing_result result = new addVendorItemPricing_result();
845
      receiveBase(result, "addVendorItemPricing");
846
      if (result.cex != null) {
847
        throw result.cex;
848
      }
849
      return;
850
    }
851
 
852
    public Vendor getVendor(long vendorId) throws org.apache.thrift.TException
853
    {
854
      send_getVendor(vendorId);
855
      return recv_getVendor();
856
    }
857
 
858
    public void send_getVendor(long vendorId) throws org.apache.thrift.TException
859
    {
860
      getVendor_args args = new getVendor_args();
861
      args.setVendorId(vendorId);
862
      sendBase("getVendor", args);
863
    }
864
 
865
    public Vendor recv_getVendor() throws org.apache.thrift.TException
866
    {
867
      getVendor_result result = new getVendor_result();
868
      receiveBase(result, "getVendor");
869
      if (result.isSetSuccess()) {
870
        return result.success;
871
      }
872
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getVendor failed: unknown result");
873
    }
874
 
875
    public List<Vendor> getAllVendors() throws org.apache.thrift.TException
876
    {
877
      send_getAllVendors();
878
      return recv_getAllVendors();
879
    }
880
 
881
    public void send_getAllVendors() throws org.apache.thrift.TException
882
    {
883
      getAllVendors_args args = new getAllVendors_args();
884
      sendBase("getAllVendors", args);
885
    }
886
 
887
    public List<Vendor> recv_getAllVendors() throws org.apache.thrift.TException
888
    {
889
      getAllVendors_result result = new getAllVendors_result();
890
      receiveBase(result, "getAllVendors");
891
      if (result.isSetSuccess()) {
892
        return result.success;
893
      }
894
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllVendors failed: unknown result");
895
    }
896
 
897
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws InventoryServiceException, org.apache.thrift.TException
898
    {
899
      send_addVendorItemMapping(key, vendorItemMapping);
900
      recv_addVendorItemMapping();
901
    }
902
 
903
    public void send_addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws org.apache.thrift.TException
904
    {
905
      addVendorItemMapping_args args = new addVendorItemMapping_args();
906
      args.setKey(key);
907
      args.setVendorItemMapping(vendorItemMapping);
908
      sendBase("addVendorItemMapping", args);
909
    }
910
 
911
    public void recv_addVendorItemMapping() throws InventoryServiceException, org.apache.thrift.TException
912
    {
913
      addVendorItemMapping_result result = new addVendorItemMapping_result();
914
      receiveBase(result, "addVendorItemMapping");
915
      if (result.cex != null) {
916
        throw result.cex;
917
      }
918
      return;
919
    }
920
 
921
    public List<VendorItemMapping> getVendorItemMappings(long itemId) throws InventoryServiceException, org.apache.thrift.TException
922
    {
923
      send_getVendorItemMappings(itemId);
924
      return recv_getVendorItemMappings();
925
    }
926
 
927
    public void send_getVendorItemMappings(long itemId) throws org.apache.thrift.TException
928
    {
929
      getVendorItemMappings_args args = new getVendorItemMappings_args();
930
      args.setItemId(itemId);
931
      sendBase("getVendorItemMappings", args);
932
    }
933
 
934
    public List<VendorItemMapping> recv_getVendorItemMappings() throws InventoryServiceException, org.apache.thrift.TException
935
    {
936
      getVendorItemMappings_result result = new getVendorItemMappings_result();
937
      receiveBase(result, "getVendorItemMappings");
938
      if (result.isSetSuccess()) {
939
        return result.success;
940
      }
941
      if (result.cex != null) {
942
        throw result.cex;
943
      }
944
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getVendorItemMappings failed: unknown result");
945
    }
946
 
947
    public List<AvailableAndReservedStock> getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException
948
    {
949
      send_getPendingOrdersInventory(vendorid);
950
      return recv_getPendingOrdersInventory();
951
    }
952
 
953
    public void send_getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException
954
    {
955
      getPendingOrdersInventory_args args = new getPendingOrdersInventory_args();
956
      args.setVendorid(vendorid);
957
      sendBase("getPendingOrdersInventory", args);
958
    }
959
 
960
    public List<AvailableAndReservedStock> recv_getPendingOrdersInventory() throws org.apache.thrift.TException
961
    {
962
      getPendingOrdersInventory_result result = new getPendingOrdersInventory_result();
963
      receiveBase(result, "getPendingOrdersInventory");
964
      if (result.isSetSuccess()) {
965
        return result.success;
966
      }
967
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPendingOrdersInventory failed: unknown result");
968
    }
969
 
970
    public List<Warehouse> getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException
971
    {
972
      send_getWarehouses(warehouseType, inventoryType, vendorId, billingWarehouseId, shippingWarehouseId);
973
      return recv_getWarehouses();
974
    }
975
 
976
    public void send_getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException
977
    {
978
      getWarehouses_args args = new getWarehouses_args();
979
      args.setWarehouseType(warehouseType);
980
      args.setInventoryType(inventoryType);
981
      args.setVendorId(vendorId);
982
      args.setBillingWarehouseId(billingWarehouseId);
983
      args.setShippingWarehouseId(shippingWarehouseId);
984
      sendBase("getWarehouses", args);
985
    }
986
 
987
    public List<Warehouse> recv_getWarehouses() throws org.apache.thrift.TException
988
    {
989
      getWarehouses_result result = new getWarehouses_result();
990
      receiveBase(result, "getWarehouses");
991
      if (result.isSetSuccess()) {
992
        return result.success;
993
      }
994
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getWarehouses failed: unknown result");
995
    }
996
 
997
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws InventoryServiceException, org.apache.thrift.TException
998
    {
999
      send_resetAvailability(itemKey, vendorId, quantity, warehouseId);
1000
      recv_resetAvailability();
1001
    }
1002
 
1003
    public void send_resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws org.apache.thrift.TException
1004
    {
1005
      resetAvailability_args args = new resetAvailability_args();
1006
      args.setItemKey(itemKey);
1007
      args.setVendorId(vendorId);
1008
      args.setQuantity(quantity);
1009
      args.setWarehouseId(warehouseId);
1010
      sendBase("resetAvailability", args);
1011
    }
1012
 
1013
    public void recv_resetAvailability() throws InventoryServiceException, org.apache.thrift.TException
1014
    {
1015
      resetAvailability_result result = new resetAvailability_result();
1016
      receiveBase(result, "resetAvailability");
1017
      if (result.cex != null) {
1018
        throw result.cex;
1019
      }
1020
      return;
1021
    }
1022
 
1023
    public void resetAvailabilityForWarehouse(long warehouseId) throws InventoryServiceException, org.apache.thrift.TException
1024
    {
1025
      send_resetAvailabilityForWarehouse(warehouseId);
1026
      recv_resetAvailabilityForWarehouse();
1027
    }
1028
 
1029
    public void send_resetAvailabilityForWarehouse(long warehouseId) throws org.apache.thrift.TException
1030
    {
1031
      resetAvailabilityForWarehouse_args args = new resetAvailabilityForWarehouse_args();
1032
      args.setWarehouseId(warehouseId);
1033
      sendBase("resetAvailabilityForWarehouse", args);
1034
    }
1035
 
1036
    public void recv_resetAvailabilityForWarehouse() throws InventoryServiceException, org.apache.thrift.TException
1037
    {
1038
      resetAvailabilityForWarehouse_result result = new resetAvailabilityForWarehouse_result();
1039
      receiveBase(result, "resetAvailabilityForWarehouse");
1040
      if (result.cex != null) {
1041
        throw result.cex;
1042
      }
1043
      return;
1044
    }
1045
 
1046
    public List<String> getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException
1047
    {
1048
      send_getItemKeysToBeProcessed(warehouseId);
1049
      return recv_getItemKeysToBeProcessed();
1050
    }
1051
 
1052
    public void send_getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException
1053
    {
1054
      getItemKeysToBeProcessed_args args = new getItemKeysToBeProcessed_args();
1055
      args.setWarehouseId(warehouseId);
1056
      sendBase("getItemKeysToBeProcessed", args);
1057
    }
1058
 
1059
    public List<String> recv_getItemKeysToBeProcessed() throws org.apache.thrift.TException
1060
    {
1061
      getItemKeysToBeProcessed_result result = new getItemKeysToBeProcessed_result();
1062
      receiveBase(result, "getItemKeysToBeProcessed");
1063
      if (result.isSetSuccess()) {
1064
        return result.success;
1065
      }
1066
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemKeysToBeProcessed failed: unknown result");
1067
    }
1068
 
1069
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException
1070
    {
1071
      send_markMissedInventoryUpdatesAsProcessed(itemKey, warehouseId);
1072
      recv_markMissedInventoryUpdatesAsProcessed();
1073
    }
1074
 
1075
    public void send_markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException
1076
    {
1077
      markMissedInventoryUpdatesAsProcessed_args args = new markMissedInventoryUpdatesAsProcessed_args();
1078
      args.setItemKey(itemKey);
1079
      args.setWarehouseId(warehouseId);
1080
      sendBase("markMissedInventoryUpdatesAsProcessed", args);
1081
    }
1082
 
1083
    public void recv_markMissedInventoryUpdatesAsProcessed() throws org.apache.thrift.TException
1084
    {
1085
      markMissedInventoryUpdatesAsProcessed_result result = new markMissedInventoryUpdatesAsProcessed_result();
1086
      receiveBase(result, "markMissedInventoryUpdatesAsProcessed");
1087
      return;
1088
    }
1089
 
1090
    public Map<String,Map<Long,Long>> getIgnoredItemKeys() throws org.apache.thrift.TException
1091
    {
1092
      send_getIgnoredItemKeys();
1093
      return recv_getIgnoredItemKeys();
1094
    }
1095
 
1096
    public void send_getIgnoredItemKeys() throws org.apache.thrift.TException
1097
    {
1098
      getIgnoredItemKeys_args args = new getIgnoredItemKeys_args();
1099
      sendBase("getIgnoredItemKeys", args);
1100
    }
1101
 
1102
    public Map<String,Map<Long,Long>> recv_getIgnoredItemKeys() throws org.apache.thrift.TException
1103
    {
1104
      getIgnoredItemKeys_result result = new getIgnoredItemKeys_result();
1105
      receiveBase(result, "getIgnoredItemKeys");
1106
      if (result.isSetSuccess()) {
1107
        return result.success;
1108
      }
1109
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getIgnoredItemKeys failed: unknown result");
1110
    }
1111
 
1112
    public void addBadInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException
1113
    {
1114
      send_addBadInventory(itemId, warehouseId, quantity);
1115
      recv_addBadInventory();
1116
    }
1117
 
1118
    public void send_addBadInventory(long itemId, long warehouseId, long quantity) throws org.apache.thrift.TException
1119
    {
1120
      addBadInventory_args args = new addBadInventory_args();
1121
      args.setItemId(itemId);
1122
      args.setWarehouseId(warehouseId);
1123
      args.setQuantity(quantity);
1124
      sendBase("addBadInventory", args);
1125
    }
1126
 
1127
    public void recv_addBadInventory() throws InventoryServiceException, org.apache.thrift.TException
1128
    {
1129
      addBadInventory_result result = new addBadInventory_result();
1130
      receiveBase(result, "addBadInventory");
1131
      if (result.cex != null) {
1132
        throw result.cex;
1133
      }
1134
      return;
1135
    }
1136
 
1137
    public List<Warehouse> getShippingLocations() throws org.apache.thrift.TException
1138
    {
1139
      send_getShippingLocations();
1140
      return recv_getShippingLocations();
1141
    }
1142
 
1143
    public void send_getShippingLocations() throws org.apache.thrift.TException
1144
    {
1145
      getShippingLocations_args args = new getShippingLocations_args();
1146
      sendBase("getShippingLocations", args);
1147
    }
1148
 
1149
    public List<Warehouse> recv_getShippingLocations() throws org.apache.thrift.TException
1150
    {
1151
      getShippingLocations_result result = new getShippingLocations_result();
1152
      receiveBase(result, "getShippingLocations");
1153
      if (result.isSetSuccess()) {
1154
        return result.success;
1155
      }
1156
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getShippingLocations failed: unknown result");
1157
    }
1158
 
1159
    public List<VendorItemMapping> getAllVendorItemMappings() throws org.apache.thrift.TException
1160
    {
1161
      send_getAllVendorItemMappings();
1162
      return recv_getAllVendorItemMappings();
1163
    }
1164
 
1165
    public void send_getAllVendorItemMappings() throws org.apache.thrift.TException
1166
    {
1167
      getAllVendorItemMappings_args args = new getAllVendorItemMappings_args();
1168
      sendBase("getAllVendorItemMappings", args);
1169
    }
1170
 
1171
    public List<VendorItemMapping> recv_getAllVendorItemMappings() throws org.apache.thrift.TException
1172
    {
1173
      getAllVendorItemMappings_result result = new getAllVendorItemMappings_result();
1174
      receiveBase(result, "getAllVendorItemMappings");
1175
      if (result.isSetSuccess()) {
1176
        return result.success;
1177
      }
1178
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllVendorItemMappings failed: unknown result");
1179
    }
1180
 
1181
    public Map<Long,ItemInventory> getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException
1182
    {
1183
      send_getInventorySnapshot(warehouseId);
1184
      return recv_getInventorySnapshot();
1185
    }
1186
 
1187
    public void send_getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException
1188
    {
1189
      getInventorySnapshot_args args = new getInventorySnapshot_args();
1190
      args.setWarehouseId(warehouseId);
1191
      sendBase("getInventorySnapshot", args);
1192
    }
1193
 
1194
    public Map<Long,ItemInventory> recv_getInventorySnapshot() throws org.apache.thrift.TException
1195
    {
1196
      getInventorySnapshot_result result = new getInventorySnapshot_result();
1197
      receiveBase(result, "getInventorySnapshot");
1198
      if (result.isSetSuccess()) {
1199
        return result.success;
1200
      }
1201
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventorySnapshot failed: unknown result");
1202
    }
1203
 
1204
    public void clearItemAvailabilityCache() throws org.apache.thrift.TException
1205
    {
1206
      send_clearItemAvailabilityCache();
1207
      recv_clearItemAvailabilityCache();
1208
    }
1209
 
1210
    public void send_clearItemAvailabilityCache() throws org.apache.thrift.TException
1211
    {
1212
      clearItemAvailabilityCache_args args = new clearItemAvailabilityCache_args();
1213
      sendBase("clearItemAvailabilityCache", args);
1214
    }
1215
 
1216
    public void recv_clearItemAvailabilityCache() throws org.apache.thrift.TException
1217
    {
1218
      clearItemAvailabilityCache_result result = new clearItemAvailabilityCache_result();
1219
      receiveBase(result, "clearItemAvailabilityCache");
1220
      return;
1221
    }
1222
 
1223
    public void updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException
1224
    {
1225
      send_updateVendorString(warehouseId, vendorString);
1226
      recv_updateVendorString();
1227
    }
1228
 
1229
    public void send_updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException
1230
    {
1231
      updateVendorString_args args = new updateVendorString_args();
1232
      args.setWarehouseId(warehouseId);
1233
      args.setVendorString(vendorString);
1234
      sendBase("updateVendorString", args);
1235
    }
1236
 
1237
    public void recv_updateVendorString() throws org.apache.thrift.TException
1238
    {
1239
      updateVendorString_result result = new updateVendorString_result();
1240
      receiveBase(result, "updateVendorString");
1241
      return;
1242
    }
1243
 
6096 amit.gupta 1244
    public void clearItemAvailabilityCacheForItem(long item_id) throws org.apache.thrift.TException
1245
    {
1246
      send_clearItemAvailabilityCacheForItem(item_id);
1247
      recv_clearItemAvailabilityCacheForItem();
1248
    }
1249
 
1250
    public void send_clearItemAvailabilityCacheForItem(long item_id) throws org.apache.thrift.TException
1251
    {
1252
      clearItemAvailabilityCacheForItem_args args = new clearItemAvailabilityCacheForItem_args();
1253
      args.setItem_id(item_id);
1254
      sendBase("clearItemAvailabilityCacheForItem", args);
1255
    }
1256
 
1257
    public void recv_clearItemAvailabilityCacheForItem() throws org.apache.thrift.TException
1258
    {
1259
      clearItemAvailabilityCacheForItem_result result = new clearItemAvailabilityCacheForItem_result();
1260
      receiveBase(result, "clearItemAvailabilityCacheForItem");
1261
      return;
1262
    }
1263
 
5945 mandeep.dh 1264
  }
1265
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
1266
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
1267
      private org.apache.thrift.async.TAsyncClientManager clientManager;
1268
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
1269
      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
1270
        this.clientManager = clientManager;
1271
        this.protocolFactory = protocolFactory;
1272
      }
1273
      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
1274
        return new AsyncClient(protocolFactory, clientManager, transport);
1275
      }
1276
    }
1277
 
1278
    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
1279
      super(protocolFactory, clientManager, transport);
1280
    }
1281
 
1282
    public void addWarehouse(Warehouse warehouse, org.apache.thrift.async.AsyncMethodCallback<addWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1283
      checkReady();
1284
      addWarehouse_call method_call = new addWarehouse_call(warehouse, resultHandler, this, ___protocolFactory, ___transport);
1285
      this.___currentMethod = method_call;
1286
      ___manager.call(method_call);
1287
    }
1288
 
1289
    public static class addWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1290
      private Warehouse warehouse;
1291
      public addWarehouse_call(Warehouse warehouse, org.apache.thrift.async.AsyncMethodCallback<addWarehouse_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 {
1292
        super(client, protocolFactory, transport, resultHandler, false);
1293
        this.warehouse = warehouse;
1294
      }
1295
 
1296
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1297
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1298
        addWarehouse_args args = new addWarehouse_args();
1299
        args.setWarehouse(warehouse);
1300
        args.write(prot);
1301
        prot.writeMessageEnd();
1302
      }
1303
 
1304
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1305
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1306
          throw new IllegalStateException("Method call not finished!");
1307
        }
1308
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1309
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1310
        return (new Client(prot)).recv_addWarehouse();
1311
      }
1312
    }
1313
 
1314
    public void addVendor(Vendor vendor, org.apache.thrift.async.AsyncMethodCallback<addVendor_call> resultHandler) throws org.apache.thrift.TException {
1315
      checkReady();
1316
      addVendor_call method_call = new addVendor_call(vendor, resultHandler, this, ___protocolFactory, ___transport);
1317
      this.___currentMethod = method_call;
1318
      ___manager.call(method_call);
1319
    }
1320
 
1321
    public static class addVendor_call extends org.apache.thrift.async.TAsyncMethodCall {
1322
      private Vendor vendor;
1323
      public addVendor_call(Vendor vendor, org.apache.thrift.async.AsyncMethodCallback<addVendor_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 {
1324
        super(client, protocolFactory, transport, resultHandler, false);
1325
        this.vendor = vendor;
1326
      }
1327
 
1328
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1329
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendor", org.apache.thrift.protocol.TMessageType.CALL, 0));
1330
        addVendor_args args = new addVendor_args();
1331
        args.setVendor(vendor);
1332
        args.write(prot);
1333
        prot.writeMessageEnd();
1334
      }
1335
 
1336
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1337
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1338
          throw new IllegalStateException("Method call not finished!");
1339
        }
1340
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1341
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1342
        return (new Client(prot)).recv_addVendor();
1343
      }
1344
    }
1345
 
1346
    public void updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability, org.apache.thrift.async.AsyncMethodCallback<updateInventoryHistory_call> resultHandler) throws org.apache.thrift.TException {
1347
      checkReady();
1348
      updateInventoryHistory_call method_call = new updateInventoryHistory_call(warehouse_id, timestamp, availability, resultHandler, this, ___protocolFactory, ___transport);
1349
      this.___currentMethod = method_call;
1350
      ___manager.call(method_call);
1351
    }
1352
 
1353
    public static class updateInventoryHistory_call extends org.apache.thrift.async.TAsyncMethodCall {
1354
      private long warehouse_id;
1355
      private String timestamp;
1356
      private Map<String,Long> availability;
1357
      public updateInventoryHistory_call(long warehouse_id, String timestamp, Map<String,Long> availability, org.apache.thrift.async.AsyncMethodCallback<updateInventoryHistory_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 {
1358
        super(client, protocolFactory, transport, resultHandler, false);
1359
        this.warehouse_id = warehouse_id;
1360
        this.timestamp = timestamp;
1361
        this.availability = availability;
1362
      }
1363
 
1364
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1365
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateInventoryHistory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1366
        updateInventoryHistory_args args = new updateInventoryHistory_args();
1367
        args.setWarehouse_id(warehouse_id);
1368
        args.setTimestamp(timestamp);
1369
        args.setAvailability(availability);
1370
        args.write(prot);
1371
        prot.writeMessageEnd();
1372
      }
1373
 
1374
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1375
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1376
          throw new IllegalStateException("Method call not finished!");
1377
        }
1378
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1379
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1380
        (new Client(prot)).recv_updateInventoryHistory();
1381
      }
1382
    }
1383
 
1384
    public void updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability, org.apache.thrift.async.AsyncMethodCallback<updateInventory_call> resultHandler) throws org.apache.thrift.TException {
1385
      checkReady();
1386
      updateInventory_call method_call = new updateInventory_call(warehouse_id, timestamp, availability, resultHandler, this, ___protocolFactory, ___transport);
1387
      this.___currentMethod = method_call;
1388
      ___manager.call(method_call);
1389
    }
1390
 
1391
    public static class updateInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
1392
      private long warehouse_id;
1393
      private String timestamp;
1394
      private Map<String,Long> availability;
1395
      public updateInventory_call(long warehouse_id, String timestamp, Map<String,Long> availability, org.apache.thrift.async.AsyncMethodCallback<updateInventory_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 {
1396
        super(client, protocolFactory, transport, resultHandler, false);
1397
        this.warehouse_id = warehouse_id;
1398
        this.timestamp = timestamp;
1399
        this.availability = availability;
1400
      }
1401
 
1402
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1403
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1404
        updateInventory_args args = new updateInventory_args();
1405
        args.setWarehouse_id(warehouse_id);
1406
        args.setTimestamp(timestamp);
1407
        args.setAvailability(availability);
1408
        args.write(prot);
1409
        prot.writeMessageEnd();
1410
      }
1411
 
1412
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1413
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1414
          throw new IllegalStateException("Method call not finished!");
1415
        }
1416
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1417
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1418
        (new Client(prot)).recv_updateInventory();
1419
      }
1420
    }
1421
 
1422
    public void addInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addInventory_call> resultHandler) throws org.apache.thrift.TException {
1423
      checkReady();
1424
      addInventory_call method_call = new addInventory_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
1425
      this.___currentMethod = method_call;
1426
      ___manager.call(method_call);
1427
    }
1428
 
1429
    public static class addInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
1430
      private long itemId;
1431
      private long warehouseId;
1432
      private long quantity;
1433
      public addInventory_call(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addInventory_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 {
1434
        super(client, protocolFactory, transport, resultHandler, false);
1435
        this.itemId = itemId;
1436
        this.warehouseId = warehouseId;
1437
        this.quantity = quantity;
1438
      }
1439
 
1440
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1441
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1442
        addInventory_args args = new addInventory_args();
1443
        args.setItemId(itemId);
1444
        args.setWarehouseId(warehouseId);
1445
        args.setQuantity(quantity);
1446
        args.write(prot);
1447
        prot.writeMessageEnd();
1448
      }
1449
 
1450
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1451
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1452
          throw new IllegalStateException("Method call not finished!");
1453
        }
1454
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1455
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1456
        (new Client(prot)).recv_addInventory();
1457
      }
1458
    }
1459
 
1460
    public void retireWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<retireWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1461
      checkReady();
1462
      retireWarehouse_call method_call = new retireWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1463
      this.___currentMethod = method_call;
1464
      ___manager.call(method_call);
1465
    }
1466
 
1467
    public static class retireWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1468
      private long warehouse_id;
1469
      public retireWarehouse_call(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<retireWarehouse_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 {
1470
        super(client, protocolFactory, transport, resultHandler, false);
1471
        this.warehouse_id = warehouse_id;
1472
      }
1473
 
1474
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1475
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("retireWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1476
        retireWarehouse_args args = new retireWarehouse_args();
1477
        args.setWarehouse_id(warehouse_id);
1478
        args.write(prot);
1479
        prot.writeMessageEnd();
1480
      }
1481
 
1482
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1483
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1484
          throw new IllegalStateException("Method call not finished!");
1485
        }
1486
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1487
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1488
        (new Client(prot)).recv_retireWarehouse();
1489
      }
1490
    }
1491
 
1492
    public void getItemInventoryByItemId(long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemInventoryByItemId_call> resultHandler) throws org.apache.thrift.TException {
1493
      checkReady();
1494
      getItemInventoryByItemId_call method_call = new getItemInventoryByItemId_call(item_id, resultHandler, this, ___protocolFactory, ___transport);
1495
      this.___currentMethod = method_call;
1496
      ___manager.call(method_call);
1497
    }
1498
 
1499
    public static class getItemInventoryByItemId_call extends org.apache.thrift.async.TAsyncMethodCall {
1500
      private long item_id;
1501
      public getItemInventoryByItemId_call(long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemInventoryByItemId_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 {
1502
        super(client, protocolFactory, transport, resultHandler, false);
1503
        this.item_id = item_id;
1504
      }
1505
 
1506
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1507
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemInventoryByItemId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1508
        getItemInventoryByItemId_args args = new getItemInventoryByItemId_args();
1509
        args.setItem_id(item_id);
1510
        args.write(prot);
1511
        prot.writeMessageEnd();
1512
      }
1513
 
1514
      public ItemInventory getResult() throws InventoryServiceException, org.apache.thrift.TException {
1515
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1516
          throw new IllegalStateException("Method call not finished!");
1517
        }
1518
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1519
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1520
        return (new Client(prot)).recv_getItemInventoryByItemId();
1521
      }
1522
    }
1523
 
1524
    public void getItemAvailibilityAtWarehouse(long warehouse_id, long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemAvailibilityAtWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1525
      checkReady();
1526
      getItemAvailibilityAtWarehouse_call method_call = new getItemAvailibilityAtWarehouse_call(warehouse_id, item_id, resultHandler, this, ___protocolFactory, ___transport);
1527
      this.___currentMethod = method_call;
1528
      ___manager.call(method_call);
1529
    }
1530
 
1531
    public static class getItemAvailibilityAtWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1532
      private long warehouse_id;
1533
      private long item_id;
1534
      public getItemAvailibilityAtWarehouse_call(long warehouse_id, long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemAvailibilityAtWarehouse_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 {
1535
        super(client, protocolFactory, transport, resultHandler, false);
1536
        this.warehouse_id = warehouse_id;
1537
        this.item_id = item_id;
1538
      }
1539
 
1540
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1541
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemAvailibilityAtWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1542
        getItemAvailibilityAtWarehouse_args args = new getItemAvailibilityAtWarehouse_args();
1543
        args.setWarehouse_id(warehouse_id);
1544
        args.setItem_id(item_id);
1545
        args.write(prot);
1546
        prot.writeMessageEnd();
1547
      }
1548
 
1549
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1550
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1551
          throw new IllegalStateException("Method call not finished!");
1552
        }
1553
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1554
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1555
        return (new Client(prot)).recv_getItemAvailibilityAtWarehouse();
1556
      }
1557
    }
1558
 
5978 rajveer 1559
    public void getItemAvailabilityAtLocation(long itemId, long sourceId, org.apache.thrift.async.AsyncMethodCallback<getItemAvailabilityAtLocation_call> resultHandler) throws org.apache.thrift.TException {
5945 mandeep.dh 1560
      checkReady();
5978 rajveer 1561
      getItemAvailabilityAtLocation_call method_call = new getItemAvailabilityAtLocation_call(itemId, sourceId, resultHandler, this, ___protocolFactory, ___transport);
5945 mandeep.dh 1562
      this.___currentMethod = method_call;
1563
      ___manager.call(method_call);
1564
    }
1565
 
1566
    public static class getItemAvailabilityAtLocation_call extends org.apache.thrift.async.TAsyncMethodCall {
1567
      private long itemId;
5978 rajveer 1568
      private long sourceId;
1569
      public getItemAvailabilityAtLocation_call(long itemId, long sourceId, org.apache.thrift.async.AsyncMethodCallback<getItemAvailabilityAtLocation_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 {
5945 mandeep.dh 1570
        super(client, protocolFactory, transport, resultHandler, false);
1571
        this.itemId = itemId;
5978 rajveer 1572
        this.sourceId = sourceId;
5945 mandeep.dh 1573
      }
1574
 
1575
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1576
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemAvailabilityAtLocation", org.apache.thrift.protocol.TMessageType.CALL, 0));
1577
        getItemAvailabilityAtLocation_args args = new getItemAvailabilityAtLocation_args();
1578
        args.setItemId(itemId);
5978 rajveer 1579
        args.setSourceId(sourceId);
5945 mandeep.dh 1580
        args.write(prot);
1581
        prot.writeMessageEnd();
1582
      }
1583
 
1584
      public List<Long> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1585
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1586
          throw new IllegalStateException("Method call not finished!");
1587
        }
1588
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1589
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1590
        return (new Client(prot)).recv_getItemAvailabilityAtLocation();
1591
      }
1592
    }
1593
 
1594
    public void getAllWarehouses(boolean isActive, org.apache.thrift.async.AsyncMethodCallback<getAllWarehouses_call> resultHandler) throws org.apache.thrift.TException {
1595
      checkReady();
1596
      getAllWarehouses_call method_call = new getAllWarehouses_call(isActive, resultHandler, this, ___protocolFactory, ___transport);
1597
      this.___currentMethod = method_call;
1598
      ___manager.call(method_call);
1599
    }
1600
 
1601
    public static class getAllWarehouses_call extends org.apache.thrift.async.TAsyncMethodCall {
1602
      private boolean isActive;
1603
      public getAllWarehouses_call(boolean isActive, org.apache.thrift.async.AsyncMethodCallback<getAllWarehouses_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 {
1604
        super(client, protocolFactory, transport, resultHandler, false);
1605
        this.isActive = isActive;
1606
      }
1607
 
1608
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1609
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllWarehouses", org.apache.thrift.protocol.TMessageType.CALL, 0));
1610
        getAllWarehouses_args args = new getAllWarehouses_args();
1611
        args.setIsActive(isActive);
1612
        args.write(prot);
1613
        prot.writeMessageEnd();
1614
      }
1615
 
1616
      public List<Warehouse> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1617
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1618
          throw new IllegalStateException("Method call not finished!");
1619
        }
1620
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1621
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1622
        return (new Client(prot)).recv_getAllWarehouses();
1623
      }
1624
    }
1625
 
1626
    public void getWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1627
      checkReady();
1628
      getWarehouse_call method_call = new getWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1629
      this.___currentMethod = method_call;
1630
      ___manager.call(method_call);
1631
    }
1632
 
1633
    public static class getWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1634
      private long warehouse_id;
1635
      public getWarehouse_call(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getWarehouse_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 {
1636
        super(client, protocolFactory, transport, resultHandler, false);
1637
        this.warehouse_id = warehouse_id;
1638
      }
1639
 
1640
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1641
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1642
        getWarehouse_args args = new getWarehouse_args();
1643
        args.setWarehouse_id(warehouse_id);
1644
        args.write(prot);
1645
        prot.writeMessageEnd();
1646
      }
1647
 
1648
      public Warehouse getResult() throws InventoryServiceException, org.apache.thrift.TException {
1649
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1650
          throw new IllegalStateException("Method call not finished!");
1651
        }
1652
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1653
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1654
        return (new Client(prot)).recv_getWarehouse();
1655
      }
1656
    }
1657
 
1658
    public void getAllItemsForWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getAllItemsForWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1659
      checkReady();
1660
      getAllItemsForWarehouse_call method_call = new getAllItemsForWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1661
      this.___currentMethod = method_call;
1662
      ___manager.call(method_call);
1663
    }
1664
 
1665
    public static class getAllItemsForWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1666
      private long warehouse_id;
1667
      public getAllItemsForWarehouse_call(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getAllItemsForWarehouse_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 {
1668
        super(client, protocolFactory, transport, resultHandler, false);
1669
        this.warehouse_id = warehouse_id;
1670
      }
1671
 
1672
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1673
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllItemsForWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1674
        getAllItemsForWarehouse_args args = new getAllItemsForWarehouse_args();
1675
        args.setWarehouse_id(warehouse_id);
1676
        args.write(prot);
1677
        prot.writeMessageEnd();
1678
      }
1679
 
1680
      public List<Long> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1681
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1682
          throw new IllegalStateException("Method call not finished!");
1683
        }
1684
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1685
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1686
        return (new Client(prot)).recv_getAllItemsForWarehouse();
1687
      }
1688
    }
1689
 
5967 rajveer 1690
    public void isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId, org.apache.thrift.async.AsyncMethodCallback<isOrderBillable_call> resultHandler) throws org.apache.thrift.TException {
5945 mandeep.dh 1691
      checkReady();
5967 rajveer 1692
      isOrderBillable_call method_call = new isOrderBillable_call(itemId, warehouseId, sourceId, orderId, resultHandler, this, ___protocolFactory, ___transport);
5945 mandeep.dh 1693
      this.___currentMethod = method_call;
1694
      ___manager.call(method_call);
1695
    }
1696
 
5967 rajveer 1697
    public static class isOrderBillable_call extends org.apache.thrift.async.TAsyncMethodCall {
1698
      private long itemId;
1699
      private long warehouseId;
1700
      private long sourceId;
1701
      private long orderId;
1702
      public isOrderBillable_call(long itemId, long warehouseId, long sourceId, long orderId, org.apache.thrift.async.AsyncMethodCallback<isOrderBillable_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 {
1703
        super(client, protocolFactory, transport, resultHandler, false);
1704
        this.itemId = itemId;
1705
        this.warehouseId = warehouseId;
1706
        this.sourceId = sourceId;
1707
        this.orderId = orderId;
1708
      }
1709
 
1710
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1711
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("isOrderBillable", org.apache.thrift.protocol.TMessageType.CALL, 0));
1712
        isOrderBillable_args args = new isOrderBillable_args();
1713
        args.setItemId(itemId);
1714
        args.setWarehouseId(warehouseId);
1715
        args.setSourceId(sourceId);
1716
        args.setOrderId(orderId);
1717
        args.write(prot);
1718
        prot.writeMessageEnd();
1719
      }
1720
 
1721
      public boolean getResult() throws org.apache.thrift.TException {
1722
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1723
          throw new IllegalStateException("Method call not finished!");
1724
        }
1725
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1726
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1727
        return (new Client(prot)).recv_isOrderBillable();
1728
      }
1729
    }
1730
 
1731
    public void reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity, org.apache.thrift.async.AsyncMethodCallback<reserveItemInWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1732
      checkReady();
1733
      reserveItemInWarehouse_call method_call = new reserveItemInWarehouse_call(itemId, warehouseId, sourceId, orderId, createdTimestamp, promisedShippingTimestamp, quantity, resultHandler, this, ___protocolFactory, ___transport);
1734
      this.___currentMethod = method_call;
1735
      ___manager.call(method_call);
1736
    }
1737
 
5945 mandeep.dh 1738
    public static class reserveItemInWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1739
      private long itemId;
1740
      private long warehouseId;
5967 rajveer 1741
      private long sourceId;
1742
      private long orderId;
1743
      private long createdTimestamp;
1744
      private long promisedShippingTimestamp;
5945 mandeep.dh 1745
      private double quantity;
5967 rajveer 1746
      public reserveItemInWarehouse_call(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity, org.apache.thrift.async.AsyncMethodCallback<reserveItemInWarehouse_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 {
5945 mandeep.dh 1747
        super(client, protocolFactory, transport, resultHandler, false);
1748
        this.itemId = itemId;
1749
        this.warehouseId = warehouseId;
5967 rajveer 1750
        this.sourceId = sourceId;
1751
        this.orderId = orderId;
1752
        this.createdTimestamp = createdTimestamp;
1753
        this.promisedShippingTimestamp = promisedShippingTimestamp;
5945 mandeep.dh 1754
        this.quantity = quantity;
1755
      }
1756
 
1757
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1758
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("reserveItemInWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1759
        reserveItemInWarehouse_args args = new reserveItemInWarehouse_args();
1760
        args.setItemId(itemId);
1761
        args.setWarehouseId(warehouseId);
5967 rajveer 1762
        args.setSourceId(sourceId);
1763
        args.setOrderId(orderId);
1764
        args.setCreatedTimestamp(createdTimestamp);
1765
        args.setPromisedShippingTimestamp(promisedShippingTimestamp);
5945 mandeep.dh 1766
        args.setQuantity(quantity);
1767
        args.write(prot);
1768
        prot.writeMessageEnd();
1769
      }
1770
 
1771
      public boolean getResult() throws InventoryServiceException, org.apache.thrift.TException {
1772
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1773
          throw new IllegalStateException("Method call not finished!");
1774
        }
1775
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1776
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1777
        return (new Client(prot)).recv_reserveItemInWarehouse();
1778
      }
1779
    }
1780
 
5967 rajveer 1781
    public void reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity, org.apache.thrift.async.AsyncMethodCallback<reduceReservationCount_call> resultHandler) throws org.apache.thrift.TException {
5945 mandeep.dh 1782
      checkReady();
5967 rajveer 1783
      reduceReservationCount_call method_call = new reduceReservationCount_call(itemId, warehouseId, sourceId, orderId, quantity, resultHandler, this, ___protocolFactory, ___transport);
5945 mandeep.dh 1784
      this.___currentMethod = method_call;
1785
      ___manager.call(method_call);
1786
    }
1787
 
1788
    public static class reduceReservationCount_call extends org.apache.thrift.async.TAsyncMethodCall {
1789
      private long itemId;
1790
      private long warehouseId;
5967 rajveer 1791
      private long sourceId;
1792
      private long orderId;
5945 mandeep.dh 1793
      private double quantity;
5967 rajveer 1794
      public reduceReservationCount_call(long itemId, long warehouseId, long sourceId, long orderId, double quantity, org.apache.thrift.async.AsyncMethodCallback<reduceReservationCount_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 {
5945 mandeep.dh 1795
        super(client, protocolFactory, transport, resultHandler, false);
1796
        this.itemId = itemId;
1797
        this.warehouseId = warehouseId;
5967 rajveer 1798
        this.sourceId = sourceId;
1799
        this.orderId = orderId;
5945 mandeep.dh 1800
        this.quantity = quantity;
1801
      }
1802
 
1803
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1804
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("reduceReservationCount", org.apache.thrift.protocol.TMessageType.CALL, 0));
1805
        reduceReservationCount_args args = new reduceReservationCount_args();
1806
        args.setItemId(itemId);
1807
        args.setWarehouseId(warehouseId);
5967 rajveer 1808
        args.setSourceId(sourceId);
1809
        args.setOrderId(orderId);
5945 mandeep.dh 1810
        args.setQuantity(quantity);
1811
        args.write(prot);
1812
        prot.writeMessageEnd();
1813
      }
1814
 
1815
      public boolean getResult() throws InventoryServiceException, org.apache.thrift.TException {
1816
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1817
          throw new IllegalStateException("Method call not finished!");
1818
        }
1819
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1820
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1821
        return (new Client(prot)).recv_reduceReservationCount();
1822
      }
1823
    }
1824
 
1825
    public void getItemPricing(long itemId, long vendorId, org.apache.thrift.async.AsyncMethodCallback<getItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1826
      checkReady();
1827
      getItemPricing_call method_call = new getItemPricing_call(itemId, vendorId, resultHandler, this, ___protocolFactory, ___transport);
1828
      this.___currentMethod = method_call;
1829
      ___manager.call(method_call);
1830
    }
1831
 
1832
    public static class getItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1833
      private long itemId;
1834
      private long vendorId;
1835
      public getItemPricing_call(long itemId, long vendorId, org.apache.thrift.async.AsyncMethodCallback<getItemPricing_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 {
1836
        super(client, protocolFactory, transport, resultHandler, false);
1837
        this.itemId = itemId;
1838
        this.vendorId = vendorId;
1839
      }
1840
 
1841
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1842
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1843
        getItemPricing_args args = new getItemPricing_args();
1844
        args.setItemId(itemId);
1845
        args.setVendorId(vendorId);
1846
        args.write(prot);
1847
        prot.writeMessageEnd();
1848
      }
1849
 
1850
      public VendorItemPricing getResult() throws InventoryServiceException, org.apache.thrift.TException {
1851
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1852
          throw new IllegalStateException("Method call not finished!");
1853
        }
1854
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1855
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1856
        return (new Client(prot)).recv_getItemPricing();
1857
      }
1858
    }
1859
 
1860
    public void getAllItemPricing(long itemId, org.apache.thrift.async.AsyncMethodCallback<getAllItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1861
      checkReady();
1862
      getAllItemPricing_call method_call = new getAllItemPricing_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1863
      this.___currentMethod = method_call;
1864
      ___manager.call(method_call);
1865
    }
1866
 
1867
    public static class getAllItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1868
      private long itemId;
1869
      public getAllItemPricing_call(long itemId, org.apache.thrift.async.AsyncMethodCallback<getAllItemPricing_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 {
1870
        super(client, protocolFactory, transport, resultHandler, false);
1871
        this.itemId = itemId;
1872
      }
1873
 
1874
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1875
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1876
        getAllItemPricing_args args = new getAllItemPricing_args();
1877
        args.setItemId(itemId);
1878
        args.write(prot);
1879
        prot.writeMessageEnd();
1880
      }
1881
 
1882
      public List<VendorItemPricing> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1883
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1884
          throw new IllegalStateException("Method call not finished!");
1885
        }
1886
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1887
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1888
        return (new Client(prot)).recv_getAllItemPricing();
1889
      }
1890
    }
1891
 
1892
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing, org.apache.thrift.async.AsyncMethodCallback<addVendorItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1893
      checkReady();
1894
      addVendorItemPricing_call method_call = new addVendorItemPricing_call(vendorItemPricing, resultHandler, this, ___protocolFactory, ___transport);
1895
      this.___currentMethod = method_call;
1896
      ___manager.call(method_call);
1897
    }
1898
 
1899
    public static class addVendorItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1900
      private VendorItemPricing vendorItemPricing;
1901
      public addVendorItemPricing_call(VendorItemPricing vendorItemPricing, org.apache.thrift.async.AsyncMethodCallback<addVendorItemPricing_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 {
1902
        super(client, protocolFactory, transport, resultHandler, false);
1903
        this.vendorItemPricing = vendorItemPricing;
1904
      }
1905
 
1906
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1907
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendorItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1908
        addVendorItemPricing_args args = new addVendorItemPricing_args();
1909
        args.setVendorItemPricing(vendorItemPricing);
1910
        args.write(prot);
1911
        prot.writeMessageEnd();
1912
      }
1913
 
1914
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1915
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1916
          throw new IllegalStateException("Method call not finished!");
1917
        }
1918
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1919
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1920
        (new Client(prot)).recv_addVendorItemPricing();
1921
      }
1922
    }
1923
 
1924
    public void getVendor(long vendorId, org.apache.thrift.async.AsyncMethodCallback<getVendor_call> resultHandler) throws org.apache.thrift.TException {
1925
      checkReady();
1926
      getVendor_call method_call = new getVendor_call(vendorId, resultHandler, this, ___protocolFactory, ___transport);
1927
      this.___currentMethod = method_call;
1928
      ___manager.call(method_call);
1929
    }
1930
 
1931
    public static class getVendor_call extends org.apache.thrift.async.TAsyncMethodCall {
1932
      private long vendorId;
1933
      public getVendor_call(long vendorId, org.apache.thrift.async.AsyncMethodCallback<getVendor_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 {
1934
        super(client, protocolFactory, transport, resultHandler, false);
1935
        this.vendorId = vendorId;
1936
      }
1937
 
1938
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1939
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getVendor", org.apache.thrift.protocol.TMessageType.CALL, 0));
1940
        getVendor_args args = new getVendor_args();
1941
        args.setVendorId(vendorId);
1942
        args.write(prot);
1943
        prot.writeMessageEnd();
1944
      }
1945
 
1946
      public Vendor getResult() throws org.apache.thrift.TException {
1947
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1948
          throw new IllegalStateException("Method call not finished!");
1949
        }
1950
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1951
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1952
        return (new Client(prot)).recv_getVendor();
1953
      }
1954
    }
1955
 
1956
    public void getAllVendors(org.apache.thrift.async.AsyncMethodCallback<getAllVendors_call> resultHandler) throws org.apache.thrift.TException {
1957
      checkReady();
1958
      getAllVendors_call method_call = new getAllVendors_call(resultHandler, this, ___protocolFactory, ___transport);
1959
      this.___currentMethod = method_call;
1960
      ___manager.call(method_call);
1961
    }
1962
 
1963
    public static class getAllVendors_call extends org.apache.thrift.async.TAsyncMethodCall {
1964
      public getAllVendors_call(org.apache.thrift.async.AsyncMethodCallback<getAllVendors_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 {
1965
        super(client, protocolFactory, transport, resultHandler, false);
1966
      }
1967
 
1968
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1969
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllVendors", org.apache.thrift.protocol.TMessageType.CALL, 0));
1970
        getAllVendors_args args = new getAllVendors_args();
1971
        args.write(prot);
1972
        prot.writeMessageEnd();
1973
      }
1974
 
1975
      public List<Vendor> getResult() throws org.apache.thrift.TException {
1976
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1977
          throw new IllegalStateException("Method call not finished!");
1978
        }
1979
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1980
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1981
        return (new Client(prot)).recv_getAllVendors();
1982
      }
1983
    }
1984
 
1985
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping, org.apache.thrift.async.AsyncMethodCallback<addVendorItemMapping_call> resultHandler) throws org.apache.thrift.TException {
1986
      checkReady();
1987
      addVendorItemMapping_call method_call = new addVendorItemMapping_call(key, vendorItemMapping, resultHandler, this, ___protocolFactory, ___transport);
1988
      this.___currentMethod = method_call;
1989
      ___manager.call(method_call);
1990
    }
1991
 
1992
    public static class addVendorItemMapping_call extends org.apache.thrift.async.TAsyncMethodCall {
1993
      private String key;
1994
      private VendorItemMapping vendorItemMapping;
1995
      public addVendorItemMapping_call(String key, VendorItemMapping vendorItemMapping, org.apache.thrift.async.AsyncMethodCallback<addVendorItemMapping_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 {
1996
        super(client, protocolFactory, transport, resultHandler, false);
1997
        this.key = key;
1998
        this.vendorItemMapping = vendorItemMapping;
1999
      }
2000
 
2001
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2002
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendorItemMapping", org.apache.thrift.protocol.TMessageType.CALL, 0));
2003
        addVendorItemMapping_args args = new addVendorItemMapping_args();
2004
        args.setKey(key);
2005
        args.setVendorItemMapping(vendorItemMapping);
2006
        args.write(prot);
2007
        prot.writeMessageEnd();
2008
      }
2009
 
2010
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2011
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2012
          throw new IllegalStateException("Method call not finished!");
2013
        }
2014
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2015
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2016
        (new Client(prot)).recv_addVendorItemMapping();
2017
      }
2018
    }
2019
 
2020
    public void getVendorItemMappings(long itemId, org.apache.thrift.async.AsyncMethodCallback<getVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException {
2021
      checkReady();
2022
      getVendorItemMappings_call method_call = new getVendorItemMappings_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
2023
      this.___currentMethod = method_call;
2024
      ___manager.call(method_call);
2025
    }
2026
 
2027
    public static class getVendorItemMappings_call extends org.apache.thrift.async.TAsyncMethodCall {
2028
      private long itemId;
2029
      public getVendorItemMappings_call(long itemId, org.apache.thrift.async.AsyncMethodCallback<getVendorItemMappings_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 {
2030
        super(client, protocolFactory, transport, resultHandler, false);
2031
        this.itemId = itemId;
2032
      }
2033
 
2034
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2035
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getVendorItemMappings", org.apache.thrift.protocol.TMessageType.CALL, 0));
2036
        getVendorItemMappings_args args = new getVendorItemMappings_args();
2037
        args.setItemId(itemId);
2038
        args.write(prot);
2039
        prot.writeMessageEnd();
2040
      }
2041
 
2042
      public List<VendorItemMapping> getResult() throws InventoryServiceException, org.apache.thrift.TException {
2043
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2044
          throw new IllegalStateException("Method call not finished!");
2045
        }
2046
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2047
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2048
        return (new Client(prot)).recv_getVendorItemMappings();
2049
      }
2050
    }
2051
 
2052
    public void getPendingOrdersInventory(long vendorid, org.apache.thrift.async.AsyncMethodCallback<getPendingOrdersInventory_call> resultHandler) throws org.apache.thrift.TException {
2053
      checkReady();
2054
      getPendingOrdersInventory_call method_call = new getPendingOrdersInventory_call(vendorid, resultHandler, this, ___protocolFactory, ___transport);
2055
      this.___currentMethod = method_call;
2056
      ___manager.call(method_call);
2057
    }
2058
 
2059
    public static class getPendingOrdersInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
2060
      private long vendorid;
2061
      public getPendingOrdersInventory_call(long vendorid, org.apache.thrift.async.AsyncMethodCallback<getPendingOrdersInventory_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 {
2062
        super(client, protocolFactory, transport, resultHandler, false);
2063
        this.vendorid = vendorid;
2064
      }
2065
 
2066
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2067
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPendingOrdersInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
2068
        getPendingOrdersInventory_args args = new getPendingOrdersInventory_args();
2069
        args.setVendorid(vendorid);
2070
        args.write(prot);
2071
        prot.writeMessageEnd();
2072
      }
2073
 
2074
      public List<AvailableAndReservedStock> getResult() throws org.apache.thrift.TException {
2075
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2076
          throw new IllegalStateException("Method call not finished!");
2077
        }
2078
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2079
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2080
        return (new Client(prot)).recv_getPendingOrdersInventory();
2081
      }
2082
    }
2083
 
2084
    public void getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<getWarehouses_call> resultHandler) throws org.apache.thrift.TException {
2085
      checkReady();
2086
      getWarehouses_call method_call = new getWarehouses_call(warehouseType, inventoryType, vendorId, billingWarehouseId, shippingWarehouseId, resultHandler, this, ___protocolFactory, ___transport);
2087
      this.___currentMethod = method_call;
2088
      ___manager.call(method_call);
2089
    }
2090
 
2091
    public static class getWarehouses_call extends org.apache.thrift.async.TAsyncMethodCall {
2092
      private WarehouseType warehouseType;
2093
      private InventoryType inventoryType;
2094
      private long vendorId;
2095
      private long billingWarehouseId;
2096
      private long shippingWarehouseId;
2097
      public getWarehouses_call(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId, org.apache.thrift.async.AsyncMethodCallback<getWarehouses_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 {
2098
        super(client, protocolFactory, transport, resultHandler, false);
2099
        this.warehouseType = warehouseType;
2100
        this.inventoryType = inventoryType;
2101
        this.vendorId = vendorId;
2102
        this.billingWarehouseId = billingWarehouseId;
2103
        this.shippingWarehouseId = shippingWarehouseId;
2104
      }
2105
 
2106
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2107
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getWarehouses", org.apache.thrift.protocol.TMessageType.CALL, 0));
2108
        getWarehouses_args args = new getWarehouses_args();
2109
        args.setWarehouseType(warehouseType);
2110
        args.setInventoryType(inventoryType);
2111
        args.setVendorId(vendorId);
2112
        args.setBillingWarehouseId(billingWarehouseId);
2113
        args.setShippingWarehouseId(shippingWarehouseId);
2114
        args.write(prot);
2115
        prot.writeMessageEnd();
2116
      }
2117
 
2118
      public List<Warehouse> getResult() throws org.apache.thrift.TException {
2119
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2120
          throw new IllegalStateException("Method call not finished!");
2121
        }
2122
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2123
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2124
        return (new Client(prot)).recv_getWarehouses();
2125
      }
2126
    }
2127
 
2128
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailability_call> resultHandler) throws org.apache.thrift.TException {
2129
      checkReady();
2130
      resetAvailability_call method_call = new resetAvailability_call(itemKey, vendorId, quantity, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2131
      this.___currentMethod = method_call;
2132
      ___manager.call(method_call);
2133
    }
2134
 
2135
    public static class resetAvailability_call extends org.apache.thrift.async.TAsyncMethodCall {
2136
      private String itemKey;
2137
      private long vendorId;
2138
      private long quantity;
2139
      private long warehouseId;
2140
      public resetAvailability_call(String itemKey, long vendorId, long quantity, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailability_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 {
2141
        super(client, protocolFactory, transport, resultHandler, false);
2142
        this.itemKey = itemKey;
2143
        this.vendorId = vendorId;
2144
        this.quantity = quantity;
2145
        this.warehouseId = warehouseId;
2146
      }
2147
 
2148
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2149
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("resetAvailability", org.apache.thrift.protocol.TMessageType.CALL, 0));
2150
        resetAvailability_args args = new resetAvailability_args();
2151
        args.setItemKey(itemKey);
2152
        args.setVendorId(vendorId);
2153
        args.setQuantity(quantity);
2154
        args.setWarehouseId(warehouseId);
2155
        args.write(prot);
2156
        prot.writeMessageEnd();
2157
      }
2158
 
2159
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2160
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2161
          throw new IllegalStateException("Method call not finished!");
2162
        }
2163
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2164
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2165
        (new Client(prot)).recv_resetAvailability();
2166
      }
2167
    }
2168
 
2169
    public void resetAvailabilityForWarehouse(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailabilityForWarehouse_call> resultHandler) throws org.apache.thrift.TException {
2170
      checkReady();
2171
      resetAvailabilityForWarehouse_call method_call = new resetAvailabilityForWarehouse_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2172
      this.___currentMethod = method_call;
2173
      ___manager.call(method_call);
2174
    }
2175
 
2176
    public static class resetAvailabilityForWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
2177
      private long warehouseId;
2178
      public resetAvailabilityForWarehouse_call(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailabilityForWarehouse_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 {
2179
        super(client, protocolFactory, transport, resultHandler, false);
2180
        this.warehouseId = warehouseId;
2181
      }
2182
 
2183
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2184
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("resetAvailabilityForWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
2185
        resetAvailabilityForWarehouse_args args = new resetAvailabilityForWarehouse_args();
2186
        args.setWarehouseId(warehouseId);
2187
        args.write(prot);
2188
        prot.writeMessageEnd();
2189
      }
2190
 
2191
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2192
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2193
          throw new IllegalStateException("Method call not finished!");
2194
        }
2195
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2196
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2197
        (new Client(prot)).recv_resetAvailabilityForWarehouse();
2198
      }
2199
    }
2200
 
2201
    public void getItemKeysToBeProcessed(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getItemKeysToBeProcessed_call> resultHandler) throws org.apache.thrift.TException {
2202
      checkReady();
2203
      getItemKeysToBeProcessed_call method_call = new getItemKeysToBeProcessed_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2204
      this.___currentMethod = method_call;
2205
      ___manager.call(method_call);
2206
    }
2207
 
2208
    public static class getItemKeysToBeProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
2209
      private long warehouseId;
2210
      public getItemKeysToBeProcessed_call(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getItemKeysToBeProcessed_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 {
2211
        super(client, protocolFactory, transport, resultHandler, false);
2212
        this.warehouseId = warehouseId;
2213
      }
2214
 
2215
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2216
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemKeysToBeProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
2217
        getItemKeysToBeProcessed_args args = new getItemKeysToBeProcessed_args();
2218
        args.setWarehouseId(warehouseId);
2219
        args.write(prot);
2220
        prot.writeMessageEnd();
2221
      }
2222
 
2223
      public List<String> getResult() throws org.apache.thrift.TException {
2224
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2225
          throw new IllegalStateException("Method call not finished!");
2226
        }
2227
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2228
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2229
        return (new Client(prot)).recv_getItemKeysToBeProcessed();
2230
      }
2231
    }
2232
 
2233
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<markMissedInventoryUpdatesAsProcessed_call> resultHandler) throws org.apache.thrift.TException {
2234
      checkReady();
2235
      markMissedInventoryUpdatesAsProcessed_call method_call = new markMissedInventoryUpdatesAsProcessed_call(itemKey, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2236
      this.___currentMethod = method_call;
2237
      ___manager.call(method_call);
2238
    }
2239
 
2240
    public static class markMissedInventoryUpdatesAsProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
2241
      private String itemKey;
2242
      private long warehouseId;
2243
      public markMissedInventoryUpdatesAsProcessed_call(String itemKey, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<markMissedInventoryUpdatesAsProcessed_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 {
2244
        super(client, protocolFactory, transport, resultHandler, false);
2245
        this.itemKey = itemKey;
2246
        this.warehouseId = warehouseId;
2247
      }
2248
 
2249
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2250
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("markMissedInventoryUpdatesAsProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
2251
        markMissedInventoryUpdatesAsProcessed_args args = new markMissedInventoryUpdatesAsProcessed_args();
2252
        args.setItemKey(itemKey);
2253
        args.setWarehouseId(warehouseId);
2254
        args.write(prot);
2255
        prot.writeMessageEnd();
2256
      }
2257
 
2258
      public void getResult() throws org.apache.thrift.TException {
2259
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2260
          throw new IllegalStateException("Method call not finished!");
2261
        }
2262
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2263
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2264
        (new Client(prot)).recv_markMissedInventoryUpdatesAsProcessed();
2265
      }
2266
    }
2267
 
2268
    public void getIgnoredItemKeys(org.apache.thrift.async.AsyncMethodCallback<getIgnoredItemKeys_call> resultHandler) throws org.apache.thrift.TException {
2269
      checkReady();
2270
      getIgnoredItemKeys_call method_call = new getIgnoredItemKeys_call(resultHandler, this, ___protocolFactory, ___transport);
2271
      this.___currentMethod = method_call;
2272
      ___manager.call(method_call);
2273
    }
2274
 
2275
    public static class getIgnoredItemKeys_call extends org.apache.thrift.async.TAsyncMethodCall {
2276
      public getIgnoredItemKeys_call(org.apache.thrift.async.AsyncMethodCallback<getIgnoredItemKeys_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 {
2277
        super(client, protocolFactory, transport, resultHandler, false);
2278
      }
2279
 
2280
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2281
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getIgnoredItemKeys", org.apache.thrift.protocol.TMessageType.CALL, 0));
2282
        getIgnoredItemKeys_args args = new getIgnoredItemKeys_args();
2283
        args.write(prot);
2284
        prot.writeMessageEnd();
2285
      }
2286
 
2287
      public Map<String,Map<Long,Long>> getResult() throws org.apache.thrift.TException {
2288
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2289
          throw new IllegalStateException("Method call not finished!");
2290
        }
2291
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2292
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2293
        return (new Client(prot)).recv_getIgnoredItemKeys();
2294
      }
2295
    }
2296
 
2297
    public void addBadInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addBadInventory_call> resultHandler) throws org.apache.thrift.TException {
2298
      checkReady();
2299
      addBadInventory_call method_call = new addBadInventory_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
2300
      this.___currentMethod = method_call;
2301
      ___manager.call(method_call);
2302
    }
2303
 
2304
    public static class addBadInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
2305
      private long itemId;
2306
      private long warehouseId;
2307
      private long quantity;
2308
      public addBadInventory_call(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addBadInventory_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 {
2309
        super(client, protocolFactory, transport, resultHandler, false);
2310
        this.itemId = itemId;
2311
        this.warehouseId = warehouseId;
2312
        this.quantity = quantity;
2313
      }
2314
 
2315
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2316
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addBadInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
2317
        addBadInventory_args args = new addBadInventory_args();
2318
        args.setItemId(itemId);
2319
        args.setWarehouseId(warehouseId);
2320
        args.setQuantity(quantity);
2321
        args.write(prot);
2322
        prot.writeMessageEnd();
2323
      }
2324
 
2325
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2326
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2327
          throw new IllegalStateException("Method call not finished!");
2328
        }
2329
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2330
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2331
        (new Client(prot)).recv_addBadInventory();
2332
      }
2333
    }
2334
 
2335
    public void getShippingLocations(org.apache.thrift.async.AsyncMethodCallback<getShippingLocations_call> resultHandler) throws org.apache.thrift.TException {
2336
      checkReady();
2337
      getShippingLocations_call method_call = new getShippingLocations_call(resultHandler, this, ___protocolFactory, ___transport);
2338
      this.___currentMethod = method_call;
2339
      ___manager.call(method_call);
2340
    }
2341
 
2342
    public static class getShippingLocations_call extends org.apache.thrift.async.TAsyncMethodCall {
2343
      public getShippingLocations_call(org.apache.thrift.async.AsyncMethodCallback<getShippingLocations_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 {
2344
        super(client, protocolFactory, transport, resultHandler, false);
2345
      }
2346
 
2347
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2348
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getShippingLocations", org.apache.thrift.protocol.TMessageType.CALL, 0));
2349
        getShippingLocations_args args = new getShippingLocations_args();
2350
        args.write(prot);
2351
        prot.writeMessageEnd();
2352
      }
2353
 
2354
      public List<Warehouse> getResult() throws org.apache.thrift.TException {
2355
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2356
          throw new IllegalStateException("Method call not finished!");
2357
        }
2358
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2359
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2360
        return (new Client(prot)).recv_getShippingLocations();
2361
      }
2362
    }
2363
 
2364
    public void getAllVendorItemMappings(org.apache.thrift.async.AsyncMethodCallback<getAllVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException {
2365
      checkReady();
2366
      getAllVendorItemMappings_call method_call = new getAllVendorItemMappings_call(resultHandler, this, ___protocolFactory, ___transport);
2367
      this.___currentMethod = method_call;
2368
      ___manager.call(method_call);
2369
    }
2370
 
2371
    public static class getAllVendorItemMappings_call extends org.apache.thrift.async.TAsyncMethodCall {
2372
      public getAllVendorItemMappings_call(org.apache.thrift.async.AsyncMethodCallback<getAllVendorItemMappings_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 {
2373
        super(client, protocolFactory, transport, resultHandler, false);
2374
      }
2375
 
2376
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2377
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllVendorItemMappings", org.apache.thrift.protocol.TMessageType.CALL, 0));
2378
        getAllVendorItemMappings_args args = new getAllVendorItemMappings_args();
2379
        args.write(prot);
2380
        prot.writeMessageEnd();
2381
      }
2382
 
2383
      public List<VendorItemMapping> getResult() throws org.apache.thrift.TException {
2384
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2385
          throw new IllegalStateException("Method call not finished!");
2386
        }
2387
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2388
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2389
        return (new Client(prot)).recv_getAllVendorItemMappings();
2390
      }
2391
    }
2392
 
2393
    public void getInventorySnapshot(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getInventorySnapshot_call> resultHandler) throws org.apache.thrift.TException {
2394
      checkReady();
2395
      getInventorySnapshot_call method_call = new getInventorySnapshot_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2396
      this.___currentMethod = method_call;
2397
      ___manager.call(method_call);
2398
    }
2399
 
2400
    public static class getInventorySnapshot_call extends org.apache.thrift.async.TAsyncMethodCall {
2401
      private long warehouseId;
2402
      public getInventorySnapshot_call(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getInventorySnapshot_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 {
2403
        super(client, protocolFactory, transport, resultHandler, false);
2404
        this.warehouseId = warehouseId;
2405
      }
2406
 
2407
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2408
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventorySnapshot", org.apache.thrift.protocol.TMessageType.CALL, 0));
2409
        getInventorySnapshot_args args = new getInventorySnapshot_args();
2410
        args.setWarehouseId(warehouseId);
2411
        args.write(prot);
2412
        prot.writeMessageEnd();
2413
      }
2414
 
2415
      public Map<Long,ItemInventory> getResult() throws org.apache.thrift.TException {
2416
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2417
          throw new IllegalStateException("Method call not finished!");
2418
        }
2419
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2420
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2421
        return (new Client(prot)).recv_getInventorySnapshot();
2422
      }
2423
    }
2424
 
2425
    public void clearItemAvailabilityCache(org.apache.thrift.async.AsyncMethodCallback<clearItemAvailabilityCache_call> resultHandler) throws org.apache.thrift.TException {
2426
      checkReady();
2427
      clearItemAvailabilityCache_call method_call = new clearItemAvailabilityCache_call(resultHandler, this, ___protocolFactory, ___transport);
2428
      this.___currentMethod = method_call;
2429
      ___manager.call(method_call);
2430
    }
2431
 
2432
    public static class clearItemAvailabilityCache_call extends org.apache.thrift.async.TAsyncMethodCall {
2433
      public clearItemAvailabilityCache_call(org.apache.thrift.async.AsyncMethodCallback<clearItemAvailabilityCache_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 {
2434
        super(client, protocolFactory, transport, resultHandler, false);
2435
      }
2436
 
2437
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2438
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("clearItemAvailabilityCache", org.apache.thrift.protocol.TMessageType.CALL, 0));
2439
        clearItemAvailabilityCache_args args = new clearItemAvailabilityCache_args();
2440
        args.write(prot);
2441
        prot.writeMessageEnd();
2442
      }
2443
 
2444
      public void getResult() throws org.apache.thrift.TException {
2445
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2446
          throw new IllegalStateException("Method call not finished!");
2447
        }
2448
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2449
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2450
        (new Client(prot)).recv_clearItemAvailabilityCache();
2451
      }
2452
    }
2453
 
2454
    public void updateVendorString(long warehouseId, String vendorString, org.apache.thrift.async.AsyncMethodCallback<updateVendorString_call> resultHandler) throws org.apache.thrift.TException {
2455
      checkReady();
2456
      updateVendorString_call method_call = new updateVendorString_call(warehouseId, vendorString, resultHandler, this, ___protocolFactory, ___transport);
2457
      this.___currentMethod = method_call;
2458
      ___manager.call(method_call);
2459
    }
2460
 
2461
    public static class updateVendorString_call extends org.apache.thrift.async.TAsyncMethodCall {
2462
      private long warehouseId;
2463
      private String vendorString;
2464
      public updateVendorString_call(long warehouseId, String vendorString, org.apache.thrift.async.AsyncMethodCallback<updateVendorString_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 {
2465
        super(client, protocolFactory, transport, resultHandler, false);
2466
        this.warehouseId = warehouseId;
2467
        this.vendorString = vendorString;
2468
      }
2469
 
2470
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2471
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateVendorString", org.apache.thrift.protocol.TMessageType.CALL, 0));
2472
        updateVendorString_args args = new updateVendorString_args();
2473
        args.setWarehouseId(warehouseId);
2474
        args.setVendorString(vendorString);
2475
        args.write(prot);
2476
        prot.writeMessageEnd();
2477
      }
2478
 
2479
      public void getResult() throws org.apache.thrift.TException {
2480
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2481
          throw new IllegalStateException("Method call not finished!");
2482
        }
2483
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2484
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2485
        (new Client(prot)).recv_updateVendorString();
2486
      }
2487
    }
2488
 
6096 amit.gupta 2489
    public void clearItemAvailabilityCacheForItem(long item_id, org.apache.thrift.async.AsyncMethodCallback<clearItemAvailabilityCacheForItem_call> resultHandler) throws org.apache.thrift.TException {
2490
      checkReady();
2491
      clearItemAvailabilityCacheForItem_call method_call = new clearItemAvailabilityCacheForItem_call(item_id, resultHandler, this, ___protocolFactory, ___transport);
2492
      this.___currentMethod = method_call;
2493
      ___manager.call(method_call);
2494
    }
2495
 
2496
    public static class clearItemAvailabilityCacheForItem_call extends org.apache.thrift.async.TAsyncMethodCall {
2497
      private long item_id;
2498
      public clearItemAvailabilityCacheForItem_call(long item_id, org.apache.thrift.async.AsyncMethodCallback<clearItemAvailabilityCacheForItem_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 {
2499
        super(client, protocolFactory, transport, resultHandler, false);
2500
        this.item_id = item_id;
2501
      }
2502
 
2503
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2504
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("clearItemAvailabilityCacheForItem", org.apache.thrift.protocol.TMessageType.CALL, 0));
2505
        clearItemAvailabilityCacheForItem_args args = new clearItemAvailabilityCacheForItem_args();
2506
        args.setItem_id(item_id);
2507
        args.write(prot);
2508
        prot.writeMessageEnd();
2509
      }
2510
 
2511
      public void getResult() throws org.apache.thrift.TException {
2512
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2513
          throw new IllegalStateException("Method call not finished!");
2514
        }
2515
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2516
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2517
        (new Client(prot)).recv_clearItemAvailabilityCacheForItem();
2518
      }
2519
    }
2520
 
5945 mandeep.dh 2521
  }
2522
 
2523
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
2524
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
2525
    public Processor(I iface) {
2526
      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
2527
    }
2528
 
2529
    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
2530
      super(iface, getProcessMap(processMap));
2531
    }
2532
 
2533
    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) {
2534
      processMap.put("addWarehouse", new addWarehouse());
2535
      processMap.put("addVendor", new addVendor());
2536
      processMap.put("updateInventoryHistory", new updateInventoryHistory());
2537
      processMap.put("updateInventory", new updateInventory());
2538
      processMap.put("addInventory", new addInventory());
2539
      processMap.put("retireWarehouse", new retireWarehouse());
2540
      processMap.put("getItemInventoryByItemId", new getItemInventoryByItemId());
2541
      processMap.put("getItemAvailibilityAtWarehouse", new getItemAvailibilityAtWarehouse());
2542
      processMap.put("getItemAvailabilityAtLocation", new getItemAvailabilityAtLocation());
2543
      processMap.put("getAllWarehouses", new getAllWarehouses());
2544
      processMap.put("getWarehouse", new getWarehouse());
2545
      processMap.put("getAllItemsForWarehouse", new getAllItemsForWarehouse());
5967 rajveer 2546
      processMap.put("isOrderBillable", new isOrderBillable());
5945 mandeep.dh 2547
      processMap.put("reserveItemInWarehouse", new reserveItemInWarehouse());
2548
      processMap.put("reduceReservationCount", new reduceReservationCount());
2549
      processMap.put("getItemPricing", new getItemPricing());
2550
      processMap.put("getAllItemPricing", new getAllItemPricing());
2551
      processMap.put("addVendorItemPricing", new addVendorItemPricing());
2552
      processMap.put("getVendor", new getVendor());
2553
      processMap.put("getAllVendors", new getAllVendors());
2554
      processMap.put("addVendorItemMapping", new addVendorItemMapping());
2555
      processMap.put("getVendorItemMappings", new getVendorItemMappings());
2556
      processMap.put("getPendingOrdersInventory", new getPendingOrdersInventory());
2557
      processMap.put("getWarehouses", new getWarehouses());
2558
      processMap.put("resetAvailability", new resetAvailability());
2559
      processMap.put("resetAvailabilityForWarehouse", new resetAvailabilityForWarehouse());
2560
      processMap.put("getItemKeysToBeProcessed", new getItemKeysToBeProcessed());
2561
      processMap.put("markMissedInventoryUpdatesAsProcessed", new markMissedInventoryUpdatesAsProcessed());
2562
      processMap.put("getIgnoredItemKeys", new getIgnoredItemKeys());
2563
      processMap.put("addBadInventory", new addBadInventory());
2564
      processMap.put("getShippingLocations", new getShippingLocations());
2565
      processMap.put("getAllVendorItemMappings", new getAllVendorItemMappings());
2566
      processMap.put("getInventorySnapshot", new getInventorySnapshot());
2567
      processMap.put("clearItemAvailabilityCache", new clearItemAvailabilityCache());
2568
      processMap.put("updateVendorString", new updateVendorString());
6096 amit.gupta 2569
      processMap.put("clearItemAvailabilityCacheForItem", new clearItemAvailabilityCacheForItem());
5945 mandeep.dh 2570
      return processMap;
2571
    }
2572
 
2573
    private static class addWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addWarehouse_args> {
2574
      public addWarehouse() {
2575
        super("addWarehouse");
2576
      }
2577
 
2578
      protected addWarehouse_args getEmptyArgsInstance() {
2579
        return new addWarehouse_args();
2580
      }
2581
 
2582
      protected addWarehouse_result getResult(I iface, addWarehouse_args args) throws org.apache.thrift.TException {
2583
        addWarehouse_result result = new addWarehouse_result();
2584
        try {
2585
          result.success = iface.addWarehouse(args.warehouse);
2586
          result.setSuccessIsSet(true);
2587
        } catch (InventoryServiceException cex) {
2588
          result.cex = cex;
2589
        }
2590
        return result;
2591
      }
2592
    }
2593
 
2594
    private static class addVendor<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendor_args> {
2595
      public addVendor() {
2596
        super("addVendor");
2597
      }
2598
 
2599
      protected addVendor_args getEmptyArgsInstance() {
2600
        return new addVendor_args();
2601
      }
2602
 
2603
      protected addVendor_result getResult(I iface, addVendor_args args) throws org.apache.thrift.TException {
2604
        addVendor_result result = new addVendor_result();
2605
        try {
2606
          result.success = iface.addVendor(args.vendor);
2607
          result.setSuccessIsSet(true);
2608
        } catch (InventoryServiceException cex) {
2609
          result.cex = cex;
2610
        }
2611
        return result;
2612
      }
2613
    }
2614
 
2615
    private static class updateInventoryHistory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateInventoryHistory_args> {
2616
      public updateInventoryHistory() {
2617
        super("updateInventoryHistory");
2618
      }
2619
 
2620
      protected updateInventoryHistory_args getEmptyArgsInstance() {
2621
        return new updateInventoryHistory_args();
2622
      }
2623
 
2624
      protected updateInventoryHistory_result getResult(I iface, updateInventoryHistory_args args) throws org.apache.thrift.TException {
2625
        updateInventoryHistory_result result = new updateInventoryHistory_result();
2626
        try {
2627
          iface.updateInventoryHistory(args.warehouse_id, args.timestamp, args.availability);
2628
        } catch (InventoryServiceException cex) {
2629
          result.cex = cex;
2630
        }
2631
        return result;
2632
      }
2633
    }
2634
 
2635
    private static class updateInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateInventory_args> {
2636
      public updateInventory() {
2637
        super("updateInventory");
2638
      }
2639
 
2640
      protected updateInventory_args getEmptyArgsInstance() {
2641
        return new updateInventory_args();
2642
      }
2643
 
2644
      protected updateInventory_result getResult(I iface, updateInventory_args args) throws org.apache.thrift.TException {
2645
        updateInventory_result result = new updateInventory_result();
2646
        try {
2647
          iface.updateInventory(args.warehouse_id, args.timestamp, args.availability);
2648
        } catch (InventoryServiceException cex) {
2649
          result.cex = cex;
2650
        }
2651
        return result;
2652
      }
2653
    }
2654
 
2655
    private static class addInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addInventory_args> {
2656
      public addInventory() {
2657
        super("addInventory");
2658
      }
2659
 
2660
      protected addInventory_args getEmptyArgsInstance() {
2661
        return new addInventory_args();
2662
      }
2663
 
2664
      protected addInventory_result getResult(I iface, addInventory_args args) throws org.apache.thrift.TException {
2665
        addInventory_result result = new addInventory_result();
2666
        try {
2667
          iface.addInventory(args.itemId, args.warehouseId, args.quantity);
2668
        } catch (InventoryServiceException cex) {
2669
          result.cex = cex;
2670
        }
2671
        return result;
2672
      }
2673
    }
2674
 
2675
    private static class retireWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, retireWarehouse_args> {
2676
      public retireWarehouse() {
2677
        super("retireWarehouse");
2678
      }
2679
 
2680
      protected retireWarehouse_args getEmptyArgsInstance() {
2681
        return new retireWarehouse_args();
2682
      }
2683
 
2684
      protected retireWarehouse_result getResult(I iface, retireWarehouse_args args) throws org.apache.thrift.TException {
2685
        retireWarehouse_result result = new retireWarehouse_result();
2686
        try {
2687
          iface.retireWarehouse(args.warehouse_id);
2688
        } catch (InventoryServiceException cex) {
2689
          result.cex = cex;
2690
        }
2691
        return result;
2692
      }
2693
    }
2694
 
2695
    private static class getItemInventoryByItemId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemInventoryByItemId_args> {
2696
      public getItemInventoryByItemId() {
2697
        super("getItemInventoryByItemId");
2698
      }
2699
 
2700
      protected getItemInventoryByItemId_args getEmptyArgsInstance() {
2701
        return new getItemInventoryByItemId_args();
2702
      }
2703
 
2704
      protected getItemInventoryByItemId_result getResult(I iface, getItemInventoryByItemId_args args) throws org.apache.thrift.TException {
2705
        getItemInventoryByItemId_result result = new getItemInventoryByItemId_result();
2706
        try {
2707
          result.success = iface.getItemInventoryByItemId(args.item_id);
2708
        } catch (InventoryServiceException cex) {
2709
          result.cex = cex;
2710
        }
2711
        return result;
2712
      }
2713
    }
2714
 
2715
    private static class getItemAvailibilityAtWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemAvailibilityAtWarehouse_args> {
2716
      public getItemAvailibilityAtWarehouse() {
2717
        super("getItemAvailibilityAtWarehouse");
2718
      }
2719
 
2720
      protected getItemAvailibilityAtWarehouse_args getEmptyArgsInstance() {
2721
        return new getItemAvailibilityAtWarehouse_args();
2722
      }
2723
 
2724
      protected getItemAvailibilityAtWarehouse_result getResult(I iface, getItemAvailibilityAtWarehouse_args args) throws org.apache.thrift.TException {
2725
        getItemAvailibilityAtWarehouse_result result = new getItemAvailibilityAtWarehouse_result();
2726
        try {
2727
          result.success = iface.getItemAvailibilityAtWarehouse(args.warehouse_id, args.item_id);
2728
          result.setSuccessIsSet(true);
2729
        } catch (InventoryServiceException cex) {
2730
          result.cex = cex;
2731
        }
2732
        return result;
2733
      }
2734
    }
2735
 
2736
    private static class getItemAvailabilityAtLocation<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemAvailabilityAtLocation_args> {
2737
      public getItemAvailabilityAtLocation() {
2738
        super("getItemAvailabilityAtLocation");
2739
      }
2740
 
2741
      protected getItemAvailabilityAtLocation_args getEmptyArgsInstance() {
2742
        return new getItemAvailabilityAtLocation_args();
2743
      }
2744
 
2745
      protected getItemAvailabilityAtLocation_result getResult(I iface, getItemAvailabilityAtLocation_args args) throws org.apache.thrift.TException {
2746
        getItemAvailabilityAtLocation_result result = new getItemAvailabilityAtLocation_result();
2747
        try {
5978 rajveer 2748
          result.success = iface.getItemAvailabilityAtLocation(args.itemId, args.sourceId);
5945 mandeep.dh 2749
        } catch (InventoryServiceException isex) {
2750
          result.isex = isex;
2751
        }
2752
        return result;
2753
      }
2754
    }
2755
 
2756
    private static class getAllWarehouses<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllWarehouses_args> {
2757
      public getAllWarehouses() {
2758
        super("getAllWarehouses");
2759
      }
2760
 
2761
      protected getAllWarehouses_args getEmptyArgsInstance() {
2762
        return new getAllWarehouses_args();
2763
      }
2764
 
2765
      protected getAllWarehouses_result getResult(I iface, getAllWarehouses_args args) throws org.apache.thrift.TException {
2766
        getAllWarehouses_result result = new getAllWarehouses_result();
2767
        try {
2768
          result.success = iface.getAllWarehouses(args.isActive);
2769
        } catch (InventoryServiceException cex) {
2770
          result.cex = cex;
2771
        }
2772
        return result;
2773
      }
2774
    }
2775
 
2776
    private static class getWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getWarehouse_args> {
2777
      public getWarehouse() {
2778
        super("getWarehouse");
2779
      }
2780
 
2781
      protected getWarehouse_args getEmptyArgsInstance() {
2782
        return new getWarehouse_args();
2783
      }
2784
 
2785
      protected getWarehouse_result getResult(I iface, getWarehouse_args args) throws org.apache.thrift.TException {
2786
        getWarehouse_result result = new getWarehouse_result();
2787
        try {
2788
          result.success = iface.getWarehouse(args.warehouse_id);
2789
        } catch (InventoryServiceException cex) {
2790
          result.cex = cex;
2791
        }
2792
        return result;
2793
      }
2794
    }
2795
 
2796
    private static class getAllItemsForWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllItemsForWarehouse_args> {
2797
      public getAllItemsForWarehouse() {
2798
        super("getAllItemsForWarehouse");
2799
      }
2800
 
2801
      protected getAllItemsForWarehouse_args getEmptyArgsInstance() {
2802
        return new getAllItemsForWarehouse_args();
2803
      }
2804
 
2805
      protected getAllItemsForWarehouse_result getResult(I iface, getAllItemsForWarehouse_args args) throws org.apache.thrift.TException {
2806
        getAllItemsForWarehouse_result result = new getAllItemsForWarehouse_result();
2807
        try {
2808
          result.success = iface.getAllItemsForWarehouse(args.warehouse_id);
2809
        } catch (InventoryServiceException cex) {
2810
          result.cex = cex;
2811
        }
2812
        return result;
2813
      }
2814
    }
2815
 
5967 rajveer 2816
    private static class isOrderBillable<I extends Iface> extends org.apache.thrift.ProcessFunction<I, isOrderBillable_args> {
2817
      public isOrderBillable() {
2818
        super("isOrderBillable");
2819
      }
2820
 
2821
      protected isOrderBillable_args getEmptyArgsInstance() {
2822
        return new isOrderBillable_args();
2823
      }
2824
 
2825
      protected isOrderBillable_result getResult(I iface, isOrderBillable_args args) throws org.apache.thrift.TException {
2826
        isOrderBillable_result result = new isOrderBillable_result();
2827
        result.success = iface.isOrderBillable(args.itemId, args.warehouseId, args.sourceId, args.orderId);
2828
        result.setSuccessIsSet(true);
2829
        return result;
2830
      }
2831
    }
2832
 
5945 mandeep.dh 2833
    private static class reserveItemInWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, reserveItemInWarehouse_args> {
2834
      public reserveItemInWarehouse() {
2835
        super("reserveItemInWarehouse");
2836
      }
2837
 
2838
      protected reserveItemInWarehouse_args getEmptyArgsInstance() {
2839
        return new reserveItemInWarehouse_args();
2840
      }
2841
 
2842
      protected reserveItemInWarehouse_result getResult(I iface, reserveItemInWarehouse_args args) throws org.apache.thrift.TException {
2843
        reserveItemInWarehouse_result result = new reserveItemInWarehouse_result();
2844
        try {
5967 rajveer 2845
          result.success = iface.reserveItemInWarehouse(args.itemId, args.warehouseId, args.sourceId, args.orderId, args.createdTimestamp, args.promisedShippingTimestamp, args.quantity);
5945 mandeep.dh 2846
          result.setSuccessIsSet(true);
2847
        } catch (InventoryServiceException cex) {
2848
          result.cex = cex;
2849
        }
2850
        return result;
2851
      }
2852
    }
2853
 
2854
    private static class reduceReservationCount<I extends Iface> extends org.apache.thrift.ProcessFunction<I, reduceReservationCount_args> {
2855
      public reduceReservationCount() {
2856
        super("reduceReservationCount");
2857
      }
2858
 
2859
      protected reduceReservationCount_args getEmptyArgsInstance() {
2860
        return new reduceReservationCount_args();
2861
      }
2862
 
2863
      protected reduceReservationCount_result getResult(I iface, reduceReservationCount_args args) throws org.apache.thrift.TException {
2864
        reduceReservationCount_result result = new reduceReservationCount_result();
2865
        try {
5967 rajveer 2866
          result.success = iface.reduceReservationCount(args.itemId, args.warehouseId, args.sourceId, args.orderId, args.quantity);
5945 mandeep.dh 2867
          result.setSuccessIsSet(true);
2868
        } catch (InventoryServiceException cex) {
2869
          result.cex = cex;
2870
        }
2871
        return result;
2872
      }
2873
    }
2874
 
2875
    private static class getItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemPricing_args> {
2876
      public getItemPricing() {
2877
        super("getItemPricing");
2878
      }
2879
 
2880
      protected getItemPricing_args getEmptyArgsInstance() {
2881
        return new getItemPricing_args();
2882
      }
2883
 
2884
      protected getItemPricing_result getResult(I iface, getItemPricing_args args) throws org.apache.thrift.TException {
2885
        getItemPricing_result result = new getItemPricing_result();
2886
        try {
2887
          result.success = iface.getItemPricing(args.itemId, args.vendorId);
2888
        } catch (InventoryServiceException cex) {
2889
          result.cex = cex;
2890
        }
2891
        return result;
2892
      }
2893
    }
2894
 
2895
    private static class getAllItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllItemPricing_args> {
2896
      public getAllItemPricing() {
2897
        super("getAllItemPricing");
2898
      }
2899
 
2900
      protected getAllItemPricing_args getEmptyArgsInstance() {
2901
        return new getAllItemPricing_args();
2902
      }
2903
 
2904
      protected getAllItemPricing_result getResult(I iface, getAllItemPricing_args args) throws org.apache.thrift.TException {
2905
        getAllItemPricing_result result = new getAllItemPricing_result();
2906
        try {
2907
          result.success = iface.getAllItemPricing(args.itemId);
2908
        } catch (InventoryServiceException cex) {
2909
          result.cex = cex;
2910
        }
2911
        return result;
2912
      }
2913
    }
2914
 
2915
    private static class addVendorItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendorItemPricing_args> {
2916
      public addVendorItemPricing() {
2917
        super("addVendorItemPricing");
2918
      }
2919
 
2920
      protected addVendorItemPricing_args getEmptyArgsInstance() {
2921
        return new addVendorItemPricing_args();
2922
      }
2923
 
2924
      protected addVendorItemPricing_result getResult(I iface, addVendorItemPricing_args args) throws org.apache.thrift.TException {
2925
        addVendorItemPricing_result result = new addVendorItemPricing_result();
2926
        try {
2927
          iface.addVendorItemPricing(args.vendorItemPricing);
2928
        } catch (InventoryServiceException cex) {
2929
          result.cex = cex;
2930
        }
2931
        return result;
2932
      }
2933
    }
2934
 
2935
    private static class getVendor<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getVendor_args> {
2936
      public getVendor() {
2937
        super("getVendor");
2938
      }
2939
 
2940
      protected getVendor_args getEmptyArgsInstance() {
2941
        return new getVendor_args();
2942
      }
2943
 
2944
      protected getVendor_result getResult(I iface, getVendor_args args) throws org.apache.thrift.TException {
2945
        getVendor_result result = new getVendor_result();
2946
        result.success = iface.getVendor(args.vendorId);
2947
        return result;
2948
      }
2949
    }
2950
 
2951
    private static class getAllVendors<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllVendors_args> {
2952
      public getAllVendors() {
2953
        super("getAllVendors");
2954
      }
2955
 
2956
      protected getAllVendors_args getEmptyArgsInstance() {
2957
        return new getAllVendors_args();
2958
      }
2959
 
2960
      protected getAllVendors_result getResult(I iface, getAllVendors_args args) throws org.apache.thrift.TException {
2961
        getAllVendors_result result = new getAllVendors_result();
2962
        result.success = iface.getAllVendors();
2963
        return result;
2964
      }
2965
    }
2966
 
2967
    private static class addVendorItemMapping<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendorItemMapping_args> {
2968
      public addVendorItemMapping() {
2969
        super("addVendorItemMapping");
2970
      }
2971
 
2972
      protected addVendorItemMapping_args getEmptyArgsInstance() {
2973
        return new addVendorItemMapping_args();
2974
      }
2975
 
2976
      protected addVendorItemMapping_result getResult(I iface, addVendorItemMapping_args args) throws org.apache.thrift.TException {
2977
        addVendorItemMapping_result result = new addVendorItemMapping_result();
2978
        try {
2979
          iface.addVendorItemMapping(args.key, args.vendorItemMapping);
2980
        } catch (InventoryServiceException cex) {
2981
          result.cex = cex;
2982
        }
2983
        return result;
2984
      }
2985
    }
2986
 
2987
    private static class getVendorItemMappings<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getVendorItemMappings_args> {
2988
      public getVendorItemMappings() {
2989
        super("getVendorItemMappings");
2990
      }
2991
 
2992
      protected getVendorItemMappings_args getEmptyArgsInstance() {
2993
        return new getVendorItemMappings_args();
2994
      }
2995
 
2996
      protected getVendorItemMappings_result getResult(I iface, getVendorItemMappings_args args) throws org.apache.thrift.TException {
2997
        getVendorItemMappings_result result = new getVendorItemMappings_result();
2998
        try {
2999
          result.success = iface.getVendorItemMappings(args.itemId);
3000
        } catch (InventoryServiceException cex) {
3001
          result.cex = cex;
3002
        }
3003
        return result;
3004
      }
3005
    }
3006
 
3007
    private static class getPendingOrdersInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPendingOrdersInventory_args> {
3008
      public getPendingOrdersInventory() {
3009
        super("getPendingOrdersInventory");
3010
      }
3011
 
3012
      protected getPendingOrdersInventory_args getEmptyArgsInstance() {
3013
        return new getPendingOrdersInventory_args();
3014
      }
3015
 
3016
      protected getPendingOrdersInventory_result getResult(I iface, getPendingOrdersInventory_args args) throws org.apache.thrift.TException {
3017
        getPendingOrdersInventory_result result = new getPendingOrdersInventory_result();
3018
        result.success = iface.getPendingOrdersInventory(args.vendorid);
3019
        return result;
3020
      }
3021
    }
3022
 
3023
    private static class getWarehouses<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getWarehouses_args> {
3024
      public getWarehouses() {
3025
        super("getWarehouses");
3026
      }
3027
 
3028
      protected getWarehouses_args getEmptyArgsInstance() {
3029
        return new getWarehouses_args();
3030
      }
3031
 
3032
      protected getWarehouses_result getResult(I iface, getWarehouses_args args) throws org.apache.thrift.TException {
3033
        getWarehouses_result result = new getWarehouses_result();
3034
        result.success = iface.getWarehouses(args.warehouseType, args.inventoryType, args.vendorId, args.billingWarehouseId, args.shippingWarehouseId);
3035
        return result;
3036
      }
3037
    }
3038
 
3039
    private static class resetAvailability<I extends Iface> extends org.apache.thrift.ProcessFunction<I, resetAvailability_args> {
3040
      public resetAvailability() {
3041
        super("resetAvailability");
3042
      }
3043
 
3044
      protected resetAvailability_args getEmptyArgsInstance() {
3045
        return new resetAvailability_args();
3046
      }
3047
 
3048
      protected resetAvailability_result getResult(I iface, resetAvailability_args args) throws org.apache.thrift.TException {
3049
        resetAvailability_result result = new resetAvailability_result();
3050
        try {
3051
          iface.resetAvailability(args.itemKey, args.vendorId, args.quantity, args.warehouseId);
3052
        } catch (InventoryServiceException cex) {
3053
          result.cex = cex;
3054
        }
3055
        return result;
3056
      }
3057
    }
3058
 
3059
    private static class resetAvailabilityForWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, resetAvailabilityForWarehouse_args> {
3060
      public resetAvailabilityForWarehouse() {
3061
        super("resetAvailabilityForWarehouse");
3062
      }
3063
 
3064
      protected resetAvailabilityForWarehouse_args getEmptyArgsInstance() {
3065
        return new resetAvailabilityForWarehouse_args();
3066
      }
3067
 
3068
      protected resetAvailabilityForWarehouse_result getResult(I iface, resetAvailabilityForWarehouse_args args) throws org.apache.thrift.TException {
3069
        resetAvailabilityForWarehouse_result result = new resetAvailabilityForWarehouse_result();
3070
        try {
3071
          iface.resetAvailabilityForWarehouse(args.warehouseId);
3072
        } catch (InventoryServiceException cex) {
3073
          result.cex = cex;
3074
        }
3075
        return result;
3076
      }
3077
    }
3078
 
3079
    private static class getItemKeysToBeProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemKeysToBeProcessed_args> {
3080
      public getItemKeysToBeProcessed() {
3081
        super("getItemKeysToBeProcessed");
3082
      }
3083
 
3084
      protected getItemKeysToBeProcessed_args getEmptyArgsInstance() {
3085
        return new getItemKeysToBeProcessed_args();
3086
      }
3087
 
3088
      protected getItemKeysToBeProcessed_result getResult(I iface, getItemKeysToBeProcessed_args args) throws org.apache.thrift.TException {
3089
        getItemKeysToBeProcessed_result result = new getItemKeysToBeProcessed_result();
3090
        result.success = iface.getItemKeysToBeProcessed(args.warehouseId);
3091
        return result;
3092
      }
3093
    }
3094
 
3095
    private static class markMissedInventoryUpdatesAsProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, markMissedInventoryUpdatesAsProcessed_args> {
3096
      public markMissedInventoryUpdatesAsProcessed() {
3097
        super("markMissedInventoryUpdatesAsProcessed");
3098
      }
3099
 
3100
      protected markMissedInventoryUpdatesAsProcessed_args getEmptyArgsInstance() {
3101
        return new markMissedInventoryUpdatesAsProcessed_args();
3102
      }
3103
 
3104
      protected markMissedInventoryUpdatesAsProcessed_result getResult(I iface, markMissedInventoryUpdatesAsProcessed_args args) throws org.apache.thrift.TException {
3105
        markMissedInventoryUpdatesAsProcessed_result result = new markMissedInventoryUpdatesAsProcessed_result();
3106
        iface.markMissedInventoryUpdatesAsProcessed(args.itemKey, args.warehouseId);
3107
        return result;
3108
      }
3109
    }
3110
 
3111
    private static class getIgnoredItemKeys<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getIgnoredItemKeys_args> {
3112
      public getIgnoredItemKeys() {
3113
        super("getIgnoredItemKeys");
3114
      }
3115
 
3116
      protected getIgnoredItemKeys_args getEmptyArgsInstance() {
3117
        return new getIgnoredItemKeys_args();
3118
      }
3119
 
3120
      protected getIgnoredItemKeys_result getResult(I iface, getIgnoredItemKeys_args args) throws org.apache.thrift.TException {
3121
        getIgnoredItemKeys_result result = new getIgnoredItemKeys_result();
3122
        result.success = iface.getIgnoredItemKeys();
3123
        return result;
3124
      }
3125
    }
3126
 
3127
    private static class addBadInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addBadInventory_args> {
3128
      public addBadInventory() {
3129
        super("addBadInventory");
3130
      }
3131
 
3132
      protected addBadInventory_args getEmptyArgsInstance() {
3133
        return new addBadInventory_args();
3134
      }
3135
 
3136
      protected addBadInventory_result getResult(I iface, addBadInventory_args args) throws org.apache.thrift.TException {
3137
        addBadInventory_result result = new addBadInventory_result();
3138
        try {
3139
          iface.addBadInventory(args.itemId, args.warehouseId, args.quantity);
3140
        } catch (InventoryServiceException cex) {
3141
          result.cex = cex;
3142
        }
3143
        return result;
3144
      }
3145
    }
3146
 
3147
    private static class getShippingLocations<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getShippingLocations_args> {
3148
      public getShippingLocations() {
3149
        super("getShippingLocations");
3150
      }
3151
 
3152
      protected getShippingLocations_args getEmptyArgsInstance() {
3153
        return new getShippingLocations_args();
3154
      }
3155
 
3156
      protected getShippingLocations_result getResult(I iface, getShippingLocations_args args) throws org.apache.thrift.TException {
3157
        getShippingLocations_result result = new getShippingLocations_result();
3158
        result.success = iface.getShippingLocations();
3159
        return result;
3160
      }
3161
    }
3162
 
3163
    private static class getAllVendorItemMappings<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllVendorItemMappings_args> {
3164
      public getAllVendorItemMappings() {
3165
        super("getAllVendorItemMappings");
3166
      }
3167
 
3168
      protected getAllVendorItemMappings_args getEmptyArgsInstance() {
3169
        return new getAllVendorItemMappings_args();
3170
      }
3171
 
3172
      protected getAllVendorItemMappings_result getResult(I iface, getAllVendorItemMappings_args args) throws org.apache.thrift.TException {
3173
        getAllVendorItemMappings_result result = new getAllVendorItemMappings_result();
3174
        result.success = iface.getAllVendorItemMappings();
3175
        return result;
3176
      }
3177
    }
3178
 
3179
    private static class getInventorySnapshot<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventorySnapshot_args> {
3180
      public getInventorySnapshot() {
3181
        super("getInventorySnapshot");
3182
      }
3183
 
3184
      protected getInventorySnapshot_args getEmptyArgsInstance() {
3185
        return new getInventorySnapshot_args();
3186
      }
3187
 
3188
      protected getInventorySnapshot_result getResult(I iface, getInventorySnapshot_args args) throws org.apache.thrift.TException {
3189
        getInventorySnapshot_result result = new getInventorySnapshot_result();
3190
        result.success = iface.getInventorySnapshot(args.warehouseId);
3191
        return result;
3192
      }
3193
    }
3194
 
3195
    private static class clearItemAvailabilityCache<I extends Iface> extends org.apache.thrift.ProcessFunction<I, clearItemAvailabilityCache_args> {
3196
      public clearItemAvailabilityCache() {
3197
        super("clearItemAvailabilityCache");
3198
      }
3199
 
3200
      protected clearItemAvailabilityCache_args getEmptyArgsInstance() {
3201
        return new clearItemAvailabilityCache_args();
3202
      }
3203
 
3204
      protected clearItemAvailabilityCache_result getResult(I iface, clearItemAvailabilityCache_args args) throws org.apache.thrift.TException {
3205
        clearItemAvailabilityCache_result result = new clearItemAvailabilityCache_result();
3206
        iface.clearItemAvailabilityCache();
3207
        return result;
3208
      }
3209
    }
3210
 
3211
    private static class updateVendorString<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateVendorString_args> {
3212
      public updateVendorString() {
3213
        super("updateVendorString");
3214
      }
3215
 
3216
      protected updateVendorString_args getEmptyArgsInstance() {
3217
        return new updateVendorString_args();
3218
      }
3219
 
3220
      protected updateVendorString_result getResult(I iface, updateVendorString_args args) throws org.apache.thrift.TException {
3221
        updateVendorString_result result = new updateVendorString_result();
3222
        iface.updateVendorString(args.warehouseId, args.vendorString);
3223
        return result;
3224
      }
3225
    }
3226
 
6096 amit.gupta 3227
    private static class clearItemAvailabilityCacheForItem<I extends Iface> extends org.apache.thrift.ProcessFunction<I, clearItemAvailabilityCacheForItem_args> {
3228
      public clearItemAvailabilityCacheForItem() {
3229
        super("clearItemAvailabilityCacheForItem");
3230
      }
3231
 
3232
      protected clearItemAvailabilityCacheForItem_args getEmptyArgsInstance() {
3233
        return new clearItemAvailabilityCacheForItem_args();
3234
      }
3235
 
3236
      protected clearItemAvailabilityCacheForItem_result getResult(I iface, clearItemAvailabilityCacheForItem_args args) throws org.apache.thrift.TException {
3237
        clearItemAvailabilityCacheForItem_result result = new clearItemAvailabilityCacheForItem_result();
3238
        iface.clearItemAvailabilityCacheForItem(args.item_id);
3239
        return result;
3240
      }
3241
    }
3242
 
5945 mandeep.dh 3243
  }
3244
 
3245
  public static class addWarehouse_args implements org.apache.thrift.TBase<addWarehouse_args, addWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
3246
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addWarehouse_args");
3247
 
3248
    private static final org.apache.thrift.protocol.TField WAREHOUSE_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouse", org.apache.thrift.protocol.TType.STRUCT, (short)1);
3249
 
3250
    private Warehouse warehouse; // required
3251
 
3252
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3253
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3254
      WAREHOUSE((short)1, "warehouse");
3255
 
3256
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3257
 
3258
      static {
3259
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3260
          byName.put(field.getFieldName(), field);
3261
        }
3262
      }
3263
 
3264
      /**
3265
       * Find the _Fields constant that matches fieldId, or null if its not found.
3266
       */
3267
      public static _Fields findByThriftId(int fieldId) {
3268
        switch(fieldId) {
3269
          case 1: // WAREHOUSE
3270
            return WAREHOUSE;
3271
          default:
3272
            return null;
3273
        }
3274
      }
3275
 
3276
      /**
3277
       * Find the _Fields constant that matches fieldId, throwing an exception
3278
       * if it is not found.
3279
       */
3280
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3281
        _Fields fields = findByThriftId(fieldId);
3282
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3283
        return fields;
3284
      }
3285
 
3286
      /**
3287
       * Find the _Fields constant that matches name, or null if its not found.
3288
       */
3289
      public static _Fields findByName(String name) {
3290
        return byName.get(name);
3291
      }
3292
 
3293
      private final short _thriftId;
3294
      private final String _fieldName;
3295
 
3296
      _Fields(short thriftId, String fieldName) {
3297
        _thriftId = thriftId;
3298
        _fieldName = fieldName;
3299
      }
3300
 
3301
      public short getThriftFieldId() {
3302
        return _thriftId;
3303
      }
3304
 
3305
      public String getFieldName() {
3306
        return _fieldName;
3307
      }
3308
    }
3309
 
3310
    // isset id assignments
3311
 
3312
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3313
    static {
3314
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3315
      tmpMap.put(_Fields.WAREHOUSE, new org.apache.thrift.meta_data.FieldMetaData("warehouse", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3316
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class)));
3317
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3318
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addWarehouse_args.class, metaDataMap);
3319
    }
3320
 
3321
    public addWarehouse_args() {
3322
    }
3323
 
3324
    public addWarehouse_args(
3325
      Warehouse warehouse)
3326
    {
3327
      this();
3328
      this.warehouse = warehouse;
3329
    }
3330
 
3331
    /**
3332
     * Performs a deep copy on <i>other</i>.
3333
     */
3334
    public addWarehouse_args(addWarehouse_args other) {
3335
      if (other.isSetWarehouse()) {
3336
        this.warehouse = new Warehouse(other.warehouse);
3337
      }
3338
    }
3339
 
3340
    public addWarehouse_args deepCopy() {
3341
      return new addWarehouse_args(this);
3342
    }
3343
 
3344
    @Override
3345
    public void clear() {
3346
      this.warehouse = null;
3347
    }
3348
 
3349
    public Warehouse getWarehouse() {
3350
      return this.warehouse;
3351
    }
3352
 
3353
    public void setWarehouse(Warehouse warehouse) {
3354
      this.warehouse = warehouse;
3355
    }
3356
 
3357
    public void unsetWarehouse() {
3358
      this.warehouse = null;
3359
    }
3360
 
3361
    /** Returns true if field warehouse is set (has been assigned a value) and false otherwise */
3362
    public boolean isSetWarehouse() {
3363
      return this.warehouse != null;
3364
    }
3365
 
3366
    public void setWarehouseIsSet(boolean value) {
3367
      if (!value) {
3368
        this.warehouse = null;
3369
      }
3370
    }
3371
 
3372
    public void setFieldValue(_Fields field, Object value) {
3373
      switch (field) {
3374
      case WAREHOUSE:
3375
        if (value == null) {
3376
          unsetWarehouse();
3377
        } else {
3378
          setWarehouse((Warehouse)value);
3379
        }
3380
        break;
3381
 
3382
      }
3383
    }
3384
 
3385
    public Object getFieldValue(_Fields field) {
3386
      switch (field) {
3387
      case WAREHOUSE:
3388
        return getWarehouse();
3389
 
3390
      }
3391
      throw new IllegalStateException();
3392
    }
3393
 
3394
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3395
    public boolean isSet(_Fields field) {
3396
      if (field == null) {
3397
        throw new IllegalArgumentException();
3398
      }
3399
 
3400
      switch (field) {
3401
      case WAREHOUSE:
3402
        return isSetWarehouse();
3403
      }
3404
      throw new IllegalStateException();
3405
    }
3406
 
3407
    @Override
3408
    public boolean equals(Object that) {
3409
      if (that == null)
3410
        return false;
3411
      if (that instanceof addWarehouse_args)
3412
        return this.equals((addWarehouse_args)that);
3413
      return false;
3414
    }
3415
 
3416
    public boolean equals(addWarehouse_args that) {
3417
      if (that == null)
3418
        return false;
3419
 
3420
      boolean this_present_warehouse = true && this.isSetWarehouse();
3421
      boolean that_present_warehouse = true && that.isSetWarehouse();
3422
      if (this_present_warehouse || that_present_warehouse) {
3423
        if (!(this_present_warehouse && that_present_warehouse))
3424
          return false;
3425
        if (!this.warehouse.equals(that.warehouse))
3426
          return false;
3427
      }
3428
 
3429
      return true;
3430
    }
3431
 
3432
    @Override
3433
    public int hashCode() {
3434
      return 0;
3435
    }
3436
 
3437
    public int compareTo(addWarehouse_args other) {
3438
      if (!getClass().equals(other.getClass())) {
3439
        return getClass().getName().compareTo(other.getClass().getName());
3440
      }
3441
 
3442
      int lastComparison = 0;
3443
      addWarehouse_args typedOther = (addWarehouse_args)other;
3444
 
3445
      lastComparison = Boolean.valueOf(isSetWarehouse()).compareTo(typedOther.isSetWarehouse());
3446
      if (lastComparison != 0) {
3447
        return lastComparison;
3448
      }
3449
      if (isSetWarehouse()) {
3450
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse, typedOther.warehouse);
3451
        if (lastComparison != 0) {
3452
          return lastComparison;
3453
        }
3454
      }
3455
      return 0;
3456
    }
3457
 
3458
    public _Fields fieldForId(int fieldId) {
3459
      return _Fields.findByThriftId(fieldId);
3460
    }
3461
 
3462
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3463
      org.apache.thrift.protocol.TField field;
3464
      iprot.readStructBegin();
3465
      while (true)
3466
      {
3467
        field = iprot.readFieldBegin();
3468
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3469
          break;
3470
        }
3471
        switch (field.id) {
3472
          case 1: // WAREHOUSE
3473
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3474
              this.warehouse = new Warehouse();
3475
              this.warehouse.read(iprot);
3476
            } else { 
3477
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3478
            }
3479
            break;
3480
          default:
3481
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3482
        }
3483
        iprot.readFieldEnd();
3484
      }
3485
      iprot.readStructEnd();
3486
      validate();
3487
    }
3488
 
3489
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3490
      validate();
3491
 
3492
      oprot.writeStructBegin(STRUCT_DESC);
3493
      if (this.warehouse != null) {
3494
        oprot.writeFieldBegin(WAREHOUSE_FIELD_DESC);
3495
        this.warehouse.write(oprot);
3496
        oprot.writeFieldEnd();
3497
      }
3498
      oprot.writeFieldStop();
3499
      oprot.writeStructEnd();
3500
    }
3501
 
3502
    @Override
3503
    public String toString() {
3504
      StringBuilder sb = new StringBuilder("addWarehouse_args(");
3505
      boolean first = true;
3506
 
3507
      sb.append("warehouse:");
3508
      if (this.warehouse == null) {
3509
        sb.append("null");
3510
      } else {
3511
        sb.append(this.warehouse);
3512
      }
3513
      first = false;
3514
      sb.append(")");
3515
      return sb.toString();
3516
    }
3517
 
3518
    public void validate() throws org.apache.thrift.TException {
3519
      // check for required fields
3520
    }
3521
 
3522
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3523
      try {
3524
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3525
      } catch (org.apache.thrift.TException te) {
3526
        throw new java.io.IOException(te);
3527
      }
3528
    }
3529
 
3530
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3531
      try {
3532
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3533
      } catch (org.apache.thrift.TException te) {
3534
        throw new java.io.IOException(te);
3535
      }
3536
    }
3537
 
3538
  }
3539
 
3540
  public static class addWarehouse_result implements org.apache.thrift.TBase<addWarehouse_result, addWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
3541
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addWarehouse_result");
3542
 
3543
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I64, (short)0);
3544
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
3545
 
3546
    private long success; // required
3547
    private InventoryServiceException cex; // required
3548
 
3549
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3550
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3551
      SUCCESS((short)0, "success"),
3552
      CEX((short)1, "cex");
3553
 
3554
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3555
 
3556
      static {
3557
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3558
          byName.put(field.getFieldName(), field);
3559
        }
3560
      }
3561
 
3562
      /**
3563
       * Find the _Fields constant that matches fieldId, or null if its not found.
3564
       */
3565
      public static _Fields findByThriftId(int fieldId) {
3566
        switch(fieldId) {
3567
          case 0: // SUCCESS
3568
            return SUCCESS;
3569
          case 1: // CEX
3570
            return CEX;
3571
          default:
3572
            return null;
3573
        }
3574
      }
3575
 
3576
      /**
3577
       * Find the _Fields constant that matches fieldId, throwing an exception
3578
       * if it is not found.
3579
       */
3580
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3581
        _Fields fields = findByThriftId(fieldId);
3582
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3583
        return fields;
3584
      }
3585
 
3586
      /**
3587
       * Find the _Fields constant that matches name, or null if its not found.
3588
       */
3589
      public static _Fields findByName(String name) {
3590
        return byName.get(name);
3591
      }
3592
 
3593
      private final short _thriftId;
3594
      private final String _fieldName;
3595
 
3596
      _Fields(short thriftId, String fieldName) {
3597
        _thriftId = thriftId;
3598
        _fieldName = fieldName;
3599
      }
3600
 
3601
      public short getThriftFieldId() {
3602
        return _thriftId;
3603
      }
3604
 
3605
      public String getFieldName() {
3606
        return _fieldName;
3607
      }
3608
    }
3609
 
3610
    // isset id assignments
3611
    private static final int __SUCCESS_ISSET_ID = 0;
3612
    private BitSet __isset_bit_vector = new BitSet(1);
3613
 
3614
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3615
    static {
3616
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3617
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3618
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3619
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3620
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3621
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3622
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addWarehouse_result.class, metaDataMap);
3623
    }
3624
 
3625
    public addWarehouse_result() {
3626
    }
3627
 
3628
    public addWarehouse_result(
3629
      long success,
3630
      InventoryServiceException cex)
3631
    {
3632
      this();
3633
      this.success = success;
3634
      setSuccessIsSet(true);
3635
      this.cex = cex;
3636
    }
3637
 
3638
    /**
3639
     * Performs a deep copy on <i>other</i>.
3640
     */
3641
    public addWarehouse_result(addWarehouse_result other) {
3642
      __isset_bit_vector.clear();
3643
      __isset_bit_vector.or(other.__isset_bit_vector);
3644
      this.success = other.success;
3645
      if (other.isSetCex()) {
3646
        this.cex = new InventoryServiceException(other.cex);
3647
      }
3648
    }
3649
 
3650
    public addWarehouse_result deepCopy() {
3651
      return new addWarehouse_result(this);
3652
    }
3653
 
3654
    @Override
3655
    public void clear() {
3656
      setSuccessIsSet(false);
3657
      this.success = 0;
3658
      this.cex = null;
3659
    }
3660
 
3661
    public long getSuccess() {
3662
      return this.success;
3663
    }
3664
 
3665
    public void setSuccess(long success) {
3666
      this.success = success;
3667
      setSuccessIsSet(true);
3668
    }
3669
 
3670
    public void unsetSuccess() {
3671
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
3672
    }
3673
 
3674
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
3675
    public boolean isSetSuccess() {
3676
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
3677
    }
3678
 
3679
    public void setSuccessIsSet(boolean value) {
3680
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
3681
    }
3682
 
3683
    public InventoryServiceException getCex() {
3684
      return this.cex;
3685
    }
3686
 
3687
    public void setCex(InventoryServiceException cex) {
3688
      this.cex = cex;
3689
    }
3690
 
3691
    public void unsetCex() {
3692
      this.cex = null;
3693
    }
3694
 
3695
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
3696
    public boolean isSetCex() {
3697
      return this.cex != null;
3698
    }
3699
 
3700
    public void setCexIsSet(boolean value) {
3701
      if (!value) {
3702
        this.cex = null;
3703
      }
3704
    }
3705
 
3706
    public void setFieldValue(_Fields field, Object value) {
3707
      switch (field) {
3708
      case SUCCESS:
3709
        if (value == null) {
3710
          unsetSuccess();
3711
        } else {
3712
          setSuccess((Long)value);
3713
        }
3714
        break;
3715
 
3716
      case CEX:
3717
        if (value == null) {
3718
          unsetCex();
3719
        } else {
3720
          setCex((InventoryServiceException)value);
3721
        }
3722
        break;
3723
 
3724
      }
3725
    }
3726
 
3727
    public Object getFieldValue(_Fields field) {
3728
      switch (field) {
3729
      case SUCCESS:
3730
        return Long.valueOf(getSuccess());
3731
 
3732
      case CEX:
3733
        return getCex();
3734
 
3735
      }
3736
      throw new IllegalStateException();
3737
    }
3738
 
3739
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3740
    public boolean isSet(_Fields field) {
3741
      if (field == null) {
3742
        throw new IllegalArgumentException();
3743
      }
3744
 
3745
      switch (field) {
3746
      case SUCCESS:
3747
        return isSetSuccess();
3748
      case CEX:
3749
        return isSetCex();
3750
      }
3751
      throw new IllegalStateException();
3752
    }
3753
 
3754
    @Override
3755
    public boolean equals(Object that) {
3756
      if (that == null)
3757
        return false;
3758
      if (that instanceof addWarehouse_result)
3759
        return this.equals((addWarehouse_result)that);
3760
      return false;
3761
    }
3762
 
3763
    public boolean equals(addWarehouse_result that) {
3764
      if (that == null)
3765
        return false;
3766
 
3767
      boolean this_present_success = true;
3768
      boolean that_present_success = true;
3769
      if (this_present_success || that_present_success) {
3770
        if (!(this_present_success && that_present_success))
3771
          return false;
3772
        if (this.success != that.success)
3773
          return false;
3774
      }
3775
 
3776
      boolean this_present_cex = true && this.isSetCex();
3777
      boolean that_present_cex = true && that.isSetCex();
3778
      if (this_present_cex || that_present_cex) {
3779
        if (!(this_present_cex && that_present_cex))
3780
          return false;
3781
        if (!this.cex.equals(that.cex))
3782
          return false;
3783
      }
3784
 
3785
      return true;
3786
    }
3787
 
3788
    @Override
3789
    public int hashCode() {
3790
      return 0;
3791
    }
3792
 
3793
    public int compareTo(addWarehouse_result other) {
3794
      if (!getClass().equals(other.getClass())) {
3795
        return getClass().getName().compareTo(other.getClass().getName());
3796
      }
3797
 
3798
      int lastComparison = 0;
3799
      addWarehouse_result typedOther = (addWarehouse_result)other;
3800
 
3801
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
3802
      if (lastComparison != 0) {
3803
        return lastComparison;
3804
      }
3805
      if (isSetSuccess()) {
3806
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3807
        if (lastComparison != 0) {
3808
          return lastComparison;
3809
        }
3810
      }
3811
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
3812
      if (lastComparison != 0) {
3813
        return lastComparison;
3814
      }
3815
      if (isSetCex()) {
3816
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
3817
        if (lastComparison != 0) {
3818
          return lastComparison;
3819
        }
3820
      }
3821
      return 0;
3822
    }
3823
 
3824
    public _Fields fieldForId(int fieldId) {
3825
      return _Fields.findByThriftId(fieldId);
3826
    }
3827
 
3828
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3829
      org.apache.thrift.protocol.TField field;
3830
      iprot.readStructBegin();
3831
      while (true)
3832
      {
3833
        field = iprot.readFieldBegin();
3834
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3835
          break;
3836
        }
3837
        switch (field.id) {
3838
          case 0: // SUCCESS
3839
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3840
              this.success = iprot.readI64();
3841
              setSuccessIsSet(true);
3842
            } else { 
3843
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3844
            }
3845
            break;
3846
          case 1: // CEX
3847
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3848
              this.cex = new InventoryServiceException();
3849
              this.cex.read(iprot);
3850
            } else { 
3851
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3852
            }
3853
            break;
3854
          default:
3855
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3856
        }
3857
        iprot.readFieldEnd();
3858
      }
3859
      iprot.readStructEnd();
3860
      validate();
3861
    }
3862
 
3863
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3864
      oprot.writeStructBegin(STRUCT_DESC);
3865
 
3866
      if (this.isSetSuccess()) {
3867
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3868
        oprot.writeI64(this.success);
3869
        oprot.writeFieldEnd();
3870
      } else if (this.isSetCex()) {
3871
        oprot.writeFieldBegin(CEX_FIELD_DESC);
3872
        this.cex.write(oprot);
3873
        oprot.writeFieldEnd();
3874
      }
3875
      oprot.writeFieldStop();
3876
      oprot.writeStructEnd();
3877
    }
3878
 
3879
    @Override
3880
    public String toString() {
3881
      StringBuilder sb = new StringBuilder("addWarehouse_result(");
3882
      boolean first = true;
3883
 
3884
      sb.append("success:");
3885
      sb.append(this.success);
3886
      first = false;
3887
      if (!first) sb.append(", ");
3888
      sb.append("cex:");
3889
      if (this.cex == null) {
3890
        sb.append("null");
3891
      } else {
3892
        sb.append(this.cex);
3893
      }
3894
      first = false;
3895
      sb.append(")");
3896
      return sb.toString();
3897
    }
3898
 
3899
    public void validate() throws org.apache.thrift.TException {
3900
      // check for required fields
3901
    }
3902
 
3903
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3904
      try {
3905
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3906
      } catch (org.apache.thrift.TException te) {
3907
        throw new java.io.IOException(te);
3908
      }
3909
    }
3910
 
3911
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3912
      try {
3913
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3914
      } catch (org.apache.thrift.TException te) {
3915
        throw new java.io.IOException(te);
3916
      }
3917
    }
3918
 
3919
  }
3920
 
3921
  public static class addVendor_args implements org.apache.thrift.TBase<addVendor_args, addVendor_args._Fields>, java.io.Serializable, Cloneable   {
3922
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendor_args");
3923
 
3924
    private static final org.apache.thrift.protocol.TField VENDOR_FIELD_DESC = new org.apache.thrift.protocol.TField("vendor", org.apache.thrift.protocol.TType.STRUCT, (short)1);
3925
 
3926
    private Vendor vendor; // required
3927
 
3928
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3929
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3930
      VENDOR((short)1, "vendor");
3931
 
3932
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3933
 
3934
      static {
3935
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3936
          byName.put(field.getFieldName(), field);
3937
        }
3938
      }
3939
 
3940
      /**
3941
       * Find the _Fields constant that matches fieldId, or null if its not found.
3942
       */
3943
      public static _Fields findByThriftId(int fieldId) {
3944
        switch(fieldId) {
3945
          case 1: // VENDOR
3946
            return VENDOR;
3947
          default:
3948
            return null;
3949
        }
3950
      }
3951
 
3952
      /**
3953
       * Find the _Fields constant that matches fieldId, throwing an exception
3954
       * if it is not found.
3955
       */
3956
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3957
        _Fields fields = findByThriftId(fieldId);
3958
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3959
        return fields;
3960
      }
3961
 
3962
      /**
3963
       * Find the _Fields constant that matches name, or null if its not found.
3964
       */
3965
      public static _Fields findByName(String name) {
3966
        return byName.get(name);
3967
      }
3968
 
3969
      private final short _thriftId;
3970
      private final String _fieldName;
3971
 
3972
      _Fields(short thriftId, String fieldName) {
3973
        _thriftId = thriftId;
3974
        _fieldName = fieldName;
3975
      }
3976
 
3977
      public short getThriftFieldId() {
3978
        return _thriftId;
3979
      }
3980
 
3981
      public String getFieldName() {
3982
        return _fieldName;
3983
      }
3984
    }
3985
 
3986
    // isset id assignments
3987
 
3988
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3989
    static {
3990
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3991
      tmpMap.put(_Fields.VENDOR, new org.apache.thrift.meta_data.FieldMetaData("vendor", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3992
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class)));
3993
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3994
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendor_args.class, metaDataMap);
3995
    }
3996
 
3997
    public addVendor_args() {
3998
    }
3999
 
4000
    public addVendor_args(
4001
      Vendor vendor)
4002
    {
4003
      this();
4004
      this.vendor = vendor;
4005
    }
4006
 
4007
    /**
4008
     * Performs a deep copy on <i>other</i>.
4009
     */
4010
    public addVendor_args(addVendor_args other) {
4011
      if (other.isSetVendor()) {
4012
        this.vendor = new Vendor(other.vendor);
4013
      }
4014
    }
4015
 
4016
    public addVendor_args deepCopy() {
4017
      return new addVendor_args(this);
4018
    }
4019
 
4020
    @Override
4021
    public void clear() {
4022
      this.vendor = null;
4023
    }
4024
 
4025
    public Vendor getVendor() {
4026
      return this.vendor;
4027
    }
4028
 
4029
    public void setVendor(Vendor vendor) {
4030
      this.vendor = vendor;
4031
    }
4032
 
4033
    public void unsetVendor() {
4034
      this.vendor = null;
4035
    }
4036
 
4037
    /** Returns true if field vendor is set (has been assigned a value) and false otherwise */
4038
    public boolean isSetVendor() {
4039
      return this.vendor != null;
4040
    }
4041
 
4042
    public void setVendorIsSet(boolean value) {
4043
      if (!value) {
4044
        this.vendor = null;
4045
      }
4046
    }
4047
 
4048
    public void setFieldValue(_Fields field, Object value) {
4049
      switch (field) {
4050
      case VENDOR:
4051
        if (value == null) {
4052
          unsetVendor();
4053
        } else {
4054
          setVendor((Vendor)value);
4055
        }
4056
        break;
4057
 
4058
      }
4059
    }
4060
 
4061
    public Object getFieldValue(_Fields field) {
4062
      switch (field) {
4063
      case VENDOR:
4064
        return getVendor();
4065
 
4066
      }
4067
      throw new IllegalStateException();
4068
    }
4069
 
4070
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4071
    public boolean isSet(_Fields field) {
4072
      if (field == null) {
4073
        throw new IllegalArgumentException();
4074
      }
4075
 
4076
      switch (field) {
4077
      case VENDOR:
4078
        return isSetVendor();
4079
      }
4080
      throw new IllegalStateException();
4081
    }
4082
 
4083
    @Override
4084
    public boolean equals(Object that) {
4085
      if (that == null)
4086
        return false;
4087
      if (that instanceof addVendor_args)
4088
        return this.equals((addVendor_args)that);
4089
      return false;
4090
    }
4091
 
4092
    public boolean equals(addVendor_args that) {
4093
      if (that == null)
4094
        return false;
4095
 
4096
      boolean this_present_vendor = true && this.isSetVendor();
4097
      boolean that_present_vendor = true && that.isSetVendor();
4098
      if (this_present_vendor || that_present_vendor) {
4099
        if (!(this_present_vendor && that_present_vendor))
4100
          return false;
4101
        if (!this.vendor.equals(that.vendor))
4102
          return false;
4103
      }
4104
 
4105
      return true;
4106
    }
4107
 
4108
    @Override
4109
    public int hashCode() {
4110
      return 0;
4111
    }
4112
 
4113
    public int compareTo(addVendor_args other) {
4114
      if (!getClass().equals(other.getClass())) {
4115
        return getClass().getName().compareTo(other.getClass().getName());
4116
      }
4117
 
4118
      int lastComparison = 0;
4119
      addVendor_args typedOther = (addVendor_args)other;
4120
 
4121
      lastComparison = Boolean.valueOf(isSetVendor()).compareTo(typedOther.isSetVendor());
4122
      if (lastComparison != 0) {
4123
        return lastComparison;
4124
      }
4125
      if (isSetVendor()) {
4126
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendor, typedOther.vendor);
4127
        if (lastComparison != 0) {
4128
          return lastComparison;
4129
        }
4130
      }
4131
      return 0;
4132
    }
4133
 
4134
    public _Fields fieldForId(int fieldId) {
4135
      return _Fields.findByThriftId(fieldId);
4136
    }
4137
 
4138
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4139
      org.apache.thrift.protocol.TField field;
4140
      iprot.readStructBegin();
4141
      while (true)
4142
      {
4143
        field = iprot.readFieldBegin();
4144
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4145
          break;
4146
        }
4147
        switch (field.id) {
4148
          case 1: // VENDOR
4149
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4150
              this.vendor = new Vendor();
4151
              this.vendor.read(iprot);
4152
            } else { 
4153
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4154
            }
4155
            break;
4156
          default:
4157
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4158
        }
4159
        iprot.readFieldEnd();
4160
      }
4161
      iprot.readStructEnd();
4162
      validate();
4163
    }
4164
 
4165
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4166
      validate();
4167
 
4168
      oprot.writeStructBegin(STRUCT_DESC);
4169
      if (this.vendor != null) {
4170
        oprot.writeFieldBegin(VENDOR_FIELD_DESC);
4171
        this.vendor.write(oprot);
4172
        oprot.writeFieldEnd();
4173
      }
4174
      oprot.writeFieldStop();
4175
      oprot.writeStructEnd();
4176
    }
4177
 
4178
    @Override
4179
    public String toString() {
4180
      StringBuilder sb = new StringBuilder("addVendor_args(");
4181
      boolean first = true;
4182
 
4183
      sb.append("vendor:");
4184
      if (this.vendor == null) {
4185
        sb.append("null");
4186
      } else {
4187
        sb.append(this.vendor);
4188
      }
4189
      first = false;
4190
      sb.append(")");
4191
      return sb.toString();
4192
    }
4193
 
4194
    public void validate() throws org.apache.thrift.TException {
4195
      // check for required fields
4196
    }
4197
 
4198
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4199
      try {
4200
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4201
      } catch (org.apache.thrift.TException te) {
4202
        throw new java.io.IOException(te);
4203
      }
4204
    }
4205
 
4206
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4207
      try {
4208
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4209
      } catch (org.apache.thrift.TException te) {
4210
        throw new java.io.IOException(te);
4211
      }
4212
    }
4213
 
4214
  }
4215
 
4216
  public static class addVendor_result implements org.apache.thrift.TBase<addVendor_result, addVendor_result._Fields>, java.io.Serializable, Cloneable   {
4217
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendor_result");
4218
 
4219
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I64, (short)0);
4220
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
4221
 
4222
    private long success; // required
4223
    private InventoryServiceException cex; // required
4224
 
4225
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4226
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4227
      SUCCESS((short)0, "success"),
4228
      CEX((short)1, "cex");
4229
 
4230
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4231
 
4232
      static {
4233
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4234
          byName.put(field.getFieldName(), field);
4235
        }
4236
      }
4237
 
4238
      /**
4239
       * Find the _Fields constant that matches fieldId, or null if its not found.
4240
       */
4241
      public static _Fields findByThriftId(int fieldId) {
4242
        switch(fieldId) {
4243
          case 0: // SUCCESS
4244
            return SUCCESS;
4245
          case 1: // CEX
4246
            return CEX;
4247
          default:
4248
            return null;
4249
        }
4250
      }
4251
 
4252
      /**
4253
       * Find the _Fields constant that matches fieldId, throwing an exception
4254
       * if it is not found.
4255
       */
4256
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4257
        _Fields fields = findByThriftId(fieldId);
4258
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4259
        return fields;
4260
      }
4261
 
4262
      /**
4263
       * Find the _Fields constant that matches name, or null if its not found.
4264
       */
4265
      public static _Fields findByName(String name) {
4266
        return byName.get(name);
4267
      }
4268
 
4269
      private final short _thriftId;
4270
      private final String _fieldName;
4271
 
4272
      _Fields(short thriftId, String fieldName) {
4273
        _thriftId = thriftId;
4274
        _fieldName = fieldName;
4275
      }
4276
 
4277
      public short getThriftFieldId() {
4278
        return _thriftId;
4279
      }
4280
 
4281
      public String getFieldName() {
4282
        return _fieldName;
4283
      }
4284
    }
4285
 
4286
    // isset id assignments
4287
    private static final int __SUCCESS_ISSET_ID = 0;
4288
    private BitSet __isset_bit_vector = new BitSet(1);
4289
 
4290
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4291
    static {
4292
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4293
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4294
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4295
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4296
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4297
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4298
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendor_result.class, metaDataMap);
4299
    }
4300
 
4301
    public addVendor_result() {
4302
    }
4303
 
4304
    public addVendor_result(
4305
      long success,
4306
      InventoryServiceException cex)
4307
    {
4308
      this();
4309
      this.success = success;
4310
      setSuccessIsSet(true);
4311
      this.cex = cex;
4312
    }
4313
 
4314
    /**
4315
     * Performs a deep copy on <i>other</i>.
4316
     */
4317
    public addVendor_result(addVendor_result other) {
4318
      __isset_bit_vector.clear();
4319
      __isset_bit_vector.or(other.__isset_bit_vector);
4320
      this.success = other.success;
4321
      if (other.isSetCex()) {
4322
        this.cex = new InventoryServiceException(other.cex);
4323
      }
4324
    }
4325
 
4326
    public addVendor_result deepCopy() {
4327
      return new addVendor_result(this);
4328
    }
4329
 
4330
    @Override
4331
    public void clear() {
4332
      setSuccessIsSet(false);
4333
      this.success = 0;
4334
      this.cex = null;
4335
    }
4336
 
4337
    public long getSuccess() {
4338
      return this.success;
4339
    }
4340
 
4341
    public void setSuccess(long success) {
4342
      this.success = success;
4343
      setSuccessIsSet(true);
4344
    }
4345
 
4346
    public void unsetSuccess() {
4347
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
4348
    }
4349
 
4350
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
4351
    public boolean isSetSuccess() {
4352
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
4353
    }
4354
 
4355
    public void setSuccessIsSet(boolean value) {
4356
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
4357
    }
4358
 
4359
    public InventoryServiceException getCex() {
4360
      return this.cex;
4361
    }
4362
 
4363
    public void setCex(InventoryServiceException cex) {
4364
      this.cex = cex;
4365
    }
4366
 
4367
    public void unsetCex() {
4368
      this.cex = null;
4369
    }
4370
 
4371
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
4372
    public boolean isSetCex() {
4373
      return this.cex != null;
4374
    }
4375
 
4376
    public void setCexIsSet(boolean value) {
4377
      if (!value) {
4378
        this.cex = null;
4379
      }
4380
    }
4381
 
4382
    public void setFieldValue(_Fields field, Object value) {
4383
      switch (field) {
4384
      case SUCCESS:
4385
        if (value == null) {
4386
          unsetSuccess();
4387
        } else {
4388
          setSuccess((Long)value);
4389
        }
4390
        break;
4391
 
4392
      case CEX:
4393
        if (value == null) {
4394
          unsetCex();
4395
        } else {
4396
          setCex((InventoryServiceException)value);
4397
        }
4398
        break;
4399
 
4400
      }
4401
    }
4402
 
4403
    public Object getFieldValue(_Fields field) {
4404
      switch (field) {
4405
      case SUCCESS:
4406
        return Long.valueOf(getSuccess());
4407
 
4408
      case CEX:
4409
        return getCex();
4410
 
4411
      }
4412
      throw new IllegalStateException();
4413
    }
4414
 
4415
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4416
    public boolean isSet(_Fields field) {
4417
      if (field == null) {
4418
        throw new IllegalArgumentException();
4419
      }
4420
 
4421
      switch (field) {
4422
      case SUCCESS:
4423
        return isSetSuccess();
4424
      case CEX:
4425
        return isSetCex();
4426
      }
4427
      throw new IllegalStateException();
4428
    }
4429
 
4430
    @Override
4431
    public boolean equals(Object that) {
4432
      if (that == null)
4433
        return false;
4434
      if (that instanceof addVendor_result)
4435
        return this.equals((addVendor_result)that);
4436
      return false;
4437
    }
4438
 
4439
    public boolean equals(addVendor_result that) {
4440
      if (that == null)
4441
        return false;
4442
 
4443
      boolean this_present_success = true;
4444
      boolean that_present_success = true;
4445
      if (this_present_success || that_present_success) {
4446
        if (!(this_present_success && that_present_success))
4447
          return false;
4448
        if (this.success != that.success)
4449
          return false;
4450
      }
4451
 
4452
      boolean this_present_cex = true && this.isSetCex();
4453
      boolean that_present_cex = true && that.isSetCex();
4454
      if (this_present_cex || that_present_cex) {
4455
        if (!(this_present_cex && that_present_cex))
4456
          return false;
4457
        if (!this.cex.equals(that.cex))
4458
          return false;
4459
      }
4460
 
4461
      return true;
4462
    }
4463
 
4464
    @Override
4465
    public int hashCode() {
4466
      return 0;
4467
    }
4468
 
4469
    public int compareTo(addVendor_result other) {
4470
      if (!getClass().equals(other.getClass())) {
4471
        return getClass().getName().compareTo(other.getClass().getName());
4472
      }
4473
 
4474
      int lastComparison = 0;
4475
      addVendor_result typedOther = (addVendor_result)other;
4476
 
4477
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
4478
      if (lastComparison != 0) {
4479
        return lastComparison;
4480
      }
4481
      if (isSetSuccess()) {
4482
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
4483
        if (lastComparison != 0) {
4484
          return lastComparison;
4485
        }
4486
      }
4487
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
4488
      if (lastComparison != 0) {
4489
        return lastComparison;
4490
      }
4491
      if (isSetCex()) {
4492
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
4493
        if (lastComparison != 0) {
4494
          return lastComparison;
4495
        }
4496
      }
4497
      return 0;
4498
    }
4499
 
4500
    public _Fields fieldForId(int fieldId) {
4501
      return _Fields.findByThriftId(fieldId);
4502
    }
4503
 
4504
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4505
      org.apache.thrift.protocol.TField field;
4506
      iprot.readStructBegin();
4507
      while (true)
4508
      {
4509
        field = iprot.readFieldBegin();
4510
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4511
          break;
4512
        }
4513
        switch (field.id) {
4514
          case 0: // SUCCESS
4515
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4516
              this.success = iprot.readI64();
4517
              setSuccessIsSet(true);
4518
            } else { 
4519
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4520
            }
4521
            break;
4522
          case 1: // CEX
4523
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4524
              this.cex = new InventoryServiceException();
4525
              this.cex.read(iprot);
4526
            } else { 
4527
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4528
            }
4529
            break;
4530
          default:
4531
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4532
        }
4533
        iprot.readFieldEnd();
4534
      }
4535
      iprot.readStructEnd();
4536
      validate();
4537
    }
4538
 
4539
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4540
      oprot.writeStructBegin(STRUCT_DESC);
4541
 
4542
      if (this.isSetSuccess()) {
4543
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
4544
        oprot.writeI64(this.success);
4545
        oprot.writeFieldEnd();
4546
      } else if (this.isSetCex()) {
4547
        oprot.writeFieldBegin(CEX_FIELD_DESC);
4548
        this.cex.write(oprot);
4549
        oprot.writeFieldEnd();
4550
      }
4551
      oprot.writeFieldStop();
4552
      oprot.writeStructEnd();
4553
    }
4554
 
4555
    @Override
4556
    public String toString() {
4557
      StringBuilder sb = new StringBuilder("addVendor_result(");
4558
      boolean first = true;
4559
 
4560
      sb.append("success:");
4561
      sb.append(this.success);
4562
      first = false;
4563
      if (!first) sb.append(", ");
4564
      sb.append("cex:");
4565
      if (this.cex == null) {
4566
        sb.append("null");
4567
      } else {
4568
        sb.append(this.cex);
4569
      }
4570
      first = false;
4571
      sb.append(")");
4572
      return sb.toString();
4573
    }
4574
 
4575
    public void validate() throws org.apache.thrift.TException {
4576
      // check for required fields
4577
    }
4578
 
4579
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4580
      try {
4581
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4582
      } catch (org.apache.thrift.TException te) {
4583
        throw new java.io.IOException(te);
4584
      }
4585
    }
4586
 
4587
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4588
      try {
4589
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4590
      } catch (org.apache.thrift.TException te) {
4591
        throw new java.io.IOException(te);
4592
      }
4593
    }
4594
 
4595
  }
4596
 
4597
  public static class updateInventoryHistory_args implements org.apache.thrift.TBase<updateInventoryHistory_args, updateInventoryHistory_args._Fields>, java.io.Serializable, Cloneable   {
4598
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventoryHistory_args");
4599
 
4600
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouse_id", org.apache.thrift.protocol.TType.I64, (short)1);
4601
    private static final org.apache.thrift.protocol.TField TIMESTAMP_FIELD_DESC = new org.apache.thrift.protocol.TField("timestamp", org.apache.thrift.protocol.TType.STRING, (short)2);
4602
    private static final org.apache.thrift.protocol.TField AVAILABILITY_FIELD_DESC = new org.apache.thrift.protocol.TField("availability", org.apache.thrift.protocol.TType.MAP, (short)3);
4603
 
4604
    private long warehouse_id; // required
4605
    private String timestamp; // required
4606
    private Map<String,Long> availability; // required
4607
 
4608
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4609
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4610
      WAREHOUSE_ID((short)1, "warehouse_id"),
4611
      TIMESTAMP((short)2, "timestamp"),
4612
      AVAILABILITY((short)3, "availability");
4613
 
4614
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4615
 
4616
      static {
4617
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4618
          byName.put(field.getFieldName(), field);
4619
        }
4620
      }
4621
 
4622
      /**
4623
       * Find the _Fields constant that matches fieldId, or null if its not found.
4624
       */
4625
      public static _Fields findByThriftId(int fieldId) {
4626
        switch(fieldId) {
4627
          case 1: // WAREHOUSE_ID
4628
            return WAREHOUSE_ID;
4629
          case 2: // TIMESTAMP
4630
            return TIMESTAMP;
4631
          case 3: // AVAILABILITY
4632
            return AVAILABILITY;
4633
          default:
4634
            return null;
4635
        }
4636
      }
4637
 
4638
      /**
4639
       * Find the _Fields constant that matches fieldId, throwing an exception
4640
       * if it is not found.
4641
       */
4642
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4643
        _Fields fields = findByThriftId(fieldId);
4644
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4645
        return fields;
4646
      }
4647
 
4648
      /**
4649
       * Find the _Fields constant that matches name, or null if its not found.
4650
       */
4651
      public static _Fields findByName(String name) {
4652
        return byName.get(name);
4653
      }
4654
 
4655
      private final short _thriftId;
4656
      private final String _fieldName;
4657
 
4658
      _Fields(short thriftId, String fieldName) {
4659
        _thriftId = thriftId;
4660
        _fieldName = fieldName;
4661
      }
4662
 
4663
      public short getThriftFieldId() {
4664
        return _thriftId;
4665
      }
4666
 
4667
      public String getFieldName() {
4668
        return _fieldName;
4669
      }
4670
    }
4671
 
4672
    // isset id assignments
4673
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
4674
    private BitSet __isset_bit_vector = new BitSet(1);
4675
 
4676
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4677
    static {
4678
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4679
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4680
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4681
      tmpMap.put(_Fields.TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("timestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4682
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
4683
      tmpMap.put(_Fields.AVAILABILITY, new org.apache.thrift.meta_data.FieldMetaData("availability", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4684
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
4685
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
4686
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
4687
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4688
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventoryHistory_args.class, metaDataMap);
4689
    }
4690
 
4691
    public updateInventoryHistory_args() {
4692
    }
4693
 
4694
    public updateInventoryHistory_args(
4695
      long warehouse_id,
4696
      String timestamp,
4697
      Map<String,Long> availability)
4698
    {
4699
      this();
4700
      this.warehouse_id = warehouse_id;
4701
      setWarehouse_idIsSet(true);
4702
      this.timestamp = timestamp;
4703
      this.availability = availability;
4704
    }
4705
 
4706
    /**
4707
     * Performs a deep copy on <i>other</i>.
4708
     */
4709
    public updateInventoryHistory_args(updateInventoryHistory_args other) {
4710
      __isset_bit_vector.clear();
4711
      __isset_bit_vector.or(other.__isset_bit_vector);
4712
      this.warehouse_id = other.warehouse_id;
4713
      if (other.isSetTimestamp()) {
4714
        this.timestamp = other.timestamp;
4715
      }
4716
      if (other.isSetAvailability()) {
4717
        Map<String,Long> __this__availability = new HashMap<String,Long>();
4718
        for (Map.Entry<String, Long> other_element : other.availability.entrySet()) {
4719
 
4720
          String other_element_key = other_element.getKey();
4721
          Long other_element_value = other_element.getValue();
4722
 
4723
          String __this__availability_copy_key = other_element_key;
4724
 
4725
          Long __this__availability_copy_value = other_element_value;
4726
 
4727
          __this__availability.put(__this__availability_copy_key, __this__availability_copy_value);
4728
        }
4729
        this.availability = __this__availability;
4730
      }
4731
    }
4732
 
4733
    public updateInventoryHistory_args deepCopy() {
4734
      return new updateInventoryHistory_args(this);
4735
    }
4736
 
4737
    @Override
4738
    public void clear() {
4739
      setWarehouse_idIsSet(false);
4740
      this.warehouse_id = 0;
4741
      this.timestamp = null;
4742
      this.availability = null;
4743
    }
4744
 
4745
    public long getWarehouse_id() {
4746
      return this.warehouse_id;
4747
    }
4748
 
4749
    public void setWarehouse_id(long warehouse_id) {
4750
      this.warehouse_id = warehouse_id;
4751
      setWarehouse_idIsSet(true);
4752
    }
4753
 
4754
    public void unsetWarehouse_id() {
4755
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
4756
    }
4757
 
4758
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
4759
    public boolean isSetWarehouse_id() {
4760
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
4761
    }
4762
 
4763
    public void setWarehouse_idIsSet(boolean value) {
4764
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
4765
    }
4766
 
4767
    public String getTimestamp() {
4768
      return this.timestamp;
4769
    }
4770
 
4771
    public void setTimestamp(String timestamp) {
4772
      this.timestamp = timestamp;
4773
    }
4774
 
4775
    public void unsetTimestamp() {
4776
      this.timestamp = null;
4777
    }
4778
 
4779
    /** Returns true if field timestamp is set (has been assigned a value) and false otherwise */
4780
    public boolean isSetTimestamp() {
4781
      return this.timestamp != null;
4782
    }
4783
 
4784
    public void setTimestampIsSet(boolean value) {
4785
      if (!value) {
4786
        this.timestamp = null;
4787
      }
4788
    }
4789
 
4790
    public int getAvailabilitySize() {
4791
      return (this.availability == null) ? 0 : this.availability.size();
4792
    }
4793
 
4794
    public void putToAvailability(String key, long val) {
4795
      if (this.availability == null) {
4796
        this.availability = new HashMap<String,Long>();
4797
      }
4798
      this.availability.put(key, val);
4799
    }
4800
 
4801
    public Map<String,Long> getAvailability() {
4802
      return this.availability;
4803
    }
4804
 
4805
    public void setAvailability(Map<String,Long> availability) {
4806
      this.availability = availability;
4807
    }
4808
 
4809
    public void unsetAvailability() {
4810
      this.availability = null;
4811
    }
4812
 
4813
    /** Returns true if field availability is set (has been assigned a value) and false otherwise */
4814
    public boolean isSetAvailability() {
4815
      return this.availability != null;
4816
    }
4817
 
4818
    public void setAvailabilityIsSet(boolean value) {
4819
      if (!value) {
4820
        this.availability = null;
4821
      }
4822
    }
4823
 
4824
    public void setFieldValue(_Fields field, Object value) {
4825
      switch (field) {
4826
      case WAREHOUSE_ID:
4827
        if (value == null) {
4828
          unsetWarehouse_id();
4829
        } else {
4830
          setWarehouse_id((Long)value);
4831
        }
4832
        break;
4833
 
4834
      case TIMESTAMP:
4835
        if (value == null) {
4836
          unsetTimestamp();
4837
        } else {
4838
          setTimestamp((String)value);
4839
        }
4840
        break;
4841
 
4842
      case AVAILABILITY:
4843
        if (value == null) {
4844
          unsetAvailability();
4845
        } else {
4846
          setAvailability((Map<String,Long>)value);
4847
        }
4848
        break;
4849
 
4850
      }
4851
    }
4852
 
4853
    public Object getFieldValue(_Fields field) {
4854
      switch (field) {
4855
      case WAREHOUSE_ID:
4856
        return Long.valueOf(getWarehouse_id());
4857
 
4858
      case TIMESTAMP:
4859
        return getTimestamp();
4860
 
4861
      case AVAILABILITY:
4862
        return getAvailability();
4863
 
4864
      }
4865
      throw new IllegalStateException();
4866
    }
4867
 
4868
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4869
    public boolean isSet(_Fields field) {
4870
      if (field == null) {
4871
        throw new IllegalArgumentException();
4872
      }
4873
 
4874
      switch (field) {
4875
      case WAREHOUSE_ID:
4876
        return isSetWarehouse_id();
4877
      case TIMESTAMP:
4878
        return isSetTimestamp();
4879
      case AVAILABILITY:
4880
        return isSetAvailability();
4881
      }
4882
      throw new IllegalStateException();
4883
    }
4884
 
4885
    @Override
4886
    public boolean equals(Object that) {
4887
      if (that == null)
4888
        return false;
4889
      if (that instanceof updateInventoryHistory_args)
4890
        return this.equals((updateInventoryHistory_args)that);
4891
      return false;
4892
    }
4893
 
4894
    public boolean equals(updateInventoryHistory_args that) {
4895
      if (that == null)
4896
        return false;
4897
 
4898
      boolean this_present_warehouse_id = true;
4899
      boolean that_present_warehouse_id = true;
4900
      if (this_present_warehouse_id || that_present_warehouse_id) {
4901
        if (!(this_present_warehouse_id && that_present_warehouse_id))
4902
          return false;
4903
        if (this.warehouse_id != that.warehouse_id)
4904
          return false;
4905
      }
4906
 
4907
      boolean this_present_timestamp = true && this.isSetTimestamp();
4908
      boolean that_present_timestamp = true && that.isSetTimestamp();
4909
      if (this_present_timestamp || that_present_timestamp) {
4910
        if (!(this_present_timestamp && that_present_timestamp))
4911
          return false;
4912
        if (!this.timestamp.equals(that.timestamp))
4913
          return false;
4914
      }
4915
 
4916
      boolean this_present_availability = true && this.isSetAvailability();
4917
      boolean that_present_availability = true && that.isSetAvailability();
4918
      if (this_present_availability || that_present_availability) {
4919
        if (!(this_present_availability && that_present_availability))
4920
          return false;
4921
        if (!this.availability.equals(that.availability))
4922
          return false;
4923
      }
4924
 
4925
      return true;
4926
    }
4927
 
4928
    @Override
4929
    public int hashCode() {
4930
      return 0;
4931
    }
4932
 
4933
    public int compareTo(updateInventoryHistory_args other) {
4934
      if (!getClass().equals(other.getClass())) {
4935
        return getClass().getName().compareTo(other.getClass().getName());
4936
      }
4937
 
4938
      int lastComparison = 0;
4939
      updateInventoryHistory_args typedOther = (updateInventoryHistory_args)other;
4940
 
4941
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
4942
      if (lastComparison != 0) {
4943
        return lastComparison;
4944
      }
4945
      if (isSetWarehouse_id()) {
4946
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
4947
        if (lastComparison != 0) {
4948
          return lastComparison;
4949
        }
4950
      }
4951
      lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(typedOther.isSetTimestamp());
4952
      if (lastComparison != 0) {
4953
        return lastComparison;
4954
      }
4955
      if (isSetTimestamp()) {
4956
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.timestamp, typedOther.timestamp);
4957
        if (lastComparison != 0) {
4958
          return lastComparison;
4959
        }
4960
      }
4961
      lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(typedOther.isSetAvailability());
4962
      if (lastComparison != 0) {
4963
        return lastComparison;
4964
      }
4965
      if (isSetAvailability()) {
4966
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.availability, typedOther.availability);
4967
        if (lastComparison != 0) {
4968
          return lastComparison;
4969
        }
4970
      }
4971
      return 0;
4972
    }
4973
 
4974
    public _Fields fieldForId(int fieldId) {
4975
      return _Fields.findByThriftId(fieldId);
4976
    }
4977
 
4978
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4979
      org.apache.thrift.protocol.TField field;
4980
      iprot.readStructBegin();
4981
      while (true)
4982
      {
4983
        field = iprot.readFieldBegin();
4984
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4985
          break;
4986
        }
4987
        switch (field.id) {
4988
          case 1: // WAREHOUSE_ID
4989
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4990
              this.warehouse_id = iprot.readI64();
4991
              setWarehouse_idIsSet(true);
4992
            } else { 
4993
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4994
            }
4995
            break;
4996
          case 2: // TIMESTAMP
4997
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
4998
              this.timestamp = iprot.readString();
4999
            } else { 
5000
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5001
            }
5002
            break;
5003
          case 3: // AVAILABILITY
5004
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
5005
              {
5006
                org.apache.thrift.protocol.TMap _map10 = iprot.readMapBegin();
5007
                this.availability = new HashMap<String,Long>(2*_map10.size);
5008
                for (int _i11 = 0; _i11 < _map10.size; ++_i11)
5009
                {
5010
                  String _key12; // required
5011
                  long _val13; // required
5012
                  _key12 = iprot.readString();
5013
                  _val13 = iprot.readI64();
5014
                  this.availability.put(_key12, _val13);
5015
                }
5016
                iprot.readMapEnd();
5017
              }
5018
            } else { 
5019
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5020
            }
5021
            break;
5022
          default:
5023
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5024
        }
5025
        iprot.readFieldEnd();
5026
      }
5027
      iprot.readStructEnd();
5028
      validate();
5029
    }
5030
 
5031
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5032
      validate();
5033
 
5034
      oprot.writeStructBegin(STRUCT_DESC);
5035
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
5036
      oprot.writeI64(this.warehouse_id);
5037
      oprot.writeFieldEnd();
5038
      if (this.timestamp != null) {
5039
        oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
5040
        oprot.writeString(this.timestamp);
5041
        oprot.writeFieldEnd();
5042
      }
5043
      if (this.availability != null) {
5044
        oprot.writeFieldBegin(AVAILABILITY_FIELD_DESC);
5045
        {
5046
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.I64, this.availability.size()));
5047
          for (Map.Entry<String, Long> _iter14 : this.availability.entrySet())
5048
          {
5049
            oprot.writeString(_iter14.getKey());
5050
            oprot.writeI64(_iter14.getValue());
5051
          }
5052
          oprot.writeMapEnd();
5053
        }
5054
        oprot.writeFieldEnd();
5055
      }
5056
      oprot.writeFieldStop();
5057
      oprot.writeStructEnd();
5058
    }
5059
 
5060
    @Override
5061
    public String toString() {
5062
      StringBuilder sb = new StringBuilder("updateInventoryHistory_args(");
5063
      boolean first = true;
5064
 
5065
      sb.append("warehouse_id:");
5066
      sb.append(this.warehouse_id);
5067
      first = false;
5068
      if (!first) sb.append(", ");
5069
      sb.append("timestamp:");
5070
      if (this.timestamp == null) {
5071
        sb.append("null");
5072
      } else {
5073
        sb.append(this.timestamp);
5074
      }
5075
      first = false;
5076
      if (!first) sb.append(", ");
5077
      sb.append("availability:");
5078
      if (this.availability == null) {
5079
        sb.append("null");
5080
      } else {
5081
        sb.append(this.availability);
5082
      }
5083
      first = false;
5084
      sb.append(")");
5085
      return sb.toString();
5086
    }
5087
 
5088
    public void validate() throws org.apache.thrift.TException {
5089
      // check for required fields
5090
    }
5091
 
5092
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5093
      try {
5094
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5095
      } catch (org.apache.thrift.TException te) {
5096
        throw new java.io.IOException(te);
5097
      }
5098
    }
5099
 
5100
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5101
      try {
5102
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
5103
        __isset_bit_vector = new BitSet(1);
5104
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5105
      } catch (org.apache.thrift.TException te) {
5106
        throw new java.io.IOException(te);
5107
      }
5108
    }
5109
 
5110
  }
5111
 
5112
  public static class updateInventoryHistory_result implements org.apache.thrift.TBase<updateInventoryHistory_result, updateInventoryHistory_result._Fields>, java.io.Serializable, Cloneable   {
5113
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventoryHistory_result");
5114
 
5115
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
5116
 
5117
    private InventoryServiceException cex; // required
5118
 
5119
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5120
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5121
      CEX((short)1, "cex");
5122
 
5123
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5124
 
5125
      static {
5126
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5127
          byName.put(field.getFieldName(), field);
5128
        }
5129
      }
5130
 
5131
      /**
5132
       * Find the _Fields constant that matches fieldId, or null if its not found.
5133
       */
5134
      public static _Fields findByThriftId(int fieldId) {
5135
        switch(fieldId) {
5136
          case 1: // CEX
5137
            return CEX;
5138
          default:
5139
            return null;
5140
        }
5141
      }
5142
 
5143
      /**
5144
       * Find the _Fields constant that matches fieldId, throwing an exception
5145
       * if it is not found.
5146
       */
5147
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5148
        _Fields fields = findByThriftId(fieldId);
5149
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5150
        return fields;
5151
      }
5152
 
5153
      /**
5154
       * Find the _Fields constant that matches name, or null if its not found.
5155
       */
5156
      public static _Fields findByName(String name) {
5157
        return byName.get(name);
5158
      }
5159
 
5160
      private final short _thriftId;
5161
      private final String _fieldName;
5162
 
5163
      _Fields(short thriftId, String fieldName) {
5164
        _thriftId = thriftId;
5165
        _fieldName = fieldName;
5166
      }
5167
 
5168
      public short getThriftFieldId() {
5169
        return _thriftId;
5170
      }
5171
 
5172
      public String getFieldName() {
5173
        return _fieldName;
5174
      }
5175
    }
5176
 
5177
    // isset id assignments
5178
 
5179
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5180
    static {
5181
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5182
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5183
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5184
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5185
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventoryHistory_result.class, metaDataMap);
5186
    }
5187
 
5188
    public updateInventoryHistory_result() {
5189
    }
5190
 
5191
    public updateInventoryHistory_result(
5192
      InventoryServiceException cex)
5193
    {
5194
      this();
5195
      this.cex = cex;
5196
    }
5197
 
5198
    /**
5199
     * Performs a deep copy on <i>other</i>.
5200
     */
5201
    public updateInventoryHistory_result(updateInventoryHistory_result other) {
5202
      if (other.isSetCex()) {
5203
        this.cex = new InventoryServiceException(other.cex);
5204
      }
5205
    }
5206
 
5207
    public updateInventoryHistory_result deepCopy() {
5208
      return new updateInventoryHistory_result(this);
5209
    }
5210
 
5211
    @Override
5212
    public void clear() {
5213
      this.cex = null;
5214
    }
5215
 
5216
    public InventoryServiceException getCex() {
5217
      return this.cex;
5218
    }
5219
 
5220
    public void setCex(InventoryServiceException cex) {
5221
      this.cex = cex;
5222
    }
5223
 
5224
    public void unsetCex() {
5225
      this.cex = null;
5226
    }
5227
 
5228
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
5229
    public boolean isSetCex() {
5230
      return this.cex != null;
5231
    }
5232
 
5233
    public void setCexIsSet(boolean value) {
5234
      if (!value) {
5235
        this.cex = null;
5236
      }
5237
    }
5238
 
5239
    public void setFieldValue(_Fields field, Object value) {
5240
      switch (field) {
5241
      case CEX:
5242
        if (value == null) {
5243
          unsetCex();
5244
        } else {
5245
          setCex((InventoryServiceException)value);
5246
        }
5247
        break;
5248
 
5249
      }
5250
    }
5251
 
5252
    public Object getFieldValue(_Fields field) {
5253
      switch (field) {
5254
      case CEX:
5255
        return getCex();
5256
 
5257
      }
5258
      throw new IllegalStateException();
5259
    }
5260
 
5261
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5262
    public boolean isSet(_Fields field) {
5263
      if (field == null) {
5264
        throw new IllegalArgumentException();
5265
      }
5266
 
5267
      switch (field) {
5268
      case CEX:
5269
        return isSetCex();
5270
      }
5271
      throw new IllegalStateException();
5272
    }
5273
 
5274
    @Override
5275
    public boolean equals(Object that) {
5276
      if (that == null)
5277
        return false;
5278
      if (that instanceof updateInventoryHistory_result)
5279
        return this.equals((updateInventoryHistory_result)that);
5280
      return false;
5281
    }
5282
 
5283
    public boolean equals(updateInventoryHistory_result that) {
5284
      if (that == null)
5285
        return false;
5286
 
5287
      boolean this_present_cex = true && this.isSetCex();
5288
      boolean that_present_cex = true && that.isSetCex();
5289
      if (this_present_cex || that_present_cex) {
5290
        if (!(this_present_cex && that_present_cex))
5291
          return false;
5292
        if (!this.cex.equals(that.cex))
5293
          return false;
5294
      }
5295
 
5296
      return true;
5297
    }
5298
 
5299
    @Override
5300
    public int hashCode() {
5301
      return 0;
5302
    }
5303
 
5304
    public int compareTo(updateInventoryHistory_result other) {
5305
      if (!getClass().equals(other.getClass())) {
5306
        return getClass().getName().compareTo(other.getClass().getName());
5307
      }
5308
 
5309
      int lastComparison = 0;
5310
      updateInventoryHistory_result typedOther = (updateInventoryHistory_result)other;
5311
 
5312
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
5313
      if (lastComparison != 0) {
5314
        return lastComparison;
5315
      }
5316
      if (isSetCex()) {
5317
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
5318
        if (lastComparison != 0) {
5319
          return lastComparison;
5320
        }
5321
      }
5322
      return 0;
5323
    }
5324
 
5325
    public _Fields fieldForId(int fieldId) {
5326
      return _Fields.findByThriftId(fieldId);
5327
    }
5328
 
5329
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5330
      org.apache.thrift.protocol.TField field;
5331
      iprot.readStructBegin();
5332
      while (true)
5333
      {
5334
        field = iprot.readFieldBegin();
5335
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5336
          break;
5337
        }
5338
        switch (field.id) {
5339
          case 1: // CEX
5340
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5341
              this.cex = new InventoryServiceException();
5342
              this.cex.read(iprot);
5343
            } else { 
5344
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5345
            }
5346
            break;
5347
          default:
5348
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5349
        }
5350
        iprot.readFieldEnd();
5351
      }
5352
      iprot.readStructEnd();
5353
      validate();
5354
    }
5355
 
5356
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5357
      oprot.writeStructBegin(STRUCT_DESC);
5358
 
5359
      if (this.isSetCex()) {
5360
        oprot.writeFieldBegin(CEX_FIELD_DESC);
5361
        this.cex.write(oprot);
5362
        oprot.writeFieldEnd();
5363
      }
5364
      oprot.writeFieldStop();
5365
      oprot.writeStructEnd();
5366
    }
5367
 
5368
    @Override
5369
    public String toString() {
5370
      StringBuilder sb = new StringBuilder("updateInventoryHistory_result(");
5371
      boolean first = true;
5372
 
5373
      sb.append("cex:");
5374
      if (this.cex == null) {
5375
        sb.append("null");
5376
      } else {
5377
        sb.append(this.cex);
5378
      }
5379
      first = false;
5380
      sb.append(")");
5381
      return sb.toString();
5382
    }
5383
 
5384
    public void validate() throws org.apache.thrift.TException {
5385
      // check for required fields
5386
    }
5387
 
5388
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5389
      try {
5390
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5391
      } catch (org.apache.thrift.TException te) {
5392
        throw new java.io.IOException(te);
5393
      }
5394
    }
5395
 
5396
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5397
      try {
5398
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5399
      } catch (org.apache.thrift.TException te) {
5400
        throw new java.io.IOException(te);
5401
      }
5402
    }
5403
 
5404
  }
5405
 
5406
  public static class updateInventory_args implements org.apache.thrift.TBase<updateInventory_args, updateInventory_args._Fields>, java.io.Serializable, Cloneable   {
5407
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventory_args");
5408
 
5409
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouse_id", org.apache.thrift.protocol.TType.I64, (short)1);
5410
    private static final org.apache.thrift.protocol.TField TIMESTAMP_FIELD_DESC = new org.apache.thrift.protocol.TField("timestamp", org.apache.thrift.protocol.TType.STRING, (short)2);
5411
    private static final org.apache.thrift.protocol.TField AVAILABILITY_FIELD_DESC = new org.apache.thrift.protocol.TField("availability", org.apache.thrift.protocol.TType.MAP, (short)3);
5412
 
5413
    private long warehouse_id; // required
5414
    private String timestamp; // required
5415
    private Map<String,Long> availability; // required
5416
 
5417
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5418
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5419
      WAREHOUSE_ID((short)1, "warehouse_id"),
5420
      TIMESTAMP((short)2, "timestamp"),
5421
      AVAILABILITY((short)3, "availability");
5422
 
5423
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5424
 
5425
      static {
5426
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5427
          byName.put(field.getFieldName(), field);
5428
        }
5429
      }
5430
 
5431
      /**
5432
       * Find the _Fields constant that matches fieldId, or null if its not found.
5433
       */
5434
      public static _Fields findByThriftId(int fieldId) {
5435
        switch(fieldId) {
5436
          case 1: // WAREHOUSE_ID
5437
            return WAREHOUSE_ID;
5438
          case 2: // TIMESTAMP
5439
            return TIMESTAMP;
5440
          case 3: // AVAILABILITY
5441
            return AVAILABILITY;
5442
          default:
5443
            return null;
5444
        }
5445
      }
5446
 
5447
      /**
5448
       * Find the _Fields constant that matches fieldId, throwing an exception
5449
       * if it is not found.
5450
       */
5451
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5452
        _Fields fields = findByThriftId(fieldId);
5453
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5454
        return fields;
5455
      }
5456
 
5457
      /**
5458
       * Find the _Fields constant that matches name, or null if its not found.
5459
       */
5460
      public static _Fields findByName(String name) {
5461
        return byName.get(name);
5462
      }
5463
 
5464
      private final short _thriftId;
5465
      private final String _fieldName;
5466
 
5467
      _Fields(short thriftId, String fieldName) {
5468
        _thriftId = thriftId;
5469
        _fieldName = fieldName;
5470
      }
5471
 
5472
      public short getThriftFieldId() {
5473
        return _thriftId;
5474
      }
5475
 
5476
      public String getFieldName() {
5477
        return _fieldName;
5478
      }
5479
    }
5480
 
5481
    // isset id assignments
5482
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
5483
    private BitSet __isset_bit_vector = new BitSet(1);
5484
 
5485
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5486
    static {
5487
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5488
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5489
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5490
      tmpMap.put(_Fields.TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("timestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5491
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
5492
      tmpMap.put(_Fields.AVAILABILITY, new org.apache.thrift.meta_data.FieldMetaData("availability", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5493
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
5494
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
5495
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
5496
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5497
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventory_args.class, metaDataMap);
5498
    }
5499
 
5500
    public updateInventory_args() {
5501
    }
5502
 
5503
    public updateInventory_args(
5504
      long warehouse_id,
5505
      String timestamp,
5506
      Map<String,Long> availability)
5507
    {
5508
      this();
5509
      this.warehouse_id = warehouse_id;
5510
      setWarehouse_idIsSet(true);
5511
      this.timestamp = timestamp;
5512
      this.availability = availability;
5513
    }
5514
 
5515
    /**
5516
     * Performs a deep copy on <i>other</i>.
5517
     */
5518
    public updateInventory_args(updateInventory_args other) {
5519
      __isset_bit_vector.clear();
5520
      __isset_bit_vector.or(other.__isset_bit_vector);
5521
      this.warehouse_id = other.warehouse_id;
5522
      if (other.isSetTimestamp()) {
5523
        this.timestamp = other.timestamp;
5524
      }
5525
      if (other.isSetAvailability()) {
5526
        Map<String,Long> __this__availability = new HashMap<String,Long>();
5527
        for (Map.Entry<String, Long> other_element : other.availability.entrySet()) {
5528
 
5529
          String other_element_key = other_element.getKey();
5530
          Long other_element_value = other_element.getValue();
5531
 
5532
          String __this__availability_copy_key = other_element_key;
5533
 
5534
          Long __this__availability_copy_value = other_element_value;
5535
 
5536
          __this__availability.put(__this__availability_copy_key, __this__availability_copy_value);
5537
        }
5538
        this.availability = __this__availability;
5539
      }
5540
    }
5541
 
5542
    public updateInventory_args deepCopy() {
5543
      return new updateInventory_args(this);
5544
    }
5545
 
5546
    @Override
5547
    public void clear() {
5548
      setWarehouse_idIsSet(false);
5549
      this.warehouse_id = 0;
5550
      this.timestamp = null;
5551
      this.availability = null;
5552
    }
5553
 
5554
    public long getWarehouse_id() {
5555
      return this.warehouse_id;
5556
    }
5557
 
5558
    public void setWarehouse_id(long warehouse_id) {
5559
      this.warehouse_id = warehouse_id;
5560
      setWarehouse_idIsSet(true);
5561
    }
5562
 
5563
    public void unsetWarehouse_id() {
5564
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
5565
    }
5566
 
5567
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
5568
    public boolean isSetWarehouse_id() {
5569
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
5570
    }
5571
 
5572
    public void setWarehouse_idIsSet(boolean value) {
5573
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
5574
    }
5575
 
5576
    public String getTimestamp() {
5577
      return this.timestamp;
5578
    }
5579
 
5580
    public void setTimestamp(String timestamp) {
5581
      this.timestamp = timestamp;
5582
    }
5583
 
5584
    public void unsetTimestamp() {
5585
      this.timestamp = null;
5586
    }
5587
 
5588
    /** Returns true if field timestamp is set (has been assigned a value) and false otherwise */
5589
    public boolean isSetTimestamp() {
5590
      return this.timestamp != null;
5591
    }
5592
 
5593
    public void setTimestampIsSet(boolean value) {
5594
      if (!value) {
5595
        this.timestamp = null;
5596
      }
5597
    }
5598
 
5599
    public int getAvailabilitySize() {
5600
      return (this.availability == null) ? 0 : this.availability.size();
5601
    }
5602
 
5603
    public void putToAvailability(String key, long val) {
5604
      if (this.availability == null) {
5605
        this.availability = new HashMap<String,Long>();
5606
      }
5607
      this.availability.put(key, val);
5608
    }
5609
 
5610
    public Map<String,Long> getAvailability() {
5611
      return this.availability;
5612
    }
5613
 
5614
    public void setAvailability(Map<String,Long> availability) {
5615
      this.availability = availability;
5616
    }
5617
 
5618
    public void unsetAvailability() {
5619
      this.availability = null;
5620
    }
5621
 
5622
    /** Returns true if field availability is set (has been assigned a value) and false otherwise */
5623
    public boolean isSetAvailability() {
5624
      return this.availability != null;
5625
    }
5626
 
5627
    public void setAvailabilityIsSet(boolean value) {
5628
      if (!value) {
5629
        this.availability = null;
5630
      }
5631
    }
5632
 
5633
    public void setFieldValue(_Fields field, Object value) {
5634
      switch (field) {
5635
      case WAREHOUSE_ID:
5636
        if (value == null) {
5637
          unsetWarehouse_id();
5638
        } else {
5639
          setWarehouse_id((Long)value);
5640
        }
5641
        break;
5642
 
5643
      case TIMESTAMP:
5644
        if (value == null) {
5645
          unsetTimestamp();
5646
        } else {
5647
          setTimestamp((String)value);
5648
        }
5649
        break;
5650
 
5651
      case AVAILABILITY:
5652
        if (value == null) {
5653
          unsetAvailability();
5654
        } else {
5655
          setAvailability((Map<String,Long>)value);
5656
        }
5657
        break;
5658
 
5659
      }
5660
    }
5661
 
5662
    public Object getFieldValue(_Fields field) {
5663
      switch (field) {
5664
      case WAREHOUSE_ID:
5665
        return Long.valueOf(getWarehouse_id());
5666
 
5667
      case TIMESTAMP:
5668
        return getTimestamp();
5669
 
5670
      case AVAILABILITY:
5671
        return getAvailability();
5672
 
5673
      }
5674
      throw new IllegalStateException();
5675
    }
5676
 
5677
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5678
    public boolean isSet(_Fields field) {
5679
      if (field == null) {
5680
        throw new IllegalArgumentException();
5681
      }
5682
 
5683
      switch (field) {
5684
      case WAREHOUSE_ID:
5685
        return isSetWarehouse_id();
5686
      case TIMESTAMP:
5687
        return isSetTimestamp();
5688
      case AVAILABILITY:
5689
        return isSetAvailability();
5690
      }
5691
      throw new IllegalStateException();
5692
    }
5693
 
5694
    @Override
5695
    public boolean equals(Object that) {
5696
      if (that == null)
5697
        return false;
5698
      if (that instanceof updateInventory_args)
5699
        return this.equals((updateInventory_args)that);
5700
      return false;
5701
    }
5702
 
5703
    public boolean equals(updateInventory_args that) {
5704
      if (that == null)
5705
        return false;
5706
 
5707
      boolean this_present_warehouse_id = true;
5708
      boolean that_present_warehouse_id = true;
5709
      if (this_present_warehouse_id || that_present_warehouse_id) {
5710
        if (!(this_present_warehouse_id && that_present_warehouse_id))
5711
          return false;
5712
        if (this.warehouse_id != that.warehouse_id)
5713
          return false;
5714
      }
5715
 
5716
      boolean this_present_timestamp = true && this.isSetTimestamp();
5717
      boolean that_present_timestamp = true && that.isSetTimestamp();
5718
      if (this_present_timestamp || that_present_timestamp) {
5719
        if (!(this_present_timestamp && that_present_timestamp))
5720
          return false;
5721
        if (!this.timestamp.equals(that.timestamp))
5722
          return false;
5723
      }
5724
 
5725
      boolean this_present_availability = true && this.isSetAvailability();
5726
      boolean that_present_availability = true && that.isSetAvailability();
5727
      if (this_present_availability || that_present_availability) {
5728
        if (!(this_present_availability && that_present_availability))
5729
          return false;
5730
        if (!this.availability.equals(that.availability))
5731
          return false;
5732
      }
5733
 
5734
      return true;
5735
    }
5736
 
5737
    @Override
5738
    public int hashCode() {
5739
      return 0;
5740
    }
5741
 
5742
    public int compareTo(updateInventory_args other) {
5743
      if (!getClass().equals(other.getClass())) {
5744
        return getClass().getName().compareTo(other.getClass().getName());
5745
      }
5746
 
5747
      int lastComparison = 0;
5748
      updateInventory_args typedOther = (updateInventory_args)other;
5749
 
5750
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
5751
      if (lastComparison != 0) {
5752
        return lastComparison;
5753
      }
5754
      if (isSetWarehouse_id()) {
5755
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
5756
        if (lastComparison != 0) {
5757
          return lastComparison;
5758
        }
5759
      }
5760
      lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(typedOther.isSetTimestamp());
5761
      if (lastComparison != 0) {
5762
        return lastComparison;
5763
      }
5764
      if (isSetTimestamp()) {
5765
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.timestamp, typedOther.timestamp);
5766
        if (lastComparison != 0) {
5767
          return lastComparison;
5768
        }
5769
      }
5770
      lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(typedOther.isSetAvailability());
5771
      if (lastComparison != 0) {
5772
        return lastComparison;
5773
      }
5774
      if (isSetAvailability()) {
5775
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.availability, typedOther.availability);
5776
        if (lastComparison != 0) {
5777
          return lastComparison;
5778
        }
5779
      }
5780
      return 0;
5781
    }
5782
 
5783
    public _Fields fieldForId(int fieldId) {
5784
      return _Fields.findByThriftId(fieldId);
5785
    }
5786
 
5787
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5788
      org.apache.thrift.protocol.TField field;
5789
      iprot.readStructBegin();
5790
      while (true)
5791
      {
5792
        field = iprot.readFieldBegin();
5793
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5794
          break;
5795
        }
5796
        switch (field.id) {
5797
          case 1: // WAREHOUSE_ID
5798
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5799
              this.warehouse_id = iprot.readI64();
5800
              setWarehouse_idIsSet(true);
5801
            } else { 
5802
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5803
            }
5804
            break;
5805
          case 2: // TIMESTAMP
5806
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
5807
              this.timestamp = iprot.readString();
5808
            } else { 
5809
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5810
            }
5811
            break;
5812
          case 3: // AVAILABILITY
5813
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
5814
              {
5815
                org.apache.thrift.protocol.TMap _map15 = iprot.readMapBegin();
5816
                this.availability = new HashMap<String,Long>(2*_map15.size);
5817
                for (int _i16 = 0; _i16 < _map15.size; ++_i16)
5818
                {
5819
                  String _key17; // required
5820
                  long _val18; // required
5821
                  _key17 = iprot.readString();
5822
                  _val18 = iprot.readI64();
5823
                  this.availability.put(_key17, _val18);
5824
                }
5825
                iprot.readMapEnd();
5826
              }
5827
            } else { 
5828
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5829
            }
5830
            break;
5831
          default:
5832
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5833
        }
5834
        iprot.readFieldEnd();
5835
      }
5836
      iprot.readStructEnd();
5837
      validate();
5838
    }
5839
 
5840
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5841
      validate();
5842
 
5843
      oprot.writeStructBegin(STRUCT_DESC);
5844
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
5845
      oprot.writeI64(this.warehouse_id);
5846
      oprot.writeFieldEnd();
5847
      if (this.timestamp != null) {
5848
        oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
5849
        oprot.writeString(this.timestamp);
5850
        oprot.writeFieldEnd();
5851
      }
5852
      if (this.availability != null) {
5853
        oprot.writeFieldBegin(AVAILABILITY_FIELD_DESC);
5854
        {
5855
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.I64, this.availability.size()));
5856
          for (Map.Entry<String, Long> _iter19 : this.availability.entrySet())
5857
          {
5858
            oprot.writeString(_iter19.getKey());
5859
            oprot.writeI64(_iter19.getValue());
5860
          }
5861
          oprot.writeMapEnd();
5862
        }
5863
        oprot.writeFieldEnd();
5864
      }
5865
      oprot.writeFieldStop();
5866
      oprot.writeStructEnd();
5867
    }
5868
 
5869
    @Override
5870
    public String toString() {
5871
      StringBuilder sb = new StringBuilder("updateInventory_args(");
5872
      boolean first = true;
5873
 
5874
      sb.append("warehouse_id:");
5875
      sb.append(this.warehouse_id);
5876
      first = false;
5877
      if (!first) sb.append(", ");
5878
      sb.append("timestamp:");
5879
      if (this.timestamp == null) {
5880
        sb.append("null");
5881
      } else {
5882
        sb.append(this.timestamp);
5883
      }
5884
      first = false;
5885
      if (!first) sb.append(", ");
5886
      sb.append("availability:");
5887
      if (this.availability == null) {
5888
        sb.append("null");
5889
      } else {
5890
        sb.append(this.availability);
5891
      }
5892
      first = false;
5893
      sb.append(")");
5894
      return sb.toString();
5895
    }
5896
 
5897
    public void validate() throws org.apache.thrift.TException {
5898
      // check for required fields
5899
    }
5900
 
5901
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5902
      try {
5903
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5904
      } catch (org.apache.thrift.TException te) {
5905
        throw new java.io.IOException(te);
5906
      }
5907
    }
5908
 
5909
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5910
      try {
5911
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
5912
        __isset_bit_vector = new BitSet(1);
5913
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5914
      } catch (org.apache.thrift.TException te) {
5915
        throw new java.io.IOException(te);
5916
      }
5917
    }
5918
 
5919
  }
5920
 
5921
  public static class updateInventory_result implements org.apache.thrift.TBase<updateInventory_result, updateInventory_result._Fields>, java.io.Serializable, Cloneable   {
5922
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventory_result");
5923
 
5924
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
5925
 
5926
    private InventoryServiceException cex; // required
5927
 
5928
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5929
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5930
      CEX((short)1, "cex");
5931
 
5932
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5933
 
5934
      static {
5935
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5936
          byName.put(field.getFieldName(), field);
5937
        }
5938
      }
5939
 
5940
      /**
5941
       * Find the _Fields constant that matches fieldId, or null if its not found.
5942
       */
5943
      public static _Fields findByThriftId(int fieldId) {
5944
        switch(fieldId) {
5945
          case 1: // CEX
5946
            return CEX;
5947
          default:
5948
            return null;
5949
        }
5950
      }
5951
 
5952
      /**
5953
       * Find the _Fields constant that matches fieldId, throwing an exception
5954
       * if it is not found.
5955
       */
5956
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5957
        _Fields fields = findByThriftId(fieldId);
5958
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5959
        return fields;
5960
      }
5961
 
5962
      /**
5963
       * Find the _Fields constant that matches name, or null if its not found.
5964
       */
5965
      public static _Fields findByName(String name) {
5966
        return byName.get(name);
5967
      }
5968
 
5969
      private final short _thriftId;
5970
      private final String _fieldName;
5971
 
5972
      _Fields(short thriftId, String fieldName) {
5973
        _thriftId = thriftId;
5974
        _fieldName = fieldName;
5975
      }
5976
 
5977
      public short getThriftFieldId() {
5978
        return _thriftId;
5979
      }
5980
 
5981
      public String getFieldName() {
5982
        return _fieldName;
5983
      }
5984
    }
5985
 
5986
    // isset id assignments
5987
 
5988
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5989
    static {
5990
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5991
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5992
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5993
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5994
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventory_result.class, metaDataMap);
5995
    }
5996
 
5997
    public updateInventory_result() {
5998
    }
5999
 
6000
    public updateInventory_result(
6001
      InventoryServiceException cex)
6002
    {
6003
      this();
6004
      this.cex = cex;
6005
    }
6006
 
6007
    /**
6008
     * Performs a deep copy on <i>other</i>.
6009
     */
6010
    public updateInventory_result(updateInventory_result other) {
6011
      if (other.isSetCex()) {
6012
        this.cex = new InventoryServiceException(other.cex);
6013
      }
6014
    }
6015
 
6016
    public updateInventory_result deepCopy() {
6017
      return new updateInventory_result(this);
6018
    }
6019
 
6020
    @Override
6021
    public void clear() {
6022
      this.cex = null;
6023
    }
6024
 
6025
    public InventoryServiceException getCex() {
6026
      return this.cex;
6027
    }
6028
 
6029
    public void setCex(InventoryServiceException cex) {
6030
      this.cex = cex;
6031
    }
6032
 
6033
    public void unsetCex() {
6034
      this.cex = null;
6035
    }
6036
 
6037
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
6038
    public boolean isSetCex() {
6039
      return this.cex != null;
6040
    }
6041
 
6042
    public void setCexIsSet(boolean value) {
6043
      if (!value) {
6044
        this.cex = null;
6045
      }
6046
    }
6047
 
6048
    public void setFieldValue(_Fields field, Object value) {
6049
      switch (field) {
6050
      case CEX:
6051
        if (value == null) {
6052
          unsetCex();
6053
        } else {
6054
          setCex((InventoryServiceException)value);
6055
        }
6056
        break;
6057
 
6058
      }
6059
    }
6060
 
6061
    public Object getFieldValue(_Fields field) {
6062
      switch (field) {
6063
      case CEX:
6064
        return getCex();
6065
 
6066
      }
6067
      throw new IllegalStateException();
6068
    }
6069
 
6070
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6071
    public boolean isSet(_Fields field) {
6072
      if (field == null) {
6073
        throw new IllegalArgumentException();
6074
      }
6075
 
6076
      switch (field) {
6077
      case CEX:
6078
        return isSetCex();
6079
      }
6080
      throw new IllegalStateException();
6081
    }
6082
 
6083
    @Override
6084
    public boolean equals(Object that) {
6085
      if (that == null)
6086
        return false;
6087
      if (that instanceof updateInventory_result)
6088
        return this.equals((updateInventory_result)that);
6089
      return false;
6090
    }
6091
 
6092
    public boolean equals(updateInventory_result that) {
6093
      if (that == null)
6094
        return false;
6095
 
6096
      boolean this_present_cex = true && this.isSetCex();
6097
      boolean that_present_cex = true && that.isSetCex();
6098
      if (this_present_cex || that_present_cex) {
6099
        if (!(this_present_cex && that_present_cex))
6100
          return false;
6101
        if (!this.cex.equals(that.cex))
6102
          return false;
6103
      }
6104
 
6105
      return true;
6106
    }
6107
 
6108
    @Override
6109
    public int hashCode() {
6110
      return 0;
6111
    }
6112
 
6113
    public int compareTo(updateInventory_result other) {
6114
      if (!getClass().equals(other.getClass())) {
6115
        return getClass().getName().compareTo(other.getClass().getName());
6116
      }
6117
 
6118
      int lastComparison = 0;
6119
      updateInventory_result typedOther = (updateInventory_result)other;
6120
 
6121
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
6122
      if (lastComparison != 0) {
6123
        return lastComparison;
6124
      }
6125
      if (isSetCex()) {
6126
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
6127
        if (lastComparison != 0) {
6128
          return lastComparison;
6129
        }
6130
      }
6131
      return 0;
6132
    }
6133
 
6134
    public _Fields fieldForId(int fieldId) {
6135
      return _Fields.findByThriftId(fieldId);
6136
    }
6137
 
6138
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6139
      org.apache.thrift.protocol.TField field;
6140
      iprot.readStructBegin();
6141
      while (true)
6142
      {
6143
        field = iprot.readFieldBegin();
6144
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6145
          break;
6146
        }
6147
        switch (field.id) {
6148
          case 1: // CEX
6149
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6150
              this.cex = new InventoryServiceException();
6151
              this.cex.read(iprot);
6152
            } else { 
6153
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6154
            }
6155
            break;
6156
          default:
6157
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6158
        }
6159
        iprot.readFieldEnd();
6160
      }
6161
      iprot.readStructEnd();
6162
      validate();
6163
    }
6164
 
6165
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6166
      oprot.writeStructBegin(STRUCT_DESC);
6167
 
6168
      if (this.isSetCex()) {
6169
        oprot.writeFieldBegin(CEX_FIELD_DESC);
6170
        this.cex.write(oprot);
6171
        oprot.writeFieldEnd();
6172
      }
6173
      oprot.writeFieldStop();
6174
      oprot.writeStructEnd();
6175
    }
6176
 
6177
    @Override
6178
    public String toString() {
6179
      StringBuilder sb = new StringBuilder("updateInventory_result(");
6180
      boolean first = true;
6181
 
6182
      sb.append("cex:");
6183
      if (this.cex == null) {
6184
        sb.append("null");
6185
      } else {
6186
        sb.append(this.cex);
6187
      }
6188
      first = false;
6189
      sb.append(")");
6190
      return sb.toString();
6191
    }
6192
 
6193
    public void validate() throws org.apache.thrift.TException {
6194
      // check for required fields
6195
    }
6196
 
6197
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6198
      try {
6199
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6200
      } catch (org.apache.thrift.TException te) {
6201
        throw new java.io.IOException(te);
6202
      }
6203
    }
6204
 
6205
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6206
      try {
6207
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6208
      } catch (org.apache.thrift.TException te) {
6209
        throw new java.io.IOException(te);
6210
      }
6211
    }
6212
 
6213
  }
6214
 
6215
  public static class addInventory_args implements org.apache.thrift.TBase<addInventory_args, addInventory_args._Fields>, java.io.Serializable, Cloneable   {
6216
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addInventory_args");
6217
 
6218
    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);
6219
    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)2);
6220
    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);
6221
 
6222
    private long itemId; // required
6223
    private long warehouseId; // required
6224
    private long quantity; // required
6225
 
6226
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6227
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6228
      ITEM_ID((short)1, "itemId"),
6229
      WAREHOUSE_ID((short)2, "warehouseId"),
6230
      QUANTITY((short)3, "quantity");
6231
 
6232
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6233
 
6234
      static {
6235
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6236
          byName.put(field.getFieldName(), field);
6237
        }
6238
      }
6239
 
6240
      /**
6241
       * Find the _Fields constant that matches fieldId, or null if its not found.
6242
       */
6243
      public static _Fields findByThriftId(int fieldId) {
6244
        switch(fieldId) {
6245
          case 1: // ITEM_ID
6246
            return ITEM_ID;
6247
          case 2: // WAREHOUSE_ID
6248
            return WAREHOUSE_ID;
6249
          case 3: // QUANTITY
6250
            return QUANTITY;
6251
          default:
6252
            return null;
6253
        }
6254
      }
6255
 
6256
      /**
6257
       * Find the _Fields constant that matches fieldId, throwing an exception
6258
       * if it is not found.
6259
       */
6260
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6261
        _Fields fields = findByThriftId(fieldId);
6262
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6263
        return fields;
6264
      }
6265
 
6266
      /**
6267
       * Find the _Fields constant that matches name, or null if its not found.
6268
       */
6269
      public static _Fields findByName(String name) {
6270
        return byName.get(name);
6271
      }
6272
 
6273
      private final short _thriftId;
6274
      private final String _fieldName;
6275
 
6276
      _Fields(short thriftId, String fieldName) {
6277
        _thriftId = thriftId;
6278
        _fieldName = fieldName;
6279
      }
6280
 
6281
      public short getThriftFieldId() {
6282
        return _thriftId;
6283
      }
6284
 
6285
      public String getFieldName() {
6286
        return _fieldName;
6287
      }
6288
    }
6289
 
6290
    // isset id assignments
6291
    private static final int __ITEMID_ISSET_ID = 0;
6292
    private static final int __WAREHOUSEID_ISSET_ID = 1;
6293
    private static final int __QUANTITY_ISSET_ID = 2;
6294
    private BitSet __isset_bit_vector = new BitSet(3);
6295
 
6296
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6297
    static {
6298
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6299
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6300
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6301
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6302
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6303
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6304
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6305
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6306
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addInventory_args.class, metaDataMap);
6307
    }
6308
 
6309
    public addInventory_args() {
6310
    }
6311
 
6312
    public addInventory_args(
6313
      long itemId,
6314
      long warehouseId,
6315
      long quantity)
6316
    {
6317
      this();
6318
      this.itemId = itemId;
6319
      setItemIdIsSet(true);
6320
      this.warehouseId = warehouseId;
6321
      setWarehouseIdIsSet(true);
6322
      this.quantity = quantity;
6323
      setQuantityIsSet(true);
6324
    }
6325
 
6326
    /**
6327
     * Performs a deep copy on <i>other</i>.
6328
     */
6329
    public addInventory_args(addInventory_args other) {
6330
      __isset_bit_vector.clear();
6331
      __isset_bit_vector.or(other.__isset_bit_vector);
6332
      this.itemId = other.itemId;
6333
      this.warehouseId = other.warehouseId;
6334
      this.quantity = other.quantity;
6335
    }
6336
 
6337
    public addInventory_args deepCopy() {
6338
      return new addInventory_args(this);
6339
    }
6340
 
6341
    @Override
6342
    public void clear() {
6343
      setItemIdIsSet(false);
6344
      this.itemId = 0;
6345
      setWarehouseIdIsSet(false);
6346
      this.warehouseId = 0;
6347
      setQuantityIsSet(false);
6348
      this.quantity = 0;
6349
    }
6350
 
6351
    public long getItemId() {
6352
      return this.itemId;
6353
    }
6354
 
6355
    public void setItemId(long itemId) {
6356
      this.itemId = itemId;
6357
      setItemIdIsSet(true);
6358
    }
6359
 
6360
    public void unsetItemId() {
6361
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
6362
    }
6363
 
6364
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
6365
    public boolean isSetItemId() {
6366
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
6367
    }
6368
 
6369
    public void setItemIdIsSet(boolean value) {
6370
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
6371
    }
6372
 
6373
    public long getWarehouseId() {
6374
      return this.warehouseId;
6375
    }
6376
 
6377
    public void setWarehouseId(long warehouseId) {
6378
      this.warehouseId = warehouseId;
6379
      setWarehouseIdIsSet(true);
6380
    }
6381
 
6382
    public void unsetWarehouseId() {
6383
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
6384
    }
6385
 
6386
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
6387
    public boolean isSetWarehouseId() {
6388
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
6389
    }
6390
 
6391
    public void setWarehouseIdIsSet(boolean value) {
6392
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
6393
    }
6394
 
6395
    public long getQuantity() {
6396
      return this.quantity;
6397
    }
6398
 
6399
    public void setQuantity(long quantity) {
6400
      this.quantity = quantity;
6401
      setQuantityIsSet(true);
6402
    }
6403
 
6404
    public void unsetQuantity() {
6405
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
6406
    }
6407
 
6408
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
6409
    public boolean isSetQuantity() {
6410
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
6411
    }
6412
 
6413
    public void setQuantityIsSet(boolean value) {
6414
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
6415
    }
6416
 
6417
    public void setFieldValue(_Fields field, Object value) {
6418
      switch (field) {
6419
      case ITEM_ID:
6420
        if (value == null) {
6421
          unsetItemId();
6422
        } else {
6423
          setItemId((Long)value);
6424
        }
6425
        break;
6426
 
6427
      case WAREHOUSE_ID:
6428
        if (value == null) {
6429
          unsetWarehouseId();
6430
        } else {
6431
          setWarehouseId((Long)value);
6432
        }
6433
        break;
6434
 
6435
      case QUANTITY:
6436
        if (value == null) {
6437
          unsetQuantity();
6438
        } else {
6439
          setQuantity((Long)value);
6440
        }
6441
        break;
6442
 
6443
      }
6444
    }
6445
 
6446
    public Object getFieldValue(_Fields field) {
6447
      switch (field) {
6448
      case ITEM_ID:
6449
        return Long.valueOf(getItemId());
6450
 
6451
      case WAREHOUSE_ID:
6452
        return Long.valueOf(getWarehouseId());
6453
 
6454
      case QUANTITY:
6455
        return Long.valueOf(getQuantity());
6456
 
6457
      }
6458
      throw new IllegalStateException();
6459
    }
6460
 
6461
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6462
    public boolean isSet(_Fields field) {
6463
      if (field == null) {
6464
        throw new IllegalArgumentException();
6465
      }
6466
 
6467
      switch (field) {
6468
      case ITEM_ID:
6469
        return isSetItemId();
6470
      case WAREHOUSE_ID:
6471
        return isSetWarehouseId();
6472
      case QUANTITY:
6473
        return isSetQuantity();
6474
      }
6475
      throw new IllegalStateException();
6476
    }
6477
 
6478
    @Override
6479
    public boolean equals(Object that) {
6480
      if (that == null)
6481
        return false;
6482
      if (that instanceof addInventory_args)
6483
        return this.equals((addInventory_args)that);
6484
      return false;
6485
    }
6486
 
6487
    public boolean equals(addInventory_args that) {
6488
      if (that == null)
6489
        return false;
6490
 
6491
      boolean this_present_itemId = true;
6492
      boolean that_present_itemId = true;
6493
      if (this_present_itemId || that_present_itemId) {
6494
        if (!(this_present_itemId && that_present_itemId))
6495
          return false;
6496
        if (this.itemId != that.itemId)
6497
          return false;
6498
      }
6499
 
6500
      boolean this_present_warehouseId = true;
6501
      boolean that_present_warehouseId = true;
6502
      if (this_present_warehouseId || that_present_warehouseId) {
6503
        if (!(this_present_warehouseId && that_present_warehouseId))
6504
          return false;
6505
        if (this.warehouseId != that.warehouseId)
6506
          return false;
6507
      }
6508
 
6509
      boolean this_present_quantity = true;
6510
      boolean that_present_quantity = true;
6511
      if (this_present_quantity || that_present_quantity) {
6512
        if (!(this_present_quantity && that_present_quantity))
6513
          return false;
6514
        if (this.quantity != that.quantity)
6515
          return false;
6516
      }
6517
 
6518
      return true;
6519
    }
6520
 
6521
    @Override
6522
    public int hashCode() {
6523
      return 0;
6524
    }
6525
 
6526
    public int compareTo(addInventory_args other) {
6527
      if (!getClass().equals(other.getClass())) {
6528
        return getClass().getName().compareTo(other.getClass().getName());
6529
      }
6530
 
6531
      int lastComparison = 0;
6532
      addInventory_args typedOther = (addInventory_args)other;
6533
 
6534
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
6535
      if (lastComparison != 0) {
6536
        return lastComparison;
6537
      }
6538
      if (isSetItemId()) {
6539
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
6540
        if (lastComparison != 0) {
6541
          return lastComparison;
6542
        }
6543
      }
6544
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
6545
      if (lastComparison != 0) {
6546
        return lastComparison;
6547
      }
6548
      if (isSetWarehouseId()) {
6549
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
6550
        if (lastComparison != 0) {
6551
          return lastComparison;
6552
        }
6553
      }
6554
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
6555
      if (lastComparison != 0) {
6556
        return lastComparison;
6557
      }
6558
      if (isSetQuantity()) {
6559
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
6560
        if (lastComparison != 0) {
6561
          return lastComparison;
6562
        }
6563
      }
6564
      return 0;
6565
    }
6566
 
6567
    public _Fields fieldForId(int fieldId) {
6568
      return _Fields.findByThriftId(fieldId);
6569
    }
6570
 
6571
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6572
      org.apache.thrift.protocol.TField field;
6573
      iprot.readStructBegin();
6574
      while (true)
6575
      {
6576
        field = iprot.readFieldBegin();
6577
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6578
          break;
6579
        }
6580
        switch (field.id) {
6581
          case 1: // ITEM_ID
6582
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6583
              this.itemId = iprot.readI64();
6584
              setItemIdIsSet(true);
6585
            } else { 
6586
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6587
            }
6588
            break;
6589
          case 2: // WAREHOUSE_ID
6590
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6591
              this.warehouseId = iprot.readI64();
6592
              setWarehouseIdIsSet(true);
6593
            } else { 
6594
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6595
            }
6596
            break;
6597
          case 3: // QUANTITY
6598
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6599
              this.quantity = iprot.readI64();
6600
              setQuantityIsSet(true);
6601
            } else { 
6602
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6603
            }
6604
            break;
6605
          default:
6606
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6607
        }
6608
        iprot.readFieldEnd();
6609
      }
6610
      iprot.readStructEnd();
6611
      validate();
6612
    }
6613
 
6614
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6615
      validate();
6616
 
6617
      oprot.writeStructBegin(STRUCT_DESC);
6618
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
6619
      oprot.writeI64(this.itemId);
6620
      oprot.writeFieldEnd();
6621
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
6622
      oprot.writeI64(this.warehouseId);
6623
      oprot.writeFieldEnd();
6624
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
6625
      oprot.writeI64(this.quantity);
6626
      oprot.writeFieldEnd();
6627
      oprot.writeFieldStop();
6628
      oprot.writeStructEnd();
6629
    }
6630
 
6631
    @Override
6632
    public String toString() {
6633
      StringBuilder sb = new StringBuilder("addInventory_args(");
6634
      boolean first = true;
6635
 
6636
      sb.append("itemId:");
6637
      sb.append(this.itemId);
6638
      first = false;
6639
      if (!first) sb.append(", ");
6640
      sb.append("warehouseId:");
6641
      sb.append(this.warehouseId);
6642
      first = false;
6643
      if (!first) sb.append(", ");
6644
      sb.append("quantity:");
6645
      sb.append(this.quantity);
6646
      first = false;
6647
      sb.append(")");
6648
      return sb.toString();
6649
    }
6650
 
6651
    public void validate() throws org.apache.thrift.TException {
6652
      // check for required fields
6653
    }
6654
 
6655
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6656
      try {
6657
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6658
      } catch (org.apache.thrift.TException te) {
6659
        throw new java.io.IOException(te);
6660
      }
6661
    }
6662
 
6663
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6664
      try {
6665
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
6666
        __isset_bit_vector = new BitSet(1);
6667
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6668
      } catch (org.apache.thrift.TException te) {
6669
        throw new java.io.IOException(te);
6670
      }
6671
    }
6672
 
6673
  }
6674
 
6675
  public static class addInventory_result implements org.apache.thrift.TBase<addInventory_result, addInventory_result._Fields>, java.io.Serializable, Cloneable   {
6676
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addInventory_result");
6677
 
6678
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
6679
 
6680
    private InventoryServiceException cex; // required
6681
 
6682
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6683
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6684
      CEX((short)1, "cex");
6685
 
6686
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6687
 
6688
      static {
6689
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6690
          byName.put(field.getFieldName(), field);
6691
        }
6692
      }
6693
 
6694
      /**
6695
       * Find the _Fields constant that matches fieldId, or null if its not found.
6696
       */
6697
      public static _Fields findByThriftId(int fieldId) {
6698
        switch(fieldId) {
6699
          case 1: // CEX
6700
            return CEX;
6701
          default:
6702
            return null;
6703
        }
6704
      }
6705
 
6706
      /**
6707
       * Find the _Fields constant that matches fieldId, throwing an exception
6708
       * if it is not found.
6709
       */
6710
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6711
        _Fields fields = findByThriftId(fieldId);
6712
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6713
        return fields;
6714
      }
6715
 
6716
      /**
6717
       * Find the _Fields constant that matches name, or null if its not found.
6718
       */
6719
      public static _Fields findByName(String name) {
6720
        return byName.get(name);
6721
      }
6722
 
6723
      private final short _thriftId;
6724
      private final String _fieldName;
6725
 
6726
      _Fields(short thriftId, String fieldName) {
6727
        _thriftId = thriftId;
6728
        _fieldName = fieldName;
6729
      }
6730
 
6731
      public short getThriftFieldId() {
6732
        return _thriftId;
6733
      }
6734
 
6735
      public String getFieldName() {
6736
        return _fieldName;
6737
      }
6738
    }
6739
 
6740
    // isset id assignments
6741
 
6742
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6743
    static {
6744
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6745
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6746
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6747
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6748
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addInventory_result.class, metaDataMap);
6749
    }
6750
 
6751
    public addInventory_result() {
6752
    }
6753
 
6754
    public addInventory_result(
6755
      InventoryServiceException cex)
6756
    {
6757
      this();
6758
      this.cex = cex;
6759
    }
6760
 
6761
    /**
6762
     * Performs a deep copy on <i>other</i>.
6763
     */
6764
    public addInventory_result(addInventory_result other) {
6765
      if (other.isSetCex()) {
6766
        this.cex = new InventoryServiceException(other.cex);
6767
      }
6768
    }
6769
 
6770
    public addInventory_result deepCopy() {
6771
      return new addInventory_result(this);
6772
    }
6773
 
6774
    @Override
6775
    public void clear() {
6776
      this.cex = null;
6777
    }
6778
 
6779
    public InventoryServiceException getCex() {
6780
      return this.cex;
6781
    }
6782
 
6783
    public void setCex(InventoryServiceException cex) {
6784
      this.cex = cex;
6785
    }
6786
 
6787
    public void unsetCex() {
6788
      this.cex = null;
6789
    }
6790
 
6791
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
6792
    public boolean isSetCex() {
6793
      return this.cex != null;
6794
    }
6795
 
6796
    public void setCexIsSet(boolean value) {
6797
      if (!value) {
6798
        this.cex = null;
6799
      }
6800
    }
6801
 
6802
    public void setFieldValue(_Fields field, Object value) {
6803
      switch (field) {
6804
      case CEX:
6805
        if (value == null) {
6806
          unsetCex();
6807
        } else {
6808
          setCex((InventoryServiceException)value);
6809
        }
6810
        break;
6811
 
6812
      }
6813
    }
6814
 
6815
    public Object getFieldValue(_Fields field) {
6816
      switch (field) {
6817
      case CEX:
6818
        return getCex();
6819
 
6820
      }
6821
      throw new IllegalStateException();
6822
    }
6823
 
6824
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6825
    public boolean isSet(_Fields field) {
6826
      if (field == null) {
6827
        throw new IllegalArgumentException();
6828
      }
6829
 
6830
      switch (field) {
6831
      case CEX:
6832
        return isSetCex();
6833
      }
6834
      throw new IllegalStateException();
6835
    }
6836
 
6837
    @Override
6838
    public boolean equals(Object that) {
6839
      if (that == null)
6840
        return false;
6841
      if (that instanceof addInventory_result)
6842
        return this.equals((addInventory_result)that);
6843
      return false;
6844
    }
6845
 
6846
    public boolean equals(addInventory_result that) {
6847
      if (that == null)
6848
        return false;
6849
 
6850
      boolean this_present_cex = true && this.isSetCex();
6851
      boolean that_present_cex = true && that.isSetCex();
6852
      if (this_present_cex || that_present_cex) {
6853
        if (!(this_present_cex && that_present_cex))
6854
          return false;
6855
        if (!this.cex.equals(that.cex))
6856
          return false;
6857
      }
6858
 
6859
      return true;
6860
    }
6861
 
6862
    @Override
6863
    public int hashCode() {
6864
      return 0;
6865
    }
6866
 
6867
    public int compareTo(addInventory_result other) {
6868
      if (!getClass().equals(other.getClass())) {
6869
        return getClass().getName().compareTo(other.getClass().getName());
6870
      }
6871
 
6872
      int lastComparison = 0;
6873
      addInventory_result typedOther = (addInventory_result)other;
6874
 
6875
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
6876
      if (lastComparison != 0) {
6877
        return lastComparison;
6878
      }
6879
      if (isSetCex()) {
6880
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
6881
        if (lastComparison != 0) {
6882
          return lastComparison;
6883
        }
6884
      }
6885
      return 0;
6886
    }
6887
 
6888
    public _Fields fieldForId(int fieldId) {
6889
      return _Fields.findByThriftId(fieldId);
6890
    }
6891
 
6892
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6893
      org.apache.thrift.protocol.TField field;
6894
      iprot.readStructBegin();
6895
      while (true)
6896
      {
6897
        field = iprot.readFieldBegin();
6898
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6899
          break;
6900
        }
6901
        switch (field.id) {
6902
          case 1: // CEX
6903
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6904
              this.cex = new InventoryServiceException();
6905
              this.cex.read(iprot);
6906
            } else { 
6907
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6908
            }
6909
            break;
6910
          default:
6911
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6912
        }
6913
        iprot.readFieldEnd();
6914
      }
6915
      iprot.readStructEnd();
6916
      validate();
6917
    }
6918
 
6919
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6920
      oprot.writeStructBegin(STRUCT_DESC);
6921
 
6922
      if (this.isSetCex()) {
6923
        oprot.writeFieldBegin(CEX_FIELD_DESC);
6924
        this.cex.write(oprot);
6925
        oprot.writeFieldEnd();
6926
      }
6927
      oprot.writeFieldStop();
6928
      oprot.writeStructEnd();
6929
    }
6930
 
6931
    @Override
6932
    public String toString() {
6933
      StringBuilder sb = new StringBuilder("addInventory_result(");
6934
      boolean first = true;
6935
 
6936
      sb.append("cex:");
6937
      if (this.cex == null) {
6938
        sb.append("null");
6939
      } else {
6940
        sb.append(this.cex);
6941
      }
6942
      first = false;
6943
      sb.append(")");
6944
      return sb.toString();
6945
    }
6946
 
6947
    public void validate() throws org.apache.thrift.TException {
6948
      // check for required fields
6949
    }
6950
 
6951
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6952
      try {
6953
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6954
      } catch (org.apache.thrift.TException te) {
6955
        throw new java.io.IOException(te);
6956
      }
6957
    }
6958
 
6959
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6960
      try {
6961
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6962
      } catch (org.apache.thrift.TException te) {
6963
        throw new java.io.IOException(te);
6964
      }
6965
    }
6966
 
6967
  }
6968
 
6969
  public static class retireWarehouse_args implements org.apache.thrift.TBase<retireWarehouse_args, retireWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
6970
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("retireWarehouse_args");
6971
 
6972
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouse_id", org.apache.thrift.protocol.TType.I64, (short)1);
6973
 
6974
    private long warehouse_id; // required
6975
 
6976
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6977
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6978
      WAREHOUSE_ID((short)1, "warehouse_id");
6979
 
6980
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6981
 
6982
      static {
6983
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6984
          byName.put(field.getFieldName(), field);
6985
        }
6986
      }
6987
 
6988
      /**
6989
       * Find the _Fields constant that matches fieldId, or null if its not found.
6990
       */
6991
      public static _Fields findByThriftId(int fieldId) {
6992
        switch(fieldId) {
6993
          case 1: // WAREHOUSE_ID
6994
            return WAREHOUSE_ID;
6995
          default:
6996
            return null;
6997
        }
6998
      }
6999
 
7000
      /**
7001
       * Find the _Fields constant that matches fieldId, throwing an exception
7002
       * if it is not found.
7003
       */
7004
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7005
        _Fields fields = findByThriftId(fieldId);
7006
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7007
        return fields;
7008
      }
7009
 
7010
      /**
7011
       * Find the _Fields constant that matches name, or null if its not found.
7012
       */
7013
      public static _Fields findByName(String name) {
7014
        return byName.get(name);
7015
      }
7016
 
7017
      private final short _thriftId;
7018
      private final String _fieldName;
7019
 
7020
      _Fields(short thriftId, String fieldName) {
7021
        _thriftId = thriftId;
7022
        _fieldName = fieldName;
7023
      }
7024
 
7025
      public short getThriftFieldId() {
7026
        return _thriftId;
7027
      }
7028
 
7029
      public String getFieldName() {
7030
        return _fieldName;
7031
      }
7032
    }
7033
 
7034
    // isset id assignments
7035
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
7036
    private BitSet __isset_bit_vector = new BitSet(1);
7037
 
7038
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7039
    static {
7040
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7041
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7042
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7043
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7044
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(retireWarehouse_args.class, metaDataMap);
7045
    }
7046
 
7047
    public retireWarehouse_args() {
7048
    }
7049
 
7050
    public retireWarehouse_args(
7051
      long warehouse_id)
7052
    {
7053
      this();
7054
      this.warehouse_id = warehouse_id;
7055
      setWarehouse_idIsSet(true);
7056
    }
7057
 
7058
    /**
7059
     * Performs a deep copy on <i>other</i>.
7060
     */
7061
    public retireWarehouse_args(retireWarehouse_args other) {
7062
      __isset_bit_vector.clear();
7063
      __isset_bit_vector.or(other.__isset_bit_vector);
7064
      this.warehouse_id = other.warehouse_id;
7065
    }
7066
 
7067
    public retireWarehouse_args deepCopy() {
7068
      return new retireWarehouse_args(this);
7069
    }
7070
 
7071
    @Override
7072
    public void clear() {
7073
      setWarehouse_idIsSet(false);
7074
      this.warehouse_id = 0;
7075
    }
7076
 
7077
    public long getWarehouse_id() {
7078
      return this.warehouse_id;
7079
    }
7080
 
7081
    public void setWarehouse_id(long warehouse_id) {
7082
      this.warehouse_id = warehouse_id;
7083
      setWarehouse_idIsSet(true);
7084
    }
7085
 
7086
    public void unsetWarehouse_id() {
7087
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
7088
    }
7089
 
7090
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
7091
    public boolean isSetWarehouse_id() {
7092
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
7093
    }
7094
 
7095
    public void setWarehouse_idIsSet(boolean value) {
7096
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
7097
    }
7098
 
7099
    public void setFieldValue(_Fields field, Object value) {
7100
      switch (field) {
7101
      case WAREHOUSE_ID:
7102
        if (value == null) {
7103
          unsetWarehouse_id();
7104
        } else {
7105
          setWarehouse_id((Long)value);
7106
        }
7107
        break;
7108
 
7109
      }
7110
    }
7111
 
7112
    public Object getFieldValue(_Fields field) {
7113
      switch (field) {
7114
      case WAREHOUSE_ID:
7115
        return Long.valueOf(getWarehouse_id());
7116
 
7117
      }
7118
      throw new IllegalStateException();
7119
    }
7120
 
7121
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7122
    public boolean isSet(_Fields field) {
7123
      if (field == null) {
7124
        throw new IllegalArgumentException();
7125
      }
7126
 
7127
      switch (field) {
7128
      case WAREHOUSE_ID:
7129
        return isSetWarehouse_id();
7130
      }
7131
      throw new IllegalStateException();
7132
    }
7133
 
7134
    @Override
7135
    public boolean equals(Object that) {
7136
      if (that == null)
7137
        return false;
7138
      if (that instanceof retireWarehouse_args)
7139
        return this.equals((retireWarehouse_args)that);
7140
      return false;
7141
    }
7142
 
7143
    public boolean equals(retireWarehouse_args that) {
7144
      if (that == null)
7145
        return false;
7146
 
7147
      boolean this_present_warehouse_id = true;
7148
      boolean that_present_warehouse_id = true;
7149
      if (this_present_warehouse_id || that_present_warehouse_id) {
7150
        if (!(this_present_warehouse_id && that_present_warehouse_id))
7151
          return false;
7152
        if (this.warehouse_id != that.warehouse_id)
7153
          return false;
7154
      }
7155
 
7156
      return true;
7157
    }
7158
 
7159
    @Override
7160
    public int hashCode() {
7161
      return 0;
7162
    }
7163
 
7164
    public int compareTo(retireWarehouse_args other) {
7165
      if (!getClass().equals(other.getClass())) {
7166
        return getClass().getName().compareTo(other.getClass().getName());
7167
      }
7168
 
7169
      int lastComparison = 0;
7170
      retireWarehouse_args typedOther = (retireWarehouse_args)other;
7171
 
7172
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
7173
      if (lastComparison != 0) {
7174
        return lastComparison;
7175
      }
7176
      if (isSetWarehouse_id()) {
7177
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
7178
        if (lastComparison != 0) {
7179
          return lastComparison;
7180
        }
7181
      }
7182
      return 0;
7183
    }
7184
 
7185
    public _Fields fieldForId(int fieldId) {
7186
      return _Fields.findByThriftId(fieldId);
7187
    }
7188
 
7189
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7190
      org.apache.thrift.protocol.TField field;
7191
      iprot.readStructBegin();
7192
      while (true)
7193
      {
7194
        field = iprot.readFieldBegin();
7195
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7196
          break;
7197
        }
7198
        switch (field.id) {
7199
          case 1: // WAREHOUSE_ID
7200
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7201
              this.warehouse_id = iprot.readI64();
7202
              setWarehouse_idIsSet(true);
7203
            } else { 
7204
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7205
            }
7206
            break;
7207
          default:
7208
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7209
        }
7210
        iprot.readFieldEnd();
7211
      }
7212
      iprot.readStructEnd();
7213
      validate();
7214
    }
7215
 
7216
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7217
      validate();
7218
 
7219
      oprot.writeStructBegin(STRUCT_DESC);
7220
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
7221
      oprot.writeI64(this.warehouse_id);
7222
      oprot.writeFieldEnd();
7223
      oprot.writeFieldStop();
7224
      oprot.writeStructEnd();
7225
    }
7226
 
7227
    @Override
7228
    public String toString() {
7229
      StringBuilder sb = new StringBuilder("retireWarehouse_args(");
7230
      boolean first = true;
7231
 
7232
      sb.append("warehouse_id:");
7233
      sb.append(this.warehouse_id);
7234
      first = false;
7235
      sb.append(")");
7236
      return sb.toString();
7237
    }
7238
 
7239
    public void validate() throws org.apache.thrift.TException {
7240
      // check for required fields
7241
    }
7242
 
7243
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7244
      try {
7245
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7246
      } catch (org.apache.thrift.TException te) {
7247
        throw new java.io.IOException(te);
7248
      }
7249
    }
7250
 
7251
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7252
      try {
7253
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7254
        __isset_bit_vector = new BitSet(1);
7255
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7256
      } catch (org.apache.thrift.TException te) {
7257
        throw new java.io.IOException(te);
7258
      }
7259
    }
7260
 
7261
  }
7262
 
7263
  public static class retireWarehouse_result implements org.apache.thrift.TBase<retireWarehouse_result, retireWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
7264
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("retireWarehouse_result");
7265
 
7266
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
7267
 
7268
    private InventoryServiceException cex; // required
7269
 
7270
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7271
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7272
      CEX((short)1, "cex");
7273
 
7274
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7275
 
7276
      static {
7277
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7278
          byName.put(field.getFieldName(), field);
7279
        }
7280
      }
7281
 
7282
      /**
7283
       * Find the _Fields constant that matches fieldId, or null if its not found.
7284
       */
7285
      public static _Fields findByThriftId(int fieldId) {
7286
        switch(fieldId) {
7287
          case 1: // CEX
7288
            return CEX;
7289
          default:
7290
            return null;
7291
        }
7292
      }
7293
 
7294
      /**
7295
       * Find the _Fields constant that matches fieldId, throwing an exception
7296
       * if it is not found.
7297
       */
7298
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7299
        _Fields fields = findByThriftId(fieldId);
7300
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7301
        return fields;
7302
      }
7303
 
7304
      /**
7305
       * Find the _Fields constant that matches name, or null if its not found.
7306
       */
7307
      public static _Fields findByName(String name) {
7308
        return byName.get(name);
7309
      }
7310
 
7311
      private final short _thriftId;
7312
      private final String _fieldName;
7313
 
7314
      _Fields(short thriftId, String fieldName) {
7315
        _thriftId = thriftId;
7316
        _fieldName = fieldName;
7317
      }
7318
 
7319
      public short getThriftFieldId() {
7320
        return _thriftId;
7321
      }
7322
 
7323
      public String getFieldName() {
7324
        return _fieldName;
7325
      }
7326
    }
7327
 
7328
    // isset id assignments
7329
 
7330
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7331
    static {
7332
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7333
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7334
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7335
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7336
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(retireWarehouse_result.class, metaDataMap);
7337
    }
7338
 
7339
    public retireWarehouse_result() {
7340
    }
7341
 
7342
    public retireWarehouse_result(
7343
      InventoryServiceException cex)
7344
    {
7345
      this();
7346
      this.cex = cex;
7347
    }
7348
 
7349
    /**
7350
     * Performs a deep copy on <i>other</i>.
7351
     */
7352
    public retireWarehouse_result(retireWarehouse_result other) {
7353
      if (other.isSetCex()) {
7354
        this.cex = new InventoryServiceException(other.cex);
7355
      }
7356
    }
7357
 
7358
    public retireWarehouse_result deepCopy() {
7359
      return new retireWarehouse_result(this);
7360
    }
7361
 
7362
    @Override
7363
    public void clear() {
7364
      this.cex = null;
7365
    }
7366
 
7367
    public InventoryServiceException getCex() {
7368
      return this.cex;
7369
    }
7370
 
7371
    public void setCex(InventoryServiceException cex) {
7372
      this.cex = cex;
7373
    }
7374
 
7375
    public void unsetCex() {
7376
      this.cex = null;
7377
    }
7378
 
7379
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
7380
    public boolean isSetCex() {
7381
      return this.cex != null;
7382
    }
7383
 
7384
    public void setCexIsSet(boolean value) {
7385
      if (!value) {
7386
        this.cex = null;
7387
      }
7388
    }
7389
 
7390
    public void setFieldValue(_Fields field, Object value) {
7391
      switch (field) {
7392
      case CEX:
7393
        if (value == null) {
7394
          unsetCex();
7395
        } else {
7396
          setCex((InventoryServiceException)value);
7397
        }
7398
        break;
7399
 
7400
      }
7401
    }
7402
 
7403
    public Object getFieldValue(_Fields field) {
7404
      switch (field) {
7405
      case CEX:
7406
        return getCex();
7407
 
7408
      }
7409
      throw new IllegalStateException();
7410
    }
7411
 
7412
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7413
    public boolean isSet(_Fields field) {
7414
      if (field == null) {
7415
        throw new IllegalArgumentException();
7416
      }
7417
 
7418
      switch (field) {
7419
      case CEX:
7420
        return isSetCex();
7421
      }
7422
      throw new IllegalStateException();
7423
    }
7424
 
7425
    @Override
7426
    public boolean equals(Object that) {
7427
      if (that == null)
7428
        return false;
7429
      if (that instanceof retireWarehouse_result)
7430
        return this.equals((retireWarehouse_result)that);
7431
      return false;
7432
    }
7433
 
7434
    public boolean equals(retireWarehouse_result that) {
7435
      if (that == null)
7436
        return false;
7437
 
7438
      boolean this_present_cex = true && this.isSetCex();
7439
      boolean that_present_cex = true && that.isSetCex();
7440
      if (this_present_cex || that_present_cex) {
7441
        if (!(this_present_cex && that_present_cex))
7442
          return false;
7443
        if (!this.cex.equals(that.cex))
7444
          return false;
7445
      }
7446
 
7447
      return true;
7448
    }
7449
 
7450
    @Override
7451
    public int hashCode() {
7452
      return 0;
7453
    }
7454
 
7455
    public int compareTo(retireWarehouse_result other) {
7456
      if (!getClass().equals(other.getClass())) {
7457
        return getClass().getName().compareTo(other.getClass().getName());
7458
      }
7459
 
7460
      int lastComparison = 0;
7461
      retireWarehouse_result typedOther = (retireWarehouse_result)other;
7462
 
7463
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
7464
      if (lastComparison != 0) {
7465
        return lastComparison;
7466
      }
7467
      if (isSetCex()) {
7468
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
7469
        if (lastComparison != 0) {
7470
          return lastComparison;
7471
        }
7472
      }
7473
      return 0;
7474
    }
7475
 
7476
    public _Fields fieldForId(int fieldId) {
7477
      return _Fields.findByThriftId(fieldId);
7478
    }
7479
 
7480
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7481
      org.apache.thrift.protocol.TField field;
7482
      iprot.readStructBegin();
7483
      while (true)
7484
      {
7485
        field = iprot.readFieldBegin();
7486
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7487
          break;
7488
        }
7489
        switch (field.id) {
7490
          case 1: // CEX
7491
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7492
              this.cex = new InventoryServiceException();
7493
              this.cex.read(iprot);
7494
            } else { 
7495
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7496
            }
7497
            break;
7498
          default:
7499
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7500
        }
7501
        iprot.readFieldEnd();
7502
      }
7503
      iprot.readStructEnd();
7504
      validate();
7505
    }
7506
 
7507
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7508
      oprot.writeStructBegin(STRUCT_DESC);
7509
 
7510
      if (this.isSetCex()) {
7511
        oprot.writeFieldBegin(CEX_FIELD_DESC);
7512
        this.cex.write(oprot);
7513
        oprot.writeFieldEnd();
7514
      }
7515
      oprot.writeFieldStop();
7516
      oprot.writeStructEnd();
7517
    }
7518
 
7519
    @Override
7520
    public String toString() {
7521
      StringBuilder sb = new StringBuilder("retireWarehouse_result(");
7522
      boolean first = true;
7523
 
7524
      sb.append("cex:");
7525
      if (this.cex == null) {
7526
        sb.append("null");
7527
      } else {
7528
        sb.append(this.cex);
7529
      }
7530
      first = false;
7531
      sb.append(")");
7532
      return sb.toString();
7533
    }
7534
 
7535
    public void validate() throws org.apache.thrift.TException {
7536
      // check for required fields
7537
    }
7538
 
7539
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7540
      try {
7541
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7542
      } catch (org.apache.thrift.TException te) {
7543
        throw new java.io.IOException(te);
7544
      }
7545
    }
7546
 
7547
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7548
      try {
7549
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7550
      } catch (org.apache.thrift.TException te) {
7551
        throw new java.io.IOException(te);
7552
      }
7553
    }
7554
 
7555
  }
7556
 
7557
  public static class getItemInventoryByItemId_args implements org.apache.thrift.TBase<getItemInventoryByItemId_args, getItemInventoryByItemId_args._Fields>, java.io.Serializable, Cloneable   {
7558
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemInventoryByItemId_args");
7559
 
7560
    private static final org.apache.thrift.protocol.TField ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("item_id", org.apache.thrift.protocol.TType.I64, (short)1);
7561
 
7562
    private long item_id; // required
7563
 
7564
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7565
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7566
      ITEM_ID((short)1, "item_id");
7567
 
7568
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7569
 
7570
      static {
7571
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7572
          byName.put(field.getFieldName(), field);
7573
        }
7574
      }
7575
 
7576
      /**
7577
       * Find the _Fields constant that matches fieldId, or null if its not found.
7578
       */
7579
      public static _Fields findByThriftId(int fieldId) {
7580
        switch(fieldId) {
7581
          case 1: // ITEM_ID
7582
            return ITEM_ID;
7583
          default:
7584
            return null;
7585
        }
7586
      }
7587
 
7588
      /**
7589
       * Find the _Fields constant that matches fieldId, throwing an exception
7590
       * if it is not found.
7591
       */
7592
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7593
        _Fields fields = findByThriftId(fieldId);
7594
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7595
        return fields;
7596
      }
7597
 
7598
      /**
7599
       * Find the _Fields constant that matches name, or null if its not found.
7600
       */
7601
      public static _Fields findByName(String name) {
7602
        return byName.get(name);
7603
      }
7604
 
7605
      private final short _thriftId;
7606
      private final String _fieldName;
7607
 
7608
      _Fields(short thriftId, String fieldName) {
7609
        _thriftId = thriftId;
7610
        _fieldName = fieldName;
7611
      }
7612
 
7613
      public short getThriftFieldId() {
7614
        return _thriftId;
7615
      }
7616
 
7617
      public String getFieldName() {
7618
        return _fieldName;
7619
      }
7620
    }
7621
 
7622
    // isset id assignments
7623
    private static final int __ITEM_ID_ISSET_ID = 0;
7624
    private BitSet __isset_bit_vector = new BitSet(1);
7625
 
7626
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7627
    static {
7628
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7629
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7630
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7631
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7632
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemInventoryByItemId_args.class, metaDataMap);
7633
    }
7634
 
7635
    public getItemInventoryByItemId_args() {
7636
    }
7637
 
7638
    public getItemInventoryByItemId_args(
7639
      long item_id)
7640
    {
7641
      this();
7642
      this.item_id = item_id;
7643
      setItem_idIsSet(true);
7644
    }
7645
 
7646
    /**
7647
     * Performs a deep copy on <i>other</i>.
7648
     */
7649
    public getItemInventoryByItemId_args(getItemInventoryByItemId_args other) {
7650
      __isset_bit_vector.clear();
7651
      __isset_bit_vector.or(other.__isset_bit_vector);
7652
      this.item_id = other.item_id;
7653
    }
7654
 
7655
    public getItemInventoryByItemId_args deepCopy() {
7656
      return new getItemInventoryByItemId_args(this);
7657
    }
7658
 
7659
    @Override
7660
    public void clear() {
7661
      setItem_idIsSet(false);
7662
      this.item_id = 0;
7663
    }
7664
 
7665
    public long getItem_id() {
7666
      return this.item_id;
7667
    }
7668
 
7669
    public void setItem_id(long item_id) {
7670
      this.item_id = item_id;
7671
      setItem_idIsSet(true);
7672
    }
7673
 
7674
    public void unsetItem_id() {
7675
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
7676
    }
7677
 
7678
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
7679
    public boolean isSetItem_id() {
7680
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
7681
    }
7682
 
7683
    public void setItem_idIsSet(boolean value) {
7684
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
7685
    }
7686
 
7687
    public void setFieldValue(_Fields field, Object value) {
7688
      switch (field) {
7689
      case ITEM_ID:
7690
        if (value == null) {
7691
          unsetItem_id();
7692
        } else {
7693
          setItem_id((Long)value);
7694
        }
7695
        break;
7696
 
7697
      }
7698
    }
7699
 
7700
    public Object getFieldValue(_Fields field) {
7701
      switch (field) {
7702
      case ITEM_ID:
7703
        return Long.valueOf(getItem_id());
7704
 
7705
      }
7706
      throw new IllegalStateException();
7707
    }
7708
 
7709
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7710
    public boolean isSet(_Fields field) {
7711
      if (field == null) {
7712
        throw new IllegalArgumentException();
7713
      }
7714
 
7715
      switch (field) {
7716
      case ITEM_ID:
7717
        return isSetItem_id();
7718
      }
7719
      throw new IllegalStateException();
7720
    }
7721
 
7722
    @Override
7723
    public boolean equals(Object that) {
7724
      if (that == null)
7725
        return false;
7726
      if (that instanceof getItemInventoryByItemId_args)
7727
        return this.equals((getItemInventoryByItemId_args)that);
7728
      return false;
7729
    }
7730
 
7731
    public boolean equals(getItemInventoryByItemId_args that) {
7732
      if (that == null)
7733
        return false;
7734
 
7735
      boolean this_present_item_id = true;
7736
      boolean that_present_item_id = true;
7737
      if (this_present_item_id || that_present_item_id) {
7738
        if (!(this_present_item_id && that_present_item_id))
7739
          return false;
7740
        if (this.item_id != that.item_id)
7741
          return false;
7742
      }
7743
 
7744
      return true;
7745
    }
7746
 
7747
    @Override
7748
    public int hashCode() {
7749
      return 0;
7750
    }
7751
 
7752
    public int compareTo(getItemInventoryByItemId_args other) {
7753
      if (!getClass().equals(other.getClass())) {
7754
        return getClass().getName().compareTo(other.getClass().getName());
7755
      }
7756
 
7757
      int lastComparison = 0;
7758
      getItemInventoryByItemId_args typedOther = (getItemInventoryByItemId_args)other;
7759
 
7760
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
7761
      if (lastComparison != 0) {
7762
        return lastComparison;
7763
      }
7764
      if (isSetItem_id()) {
7765
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
7766
        if (lastComparison != 0) {
7767
          return lastComparison;
7768
        }
7769
      }
7770
      return 0;
7771
    }
7772
 
7773
    public _Fields fieldForId(int fieldId) {
7774
      return _Fields.findByThriftId(fieldId);
7775
    }
7776
 
7777
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7778
      org.apache.thrift.protocol.TField field;
7779
      iprot.readStructBegin();
7780
      while (true)
7781
      {
7782
        field = iprot.readFieldBegin();
7783
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7784
          break;
7785
        }
7786
        switch (field.id) {
7787
          case 1: // ITEM_ID
7788
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7789
              this.item_id = iprot.readI64();
7790
              setItem_idIsSet(true);
7791
            } else { 
7792
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7793
            }
7794
            break;
7795
          default:
7796
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7797
        }
7798
        iprot.readFieldEnd();
7799
      }
7800
      iprot.readStructEnd();
7801
      validate();
7802
    }
7803
 
7804
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7805
      validate();
7806
 
7807
      oprot.writeStructBegin(STRUCT_DESC);
7808
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
7809
      oprot.writeI64(this.item_id);
7810
      oprot.writeFieldEnd();
7811
      oprot.writeFieldStop();
7812
      oprot.writeStructEnd();
7813
    }
7814
 
7815
    @Override
7816
    public String toString() {
7817
      StringBuilder sb = new StringBuilder("getItemInventoryByItemId_args(");
7818
      boolean first = true;
7819
 
7820
      sb.append("item_id:");
7821
      sb.append(this.item_id);
7822
      first = false;
7823
      sb.append(")");
7824
      return sb.toString();
7825
    }
7826
 
7827
    public void validate() throws org.apache.thrift.TException {
7828
      // check for required fields
7829
    }
7830
 
7831
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7832
      try {
7833
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7834
      } catch (org.apache.thrift.TException te) {
7835
        throw new java.io.IOException(te);
7836
      }
7837
    }
7838
 
7839
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7840
      try {
7841
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7842
        __isset_bit_vector = new BitSet(1);
7843
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7844
      } catch (org.apache.thrift.TException te) {
7845
        throw new java.io.IOException(te);
7846
      }
7847
    }
7848
 
7849
  }
7850
 
7851
  public static class getItemInventoryByItemId_result implements org.apache.thrift.TBase<getItemInventoryByItemId_result, getItemInventoryByItemId_result._Fields>, java.io.Serializable, Cloneable   {
7852
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemInventoryByItemId_result");
7853
 
7854
    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);
7855
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
7856
 
7857
    private ItemInventory success; // required
7858
    private InventoryServiceException cex; // required
7859
 
7860
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7861
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7862
      SUCCESS((short)0, "success"),
7863
      CEX((short)1, "cex");
7864
 
7865
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7866
 
7867
      static {
7868
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7869
          byName.put(field.getFieldName(), field);
7870
        }
7871
      }
7872
 
7873
      /**
7874
       * Find the _Fields constant that matches fieldId, or null if its not found.
7875
       */
7876
      public static _Fields findByThriftId(int fieldId) {
7877
        switch(fieldId) {
7878
          case 0: // SUCCESS
7879
            return SUCCESS;
7880
          case 1: // CEX
7881
            return CEX;
7882
          default:
7883
            return null;
7884
        }
7885
      }
7886
 
7887
      /**
7888
       * Find the _Fields constant that matches fieldId, throwing an exception
7889
       * if it is not found.
7890
       */
7891
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7892
        _Fields fields = findByThriftId(fieldId);
7893
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7894
        return fields;
7895
      }
7896
 
7897
      /**
7898
       * Find the _Fields constant that matches name, or null if its not found.
7899
       */
7900
      public static _Fields findByName(String name) {
7901
        return byName.get(name);
7902
      }
7903
 
7904
      private final short _thriftId;
7905
      private final String _fieldName;
7906
 
7907
      _Fields(short thriftId, String fieldName) {
7908
        _thriftId = thriftId;
7909
        _fieldName = fieldName;
7910
      }
7911
 
7912
      public short getThriftFieldId() {
7913
        return _thriftId;
7914
      }
7915
 
7916
      public String getFieldName() {
7917
        return _fieldName;
7918
      }
7919
    }
7920
 
7921
    // isset id assignments
7922
 
7923
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7924
    static {
7925
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7926
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7927
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ItemInventory.class)));
7928
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7929
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7930
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7931
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemInventoryByItemId_result.class, metaDataMap);
7932
    }
7933
 
7934
    public getItemInventoryByItemId_result() {
7935
    }
7936
 
7937
    public getItemInventoryByItemId_result(
7938
      ItemInventory success,
7939
      InventoryServiceException cex)
7940
    {
7941
      this();
7942
      this.success = success;
7943
      this.cex = cex;
7944
    }
7945
 
7946
    /**
7947
     * Performs a deep copy on <i>other</i>.
7948
     */
7949
    public getItemInventoryByItemId_result(getItemInventoryByItemId_result other) {
7950
      if (other.isSetSuccess()) {
7951
        this.success = new ItemInventory(other.success);
7952
      }
7953
      if (other.isSetCex()) {
7954
        this.cex = new InventoryServiceException(other.cex);
7955
      }
7956
    }
7957
 
7958
    public getItemInventoryByItemId_result deepCopy() {
7959
      return new getItemInventoryByItemId_result(this);
7960
    }
7961
 
7962
    @Override
7963
    public void clear() {
7964
      this.success = null;
7965
      this.cex = null;
7966
    }
7967
 
7968
    public ItemInventory getSuccess() {
7969
      return this.success;
7970
    }
7971
 
7972
    public void setSuccess(ItemInventory success) {
7973
      this.success = success;
7974
    }
7975
 
7976
    public void unsetSuccess() {
7977
      this.success = null;
7978
    }
7979
 
7980
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
7981
    public boolean isSetSuccess() {
7982
      return this.success != null;
7983
    }
7984
 
7985
    public void setSuccessIsSet(boolean value) {
7986
      if (!value) {
7987
        this.success = null;
7988
      }
7989
    }
7990
 
7991
    public InventoryServiceException getCex() {
7992
      return this.cex;
7993
    }
7994
 
7995
    public void setCex(InventoryServiceException cex) {
7996
      this.cex = cex;
7997
    }
7998
 
7999
    public void unsetCex() {
8000
      this.cex = null;
8001
    }
8002
 
8003
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
8004
    public boolean isSetCex() {
8005
      return this.cex != null;
8006
    }
8007
 
8008
    public void setCexIsSet(boolean value) {
8009
      if (!value) {
8010
        this.cex = null;
8011
      }
8012
    }
8013
 
8014
    public void setFieldValue(_Fields field, Object value) {
8015
      switch (field) {
8016
      case SUCCESS:
8017
        if (value == null) {
8018
          unsetSuccess();
8019
        } else {
8020
          setSuccess((ItemInventory)value);
8021
        }
8022
        break;
8023
 
8024
      case CEX:
8025
        if (value == null) {
8026
          unsetCex();
8027
        } else {
8028
          setCex((InventoryServiceException)value);
8029
        }
8030
        break;
8031
 
8032
      }
8033
    }
8034
 
8035
    public Object getFieldValue(_Fields field) {
8036
      switch (field) {
8037
      case SUCCESS:
8038
        return getSuccess();
8039
 
8040
      case CEX:
8041
        return getCex();
8042
 
8043
      }
8044
      throw new IllegalStateException();
8045
    }
8046
 
8047
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8048
    public boolean isSet(_Fields field) {
8049
      if (field == null) {
8050
        throw new IllegalArgumentException();
8051
      }
8052
 
8053
      switch (field) {
8054
      case SUCCESS:
8055
        return isSetSuccess();
8056
      case CEX:
8057
        return isSetCex();
8058
      }
8059
      throw new IllegalStateException();
8060
    }
8061
 
8062
    @Override
8063
    public boolean equals(Object that) {
8064
      if (that == null)
8065
        return false;
8066
      if (that instanceof getItemInventoryByItemId_result)
8067
        return this.equals((getItemInventoryByItemId_result)that);
8068
      return false;
8069
    }
8070
 
8071
    public boolean equals(getItemInventoryByItemId_result that) {
8072
      if (that == null)
8073
        return false;
8074
 
8075
      boolean this_present_success = true && this.isSetSuccess();
8076
      boolean that_present_success = true && that.isSetSuccess();
8077
      if (this_present_success || that_present_success) {
8078
        if (!(this_present_success && that_present_success))
8079
          return false;
8080
        if (!this.success.equals(that.success))
8081
          return false;
8082
      }
8083
 
8084
      boolean this_present_cex = true && this.isSetCex();
8085
      boolean that_present_cex = true && that.isSetCex();
8086
      if (this_present_cex || that_present_cex) {
8087
        if (!(this_present_cex && that_present_cex))
8088
          return false;
8089
        if (!this.cex.equals(that.cex))
8090
          return false;
8091
      }
8092
 
8093
      return true;
8094
    }
8095
 
8096
    @Override
8097
    public int hashCode() {
8098
      return 0;
8099
    }
8100
 
8101
    public int compareTo(getItemInventoryByItemId_result other) {
8102
      if (!getClass().equals(other.getClass())) {
8103
        return getClass().getName().compareTo(other.getClass().getName());
8104
      }
8105
 
8106
      int lastComparison = 0;
8107
      getItemInventoryByItemId_result typedOther = (getItemInventoryByItemId_result)other;
8108
 
8109
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
8110
      if (lastComparison != 0) {
8111
        return lastComparison;
8112
      }
8113
      if (isSetSuccess()) {
8114
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8115
        if (lastComparison != 0) {
8116
          return lastComparison;
8117
        }
8118
      }
8119
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
8120
      if (lastComparison != 0) {
8121
        return lastComparison;
8122
      }
8123
      if (isSetCex()) {
8124
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
8125
        if (lastComparison != 0) {
8126
          return lastComparison;
8127
        }
8128
      }
8129
      return 0;
8130
    }
8131
 
8132
    public _Fields fieldForId(int fieldId) {
8133
      return _Fields.findByThriftId(fieldId);
8134
    }
8135
 
8136
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8137
      org.apache.thrift.protocol.TField field;
8138
      iprot.readStructBegin();
8139
      while (true)
8140
      {
8141
        field = iprot.readFieldBegin();
8142
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8143
          break;
8144
        }
8145
        switch (field.id) {
8146
          case 0: // SUCCESS
8147
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8148
              this.success = new ItemInventory();
8149
              this.success.read(iprot);
8150
            } else { 
8151
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8152
            }
8153
            break;
8154
          case 1: // CEX
8155
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8156
              this.cex = new InventoryServiceException();
8157
              this.cex.read(iprot);
8158
            } else { 
8159
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8160
            }
8161
            break;
8162
          default:
8163
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8164
        }
8165
        iprot.readFieldEnd();
8166
      }
8167
      iprot.readStructEnd();
8168
      validate();
8169
    }
8170
 
8171
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8172
      oprot.writeStructBegin(STRUCT_DESC);
8173
 
8174
      if (this.isSetSuccess()) {
8175
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8176
        this.success.write(oprot);
8177
        oprot.writeFieldEnd();
8178
      } else if (this.isSetCex()) {
8179
        oprot.writeFieldBegin(CEX_FIELD_DESC);
8180
        this.cex.write(oprot);
8181
        oprot.writeFieldEnd();
8182
      }
8183
      oprot.writeFieldStop();
8184
      oprot.writeStructEnd();
8185
    }
8186
 
8187
    @Override
8188
    public String toString() {
8189
      StringBuilder sb = new StringBuilder("getItemInventoryByItemId_result(");
8190
      boolean first = true;
8191
 
8192
      sb.append("success:");
8193
      if (this.success == null) {
8194
        sb.append("null");
8195
      } else {
8196
        sb.append(this.success);
8197
      }
8198
      first = false;
8199
      if (!first) sb.append(", ");
8200
      sb.append("cex:");
8201
      if (this.cex == null) {
8202
        sb.append("null");
8203
      } else {
8204
        sb.append(this.cex);
8205
      }
8206
      first = false;
8207
      sb.append(")");
8208
      return sb.toString();
8209
    }
8210
 
8211
    public void validate() throws org.apache.thrift.TException {
8212
      // check for required fields
8213
    }
8214
 
8215
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8216
      try {
8217
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8218
      } catch (org.apache.thrift.TException te) {
8219
        throw new java.io.IOException(te);
8220
      }
8221
    }
8222
 
8223
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8224
      try {
8225
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8226
      } catch (org.apache.thrift.TException te) {
8227
        throw new java.io.IOException(te);
8228
      }
8229
    }
8230
 
8231
  }
8232
 
8233
  public static class getItemAvailibilityAtWarehouse_args implements org.apache.thrift.TBase<getItemAvailibilityAtWarehouse_args, getItemAvailibilityAtWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
8234
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailibilityAtWarehouse_args");
8235
 
8236
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouse_id", org.apache.thrift.protocol.TType.I64, (short)1);
8237
    private static final org.apache.thrift.protocol.TField ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("item_id", org.apache.thrift.protocol.TType.I64, (short)2);
8238
 
8239
    private long warehouse_id; // required
8240
    private long item_id; // required
8241
 
8242
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8243
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8244
      WAREHOUSE_ID((short)1, "warehouse_id"),
8245
      ITEM_ID((short)2, "item_id");
8246
 
8247
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8248
 
8249
      static {
8250
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8251
          byName.put(field.getFieldName(), field);
8252
        }
8253
      }
8254
 
8255
      /**
8256
       * Find the _Fields constant that matches fieldId, or null if its not found.
8257
       */
8258
      public static _Fields findByThriftId(int fieldId) {
8259
        switch(fieldId) {
8260
          case 1: // WAREHOUSE_ID
8261
            return WAREHOUSE_ID;
8262
          case 2: // ITEM_ID
8263
            return ITEM_ID;
8264
          default:
8265
            return null;
8266
        }
8267
      }
8268
 
8269
      /**
8270
       * Find the _Fields constant that matches fieldId, throwing an exception
8271
       * if it is not found.
8272
       */
8273
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8274
        _Fields fields = findByThriftId(fieldId);
8275
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8276
        return fields;
8277
      }
8278
 
8279
      /**
8280
       * Find the _Fields constant that matches name, or null if its not found.
8281
       */
8282
      public static _Fields findByName(String name) {
8283
        return byName.get(name);
8284
      }
8285
 
8286
      private final short _thriftId;
8287
      private final String _fieldName;
8288
 
8289
      _Fields(short thriftId, String fieldName) {
8290
        _thriftId = thriftId;
8291
        _fieldName = fieldName;
8292
      }
8293
 
8294
      public short getThriftFieldId() {
8295
        return _thriftId;
8296
      }
8297
 
8298
      public String getFieldName() {
8299
        return _fieldName;
8300
      }
8301
    }
8302
 
8303
    // isset id assignments
8304
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
8305
    private static final int __ITEM_ID_ISSET_ID = 1;
8306
    private BitSet __isset_bit_vector = new BitSet(2);
8307
 
8308
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8309
    static {
8310
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8311
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8312
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8313
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8314
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8315
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8316
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailibilityAtWarehouse_args.class, metaDataMap);
8317
    }
8318
 
8319
    public getItemAvailibilityAtWarehouse_args() {
8320
    }
8321
 
8322
    public getItemAvailibilityAtWarehouse_args(
8323
      long warehouse_id,
8324
      long item_id)
8325
    {
8326
      this();
8327
      this.warehouse_id = warehouse_id;
8328
      setWarehouse_idIsSet(true);
8329
      this.item_id = item_id;
8330
      setItem_idIsSet(true);
8331
    }
8332
 
8333
    /**
8334
     * Performs a deep copy on <i>other</i>.
8335
     */
8336
    public getItemAvailibilityAtWarehouse_args(getItemAvailibilityAtWarehouse_args other) {
8337
      __isset_bit_vector.clear();
8338
      __isset_bit_vector.or(other.__isset_bit_vector);
8339
      this.warehouse_id = other.warehouse_id;
8340
      this.item_id = other.item_id;
8341
    }
8342
 
8343
    public getItemAvailibilityAtWarehouse_args deepCopy() {
8344
      return new getItemAvailibilityAtWarehouse_args(this);
8345
    }
8346
 
8347
    @Override
8348
    public void clear() {
8349
      setWarehouse_idIsSet(false);
8350
      this.warehouse_id = 0;
8351
      setItem_idIsSet(false);
8352
      this.item_id = 0;
8353
    }
8354
 
8355
    public long getWarehouse_id() {
8356
      return this.warehouse_id;
8357
    }
8358
 
8359
    public void setWarehouse_id(long warehouse_id) {
8360
      this.warehouse_id = warehouse_id;
8361
      setWarehouse_idIsSet(true);
8362
    }
8363
 
8364
    public void unsetWarehouse_id() {
8365
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
8366
    }
8367
 
8368
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
8369
    public boolean isSetWarehouse_id() {
8370
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
8371
    }
8372
 
8373
    public void setWarehouse_idIsSet(boolean value) {
8374
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
8375
    }
8376
 
8377
    public long getItem_id() {
8378
      return this.item_id;
8379
    }
8380
 
8381
    public void setItem_id(long item_id) {
8382
      this.item_id = item_id;
8383
      setItem_idIsSet(true);
8384
    }
8385
 
8386
    public void unsetItem_id() {
8387
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
8388
    }
8389
 
8390
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
8391
    public boolean isSetItem_id() {
8392
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
8393
    }
8394
 
8395
    public void setItem_idIsSet(boolean value) {
8396
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
8397
    }
8398
 
8399
    public void setFieldValue(_Fields field, Object value) {
8400
      switch (field) {
8401
      case WAREHOUSE_ID:
8402
        if (value == null) {
8403
          unsetWarehouse_id();
8404
        } else {
8405
          setWarehouse_id((Long)value);
8406
        }
8407
        break;
8408
 
8409
      case ITEM_ID:
8410
        if (value == null) {
8411
          unsetItem_id();
8412
        } else {
8413
          setItem_id((Long)value);
8414
        }
8415
        break;
8416
 
8417
      }
8418
    }
8419
 
8420
    public Object getFieldValue(_Fields field) {
8421
      switch (field) {
8422
      case WAREHOUSE_ID:
8423
        return Long.valueOf(getWarehouse_id());
8424
 
8425
      case ITEM_ID:
8426
        return Long.valueOf(getItem_id());
8427
 
8428
      }
8429
      throw new IllegalStateException();
8430
    }
8431
 
8432
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8433
    public boolean isSet(_Fields field) {
8434
      if (field == null) {
8435
        throw new IllegalArgumentException();
8436
      }
8437
 
8438
      switch (field) {
8439
      case WAREHOUSE_ID:
8440
        return isSetWarehouse_id();
8441
      case ITEM_ID:
8442
        return isSetItem_id();
8443
      }
8444
      throw new IllegalStateException();
8445
    }
8446
 
8447
    @Override
8448
    public boolean equals(Object that) {
8449
      if (that == null)
8450
        return false;
8451
      if (that instanceof getItemAvailibilityAtWarehouse_args)
8452
        return this.equals((getItemAvailibilityAtWarehouse_args)that);
8453
      return false;
8454
    }
8455
 
8456
    public boolean equals(getItemAvailibilityAtWarehouse_args that) {
8457
      if (that == null)
8458
        return false;
8459
 
8460
      boolean this_present_warehouse_id = true;
8461
      boolean that_present_warehouse_id = true;
8462
      if (this_present_warehouse_id || that_present_warehouse_id) {
8463
        if (!(this_present_warehouse_id && that_present_warehouse_id))
8464
          return false;
8465
        if (this.warehouse_id != that.warehouse_id)
8466
          return false;
8467
      }
8468
 
8469
      boolean this_present_item_id = true;
8470
      boolean that_present_item_id = true;
8471
      if (this_present_item_id || that_present_item_id) {
8472
        if (!(this_present_item_id && that_present_item_id))
8473
          return false;
8474
        if (this.item_id != that.item_id)
8475
          return false;
8476
      }
8477
 
8478
      return true;
8479
    }
8480
 
8481
    @Override
8482
    public int hashCode() {
8483
      return 0;
8484
    }
8485
 
8486
    public int compareTo(getItemAvailibilityAtWarehouse_args other) {
8487
      if (!getClass().equals(other.getClass())) {
8488
        return getClass().getName().compareTo(other.getClass().getName());
8489
      }
8490
 
8491
      int lastComparison = 0;
8492
      getItemAvailibilityAtWarehouse_args typedOther = (getItemAvailibilityAtWarehouse_args)other;
8493
 
8494
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
8495
      if (lastComparison != 0) {
8496
        return lastComparison;
8497
      }
8498
      if (isSetWarehouse_id()) {
8499
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
8500
        if (lastComparison != 0) {
8501
          return lastComparison;
8502
        }
8503
      }
8504
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
8505
      if (lastComparison != 0) {
8506
        return lastComparison;
8507
      }
8508
      if (isSetItem_id()) {
8509
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
8510
        if (lastComparison != 0) {
8511
          return lastComparison;
8512
        }
8513
      }
8514
      return 0;
8515
    }
8516
 
8517
    public _Fields fieldForId(int fieldId) {
8518
      return _Fields.findByThriftId(fieldId);
8519
    }
8520
 
8521
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8522
      org.apache.thrift.protocol.TField field;
8523
      iprot.readStructBegin();
8524
      while (true)
8525
      {
8526
        field = iprot.readFieldBegin();
8527
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8528
          break;
8529
        }
8530
        switch (field.id) {
8531
          case 1: // WAREHOUSE_ID
8532
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8533
              this.warehouse_id = iprot.readI64();
8534
              setWarehouse_idIsSet(true);
8535
            } else { 
8536
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8537
            }
8538
            break;
8539
          case 2: // ITEM_ID
8540
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8541
              this.item_id = iprot.readI64();
8542
              setItem_idIsSet(true);
8543
            } else { 
8544
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8545
            }
8546
            break;
8547
          default:
8548
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8549
        }
8550
        iprot.readFieldEnd();
8551
      }
8552
      iprot.readStructEnd();
8553
      validate();
8554
    }
8555
 
8556
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8557
      validate();
8558
 
8559
      oprot.writeStructBegin(STRUCT_DESC);
8560
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
8561
      oprot.writeI64(this.warehouse_id);
8562
      oprot.writeFieldEnd();
8563
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
8564
      oprot.writeI64(this.item_id);
8565
      oprot.writeFieldEnd();
8566
      oprot.writeFieldStop();
8567
      oprot.writeStructEnd();
8568
    }
8569
 
8570
    @Override
8571
    public String toString() {
8572
      StringBuilder sb = new StringBuilder("getItemAvailibilityAtWarehouse_args(");
8573
      boolean first = true;
8574
 
8575
      sb.append("warehouse_id:");
8576
      sb.append(this.warehouse_id);
8577
      first = false;
8578
      if (!first) sb.append(", ");
8579
      sb.append("item_id:");
8580
      sb.append(this.item_id);
8581
      first = false;
8582
      sb.append(")");
8583
      return sb.toString();
8584
    }
8585
 
8586
    public void validate() throws org.apache.thrift.TException {
8587
      // check for required fields
8588
    }
8589
 
8590
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8591
      try {
8592
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8593
      } catch (org.apache.thrift.TException te) {
8594
        throw new java.io.IOException(te);
8595
      }
8596
    }
8597
 
8598
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8599
      try {
8600
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
8601
        __isset_bit_vector = new BitSet(1);
8602
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8603
      } catch (org.apache.thrift.TException te) {
8604
        throw new java.io.IOException(te);
8605
      }
8606
    }
8607
 
8608
  }
8609
 
8610
  public static class getItemAvailibilityAtWarehouse_result implements org.apache.thrift.TBase<getItemAvailibilityAtWarehouse_result, getItemAvailibilityAtWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
8611
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailibilityAtWarehouse_result");
8612
 
8613
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.I64, (short)0);
8614
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
8615
 
8616
    private long success; // required
8617
    private InventoryServiceException cex; // required
8618
 
8619
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8620
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8621
      SUCCESS((short)0, "success"),
8622
      CEX((short)1, "cex");
8623
 
8624
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8625
 
8626
      static {
8627
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8628
          byName.put(field.getFieldName(), field);
8629
        }
8630
      }
8631
 
8632
      /**
8633
       * Find the _Fields constant that matches fieldId, or null if its not found.
8634
       */
8635
      public static _Fields findByThriftId(int fieldId) {
8636
        switch(fieldId) {
8637
          case 0: // SUCCESS
8638
            return SUCCESS;
8639
          case 1: // CEX
8640
            return CEX;
8641
          default:
8642
            return null;
8643
        }
8644
      }
8645
 
8646
      /**
8647
       * Find the _Fields constant that matches fieldId, throwing an exception
8648
       * if it is not found.
8649
       */
8650
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8651
        _Fields fields = findByThriftId(fieldId);
8652
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8653
        return fields;
8654
      }
8655
 
8656
      /**
8657
       * Find the _Fields constant that matches name, or null if its not found.
8658
       */
8659
      public static _Fields findByName(String name) {
8660
        return byName.get(name);
8661
      }
8662
 
8663
      private final short _thriftId;
8664
      private final String _fieldName;
8665
 
8666
      _Fields(short thriftId, String fieldName) {
8667
        _thriftId = thriftId;
8668
        _fieldName = fieldName;
8669
      }
8670
 
8671
      public short getThriftFieldId() {
8672
        return _thriftId;
8673
      }
8674
 
8675
      public String getFieldName() {
8676
        return _fieldName;
8677
      }
8678
    }
8679
 
8680
    // isset id assignments
8681
    private static final int __SUCCESS_ISSET_ID = 0;
8682
    private BitSet __isset_bit_vector = new BitSet(1);
8683
 
8684
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8685
    static {
8686
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8687
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8688
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8689
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8690
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
8691
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8692
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailibilityAtWarehouse_result.class, metaDataMap);
8693
    }
8694
 
8695
    public getItemAvailibilityAtWarehouse_result() {
8696
    }
8697
 
8698
    public getItemAvailibilityAtWarehouse_result(
8699
      long success,
8700
      InventoryServiceException cex)
8701
    {
8702
      this();
8703
      this.success = success;
8704
      setSuccessIsSet(true);
8705
      this.cex = cex;
8706
    }
8707
 
8708
    /**
8709
     * Performs a deep copy on <i>other</i>.
8710
     */
8711
    public getItemAvailibilityAtWarehouse_result(getItemAvailibilityAtWarehouse_result other) {
8712
      __isset_bit_vector.clear();
8713
      __isset_bit_vector.or(other.__isset_bit_vector);
8714
      this.success = other.success;
8715
      if (other.isSetCex()) {
8716
        this.cex = new InventoryServiceException(other.cex);
8717
      }
8718
    }
8719
 
8720
    public getItemAvailibilityAtWarehouse_result deepCopy() {
8721
      return new getItemAvailibilityAtWarehouse_result(this);
8722
    }
8723
 
8724
    @Override
8725
    public void clear() {
8726
      setSuccessIsSet(false);
8727
      this.success = 0;
8728
      this.cex = null;
8729
    }
8730
 
8731
    public long getSuccess() {
8732
      return this.success;
8733
    }
8734
 
8735
    public void setSuccess(long success) {
8736
      this.success = success;
8737
      setSuccessIsSet(true);
8738
    }
8739
 
8740
    public void unsetSuccess() {
8741
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
8742
    }
8743
 
8744
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
8745
    public boolean isSetSuccess() {
8746
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
8747
    }
8748
 
8749
    public void setSuccessIsSet(boolean value) {
8750
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
8751
    }
8752
 
8753
    public InventoryServiceException getCex() {
8754
      return this.cex;
8755
    }
8756
 
8757
    public void setCex(InventoryServiceException cex) {
8758
      this.cex = cex;
8759
    }
8760
 
8761
    public void unsetCex() {
8762
      this.cex = null;
8763
    }
8764
 
8765
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
8766
    public boolean isSetCex() {
8767
      return this.cex != null;
8768
    }
8769
 
8770
    public void setCexIsSet(boolean value) {
8771
      if (!value) {
8772
        this.cex = null;
8773
      }
8774
    }
8775
 
8776
    public void setFieldValue(_Fields field, Object value) {
8777
      switch (field) {
8778
      case SUCCESS:
8779
        if (value == null) {
8780
          unsetSuccess();
8781
        } else {
8782
          setSuccess((Long)value);
8783
        }
8784
        break;
8785
 
8786
      case CEX:
8787
        if (value == null) {
8788
          unsetCex();
8789
        } else {
8790
          setCex((InventoryServiceException)value);
8791
        }
8792
        break;
8793
 
8794
      }
8795
    }
8796
 
8797
    public Object getFieldValue(_Fields field) {
8798
      switch (field) {
8799
      case SUCCESS:
8800
        return Long.valueOf(getSuccess());
8801
 
8802
      case CEX:
8803
        return getCex();
8804
 
8805
      }
8806
      throw new IllegalStateException();
8807
    }
8808
 
8809
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8810
    public boolean isSet(_Fields field) {
8811
      if (field == null) {
8812
        throw new IllegalArgumentException();
8813
      }
8814
 
8815
      switch (field) {
8816
      case SUCCESS:
8817
        return isSetSuccess();
8818
      case CEX:
8819
        return isSetCex();
8820
      }
8821
      throw new IllegalStateException();
8822
    }
8823
 
8824
    @Override
8825
    public boolean equals(Object that) {
8826
      if (that == null)
8827
        return false;
8828
      if (that instanceof getItemAvailibilityAtWarehouse_result)
8829
        return this.equals((getItemAvailibilityAtWarehouse_result)that);
8830
      return false;
8831
    }
8832
 
8833
    public boolean equals(getItemAvailibilityAtWarehouse_result that) {
8834
      if (that == null)
8835
        return false;
8836
 
8837
      boolean this_present_success = true;
8838
      boolean that_present_success = true;
8839
      if (this_present_success || that_present_success) {
8840
        if (!(this_present_success && that_present_success))
8841
          return false;
8842
        if (this.success != that.success)
8843
          return false;
8844
      }
8845
 
8846
      boolean this_present_cex = true && this.isSetCex();
8847
      boolean that_present_cex = true && that.isSetCex();
8848
      if (this_present_cex || that_present_cex) {
8849
        if (!(this_present_cex && that_present_cex))
8850
          return false;
8851
        if (!this.cex.equals(that.cex))
8852
          return false;
8853
      }
8854
 
8855
      return true;
8856
    }
8857
 
8858
    @Override
8859
    public int hashCode() {
8860
      return 0;
8861
    }
8862
 
8863
    public int compareTo(getItemAvailibilityAtWarehouse_result other) {
8864
      if (!getClass().equals(other.getClass())) {
8865
        return getClass().getName().compareTo(other.getClass().getName());
8866
      }
8867
 
8868
      int lastComparison = 0;
8869
      getItemAvailibilityAtWarehouse_result typedOther = (getItemAvailibilityAtWarehouse_result)other;
8870
 
8871
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
8872
      if (lastComparison != 0) {
8873
        return lastComparison;
8874
      }
8875
      if (isSetSuccess()) {
8876
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8877
        if (lastComparison != 0) {
8878
          return lastComparison;
8879
        }
8880
      }
8881
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
8882
      if (lastComparison != 0) {
8883
        return lastComparison;
8884
      }
8885
      if (isSetCex()) {
8886
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
8887
        if (lastComparison != 0) {
8888
          return lastComparison;
8889
        }
8890
      }
8891
      return 0;
8892
    }
8893
 
8894
    public _Fields fieldForId(int fieldId) {
8895
      return _Fields.findByThriftId(fieldId);
8896
    }
8897
 
8898
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8899
      org.apache.thrift.protocol.TField field;
8900
      iprot.readStructBegin();
8901
      while (true)
8902
      {
8903
        field = iprot.readFieldBegin();
8904
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8905
          break;
8906
        }
8907
        switch (field.id) {
8908
          case 0: // SUCCESS
8909
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8910
              this.success = iprot.readI64();
8911
              setSuccessIsSet(true);
8912
            } else { 
8913
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8914
            }
8915
            break;
8916
          case 1: // CEX
8917
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8918
              this.cex = new InventoryServiceException();
8919
              this.cex.read(iprot);
8920
            } else { 
8921
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8922
            }
8923
            break;
8924
          default:
8925
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8926
        }
8927
        iprot.readFieldEnd();
8928
      }
8929
      iprot.readStructEnd();
8930
      validate();
8931
    }
8932
 
8933
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8934
      oprot.writeStructBegin(STRUCT_DESC);
8935
 
8936
      if (this.isSetSuccess()) {
8937
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8938
        oprot.writeI64(this.success);
8939
        oprot.writeFieldEnd();
8940
      } else if (this.isSetCex()) {
8941
        oprot.writeFieldBegin(CEX_FIELD_DESC);
8942
        this.cex.write(oprot);
8943
        oprot.writeFieldEnd();
8944
      }
8945
      oprot.writeFieldStop();
8946
      oprot.writeStructEnd();
8947
    }
8948
 
8949
    @Override
8950
    public String toString() {
8951
      StringBuilder sb = new StringBuilder("getItemAvailibilityAtWarehouse_result(");
8952
      boolean first = true;
8953
 
8954
      sb.append("success:");
8955
      sb.append(this.success);
8956
      first = false;
8957
      if (!first) sb.append(", ");
8958
      sb.append("cex:");
8959
      if (this.cex == null) {
8960
        sb.append("null");
8961
      } else {
8962
        sb.append(this.cex);
8963
      }
8964
      first = false;
8965
      sb.append(")");
8966
      return sb.toString();
8967
    }
8968
 
8969
    public void validate() throws org.apache.thrift.TException {
8970
      // check for required fields
8971
    }
8972
 
8973
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8974
      try {
8975
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8976
      } catch (org.apache.thrift.TException te) {
8977
        throw new java.io.IOException(te);
8978
      }
8979
    }
8980
 
8981
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8982
      try {
8983
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8984
      } catch (org.apache.thrift.TException te) {
8985
        throw new java.io.IOException(te);
8986
      }
8987
    }
8988
 
8989
  }
8990
 
8991
  public static class getItemAvailabilityAtLocation_args implements org.apache.thrift.TBase<getItemAvailabilityAtLocation_args, getItemAvailabilityAtLocation_args._Fields>, java.io.Serializable, Cloneable   {
8992
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailabilityAtLocation_args");
8993
 
8994
    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);
5978 rajveer 8995
    private static final org.apache.thrift.protocol.TField SOURCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sourceId", org.apache.thrift.protocol.TType.I64, (short)2);
5945 mandeep.dh 8996
 
8997
    private long itemId; // required
5978 rajveer 8998
    private long sourceId; // required
5945 mandeep.dh 8999
 
9000
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9001
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5978 rajveer 9002
      ITEM_ID((short)1, "itemId"),
9003
      SOURCE_ID((short)2, "sourceId");
5945 mandeep.dh 9004
 
9005
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9006
 
9007
      static {
9008
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9009
          byName.put(field.getFieldName(), field);
9010
        }
9011
      }
9012
 
9013
      /**
9014
       * Find the _Fields constant that matches fieldId, or null if its not found.
9015
       */
9016
      public static _Fields findByThriftId(int fieldId) {
9017
        switch(fieldId) {
9018
          case 1: // ITEM_ID
9019
            return ITEM_ID;
5978 rajveer 9020
          case 2: // SOURCE_ID
9021
            return SOURCE_ID;
5945 mandeep.dh 9022
          default:
9023
            return null;
9024
        }
9025
      }
9026
 
9027
      /**
9028
       * Find the _Fields constant that matches fieldId, throwing an exception
9029
       * if it is not found.
9030
       */
9031
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9032
        _Fields fields = findByThriftId(fieldId);
9033
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9034
        return fields;
9035
      }
9036
 
9037
      /**
9038
       * Find the _Fields constant that matches name, or null if its not found.
9039
       */
9040
      public static _Fields findByName(String name) {
9041
        return byName.get(name);
9042
      }
9043
 
9044
      private final short _thriftId;
9045
      private final String _fieldName;
9046
 
9047
      _Fields(short thriftId, String fieldName) {
9048
        _thriftId = thriftId;
9049
        _fieldName = fieldName;
9050
      }
9051
 
9052
      public short getThriftFieldId() {
9053
        return _thriftId;
9054
      }
9055
 
9056
      public String getFieldName() {
9057
        return _fieldName;
9058
      }
9059
    }
9060
 
9061
    // isset id assignments
9062
    private static final int __ITEMID_ISSET_ID = 0;
5978 rajveer 9063
    private static final int __SOURCEID_ISSET_ID = 1;
9064
    private BitSet __isset_bit_vector = new BitSet(2);
5945 mandeep.dh 9065
 
9066
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9067
    static {
9068
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9069
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9070
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5978 rajveer 9071
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9072
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5945 mandeep.dh 9073
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9074
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailabilityAtLocation_args.class, metaDataMap);
9075
    }
9076
 
9077
    public getItemAvailabilityAtLocation_args() {
9078
    }
9079
 
9080
    public getItemAvailabilityAtLocation_args(
5978 rajveer 9081
      long itemId,
9082
      long sourceId)
5945 mandeep.dh 9083
    {
9084
      this();
9085
      this.itemId = itemId;
9086
      setItemIdIsSet(true);
5978 rajveer 9087
      this.sourceId = sourceId;
9088
      setSourceIdIsSet(true);
5945 mandeep.dh 9089
    }
9090
 
9091
    /**
9092
     * Performs a deep copy on <i>other</i>.
9093
     */
9094
    public getItemAvailabilityAtLocation_args(getItemAvailabilityAtLocation_args other) {
9095
      __isset_bit_vector.clear();
9096
      __isset_bit_vector.or(other.__isset_bit_vector);
9097
      this.itemId = other.itemId;
5978 rajveer 9098
      this.sourceId = other.sourceId;
5945 mandeep.dh 9099
    }
9100
 
9101
    public getItemAvailabilityAtLocation_args deepCopy() {
9102
      return new getItemAvailabilityAtLocation_args(this);
9103
    }
9104
 
9105
    @Override
9106
    public void clear() {
9107
      setItemIdIsSet(false);
9108
      this.itemId = 0;
5978 rajveer 9109
      setSourceIdIsSet(false);
9110
      this.sourceId = 0;
5945 mandeep.dh 9111
    }
9112
 
9113
    public long getItemId() {
9114
      return this.itemId;
9115
    }
9116
 
9117
    public void setItemId(long itemId) {
9118
      this.itemId = itemId;
9119
      setItemIdIsSet(true);
9120
    }
9121
 
9122
    public void unsetItemId() {
9123
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
9124
    }
9125
 
9126
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
9127
    public boolean isSetItemId() {
9128
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
9129
    }
9130
 
9131
    public void setItemIdIsSet(boolean value) {
9132
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
9133
    }
9134
 
5978 rajveer 9135
    public long getSourceId() {
9136
      return this.sourceId;
9137
    }
9138
 
9139
    public void setSourceId(long sourceId) {
9140
      this.sourceId = sourceId;
9141
      setSourceIdIsSet(true);
9142
    }
9143
 
9144
    public void unsetSourceId() {
9145
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
9146
    }
9147
 
9148
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
9149
    public boolean isSetSourceId() {
9150
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
9151
    }
9152
 
9153
    public void setSourceIdIsSet(boolean value) {
9154
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
9155
    }
9156
 
5945 mandeep.dh 9157
    public void setFieldValue(_Fields field, Object value) {
9158
      switch (field) {
9159
      case ITEM_ID:
9160
        if (value == null) {
9161
          unsetItemId();
9162
        } else {
9163
          setItemId((Long)value);
9164
        }
9165
        break;
9166
 
5978 rajveer 9167
      case SOURCE_ID:
9168
        if (value == null) {
9169
          unsetSourceId();
9170
        } else {
9171
          setSourceId((Long)value);
9172
        }
9173
        break;
9174
 
5945 mandeep.dh 9175
      }
9176
    }
9177
 
9178
    public Object getFieldValue(_Fields field) {
9179
      switch (field) {
9180
      case ITEM_ID:
9181
        return Long.valueOf(getItemId());
9182
 
5978 rajveer 9183
      case SOURCE_ID:
9184
        return Long.valueOf(getSourceId());
9185
 
5945 mandeep.dh 9186
      }
9187
      throw new IllegalStateException();
9188
    }
9189
 
9190
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9191
    public boolean isSet(_Fields field) {
9192
      if (field == null) {
9193
        throw new IllegalArgumentException();
9194
      }
9195
 
9196
      switch (field) {
9197
      case ITEM_ID:
9198
        return isSetItemId();
5978 rajveer 9199
      case SOURCE_ID:
9200
        return isSetSourceId();
5945 mandeep.dh 9201
      }
9202
      throw new IllegalStateException();
9203
    }
9204
 
9205
    @Override
9206
    public boolean equals(Object that) {
9207
      if (that == null)
9208
        return false;
9209
      if (that instanceof getItemAvailabilityAtLocation_args)
9210
        return this.equals((getItemAvailabilityAtLocation_args)that);
9211
      return false;
9212
    }
9213
 
9214
    public boolean equals(getItemAvailabilityAtLocation_args that) {
9215
      if (that == null)
9216
        return false;
9217
 
9218
      boolean this_present_itemId = true;
9219
      boolean that_present_itemId = true;
9220
      if (this_present_itemId || that_present_itemId) {
9221
        if (!(this_present_itemId && that_present_itemId))
9222
          return false;
9223
        if (this.itemId != that.itemId)
9224
          return false;
9225
      }
9226
 
5978 rajveer 9227
      boolean this_present_sourceId = true;
9228
      boolean that_present_sourceId = true;
9229
      if (this_present_sourceId || that_present_sourceId) {
9230
        if (!(this_present_sourceId && that_present_sourceId))
9231
          return false;
9232
        if (this.sourceId != that.sourceId)
9233
          return false;
9234
      }
9235
 
5945 mandeep.dh 9236
      return true;
9237
    }
9238
 
9239
    @Override
9240
    public int hashCode() {
9241
      return 0;
9242
    }
9243
 
9244
    public int compareTo(getItemAvailabilityAtLocation_args other) {
9245
      if (!getClass().equals(other.getClass())) {
9246
        return getClass().getName().compareTo(other.getClass().getName());
9247
      }
9248
 
9249
      int lastComparison = 0;
9250
      getItemAvailabilityAtLocation_args typedOther = (getItemAvailabilityAtLocation_args)other;
9251
 
9252
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
9253
      if (lastComparison != 0) {
9254
        return lastComparison;
9255
      }
9256
      if (isSetItemId()) {
9257
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
9258
        if (lastComparison != 0) {
9259
          return lastComparison;
9260
        }
9261
      }
5978 rajveer 9262
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
9263
      if (lastComparison != 0) {
9264
        return lastComparison;
9265
      }
9266
      if (isSetSourceId()) {
9267
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
9268
        if (lastComparison != 0) {
9269
          return lastComparison;
9270
        }
9271
      }
5945 mandeep.dh 9272
      return 0;
9273
    }
9274
 
9275
    public _Fields fieldForId(int fieldId) {
9276
      return _Fields.findByThriftId(fieldId);
9277
    }
9278
 
9279
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9280
      org.apache.thrift.protocol.TField field;
9281
      iprot.readStructBegin();
9282
      while (true)
9283
      {
9284
        field = iprot.readFieldBegin();
9285
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9286
          break;
9287
        }
9288
        switch (field.id) {
9289
          case 1: // ITEM_ID
9290
            if (field.type == org.apache.thrift.protocol.TType.I64) {
9291
              this.itemId = iprot.readI64();
9292
              setItemIdIsSet(true);
9293
            } else { 
9294
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9295
            }
9296
            break;
5978 rajveer 9297
          case 2: // SOURCE_ID
9298
            if (field.type == org.apache.thrift.protocol.TType.I64) {
9299
              this.sourceId = iprot.readI64();
9300
              setSourceIdIsSet(true);
9301
            } else { 
9302
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9303
            }
9304
            break;
5945 mandeep.dh 9305
          default:
9306
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9307
        }
9308
        iprot.readFieldEnd();
9309
      }
9310
      iprot.readStructEnd();
9311
      validate();
9312
    }
9313
 
9314
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9315
      validate();
9316
 
9317
      oprot.writeStructBegin(STRUCT_DESC);
9318
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
9319
      oprot.writeI64(this.itemId);
9320
      oprot.writeFieldEnd();
5978 rajveer 9321
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
9322
      oprot.writeI64(this.sourceId);
9323
      oprot.writeFieldEnd();
5945 mandeep.dh 9324
      oprot.writeFieldStop();
9325
      oprot.writeStructEnd();
9326
    }
9327
 
9328
    @Override
9329
    public String toString() {
9330
      StringBuilder sb = new StringBuilder("getItemAvailabilityAtLocation_args(");
9331
      boolean first = true;
9332
 
9333
      sb.append("itemId:");
9334
      sb.append(this.itemId);
9335
      first = false;
5978 rajveer 9336
      if (!first) sb.append(", ");
9337
      sb.append("sourceId:");
9338
      sb.append(this.sourceId);
9339
      first = false;
5945 mandeep.dh 9340
      sb.append(")");
9341
      return sb.toString();
9342
    }
9343
 
9344
    public void validate() throws org.apache.thrift.TException {
9345
      // check for required fields
9346
    }
9347
 
9348
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9349
      try {
9350
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9351
      } catch (org.apache.thrift.TException te) {
9352
        throw new java.io.IOException(te);
9353
      }
9354
    }
9355
 
9356
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9357
      try {
9358
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9359
      } catch (org.apache.thrift.TException te) {
9360
        throw new java.io.IOException(te);
9361
      }
9362
    }
9363
 
9364
  }
9365
 
9366
  public static class getItemAvailabilityAtLocation_result implements org.apache.thrift.TBase<getItemAvailabilityAtLocation_result, getItemAvailabilityAtLocation_result._Fields>, java.io.Serializable, Cloneable   {
9367
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailabilityAtLocation_result");
9368
 
9369
    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);
9370
    private static final org.apache.thrift.protocol.TField ISEX_FIELD_DESC = new org.apache.thrift.protocol.TField("isex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
9371
 
9372
    private List<Long> success; // required
9373
    private InventoryServiceException isex; // required
9374
 
9375
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9376
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9377
      SUCCESS((short)0, "success"),
9378
      ISEX((short)1, "isex");
9379
 
9380
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9381
 
9382
      static {
9383
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9384
          byName.put(field.getFieldName(), field);
9385
        }
9386
      }
9387
 
9388
      /**
9389
       * Find the _Fields constant that matches fieldId, or null if its not found.
9390
       */
9391
      public static _Fields findByThriftId(int fieldId) {
9392
        switch(fieldId) {
9393
          case 0: // SUCCESS
9394
            return SUCCESS;
9395
          case 1: // ISEX
9396
            return ISEX;
9397
          default:
9398
            return null;
9399
        }
9400
      }
9401
 
9402
      /**
9403
       * Find the _Fields constant that matches fieldId, throwing an exception
9404
       * if it is not found.
9405
       */
9406
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9407
        _Fields fields = findByThriftId(fieldId);
9408
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9409
        return fields;
9410
      }
9411
 
9412
      /**
9413
       * Find the _Fields constant that matches name, or null if its not found.
9414
       */
9415
      public static _Fields findByName(String name) {
9416
        return byName.get(name);
9417
      }
9418
 
9419
      private final short _thriftId;
9420
      private final String _fieldName;
9421
 
9422
      _Fields(short thriftId, String fieldName) {
9423
        _thriftId = thriftId;
9424
        _fieldName = fieldName;
9425
      }
9426
 
9427
      public short getThriftFieldId() {
9428
        return _thriftId;
9429
      }
9430
 
9431
      public String getFieldName() {
9432
        return _fieldName;
9433
      }
9434
    }
9435
 
9436
    // isset id assignments
9437
 
9438
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9439
    static {
9440
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9441
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9442
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9443
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
9444
      tmpMap.put(_Fields.ISEX, new org.apache.thrift.meta_data.FieldMetaData("isex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9445
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9446
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9447
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailabilityAtLocation_result.class, metaDataMap);
9448
    }
9449
 
9450
    public getItemAvailabilityAtLocation_result() {
9451
    }
9452
 
9453
    public getItemAvailabilityAtLocation_result(
9454
      List<Long> success,
9455
      InventoryServiceException isex)
9456
    {
9457
      this();
9458
      this.success = success;
9459
      this.isex = isex;
9460
    }
9461
 
9462
    /**
9463
     * Performs a deep copy on <i>other</i>.
9464
     */
9465
    public getItemAvailabilityAtLocation_result(getItemAvailabilityAtLocation_result other) {
9466
      if (other.isSetSuccess()) {
9467
        List<Long> __this__success = new ArrayList<Long>();
9468
        for (Long other_element : other.success) {
9469
          __this__success.add(other_element);
9470
        }
9471
        this.success = __this__success;
9472
      }
9473
      if (other.isSetIsex()) {
9474
        this.isex = new InventoryServiceException(other.isex);
9475
      }
9476
    }
9477
 
9478
    public getItemAvailabilityAtLocation_result deepCopy() {
9479
      return new getItemAvailabilityAtLocation_result(this);
9480
    }
9481
 
9482
    @Override
9483
    public void clear() {
9484
      this.success = null;
9485
      this.isex = null;
9486
    }
9487
 
9488
    public int getSuccessSize() {
9489
      return (this.success == null) ? 0 : this.success.size();
9490
    }
9491
 
9492
    public java.util.Iterator<Long> getSuccessIterator() {
9493
      return (this.success == null) ? null : this.success.iterator();
9494
    }
9495
 
9496
    public void addToSuccess(long elem) {
9497
      if (this.success == null) {
9498
        this.success = new ArrayList<Long>();
9499
      }
9500
      this.success.add(elem);
9501
    }
9502
 
9503
    public List<Long> getSuccess() {
9504
      return this.success;
9505
    }
9506
 
9507
    public void setSuccess(List<Long> success) {
9508
      this.success = success;
9509
    }
9510
 
9511
    public void unsetSuccess() {
9512
      this.success = null;
9513
    }
9514
 
9515
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9516
    public boolean isSetSuccess() {
9517
      return this.success != null;
9518
    }
9519
 
9520
    public void setSuccessIsSet(boolean value) {
9521
      if (!value) {
9522
        this.success = null;
9523
      }
9524
    }
9525
 
9526
    public InventoryServiceException getIsex() {
9527
      return this.isex;
9528
    }
9529
 
9530
    public void setIsex(InventoryServiceException isex) {
9531
      this.isex = isex;
9532
    }
9533
 
9534
    public void unsetIsex() {
9535
      this.isex = null;
9536
    }
9537
 
9538
    /** Returns true if field isex is set (has been assigned a value) and false otherwise */
9539
    public boolean isSetIsex() {
9540
      return this.isex != null;
9541
    }
9542
 
9543
    public void setIsexIsSet(boolean value) {
9544
      if (!value) {
9545
        this.isex = null;
9546
      }
9547
    }
9548
 
9549
    public void setFieldValue(_Fields field, Object value) {
9550
      switch (field) {
9551
      case SUCCESS:
9552
        if (value == null) {
9553
          unsetSuccess();
9554
        } else {
9555
          setSuccess((List<Long>)value);
9556
        }
9557
        break;
9558
 
9559
      case ISEX:
9560
        if (value == null) {
9561
          unsetIsex();
9562
        } else {
9563
          setIsex((InventoryServiceException)value);
9564
        }
9565
        break;
9566
 
9567
      }
9568
    }
9569
 
9570
    public Object getFieldValue(_Fields field) {
9571
      switch (field) {
9572
      case SUCCESS:
9573
        return getSuccess();
9574
 
9575
      case ISEX:
9576
        return getIsex();
9577
 
9578
      }
9579
      throw new IllegalStateException();
9580
    }
9581
 
9582
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9583
    public boolean isSet(_Fields field) {
9584
      if (field == null) {
9585
        throw new IllegalArgumentException();
9586
      }
9587
 
9588
      switch (field) {
9589
      case SUCCESS:
9590
        return isSetSuccess();
9591
      case ISEX:
9592
        return isSetIsex();
9593
      }
9594
      throw new IllegalStateException();
9595
    }
9596
 
9597
    @Override
9598
    public boolean equals(Object that) {
9599
      if (that == null)
9600
        return false;
9601
      if (that instanceof getItemAvailabilityAtLocation_result)
9602
        return this.equals((getItemAvailabilityAtLocation_result)that);
9603
      return false;
9604
    }
9605
 
9606
    public boolean equals(getItemAvailabilityAtLocation_result that) {
9607
      if (that == null)
9608
        return false;
9609
 
9610
      boolean this_present_success = true && this.isSetSuccess();
9611
      boolean that_present_success = true && that.isSetSuccess();
9612
      if (this_present_success || that_present_success) {
9613
        if (!(this_present_success && that_present_success))
9614
          return false;
9615
        if (!this.success.equals(that.success))
9616
          return false;
9617
      }
9618
 
9619
      boolean this_present_isex = true && this.isSetIsex();
9620
      boolean that_present_isex = true && that.isSetIsex();
9621
      if (this_present_isex || that_present_isex) {
9622
        if (!(this_present_isex && that_present_isex))
9623
          return false;
9624
        if (!this.isex.equals(that.isex))
9625
          return false;
9626
      }
9627
 
9628
      return true;
9629
    }
9630
 
9631
    @Override
9632
    public int hashCode() {
9633
      return 0;
9634
    }
9635
 
9636
    public int compareTo(getItemAvailabilityAtLocation_result other) {
9637
      if (!getClass().equals(other.getClass())) {
9638
        return getClass().getName().compareTo(other.getClass().getName());
9639
      }
9640
 
9641
      int lastComparison = 0;
9642
      getItemAvailabilityAtLocation_result typedOther = (getItemAvailabilityAtLocation_result)other;
9643
 
9644
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
9645
      if (lastComparison != 0) {
9646
        return lastComparison;
9647
      }
9648
      if (isSetSuccess()) {
9649
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9650
        if (lastComparison != 0) {
9651
          return lastComparison;
9652
        }
9653
      }
9654
      lastComparison = Boolean.valueOf(isSetIsex()).compareTo(typedOther.isSetIsex());
9655
      if (lastComparison != 0) {
9656
        return lastComparison;
9657
      }
9658
      if (isSetIsex()) {
9659
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isex, typedOther.isex);
9660
        if (lastComparison != 0) {
9661
          return lastComparison;
9662
        }
9663
      }
9664
      return 0;
9665
    }
9666
 
9667
    public _Fields fieldForId(int fieldId) {
9668
      return _Fields.findByThriftId(fieldId);
9669
    }
9670
 
9671
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9672
      org.apache.thrift.protocol.TField field;
9673
      iprot.readStructBegin();
9674
      while (true)
9675
      {
9676
        field = iprot.readFieldBegin();
9677
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9678
          break;
9679
        }
9680
        switch (field.id) {
9681
          case 0: // SUCCESS
9682
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
9683
              {
9684
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
9685
                this.success = new ArrayList<Long>(_list20.size);
9686
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
9687
                {
9688
                  long _elem22; // required
9689
                  _elem22 = iprot.readI64();
9690
                  this.success.add(_elem22);
9691
                }
9692
                iprot.readListEnd();
9693
              }
9694
            } else { 
9695
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9696
            }
9697
            break;
9698
          case 1: // ISEX
9699
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9700
              this.isex = new InventoryServiceException();
9701
              this.isex.read(iprot);
9702
            } else { 
9703
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9704
            }
9705
            break;
9706
          default:
9707
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9708
        }
9709
        iprot.readFieldEnd();
9710
      }
9711
      iprot.readStructEnd();
9712
      validate();
9713
    }
9714
 
9715
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9716
      oprot.writeStructBegin(STRUCT_DESC);
9717
 
9718
      if (this.isSetSuccess()) {
9719
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9720
        {
9721
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
9722
          for (long _iter23 : this.success)
9723
          {
9724
            oprot.writeI64(_iter23);
9725
          }
9726
          oprot.writeListEnd();
9727
        }
9728
        oprot.writeFieldEnd();
9729
      } else if (this.isSetIsex()) {
9730
        oprot.writeFieldBegin(ISEX_FIELD_DESC);
9731
        this.isex.write(oprot);
9732
        oprot.writeFieldEnd();
9733
      }
9734
      oprot.writeFieldStop();
9735
      oprot.writeStructEnd();
9736
    }
9737
 
9738
    @Override
9739
    public String toString() {
9740
      StringBuilder sb = new StringBuilder("getItemAvailabilityAtLocation_result(");
9741
      boolean first = true;
9742
 
9743
      sb.append("success:");
9744
      if (this.success == null) {
9745
        sb.append("null");
9746
      } else {
9747
        sb.append(this.success);
9748
      }
9749
      first = false;
9750
      if (!first) sb.append(", ");
9751
      sb.append("isex:");
9752
      if (this.isex == null) {
9753
        sb.append("null");
9754
      } else {
9755
        sb.append(this.isex);
9756
      }
9757
      first = false;
9758
      sb.append(")");
9759
      return sb.toString();
9760
    }
9761
 
9762
    public void validate() throws org.apache.thrift.TException {
9763
      // check for required fields
9764
    }
9765
 
9766
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9767
      try {
9768
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9769
      } catch (org.apache.thrift.TException te) {
9770
        throw new java.io.IOException(te);
9771
      }
9772
    }
9773
 
9774
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9775
      try {
9776
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9777
      } catch (org.apache.thrift.TException te) {
9778
        throw new java.io.IOException(te);
9779
      }
9780
    }
9781
 
9782
  }
9783
 
9784
  public static class getAllWarehouses_args implements org.apache.thrift.TBase<getAllWarehouses_args, getAllWarehouses_args._Fields>, java.io.Serializable, Cloneable   {
9785
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllWarehouses_args");
9786
 
9787
    private static final org.apache.thrift.protocol.TField IS_ACTIVE_FIELD_DESC = new org.apache.thrift.protocol.TField("isActive", org.apache.thrift.protocol.TType.BOOL, (short)1);
9788
 
9789
    private boolean isActive; // required
9790
 
9791
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9792
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9793
      IS_ACTIVE((short)1, "isActive");
9794
 
9795
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9796
 
9797
      static {
9798
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9799
          byName.put(field.getFieldName(), field);
9800
        }
9801
      }
9802
 
9803
      /**
9804
       * Find the _Fields constant that matches fieldId, or null if its not found.
9805
       */
9806
      public static _Fields findByThriftId(int fieldId) {
9807
        switch(fieldId) {
9808
          case 1: // IS_ACTIVE
9809
            return IS_ACTIVE;
9810
          default:
9811
            return null;
9812
        }
9813
      }
9814
 
9815
      /**
9816
       * Find the _Fields constant that matches fieldId, throwing an exception
9817
       * if it is not found.
9818
       */
9819
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9820
        _Fields fields = findByThriftId(fieldId);
9821
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9822
        return fields;
9823
      }
9824
 
9825
      /**
9826
       * Find the _Fields constant that matches name, or null if its not found.
9827
       */
9828
      public static _Fields findByName(String name) {
9829
        return byName.get(name);
9830
      }
9831
 
9832
      private final short _thriftId;
9833
      private final String _fieldName;
9834
 
9835
      _Fields(short thriftId, String fieldName) {
9836
        _thriftId = thriftId;
9837
        _fieldName = fieldName;
9838
      }
9839
 
9840
      public short getThriftFieldId() {
9841
        return _thriftId;
9842
      }
9843
 
9844
      public String getFieldName() {
9845
        return _fieldName;
9846
      }
9847
    }
9848
 
9849
    // isset id assignments
9850
    private static final int __ISACTIVE_ISSET_ID = 0;
9851
    private BitSet __isset_bit_vector = new BitSet(1);
9852
 
9853
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9854
    static {
9855
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9856
      tmpMap.put(_Fields.IS_ACTIVE, new org.apache.thrift.meta_data.FieldMetaData("isActive", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9857
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
9858
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9859
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllWarehouses_args.class, metaDataMap);
9860
    }
9861
 
9862
    public getAllWarehouses_args() {
9863
    }
9864
 
9865
    public getAllWarehouses_args(
9866
      boolean isActive)
9867
    {
9868
      this();
9869
      this.isActive = isActive;
9870
      setIsActiveIsSet(true);
9871
    }
9872
 
9873
    /**
9874
     * Performs a deep copy on <i>other</i>.
9875
     */
9876
    public getAllWarehouses_args(getAllWarehouses_args other) {
9877
      __isset_bit_vector.clear();
9878
      __isset_bit_vector.or(other.__isset_bit_vector);
9879
      this.isActive = other.isActive;
9880
    }
9881
 
9882
    public getAllWarehouses_args deepCopy() {
9883
      return new getAllWarehouses_args(this);
9884
    }
9885
 
9886
    @Override
9887
    public void clear() {
9888
      setIsActiveIsSet(false);
9889
      this.isActive = false;
9890
    }
9891
 
9892
    public boolean isIsActive() {
9893
      return this.isActive;
9894
    }
9895
 
9896
    public void setIsActive(boolean isActive) {
9897
      this.isActive = isActive;
9898
      setIsActiveIsSet(true);
9899
    }
9900
 
9901
    public void unsetIsActive() {
9902
      __isset_bit_vector.clear(__ISACTIVE_ISSET_ID);
9903
    }
9904
 
9905
    /** Returns true if field isActive is set (has been assigned a value) and false otherwise */
9906
    public boolean isSetIsActive() {
9907
      return __isset_bit_vector.get(__ISACTIVE_ISSET_ID);
9908
    }
9909
 
9910
    public void setIsActiveIsSet(boolean value) {
9911
      __isset_bit_vector.set(__ISACTIVE_ISSET_ID, value);
9912
    }
9913
 
9914
    public void setFieldValue(_Fields field, Object value) {
9915
      switch (field) {
9916
      case IS_ACTIVE:
9917
        if (value == null) {
9918
          unsetIsActive();
9919
        } else {
9920
          setIsActive((Boolean)value);
9921
        }
9922
        break;
9923
 
9924
      }
9925
    }
9926
 
9927
    public Object getFieldValue(_Fields field) {
9928
      switch (field) {
9929
      case IS_ACTIVE:
9930
        return Boolean.valueOf(isIsActive());
9931
 
9932
      }
9933
      throw new IllegalStateException();
9934
    }
9935
 
9936
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9937
    public boolean isSet(_Fields field) {
9938
      if (field == null) {
9939
        throw new IllegalArgumentException();
9940
      }
9941
 
9942
      switch (field) {
9943
      case IS_ACTIVE:
9944
        return isSetIsActive();
9945
      }
9946
      throw new IllegalStateException();
9947
    }
9948
 
9949
    @Override
9950
    public boolean equals(Object that) {
9951
      if (that == null)
9952
        return false;
9953
      if (that instanceof getAllWarehouses_args)
9954
        return this.equals((getAllWarehouses_args)that);
9955
      return false;
9956
    }
9957
 
9958
    public boolean equals(getAllWarehouses_args that) {
9959
      if (that == null)
9960
        return false;
9961
 
9962
      boolean this_present_isActive = true;
9963
      boolean that_present_isActive = true;
9964
      if (this_present_isActive || that_present_isActive) {
9965
        if (!(this_present_isActive && that_present_isActive))
9966
          return false;
9967
        if (this.isActive != that.isActive)
9968
          return false;
9969
      }
9970
 
9971
      return true;
9972
    }
9973
 
9974
    @Override
9975
    public int hashCode() {
9976
      return 0;
9977
    }
9978
 
9979
    public int compareTo(getAllWarehouses_args other) {
9980
      if (!getClass().equals(other.getClass())) {
9981
        return getClass().getName().compareTo(other.getClass().getName());
9982
      }
9983
 
9984
      int lastComparison = 0;
9985
      getAllWarehouses_args typedOther = (getAllWarehouses_args)other;
9986
 
9987
      lastComparison = Boolean.valueOf(isSetIsActive()).compareTo(typedOther.isSetIsActive());
9988
      if (lastComparison != 0) {
9989
        return lastComparison;
9990
      }
9991
      if (isSetIsActive()) {
9992
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isActive, typedOther.isActive);
9993
        if (lastComparison != 0) {
9994
          return lastComparison;
9995
        }
9996
      }
9997
      return 0;
9998
    }
9999
 
10000
    public _Fields fieldForId(int fieldId) {
10001
      return _Fields.findByThriftId(fieldId);
10002
    }
10003
 
10004
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10005
      org.apache.thrift.protocol.TField field;
10006
      iprot.readStructBegin();
10007
      while (true)
10008
      {
10009
        field = iprot.readFieldBegin();
10010
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10011
          break;
10012
        }
10013
        switch (field.id) {
10014
          case 1: // IS_ACTIVE
10015
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
10016
              this.isActive = iprot.readBool();
10017
              setIsActiveIsSet(true);
10018
            } else { 
10019
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10020
            }
10021
            break;
10022
          default:
10023
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10024
        }
10025
        iprot.readFieldEnd();
10026
      }
10027
      iprot.readStructEnd();
10028
      validate();
10029
    }
10030
 
10031
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10032
      validate();
10033
 
10034
      oprot.writeStructBegin(STRUCT_DESC);
10035
      oprot.writeFieldBegin(IS_ACTIVE_FIELD_DESC);
10036
      oprot.writeBool(this.isActive);
10037
      oprot.writeFieldEnd();
10038
      oprot.writeFieldStop();
10039
      oprot.writeStructEnd();
10040
    }
10041
 
10042
    @Override
10043
    public String toString() {
10044
      StringBuilder sb = new StringBuilder("getAllWarehouses_args(");
10045
      boolean first = true;
10046
 
10047
      sb.append("isActive:");
10048
      sb.append(this.isActive);
10049
      first = false;
10050
      sb.append(")");
10051
      return sb.toString();
10052
    }
10053
 
10054
    public void validate() throws org.apache.thrift.TException {
10055
      // check for required fields
10056
    }
10057
 
10058
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10059
      try {
10060
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10061
      } catch (org.apache.thrift.TException te) {
10062
        throw new java.io.IOException(te);
10063
      }
10064
    }
10065
 
10066
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10067
      try {
10068
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
10069
        __isset_bit_vector = new BitSet(1);
10070
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10071
      } catch (org.apache.thrift.TException te) {
10072
        throw new java.io.IOException(te);
10073
      }
10074
    }
10075
 
10076
  }
10077
 
10078
  public static class getAllWarehouses_result implements org.apache.thrift.TBase<getAllWarehouses_result, getAllWarehouses_result._Fields>, java.io.Serializable, Cloneable   {
10079
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllWarehouses_result");
10080
 
10081
    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);
10082
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
10083
 
10084
    private List<Warehouse> success; // required
10085
    private InventoryServiceException cex; // required
10086
 
10087
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10088
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10089
      SUCCESS((short)0, "success"),
10090
      CEX((short)1, "cex");
10091
 
10092
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10093
 
10094
      static {
10095
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10096
          byName.put(field.getFieldName(), field);
10097
        }
10098
      }
10099
 
10100
      /**
10101
       * Find the _Fields constant that matches fieldId, or null if its not found.
10102
       */
10103
      public static _Fields findByThriftId(int fieldId) {
10104
        switch(fieldId) {
10105
          case 0: // SUCCESS
10106
            return SUCCESS;
10107
          case 1: // CEX
10108
            return CEX;
10109
          default:
10110
            return null;
10111
        }
10112
      }
10113
 
10114
      /**
10115
       * Find the _Fields constant that matches fieldId, throwing an exception
10116
       * if it is not found.
10117
       */
10118
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10119
        _Fields fields = findByThriftId(fieldId);
10120
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10121
        return fields;
10122
      }
10123
 
10124
      /**
10125
       * Find the _Fields constant that matches name, or null if its not found.
10126
       */
10127
      public static _Fields findByName(String name) {
10128
        return byName.get(name);
10129
      }
10130
 
10131
      private final short _thriftId;
10132
      private final String _fieldName;
10133
 
10134
      _Fields(short thriftId, String fieldName) {
10135
        _thriftId = thriftId;
10136
        _fieldName = fieldName;
10137
      }
10138
 
10139
      public short getThriftFieldId() {
10140
        return _thriftId;
10141
      }
10142
 
10143
      public String getFieldName() {
10144
        return _fieldName;
10145
      }
10146
    }
10147
 
10148
    // isset id assignments
10149
 
10150
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10151
    static {
10152
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10153
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10154
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
10155
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
10156
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10157
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
10158
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10159
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllWarehouses_result.class, metaDataMap);
10160
    }
10161
 
10162
    public getAllWarehouses_result() {
10163
    }
10164
 
10165
    public getAllWarehouses_result(
10166
      List<Warehouse> success,
10167
      InventoryServiceException cex)
10168
    {
10169
      this();
10170
      this.success = success;
10171
      this.cex = cex;
10172
    }
10173
 
10174
    /**
10175
     * Performs a deep copy on <i>other</i>.
10176
     */
10177
    public getAllWarehouses_result(getAllWarehouses_result other) {
10178
      if (other.isSetSuccess()) {
10179
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
10180
        for (Warehouse other_element : other.success) {
10181
          __this__success.add(new Warehouse(other_element));
10182
        }
10183
        this.success = __this__success;
10184
      }
10185
      if (other.isSetCex()) {
10186
        this.cex = new InventoryServiceException(other.cex);
10187
      }
10188
    }
10189
 
10190
    public getAllWarehouses_result deepCopy() {
10191
      return new getAllWarehouses_result(this);
10192
    }
10193
 
10194
    @Override
10195
    public void clear() {
10196
      this.success = null;
10197
      this.cex = null;
10198
    }
10199
 
10200
    public int getSuccessSize() {
10201
      return (this.success == null) ? 0 : this.success.size();
10202
    }
10203
 
10204
    public java.util.Iterator<Warehouse> getSuccessIterator() {
10205
      return (this.success == null) ? null : this.success.iterator();
10206
    }
10207
 
10208
    public void addToSuccess(Warehouse elem) {
10209
      if (this.success == null) {
10210
        this.success = new ArrayList<Warehouse>();
10211
      }
10212
      this.success.add(elem);
10213
    }
10214
 
10215
    public List<Warehouse> getSuccess() {
10216
      return this.success;
10217
    }
10218
 
10219
    public void setSuccess(List<Warehouse> success) {
10220
      this.success = success;
10221
    }
10222
 
10223
    public void unsetSuccess() {
10224
      this.success = null;
10225
    }
10226
 
10227
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
10228
    public boolean isSetSuccess() {
10229
      return this.success != null;
10230
    }
10231
 
10232
    public void setSuccessIsSet(boolean value) {
10233
      if (!value) {
10234
        this.success = null;
10235
      }
10236
    }
10237
 
10238
    public InventoryServiceException getCex() {
10239
      return this.cex;
10240
    }
10241
 
10242
    public void setCex(InventoryServiceException cex) {
10243
      this.cex = cex;
10244
    }
10245
 
10246
    public void unsetCex() {
10247
      this.cex = null;
10248
    }
10249
 
10250
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
10251
    public boolean isSetCex() {
10252
      return this.cex != null;
10253
    }
10254
 
10255
    public void setCexIsSet(boolean value) {
10256
      if (!value) {
10257
        this.cex = null;
10258
      }
10259
    }
10260
 
10261
    public void setFieldValue(_Fields field, Object value) {
10262
      switch (field) {
10263
      case SUCCESS:
10264
        if (value == null) {
10265
          unsetSuccess();
10266
        } else {
10267
          setSuccess((List<Warehouse>)value);
10268
        }
10269
        break;
10270
 
10271
      case CEX:
10272
        if (value == null) {
10273
          unsetCex();
10274
        } else {
10275
          setCex((InventoryServiceException)value);
10276
        }
10277
        break;
10278
 
10279
      }
10280
    }
10281
 
10282
    public Object getFieldValue(_Fields field) {
10283
      switch (field) {
10284
      case SUCCESS:
10285
        return getSuccess();
10286
 
10287
      case CEX:
10288
        return getCex();
10289
 
10290
      }
10291
      throw new IllegalStateException();
10292
    }
10293
 
10294
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10295
    public boolean isSet(_Fields field) {
10296
      if (field == null) {
10297
        throw new IllegalArgumentException();
10298
      }
10299
 
10300
      switch (field) {
10301
      case SUCCESS:
10302
        return isSetSuccess();
10303
      case CEX:
10304
        return isSetCex();
10305
      }
10306
      throw new IllegalStateException();
10307
    }
10308
 
10309
    @Override
10310
    public boolean equals(Object that) {
10311
      if (that == null)
10312
        return false;
10313
      if (that instanceof getAllWarehouses_result)
10314
        return this.equals((getAllWarehouses_result)that);
10315
      return false;
10316
    }
10317
 
10318
    public boolean equals(getAllWarehouses_result that) {
10319
      if (that == null)
10320
        return false;
10321
 
10322
      boolean this_present_success = true && this.isSetSuccess();
10323
      boolean that_present_success = true && that.isSetSuccess();
10324
      if (this_present_success || that_present_success) {
10325
        if (!(this_present_success && that_present_success))
10326
          return false;
10327
        if (!this.success.equals(that.success))
10328
          return false;
10329
      }
10330
 
10331
      boolean this_present_cex = true && this.isSetCex();
10332
      boolean that_present_cex = true && that.isSetCex();
10333
      if (this_present_cex || that_present_cex) {
10334
        if (!(this_present_cex && that_present_cex))
10335
          return false;
10336
        if (!this.cex.equals(that.cex))
10337
          return false;
10338
      }
10339
 
10340
      return true;
10341
    }
10342
 
10343
    @Override
10344
    public int hashCode() {
10345
      return 0;
10346
    }
10347
 
10348
    public int compareTo(getAllWarehouses_result other) {
10349
      if (!getClass().equals(other.getClass())) {
10350
        return getClass().getName().compareTo(other.getClass().getName());
10351
      }
10352
 
10353
      int lastComparison = 0;
10354
      getAllWarehouses_result typedOther = (getAllWarehouses_result)other;
10355
 
10356
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10357
      if (lastComparison != 0) {
10358
        return lastComparison;
10359
      }
10360
      if (isSetSuccess()) {
10361
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10362
        if (lastComparison != 0) {
10363
          return lastComparison;
10364
        }
10365
      }
10366
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
10367
      if (lastComparison != 0) {
10368
        return lastComparison;
10369
      }
10370
      if (isSetCex()) {
10371
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
10372
        if (lastComparison != 0) {
10373
          return lastComparison;
10374
        }
10375
      }
10376
      return 0;
10377
    }
10378
 
10379
    public _Fields fieldForId(int fieldId) {
10380
      return _Fields.findByThriftId(fieldId);
10381
    }
10382
 
10383
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10384
      org.apache.thrift.protocol.TField field;
10385
      iprot.readStructBegin();
10386
      while (true)
10387
      {
10388
        field = iprot.readFieldBegin();
10389
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10390
          break;
10391
        }
10392
        switch (field.id) {
10393
          case 0: // SUCCESS
10394
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
10395
              {
10396
                org.apache.thrift.protocol.TList _list24 = iprot.readListBegin();
10397
                this.success = new ArrayList<Warehouse>(_list24.size);
10398
                for (int _i25 = 0; _i25 < _list24.size; ++_i25)
10399
                {
10400
                  Warehouse _elem26; // required
10401
                  _elem26 = new Warehouse();
10402
                  _elem26.read(iprot);
10403
                  this.success.add(_elem26);
10404
                }
10405
                iprot.readListEnd();
10406
              }
10407
            } else { 
10408
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10409
            }
10410
            break;
10411
          case 1: // CEX
10412
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10413
              this.cex = new InventoryServiceException();
10414
              this.cex.read(iprot);
10415
            } else { 
10416
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10417
            }
10418
            break;
10419
          default:
10420
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10421
        }
10422
        iprot.readFieldEnd();
10423
      }
10424
      iprot.readStructEnd();
10425
      validate();
10426
    }
10427
 
10428
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10429
      oprot.writeStructBegin(STRUCT_DESC);
10430
 
10431
      if (this.isSetSuccess()) {
10432
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10433
        {
10434
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
10435
          for (Warehouse _iter27 : this.success)
10436
          {
10437
            _iter27.write(oprot);
10438
          }
10439
          oprot.writeListEnd();
10440
        }
10441
        oprot.writeFieldEnd();
10442
      } else if (this.isSetCex()) {
10443
        oprot.writeFieldBegin(CEX_FIELD_DESC);
10444
        this.cex.write(oprot);
10445
        oprot.writeFieldEnd();
10446
      }
10447
      oprot.writeFieldStop();
10448
      oprot.writeStructEnd();
10449
    }
10450
 
10451
    @Override
10452
    public String toString() {
10453
      StringBuilder sb = new StringBuilder("getAllWarehouses_result(");
10454
      boolean first = true;
10455
 
10456
      sb.append("success:");
10457
      if (this.success == null) {
10458
        sb.append("null");
10459
      } else {
10460
        sb.append(this.success);
10461
      }
10462
      first = false;
10463
      if (!first) sb.append(", ");
10464
      sb.append("cex:");
10465
      if (this.cex == null) {
10466
        sb.append("null");
10467
      } else {
10468
        sb.append(this.cex);
10469
      }
10470
      first = false;
10471
      sb.append(")");
10472
      return sb.toString();
10473
    }
10474
 
10475
    public void validate() throws org.apache.thrift.TException {
10476
      // check for required fields
10477
    }
10478
 
10479
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10480
      try {
10481
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10482
      } catch (org.apache.thrift.TException te) {
10483
        throw new java.io.IOException(te);
10484
      }
10485
    }
10486
 
10487
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10488
      try {
10489
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10490
      } catch (org.apache.thrift.TException te) {
10491
        throw new java.io.IOException(te);
10492
      }
10493
    }
10494
 
10495
  }
10496
 
10497
  public static class getWarehouse_args implements org.apache.thrift.TBase<getWarehouse_args, getWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
10498
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouse_args");
10499
 
10500
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouse_id", org.apache.thrift.protocol.TType.I64, (short)1);
10501
 
10502
    private long warehouse_id; // required
10503
 
10504
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10505
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10506
      WAREHOUSE_ID((short)1, "warehouse_id");
10507
 
10508
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10509
 
10510
      static {
10511
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10512
          byName.put(field.getFieldName(), field);
10513
        }
10514
      }
10515
 
10516
      /**
10517
       * Find the _Fields constant that matches fieldId, or null if its not found.
10518
       */
10519
      public static _Fields findByThriftId(int fieldId) {
10520
        switch(fieldId) {
10521
          case 1: // WAREHOUSE_ID
10522
            return WAREHOUSE_ID;
10523
          default:
10524
            return null;
10525
        }
10526
      }
10527
 
10528
      /**
10529
       * Find the _Fields constant that matches fieldId, throwing an exception
10530
       * if it is not found.
10531
       */
10532
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10533
        _Fields fields = findByThriftId(fieldId);
10534
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10535
        return fields;
10536
      }
10537
 
10538
      /**
10539
       * Find the _Fields constant that matches name, or null if its not found.
10540
       */
10541
      public static _Fields findByName(String name) {
10542
        return byName.get(name);
10543
      }
10544
 
10545
      private final short _thriftId;
10546
      private final String _fieldName;
10547
 
10548
      _Fields(short thriftId, String fieldName) {
10549
        _thriftId = thriftId;
10550
        _fieldName = fieldName;
10551
      }
10552
 
10553
      public short getThriftFieldId() {
10554
        return _thriftId;
10555
      }
10556
 
10557
      public String getFieldName() {
10558
        return _fieldName;
10559
      }
10560
    }
10561
 
10562
    // isset id assignments
10563
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
10564
    private BitSet __isset_bit_vector = new BitSet(1);
10565
 
10566
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10567
    static {
10568
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10569
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10570
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10571
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10572
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouse_args.class, metaDataMap);
10573
    }
10574
 
10575
    public getWarehouse_args() {
10576
    }
10577
 
10578
    public getWarehouse_args(
10579
      long warehouse_id)
10580
    {
10581
      this();
10582
      this.warehouse_id = warehouse_id;
10583
      setWarehouse_idIsSet(true);
10584
    }
10585
 
10586
    /**
10587
     * Performs a deep copy on <i>other</i>.
10588
     */
10589
    public getWarehouse_args(getWarehouse_args other) {
10590
      __isset_bit_vector.clear();
10591
      __isset_bit_vector.or(other.__isset_bit_vector);
10592
      this.warehouse_id = other.warehouse_id;
10593
    }
10594
 
10595
    public getWarehouse_args deepCopy() {
10596
      return new getWarehouse_args(this);
10597
    }
10598
 
10599
    @Override
10600
    public void clear() {
10601
      setWarehouse_idIsSet(false);
10602
      this.warehouse_id = 0;
10603
    }
10604
 
10605
    public long getWarehouse_id() {
10606
      return this.warehouse_id;
10607
    }
10608
 
10609
    public void setWarehouse_id(long warehouse_id) {
10610
      this.warehouse_id = warehouse_id;
10611
      setWarehouse_idIsSet(true);
10612
    }
10613
 
10614
    public void unsetWarehouse_id() {
10615
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
10616
    }
10617
 
10618
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
10619
    public boolean isSetWarehouse_id() {
10620
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
10621
    }
10622
 
10623
    public void setWarehouse_idIsSet(boolean value) {
10624
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
10625
    }
10626
 
10627
    public void setFieldValue(_Fields field, Object value) {
10628
      switch (field) {
10629
      case WAREHOUSE_ID:
10630
        if (value == null) {
10631
          unsetWarehouse_id();
10632
        } else {
10633
          setWarehouse_id((Long)value);
10634
        }
10635
        break;
10636
 
10637
      }
10638
    }
10639
 
10640
    public Object getFieldValue(_Fields field) {
10641
      switch (field) {
10642
      case WAREHOUSE_ID:
10643
        return Long.valueOf(getWarehouse_id());
10644
 
10645
      }
10646
      throw new IllegalStateException();
10647
    }
10648
 
10649
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10650
    public boolean isSet(_Fields field) {
10651
      if (field == null) {
10652
        throw new IllegalArgumentException();
10653
      }
10654
 
10655
      switch (field) {
10656
      case WAREHOUSE_ID:
10657
        return isSetWarehouse_id();
10658
      }
10659
      throw new IllegalStateException();
10660
    }
10661
 
10662
    @Override
10663
    public boolean equals(Object that) {
10664
      if (that == null)
10665
        return false;
10666
      if (that instanceof getWarehouse_args)
10667
        return this.equals((getWarehouse_args)that);
10668
      return false;
10669
    }
10670
 
10671
    public boolean equals(getWarehouse_args that) {
10672
      if (that == null)
10673
        return false;
10674
 
10675
      boolean this_present_warehouse_id = true;
10676
      boolean that_present_warehouse_id = true;
10677
      if (this_present_warehouse_id || that_present_warehouse_id) {
10678
        if (!(this_present_warehouse_id && that_present_warehouse_id))
10679
          return false;
10680
        if (this.warehouse_id != that.warehouse_id)
10681
          return false;
10682
      }
10683
 
10684
      return true;
10685
    }
10686
 
10687
    @Override
10688
    public int hashCode() {
10689
      return 0;
10690
    }
10691
 
10692
    public int compareTo(getWarehouse_args other) {
10693
      if (!getClass().equals(other.getClass())) {
10694
        return getClass().getName().compareTo(other.getClass().getName());
10695
      }
10696
 
10697
      int lastComparison = 0;
10698
      getWarehouse_args typedOther = (getWarehouse_args)other;
10699
 
10700
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
10701
      if (lastComparison != 0) {
10702
        return lastComparison;
10703
      }
10704
      if (isSetWarehouse_id()) {
10705
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
10706
        if (lastComparison != 0) {
10707
          return lastComparison;
10708
        }
10709
      }
10710
      return 0;
10711
    }
10712
 
10713
    public _Fields fieldForId(int fieldId) {
10714
      return _Fields.findByThriftId(fieldId);
10715
    }
10716
 
10717
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10718
      org.apache.thrift.protocol.TField field;
10719
      iprot.readStructBegin();
10720
      while (true)
10721
      {
10722
        field = iprot.readFieldBegin();
10723
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10724
          break;
10725
        }
10726
        switch (field.id) {
10727
          case 1: // WAREHOUSE_ID
10728
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10729
              this.warehouse_id = iprot.readI64();
10730
              setWarehouse_idIsSet(true);
10731
            } else { 
10732
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10733
            }
10734
            break;
10735
          default:
10736
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10737
        }
10738
        iprot.readFieldEnd();
10739
      }
10740
      iprot.readStructEnd();
10741
      validate();
10742
    }
10743
 
10744
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10745
      validate();
10746
 
10747
      oprot.writeStructBegin(STRUCT_DESC);
10748
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
10749
      oprot.writeI64(this.warehouse_id);
10750
      oprot.writeFieldEnd();
10751
      oprot.writeFieldStop();
10752
      oprot.writeStructEnd();
10753
    }
10754
 
10755
    @Override
10756
    public String toString() {
10757
      StringBuilder sb = new StringBuilder("getWarehouse_args(");
10758
      boolean first = true;
10759
 
10760
      sb.append("warehouse_id:");
10761
      sb.append(this.warehouse_id);
10762
      first = false;
10763
      sb.append(")");
10764
      return sb.toString();
10765
    }
10766
 
10767
    public void validate() throws org.apache.thrift.TException {
10768
      // check for required fields
10769
    }
10770
 
10771
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10772
      try {
10773
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10774
      } catch (org.apache.thrift.TException te) {
10775
        throw new java.io.IOException(te);
10776
      }
10777
    }
10778
 
10779
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10780
      try {
10781
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
10782
        __isset_bit_vector = new BitSet(1);
10783
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10784
      } catch (org.apache.thrift.TException te) {
10785
        throw new java.io.IOException(te);
10786
      }
10787
    }
10788
 
10789
  }
10790
 
10791
  public static class getWarehouse_result implements org.apache.thrift.TBase<getWarehouse_result, getWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
10792
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouse_result");
10793
 
10794
    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);
10795
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
10796
 
10797
    private Warehouse success; // required
10798
    private InventoryServiceException cex; // required
10799
 
10800
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10801
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10802
      SUCCESS((short)0, "success"),
10803
      CEX((short)1, "cex");
10804
 
10805
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10806
 
10807
      static {
10808
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10809
          byName.put(field.getFieldName(), field);
10810
        }
10811
      }
10812
 
10813
      /**
10814
       * Find the _Fields constant that matches fieldId, or null if its not found.
10815
       */
10816
      public static _Fields findByThriftId(int fieldId) {
10817
        switch(fieldId) {
10818
          case 0: // SUCCESS
10819
            return SUCCESS;
10820
          case 1: // CEX
10821
            return CEX;
10822
          default:
10823
            return null;
10824
        }
10825
      }
10826
 
10827
      /**
10828
       * Find the _Fields constant that matches fieldId, throwing an exception
10829
       * if it is not found.
10830
       */
10831
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10832
        _Fields fields = findByThriftId(fieldId);
10833
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10834
        return fields;
10835
      }
10836
 
10837
      /**
10838
       * Find the _Fields constant that matches name, or null if its not found.
10839
       */
10840
      public static _Fields findByName(String name) {
10841
        return byName.get(name);
10842
      }
10843
 
10844
      private final short _thriftId;
10845
      private final String _fieldName;
10846
 
10847
      _Fields(short thriftId, String fieldName) {
10848
        _thriftId = thriftId;
10849
        _fieldName = fieldName;
10850
      }
10851
 
10852
      public short getThriftFieldId() {
10853
        return _thriftId;
10854
      }
10855
 
10856
      public String getFieldName() {
10857
        return _fieldName;
10858
      }
10859
    }
10860
 
10861
    // isset id assignments
10862
 
10863
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10864
    static {
10865
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10866
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10867
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class)));
10868
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10869
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
10870
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10871
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouse_result.class, metaDataMap);
10872
    }
10873
 
10874
    public getWarehouse_result() {
10875
    }
10876
 
10877
    public getWarehouse_result(
10878
      Warehouse success,
10879
      InventoryServiceException cex)
10880
    {
10881
      this();
10882
      this.success = success;
10883
      this.cex = cex;
10884
    }
10885
 
10886
    /**
10887
     * Performs a deep copy on <i>other</i>.
10888
     */
10889
    public getWarehouse_result(getWarehouse_result other) {
10890
      if (other.isSetSuccess()) {
10891
        this.success = new Warehouse(other.success);
10892
      }
10893
      if (other.isSetCex()) {
10894
        this.cex = new InventoryServiceException(other.cex);
10895
      }
10896
    }
10897
 
10898
    public getWarehouse_result deepCopy() {
10899
      return new getWarehouse_result(this);
10900
    }
10901
 
10902
    @Override
10903
    public void clear() {
10904
      this.success = null;
10905
      this.cex = null;
10906
    }
10907
 
10908
    public Warehouse getSuccess() {
10909
      return this.success;
10910
    }
10911
 
10912
    public void setSuccess(Warehouse success) {
10913
      this.success = success;
10914
    }
10915
 
10916
    public void unsetSuccess() {
10917
      this.success = null;
10918
    }
10919
 
10920
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
10921
    public boolean isSetSuccess() {
10922
      return this.success != null;
10923
    }
10924
 
10925
    public void setSuccessIsSet(boolean value) {
10926
      if (!value) {
10927
        this.success = null;
10928
      }
10929
    }
10930
 
10931
    public InventoryServiceException getCex() {
10932
      return this.cex;
10933
    }
10934
 
10935
    public void setCex(InventoryServiceException cex) {
10936
      this.cex = cex;
10937
    }
10938
 
10939
    public void unsetCex() {
10940
      this.cex = null;
10941
    }
10942
 
10943
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
10944
    public boolean isSetCex() {
10945
      return this.cex != null;
10946
    }
10947
 
10948
    public void setCexIsSet(boolean value) {
10949
      if (!value) {
10950
        this.cex = null;
10951
      }
10952
    }
10953
 
10954
    public void setFieldValue(_Fields field, Object value) {
10955
      switch (field) {
10956
      case SUCCESS:
10957
        if (value == null) {
10958
          unsetSuccess();
10959
        } else {
10960
          setSuccess((Warehouse)value);
10961
        }
10962
        break;
10963
 
10964
      case CEX:
10965
        if (value == null) {
10966
          unsetCex();
10967
        } else {
10968
          setCex((InventoryServiceException)value);
10969
        }
10970
        break;
10971
 
10972
      }
10973
    }
10974
 
10975
    public Object getFieldValue(_Fields field) {
10976
      switch (field) {
10977
      case SUCCESS:
10978
        return getSuccess();
10979
 
10980
      case CEX:
10981
        return getCex();
10982
 
10983
      }
10984
      throw new IllegalStateException();
10985
    }
10986
 
10987
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10988
    public boolean isSet(_Fields field) {
10989
      if (field == null) {
10990
        throw new IllegalArgumentException();
10991
      }
10992
 
10993
      switch (field) {
10994
      case SUCCESS:
10995
        return isSetSuccess();
10996
      case CEX:
10997
        return isSetCex();
10998
      }
10999
      throw new IllegalStateException();
11000
    }
11001
 
11002
    @Override
11003
    public boolean equals(Object that) {
11004
      if (that == null)
11005
        return false;
11006
      if (that instanceof getWarehouse_result)
11007
        return this.equals((getWarehouse_result)that);
11008
      return false;
11009
    }
11010
 
11011
    public boolean equals(getWarehouse_result that) {
11012
      if (that == null)
11013
        return false;
11014
 
11015
      boolean this_present_success = true && this.isSetSuccess();
11016
      boolean that_present_success = true && that.isSetSuccess();
11017
      if (this_present_success || that_present_success) {
11018
        if (!(this_present_success && that_present_success))
11019
          return false;
11020
        if (!this.success.equals(that.success))
11021
          return false;
11022
      }
11023
 
11024
      boolean this_present_cex = true && this.isSetCex();
11025
      boolean that_present_cex = true && that.isSetCex();
11026
      if (this_present_cex || that_present_cex) {
11027
        if (!(this_present_cex && that_present_cex))
11028
          return false;
11029
        if (!this.cex.equals(that.cex))
11030
          return false;
11031
      }
11032
 
11033
      return true;
11034
    }
11035
 
11036
    @Override
11037
    public int hashCode() {
11038
      return 0;
11039
    }
11040
 
11041
    public int compareTo(getWarehouse_result other) {
11042
      if (!getClass().equals(other.getClass())) {
11043
        return getClass().getName().compareTo(other.getClass().getName());
11044
      }
11045
 
11046
      int lastComparison = 0;
11047
      getWarehouse_result typedOther = (getWarehouse_result)other;
11048
 
11049
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
11050
      if (lastComparison != 0) {
11051
        return lastComparison;
11052
      }
11053
      if (isSetSuccess()) {
11054
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11055
        if (lastComparison != 0) {
11056
          return lastComparison;
11057
        }
11058
      }
11059
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
11060
      if (lastComparison != 0) {
11061
        return lastComparison;
11062
      }
11063
      if (isSetCex()) {
11064
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
11065
        if (lastComparison != 0) {
11066
          return lastComparison;
11067
        }
11068
      }
11069
      return 0;
11070
    }
11071
 
11072
    public _Fields fieldForId(int fieldId) {
11073
      return _Fields.findByThriftId(fieldId);
11074
    }
11075
 
11076
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11077
      org.apache.thrift.protocol.TField field;
11078
      iprot.readStructBegin();
11079
      while (true)
11080
      {
11081
        field = iprot.readFieldBegin();
11082
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11083
          break;
11084
        }
11085
        switch (field.id) {
11086
          case 0: // SUCCESS
11087
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11088
              this.success = new Warehouse();
11089
              this.success.read(iprot);
11090
            } else { 
11091
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11092
            }
11093
            break;
11094
          case 1: // CEX
11095
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11096
              this.cex = new InventoryServiceException();
11097
              this.cex.read(iprot);
11098
            } else { 
11099
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11100
            }
11101
            break;
11102
          default:
11103
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11104
        }
11105
        iprot.readFieldEnd();
11106
      }
11107
      iprot.readStructEnd();
11108
      validate();
11109
    }
11110
 
11111
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11112
      oprot.writeStructBegin(STRUCT_DESC);
11113
 
11114
      if (this.isSetSuccess()) {
11115
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11116
        this.success.write(oprot);
11117
        oprot.writeFieldEnd();
11118
      } else if (this.isSetCex()) {
11119
        oprot.writeFieldBegin(CEX_FIELD_DESC);
11120
        this.cex.write(oprot);
11121
        oprot.writeFieldEnd();
11122
      }
11123
      oprot.writeFieldStop();
11124
      oprot.writeStructEnd();
11125
    }
11126
 
11127
    @Override
11128
    public String toString() {
11129
      StringBuilder sb = new StringBuilder("getWarehouse_result(");
11130
      boolean first = true;
11131
 
11132
      sb.append("success:");
11133
      if (this.success == null) {
11134
        sb.append("null");
11135
      } else {
11136
        sb.append(this.success);
11137
      }
11138
      first = false;
11139
      if (!first) sb.append(", ");
11140
      sb.append("cex:");
11141
      if (this.cex == null) {
11142
        sb.append("null");
11143
      } else {
11144
        sb.append(this.cex);
11145
      }
11146
      first = false;
11147
      sb.append(")");
11148
      return sb.toString();
11149
    }
11150
 
11151
    public void validate() throws org.apache.thrift.TException {
11152
      // check for required fields
11153
    }
11154
 
11155
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11156
      try {
11157
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11158
      } catch (org.apache.thrift.TException te) {
11159
        throw new java.io.IOException(te);
11160
      }
11161
    }
11162
 
11163
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11164
      try {
11165
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11166
      } catch (org.apache.thrift.TException te) {
11167
        throw new java.io.IOException(te);
11168
      }
11169
    }
11170
 
11171
  }
11172
 
11173
  public static class getAllItemsForWarehouse_args implements org.apache.thrift.TBase<getAllItemsForWarehouse_args, getAllItemsForWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
11174
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemsForWarehouse_args");
11175
 
11176
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouse_id", org.apache.thrift.protocol.TType.I64, (short)1);
11177
 
11178
    private long warehouse_id; // required
11179
 
11180
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11181
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11182
      WAREHOUSE_ID((short)1, "warehouse_id");
11183
 
11184
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11185
 
11186
      static {
11187
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11188
          byName.put(field.getFieldName(), field);
11189
        }
11190
      }
11191
 
11192
      /**
11193
       * Find the _Fields constant that matches fieldId, or null if its not found.
11194
       */
11195
      public static _Fields findByThriftId(int fieldId) {
11196
        switch(fieldId) {
11197
          case 1: // WAREHOUSE_ID
11198
            return WAREHOUSE_ID;
11199
          default:
11200
            return null;
11201
        }
11202
      }
11203
 
11204
      /**
11205
       * Find the _Fields constant that matches fieldId, throwing an exception
11206
       * if it is not found.
11207
       */
11208
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11209
        _Fields fields = findByThriftId(fieldId);
11210
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11211
        return fields;
11212
      }
11213
 
11214
      /**
11215
       * Find the _Fields constant that matches name, or null if its not found.
11216
       */
11217
      public static _Fields findByName(String name) {
11218
        return byName.get(name);
11219
      }
11220
 
11221
      private final short _thriftId;
11222
      private final String _fieldName;
11223
 
11224
      _Fields(short thriftId, String fieldName) {
11225
        _thriftId = thriftId;
11226
        _fieldName = fieldName;
11227
      }
11228
 
11229
      public short getThriftFieldId() {
11230
        return _thriftId;
11231
      }
11232
 
11233
      public String getFieldName() {
11234
        return _fieldName;
11235
      }
11236
    }
11237
 
11238
    // isset id assignments
11239
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
11240
    private BitSet __isset_bit_vector = new BitSet(1);
11241
 
11242
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11243
    static {
11244
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11245
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11246
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11247
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11248
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemsForWarehouse_args.class, metaDataMap);
11249
    }
11250
 
11251
    public getAllItemsForWarehouse_args() {
11252
    }
11253
 
11254
    public getAllItemsForWarehouse_args(
11255
      long warehouse_id)
11256
    {
11257
      this();
11258
      this.warehouse_id = warehouse_id;
11259
      setWarehouse_idIsSet(true);
11260
    }
11261
 
11262
    /**
11263
     * Performs a deep copy on <i>other</i>.
11264
     */
11265
    public getAllItemsForWarehouse_args(getAllItemsForWarehouse_args other) {
11266
      __isset_bit_vector.clear();
11267
      __isset_bit_vector.or(other.__isset_bit_vector);
11268
      this.warehouse_id = other.warehouse_id;
11269
    }
11270
 
11271
    public getAllItemsForWarehouse_args deepCopy() {
11272
      return new getAllItemsForWarehouse_args(this);
11273
    }
11274
 
11275
    @Override
11276
    public void clear() {
11277
      setWarehouse_idIsSet(false);
11278
      this.warehouse_id = 0;
11279
    }
11280
 
11281
    public long getWarehouse_id() {
11282
      return this.warehouse_id;
11283
    }
11284
 
11285
    public void setWarehouse_id(long warehouse_id) {
11286
      this.warehouse_id = warehouse_id;
11287
      setWarehouse_idIsSet(true);
11288
    }
11289
 
11290
    public void unsetWarehouse_id() {
11291
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
11292
    }
11293
 
11294
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
11295
    public boolean isSetWarehouse_id() {
11296
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
11297
    }
11298
 
11299
    public void setWarehouse_idIsSet(boolean value) {
11300
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
11301
    }
11302
 
11303
    public void setFieldValue(_Fields field, Object value) {
11304
      switch (field) {
11305
      case WAREHOUSE_ID:
11306
        if (value == null) {
11307
          unsetWarehouse_id();
11308
        } else {
11309
          setWarehouse_id((Long)value);
11310
        }
11311
        break;
11312
 
11313
      }
11314
    }
11315
 
11316
    public Object getFieldValue(_Fields field) {
11317
      switch (field) {
11318
      case WAREHOUSE_ID:
11319
        return Long.valueOf(getWarehouse_id());
11320
 
11321
      }
11322
      throw new IllegalStateException();
11323
    }
11324
 
11325
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11326
    public boolean isSet(_Fields field) {
11327
      if (field == null) {
11328
        throw new IllegalArgumentException();
11329
      }
11330
 
11331
      switch (field) {
11332
      case WAREHOUSE_ID:
11333
        return isSetWarehouse_id();
11334
      }
11335
      throw new IllegalStateException();
11336
    }
11337
 
11338
    @Override
11339
    public boolean equals(Object that) {
11340
      if (that == null)
11341
        return false;
11342
      if (that instanceof getAllItemsForWarehouse_args)
11343
        return this.equals((getAllItemsForWarehouse_args)that);
11344
      return false;
11345
    }
11346
 
11347
    public boolean equals(getAllItemsForWarehouse_args that) {
11348
      if (that == null)
11349
        return false;
11350
 
11351
      boolean this_present_warehouse_id = true;
11352
      boolean that_present_warehouse_id = true;
11353
      if (this_present_warehouse_id || that_present_warehouse_id) {
11354
        if (!(this_present_warehouse_id && that_present_warehouse_id))
11355
          return false;
11356
        if (this.warehouse_id != that.warehouse_id)
11357
          return false;
11358
      }
11359
 
11360
      return true;
11361
    }
11362
 
11363
    @Override
11364
    public int hashCode() {
11365
      return 0;
11366
    }
11367
 
11368
    public int compareTo(getAllItemsForWarehouse_args other) {
11369
      if (!getClass().equals(other.getClass())) {
11370
        return getClass().getName().compareTo(other.getClass().getName());
11371
      }
11372
 
11373
      int lastComparison = 0;
11374
      getAllItemsForWarehouse_args typedOther = (getAllItemsForWarehouse_args)other;
11375
 
11376
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
11377
      if (lastComparison != 0) {
11378
        return lastComparison;
11379
      }
11380
      if (isSetWarehouse_id()) {
11381
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
11382
        if (lastComparison != 0) {
11383
          return lastComparison;
11384
        }
11385
      }
11386
      return 0;
11387
    }
11388
 
11389
    public _Fields fieldForId(int fieldId) {
11390
      return _Fields.findByThriftId(fieldId);
11391
    }
11392
 
11393
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11394
      org.apache.thrift.protocol.TField field;
11395
      iprot.readStructBegin();
11396
      while (true)
11397
      {
11398
        field = iprot.readFieldBegin();
11399
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11400
          break;
11401
        }
11402
        switch (field.id) {
11403
          case 1: // WAREHOUSE_ID
11404
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11405
              this.warehouse_id = iprot.readI64();
11406
              setWarehouse_idIsSet(true);
11407
            } else { 
11408
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11409
            }
11410
            break;
11411
          default:
11412
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11413
        }
11414
        iprot.readFieldEnd();
11415
      }
11416
      iprot.readStructEnd();
11417
      validate();
11418
    }
11419
 
11420
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11421
      validate();
11422
 
11423
      oprot.writeStructBegin(STRUCT_DESC);
11424
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
11425
      oprot.writeI64(this.warehouse_id);
11426
      oprot.writeFieldEnd();
11427
      oprot.writeFieldStop();
11428
      oprot.writeStructEnd();
11429
    }
11430
 
11431
    @Override
11432
    public String toString() {
11433
      StringBuilder sb = new StringBuilder("getAllItemsForWarehouse_args(");
11434
      boolean first = true;
11435
 
11436
      sb.append("warehouse_id:");
11437
      sb.append(this.warehouse_id);
11438
      first = false;
11439
      sb.append(")");
11440
      return sb.toString();
11441
    }
11442
 
11443
    public void validate() throws org.apache.thrift.TException {
11444
      // check for required fields
11445
    }
11446
 
11447
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11448
      try {
11449
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11450
      } catch (org.apache.thrift.TException te) {
11451
        throw new java.io.IOException(te);
11452
      }
11453
    }
11454
 
11455
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11456
      try {
11457
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
11458
        __isset_bit_vector = new BitSet(1);
11459
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11460
      } catch (org.apache.thrift.TException te) {
11461
        throw new java.io.IOException(te);
11462
      }
11463
    }
11464
 
11465
  }
11466
 
11467
  public static class getAllItemsForWarehouse_result implements org.apache.thrift.TBase<getAllItemsForWarehouse_result, getAllItemsForWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
11468
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemsForWarehouse_result");
11469
 
11470
    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);
11471
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
11472
 
11473
    private List<Long> success; // required
11474
    private InventoryServiceException cex; // required
11475
 
11476
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11477
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11478
      SUCCESS((short)0, "success"),
11479
      CEX((short)1, "cex");
11480
 
11481
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11482
 
11483
      static {
11484
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11485
          byName.put(field.getFieldName(), field);
11486
        }
11487
      }
11488
 
11489
      /**
11490
       * Find the _Fields constant that matches fieldId, or null if its not found.
11491
       */
11492
      public static _Fields findByThriftId(int fieldId) {
11493
        switch(fieldId) {
11494
          case 0: // SUCCESS
11495
            return SUCCESS;
11496
          case 1: // CEX
11497
            return CEX;
11498
          default:
11499
            return null;
11500
        }
11501
      }
11502
 
11503
      /**
11504
       * Find the _Fields constant that matches fieldId, throwing an exception
11505
       * if it is not found.
11506
       */
11507
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11508
        _Fields fields = findByThriftId(fieldId);
11509
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11510
        return fields;
11511
      }
11512
 
11513
      /**
11514
       * Find the _Fields constant that matches name, or null if its not found.
11515
       */
11516
      public static _Fields findByName(String name) {
11517
        return byName.get(name);
11518
      }
11519
 
11520
      private final short _thriftId;
11521
      private final String _fieldName;
11522
 
11523
      _Fields(short thriftId, String fieldName) {
11524
        _thriftId = thriftId;
11525
        _fieldName = fieldName;
11526
      }
11527
 
11528
      public short getThriftFieldId() {
11529
        return _thriftId;
11530
      }
11531
 
11532
      public String getFieldName() {
11533
        return _fieldName;
11534
      }
11535
    }
11536
 
11537
    // isset id assignments
11538
 
11539
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11540
    static {
11541
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11542
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11543
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
11544
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
11545
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11546
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
11547
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11548
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemsForWarehouse_result.class, metaDataMap);
11549
    }
11550
 
11551
    public getAllItemsForWarehouse_result() {
11552
    }
11553
 
11554
    public getAllItemsForWarehouse_result(
11555
      List<Long> success,
11556
      InventoryServiceException cex)
11557
    {
11558
      this();
11559
      this.success = success;
11560
      this.cex = cex;
11561
    }
11562
 
11563
    /**
11564
     * Performs a deep copy on <i>other</i>.
11565
     */
11566
    public getAllItemsForWarehouse_result(getAllItemsForWarehouse_result other) {
11567
      if (other.isSetSuccess()) {
11568
        List<Long> __this__success = new ArrayList<Long>();
11569
        for (Long other_element : other.success) {
11570
          __this__success.add(other_element);
11571
        }
11572
        this.success = __this__success;
11573
      }
11574
      if (other.isSetCex()) {
11575
        this.cex = new InventoryServiceException(other.cex);
11576
      }
11577
    }
11578
 
11579
    public getAllItemsForWarehouse_result deepCopy() {
11580
      return new getAllItemsForWarehouse_result(this);
11581
    }
11582
 
11583
    @Override
11584
    public void clear() {
11585
      this.success = null;
11586
      this.cex = null;
11587
    }
11588
 
11589
    public int getSuccessSize() {
11590
      return (this.success == null) ? 0 : this.success.size();
11591
    }
11592
 
11593
    public java.util.Iterator<Long> getSuccessIterator() {
11594
      return (this.success == null) ? null : this.success.iterator();
11595
    }
11596
 
11597
    public void addToSuccess(long elem) {
11598
      if (this.success == null) {
11599
        this.success = new ArrayList<Long>();
11600
      }
11601
      this.success.add(elem);
11602
    }
11603
 
11604
    public List<Long> getSuccess() {
11605
      return this.success;
11606
    }
11607
 
11608
    public void setSuccess(List<Long> success) {
11609
      this.success = success;
11610
    }
11611
 
11612
    public void unsetSuccess() {
11613
      this.success = null;
11614
    }
11615
 
11616
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
11617
    public boolean isSetSuccess() {
11618
      return this.success != null;
11619
    }
11620
 
11621
    public void setSuccessIsSet(boolean value) {
11622
      if (!value) {
11623
        this.success = null;
11624
      }
11625
    }
11626
 
11627
    public InventoryServiceException getCex() {
11628
      return this.cex;
11629
    }
11630
 
11631
    public void setCex(InventoryServiceException cex) {
11632
      this.cex = cex;
11633
    }
11634
 
11635
    public void unsetCex() {
11636
      this.cex = null;
11637
    }
11638
 
11639
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
11640
    public boolean isSetCex() {
11641
      return this.cex != null;
11642
    }
11643
 
11644
    public void setCexIsSet(boolean value) {
11645
      if (!value) {
11646
        this.cex = null;
11647
      }
11648
    }
11649
 
11650
    public void setFieldValue(_Fields field, Object value) {
11651
      switch (field) {
11652
      case SUCCESS:
11653
        if (value == null) {
11654
          unsetSuccess();
11655
        } else {
11656
          setSuccess((List<Long>)value);
11657
        }
11658
        break;
11659
 
11660
      case CEX:
11661
        if (value == null) {
11662
          unsetCex();
11663
        } else {
11664
          setCex((InventoryServiceException)value);
11665
        }
11666
        break;
11667
 
11668
      }
11669
    }
11670
 
11671
    public Object getFieldValue(_Fields field) {
11672
      switch (field) {
11673
      case SUCCESS:
11674
        return getSuccess();
11675
 
11676
      case CEX:
11677
        return getCex();
11678
 
11679
      }
11680
      throw new IllegalStateException();
11681
    }
11682
 
11683
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11684
    public boolean isSet(_Fields field) {
11685
      if (field == null) {
11686
        throw new IllegalArgumentException();
11687
      }
11688
 
11689
      switch (field) {
11690
      case SUCCESS:
11691
        return isSetSuccess();
11692
      case CEX:
11693
        return isSetCex();
11694
      }
11695
      throw new IllegalStateException();
11696
    }
11697
 
11698
    @Override
11699
    public boolean equals(Object that) {
11700
      if (that == null)
11701
        return false;
11702
      if (that instanceof getAllItemsForWarehouse_result)
11703
        return this.equals((getAllItemsForWarehouse_result)that);
11704
      return false;
11705
    }
11706
 
11707
    public boolean equals(getAllItemsForWarehouse_result that) {
11708
      if (that == null)
11709
        return false;
11710
 
11711
      boolean this_present_success = true && this.isSetSuccess();
11712
      boolean that_present_success = true && that.isSetSuccess();
11713
      if (this_present_success || that_present_success) {
11714
        if (!(this_present_success && that_present_success))
11715
          return false;
11716
        if (!this.success.equals(that.success))
11717
          return false;
11718
      }
11719
 
11720
      boolean this_present_cex = true && this.isSetCex();
11721
      boolean that_present_cex = true && that.isSetCex();
11722
      if (this_present_cex || that_present_cex) {
11723
        if (!(this_present_cex && that_present_cex))
11724
          return false;
11725
        if (!this.cex.equals(that.cex))
11726
          return false;
11727
      }
11728
 
11729
      return true;
11730
    }
11731
 
11732
    @Override
11733
    public int hashCode() {
11734
      return 0;
11735
    }
11736
 
11737
    public int compareTo(getAllItemsForWarehouse_result other) {
11738
      if (!getClass().equals(other.getClass())) {
11739
        return getClass().getName().compareTo(other.getClass().getName());
11740
      }
11741
 
11742
      int lastComparison = 0;
11743
      getAllItemsForWarehouse_result typedOther = (getAllItemsForWarehouse_result)other;
11744
 
11745
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
11746
      if (lastComparison != 0) {
11747
        return lastComparison;
11748
      }
11749
      if (isSetSuccess()) {
11750
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11751
        if (lastComparison != 0) {
11752
          return lastComparison;
11753
        }
11754
      }
11755
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
11756
      if (lastComparison != 0) {
11757
        return lastComparison;
11758
      }
11759
      if (isSetCex()) {
11760
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
11761
        if (lastComparison != 0) {
11762
          return lastComparison;
11763
        }
11764
      }
11765
      return 0;
11766
    }
11767
 
11768
    public _Fields fieldForId(int fieldId) {
11769
      return _Fields.findByThriftId(fieldId);
11770
    }
11771
 
11772
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11773
      org.apache.thrift.protocol.TField field;
11774
      iprot.readStructBegin();
11775
      while (true)
11776
      {
11777
        field = iprot.readFieldBegin();
11778
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11779
          break;
11780
        }
11781
        switch (field.id) {
11782
          case 0: // SUCCESS
11783
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
11784
              {
11785
                org.apache.thrift.protocol.TList _list28 = iprot.readListBegin();
11786
                this.success = new ArrayList<Long>(_list28.size);
11787
                for (int _i29 = 0; _i29 < _list28.size; ++_i29)
11788
                {
11789
                  long _elem30; // required
11790
                  _elem30 = iprot.readI64();
11791
                  this.success.add(_elem30);
11792
                }
11793
                iprot.readListEnd();
11794
              }
11795
            } else { 
11796
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11797
            }
11798
            break;
11799
          case 1: // CEX
11800
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11801
              this.cex = new InventoryServiceException();
11802
              this.cex.read(iprot);
11803
            } else { 
11804
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11805
            }
11806
            break;
11807
          default:
11808
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11809
        }
11810
        iprot.readFieldEnd();
11811
      }
11812
      iprot.readStructEnd();
11813
      validate();
11814
    }
11815
 
11816
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11817
      oprot.writeStructBegin(STRUCT_DESC);
11818
 
11819
      if (this.isSetSuccess()) {
11820
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11821
        {
11822
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
11823
          for (long _iter31 : this.success)
11824
          {
11825
            oprot.writeI64(_iter31);
11826
          }
11827
          oprot.writeListEnd();
11828
        }
11829
        oprot.writeFieldEnd();
11830
      } else if (this.isSetCex()) {
11831
        oprot.writeFieldBegin(CEX_FIELD_DESC);
11832
        this.cex.write(oprot);
11833
        oprot.writeFieldEnd();
11834
      }
11835
      oprot.writeFieldStop();
11836
      oprot.writeStructEnd();
11837
    }
11838
 
11839
    @Override
11840
    public String toString() {
11841
      StringBuilder sb = new StringBuilder("getAllItemsForWarehouse_result(");
11842
      boolean first = true;
11843
 
11844
      sb.append("success:");
11845
      if (this.success == null) {
11846
        sb.append("null");
11847
      } else {
11848
        sb.append(this.success);
11849
      }
11850
      first = false;
11851
      if (!first) sb.append(", ");
11852
      sb.append("cex:");
11853
      if (this.cex == null) {
11854
        sb.append("null");
11855
      } else {
11856
        sb.append(this.cex);
11857
      }
11858
      first = false;
11859
      sb.append(")");
11860
      return sb.toString();
11861
    }
11862
 
11863
    public void validate() throws org.apache.thrift.TException {
11864
      // check for required fields
11865
    }
11866
 
11867
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11868
      try {
11869
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11870
      } catch (org.apache.thrift.TException te) {
11871
        throw new java.io.IOException(te);
11872
      }
11873
    }
11874
 
11875
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11876
      try {
11877
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11878
      } catch (org.apache.thrift.TException te) {
11879
        throw new java.io.IOException(te);
11880
      }
11881
    }
11882
 
11883
  }
11884
 
5967 rajveer 11885
  public static class isOrderBillable_args implements org.apache.thrift.TBase<isOrderBillable_args, isOrderBillable_args._Fields>, java.io.Serializable, Cloneable   {
11886
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("isOrderBillable_args");
11887
 
11888
    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);
11889
    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)2);
11890
    private static final org.apache.thrift.protocol.TField SOURCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sourceId", org.apache.thrift.protocol.TType.I64, (short)3);
11891
    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);
11892
 
11893
    private long itemId; // required
11894
    private long warehouseId; // required
11895
    private long sourceId; // required
11896
    private long orderId; // required
11897
 
11898
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11899
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11900
      ITEM_ID((short)1, "itemId"),
11901
      WAREHOUSE_ID((short)2, "warehouseId"),
11902
      SOURCE_ID((short)3, "sourceId"),
11903
      ORDER_ID((short)4, "orderId");
11904
 
11905
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11906
 
11907
      static {
11908
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11909
          byName.put(field.getFieldName(), field);
11910
        }
11911
      }
11912
 
11913
      /**
11914
       * Find the _Fields constant that matches fieldId, or null if its not found.
11915
       */
11916
      public static _Fields findByThriftId(int fieldId) {
11917
        switch(fieldId) {
11918
          case 1: // ITEM_ID
11919
            return ITEM_ID;
11920
          case 2: // WAREHOUSE_ID
11921
            return WAREHOUSE_ID;
11922
          case 3: // SOURCE_ID
11923
            return SOURCE_ID;
11924
          case 4: // ORDER_ID
11925
            return ORDER_ID;
11926
          default:
11927
            return null;
11928
        }
11929
      }
11930
 
11931
      /**
11932
       * Find the _Fields constant that matches fieldId, throwing an exception
11933
       * if it is not found.
11934
       */
11935
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11936
        _Fields fields = findByThriftId(fieldId);
11937
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11938
        return fields;
11939
      }
11940
 
11941
      /**
11942
       * Find the _Fields constant that matches name, or null if its not found.
11943
       */
11944
      public static _Fields findByName(String name) {
11945
        return byName.get(name);
11946
      }
11947
 
11948
      private final short _thriftId;
11949
      private final String _fieldName;
11950
 
11951
      _Fields(short thriftId, String fieldName) {
11952
        _thriftId = thriftId;
11953
        _fieldName = fieldName;
11954
      }
11955
 
11956
      public short getThriftFieldId() {
11957
        return _thriftId;
11958
      }
11959
 
11960
      public String getFieldName() {
11961
        return _fieldName;
11962
      }
11963
    }
11964
 
11965
    // isset id assignments
11966
    private static final int __ITEMID_ISSET_ID = 0;
11967
    private static final int __WAREHOUSEID_ISSET_ID = 1;
11968
    private static final int __SOURCEID_ISSET_ID = 2;
11969
    private static final int __ORDERID_ISSET_ID = 3;
11970
    private BitSet __isset_bit_vector = new BitSet(4);
11971
 
11972
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11973
    static {
11974
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11975
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11976
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11977
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11978
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11979
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11980
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11981
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11982
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11983
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11984
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(isOrderBillable_args.class, metaDataMap);
11985
    }
11986
 
11987
    public isOrderBillable_args() {
11988
    }
11989
 
11990
    public isOrderBillable_args(
11991
      long itemId,
11992
      long warehouseId,
11993
      long sourceId,
11994
      long orderId)
11995
    {
11996
      this();
11997
      this.itemId = itemId;
11998
      setItemIdIsSet(true);
11999
      this.warehouseId = warehouseId;
12000
      setWarehouseIdIsSet(true);
12001
      this.sourceId = sourceId;
12002
      setSourceIdIsSet(true);
12003
      this.orderId = orderId;
12004
      setOrderIdIsSet(true);
12005
    }
12006
 
12007
    /**
12008
     * Performs a deep copy on <i>other</i>.
12009
     */
12010
    public isOrderBillable_args(isOrderBillable_args other) {
12011
      __isset_bit_vector.clear();
12012
      __isset_bit_vector.or(other.__isset_bit_vector);
12013
      this.itemId = other.itemId;
12014
      this.warehouseId = other.warehouseId;
12015
      this.sourceId = other.sourceId;
12016
      this.orderId = other.orderId;
12017
    }
12018
 
12019
    public isOrderBillable_args deepCopy() {
12020
      return new isOrderBillable_args(this);
12021
    }
12022
 
12023
    @Override
12024
    public void clear() {
12025
      setItemIdIsSet(false);
12026
      this.itemId = 0;
12027
      setWarehouseIdIsSet(false);
12028
      this.warehouseId = 0;
12029
      setSourceIdIsSet(false);
12030
      this.sourceId = 0;
12031
      setOrderIdIsSet(false);
12032
      this.orderId = 0;
12033
    }
12034
 
12035
    public long getItemId() {
12036
      return this.itemId;
12037
    }
12038
 
12039
    public void setItemId(long itemId) {
12040
      this.itemId = itemId;
12041
      setItemIdIsSet(true);
12042
    }
12043
 
12044
    public void unsetItemId() {
12045
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
12046
    }
12047
 
12048
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
12049
    public boolean isSetItemId() {
12050
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
12051
    }
12052
 
12053
    public void setItemIdIsSet(boolean value) {
12054
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
12055
    }
12056
 
12057
    public long getWarehouseId() {
12058
      return this.warehouseId;
12059
    }
12060
 
12061
    public void setWarehouseId(long warehouseId) {
12062
      this.warehouseId = warehouseId;
12063
      setWarehouseIdIsSet(true);
12064
    }
12065
 
12066
    public void unsetWarehouseId() {
12067
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
12068
    }
12069
 
12070
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
12071
    public boolean isSetWarehouseId() {
12072
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
12073
    }
12074
 
12075
    public void setWarehouseIdIsSet(boolean value) {
12076
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
12077
    }
12078
 
12079
    public long getSourceId() {
12080
      return this.sourceId;
12081
    }
12082
 
12083
    public void setSourceId(long sourceId) {
12084
      this.sourceId = sourceId;
12085
      setSourceIdIsSet(true);
12086
    }
12087
 
12088
    public void unsetSourceId() {
12089
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
12090
    }
12091
 
12092
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
12093
    public boolean isSetSourceId() {
12094
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
12095
    }
12096
 
12097
    public void setSourceIdIsSet(boolean value) {
12098
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
12099
    }
12100
 
12101
    public long getOrderId() {
12102
      return this.orderId;
12103
    }
12104
 
12105
    public void setOrderId(long orderId) {
12106
      this.orderId = orderId;
12107
      setOrderIdIsSet(true);
12108
    }
12109
 
12110
    public void unsetOrderId() {
12111
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
12112
    }
12113
 
12114
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
12115
    public boolean isSetOrderId() {
12116
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
12117
    }
12118
 
12119
    public void setOrderIdIsSet(boolean value) {
12120
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
12121
    }
12122
 
12123
    public void setFieldValue(_Fields field, Object value) {
12124
      switch (field) {
12125
      case ITEM_ID:
12126
        if (value == null) {
12127
          unsetItemId();
12128
        } else {
12129
          setItemId((Long)value);
12130
        }
12131
        break;
12132
 
12133
      case WAREHOUSE_ID:
12134
        if (value == null) {
12135
          unsetWarehouseId();
12136
        } else {
12137
          setWarehouseId((Long)value);
12138
        }
12139
        break;
12140
 
12141
      case SOURCE_ID:
12142
        if (value == null) {
12143
          unsetSourceId();
12144
        } else {
12145
          setSourceId((Long)value);
12146
        }
12147
        break;
12148
 
12149
      case ORDER_ID:
12150
        if (value == null) {
12151
          unsetOrderId();
12152
        } else {
12153
          setOrderId((Long)value);
12154
        }
12155
        break;
12156
 
12157
      }
12158
    }
12159
 
12160
    public Object getFieldValue(_Fields field) {
12161
      switch (field) {
12162
      case ITEM_ID:
12163
        return Long.valueOf(getItemId());
12164
 
12165
      case WAREHOUSE_ID:
12166
        return Long.valueOf(getWarehouseId());
12167
 
12168
      case SOURCE_ID:
12169
        return Long.valueOf(getSourceId());
12170
 
12171
      case ORDER_ID:
12172
        return Long.valueOf(getOrderId());
12173
 
12174
      }
12175
      throw new IllegalStateException();
12176
    }
12177
 
12178
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12179
    public boolean isSet(_Fields field) {
12180
      if (field == null) {
12181
        throw new IllegalArgumentException();
12182
      }
12183
 
12184
      switch (field) {
12185
      case ITEM_ID:
12186
        return isSetItemId();
12187
      case WAREHOUSE_ID:
12188
        return isSetWarehouseId();
12189
      case SOURCE_ID:
12190
        return isSetSourceId();
12191
      case ORDER_ID:
12192
        return isSetOrderId();
12193
      }
12194
      throw new IllegalStateException();
12195
    }
12196
 
12197
    @Override
12198
    public boolean equals(Object that) {
12199
      if (that == null)
12200
        return false;
12201
      if (that instanceof isOrderBillable_args)
12202
        return this.equals((isOrderBillable_args)that);
12203
      return false;
12204
    }
12205
 
12206
    public boolean equals(isOrderBillable_args that) {
12207
      if (that == null)
12208
        return false;
12209
 
12210
      boolean this_present_itemId = true;
12211
      boolean that_present_itemId = true;
12212
      if (this_present_itemId || that_present_itemId) {
12213
        if (!(this_present_itemId && that_present_itemId))
12214
          return false;
12215
        if (this.itemId != that.itemId)
12216
          return false;
12217
      }
12218
 
12219
      boolean this_present_warehouseId = true;
12220
      boolean that_present_warehouseId = true;
12221
      if (this_present_warehouseId || that_present_warehouseId) {
12222
        if (!(this_present_warehouseId && that_present_warehouseId))
12223
          return false;
12224
        if (this.warehouseId != that.warehouseId)
12225
          return false;
12226
      }
12227
 
12228
      boolean this_present_sourceId = true;
12229
      boolean that_present_sourceId = true;
12230
      if (this_present_sourceId || that_present_sourceId) {
12231
        if (!(this_present_sourceId && that_present_sourceId))
12232
          return false;
12233
        if (this.sourceId != that.sourceId)
12234
          return false;
12235
      }
12236
 
12237
      boolean this_present_orderId = true;
12238
      boolean that_present_orderId = true;
12239
      if (this_present_orderId || that_present_orderId) {
12240
        if (!(this_present_orderId && that_present_orderId))
12241
          return false;
12242
        if (this.orderId != that.orderId)
12243
          return false;
12244
      }
12245
 
12246
      return true;
12247
    }
12248
 
12249
    @Override
12250
    public int hashCode() {
12251
      return 0;
12252
    }
12253
 
12254
    public int compareTo(isOrderBillable_args other) {
12255
      if (!getClass().equals(other.getClass())) {
12256
        return getClass().getName().compareTo(other.getClass().getName());
12257
      }
12258
 
12259
      int lastComparison = 0;
12260
      isOrderBillable_args typedOther = (isOrderBillable_args)other;
12261
 
12262
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
12263
      if (lastComparison != 0) {
12264
        return lastComparison;
12265
      }
12266
      if (isSetItemId()) {
12267
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
12268
        if (lastComparison != 0) {
12269
          return lastComparison;
12270
        }
12271
      }
12272
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
12273
      if (lastComparison != 0) {
12274
        return lastComparison;
12275
      }
12276
      if (isSetWarehouseId()) {
12277
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
12278
        if (lastComparison != 0) {
12279
          return lastComparison;
12280
        }
12281
      }
12282
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
12283
      if (lastComparison != 0) {
12284
        return lastComparison;
12285
      }
12286
      if (isSetSourceId()) {
12287
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
12288
        if (lastComparison != 0) {
12289
          return lastComparison;
12290
        }
12291
      }
12292
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
12293
      if (lastComparison != 0) {
12294
        return lastComparison;
12295
      }
12296
      if (isSetOrderId()) {
12297
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
12298
        if (lastComparison != 0) {
12299
          return lastComparison;
12300
        }
12301
      }
12302
      return 0;
12303
    }
12304
 
12305
    public _Fields fieldForId(int fieldId) {
12306
      return _Fields.findByThriftId(fieldId);
12307
    }
12308
 
12309
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12310
      org.apache.thrift.protocol.TField field;
12311
      iprot.readStructBegin();
12312
      while (true)
12313
      {
12314
        field = iprot.readFieldBegin();
12315
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12316
          break;
12317
        }
12318
        switch (field.id) {
12319
          case 1: // ITEM_ID
12320
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12321
              this.itemId = iprot.readI64();
12322
              setItemIdIsSet(true);
12323
            } else { 
12324
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12325
            }
12326
            break;
12327
          case 2: // WAREHOUSE_ID
12328
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12329
              this.warehouseId = iprot.readI64();
12330
              setWarehouseIdIsSet(true);
12331
            } else { 
12332
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12333
            }
12334
            break;
12335
          case 3: // SOURCE_ID
12336
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12337
              this.sourceId = iprot.readI64();
12338
              setSourceIdIsSet(true);
12339
            } else { 
12340
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12341
            }
12342
            break;
12343
          case 4: // ORDER_ID
12344
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12345
              this.orderId = iprot.readI64();
12346
              setOrderIdIsSet(true);
12347
            } else { 
12348
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12349
            }
12350
            break;
12351
          default:
12352
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12353
        }
12354
        iprot.readFieldEnd();
12355
      }
12356
      iprot.readStructEnd();
12357
      validate();
12358
    }
12359
 
12360
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12361
      validate();
12362
 
12363
      oprot.writeStructBegin(STRUCT_DESC);
12364
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
12365
      oprot.writeI64(this.itemId);
12366
      oprot.writeFieldEnd();
12367
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
12368
      oprot.writeI64(this.warehouseId);
12369
      oprot.writeFieldEnd();
12370
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
12371
      oprot.writeI64(this.sourceId);
12372
      oprot.writeFieldEnd();
12373
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
12374
      oprot.writeI64(this.orderId);
12375
      oprot.writeFieldEnd();
12376
      oprot.writeFieldStop();
12377
      oprot.writeStructEnd();
12378
    }
12379
 
12380
    @Override
12381
    public String toString() {
12382
      StringBuilder sb = new StringBuilder("isOrderBillable_args(");
12383
      boolean first = true;
12384
 
12385
      sb.append("itemId:");
12386
      sb.append(this.itemId);
12387
      first = false;
12388
      if (!first) sb.append(", ");
12389
      sb.append("warehouseId:");
12390
      sb.append(this.warehouseId);
12391
      first = false;
12392
      if (!first) sb.append(", ");
12393
      sb.append("sourceId:");
12394
      sb.append(this.sourceId);
12395
      first = false;
12396
      if (!first) sb.append(", ");
12397
      sb.append("orderId:");
12398
      sb.append(this.orderId);
12399
      first = false;
12400
      sb.append(")");
12401
      return sb.toString();
12402
    }
12403
 
12404
    public void validate() throws org.apache.thrift.TException {
12405
      // check for required fields
12406
    }
12407
 
12408
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12409
      try {
12410
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12411
      } catch (org.apache.thrift.TException te) {
12412
        throw new java.io.IOException(te);
12413
      }
12414
    }
12415
 
12416
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12417
      try {
12418
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12419
      } catch (org.apache.thrift.TException te) {
12420
        throw new java.io.IOException(te);
12421
      }
12422
    }
12423
 
12424
  }
12425
 
12426
  public static class isOrderBillable_result implements org.apache.thrift.TBase<isOrderBillable_result, isOrderBillable_result._Fields>, java.io.Serializable, Cloneable   {
12427
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("isOrderBillable_result");
12428
 
12429
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)0);
12430
 
12431
    private boolean success; // required
12432
 
12433
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12434
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12435
      SUCCESS((short)0, "success");
12436
 
12437
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12438
 
12439
      static {
12440
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12441
          byName.put(field.getFieldName(), field);
12442
        }
12443
      }
12444
 
12445
      /**
12446
       * Find the _Fields constant that matches fieldId, or null if its not found.
12447
       */
12448
      public static _Fields findByThriftId(int fieldId) {
12449
        switch(fieldId) {
12450
          case 0: // SUCCESS
12451
            return SUCCESS;
12452
          default:
12453
            return null;
12454
        }
12455
      }
12456
 
12457
      /**
12458
       * Find the _Fields constant that matches fieldId, throwing an exception
12459
       * if it is not found.
12460
       */
12461
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12462
        _Fields fields = findByThriftId(fieldId);
12463
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12464
        return fields;
12465
      }
12466
 
12467
      /**
12468
       * Find the _Fields constant that matches name, or null if its not found.
12469
       */
12470
      public static _Fields findByName(String name) {
12471
        return byName.get(name);
12472
      }
12473
 
12474
      private final short _thriftId;
12475
      private final String _fieldName;
12476
 
12477
      _Fields(short thriftId, String fieldName) {
12478
        _thriftId = thriftId;
12479
        _fieldName = fieldName;
12480
      }
12481
 
12482
      public short getThriftFieldId() {
12483
        return _thriftId;
12484
      }
12485
 
12486
      public String getFieldName() {
12487
        return _fieldName;
12488
      }
12489
    }
12490
 
12491
    // isset id assignments
12492
    private static final int __SUCCESS_ISSET_ID = 0;
12493
    private BitSet __isset_bit_vector = new BitSet(1);
12494
 
12495
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12496
    static {
12497
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12498
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12499
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
12500
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12501
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(isOrderBillable_result.class, metaDataMap);
12502
    }
12503
 
12504
    public isOrderBillable_result() {
12505
    }
12506
 
12507
    public isOrderBillable_result(
12508
      boolean success)
12509
    {
12510
      this();
12511
      this.success = success;
12512
      setSuccessIsSet(true);
12513
    }
12514
 
12515
    /**
12516
     * Performs a deep copy on <i>other</i>.
12517
     */
12518
    public isOrderBillable_result(isOrderBillable_result other) {
12519
      __isset_bit_vector.clear();
12520
      __isset_bit_vector.or(other.__isset_bit_vector);
12521
      this.success = other.success;
12522
    }
12523
 
12524
    public isOrderBillable_result deepCopy() {
12525
      return new isOrderBillable_result(this);
12526
    }
12527
 
12528
    @Override
12529
    public void clear() {
12530
      setSuccessIsSet(false);
12531
      this.success = false;
12532
    }
12533
 
12534
    public boolean isSuccess() {
12535
      return this.success;
12536
    }
12537
 
12538
    public void setSuccess(boolean success) {
12539
      this.success = success;
12540
      setSuccessIsSet(true);
12541
    }
12542
 
12543
    public void unsetSuccess() {
12544
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
12545
    }
12546
 
12547
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
12548
    public boolean isSetSuccess() {
12549
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
12550
    }
12551
 
12552
    public void setSuccessIsSet(boolean value) {
12553
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
12554
    }
12555
 
12556
    public void setFieldValue(_Fields field, Object value) {
12557
      switch (field) {
12558
      case SUCCESS:
12559
        if (value == null) {
12560
          unsetSuccess();
12561
        } else {
12562
          setSuccess((Boolean)value);
12563
        }
12564
        break;
12565
 
12566
      }
12567
    }
12568
 
12569
    public Object getFieldValue(_Fields field) {
12570
      switch (field) {
12571
      case SUCCESS:
12572
        return Boolean.valueOf(isSuccess());
12573
 
12574
      }
12575
      throw new IllegalStateException();
12576
    }
12577
 
12578
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12579
    public boolean isSet(_Fields field) {
12580
      if (field == null) {
12581
        throw new IllegalArgumentException();
12582
      }
12583
 
12584
      switch (field) {
12585
      case SUCCESS:
12586
        return isSetSuccess();
12587
      }
12588
      throw new IllegalStateException();
12589
    }
12590
 
12591
    @Override
12592
    public boolean equals(Object that) {
12593
      if (that == null)
12594
        return false;
12595
      if (that instanceof isOrderBillable_result)
12596
        return this.equals((isOrderBillable_result)that);
12597
      return false;
12598
    }
12599
 
12600
    public boolean equals(isOrderBillable_result that) {
12601
      if (that == null)
12602
        return false;
12603
 
12604
      boolean this_present_success = true;
12605
      boolean that_present_success = true;
12606
      if (this_present_success || that_present_success) {
12607
        if (!(this_present_success && that_present_success))
12608
          return false;
12609
        if (this.success != that.success)
12610
          return false;
12611
      }
12612
 
12613
      return true;
12614
    }
12615
 
12616
    @Override
12617
    public int hashCode() {
12618
      return 0;
12619
    }
12620
 
12621
    public int compareTo(isOrderBillable_result other) {
12622
      if (!getClass().equals(other.getClass())) {
12623
        return getClass().getName().compareTo(other.getClass().getName());
12624
      }
12625
 
12626
      int lastComparison = 0;
12627
      isOrderBillable_result typedOther = (isOrderBillable_result)other;
12628
 
12629
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
12630
      if (lastComparison != 0) {
12631
        return lastComparison;
12632
      }
12633
      if (isSetSuccess()) {
12634
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
12635
        if (lastComparison != 0) {
12636
          return lastComparison;
12637
        }
12638
      }
12639
      return 0;
12640
    }
12641
 
12642
    public _Fields fieldForId(int fieldId) {
12643
      return _Fields.findByThriftId(fieldId);
12644
    }
12645
 
12646
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12647
      org.apache.thrift.protocol.TField field;
12648
      iprot.readStructBegin();
12649
      while (true)
12650
      {
12651
        field = iprot.readFieldBegin();
12652
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12653
          break;
12654
        }
12655
        switch (field.id) {
12656
          case 0: // SUCCESS
12657
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
12658
              this.success = iprot.readBool();
12659
              setSuccessIsSet(true);
12660
            } else { 
12661
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12662
            }
12663
            break;
12664
          default:
12665
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12666
        }
12667
        iprot.readFieldEnd();
12668
      }
12669
      iprot.readStructEnd();
12670
      validate();
12671
    }
12672
 
12673
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12674
      oprot.writeStructBegin(STRUCT_DESC);
12675
 
12676
      if (this.isSetSuccess()) {
12677
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
12678
        oprot.writeBool(this.success);
12679
        oprot.writeFieldEnd();
12680
      }
12681
      oprot.writeFieldStop();
12682
      oprot.writeStructEnd();
12683
    }
12684
 
12685
    @Override
12686
    public String toString() {
12687
      StringBuilder sb = new StringBuilder("isOrderBillable_result(");
12688
      boolean first = true;
12689
 
12690
      sb.append("success:");
12691
      sb.append(this.success);
12692
      first = false;
12693
      sb.append(")");
12694
      return sb.toString();
12695
    }
12696
 
12697
    public void validate() throws org.apache.thrift.TException {
12698
      // check for required fields
12699
    }
12700
 
12701
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12702
      try {
12703
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12704
      } catch (org.apache.thrift.TException te) {
12705
        throw new java.io.IOException(te);
12706
      }
12707
    }
12708
 
12709
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12710
      try {
12711
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12712
      } catch (org.apache.thrift.TException te) {
12713
        throw new java.io.IOException(te);
12714
      }
12715
    }
12716
 
12717
  }
12718
 
5945 mandeep.dh 12719
  public static class reserveItemInWarehouse_args implements org.apache.thrift.TBase<reserveItemInWarehouse_args, reserveItemInWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
12720
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reserveItemInWarehouse_args");
12721
 
12722
    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);
12723
    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)2);
5967 rajveer 12724
    private static final org.apache.thrift.protocol.TField SOURCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sourceId", org.apache.thrift.protocol.TType.I64, (short)3);
12725
    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);
12726
    private static final org.apache.thrift.protocol.TField CREATED_TIMESTAMP_FIELD_DESC = new org.apache.thrift.protocol.TField("createdTimestamp", org.apache.thrift.protocol.TType.I64, (short)5);
12727
    private static final org.apache.thrift.protocol.TField PROMISED_SHIPPING_TIMESTAMP_FIELD_DESC = new org.apache.thrift.protocol.TField("promisedShippingTimestamp", org.apache.thrift.protocol.TType.I64, (short)6);
12728
    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)7);
5945 mandeep.dh 12729
 
12730
    private long itemId; // required
12731
    private long warehouseId; // required
5967 rajveer 12732
    private long sourceId; // required
12733
    private long orderId; // required
12734
    private long createdTimestamp; // required
12735
    private long promisedShippingTimestamp; // required
5945 mandeep.dh 12736
    private double quantity; // required
12737
 
12738
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12739
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12740
      ITEM_ID((short)1, "itemId"),
12741
      WAREHOUSE_ID((short)2, "warehouseId"),
5967 rajveer 12742
      SOURCE_ID((short)3, "sourceId"),
12743
      ORDER_ID((short)4, "orderId"),
12744
      CREATED_TIMESTAMP((short)5, "createdTimestamp"),
12745
      PROMISED_SHIPPING_TIMESTAMP((short)6, "promisedShippingTimestamp"),
12746
      QUANTITY((short)7, "quantity");
5945 mandeep.dh 12747
 
12748
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12749
 
12750
      static {
12751
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12752
          byName.put(field.getFieldName(), field);
12753
        }
12754
      }
12755
 
12756
      /**
12757
       * Find the _Fields constant that matches fieldId, or null if its not found.
12758
       */
12759
      public static _Fields findByThriftId(int fieldId) {
12760
        switch(fieldId) {
12761
          case 1: // ITEM_ID
12762
            return ITEM_ID;
12763
          case 2: // WAREHOUSE_ID
12764
            return WAREHOUSE_ID;
5967 rajveer 12765
          case 3: // SOURCE_ID
12766
            return SOURCE_ID;
12767
          case 4: // ORDER_ID
12768
            return ORDER_ID;
12769
          case 5: // CREATED_TIMESTAMP
12770
            return CREATED_TIMESTAMP;
12771
          case 6: // PROMISED_SHIPPING_TIMESTAMP
12772
            return PROMISED_SHIPPING_TIMESTAMP;
12773
          case 7: // QUANTITY
5945 mandeep.dh 12774
            return QUANTITY;
12775
          default:
12776
            return null;
12777
        }
12778
      }
12779
 
12780
      /**
12781
       * Find the _Fields constant that matches fieldId, throwing an exception
12782
       * if it is not found.
12783
       */
12784
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12785
        _Fields fields = findByThriftId(fieldId);
12786
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12787
        return fields;
12788
      }
12789
 
12790
      /**
12791
       * Find the _Fields constant that matches name, or null if its not found.
12792
       */
12793
      public static _Fields findByName(String name) {
12794
        return byName.get(name);
12795
      }
12796
 
12797
      private final short _thriftId;
12798
      private final String _fieldName;
12799
 
12800
      _Fields(short thriftId, String fieldName) {
12801
        _thriftId = thriftId;
12802
        _fieldName = fieldName;
12803
      }
12804
 
12805
      public short getThriftFieldId() {
12806
        return _thriftId;
12807
      }
12808
 
12809
      public String getFieldName() {
12810
        return _fieldName;
12811
      }
12812
    }
12813
 
12814
    // isset id assignments
12815
    private static final int __ITEMID_ISSET_ID = 0;
12816
    private static final int __WAREHOUSEID_ISSET_ID = 1;
5967 rajveer 12817
    private static final int __SOURCEID_ISSET_ID = 2;
12818
    private static final int __ORDERID_ISSET_ID = 3;
12819
    private static final int __CREATEDTIMESTAMP_ISSET_ID = 4;
12820
    private static final int __PROMISEDSHIPPINGTIMESTAMP_ISSET_ID = 5;
12821
    private static final int __QUANTITY_ISSET_ID = 6;
12822
    private BitSet __isset_bit_vector = new BitSet(7);
5945 mandeep.dh 12823
 
12824
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12825
    static {
12826
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12827
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12828
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12829
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12830
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5967 rajveer 12831
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12832
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12833
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12834
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12835
      tmpMap.put(_Fields.CREATED_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("createdTimestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12836
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12837
      tmpMap.put(_Fields.PROMISED_SHIPPING_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("promisedShippingTimestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12838
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5945 mandeep.dh 12839
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12840
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
12841
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12842
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reserveItemInWarehouse_args.class, metaDataMap);
12843
    }
12844
 
12845
    public reserveItemInWarehouse_args() {
12846
    }
12847
 
12848
    public reserveItemInWarehouse_args(
12849
      long itemId,
12850
      long warehouseId,
5967 rajveer 12851
      long sourceId,
12852
      long orderId,
12853
      long createdTimestamp,
12854
      long promisedShippingTimestamp,
5945 mandeep.dh 12855
      double quantity)
12856
    {
12857
      this();
12858
      this.itemId = itemId;
12859
      setItemIdIsSet(true);
12860
      this.warehouseId = warehouseId;
12861
      setWarehouseIdIsSet(true);
5967 rajveer 12862
      this.sourceId = sourceId;
12863
      setSourceIdIsSet(true);
12864
      this.orderId = orderId;
12865
      setOrderIdIsSet(true);
12866
      this.createdTimestamp = createdTimestamp;
12867
      setCreatedTimestampIsSet(true);
12868
      this.promisedShippingTimestamp = promisedShippingTimestamp;
12869
      setPromisedShippingTimestampIsSet(true);
5945 mandeep.dh 12870
      this.quantity = quantity;
12871
      setQuantityIsSet(true);
12872
    }
12873
 
12874
    /**
12875
     * Performs a deep copy on <i>other</i>.
12876
     */
12877
    public reserveItemInWarehouse_args(reserveItemInWarehouse_args other) {
12878
      __isset_bit_vector.clear();
12879
      __isset_bit_vector.or(other.__isset_bit_vector);
12880
      this.itemId = other.itemId;
12881
      this.warehouseId = other.warehouseId;
5967 rajveer 12882
      this.sourceId = other.sourceId;
12883
      this.orderId = other.orderId;
12884
      this.createdTimestamp = other.createdTimestamp;
12885
      this.promisedShippingTimestamp = other.promisedShippingTimestamp;
5945 mandeep.dh 12886
      this.quantity = other.quantity;
12887
    }
12888
 
12889
    public reserveItemInWarehouse_args deepCopy() {
12890
      return new reserveItemInWarehouse_args(this);
12891
    }
12892
 
12893
    @Override
12894
    public void clear() {
12895
      setItemIdIsSet(false);
12896
      this.itemId = 0;
12897
      setWarehouseIdIsSet(false);
12898
      this.warehouseId = 0;
5967 rajveer 12899
      setSourceIdIsSet(false);
12900
      this.sourceId = 0;
12901
      setOrderIdIsSet(false);
12902
      this.orderId = 0;
12903
      setCreatedTimestampIsSet(false);
12904
      this.createdTimestamp = 0;
12905
      setPromisedShippingTimestampIsSet(false);
12906
      this.promisedShippingTimestamp = 0;
5945 mandeep.dh 12907
      setQuantityIsSet(false);
12908
      this.quantity = 0.0;
12909
    }
12910
 
12911
    public long getItemId() {
12912
      return this.itemId;
12913
    }
12914
 
12915
    public void setItemId(long itemId) {
12916
      this.itemId = itemId;
12917
      setItemIdIsSet(true);
12918
    }
12919
 
12920
    public void unsetItemId() {
12921
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
12922
    }
12923
 
12924
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
12925
    public boolean isSetItemId() {
12926
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
12927
    }
12928
 
12929
    public void setItemIdIsSet(boolean value) {
12930
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
12931
    }
12932
 
12933
    public long getWarehouseId() {
12934
      return this.warehouseId;
12935
    }
12936
 
12937
    public void setWarehouseId(long warehouseId) {
12938
      this.warehouseId = warehouseId;
12939
      setWarehouseIdIsSet(true);
12940
    }
12941
 
12942
    public void unsetWarehouseId() {
12943
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
12944
    }
12945
 
12946
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
12947
    public boolean isSetWarehouseId() {
12948
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
12949
    }
12950
 
12951
    public void setWarehouseIdIsSet(boolean value) {
12952
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
12953
    }
12954
 
5967 rajveer 12955
    public long getSourceId() {
12956
      return this.sourceId;
12957
    }
12958
 
12959
    public void setSourceId(long sourceId) {
12960
      this.sourceId = sourceId;
12961
      setSourceIdIsSet(true);
12962
    }
12963
 
12964
    public void unsetSourceId() {
12965
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
12966
    }
12967
 
12968
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
12969
    public boolean isSetSourceId() {
12970
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
12971
    }
12972
 
12973
    public void setSourceIdIsSet(boolean value) {
12974
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
12975
    }
12976
 
12977
    public long getOrderId() {
12978
      return this.orderId;
12979
    }
12980
 
12981
    public void setOrderId(long orderId) {
12982
      this.orderId = orderId;
12983
      setOrderIdIsSet(true);
12984
    }
12985
 
12986
    public void unsetOrderId() {
12987
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
12988
    }
12989
 
12990
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
12991
    public boolean isSetOrderId() {
12992
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
12993
    }
12994
 
12995
    public void setOrderIdIsSet(boolean value) {
12996
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
12997
    }
12998
 
12999
    public long getCreatedTimestamp() {
13000
      return this.createdTimestamp;
13001
    }
13002
 
13003
    public void setCreatedTimestamp(long createdTimestamp) {
13004
      this.createdTimestamp = createdTimestamp;
13005
      setCreatedTimestampIsSet(true);
13006
    }
13007
 
13008
    public void unsetCreatedTimestamp() {
13009
      __isset_bit_vector.clear(__CREATEDTIMESTAMP_ISSET_ID);
13010
    }
13011
 
13012
    /** Returns true if field createdTimestamp is set (has been assigned a value) and false otherwise */
13013
    public boolean isSetCreatedTimestamp() {
13014
      return __isset_bit_vector.get(__CREATEDTIMESTAMP_ISSET_ID);
13015
    }
13016
 
13017
    public void setCreatedTimestampIsSet(boolean value) {
13018
      __isset_bit_vector.set(__CREATEDTIMESTAMP_ISSET_ID, value);
13019
    }
13020
 
13021
    public long getPromisedShippingTimestamp() {
13022
      return this.promisedShippingTimestamp;
13023
    }
13024
 
13025
    public void setPromisedShippingTimestamp(long promisedShippingTimestamp) {
13026
      this.promisedShippingTimestamp = promisedShippingTimestamp;
13027
      setPromisedShippingTimestampIsSet(true);
13028
    }
13029
 
13030
    public void unsetPromisedShippingTimestamp() {
13031
      __isset_bit_vector.clear(__PROMISEDSHIPPINGTIMESTAMP_ISSET_ID);
13032
    }
13033
 
13034
    /** Returns true if field promisedShippingTimestamp is set (has been assigned a value) and false otherwise */
13035
    public boolean isSetPromisedShippingTimestamp() {
13036
      return __isset_bit_vector.get(__PROMISEDSHIPPINGTIMESTAMP_ISSET_ID);
13037
    }
13038
 
13039
    public void setPromisedShippingTimestampIsSet(boolean value) {
13040
      __isset_bit_vector.set(__PROMISEDSHIPPINGTIMESTAMP_ISSET_ID, value);
13041
    }
13042
 
5945 mandeep.dh 13043
    public double getQuantity() {
13044
      return this.quantity;
13045
    }
13046
 
13047
    public void setQuantity(double quantity) {
13048
      this.quantity = quantity;
13049
      setQuantityIsSet(true);
13050
    }
13051
 
13052
    public void unsetQuantity() {
13053
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
13054
    }
13055
 
13056
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
13057
    public boolean isSetQuantity() {
13058
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
13059
    }
13060
 
13061
    public void setQuantityIsSet(boolean value) {
13062
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
13063
    }
13064
 
13065
    public void setFieldValue(_Fields field, Object value) {
13066
      switch (field) {
13067
      case ITEM_ID:
13068
        if (value == null) {
13069
          unsetItemId();
13070
        } else {
13071
          setItemId((Long)value);
13072
        }
13073
        break;
13074
 
13075
      case WAREHOUSE_ID:
13076
        if (value == null) {
13077
          unsetWarehouseId();
13078
        } else {
13079
          setWarehouseId((Long)value);
13080
        }
13081
        break;
13082
 
5967 rajveer 13083
      case SOURCE_ID:
13084
        if (value == null) {
13085
          unsetSourceId();
13086
        } else {
13087
          setSourceId((Long)value);
13088
        }
13089
        break;
13090
 
13091
      case ORDER_ID:
13092
        if (value == null) {
13093
          unsetOrderId();
13094
        } else {
13095
          setOrderId((Long)value);
13096
        }
13097
        break;
13098
 
13099
      case CREATED_TIMESTAMP:
13100
        if (value == null) {
13101
          unsetCreatedTimestamp();
13102
        } else {
13103
          setCreatedTimestamp((Long)value);
13104
        }
13105
        break;
13106
 
13107
      case PROMISED_SHIPPING_TIMESTAMP:
13108
        if (value == null) {
13109
          unsetPromisedShippingTimestamp();
13110
        } else {
13111
          setPromisedShippingTimestamp((Long)value);
13112
        }
13113
        break;
13114
 
5945 mandeep.dh 13115
      case QUANTITY:
13116
        if (value == null) {
13117
          unsetQuantity();
13118
        } else {
13119
          setQuantity((Double)value);
13120
        }
13121
        break;
13122
 
13123
      }
13124
    }
13125
 
13126
    public Object getFieldValue(_Fields field) {
13127
      switch (field) {
13128
      case ITEM_ID:
13129
        return Long.valueOf(getItemId());
13130
 
13131
      case WAREHOUSE_ID:
13132
        return Long.valueOf(getWarehouseId());
13133
 
5967 rajveer 13134
      case SOURCE_ID:
13135
        return Long.valueOf(getSourceId());
13136
 
13137
      case ORDER_ID:
13138
        return Long.valueOf(getOrderId());
13139
 
13140
      case CREATED_TIMESTAMP:
13141
        return Long.valueOf(getCreatedTimestamp());
13142
 
13143
      case PROMISED_SHIPPING_TIMESTAMP:
13144
        return Long.valueOf(getPromisedShippingTimestamp());
13145
 
5945 mandeep.dh 13146
      case QUANTITY:
13147
        return Double.valueOf(getQuantity());
13148
 
13149
      }
13150
      throw new IllegalStateException();
13151
    }
13152
 
13153
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13154
    public boolean isSet(_Fields field) {
13155
      if (field == null) {
13156
        throw new IllegalArgumentException();
13157
      }
13158
 
13159
      switch (field) {
13160
      case ITEM_ID:
13161
        return isSetItemId();
13162
      case WAREHOUSE_ID:
13163
        return isSetWarehouseId();
5967 rajveer 13164
      case SOURCE_ID:
13165
        return isSetSourceId();
13166
      case ORDER_ID:
13167
        return isSetOrderId();
13168
      case CREATED_TIMESTAMP:
13169
        return isSetCreatedTimestamp();
13170
      case PROMISED_SHIPPING_TIMESTAMP:
13171
        return isSetPromisedShippingTimestamp();
5945 mandeep.dh 13172
      case QUANTITY:
13173
        return isSetQuantity();
13174
      }
13175
      throw new IllegalStateException();
13176
    }
13177
 
13178
    @Override
13179
    public boolean equals(Object that) {
13180
      if (that == null)
13181
        return false;
13182
      if (that instanceof reserveItemInWarehouse_args)
13183
        return this.equals((reserveItemInWarehouse_args)that);
13184
      return false;
13185
    }
13186
 
13187
    public boolean equals(reserveItemInWarehouse_args that) {
13188
      if (that == null)
13189
        return false;
13190
 
13191
      boolean this_present_itemId = true;
13192
      boolean that_present_itemId = true;
13193
      if (this_present_itemId || that_present_itemId) {
13194
        if (!(this_present_itemId && that_present_itemId))
13195
          return false;
13196
        if (this.itemId != that.itemId)
13197
          return false;
13198
      }
13199
 
13200
      boolean this_present_warehouseId = true;
13201
      boolean that_present_warehouseId = true;
13202
      if (this_present_warehouseId || that_present_warehouseId) {
13203
        if (!(this_present_warehouseId && that_present_warehouseId))
13204
          return false;
13205
        if (this.warehouseId != that.warehouseId)
13206
          return false;
13207
      }
13208
 
5967 rajveer 13209
      boolean this_present_sourceId = true;
13210
      boolean that_present_sourceId = true;
13211
      if (this_present_sourceId || that_present_sourceId) {
13212
        if (!(this_present_sourceId && that_present_sourceId))
13213
          return false;
13214
        if (this.sourceId != that.sourceId)
13215
          return false;
13216
      }
13217
 
13218
      boolean this_present_orderId = true;
13219
      boolean that_present_orderId = true;
13220
      if (this_present_orderId || that_present_orderId) {
13221
        if (!(this_present_orderId && that_present_orderId))
13222
          return false;
13223
        if (this.orderId != that.orderId)
13224
          return false;
13225
      }
13226
 
13227
      boolean this_present_createdTimestamp = true;
13228
      boolean that_present_createdTimestamp = true;
13229
      if (this_present_createdTimestamp || that_present_createdTimestamp) {
13230
        if (!(this_present_createdTimestamp && that_present_createdTimestamp))
13231
          return false;
13232
        if (this.createdTimestamp != that.createdTimestamp)
13233
          return false;
13234
      }
13235
 
13236
      boolean this_present_promisedShippingTimestamp = true;
13237
      boolean that_present_promisedShippingTimestamp = true;
13238
      if (this_present_promisedShippingTimestamp || that_present_promisedShippingTimestamp) {
13239
        if (!(this_present_promisedShippingTimestamp && that_present_promisedShippingTimestamp))
13240
          return false;
13241
        if (this.promisedShippingTimestamp != that.promisedShippingTimestamp)
13242
          return false;
13243
      }
13244
 
5945 mandeep.dh 13245
      boolean this_present_quantity = true;
13246
      boolean that_present_quantity = true;
13247
      if (this_present_quantity || that_present_quantity) {
13248
        if (!(this_present_quantity && that_present_quantity))
13249
          return false;
13250
        if (this.quantity != that.quantity)
13251
          return false;
13252
      }
13253
 
13254
      return true;
13255
    }
13256
 
13257
    @Override
13258
    public int hashCode() {
13259
      return 0;
13260
    }
13261
 
13262
    public int compareTo(reserveItemInWarehouse_args other) {
13263
      if (!getClass().equals(other.getClass())) {
13264
        return getClass().getName().compareTo(other.getClass().getName());
13265
      }
13266
 
13267
      int lastComparison = 0;
13268
      reserveItemInWarehouse_args typedOther = (reserveItemInWarehouse_args)other;
13269
 
13270
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
13271
      if (lastComparison != 0) {
13272
        return lastComparison;
13273
      }
13274
      if (isSetItemId()) {
13275
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
13276
        if (lastComparison != 0) {
13277
          return lastComparison;
13278
        }
13279
      }
13280
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
13281
      if (lastComparison != 0) {
13282
        return lastComparison;
13283
      }
13284
      if (isSetWarehouseId()) {
13285
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
13286
        if (lastComparison != 0) {
13287
          return lastComparison;
13288
        }
13289
      }
5967 rajveer 13290
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
13291
      if (lastComparison != 0) {
13292
        return lastComparison;
13293
      }
13294
      if (isSetSourceId()) {
13295
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
13296
        if (lastComparison != 0) {
13297
          return lastComparison;
13298
        }
13299
      }
13300
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
13301
      if (lastComparison != 0) {
13302
        return lastComparison;
13303
      }
13304
      if (isSetOrderId()) {
13305
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
13306
        if (lastComparison != 0) {
13307
          return lastComparison;
13308
        }
13309
      }
13310
      lastComparison = Boolean.valueOf(isSetCreatedTimestamp()).compareTo(typedOther.isSetCreatedTimestamp());
13311
      if (lastComparison != 0) {
13312
        return lastComparison;
13313
      }
13314
      if (isSetCreatedTimestamp()) {
13315
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.createdTimestamp, typedOther.createdTimestamp);
13316
        if (lastComparison != 0) {
13317
          return lastComparison;
13318
        }
13319
      }
13320
      lastComparison = Boolean.valueOf(isSetPromisedShippingTimestamp()).compareTo(typedOther.isSetPromisedShippingTimestamp());
13321
      if (lastComparison != 0) {
13322
        return lastComparison;
13323
      }
13324
      if (isSetPromisedShippingTimestamp()) {
13325
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.promisedShippingTimestamp, typedOther.promisedShippingTimestamp);
13326
        if (lastComparison != 0) {
13327
          return lastComparison;
13328
        }
13329
      }
5945 mandeep.dh 13330
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
13331
      if (lastComparison != 0) {
13332
        return lastComparison;
13333
      }
13334
      if (isSetQuantity()) {
13335
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
13336
        if (lastComparison != 0) {
13337
          return lastComparison;
13338
        }
13339
      }
13340
      return 0;
13341
    }
13342
 
13343
    public _Fields fieldForId(int fieldId) {
13344
      return _Fields.findByThriftId(fieldId);
13345
    }
13346
 
13347
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13348
      org.apache.thrift.protocol.TField field;
13349
      iprot.readStructBegin();
13350
      while (true)
13351
      {
13352
        field = iprot.readFieldBegin();
13353
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13354
          break;
13355
        }
13356
        switch (field.id) {
13357
          case 1: // ITEM_ID
13358
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13359
              this.itemId = iprot.readI64();
13360
              setItemIdIsSet(true);
13361
            } else { 
13362
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13363
            }
13364
            break;
13365
          case 2: // WAREHOUSE_ID
13366
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13367
              this.warehouseId = iprot.readI64();
13368
              setWarehouseIdIsSet(true);
13369
            } else { 
13370
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13371
            }
13372
            break;
5967 rajveer 13373
          case 3: // SOURCE_ID
13374
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13375
              this.sourceId = iprot.readI64();
13376
              setSourceIdIsSet(true);
13377
            } else { 
13378
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13379
            }
13380
            break;
13381
          case 4: // ORDER_ID
13382
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13383
              this.orderId = iprot.readI64();
13384
              setOrderIdIsSet(true);
13385
            } else { 
13386
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13387
            }
13388
            break;
13389
          case 5: // CREATED_TIMESTAMP
13390
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13391
              this.createdTimestamp = iprot.readI64();
13392
              setCreatedTimestampIsSet(true);
13393
            } else { 
13394
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13395
            }
13396
            break;
13397
          case 6: // PROMISED_SHIPPING_TIMESTAMP
13398
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13399
              this.promisedShippingTimestamp = iprot.readI64();
13400
              setPromisedShippingTimestampIsSet(true);
13401
            } else { 
13402
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13403
            }
13404
            break;
13405
          case 7: // QUANTITY
5945 mandeep.dh 13406
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
13407
              this.quantity = iprot.readDouble();
13408
              setQuantityIsSet(true);
13409
            } else { 
13410
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13411
            }
13412
            break;
13413
          default:
13414
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13415
        }
13416
        iprot.readFieldEnd();
13417
      }
13418
      iprot.readStructEnd();
13419
      validate();
13420
    }
13421
 
13422
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13423
      validate();
13424
 
13425
      oprot.writeStructBegin(STRUCT_DESC);
13426
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
13427
      oprot.writeI64(this.itemId);
13428
      oprot.writeFieldEnd();
13429
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
13430
      oprot.writeI64(this.warehouseId);
13431
      oprot.writeFieldEnd();
5967 rajveer 13432
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
13433
      oprot.writeI64(this.sourceId);
13434
      oprot.writeFieldEnd();
13435
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
13436
      oprot.writeI64(this.orderId);
13437
      oprot.writeFieldEnd();
13438
      oprot.writeFieldBegin(CREATED_TIMESTAMP_FIELD_DESC);
13439
      oprot.writeI64(this.createdTimestamp);
13440
      oprot.writeFieldEnd();
13441
      oprot.writeFieldBegin(PROMISED_SHIPPING_TIMESTAMP_FIELD_DESC);
13442
      oprot.writeI64(this.promisedShippingTimestamp);
13443
      oprot.writeFieldEnd();
5945 mandeep.dh 13444
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
13445
      oprot.writeDouble(this.quantity);
13446
      oprot.writeFieldEnd();
13447
      oprot.writeFieldStop();
13448
      oprot.writeStructEnd();
13449
    }
13450
 
13451
    @Override
13452
    public String toString() {
13453
      StringBuilder sb = new StringBuilder("reserveItemInWarehouse_args(");
13454
      boolean first = true;
13455
 
13456
      sb.append("itemId:");
13457
      sb.append(this.itemId);
13458
      first = false;
13459
      if (!first) sb.append(", ");
13460
      sb.append("warehouseId:");
13461
      sb.append(this.warehouseId);
13462
      first = false;
13463
      if (!first) sb.append(", ");
5967 rajveer 13464
      sb.append("sourceId:");
13465
      sb.append(this.sourceId);
13466
      first = false;
13467
      if (!first) sb.append(", ");
13468
      sb.append("orderId:");
13469
      sb.append(this.orderId);
13470
      first = false;
13471
      if (!first) sb.append(", ");
13472
      sb.append("createdTimestamp:");
13473
      sb.append(this.createdTimestamp);
13474
      first = false;
13475
      if (!first) sb.append(", ");
13476
      sb.append("promisedShippingTimestamp:");
13477
      sb.append(this.promisedShippingTimestamp);
13478
      first = false;
13479
      if (!first) sb.append(", ");
5945 mandeep.dh 13480
      sb.append("quantity:");
13481
      sb.append(this.quantity);
13482
      first = false;
13483
      sb.append(")");
13484
      return sb.toString();
13485
    }
13486
 
13487
    public void validate() throws org.apache.thrift.TException {
13488
      // check for required fields
13489
    }
13490
 
13491
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13492
      try {
13493
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13494
      } catch (org.apache.thrift.TException te) {
13495
        throw new java.io.IOException(te);
13496
      }
13497
    }
13498
 
13499
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13500
      try {
13501
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13502
      } catch (org.apache.thrift.TException te) {
13503
        throw new java.io.IOException(te);
13504
      }
13505
    }
13506
 
13507
  }
13508
 
13509
  public static class reserveItemInWarehouse_result implements org.apache.thrift.TBase<reserveItemInWarehouse_result, reserveItemInWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
13510
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reserveItemInWarehouse_result");
13511
 
13512
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)0);
13513
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
13514
 
13515
    private boolean success; // required
13516
    private InventoryServiceException cex; // required
13517
 
13518
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13519
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13520
      SUCCESS((short)0, "success"),
13521
      CEX((short)1, "cex");
13522
 
13523
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13524
 
13525
      static {
13526
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13527
          byName.put(field.getFieldName(), field);
13528
        }
13529
      }
13530
 
13531
      /**
13532
       * Find the _Fields constant that matches fieldId, or null if its not found.
13533
       */
13534
      public static _Fields findByThriftId(int fieldId) {
13535
        switch(fieldId) {
13536
          case 0: // SUCCESS
13537
            return SUCCESS;
13538
          case 1: // CEX
13539
            return CEX;
13540
          default:
13541
            return null;
13542
        }
13543
      }
13544
 
13545
      /**
13546
       * Find the _Fields constant that matches fieldId, throwing an exception
13547
       * if it is not found.
13548
       */
13549
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13550
        _Fields fields = findByThriftId(fieldId);
13551
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13552
        return fields;
13553
      }
13554
 
13555
      /**
13556
       * Find the _Fields constant that matches name, or null if its not found.
13557
       */
13558
      public static _Fields findByName(String name) {
13559
        return byName.get(name);
13560
      }
13561
 
13562
      private final short _thriftId;
13563
      private final String _fieldName;
13564
 
13565
      _Fields(short thriftId, String fieldName) {
13566
        _thriftId = thriftId;
13567
        _fieldName = fieldName;
13568
      }
13569
 
13570
      public short getThriftFieldId() {
13571
        return _thriftId;
13572
      }
13573
 
13574
      public String getFieldName() {
13575
        return _fieldName;
13576
      }
13577
    }
13578
 
13579
    // isset id assignments
13580
    private static final int __SUCCESS_ISSET_ID = 0;
13581
    private BitSet __isset_bit_vector = new BitSet(1);
13582
 
13583
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13584
    static {
13585
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13586
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13587
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
13588
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13589
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
13590
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13591
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reserveItemInWarehouse_result.class, metaDataMap);
13592
    }
13593
 
13594
    public reserveItemInWarehouse_result() {
13595
    }
13596
 
13597
    public reserveItemInWarehouse_result(
13598
      boolean success,
13599
      InventoryServiceException cex)
13600
    {
13601
      this();
13602
      this.success = success;
13603
      setSuccessIsSet(true);
13604
      this.cex = cex;
13605
    }
13606
 
13607
    /**
13608
     * Performs a deep copy on <i>other</i>.
13609
     */
13610
    public reserveItemInWarehouse_result(reserveItemInWarehouse_result other) {
13611
      __isset_bit_vector.clear();
13612
      __isset_bit_vector.or(other.__isset_bit_vector);
13613
      this.success = other.success;
13614
      if (other.isSetCex()) {
13615
        this.cex = new InventoryServiceException(other.cex);
13616
      }
13617
    }
13618
 
13619
    public reserveItemInWarehouse_result deepCopy() {
13620
      return new reserveItemInWarehouse_result(this);
13621
    }
13622
 
13623
    @Override
13624
    public void clear() {
13625
      setSuccessIsSet(false);
13626
      this.success = false;
13627
      this.cex = null;
13628
    }
13629
 
13630
    public boolean isSuccess() {
13631
      return this.success;
13632
    }
13633
 
13634
    public void setSuccess(boolean success) {
13635
      this.success = success;
13636
      setSuccessIsSet(true);
13637
    }
13638
 
13639
    public void unsetSuccess() {
13640
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
13641
    }
13642
 
13643
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13644
    public boolean isSetSuccess() {
13645
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
13646
    }
13647
 
13648
    public void setSuccessIsSet(boolean value) {
13649
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
13650
    }
13651
 
13652
    public InventoryServiceException getCex() {
13653
      return this.cex;
13654
    }
13655
 
13656
    public void setCex(InventoryServiceException cex) {
13657
      this.cex = cex;
13658
    }
13659
 
13660
    public void unsetCex() {
13661
      this.cex = null;
13662
    }
13663
 
13664
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
13665
    public boolean isSetCex() {
13666
      return this.cex != null;
13667
    }
13668
 
13669
    public void setCexIsSet(boolean value) {
13670
      if (!value) {
13671
        this.cex = null;
13672
      }
13673
    }
13674
 
13675
    public void setFieldValue(_Fields field, Object value) {
13676
      switch (field) {
13677
      case SUCCESS:
13678
        if (value == null) {
13679
          unsetSuccess();
13680
        } else {
13681
          setSuccess((Boolean)value);
13682
        }
13683
        break;
13684
 
13685
      case CEX:
13686
        if (value == null) {
13687
          unsetCex();
13688
        } else {
13689
          setCex((InventoryServiceException)value);
13690
        }
13691
        break;
13692
 
13693
      }
13694
    }
13695
 
13696
    public Object getFieldValue(_Fields field) {
13697
      switch (field) {
13698
      case SUCCESS:
13699
        return Boolean.valueOf(isSuccess());
13700
 
13701
      case CEX:
13702
        return getCex();
13703
 
13704
      }
13705
      throw new IllegalStateException();
13706
    }
13707
 
13708
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13709
    public boolean isSet(_Fields field) {
13710
      if (field == null) {
13711
        throw new IllegalArgumentException();
13712
      }
13713
 
13714
      switch (field) {
13715
      case SUCCESS:
13716
        return isSetSuccess();
13717
      case CEX:
13718
        return isSetCex();
13719
      }
13720
      throw new IllegalStateException();
13721
    }
13722
 
13723
    @Override
13724
    public boolean equals(Object that) {
13725
      if (that == null)
13726
        return false;
13727
      if (that instanceof reserveItemInWarehouse_result)
13728
        return this.equals((reserveItemInWarehouse_result)that);
13729
      return false;
13730
    }
13731
 
13732
    public boolean equals(reserveItemInWarehouse_result that) {
13733
      if (that == null)
13734
        return false;
13735
 
13736
      boolean this_present_success = true;
13737
      boolean that_present_success = true;
13738
      if (this_present_success || that_present_success) {
13739
        if (!(this_present_success && that_present_success))
13740
          return false;
13741
        if (this.success != that.success)
13742
          return false;
13743
      }
13744
 
13745
      boolean this_present_cex = true && this.isSetCex();
13746
      boolean that_present_cex = true && that.isSetCex();
13747
      if (this_present_cex || that_present_cex) {
13748
        if (!(this_present_cex && that_present_cex))
13749
          return false;
13750
        if (!this.cex.equals(that.cex))
13751
          return false;
13752
      }
13753
 
13754
      return true;
13755
    }
13756
 
13757
    @Override
13758
    public int hashCode() {
13759
      return 0;
13760
    }
13761
 
13762
    public int compareTo(reserveItemInWarehouse_result other) {
13763
      if (!getClass().equals(other.getClass())) {
13764
        return getClass().getName().compareTo(other.getClass().getName());
13765
      }
13766
 
13767
      int lastComparison = 0;
13768
      reserveItemInWarehouse_result typedOther = (reserveItemInWarehouse_result)other;
13769
 
13770
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13771
      if (lastComparison != 0) {
13772
        return lastComparison;
13773
      }
13774
      if (isSetSuccess()) {
13775
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13776
        if (lastComparison != 0) {
13777
          return lastComparison;
13778
        }
13779
      }
13780
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
13781
      if (lastComparison != 0) {
13782
        return lastComparison;
13783
      }
13784
      if (isSetCex()) {
13785
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
13786
        if (lastComparison != 0) {
13787
          return lastComparison;
13788
        }
13789
      }
13790
      return 0;
13791
    }
13792
 
13793
    public _Fields fieldForId(int fieldId) {
13794
      return _Fields.findByThriftId(fieldId);
13795
    }
13796
 
13797
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13798
      org.apache.thrift.protocol.TField field;
13799
      iprot.readStructBegin();
13800
      while (true)
13801
      {
13802
        field = iprot.readFieldBegin();
13803
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13804
          break;
13805
        }
13806
        switch (field.id) {
13807
          case 0: // SUCCESS
13808
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
13809
              this.success = iprot.readBool();
13810
              setSuccessIsSet(true);
13811
            } else { 
13812
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13813
            }
13814
            break;
13815
          case 1: // CEX
13816
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
13817
              this.cex = new InventoryServiceException();
13818
              this.cex.read(iprot);
13819
            } else { 
13820
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13821
            }
13822
            break;
13823
          default:
13824
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13825
        }
13826
        iprot.readFieldEnd();
13827
      }
13828
      iprot.readStructEnd();
13829
      validate();
13830
    }
13831
 
13832
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13833
      oprot.writeStructBegin(STRUCT_DESC);
13834
 
13835
      if (this.isSetSuccess()) {
13836
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
13837
        oprot.writeBool(this.success);
13838
        oprot.writeFieldEnd();
13839
      } else if (this.isSetCex()) {
13840
        oprot.writeFieldBegin(CEX_FIELD_DESC);
13841
        this.cex.write(oprot);
13842
        oprot.writeFieldEnd();
13843
      }
13844
      oprot.writeFieldStop();
13845
      oprot.writeStructEnd();
13846
    }
13847
 
13848
    @Override
13849
    public String toString() {
13850
      StringBuilder sb = new StringBuilder("reserveItemInWarehouse_result(");
13851
      boolean first = true;
13852
 
13853
      sb.append("success:");
13854
      sb.append(this.success);
13855
      first = false;
13856
      if (!first) sb.append(", ");
13857
      sb.append("cex:");
13858
      if (this.cex == null) {
13859
        sb.append("null");
13860
      } else {
13861
        sb.append(this.cex);
13862
      }
13863
      first = false;
13864
      sb.append(")");
13865
      return sb.toString();
13866
    }
13867
 
13868
    public void validate() throws org.apache.thrift.TException {
13869
      // check for required fields
13870
    }
13871
 
13872
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13873
      try {
13874
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13875
      } catch (org.apache.thrift.TException te) {
13876
        throw new java.io.IOException(te);
13877
      }
13878
    }
13879
 
13880
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13881
      try {
13882
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13883
      } catch (org.apache.thrift.TException te) {
13884
        throw new java.io.IOException(te);
13885
      }
13886
    }
13887
 
13888
  }
13889
 
13890
  public static class reduceReservationCount_args implements org.apache.thrift.TBase<reduceReservationCount_args, reduceReservationCount_args._Fields>, java.io.Serializable, Cloneable   {
13891
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reduceReservationCount_args");
13892
 
13893
    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);
13894
    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)2);
5967 rajveer 13895
    private static final org.apache.thrift.protocol.TField SOURCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sourceId", org.apache.thrift.protocol.TType.I64, (short)3);
13896
    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);
13897
    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);
5945 mandeep.dh 13898
 
13899
    private long itemId; // required
13900
    private long warehouseId; // required
5967 rajveer 13901
    private long sourceId; // required
13902
    private long orderId; // required
5945 mandeep.dh 13903
    private double quantity; // required
13904
 
13905
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13906
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13907
      ITEM_ID((short)1, "itemId"),
13908
      WAREHOUSE_ID((short)2, "warehouseId"),
5967 rajveer 13909
      SOURCE_ID((short)3, "sourceId"),
13910
      ORDER_ID((short)4, "orderId"),
13911
      QUANTITY((short)5, "quantity");
5945 mandeep.dh 13912
 
13913
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13914
 
13915
      static {
13916
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13917
          byName.put(field.getFieldName(), field);
13918
        }
13919
      }
13920
 
13921
      /**
13922
       * Find the _Fields constant that matches fieldId, or null if its not found.
13923
       */
13924
      public static _Fields findByThriftId(int fieldId) {
13925
        switch(fieldId) {
13926
          case 1: // ITEM_ID
13927
            return ITEM_ID;
13928
          case 2: // WAREHOUSE_ID
13929
            return WAREHOUSE_ID;
5967 rajveer 13930
          case 3: // SOURCE_ID
13931
            return SOURCE_ID;
13932
          case 4: // ORDER_ID
13933
            return ORDER_ID;
13934
          case 5: // QUANTITY
5945 mandeep.dh 13935
            return QUANTITY;
13936
          default:
13937
            return null;
13938
        }
13939
      }
13940
 
13941
      /**
13942
       * Find the _Fields constant that matches fieldId, throwing an exception
13943
       * if it is not found.
13944
       */
13945
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13946
        _Fields fields = findByThriftId(fieldId);
13947
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13948
        return fields;
13949
      }
13950
 
13951
      /**
13952
       * Find the _Fields constant that matches name, or null if its not found.
13953
       */
13954
      public static _Fields findByName(String name) {
13955
        return byName.get(name);
13956
      }
13957
 
13958
      private final short _thriftId;
13959
      private final String _fieldName;
13960
 
13961
      _Fields(short thriftId, String fieldName) {
13962
        _thriftId = thriftId;
13963
        _fieldName = fieldName;
13964
      }
13965
 
13966
      public short getThriftFieldId() {
13967
        return _thriftId;
13968
      }
13969
 
13970
      public String getFieldName() {
13971
        return _fieldName;
13972
      }
13973
    }
13974
 
13975
    // isset id assignments
13976
    private static final int __ITEMID_ISSET_ID = 0;
13977
    private static final int __WAREHOUSEID_ISSET_ID = 1;
5967 rajveer 13978
    private static final int __SOURCEID_ISSET_ID = 2;
13979
    private static final int __ORDERID_ISSET_ID = 3;
13980
    private static final int __QUANTITY_ISSET_ID = 4;
13981
    private BitSet __isset_bit_vector = new BitSet(5);
5945 mandeep.dh 13982
 
13983
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13984
    static {
13985
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13986
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13987
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13988
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13989
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5967 rajveer 13990
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13991
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13992
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13993
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5945 mandeep.dh 13994
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13995
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
13996
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13997
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reduceReservationCount_args.class, metaDataMap);
13998
    }
13999
 
14000
    public reduceReservationCount_args() {
14001
    }
14002
 
14003
    public reduceReservationCount_args(
14004
      long itemId,
14005
      long warehouseId,
5967 rajveer 14006
      long sourceId,
14007
      long orderId,
5945 mandeep.dh 14008
      double quantity)
14009
    {
14010
      this();
14011
      this.itemId = itemId;
14012
      setItemIdIsSet(true);
14013
      this.warehouseId = warehouseId;
14014
      setWarehouseIdIsSet(true);
5967 rajveer 14015
      this.sourceId = sourceId;
14016
      setSourceIdIsSet(true);
14017
      this.orderId = orderId;
14018
      setOrderIdIsSet(true);
5945 mandeep.dh 14019
      this.quantity = quantity;
14020
      setQuantityIsSet(true);
14021
    }
14022
 
14023
    /**
14024
     * Performs a deep copy on <i>other</i>.
14025
     */
14026
    public reduceReservationCount_args(reduceReservationCount_args other) {
14027
      __isset_bit_vector.clear();
14028
      __isset_bit_vector.or(other.__isset_bit_vector);
14029
      this.itemId = other.itemId;
14030
      this.warehouseId = other.warehouseId;
5967 rajveer 14031
      this.sourceId = other.sourceId;
14032
      this.orderId = other.orderId;
5945 mandeep.dh 14033
      this.quantity = other.quantity;
14034
    }
14035
 
14036
    public reduceReservationCount_args deepCopy() {
14037
      return new reduceReservationCount_args(this);
14038
    }
14039
 
14040
    @Override
14041
    public void clear() {
14042
      setItemIdIsSet(false);
14043
      this.itemId = 0;
14044
      setWarehouseIdIsSet(false);
14045
      this.warehouseId = 0;
5967 rajveer 14046
      setSourceIdIsSet(false);
14047
      this.sourceId = 0;
14048
      setOrderIdIsSet(false);
14049
      this.orderId = 0;
5945 mandeep.dh 14050
      setQuantityIsSet(false);
14051
      this.quantity = 0.0;
14052
    }
14053
 
14054
    public long getItemId() {
14055
      return this.itemId;
14056
    }
14057
 
14058
    public void setItemId(long itemId) {
14059
      this.itemId = itemId;
14060
      setItemIdIsSet(true);
14061
    }
14062
 
14063
    public void unsetItemId() {
14064
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
14065
    }
14066
 
14067
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
14068
    public boolean isSetItemId() {
14069
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
14070
    }
14071
 
14072
    public void setItemIdIsSet(boolean value) {
14073
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
14074
    }
14075
 
14076
    public long getWarehouseId() {
14077
      return this.warehouseId;
14078
    }
14079
 
14080
    public void setWarehouseId(long warehouseId) {
14081
      this.warehouseId = warehouseId;
14082
      setWarehouseIdIsSet(true);
14083
    }
14084
 
14085
    public void unsetWarehouseId() {
14086
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
14087
    }
14088
 
14089
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
14090
    public boolean isSetWarehouseId() {
14091
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
14092
    }
14093
 
14094
    public void setWarehouseIdIsSet(boolean value) {
14095
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
14096
    }
14097
 
5967 rajveer 14098
    public long getSourceId() {
14099
      return this.sourceId;
14100
    }
14101
 
14102
    public void setSourceId(long sourceId) {
14103
      this.sourceId = sourceId;
14104
      setSourceIdIsSet(true);
14105
    }
14106
 
14107
    public void unsetSourceId() {
14108
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
14109
    }
14110
 
14111
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
14112
    public boolean isSetSourceId() {
14113
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
14114
    }
14115
 
14116
    public void setSourceIdIsSet(boolean value) {
14117
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
14118
    }
14119
 
14120
    public long getOrderId() {
14121
      return this.orderId;
14122
    }
14123
 
14124
    public void setOrderId(long orderId) {
14125
      this.orderId = orderId;
14126
      setOrderIdIsSet(true);
14127
    }
14128
 
14129
    public void unsetOrderId() {
14130
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
14131
    }
14132
 
14133
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
14134
    public boolean isSetOrderId() {
14135
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
14136
    }
14137
 
14138
    public void setOrderIdIsSet(boolean value) {
14139
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
14140
    }
14141
 
5945 mandeep.dh 14142
    public double getQuantity() {
14143
      return this.quantity;
14144
    }
14145
 
14146
    public void setQuantity(double quantity) {
14147
      this.quantity = quantity;
14148
      setQuantityIsSet(true);
14149
    }
14150
 
14151
    public void unsetQuantity() {
14152
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
14153
    }
14154
 
14155
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
14156
    public boolean isSetQuantity() {
14157
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
14158
    }
14159
 
14160
    public void setQuantityIsSet(boolean value) {
14161
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
14162
    }
14163
 
14164
    public void setFieldValue(_Fields field, Object value) {
14165
      switch (field) {
14166
      case ITEM_ID:
14167
        if (value == null) {
14168
          unsetItemId();
14169
        } else {
14170
          setItemId((Long)value);
14171
        }
14172
        break;
14173
 
14174
      case WAREHOUSE_ID:
14175
        if (value == null) {
14176
          unsetWarehouseId();
14177
        } else {
14178
          setWarehouseId((Long)value);
14179
        }
14180
        break;
14181
 
5967 rajveer 14182
      case SOURCE_ID:
14183
        if (value == null) {
14184
          unsetSourceId();
14185
        } else {
14186
          setSourceId((Long)value);
14187
        }
14188
        break;
14189
 
14190
      case ORDER_ID:
14191
        if (value == null) {
14192
          unsetOrderId();
14193
        } else {
14194
          setOrderId((Long)value);
14195
        }
14196
        break;
14197
 
5945 mandeep.dh 14198
      case QUANTITY:
14199
        if (value == null) {
14200
          unsetQuantity();
14201
        } else {
14202
          setQuantity((Double)value);
14203
        }
14204
        break;
14205
 
14206
      }
14207
    }
14208
 
14209
    public Object getFieldValue(_Fields field) {
14210
      switch (field) {
14211
      case ITEM_ID:
14212
        return Long.valueOf(getItemId());
14213
 
14214
      case WAREHOUSE_ID:
14215
        return Long.valueOf(getWarehouseId());
14216
 
5967 rajveer 14217
      case SOURCE_ID:
14218
        return Long.valueOf(getSourceId());
14219
 
14220
      case ORDER_ID:
14221
        return Long.valueOf(getOrderId());
14222
 
5945 mandeep.dh 14223
      case QUANTITY:
14224
        return Double.valueOf(getQuantity());
14225
 
14226
      }
14227
      throw new IllegalStateException();
14228
    }
14229
 
14230
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14231
    public boolean isSet(_Fields field) {
14232
      if (field == null) {
14233
        throw new IllegalArgumentException();
14234
      }
14235
 
14236
      switch (field) {
14237
      case ITEM_ID:
14238
        return isSetItemId();
14239
      case WAREHOUSE_ID:
14240
        return isSetWarehouseId();
5967 rajveer 14241
      case SOURCE_ID:
14242
        return isSetSourceId();
14243
      case ORDER_ID:
14244
        return isSetOrderId();
5945 mandeep.dh 14245
      case QUANTITY:
14246
        return isSetQuantity();
14247
      }
14248
      throw new IllegalStateException();
14249
    }
14250
 
14251
    @Override
14252
    public boolean equals(Object that) {
14253
      if (that == null)
14254
        return false;
14255
      if (that instanceof reduceReservationCount_args)
14256
        return this.equals((reduceReservationCount_args)that);
14257
      return false;
14258
    }
14259
 
14260
    public boolean equals(reduceReservationCount_args that) {
14261
      if (that == null)
14262
        return false;
14263
 
14264
      boolean this_present_itemId = true;
14265
      boolean that_present_itemId = true;
14266
      if (this_present_itemId || that_present_itemId) {
14267
        if (!(this_present_itemId && that_present_itemId))
14268
          return false;
14269
        if (this.itemId != that.itemId)
14270
          return false;
14271
      }
14272
 
14273
      boolean this_present_warehouseId = true;
14274
      boolean that_present_warehouseId = true;
14275
      if (this_present_warehouseId || that_present_warehouseId) {
14276
        if (!(this_present_warehouseId && that_present_warehouseId))
14277
          return false;
14278
        if (this.warehouseId != that.warehouseId)
14279
          return false;
14280
      }
14281
 
5967 rajveer 14282
      boolean this_present_sourceId = true;
14283
      boolean that_present_sourceId = true;
14284
      if (this_present_sourceId || that_present_sourceId) {
14285
        if (!(this_present_sourceId && that_present_sourceId))
14286
          return false;
14287
        if (this.sourceId != that.sourceId)
14288
          return false;
14289
      }
14290
 
14291
      boolean this_present_orderId = true;
14292
      boolean that_present_orderId = true;
14293
      if (this_present_orderId || that_present_orderId) {
14294
        if (!(this_present_orderId && that_present_orderId))
14295
          return false;
14296
        if (this.orderId != that.orderId)
14297
          return false;
14298
      }
14299
 
5945 mandeep.dh 14300
      boolean this_present_quantity = true;
14301
      boolean that_present_quantity = true;
14302
      if (this_present_quantity || that_present_quantity) {
14303
        if (!(this_present_quantity && that_present_quantity))
14304
          return false;
14305
        if (this.quantity != that.quantity)
14306
          return false;
14307
      }
14308
 
14309
      return true;
14310
    }
14311
 
14312
    @Override
14313
    public int hashCode() {
14314
      return 0;
14315
    }
14316
 
14317
    public int compareTo(reduceReservationCount_args other) {
14318
      if (!getClass().equals(other.getClass())) {
14319
        return getClass().getName().compareTo(other.getClass().getName());
14320
      }
14321
 
14322
      int lastComparison = 0;
14323
      reduceReservationCount_args typedOther = (reduceReservationCount_args)other;
14324
 
14325
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
14326
      if (lastComparison != 0) {
14327
        return lastComparison;
14328
      }
14329
      if (isSetItemId()) {
14330
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
14331
        if (lastComparison != 0) {
14332
          return lastComparison;
14333
        }
14334
      }
14335
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
14336
      if (lastComparison != 0) {
14337
        return lastComparison;
14338
      }
14339
      if (isSetWarehouseId()) {
14340
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
14341
        if (lastComparison != 0) {
14342
          return lastComparison;
14343
        }
14344
      }
5967 rajveer 14345
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
14346
      if (lastComparison != 0) {
14347
        return lastComparison;
14348
      }
14349
      if (isSetSourceId()) {
14350
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
14351
        if (lastComparison != 0) {
14352
          return lastComparison;
14353
        }
14354
      }
14355
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
14356
      if (lastComparison != 0) {
14357
        return lastComparison;
14358
      }
14359
      if (isSetOrderId()) {
14360
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
14361
        if (lastComparison != 0) {
14362
          return lastComparison;
14363
        }
14364
      }
5945 mandeep.dh 14365
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
14366
      if (lastComparison != 0) {
14367
        return lastComparison;
14368
      }
14369
      if (isSetQuantity()) {
14370
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
14371
        if (lastComparison != 0) {
14372
          return lastComparison;
14373
        }
14374
      }
14375
      return 0;
14376
    }
14377
 
14378
    public _Fields fieldForId(int fieldId) {
14379
      return _Fields.findByThriftId(fieldId);
14380
    }
14381
 
14382
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14383
      org.apache.thrift.protocol.TField field;
14384
      iprot.readStructBegin();
14385
      while (true)
14386
      {
14387
        field = iprot.readFieldBegin();
14388
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14389
          break;
14390
        }
14391
        switch (field.id) {
14392
          case 1: // ITEM_ID
14393
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14394
              this.itemId = iprot.readI64();
14395
              setItemIdIsSet(true);
14396
            } else { 
14397
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14398
            }
14399
            break;
14400
          case 2: // WAREHOUSE_ID
14401
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14402
              this.warehouseId = iprot.readI64();
14403
              setWarehouseIdIsSet(true);
14404
            } else { 
14405
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14406
            }
14407
            break;
5967 rajveer 14408
          case 3: // SOURCE_ID
14409
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14410
              this.sourceId = iprot.readI64();
14411
              setSourceIdIsSet(true);
14412
            } else { 
14413
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14414
            }
14415
            break;
14416
          case 4: // ORDER_ID
14417
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14418
              this.orderId = iprot.readI64();
14419
              setOrderIdIsSet(true);
14420
            } else { 
14421
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14422
            }
14423
            break;
14424
          case 5: // QUANTITY
5945 mandeep.dh 14425
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
14426
              this.quantity = iprot.readDouble();
14427
              setQuantityIsSet(true);
14428
            } else { 
14429
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14430
            }
14431
            break;
14432
          default:
14433
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14434
        }
14435
        iprot.readFieldEnd();
14436
      }
14437
      iprot.readStructEnd();
14438
      validate();
14439
    }
14440
 
14441
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14442
      validate();
14443
 
14444
      oprot.writeStructBegin(STRUCT_DESC);
14445
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
14446
      oprot.writeI64(this.itemId);
14447
      oprot.writeFieldEnd();
14448
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
14449
      oprot.writeI64(this.warehouseId);
14450
      oprot.writeFieldEnd();
5967 rajveer 14451
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
14452
      oprot.writeI64(this.sourceId);
14453
      oprot.writeFieldEnd();
14454
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
14455
      oprot.writeI64(this.orderId);
14456
      oprot.writeFieldEnd();
5945 mandeep.dh 14457
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
14458
      oprot.writeDouble(this.quantity);
14459
      oprot.writeFieldEnd();
14460
      oprot.writeFieldStop();
14461
      oprot.writeStructEnd();
14462
    }
14463
 
14464
    @Override
14465
    public String toString() {
14466
      StringBuilder sb = new StringBuilder("reduceReservationCount_args(");
14467
      boolean first = true;
14468
 
14469
      sb.append("itemId:");
14470
      sb.append(this.itemId);
14471
      first = false;
14472
      if (!first) sb.append(", ");
14473
      sb.append("warehouseId:");
14474
      sb.append(this.warehouseId);
14475
      first = false;
14476
      if (!first) sb.append(", ");
5967 rajveer 14477
      sb.append("sourceId:");
14478
      sb.append(this.sourceId);
14479
      first = false;
14480
      if (!first) sb.append(", ");
14481
      sb.append("orderId:");
14482
      sb.append(this.orderId);
14483
      first = false;
14484
      if (!first) sb.append(", ");
5945 mandeep.dh 14485
      sb.append("quantity:");
14486
      sb.append(this.quantity);
14487
      first = false;
14488
      sb.append(")");
14489
      return sb.toString();
14490
    }
14491
 
14492
    public void validate() throws org.apache.thrift.TException {
14493
      // check for required fields
14494
    }
14495
 
14496
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14497
      try {
14498
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14499
      } catch (org.apache.thrift.TException te) {
14500
        throw new java.io.IOException(te);
14501
      }
14502
    }
14503
 
14504
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14505
      try {
14506
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14507
      } catch (org.apache.thrift.TException te) {
14508
        throw new java.io.IOException(te);
14509
      }
14510
    }
14511
 
14512
  }
14513
 
14514
  public static class reduceReservationCount_result implements org.apache.thrift.TBase<reduceReservationCount_result, reduceReservationCount_result._Fields>, java.io.Serializable, Cloneable   {
14515
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reduceReservationCount_result");
14516
 
14517
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.BOOL, (short)0);
14518
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
14519
 
14520
    private boolean success; // required
14521
    private InventoryServiceException cex; // required
14522
 
14523
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14524
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14525
      SUCCESS((short)0, "success"),
14526
      CEX((short)1, "cex");
14527
 
14528
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14529
 
14530
      static {
14531
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14532
          byName.put(field.getFieldName(), field);
14533
        }
14534
      }
14535
 
14536
      /**
14537
       * Find the _Fields constant that matches fieldId, or null if its not found.
14538
       */
14539
      public static _Fields findByThriftId(int fieldId) {
14540
        switch(fieldId) {
14541
          case 0: // SUCCESS
14542
            return SUCCESS;
14543
          case 1: // CEX
14544
            return CEX;
14545
          default:
14546
            return null;
14547
        }
14548
      }
14549
 
14550
      /**
14551
       * Find the _Fields constant that matches fieldId, throwing an exception
14552
       * if it is not found.
14553
       */
14554
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14555
        _Fields fields = findByThriftId(fieldId);
14556
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14557
        return fields;
14558
      }
14559
 
14560
      /**
14561
       * Find the _Fields constant that matches name, or null if its not found.
14562
       */
14563
      public static _Fields findByName(String name) {
14564
        return byName.get(name);
14565
      }
14566
 
14567
      private final short _thriftId;
14568
      private final String _fieldName;
14569
 
14570
      _Fields(short thriftId, String fieldName) {
14571
        _thriftId = thriftId;
14572
        _fieldName = fieldName;
14573
      }
14574
 
14575
      public short getThriftFieldId() {
14576
        return _thriftId;
14577
      }
14578
 
14579
      public String getFieldName() {
14580
        return _fieldName;
14581
      }
14582
    }
14583
 
14584
    // isset id assignments
14585
    private static final int __SUCCESS_ISSET_ID = 0;
14586
    private BitSet __isset_bit_vector = new BitSet(1);
14587
 
14588
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14589
    static {
14590
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14591
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14592
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
14593
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14594
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
14595
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14596
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reduceReservationCount_result.class, metaDataMap);
14597
    }
14598
 
14599
    public reduceReservationCount_result() {
14600
    }
14601
 
14602
    public reduceReservationCount_result(
14603
      boolean success,
14604
      InventoryServiceException cex)
14605
    {
14606
      this();
14607
      this.success = success;
14608
      setSuccessIsSet(true);
14609
      this.cex = cex;
14610
    }
14611
 
14612
    /**
14613
     * Performs a deep copy on <i>other</i>.
14614
     */
14615
    public reduceReservationCount_result(reduceReservationCount_result other) {
14616
      __isset_bit_vector.clear();
14617
      __isset_bit_vector.or(other.__isset_bit_vector);
14618
      this.success = other.success;
14619
      if (other.isSetCex()) {
14620
        this.cex = new InventoryServiceException(other.cex);
14621
      }
14622
    }
14623
 
14624
    public reduceReservationCount_result deepCopy() {
14625
      return new reduceReservationCount_result(this);
14626
    }
14627
 
14628
    @Override
14629
    public void clear() {
14630
      setSuccessIsSet(false);
14631
      this.success = false;
14632
      this.cex = null;
14633
    }
14634
 
14635
    public boolean isSuccess() {
14636
      return this.success;
14637
    }
14638
 
14639
    public void setSuccess(boolean success) {
14640
      this.success = success;
14641
      setSuccessIsSet(true);
14642
    }
14643
 
14644
    public void unsetSuccess() {
14645
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
14646
    }
14647
 
14648
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
14649
    public boolean isSetSuccess() {
14650
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
14651
    }
14652
 
14653
    public void setSuccessIsSet(boolean value) {
14654
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
14655
    }
14656
 
14657
    public InventoryServiceException getCex() {
14658
      return this.cex;
14659
    }
14660
 
14661
    public void setCex(InventoryServiceException cex) {
14662
      this.cex = cex;
14663
    }
14664
 
14665
    public void unsetCex() {
14666
      this.cex = null;
14667
    }
14668
 
14669
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
14670
    public boolean isSetCex() {
14671
      return this.cex != null;
14672
    }
14673
 
14674
    public void setCexIsSet(boolean value) {
14675
      if (!value) {
14676
        this.cex = null;
14677
      }
14678
    }
14679
 
14680
    public void setFieldValue(_Fields field, Object value) {
14681
      switch (field) {
14682
      case SUCCESS:
14683
        if (value == null) {
14684
          unsetSuccess();
14685
        } else {
14686
          setSuccess((Boolean)value);
14687
        }
14688
        break;
14689
 
14690
      case CEX:
14691
        if (value == null) {
14692
          unsetCex();
14693
        } else {
14694
          setCex((InventoryServiceException)value);
14695
        }
14696
        break;
14697
 
14698
      }
14699
    }
14700
 
14701
    public Object getFieldValue(_Fields field) {
14702
      switch (field) {
14703
      case SUCCESS:
14704
        return Boolean.valueOf(isSuccess());
14705
 
14706
      case CEX:
14707
        return getCex();
14708
 
14709
      }
14710
      throw new IllegalStateException();
14711
    }
14712
 
14713
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14714
    public boolean isSet(_Fields field) {
14715
      if (field == null) {
14716
        throw new IllegalArgumentException();
14717
      }
14718
 
14719
      switch (field) {
14720
      case SUCCESS:
14721
        return isSetSuccess();
14722
      case CEX:
14723
        return isSetCex();
14724
      }
14725
      throw new IllegalStateException();
14726
    }
14727
 
14728
    @Override
14729
    public boolean equals(Object that) {
14730
      if (that == null)
14731
        return false;
14732
      if (that instanceof reduceReservationCount_result)
14733
        return this.equals((reduceReservationCount_result)that);
14734
      return false;
14735
    }
14736
 
14737
    public boolean equals(reduceReservationCount_result that) {
14738
      if (that == null)
14739
        return false;
14740
 
14741
      boolean this_present_success = true;
14742
      boolean that_present_success = true;
14743
      if (this_present_success || that_present_success) {
14744
        if (!(this_present_success && that_present_success))
14745
          return false;
14746
        if (this.success != that.success)
14747
          return false;
14748
      }
14749
 
14750
      boolean this_present_cex = true && this.isSetCex();
14751
      boolean that_present_cex = true && that.isSetCex();
14752
      if (this_present_cex || that_present_cex) {
14753
        if (!(this_present_cex && that_present_cex))
14754
          return false;
14755
        if (!this.cex.equals(that.cex))
14756
          return false;
14757
      }
14758
 
14759
      return true;
14760
    }
14761
 
14762
    @Override
14763
    public int hashCode() {
14764
      return 0;
14765
    }
14766
 
14767
    public int compareTo(reduceReservationCount_result other) {
14768
      if (!getClass().equals(other.getClass())) {
14769
        return getClass().getName().compareTo(other.getClass().getName());
14770
      }
14771
 
14772
      int lastComparison = 0;
14773
      reduceReservationCount_result typedOther = (reduceReservationCount_result)other;
14774
 
14775
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
14776
      if (lastComparison != 0) {
14777
        return lastComparison;
14778
      }
14779
      if (isSetSuccess()) {
14780
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
14781
        if (lastComparison != 0) {
14782
          return lastComparison;
14783
        }
14784
      }
14785
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
14786
      if (lastComparison != 0) {
14787
        return lastComparison;
14788
      }
14789
      if (isSetCex()) {
14790
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
14791
        if (lastComparison != 0) {
14792
          return lastComparison;
14793
        }
14794
      }
14795
      return 0;
14796
    }
14797
 
14798
    public _Fields fieldForId(int fieldId) {
14799
      return _Fields.findByThriftId(fieldId);
14800
    }
14801
 
14802
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14803
      org.apache.thrift.protocol.TField field;
14804
      iprot.readStructBegin();
14805
      while (true)
14806
      {
14807
        field = iprot.readFieldBegin();
14808
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14809
          break;
14810
        }
14811
        switch (field.id) {
14812
          case 0: // SUCCESS
14813
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
14814
              this.success = iprot.readBool();
14815
              setSuccessIsSet(true);
14816
            } else { 
14817
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14818
            }
14819
            break;
14820
          case 1: // CEX
14821
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
14822
              this.cex = new InventoryServiceException();
14823
              this.cex.read(iprot);
14824
            } else { 
14825
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14826
            }
14827
            break;
14828
          default:
14829
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14830
        }
14831
        iprot.readFieldEnd();
14832
      }
14833
      iprot.readStructEnd();
14834
      validate();
14835
    }
14836
 
14837
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14838
      oprot.writeStructBegin(STRUCT_DESC);
14839
 
14840
      if (this.isSetSuccess()) {
14841
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
14842
        oprot.writeBool(this.success);
14843
        oprot.writeFieldEnd();
14844
      } else if (this.isSetCex()) {
14845
        oprot.writeFieldBegin(CEX_FIELD_DESC);
14846
        this.cex.write(oprot);
14847
        oprot.writeFieldEnd();
14848
      }
14849
      oprot.writeFieldStop();
14850
      oprot.writeStructEnd();
14851
    }
14852
 
14853
    @Override
14854
    public String toString() {
14855
      StringBuilder sb = new StringBuilder("reduceReservationCount_result(");
14856
      boolean first = true;
14857
 
14858
      sb.append("success:");
14859
      sb.append(this.success);
14860
      first = false;
14861
      if (!first) sb.append(", ");
14862
      sb.append("cex:");
14863
      if (this.cex == null) {
14864
        sb.append("null");
14865
      } else {
14866
        sb.append(this.cex);
14867
      }
14868
      first = false;
14869
      sb.append(")");
14870
      return sb.toString();
14871
    }
14872
 
14873
    public void validate() throws org.apache.thrift.TException {
14874
      // check for required fields
14875
    }
14876
 
14877
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14878
      try {
14879
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14880
      } catch (org.apache.thrift.TException te) {
14881
        throw new java.io.IOException(te);
14882
      }
14883
    }
14884
 
14885
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14886
      try {
14887
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14888
      } catch (org.apache.thrift.TException te) {
14889
        throw new java.io.IOException(te);
14890
      }
14891
    }
14892
 
14893
  }
14894
 
14895
  public static class getItemPricing_args implements org.apache.thrift.TBase<getItemPricing_args, getItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
14896
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemPricing_args");
14897
 
14898
    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);
14899
    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);
14900
 
14901
    private long itemId; // required
14902
    private long vendorId; // required
14903
 
14904
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14905
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14906
      ITEM_ID((short)1, "itemId"),
14907
      VENDOR_ID((short)2, "vendorId");
14908
 
14909
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14910
 
14911
      static {
14912
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14913
          byName.put(field.getFieldName(), field);
14914
        }
14915
      }
14916
 
14917
      /**
14918
       * Find the _Fields constant that matches fieldId, or null if its not found.
14919
       */
14920
      public static _Fields findByThriftId(int fieldId) {
14921
        switch(fieldId) {
14922
          case 1: // ITEM_ID
14923
            return ITEM_ID;
14924
          case 2: // VENDOR_ID
14925
            return VENDOR_ID;
14926
          default:
14927
            return null;
14928
        }
14929
      }
14930
 
14931
      /**
14932
       * Find the _Fields constant that matches fieldId, throwing an exception
14933
       * if it is not found.
14934
       */
14935
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14936
        _Fields fields = findByThriftId(fieldId);
14937
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14938
        return fields;
14939
      }
14940
 
14941
      /**
14942
       * Find the _Fields constant that matches name, or null if its not found.
14943
       */
14944
      public static _Fields findByName(String name) {
14945
        return byName.get(name);
14946
      }
14947
 
14948
      private final short _thriftId;
14949
      private final String _fieldName;
14950
 
14951
      _Fields(short thriftId, String fieldName) {
14952
        _thriftId = thriftId;
14953
        _fieldName = fieldName;
14954
      }
14955
 
14956
      public short getThriftFieldId() {
14957
        return _thriftId;
14958
      }
14959
 
14960
      public String getFieldName() {
14961
        return _fieldName;
14962
      }
14963
    }
14964
 
14965
    // isset id assignments
14966
    private static final int __ITEMID_ISSET_ID = 0;
14967
    private static final int __VENDORID_ISSET_ID = 1;
14968
    private BitSet __isset_bit_vector = new BitSet(2);
14969
 
14970
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14971
    static {
14972
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14973
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14974
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14975
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14976
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14977
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14978
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemPricing_args.class, metaDataMap);
14979
    }
14980
 
14981
    public getItemPricing_args() {
14982
    }
14983
 
14984
    public getItemPricing_args(
14985
      long itemId,
14986
      long vendorId)
14987
    {
14988
      this();
14989
      this.itemId = itemId;
14990
      setItemIdIsSet(true);
14991
      this.vendorId = vendorId;
14992
      setVendorIdIsSet(true);
14993
    }
14994
 
14995
    /**
14996
     * Performs a deep copy on <i>other</i>.
14997
     */
14998
    public getItemPricing_args(getItemPricing_args other) {
14999
      __isset_bit_vector.clear();
15000
      __isset_bit_vector.or(other.__isset_bit_vector);
15001
      this.itemId = other.itemId;
15002
      this.vendorId = other.vendorId;
15003
    }
15004
 
15005
    public getItemPricing_args deepCopy() {
15006
      return new getItemPricing_args(this);
15007
    }
15008
 
15009
    @Override
15010
    public void clear() {
15011
      setItemIdIsSet(false);
15012
      this.itemId = 0;
15013
      setVendorIdIsSet(false);
15014
      this.vendorId = 0;
15015
    }
15016
 
15017
    public long getItemId() {
15018
      return this.itemId;
15019
    }
15020
 
15021
    public void setItemId(long itemId) {
15022
      this.itemId = itemId;
15023
      setItemIdIsSet(true);
15024
    }
15025
 
15026
    public void unsetItemId() {
15027
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
15028
    }
15029
 
15030
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
15031
    public boolean isSetItemId() {
15032
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
15033
    }
15034
 
15035
    public void setItemIdIsSet(boolean value) {
15036
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
15037
    }
15038
 
15039
    public long getVendorId() {
15040
      return this.vendorId;
15041
    }
15042
 
15043
    public void setVendorId(long vendorId) {
15044
      this.vendorId = vendorId;
15045
      setVendorIdIsSet(true);
15046
    }
15047
 
15048
    public void unsetVendorId() {
15049
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
15050
    }
15051
 
15052
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
15053
    public boolean isSetVendorId() {
15054
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
15055
    }
15056
 
15057
    public void setVendorIdIsSet(boolean value) {
15058
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
15059
    }
15060
 
15061
    public void setFieldValue(_Fields field, Object value) {
15062
      switch (field) {
15063
      case ITEM_ID:
15064
        if (value == null) {
15065
          unsetItemId();
15066
        } else {
15067
          setItemId((Long)value);
15068
        }
15069
        break;
15070
 
15071
      case VENDOR_ID:
15072
        if (value == null) {
15073
          unsetVendorId();
15074
        } else {
15075
          setVendorId((Long)value);
15076
        }
15077
        break;
15078
 
15079
      }
15080
    }
15081
 
15082
    public Object getFieldValue(_Fields field) {
15083
      switch (field) {
15084
      case ITEM_ID:
15085
        return Long.valueOf(getItemId());
15086
 
15087
      case VENDOR_ID:
15088
        return Long.valueOf(getVendorId());
15089
 
15090
      }
15091
      throw new IllegalStateException();
15092
    }
15093
 
15094
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15095
    public boolean isSet(_Fields field) {
15096
      if (field == null) {
15097
        throw new IllegalArgumentException();
15098
      }
15099
 
15100
      switch (field) {
15101
      case ITEM_ID:
15102
        return isSetItemId();
15103
      case VENDOR_ID:
15104
        return isSetVendorId();
15105
      }
15106
      throw new IllegalStateException();
15107
    }
15108
 
15109
    @Override
15110
    public boolean equals(Object that) {
15111
      if (that == null)
15112
        return false;
15113
      if (that instanceof getItemPricing_args)
15114
        return this.equals((getItemPricing_args)that);
15115
      return false;
15116
    }
15117
 
15118
    public boolean equals(getItemPricing_args that) {
15119
      if (that == null)
15120
        return false;
15121
 
15122
      boolean this_present_itemId = true;
15123
      boolean that_present_itemId = true;
15124
      if (this_present_itemId || that_present_itemId) {
15125
        if (!(this_present_itemId && that_present_itemId))
15126
          return false;
15127
        if (this.itemId != that.itemId)
15128
          return false;
15129
      }
15130
 
15131
      boolean this_present_vendorId = true;
15132
      boolean that_present_vendorId = true;
15133
      if (this_present_vendorId || that_present_vendorId) {
15134
        if (!(this_present_vendorId && that_present_vendorId))
15135
          return false;
15136
        if (this.vendorId != that.vendorId)
15137
          return false;
15138
      }
15139
 
15140
      return true;
15141
    }
15142
 
15143
    @Override
15144
    public int hashCode() {
15145
      return 0;
15146
    }
15147
 
15148
    public int compareTo(getItemPricing_args other) {
15149
      if (!getClass().equals(other.getClass())) {
15150
        return getClass().getName().compareTo(other.getClass().getName());
15151
      }
15152
 
15153
      int lastComparison = 0;
15154
      getItemPricing_args typedOther = (getItemPricing_args)other;
15155
 
15156
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
15157
      if (lastComparison != 0) {
15158
        return lastComparison;
15159
      }
15160
      if (isSetItemId()) {
15161
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
15162
        if (lastComparison != 0) {
15163
          return lastComparison;
15164
        }
15165
      }
15166
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
15167
      if (lastComparison != 0) {
15168
        return lastComparison;
15169
      }
15170
      if (isSetVendorId()) {
15171
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
15172
        if (lastComparison != 0) {
15173
          return lastComparison;
15174
        }
15175
      }
15176
      return 0;
15177
    }
15178
 
15179
    public _Fields fieldForId(int fieldId) {
15180
      return _Fields.findByThriftId(fieldId);
15181
    }
15182
 
15183
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15184
      org.apache.thrift.protocol.TField field;
15185
      iprot.readStructBegin();
15186
      while (true)
15187
      {
15188
        field = iprot.readFieldBegin();
15189
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15190
          break;
15191
        }
15192
        switch (field.id) {
15193
          case 1: // ITEM_ID
15194
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15195
              this.itemId = iprot.readI64();
15196
              setItemIdIsSet(true);
15197
            } else { 
15198
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15199
            }
15200
            break;
15201
          case 2: // VENDOR_ID
15202
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15203
              this.vendorId = iprot.readI64();
15204
              setVendorIdIsSet(true);
15205
            } else { 
15206
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15207
            }
15208
            break;
15209
          default:
15210
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15211
        }
15212
        iprot.readFieldEnd();
15213
      }
15214
      iprot.readStructEnd();
15215
      validate();
15216
    }
15217
 
15218
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15219
      validate();
15220
 
15221
      oprot.writeStructBegin(STRUCT_DESC);
15222
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
15223
      oprot.writeI64(this.itemId);
15224
      oprot.writeFieldEnd();
15225
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
15226
      oprot.writeI64(this.vendorId);
15227
      oprot.writeFieldEnd();
15228
      oprot.writeFieldStop();
15229
      oprot.writeStructEnd();
15230
    }
15231
 
15232
    @Override
15233
    public String toString() {
15234
      StringBuilder sb = new StringBuilder("getItemPricing_args(");
15235
      boolean first = true;
15236
 
15237
      sb.append("itemId:");
15238
      sb.append(this.itemId);
15239
      first = false;
15240
      if (!first) sb.append(", ");
15241
      sb.append("vendorId:");
15242
      sb.append(this.vendorId);
15243
      first = false;
15244
      sb.append(")");
15245
      return sb.toString();
15246
    }
15247
 
15248
    public void validate() throws org.apache.thrift.TException {
15249
      // check for required fields
15250
    }
15251
 
15252
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15253
      try {
15254
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15255
      } catch (org.apache.thrift.TException te) {
15256
        throw new java.io.IOException(te);
15257
      }
15258
    }
15259
 
15260
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15261
      try {
15262
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15263
      } catch (org.apache.thrift.TException te) {
15264
        throw new java.io.IOException(te);
15265
      }
15266
    }
15267
 
15268
  }
15269
 
15270
  public static class getItemPricing_result implements org.apache.thrift.TBase<getItemPricing_result, getItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
15271
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemPricing_result");
15272
 
15273
    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);
15274
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
15275
 
15276
    private VendorItemPricing success; // required
15277
    private InventoryServiceException cex; // required
15278
 
15279
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15280
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15281
      SUCCESS((short)0, "success"),
15282
      CEX((short)1, "cex");
15283
 
15284
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15285
 
15286
      static {
15287
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15288
          byName.put(field.getFieldName(), field);
15289
        }
15290
      }
15291
 
15292
      /**
15293
       * Find the _Fields constant that matches fieldId, or null if its not found.
15294
       */
15295
      public static _Fields findByThriftId(int fieldId) {
15296
        switch(fieldId) {
15297
          case 0: // SUCCESS
15298
            return SUCCESS;
15299
          case 1: // CEX
15300
            return CEX;
15301
          default:
15302
            return null;
15303
        }
15304
      }
15305
 
15306
      /**
15307
       * Find the _Fields constant that matches fieldId, throwing an exception
15308
       * if it is not found.
15309
       */
15310
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15311
        _Fields fields = findByThriftId(fieldId);
15312
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15313
        return fields;
15314
      }
15315
 
15316
      /**
15317
       * Find the _Fields constant that matches name, or null if its not found.
15318
       */
15319
      public static _Fields findByName(String name) {
15320
        return byName.get(name);
15321
      }
15322
 
15323
      private final short _thriftId;
15324
      private final String _fieldName;
15325
 
15326
      _Fields(short thriftId, String fieldName) {
15327
        _thriftId = thriftId;
15328
        _fieldName = fieldName;
15329
      }
15330
 
15331
      public short getThriftFieldId() {
15332
        return _thriftId;
15333
      }
15334
 
15335
      public String getFieldName() {
15336
        return _fieldName;
15337
      }
15338
    }
15339
 
15340
    // isset id assignments
15341
 
15342
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15343
    static {
15344
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15345
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15346
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class)));
15347
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15348
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
15349
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15350
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemPricing_result.class, metaDataMap);
15351
    }
15352
 
15353
    public getItemPricing_result() {
15354
    }
15355
 
15356
    public getItemPricing_result(
15357
      VendorItemPricing success,
15358
      InventoryServiceException cex)
15359
    {
15360
      this();
15361
      this.success = success;
15362
      this.cex = cex;
15363
    }
15364
 
15365
    /**
15366
     * Performs a deep copy on <i>other</i>.
15367
     */
15368
    public getItemPricing_result(getItemPricing_result other) {
15369
      if (other.isSetSuccess()) {
15370
        this.success = new VendorItemPricing(other.success);
15371
      }
15372
      if (other.isSetCex()) {
15373
        this.cex = new InventoryServiceException(other.cex);
15374
      }
15375
    }
15376
 
15377
    public getItemPricing_result deepCopy() {
15378
      return new getItemPricing_result(this);
15379
    }
15380
 
15381
    @Override
15382
    public void clear() {
15383
      this.success = null;
15384
      this.cex = null;
15385
    }
15386
 
15387
    public VendorItemPricing getSuccess() {
15388
      return this.success;
15389
    }
15390
 
15391
    public void setSuccess(VendorItemPricing success) {
15392
      this.success = success;
15393
    }
15394
 
15395
    public void unsetSuccess() {
15396
      this.success = null;
15397
    }
15398
 
15399
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
15400
    public boolean isSetSuccess() {
15401
      return this.success != null;
15402
    }
15403
 
15404
    public void setSuccessIsSet(boolean value) {
15405
      if (!value) {
15406
        this.success = null;
15407
      }
15408
    }
15409
 
15410
    public InventoryServiceException getCex() {
15411
      return this.cex;
15412
    }
15413
 
15414
    public void setCex(InventoryServiceException cex) {
15415
      this.cex = cex;
15416
    }
15417
 
15418
    public void unsetCex() {
15419
      this.cex = null;
15420
    }
15421
 
15422
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
15423
    public boolean isSetCex() {
15424
      return this.cex != null;
15425
    }
15426
 
15427
    public void setCexIsSet(boolean value) {
15428
      if (!value) {
15429
        this.cex = null;
15430
      }
15431
    }
15432
 
15433
    public void setFieldValue(_Fields field, Object value) {
15434
      switch (field) {
15435
      case SUCCESS:
15436
        if (value == null) {
15437
          unsetSuccess();
15438
        } else {
15439
          setSuccess((VendorItemPricing)value);
15440
        }
15441
        break;
15442
 
15443
      case CEX:
15444
        if (value == null) {
15445
          unsetCex();
15446
        } else {
15447
          setCex((InventoryServiceException)value);
15448
        }
15449
        break;
15450
 
15451
      }
15452
    }
15453
 
15454
    public Object getFieldValue(_Fields field) {
15455
      switch (field) {
15456
      case SUCCESS:
15457
        return getSuccess();
15458
 
15459
      case CEX:
15460
        return getCex();
15461
 
15462
      }
15463
      throw new IllegalStateException();
15464
    }
15465
 
15466
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15467
    public boolean isSet(_Fields field) {
15468
      if (field == null) {
15469
        throw new IllegalArgumentException();
15470
      }
15471
 
15472
      switch (field) {
15473
      case SUCCESS:
15474
        return isSetSuccess();
15475
      case CEX:
15476
        return isSetCex();
15477
      }
15478
      throw new IllegalStateException();
15479
    }
15480
 
15481
    @Override
15482
    public boolean equals(Object that) {
15483
      if (that == null)
15484
        return false;
15485
      if (that instanceof getItemPricing_result)
15486
        return this.equals((getItemPricing_result)that);
15487
      return false;
15488
    }
15489
 
15490
    public boolean equals(getItemPricing_result that) {
15491
      if (that == null)
15492
        return false;
15493
 
15494
      boolean this_present_success = true && this.isSetSuccess();
15495
      boolean that_present_success = true && that.isSetSuccess();
15496
      if (this_present_success || that_present_success) {
15497
        if (!(this_present_success && that_present_success))
15498
          return false;
15499
        if (!this.success.equals(that.success))
15500
          return false;
15501
      }
15502
 
15503
      boolean this_present_cex = true && this.isSetCex();
15504
      boolean that_present_cex = true && that.isSetCex();
15505
      if (this_present_cex || that_present_cex) {
15506
        if (!(this_present_cex && that_present_cex))
15507
          return false;
15508
        if (!this.cex.equals(that.cex))
15509
          return false;
15510
      }
15511
 
15512
      return true;
15513
    }
15514
 
15515
    @Override
15516
    public int hashCode() {
15517
      return 0;
15518
    }
15519
 
15520
    public int compareTo(getItemPricing_result other) {
15521
      if (!getClass().equals(other.getClass())) {
15522
        return getClass().getName().compareTo(other.getClass().getName());
15523
      }
15524
 
15525
      int lastComparison = 0;
15526
      getItemPricing_result typedOther = (getItemPricing_result)other;
15527
 
15528
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
15529
      if (lastComparison != 0) {
15530
        return lastComparison;
15531
      }
15532
      if (isSetSuccess()) {
15533
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
15534
        if (lastComparison != 0) {
15535
          return lastComparison;
15536
        }
15537
      }
15538
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
15539
      if (lastComparison != 0) {
15540
        return lastComparison;
15541
      }
15542
      if (isSetCex()) {
15543
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
15544
        if (lastComparison != 0) {
15545
          return lastComparison;
15546
        }
15547
      }
15548
      return 0;
15549
    }
15550
 
15551
    public _Fields fieldForId(int fieldId) {
15552
      return _Fields.findByThriftId(fieldId);
15553
    }
15554
 
15555
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15556
      org.apache.thrift.protocol.TField field;
15557
      iprot.readStructBegin();
15558
      while (true)
15559
      {
15560
        field = iprot.readFieldBegin();
15561
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15562
          break;
15563
        }
15564
        switch (field.id) {
15565
          case 0: // SUCCESS
15566
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15567
              this.success = new VendorItemPricing();
15568
              this.success.read(iprot);
15569
            } else { 
15570
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15571
            }
15572
            break;
15573
          case 1: // CEX
15574
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15575
              this.cex = new InventoryServiceException();
15576
              this.cex.read(iprot);
15577
            } else { 
15578
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15579
            }
15580
            break;
15581
          default:
15582
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15583
        }
15584
        iprot.readFieldEnd();
15585
      }
15586
      iprot.readStructEnd();
15587
      validate();
15588
    }
15589
 
15590
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15591
      oprot.writeStructBegin(STRUCT_DESC);
15592
 
15593
      if (this.isSetSuccess()) {
15594
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
15595
        this.success.write(oprot);
15596
        oprot.writeFieldEnd();
15597
      } else if (this.isSetCex()) {
15598
        oprot.writeFieldBegin(CEX_FIELD_DESC);
15599
        this.cex.write(oprot);
15600
        oprot.writeFieldEnd();
15601
      }
15602
      oprot.writeFieldStop();
15603
      oprot.writeStructEnd();
15604
    }
15605
 
15606
    @Override
15607
    public String toString() {
15608
      StringBuilder sb = new StringBuilder("getItemPricing_result(");
15609
      boolean first = true;
15610
 
15611
      sb.append("success:");
15612
      if (this.success == null) {
15613
        sb.append("null");
15614
      } else {
15615
        sb.append(this.success);
15616
      }
15617
      first = false;
15618
      if (!first) sb.append(", ");
15619
      sb.append("cex:");
15620
      if (this.cex == null) {
15621
        sb.append("null");
15622
      } else {
15623
        sb.append(this.cex);
15624
      }
15625
      first = false;
15626
      sb.append(")");
15627
      return sb.toString();
15628
    }
15629
 
15630
    public void validate() throws org.apache.thrift.TException {
15631
      // check for required fields
15632
    }
15633
 
15634
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15635
      try {
15636
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15637
      } catch (org.apache.thrift.TException te) {
15638
        throw new java.io.IOException(te);
15639
      }
15640
    }
15641
 
15642
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15643
      try {
15644
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15645
      } catch (org.apache.thrift.TException te) {
15646
        throw new java.io.IOException(te);
15647
      }
15648
    }
15649
 
15650
  }
15651
 
15652
  public static class getAllItemPricing_args implements org.apache.thrift.TBase<getAllItemPricing_args, getAllItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
15653
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemPricing_args");
15654
 
15655
    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);
15656
 
15657
    private long itemId; // required
15658
 
15659
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15660
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15661
      ITEM_ID((short)1, "itemId");
15662
 
15663
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15664
 
15665
      static {
15666
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15667
          byName.put(field.getFieldName(), field);
15668
        }
15669
      }
15670
 
15671
      /**
15672
       * Find the _Fields constant that matches fieldId, or null if its not found.
15673
       */
15674
      public static _Fields findByThriftId(int fieldId) {
15675
        switch(fieldId) {
15676
          case 1: // ITEM_ID
15677
            return ITEM_ID;
15678
          default:
15679
            return null;
15680
        }
15681
      }
15682
 
15683
      /**
15684
       * Find the _Fields constant that matches fieldId, throwing an exception
15685
       * if it is not found.
15686
       */
15687
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15688
        _Fields fields = findByThriftId(fieldId);
15689
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15690
        return fields;
15691
      }
15692
 
15693
      /**
15694
       * Find the _Fields constant that matches name, or null if its not found.
15695
       */
15696
      public static _Fields findByName(String name) {
15697
        return byName.get(name);
15698
      }
15699
 
15700
      private final short _thriftId;
15701
      private final String _fieldName;
15702
 
15703
      _Fields(short thriftId, String fieldName) {
15704
        _thriftId = thriftId;
15705
        _fieldName = fieldName;
15706
      }
15707
 
15708
      public short getThriftFieldId() {
15709
        return _thriftId;
15710
      }
15711
 
15712
      public String getFieldName() {
15713
        return _fieldName;
15714
      }
15715
    }
15716
 
15717
    // isset id assignments
15718
    private static final int __ITEMID_ISSET_ID = 0;
15719
    private BitSet __isset_bit_vector = new BitSet(1);
15720
 
15721
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15722
    static {
15723
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15724
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15725
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
15726
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15727
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemPricing_args.class, metaDataMap);
15728
    }
15729
 
15730
    public getAllItemPricing_args() {
15731
    }
15732
 
15733
    public getAllItemPricing_args(
15734
      long itemId)
15735
    {
15736
      this();
15737
      this.itemId = itemId;
15738
      setItemIdIsSet(true);
15739
    }
15740
 
15741
    /**
15742
     * Performs a deep copy on <i>other</i>.
15743
     */
15744
    public getAllItemPricing_args(getAllItemPricing_args other) {
15745
      __isset_bit_vector.clear();
15746
      __isset_bit_vector.or(other.__isset_bit_vector);
15747
      this.itemId = other.itemId;
15748
    }
15749
 
15750
    public getAllItemPricing_args deepCopy() {
15751
      return new getAllItemPricing_args(this);
15752
    }
15753
 
15754
    @Override
15755
    public void clear() {
15756
      setItemIdIsSet(false);
15757
      this.itemId = 0;
15758
    }
15759
 
15760
    public long getItemId() {
15761
      return this.itemId;
15762
    }
15763
 
15764
    public void setItemId(long itemId) {
15765
      this.itemId = itemId;
15766
      setItemIdIsSet(true);
15767
    }
15768
 
15769
    public void unsetItemId() {
15770
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
15771
    }
15772
 
15773
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
15774
    public boolean isSetItemId() {
15775
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
15776
    }
15777
 
15778
    public void setItemIdIsSet(boolean value) {
15779
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
15780
    }
15781
 
15782
    public void setFieldValue(_Fields field, Object value) {
15783
      switch (field) {
15784
      case ITEM_ID:
15785
        if (value == null) {
15786
          unsetItemId();
15787
        } else {
15788
          setItemId((Long)value);
15789
        }
15790
        break;
15791
 
15792
      }
15793
    }
15794
 
15795
    public Object getFieldValue(_Fields field) {
15796
      switch (field) {
15797
      case ITEM_ID:
15798
        return Long.valueOf(getItemId());
15799
 
15800
      }
15801
      throw new IllegalStateException();
15802
    }
15803
 
15804
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15805
    public boolean isSet(_Fields field) {
15806
      if (field == null) {
15807
        throw new IllegalArgumentException();
15808
      }
15809
 
15810
      switch (field) {
15811
      case ITEM_ID:
15812
        return isSetItemId();
15813
      }
15814
      throw new IllegalStateException();
15815
    }
15816
 
15817
    @Override
15818
    public boolean equals(Object that) {
15819
      if (that == null)
15820
        return false;
15821
      if (that instanceof getAllItemPricing_args)
15822
        return this.equals((getAllItemPricing_args)that);
15823
      return false;
15824
    }
15825
 
15826
    public boolean equals(getAllItemPricing_args that) {
15827
      if (that == null)
15828
        return false;
15829
 
15830
      boolean this_present_itemId = true;
15831
      boolean that_present_itemId = true;
15832
      if (this_present_itemId || that_present_itemId) {
15833
        if (!(this_present_itemId && that_present_itemId))
15834
          return false;
15835
        if (this.itemId != that.itemId)
15836
          return false;
15837
      }
15838
 
15839
      return true;
15840
    }
15841
 
15842
    @Override
15843
    public int hashCode() {
15844
      return 0;
15845
    }
15846
 
15847
    public int compareTo(getAllItemPricing_args other) {
15848
      if (!getClass().equals(other.getClass())) {
15849
        return getClass().getName().compareTo(other.getClass().getName());
15850
      }
15851
 
15852
      int lastComparison = 0;
15853
      getAllItemPricing_args typedOther = (getAllItemPricing_args)other;
15854
 
15855
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
15856
      if (lastComparison != 0) {
15857
        return lastComparison;
15858
      }
15859
      if (isSetItemId()) {
15860
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
15861
        if (lastComparison != 0) {
15862
          return lastComparison;
15863
        }
15864
      }
15865
      return 0;
15866
    }
15867
 
15868
    public _Fields fieldForId(int fieldId) {
15869
      return _Fields.findByThriftId(fieldId);
15870
    }
15871
 
15872
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15873
      org.apache.thrift.protocol.TField field;
15874
      iprot.readStructBegin();
15875
      while (true)
15876
      {
15877
        field = iprot.readFieldBegin();
15878
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15879
          break;
15880
        }
15881
        switch (field.id) {
15882
          case 1: // ITEM_ID
15883
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15884
              this.itemId = iprot.readI64();
15885
              setItemIdIsSet(true);
15886
            } else { 
15887
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15888
            }
15889
            break;
15890
          default:
15891
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15892
        }
15893
        iprot.readFieldEnd();
15894
      }
15895
      iprot.readStructEnd();
15896
      validate();
15897
    }
15898
 
15899
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15900
      validate();
15901
 
15902
      oprot.writeStructBegin(STRUCT_DESC);
15903
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
15904
      oprot.writeI64(this.itemId);
15905
      oprot.writeFieldEnd();
15906
      oprot.writeFieldStop();
15907
      oprot.writeStructEnd();
15908
    }
15909
 
15910
    @Override
15911
    public String toString() {
15912
      StringBuilder sb = new StringBuilder("getAllItemPricing_args(");
15913
      boolean first = true;
15914
 
15915
      sb.append("itemId:");
15916
      sb.append(this.itemId);
15917
      first = false;
15918
      sb.append(")");
15919
      return sb.toString();
15920
    }
15921
 
15922
    public void validate() throws org.apache.thrift.TException {
15923
      // check for required fields
15924
    }
15925
 
15926
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15927
      try {
15928
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15929
      } catch (org.apache.thrift.TException te) {
15930
        throw new java.io.IOException(te);
15931
      }
15932
    }
15933
 
15934
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15935
      try {
15936
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15937
      } catch (org.apache.thrift.TException te) {
15938
        throw new java.io.IOException(te);
15939
      }
15940
    }
15941
 
15942
  }
15943
 
15944
  public static class getAllItemPricing_result implements org.apache.thrift.TBase<getAllItemPricing_result, getAllItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
15945
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemPricing_result");
15946
 
15947
    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);
15948
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
15949
 
15950
    private List<VendorItemPricing> success; // required
15951
    private InventoryServiceException cex; // required
15952
 
15953
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15954
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15955
      SUCCESS((short)0, "success"),
15956
      CEX((short)1, "cex");
15957
 
15958
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15959
 
15960
      static {
15961
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15962
          byName.put(field.getFieldName(), field);
15963
        }
15964
      }
15965
 
15966
      /**
15967
       * Find the _Fields constant that matches fieldId, or null if its not found.
15968
       */
15969
      public static _Fields findByThriftId(int fieldId) {
15970
        switch(fieldId) {
15971
          case 0: // SUCCESS
15972
            return SUCCESS;
15973
          case 1: // CEX
15974
            return CEX;
15975
          default:
15976
            return null;
15977
        }
15978
      }
15979
 
15980
      /**
15981
       * Find the _Fields constant that matches fieldId, throwing an exception
15982
       * if it is not found.
15983
       */
15984
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15985
        _Fields fields = findByThriftId(fieldId);
15986
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15987
        return fields;
15988
      }
15989
 
15990
      /**
15991
       * Find the _Fields constant that matches name, or null if its not found.
15992
       */
15993
      public static _Fields findByName(String name) {
15994
        return byName.get(name);
15995
      }
15996
 
15997
      private final short _thriftId;
15998
      private final String _fieldName;
15999
 
16000
      _Fields(short thriftId, String fieldName) {
16001
        _thriftId = thriftId;
16002
        _fieldName = fieldName;
16003
      }
16004
 
16005
      public short getThriftFieldId() {
16006
        return _thriftId;
16007
      }
16008
 
16009
      public String getFieldName() {
16010
        return _fieldName;
16011
      }
16012
    }
16013
 
16014
    // isset id assignments
16015
 
16016
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16017
    static {
16018
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16019
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16020
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
16021
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class))));
16022
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16023
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
16024
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16025
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemPricing_result.class, metaDataMap);
16026
    }
16027
 
16028
    public getAllItemPricing_result() {
16029
    }
16030
 
16031
    public getAllItemPricing_result(
16032
      List<VendorItemPricing> success,
16033
      InventoryServiceException cex)
16034
    {
16035
      this();
16036
      this.success = success;
16037
      this.cex = cex;
16038
    }
16039
 
16040
    /**
16041
     * Performs a deep copy on <i>other</i>.
16042
     */
16043
    public getAllItemPricing_result(getAllItemPricing_result other) {
16044
      if (other.isSetSuccess()) {
16045
        List<VendorItemPricing> __this__success = new ArrayList<VendorItemPricing>();
16046
        for (VendorItemPricing other_element : other.success) {
16047
          __this__success.add(new VendorItemPricing(other_element));
16048
        }
16049
        this.success = __this__success;
16050
      }
16051
      if (other.isSetCex()) {
16052
        this.cex = new InventoryServiceException(other.cex);
16053
      }
16054
    }
16055
 
16056
    public getAllItemPricing_result deepCopy() {
16057
      return new getAllItemPricing_result(this);
16058
    }
16059
 
16060
    @Override
16061
    public void clear() {
16062
      this.success = null;
16063
      this.cex = null;
16064
    }
16065
 
16066
    public int getSuccessSize() {
16067
      return (this.success == null) ? 0 : this.success.size();
16068
    }
16069
 
16070
    public java.util.Iterator<VendorItemPricing> getSuccessIterator() {
16071
      return (this.success == null) ? null : this.success.iterator();
16072
    }
16073
 
16074
    public void addToSuccess(VendorItemPricing elem) {
16075
      if (this.success == null) {
16076
        this.success = new ArrayList<VendorItemPricing>();
16077
      }
16078
      this.success.add(elem);
16079
    }
16080
 
16081
    public List<VendorItemPricing> getSuccess() {
16082
      return this.success;
16083
    }
16084
 
16085
    public void setSuccess(List<VendorItemPricing> success) {
16086
      this.success = success;
16087
    }
16088
 
16089
    public void unsetSuccess() {
16090
      this.success = null;
16091
    }
16092
 
16093
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
16094
    public boolean isSetSuccess() {
16095
      return this.success != null;
16096
    }
16097
 
16098
    public void setSuccessIsSet(boolean value) {
16099
      if (!value) {
16100
        this.success = null;
16101
      }
16102
    }
16103
 
16104
    public InventoryServiceException getCex() {
16105
      return this.cex;
16106
    }
16107
 
16108
    public void setCex(InventoryServiceException cex) {
16109
      this.cex = cex;
16110
    }
16111
 
16112
    public void unsetCex() {
16113
      this.cex = null;
16114
    }
16115
 
16116
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
16117
    public boolean isSetCex() {
16118
      return this.cex != null;
16119
    }
16120
 
16121
    public void setCexIsSet(boolean value) {
16122
      if (!value) {
16123
        this.cex = null;
16124
      }
16125
    }
16126
 
16127
    public void setFieldValue(_Fields field, Object value) {
16128
      switch (field) {
16129
      case SUCCESS:
16130
        if (value == null) {
16131
          unsetSuccess();
16132
        } else {
16133
          setSuccess((List<VendorItemPricing>)value);
16134
        }
16135
        break;
16136
 
16137
      case CEX:
16138
        if (value == null) {
16139
          unsetCex();
16140
        } else {
16141
          setCex((InventoryServiceException)value);
16142
        }
16143
        break;
16144
 
16145
      }
16146
    }
16147
 
16148
    public Object getFieldValue(_Fields field) {
16149
      switch (field) {
16150
      case SUCCESS:
16151
        return getSuccess();
16152
 
16153
      case CEX:
16154
        return getCex();
16155
 
16156
      }
16157
      throw new IllegalStateException();
16158
    }
16159
 
16160
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16161
    public boolean isSet(_Fields field) {
16162
      if (field == null) {
16163
        throw new IllegalArgumentException();
16164
      }
16165
 
16166
      switch (field) {
16167
      case SUCCESS:
16168
        return isSetSuccess();
16169
      case CEX:
16170
        return isSetCex();
16171
      }
16172
      throw new IllegalStateException();
16173
    }
16174
 
16175
    @Override
16176
    public boolean equals(Object that) {
16177
      if (that == null)
16178
        return false;
16179
      if (that instanceof getAllItemPricing_result)
16180
        return this.equals((getAllItemPricing_result)that);
16181
      return false;
16182
    }
16183
 
16184
    public boolean equals(getAllItemPricing_result that) {
16185
      if (that == null)
16186
        return false;
16187
 
16188
      boolean this_present_success = true && this.isSetSuccess();
16189
      boolean that_present_success = true && that.isSetSuccess();
16190
      if (this_present_success || that_present_success) {
16191
        if (!(this_present_success && that_present_success))
16192
          return false;
16193
        if (!this.success.equals(that.success))
16194
          return false;
16195
      }
16196
 
16197
      boolean this_present_cex = true && this.isSetCex();
16198
      boolean that_present_cex = true && that.isSetCex();
16199
      if (this_present_cex || that_present_cex) {
16200
        if (!(this_present_cex && that_present_cex))
16201
          return false;
16202
        if (!this.cex.equals(that.cex))
16203
          return false;
16204
      }
16205
 
16206
      return true;
16207
    }
16208
 
16209
    @Override
16210
    public int hashCode() {
16211
      return 0;
16212
    }
16213
 
16214
    public int compareTo(getAllItemPricing_result other) {
16215
      if (!getClass().equals(other.getClass())) {
16216
        return getClass().getName().compareTo(other.getClass().getName());
16217
      }
16218
 
16219
      int lastComparison = 0;
16220
      getAllItemPricing_result typedOther = (getAllItemPricing_result)other;
16221
 
16222
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
16223
      if (lastComparison != 0) {
16224
        return lastComparison;
16225
      }
16226
      if (isSetSuccess()) {
16227
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
16228
        if (lastComparison != 0) {
16229
          return lastComparison;
16230
        }
16231
      }
16232
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
16233
      if (lastComparison != 0) {
16234
        return lastComparison;
16235
      }
16236
      if (isSetCex()) {
16237
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
16238
        if (lastComparison != 0) {
16239
          return lastComparison;
16240
        }
16241
      }
16242
      return 0;
16243
    }
16244
 
16245
    public _Fields fieldForId(int fieldId) {
16246
      return _Fields.findByThriftId(fieldId);
16247
    }
16248
 
16249
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16250
      org.apache.thrift.protocol.TField field;
16251
      iprot.readStructBegin();
16252
      while (true)
16253
      {
16254
        field = iprot.readFieldBegin();
16255
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16256
          break;
16257
        }
16258
        switch (field.id) {
16259
          case 0: // SUCCESS
16260
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
16261
              {
16262
                org.apache.thrift.protocol.TList _list32 = iprot.readListBegin();
16263
                this.success = new ArrayList<VendorItemPricing>(_list32.size);
16264
                for (int _i33 = 0; _i33 < _list32.size; ++_i33)
16265
                {
16266
                  VendorItemPricing _elem34; // required
16267
                  _elem34 = new VendorItemPricing();
16268
                  _elem34.read(iprot);
16269
                  this.success.add(_elem34);
16270
                }
16271
                iprot.readListEnd();
16272
              }
16273
            } else { 
16274
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16275
            }
16276
            break;
16277
          case 1: // CEX
16278
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16279
              this.cex = new InventoryServiceException();
16280
              this.cex.read(iprot);
16281
            } else { 
16282
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16283
            }
16284
            break;
16285
          default:
16286
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16287
        }
16288
        iprot.readFieldEnd();
16289
      }
16290
      iprot.readStructEnd();
16291
      validate();
16292
    }
16293
 
16294
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16295
      oprot.writeStructBegin(STRUCT_DESC);
16296
 
16297
      if (this.isSetSuccess()) {
16298
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
16299
        {
16300
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
16301
          for (VendorItemPricing _iter35 : this.success)
16302
          {
16303
            _iter35.write(oprot);
16304
          }
16305
          oprot.writeListEnd();
16306
        }
16307
        oprot.writeFieldEnd();
16308
      } else if (this.isSetCex()) {
16309
        oprot.writeFieldBegin(CEX_FIELD_DESC);
16310
        this.cex.write(oprot);
16311
        oprot.writeFieldEnd();
16312
      }
16313
      oprot.writeFieldStop();
16314
      oprot.writeStructEnd();
16315
    }
16316
 
16317
    @Override
16318
    public String toString() {
16319
      StringBuilder sb = new StringBuilder("getAllItemPricing_result(");
16320
      boolean first = true;
16321
 
16322
      sb.append("success:");
16323
      if (this.success == null) {
16324
        sb.append("null");
16325
      } else {
16326
        sb.append(this.success);
16327
      }
16328
      first = false;
16329
      if (!first) sb.append(", ");
16330
      sb.append("cex:");
16331
      if (this.cex == null) {
16332
        sb.append("null");
16333
      } else {
16334
        sb.append(this.cex);
16335
      }
16336
      first = false;
16337
      sb.append(")");
16338
      return sb.toString();
16339
    }
16340
 
16341
    public void validate() throws org.apache.thrift.TException {
16342
      // check for required fields
16343
    }
16344
 
16345
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16346
      try {
16347
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16348
      } catch (org.apache.thrift.TException te) {
16349
        throw new java.io.IOException(te);
16350
      }
16351
    }
16352
 
16353
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16354
      try {
16355
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16356
      } catch (org.apache.thrift.TException te) {
16357
        throw new java.io.IOException(te);
16358
      }
16359
    }
16360
 
16361
  }
16362
 
16363
  public static class addVendorItemPricing_args implements org.apache.thrift.TBase<addVendorItemPricing_args, addVendorItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
16364
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemPricing_args");
16365
 
16366
    private static final org.apache.thrift.protocol.TField VENDOR_ITEM_PRICING_FIELD_DESC = new org.apache.thrift.protocol.TField("vendorItemPricing", org.apache.thrift.protocol.TType.STRUCT, (short)1);
16367
 
16368
    private VendorItemPricing vendorItemPricing; // required
16369
 
16370
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16371
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16372
      VENDOR_ITEM_PRICING((short)1, "vendorItemPricing");
16373
 
16374
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16375
 
16376
      static {
16377
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16378
          byName.put(field.getFieldName(), field);
16379
        }
16380
      }
16381
 
16382
      /**
16383
       * Find the _Fields constant that matches fieldId, or null if its not found.
16384
       */
16385
      public static _Fields findByThriftId(int fieldId) {
16386
        switch(fieldId) {
16387
          case 1: // VENDOR_ITEM_PRICING
16388
            return VENDOR_ITEM_PRICING;
16389
          default:
16390
            return null;
16391
        }
16392
      }
16393
 
16394
      /**
16395
       * Find the _Fields constant that matches fieldId, throwing an exception
16396
       * if it is not found.
16397
       */
16398
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16399
        _Fields fields = findByThriftId(fieldId);
16400
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16401
        return fields;
16402
      }
16403
 
16404
      /**
16405
       * Find the _Fields constant that matches name, or null if its not found.
16406
       */
16407
      public static _Fields findByName(String name) {
16408
        return byName.get(name);
16409
      }
16410
 
16411
      private final short _thriftId;
16412
      private final String _fieldName;
16413
 
16414
      _Fields(short thriftId, String fieldName) {
16415
        _thriftId = thriftId;
16416
        _fieldName = fieldName;
16417
      }
16418
 
16419
      public short getThriftFieldId() {
16420
        return _thriftId;
16421
      }
16422
 
16423
      public String getFieldName() {
16424
        return _fieldName;
16425
      }
16426
    }
16427
 
16428
    // isset id assignments
16429
 
16430
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16431
    static {
16432
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16433
      tmpMap.put(_Fields.VENDOR_ITEM_PRICING, new org.apache.thrift.meta_data.FieldMetaData("vendorItemPricing", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16434
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class)));
16435
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16436
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemPricing_args.class, metaDataMap);
16437
    }
16438
 
16439
    public addVendorItemPricing_args() {
16440
    }
16441
 
16442
    public addVendorItemPricing_args(
16443
      VendorItemPricing vendorItemPricing)
16444
    {
16445
      this();
16446
      this.vendorItemPricing = vendorItemPricing;
16447
    }
16448
 
16449
    /**
16450
     * Performs a deep copy on <i>other</i>.
16451
     */
16452
    public addVendorItemPricing_args(addVendorItemPricing_args other) {
16453
      if (other.isSetVendorItemPricing()) {
16454
        this.vendorItemPricing = new VendorItemPricing(other.vendorItemPricing);
16455
      }
16456
    }
16457
 
16458
    public addVendorItemPricing_args deepCopy() {
16459
      return new addVendorItemPricing_args(this);
16460
    }
16461
 
16462
    @Override
16463
    public void clear() {
16464
      this.vendorItemPricing = null;
16465
    }
16466
 
16467
    public VendorItemPricing getVendorItemPricing() {
16468
      return this.vendorItemPricing;
16469
    }
16470
 
16471
    public void setVendorItemPricing(VendorItemPricing vendorItemPricing) {
16472
      this.vendorItemPricing = vendorItemPricing;
16473
    }
16474
 
16475
    public void unsetVendorItemPricing() {
16476
      this.vendorItemPricing = null;
16477
    }
16478
 
16479
    /** Returns true if field vendorItemPricing is set (has been assigned a value) and false otherwise */
16480
    public boolean isSetVendorItemPricing() {
16481
      return this.vendorItemPricing != null;
16482
    }
16483
 
16484
    public void setVendorItemPricingIsSet(boolean value) {
16485
      if (!value) {
16486
        this.vendorItemPricing = null;
16487
      }
16488
    }
16489
 
16490
    public void setFieldValue(_Fields field, Object value) {
16491
      switch (field) {
16492
      case VENDOR_ITEM_PRICING:
16493
        if (value == null) {
16494
          unsetVendorItemPricing();
16495
        } else {
16496
          setVendorItemPricing((VendorItemPricing)value);
16497
        }
16498
        break;
16499
 
16500
      }
16501
    }
16502
 
16503
    public Object getFieldValue(_Fields field) {
16504
      switch (field) {
16505
      case VENDOR_ITEM_PRICING:
16506
        return getVendorItemPricing();
16507
 
16508
      }
16509
      throw new IllegalStateException();
16510
    }
16511
 
16512
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16513
    public boolean isSet(_Fields field) {
16514
      if (field == null) {
16515
        throw new IllegalArgumentException();
16516
      }
16517
 
16518
      switch (field) {
16519
      case VENDOR_ITEM_PRICING:
16520
        return isSetVendorItemPricing();
16521
      }
16522
      throw new IllegalStateException();
16523
    }
16524
 
16525
    @Override
16526
    public boolean equals(Object that) {
16527
      if (that == null)
16528
        return false;
16529
      if (that instanceof addVendorItemPricing_args)
16530
        return this.equals((addVendorItemPricing_args)that);
16531
      return false;
16532
    }
16533
 
16534
    public boolean equals(addVendorItemPricing_args that) {
16535
      if (that == null)
16536
        return false;
16537
 
16538
      boolean this_present_vendorItemPricing = true && this.isSetVendorItemPricing();
16539
      boolean that_present_vendorItemPricing = true && that.isSetVendorItemPricing();
16540
      if (this_present_vendorItemPricing || that_present_vendorItemPricing) {
16541
        if (!(this_present_vendorItemPricing && that_present_vendorItemPricing))
16542
          return false;
16543
        if (!this.vendorItemPricing.equals(that.vendorItemPricing))
16544
          return false;
16545
      }
16546
 
16547
      return true;
16548
    }
16549
 
16550
    @Override
16551
    public int hashCode() {
16552
      return 0;
16553
    }
16554
 
16555
    public int compareTo(addVendorItemPricing_args other) {
16556
      if (!getClass().equals(other.getClass())) {
16557
        return getClass().getName().compareTo(other.getClass().getName());
16558
      }
16559
 
16560
      int lastComparison = 0;
16561
      addVendorItemPricing_args typedOther = (addVendorItemPricing_args)other;
16562
 
16563
      lastComparison = Boolean.valueOf(isSetVendorItemPricing()).compareTo(typedOther.isSetVendorItemPricing());
16564
      if (lastComparison != 0) {
16565
        return lastComparison;
16566
      }
16567
      if (isSetVendorItemPricing()) {
16568
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorItemPricing, typedOther.vendorItemPricing);
16569
        if (lastComparison != 0) {
16570
          return lastComparison;
16571
        }
16572
      }
16573
      return 0;
16574
    }
16575
 
16576
    public _Fields fieldForId(int fieldId) {
16577
      return _Fields.findByThriftId(fieldId);
16578
    }
16579
 
16580
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16581
      org.apache.thrift.protocol.TField field;
16582
      iprot.readStructBegin();
16583
      while (true)
16584
      {
16585
        field = iprot.readFieldBegin();
16586
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16587
          break;
16588
        }
16589
        switch (field.id) {
16590
          case 1: // VENDOR_ITEM_PRICING
16591
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16592
              this.vendorItemPricing = new VendorItemPricing();
16593
              this.vendorItemPricing.read(iprot);
16594
            } else { 
16595
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16596
            }
16597
            break;
16598
          default:
16599
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16600
        }
16601
        iprot.readFieldEnd();
16602
      }
16603
      iprot.readStructEnd();
16604
      validate();
16605
    }
16606
 
16607
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16608
      validate();
16609
 
16610
      oprot.writeStructBegin(STRUCT_DESC);
16611
      if (this.vendorItemPricing != null) {
16612
        oprot.writeFieldBegin(VENDOR_ITEM_PRICING_FIELD_DESC);
16613
        this.vendorItemPricing.write(oprot);
16614
        oprot.writeFieldEnd();
16615
      }
16616
      oprot.writeFieldStop();
16617
      oprot.writeStructEnd();
16618
    }
16619
 
16620
    @Override
16621
    public String toString() {
16622
      StringBuilder sb = new StringBuilder("addVendorItemPricing_args(");
16623
      boolean first = true;
16624
 
16625
      sb.append("vendorItemPricing:");
16626
      if (this.vendorItemPricing == null) {
16627
        sb.append("null");
16628
      } else {
16629
        sb.append(this.vendorItemPricing);
16630
      }
16631
      first = false;
16632
      sb.append(")");
16633
      return sb.toString();
16634
    }
16635
 
16636
    public void validate() throws org.apache.thrift.TException {
16637
      // check for required fields
16638
    }
16639
 
16640
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16641
      try {
16642
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16643
      } catch (org.apache.thrift.TException te) {
16644
        throw new java.io.IOException(te);
16645
      }
16646
    }
16647
 
16648
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16649
      try {
16650
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16651
      } catch (org.apache.thrift.TException te) {
16652
        throw new java.io.IOException(te);
16653
      }
16654
    }
16655
 
16656
  }
16657
 
16658
  public static class addVendorItemPricing_result implements org.apache.thrift.TBase<addVendorItemPricing_result, addVendorItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
16659
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemPricing_result");
16660
 
16661
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
16662
 
16663
    private InventoryServiceException cex; // required
16664
 
16665
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16666
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16667
      CEX((short)1, "cex");
16668
 
16669
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16670
 
16671
      static {
16672
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16673
          byName.put(field.getFieldName(), field);
16674
        }
16675
      }
16676
 
16677
      /**
16678
       * Find the _Fields constant that matches fieldId, or null if its not found.
16679
       */
16680
      public static _Fields findByThriftId(int fieldId) {
16681
        switch(fieldId) {
16682
          case 1: // CEX
16683
            return CEX;
16684
          default:
16685
            return null;
16686
        }
16687
      }
16688
 
16689
      /**
16690
       * Find the _Fields constant that matches fieldId, throwing an exception
16691
       * if it is not found.
16692
       */
16693
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16694
        _Fields fields = findByThriftId(fieldId);
16695
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16696
        return fields;
16697
      }
16698
 
16699
      /**
16700
       * Find the _Fields constant that matches name, or null if its not found.
16701
       */
16702
      public static _Fields findByName(String name) {
16703
        return byName.get(name);
16704
      }
16705
 
16706
      private final short _thriftId;
16707
      private final String _fieldName;
16708
 
16709
      _Fields(short thriftId, String fieldName) {
16710
        _thriftId = thriftId;
16711
        _fieldName = fieldName;
16712
      }
16713
 
16714
      public short getThriftFieldId() {
16715
        return _thriftId;
16716
      }
16717
 
16718
      public String getFieldName() {
16719
        return _fieldName;
16720
      }
16721
    }
16722
 
16723
    // isset id assignments
16724
 
16725
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16726
    static {
16727
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16728
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16729
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
16730
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16731
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemPricing_result.class, metaDataMap);
16732
    }
16733
 
16734
    public addVendorItemPricing_result() {
16735
    }
16736
 
16737
    public addVendorItemPricing_result(
16738
      InventoryServiceException cex)
16739
    {
16740
      this();
16741
      this.cex = cex;
16742
    }
16743
 
16744
    /**
16745
     * Performs a deep copy on <i>other</i>.
16746
     */
16747
    public addVendorItemPricing_result(addVendorItemPricing_result other) {
16748
      if (other.isSetCex()) {
16749
        this.cex = new InventoryServiceException(other.cex);
16750
      }
16751
    }
16752
 
16753
    public addVendorItemPricing_result deepCopy() {
16754
      return new addVendorItemPricing_result(this);
16755
    }
16756
 
16757
    @Override
16758
    public void clear() {
16759
      this.cex = null;
16760
    }
16761
 
16762
    public InventoryServiceException getCex() {
16763
      return this.cex;
16764
    }
16765
 
16766
    public void setCex(InventoryServiceException cex) {
16767
      this.cex = cex;
16768
    }
16769
 
16770
    public void unsetCex() {
16771
      this.cex = null;
16772
    }
16773
 
16774
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
16775
    public boolean isSetCex() {
16776
      return this.cex != null;
16777
    }
16778
 
16779
    public void setCexIsSet(boolean value) {
16780
      if (!value) {
16781
        this.cex = null;
16782
      }
16783
    }
16784
 
16785
    public void setFieldValue(_Fields field, Object value) {
16786
      switch (field) {
16787
      case CEX:
16788
        if (value == null) {
16789
          unsetCex();
16790
        } else {
16791
          setCex((InventoryServiceException)value);
16792
        }
16793
        break;
16794
 
16795
      }
16796
    }
16797
 
16798
    public Object getFieldValue(_Fields field) {
16799
      switch (field) {
16800
      case CEX:
16801
        return getCex();
16802
 
16803
      }
16804
      throw new IllegalStateException();
16805
    }
16806
 
16807
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16808
    public boolean isSet(_Fields field) {
16809
      if (field == null) {
16810
        throw new IllegalArgumentException();
16811
      }
16812
 
16813
      switch (field) {
16814
      case CEX:
16815
        return isSetCex();
16816
      }
16817
      throw new IllegalStateException();
16818
    }
16819
 
16820
    @Override
16821
    public boolean equals(Object that) {
16822
      if (that == null)
16823
        return false;
16824
      if (that instanceof addVendorItemPricing_result)
16825
        return this.equals((addVendorItemPricing_result)that);
16826
      return false;
16827
    }
16828
 
16829
    public boolean equals(addVendorItemPricing_result that) {
16830
      if (that == null)
16831
        return false;
16832
 
16833
      boolean this_present_cex = true && this.isSetCex();
16834
      boolean that_present_cex = true && that.isSetCex();
16835
      if (this_present_cex || that_present_cex) {
16836
        if (!(this_present_cex && that_present_cex))
16837
          return false;
16838
        if (!this.cex.equals(that.cex))
16839
          return false;
16840
      }
16841
 
16842
      return true;
16843
    }
16844
 
16845
    @Override
16846
    public int hashCode() {
16847
      return 0;
16848
    }
16849
 
16850
    public int compareTo(addVendorItemPricing_result other) {
16851
      if (!getClass().equals(other.getClass())) {
16852
        return getClass().getName().compareTo(other.getClass().getName());
16853
      }
16854
 
16855
      int lastComparison = 0;
16856
      addVendorItemPricing_result typedOther = (addVendorItemPricing_result)other;
16857
 
16858
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
16859
      if (lastComparison != 0) {
16860
        return lastComparison;
16861
      }
16862
      if (isSetCex()) {
16863
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
16864
        if (lastComparison != 0) {
16865
          return lastComparison;
16866
        }
16867
      }
16868
      return 0;
16869
    }
16870
 
16871
    public _Fields fieldForId(int fieldId) {
16872
      return _Fields.findByThriftId(fieldId);
16873
    }
16874
 
16875
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16876
      org.apache.thrift.protocol.TField field;
16877
      iprot.readStructBegin();
16878
      while (true)
16879
      {
16880
        field = iprot.readFieldBegin();
16881
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16882
          break;
16883
        }
16884
        switch (field.id) {
16885
          case 1: // CEX
16886
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16887
              this.cex = new InventoryServiceException();
16888
              this.cex.read(iprot);
16889
            } else { 
16890
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16891
            }
16892
            break;
16893
          default:
16894
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16895
        }
16896
        iprot.readFieldEnd();
16897
      }
16898
      iprot.readStructEnd();
16899
      validate();
16900
    }
16901
 
16902
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16903
      oprot.writeStructBegin(STRUCT_DESC);
16904
 
16905
      if (this.isSetCex()) {
16906
        oprot.writeFieldBegin(CEX_FIELD_DESC);
16907
        this.cex.write(oprot);
16908
        oprot.writeFieldEnd();
16909
      }
16910
      oprot.writeFieldStop();
16911
      oprot.writeStructEnd();
16912
    }
16913
 
16914
    @Override
16915
    public String toString() {
16916
      StringBuilder sb = new StringBuilder("addVendorItemPricing_result(");
16917
      boolean first = true;
16918
 
16919
      sb.append("cex:");
16920
      if (this.cex == null) {
16921
        sb.append("null");
16922
      } else {
16923
        sb.append(this.cex);
16924
      }
16925
      first = false;
16926
      sb.append(")");
16927
      return sb.toString();
16928
    }
16929
 
16930
    public void validate() throws org.apache.thrift.TException {
16931
      // check for required fields
16932
    }
16933
 
16934
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16935
      try {
16936
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16937
      } catch (org.apache.thrift.TException te) {
16938
        throw new java.io.IOException(te);
16939
      }
16940
    }
16941
 
16942
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16943
      try {
16944
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16945
      } catch (org.apache.thrift.TException te) {
16946
        throw new java.io.IOException(te);
16947
      }
16948
    }
16949
 
16950
  }
16951
 
16952
  public static class getVendor_args implements org.apache.thrift.TBase<getVendor_args, getVendor_args._Fields>, java.io.Serializable, Cloneable   {
16953
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendor_args");
16954
 
16955
    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)1);
16956
 
16957
    private long vendorId; // required
16958
 
16959
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16960
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16961
      VENDOR_ID((short)1, "vendorId");
16962
 
16963
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16964
 
16965
      static {
16966
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16967
          byName.put(field.getFieldName(), field);
16968
        }
16969
      }
16970
 
16971
      /**
16972
       * Find the _Fields constant that matches fieldId, or null if its not found.
16973
       */
16974
      public static _Fields findByThriftId(int fieldId) {
16975
        switch(fieldId) {
16976
          case 1: // VENDOR_ID
16977
            return VENDOR_ID;
16978
          default:
16979
            return null;
16980
        }
16981
      }
16982
 
16983
      /**
16984
       * Find the _Fields constant that matches fieldId, throwing an exception
16985
       * if it is not found.
16986
       */
16987
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16988
        _Fields fields = findByThriftId(fieldId);
16989
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16990
        return fields;
16991
      }
16992
 
16993
      /**
16994
       * Find the _Fields constant that matches name, or null if its not found.
16995
       */
16996
      public static _Fields findByName(String name) {
16997
        return byName.get(name);
16998
      }
16999
 
17000
      private final short _thriftId;
17001
      private final String _fieldName;
17002
 
17003
      _Fields(short thriftId, String fieldName) {
17004
        _thriftId = thriftId;
17005
        _fieldName = fieldName;
17006
      }
17007
 
17008
      public short getThriftFieldId() {
17009
        return _thriftId;
17010
      }
17011
 
17012
      public String getFieldName() {
17013
        return _fieldName;
17014
      }
17015
    }
17016
 
17017
    // isset id assignments
17018
    private static final int __VENDORID_ISSET_ID = 0;
17019
    private BitSet __isset_bit_vector = new BitSet(1);
17020
 
17021
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17022
    static {
17023
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17024
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17025
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17026
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17027
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendor_args.class, metaDataMap);
17028
    }
17029
 
17030
    public getVendor_args() {
17031
    }
17032
 
17033
    public getVendor_args(
17034
      long vendorId)
17035
    {
17036
      this();
17037
      this.vendorId = vendorId;
17038
      setVendorIdIsSet(true);
17039
    }
17040
 
17041
    /**
17042
     * Performs a deep copy on <i>other</i>.
17043
     */
17044
    public getVendor_args(getVendor_args other) {
17045
      __isset_bit_vector.clear();
17046
      __isset_bit_vector.or(other.__isset_bit_vector);
17047
      this.vendorId = other.vendorId;
17048
    }
17049
 
17050
    public getVendor_args deepCopy() {
17051
      return new getVendor_args(this);
17052
    }
17053
 
17054
    @Override
17055
    public void clear() {
17056
      setVendorIdIsSet(false);
17057
      this.vendorId = 0;
17058
    }
17059
 
17060
    public long getVendorId() {
17061
      return this.vendorId;
17062
    }
17063
 
17064
    public void setVendorId(long vendorId) {
17065
      this.vendorId = vendorId;
17066
      setVendorIdIsSet(true);
17067
    }
17068
 
17069
    public void unsetVendorId() {
17070
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
17071
    }
17072
 
17073
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
17074
    public boolean isSetVendorId() {
17075
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
17076
    }
17077
 
17078
    public void setVendorIdIsSet(boolean value) {
17079
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
17080
    }
17081
 
17082
    public void setFieldValue(_Fields field, Object value) {
17083
      switch (field) {
17084
      case VENDOR_ID:
17085
        if (value == null) {
17086
          unsetVendorId();
17087
        } else {
17088
          setVendorId((Long)value);
17089
        }
17090
        break;
17091
 
17092
      }
17093
    }
17094
 
17095
    public Object getFieldValue(_Fields field) {
17096
      switch (field) {
17097
      case VENDOR_ID:
17098
        return Long.valueOf(getVendorId());
17099
 
17100
      }
17101
      throw new IllegalStateException();
17102
    }
17103
 
17104
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17105
    public boolean isSet(_Fields field) {
17106
      if (field == null) {
17107
        throw new IllegalArgumentException();
17108
      }
17109
 
17110
      switch (field) {
17111
      case VENDOR_ID:
17112
        return isSetVendorId();
17113
      }
17114
      throw new IllegalStateException();
17115
    }
17116
 
17117
    @Override
17118
    public boolean equals(Object that) {
17119
      if (that == null)
17120
        return false;
17121
      if (that instanceof getVendor_args)
17122
        return this.equals((getVendor_args)that);
17123
      return false;
17124
    }
17125
 
17126
    public boolean equals(getVendor_args that) {
17127
      if (that == null)
17128
        return false;
17129
 
17130
      boolean this_present_vendorId = true;
17131
      boolean that_present_vendorId = true;
17132
      if (this_present_vendorId || that_present_vendorId) {
17133
        if (!(this_present_vendorId && that_present_vendorId))
17134
          return false;
17135
        if (this.vendorId != that.vendorId)
17136
          return false;
17137
      }
17138
 
17139
      return true;
17140
    }
17141
 
17142
    @Override
17143
    public int hashCode() {
17144
      return 0;
17145
    }
17146
 
17147
    public int compareTo(getVendor_args other) {
17148
      if (!getClass().equals(other.getClass())) {
17149
        return getClass().getName().compareTo(other.getClass().getName());
17150
      }
17151
 
17152
      int lastComparison = 0;
17153
      getVendor_args typedOther = (getVendor_args)other;
17154
 
17155
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
17156
      if (lastComparison != 0) {
17157
        return lastComparison;
17158
      }
17159
      if (isSetVendorId()) {
17160
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
17161
        if (lastComparison != 0) {
17162
          return lastComparison;
17163
        }
17164
      }
17165
      return 0;
17166
    }
17167
 
17168
    public _Fields fieldForId(int fieldId) {
17169
      return _Fields.findByThriftId(fieldId);
17170
    }
17171
 
17172
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17173
      org.apache.thrift.protocol.TField field;
17174
      iprot.readStructBegin();
17175
      while (true)
17176
      {
17177
        field = iprot.readFieldBegin();
17178
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17179
          break;
17180
        }
17181
        switch (field.id) {
17182
          case 1: // VENDOR_ID
17183
            if (field.type == org.apache.thrift.protocol.TType.I64) {
17184
              this.vendorId = iprot.readI64();
17185
              setVendorIdIsSet(true);
17186
            } else { 
17187
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17188
            }
17189
            break;
17190
          default:
17191
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17192
        }
17193
        iprot.readFieldEnd();
17194
      }
17195
      iprot.readStructEnd();
17196
      validate();
17197
    }
17198
 
17199
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17200
      validate();
17201
 
17202
      oprot.writeStructBegin(STRUCT_DESC);
17203
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
17204
      oprot.writeI64(this.vendorId);
17205
      oprot.writeFieldEnd();
17206
      oprot.writeFieldStop();
17207
      oprot.writeStructEnd();
17208
    }
17209
 
17210
    @Override
17211
    public String toString() {
17212
      StringBuilder sb = new StringBuilder("getVendor_args(");
17213
      boolean first = true;
17214
 
17215
      sb.append("vendorId:");
17216
      sb.append(this.vendorId);
17217
      first = false;
17218
      sb.append(")");
17219
      return sb.toString();
17220
    }
17221
 
17222
    public void validate() throws org.apache.thrift.TException {
17223
      // check for required fields
17224
    }
17225
 
17226
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17227
      try {
17228
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17229
      } catch (org.apache.thrift.TException te) {
17230
        throw new java.io.IOException(te);
17231
      }
17232
    }
17233
 
17234
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17235
      try {
17236
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
17237
        __isset_bit_vector = new BitSet(1);
17238
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17239
      } catch (org.apache.thrift.TException te) {
17240
        throw new java.io.IOException(te);
17241
      }
17242
    }
17243
 
17244
  }
17245
 
17246
  public static class getVendor_result implements org.apache.thrift.TBase<getVendor_result, getVendor_result._Fields>, java.io.Serializable, Cloneable   {
17247
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendor_result");
17248
 
17249
    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);
17250
 
17251
    private Vendor success; // required
17252
 
17253
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17254
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17255
      SUCCESS((short)0, "success");
17256
 
17257
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17258
 
17259
      static {
17260
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17261
          byName.put(field.getFieldName(), field);
17262
        }
17263
      }
17264
 
17265
      /**
17266
       * Find the _Fields constant that matches fieldId, or null if its not found.
17267
       */
17268
      public static _Fields findByThriftId(int fieldId) {
17269
        switch(fieldId) {
17270
          case 0: // SUCCESS
17271
            return SUCCESS;
17272
          default:
17273
            return null;
17274
        }
17275
      }
17276
 
17277
      /**
17278
       * Find the _Fields constant that matches fieldId, throwing an exception
17279
       * if it is not found.
17280
       */
17281
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17282
        _Fields fields = findByThriftId(fieldId);
17283
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17284
        return fields;
17285
      }
17286
 
17287
      /**
17288
       * Find the _Fields constant that matches name, or null if its not found.
17289
       */
17290
      public static _Fields findByName(String name) {
17291
        return byName.get(name);
17292
      }
17293
 
17294
      private final short _thriftId;
17295
      private final String _fieldName;
17296
 
17297
      _Fields(short thriftId, String fieldName) {
17298
        _thriftId = thriftId;
17299
        _fieldName = fieldName;
17300
      }
17301
 
17302
      public short getThriftFieldId() {
17303
        return _thriftId;
17304
      }
17305
 
17306
      public String getFieldName() {
17307
        return _fieldName;
17308
      }
17309
    }
17310
 
17311
    // isset id assignments
17312
 
17313
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17314
    static {
17315
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17316
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17317
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class)));
17318
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17319
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendor_result.class, metaDataMap);
17320
    }
17321
 
17322
    public getVendor_result() {
17323
    }
17324
 
17325
    public getVendor_result(
17326
      Vendor success)
17327
    {
17328
      this();
17329
      this.success = success;
17330
    }
17331
 
17332
    /**
17333
     * Performs a deep copy on <i>other</i>.
17334
     */
17335
    public getVendor_result(getVendor_result other) {
17336
      if (other.isSetSuccess()) {
17337
        this.success = new Vendor(other.success);
17338
      }
17339
    }
17340
 
17341
    public getVendor_result deepCopy() {
17342
      return new getVendor_result(this);
17343
    }
17344
 
17345
    @Override
17346
    public void clear() {
17347
      this.success = null;
17348
    }
17349
 
17350
    public Vendor getSuccess() {
17351
      return this.success;
17352
    }
17353
 
17354
    public void setSuccess(Vendor success) {
17355
      this.success = success;
17356
    }
17357
 
17358
    public void unsetSuccess() {
17359
      this.success = null;
17360
    }
17361
 
17362
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17363
    public boolean isSetSuccess() {
17364
      return this.success != null;
17365
    }
17366
 
17367
    public void setSuccessIsSet(boolean value) {
17368
      if (!value) {
17369
        this.success = null;
17370
      }
17371
    }
17372
 
17373
    public void setFieldValue(_Fields field, Object value) {
17374
      switch (field) {
17375
      case SUCCESS:
17376
        if (value == null) {
17377
          unsetSuccess();
17378
        } else {
17379
          setSuccess((Vendor)value);
17380
        }
17381
        break;
17382
 
17383
      }
17384
    }
17385
 
17386
    public Object getFieldValue(_Fields field) {
17387
      switch (field) {
17388
      case SUCCESS:
17389
        return getSuccess();
17390
 
17391
      }
17392
      throw new IllegalStateException();
17393
    }
17394
 
17395
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17396
    public boolean isSet(_Fields field) {
17397
      if (field == null) {
17398
        throw new IllegalArgumentException();
17399
      }
17400
 
17401
      switch (field) {
17402
      case SUCCESS:
17403
        return isSetSuccess();
17404
      }
17405
      throw new IllegalStateException();
17406
    }
17407
 
17408
    @Override
17409
    public boolean equals(Object that) {
17410
      if (that == null)
17411
        return false;
17412
      if (that instanceof getVendor_result)
17413
        return this.equals((getVendor_result)that);
17414
      return false;
17415
    }
17416
 
17417
    public boolean equals(getVendor_result that) {
17418
      if (that == null)
17419
        return false;
17420
 
17421
      boolean this_present_success = true && this.isSetSuccess();
17422
      boolean that_present_success = true && that.isSetSuccess();
17423
      if (this_present_success || that_present_success) {
17424
        if (!(this_present_success && that_present_success))
17425
          return false;
17426
        if (!this.success.equals(that.success))
17427
          return false;
17428
      }
17429
 
17430
      return true;
17431
    }
17432
 
17433
    @Override
17434
    public int hashCode() {
17435
      return 0;
17436
    }
17437
 
17438
    public int compareTo(getVendor_result other) {
17439
      if (!getClass().equals(other.getClass())) {
17440
        return getClass().getName().compareTo(other.getClass().getName());
17441
      }
17442
 
17443
      int lastComparison = 0;
17444
      getVendor_result typedOther = (getVendor_result)other;
17445
 
17446
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17447
      if (lastComparison != 0) {
17448
        return lastComparison;
17449
      }
17450
      if (isSetSuccess()) {
17451
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17452
        if (lastComparison != 0) {
17453
          return lastComparison;
17454
        }
17455
      }
17456
      return 0;
17457
    }
17458
 
17459
    public _Fields fieldForId(int fieldId) {
17460
      return _Fields.findByThriftId(fieldId);
17461
    }
17462
 
17463
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17464
      org.apache.thrift.protocol.TField field;
17465
      iprot.readStructBegin();
17466
      while (true)
17467
      {
17468
        field = iprot.readFieldBegin();
17469
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17470
          break;
17471
        }
17472
        switch (field.id) {
17473
          case 0: // SUCCESS
17474
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
17475
              this.success = new Vendor();
17476
              this.success.read(iprot);
17477
            } else { 
17478
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17479
            }
17480
            break;
17481
          default:
17482
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17483
        }
17484
        iprot.readFieldEnd();
17485
      }
17486
      iprot.readStructEnd();
17487
      validate();
17488
    }
17489
 
17490
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17491
      oprot.writeStructBegin(STRUCT_DESC);
17492
 
17493
      if (this.isSetSuccess()) {
17494
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17495
        this.success.write(oprot);
17496
        oprot.writeFieldEnd();
17497
      }
17498
      oprot.writeFieldStop();
17499
      oprot.writeStructEnd();
17500
    }
17501
 
17502
    @Override
17503
    public String toString() {
17504
      StringBuilder sb = new StringBuilder("getVendor_result(");
17505
      boolean first = true;
17506
 
17507
      sb.append("success:");
17508
      if (this.success == null) {
17509
        sb.append("null");
17510
      } else {
17511
        sb.append(this.success);
17512
      }
17513
      first = false;
17514
      sb.append(")");
17515
      return sb.toString();
17516
    }
17517
 
17518
    public void validate() throws org.apache.thrift.TException {
17519
      // check for required fields
17520
    }
17521
 
17522
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17523
      try {
17524
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17525
      } catch (org.apache.thrift.TException te) {
17526
        throw new java.io.IOException(te);
17527
      }
17528
    }
17529
 
17530
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17531
      try {
17532
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17533
      } catch (org.apache.thrift.TException te) {
17534
        throw new java.io.IOException(te);
17535
      }
17536
    }
17537
 
17538
  }
17539
 
17540
  public static class getAllVendors_args implements org.apache.thrift.TBase<getAllVendors_args, getAllVendors_args._Fields>, java.io.Serializable, Cloneable   {
17541
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendors_args");
17542
 
17543
 
17544
 
17545
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17546
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17547
;
17548
 
17549
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17550
 
17551
      static {
17552
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17553
          byName.put(field.getFieldName(), field);
17554
        }
17555
      }
17556
 
17557
      /**
17558
       * Find the _Fields constant that matches fieldId, or null if its not found.
17559
       */
17560
      public static _Fields findByThriftId(int fieldId) {
17561
        switch(fieldId) {
17562
          default:
17563
            return null;
17564
        }
17565
      }
17566
 
17567
      /**
17568
       * Find the _Fields constant that matches fieldId, throwing an exception
17569
       * if it is not found.
17570
       */
17571
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17572
        _Fields fields = findByThriftId(fieldId);
17573
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17574
        return fields;
17575
      }
17576
 
17577
      /**
17578
       * Find the _Fields constant that matches name, or null if its not found.
17579
       */
17580
      public static _Fields findByName(String name) {
17581
        return byName.get(name);
17582
      }
17583
 
17584
      private final short _thriftId;
17585
      private final String _fieldName;
17586
 
17587
      _Fields(short thriftId, String fieldName) {
17588
        _thriftId = thriftId;
17589
        _fieldName = fieldName;
17590
      }
17591
 
17592
      public short getThriftFieldId() {
17593
        return _thriftId;
17594
      }
17595
 
17596
      public String getFieldName() {
17597
        return _fieldName;
17598
      }
17599
    }
17600
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17601
    static {
17602
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17603
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17604
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendors_args.class, metaDataMap);
17605
    }
17606
 
17607
    public getAllVendors_args() {
17608
    }
17609
 
17610
    /**
17611
     * Performs a deep copy on <i>other</i>.
17612
     */
17613
    public getAllVendors_args(getAllVendors_args other) {
17614
    }
17615
 
17616
    public getAllVendors_args deepCopy() {
17617
      return new getAllVendors_args(this);
17618
    }
17619
 
17620
    @Override
17621
    public void clear() {
17622
    }
17623
 
17624
    public void setFieldValue(_Fields field, Object value) {
17625
      switch (field) {
17626
      }
17627
    }
17628
 
17629
    public Object getFieldValue(_Fields field) {
17630
      switch (field) {
17631
      }
17632
      throw new IllegalStateException();
17633
    }
17634
 
17635
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17636
    public boolean isSet(_Fields field) {
17637
      if (field == null) {
17638
        throw new IllegalArgumentException();
17639
      }
17640
 
17641
      switch (field) {
17642
      }
17643
      throw new IllegalStateException();
17644
    }
17645
 
17646
    @Override
17647
    public boolean equals(Object that) {
17648
      if (that == null)
17649
        return false;
17650
      if (that instanceof getAllVendors_args)
17651
        return this.equals((getAllVendors_args)that);
17652
      return false;
17653
    }
17654
 
17655
    public boolean equals(getAllVendors_args that) {
17656
      if (that == null)
17657
        return false;
17658
 
17659
      return true;
17660
    }
17661
 
17662
    @Override
17663
    public int hashCode() {
17664
      return 0;
17665
    }
17666
 
17667
    public int compareTo(getAllVendors_args other) {
17668
      if (!getClass().equals(other.getClass())) {
17669
        return getClass().getName().compareTo(other.getClass().getName());
17670
      }
17671
 
17672
      int lastComparison = 0;
17673
      getAllVendors_args typedOther = (getAllVendors_args)other;
17674
 
17675
      return 0;
17676
    }
17677
 
17678
    public _Fields fieldForId(int fieldId) {
17679
      return _Fields.findByThriftId(fieldId);
17680
    }
17681
 
17682
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17683
      org.apache.thrift.protocol.TField field;
17684
      iprot.readStructBegin();
17685
      while (true)
17686
      {
17687
        field = iprot.readFieldBegin();
17688
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17689
          break;
17690
        }
17691
        switch (field.id) {
17692
          default:
17693
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17694
        }
17695
        iprot.readFieldEnd();
17696
      }
17697
      iprot.readStructEnd();
17698
      validate();
17699
    }
17700
 
17701
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17702
      validate();
17703
 
17704
      oprot.writeStructBegin(STRUCT_DESC);
17705
      oprot.writeFieldStop();
17706
      oprot.writeStructEnd();
17707
    }
17708
 
17709
    @Override
17710
    public String toString() {
17711
      StringBuilder sb = new StringBuilder("getAllVendors_args(");
17712
      boolean first = true;
17713
 
17714
      sb.append(")");
17715
      return sb.toString();
17716
    }
17717
 
17718
    public void validate() throws org.apache.thrift.TException {
17719
      // check for required fields
17720
    }
17721
 
17722
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17723
      try {
17724
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17725
      } catch (org.apache.thrift.TException te) {
17726
        throw new java.io.IOException(te);
17727
      }
17728
    }
17729
 
17730
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17731
      try {
17732
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17733
      } catch (org.apache.thrift.TException te) {
17734
        throw new java.io.IOException(te);
17735
      }
17736
    }
17737
 
17738
  }
17739
 
17740
  public static class getAllVendors_result implements org.apache.thrift.TBase<getAllVendors_result, getAllVendors_result._Fields>, java.io.Serializable, Cloneable   {
17741
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendors_result");
17742
 
17743
    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);
17744
 
17745
    private List<Vendor> success; // required
17746
 
17747
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17748
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17749
      SUCCESS((short)0, "success");
17750
 
17751
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17752
 
17753
      static {
17754
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17755
          byName.put(field.getFieldName(), field);
17756
        }
17757
      }
17758
 
17759
      /**
17760
       * Find the _Fields constant that matches fieldId, or null if its not found.
17761
       */
17762
      public static _Fields findByThriftId(int fieldId) {
17763
        switch(fieldId) {
17764
          case 0: // SUCCESS
17765
            return SUCCESS;
17766
          default:
17767
            return null;
17768
        }
17769
      }
17770
 
17771
      /**
17772
       * Find the _Fields constant that matches fieldId, throwing an exception
17773
       * if it is not found.
17774
       */
17775
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17776
        _Fields fields = findByThriftId(fieldId);
17777
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17778
        return fields;
17779
      }
17780
 
17781
      /**
17782
       * Find the _Fields constant that matches name, or null if its not found.
17783
       */
17784
      public static _Fields findByName(String name) {
17785
        return byName.get(name);
17786
      }
17787
 
17788
      private final short _thriftId;
17789
      private final String _fieldName;
17790
 
17791
      _Fields(short thriftId, String fieldName) {
17792
        _thriftId = thriftId;
17793
        _fieldName = fieldName;
17794
      }
17795
 
17796
      public short getThriftFieldId() {
17797
        return _thriftId;
17798
      }
17799
 
17800
      public String getFieldName() {
17801
        return _fieldName;
17802
      }
17803
    }
17804
 
17805
    // isset id assignments
17806
 
17807
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17808
    static {
17809
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17810
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17811
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
17812
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class))));
17813
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17814
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendors_result.class, metaDataMap);
17815
    }
17816
 
17817
    public getAllVendors_result() {
17818
    }
17819
 
17820
    public getAllVendors_result(
17821
      List<Vendor> success)
17822
    {
17823
      this();
17824
      this.success = success;
17825
    }
17826
 
17827
    /**
17828
     * Performs a deep copy on <i>other</i>.
17829
     */
17830
    public getAllVendors_result(getAllVendors_result other) {
17831
      if (other.isSetSuccess()) {
17832
        List<Vendor> __this__success = new ArrayList<Vendor>();
17833
        for (Vendor other_element : other.success) {
17834
          __this__success.add(new Vendor(other_element));
17835
        }
17836
        this.success = __this__success;
17837
      }
17838
    }
17839
 
17840
    public getAllVendors_result deepCopy() {
17841
      return new getAllVendors_result(this);
17842
    }
17843
 
17844
    @Override
17845
    public void clear() {
17846
      this.success = null;
17847
    }
17848
 
17849
    public int getSuccessSize() {
17850
      return (this.success == null) ? 0 : this.success.size();
17851
    }
17852
 
17853
    public java.util.Iterator<Vendor> getSuccessIterator() {
17854
      return (this.success == null) ? null : this.success.iterator();
17855
    }
17856
 
17857
    public void addToSuccess(Vendor elem) {
17858
      if (this.success == null) {
17859
        this.success = new ArrayList<Vendor>();
17860
      }
17861
      this.success.add(elem);
17862
    }
17863
 
17864
    public List<Vendor> getSuccess() {
17865
      return this.success;
17866
    }
17867
 
17868
    public void setSuccess(List<Vendor> success) {
17869
      this.success = success;
17870
    }
17871
 
17872
    public void unsetSuccess() {
17873
      this.success = null;
17874
    }
17875
 
17876
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17877
    public boolean isSetSuccess() {
17878
      return this.success != null;
17879
    }
17880
 
17881
    public void setSuccessIsSet(boolean value) {
17882
      if (!value) {
17883
        this.success = null;
17884
      }
17885
    }
17886
 
17887
    public void setFieldValue(_Fields field, Object value) {
17888
      switch (field) {
17889
      case SUCCESS:
17890
        if (value == null) {
17891
          unsetSuccess();
17892
        } else {
17893
          setSuccess((List<Vendor>)value);
17894
        }
17895
        break;
17896
 
17897
      }
17898
    }
17899
 
17900
    public Object getFieldValue(_Fields field) {
17901
      switch (field) {
17902
      case SUCCESS:
17903
        return getSuccess();
17904
 
17905
      }
17906
      throw new IllegalStateException();
17907
    }
17908
 
17909
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17910
    public boolean isSet(_Fields field) {
17911
      if (field == null) {
17912
        throw new IllegalArgumentException();
17913
      }
17914
 
17915
      switch (field) {
17916
      case SUCCESS:
17917
        return isSetSuccess();
17918
      }
17919
      throw new IllegalStateException();
17920
    }
17921
 
17922
    @Override
17923
    public boolean equals(Object that) {
17924
      if (that == null)
17925
        return false;
17926
      if (that instanceof getAllVendors_result)
17927
        return this.equals((getAllVendors_result)that);
17928
      return false;
17929
    }
17930
 
17931
    public boolean equals(getAllVendors_result that) {
17932
      if (that == null)
17933
        return false;
17934
 
17935
      boolean this_present_success = true && this.isSetSuccess();
17936
      boolean that_present_success = true && that.isSetSuccess();
17937
      if (this_present_success || that_present_success) {
17938
        if (!(this_present_success && that_present_success))
17939
          return false;
17940
        if (!this.success.equals(that.success))
17941
          return false;
17942
      }
17943
 
17944
      return true;
17945
    }
17946
 
17947
    @Override
17948
    public int hashCode() {
17949
      return 0;
17950
    }
17951
 
17952
    public int compareTo(getAllVendors_result other) {
17953
      if (!getClass().equals(other.getClass())) {
17954
        return getClass().getName().compareTo(other.getClass().getName());
17955
      }
17956
 
17957
      int lastComparison = 0;
17958
      getAllVendors_result typedOther = (getAllVendors_result)other;
17959
 
17960
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17961
      if (lastComparison != 0) {
17962
        return lastComparison;
17963
      }
17964
      if (isSetSuccess()) {
17965
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17966
        if (lastComparison != 0) {
17967
          return lastComparison;
17968
        }
17969
      }
17970
      return 0;
17971
    }
17972
 
17973
    public _Fields fieldForId(int fieldId) {
17974
      return _Fields.findByThriftId(fieldId);
17975
    }
17976
 
17977
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17978
      org.apache.thrift.protocol.TField field;
17979
      iprot.readStructBegin();
17980
      while (true)
17981
      {
17982
        field = iprot.readFieldBegin();
17983
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17984
          break;
17985
        }
17986
        switch (field.id) {
17987
          case 0: // SUCCESS
17988
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
17989
              {
17990
                org.apache.thrift.protocol.TList _list36 = iprot.readListBegin();
17991
                this.success = new ArrayList<Vendor>(_list36.size);
17992
                for (int _i37 = 0; _i37 < _list36.size; ++_i37)
17993
                {
17994
                  Vendor _elem38; // required
17995
                  _elem38 = new Vendor();
17996
                  _elem38.read(iprot);
17997
                  this.success.add(_elem38);
17998
                }
17999
                iprot.readListEnd();
18000
              }
18001
            } else { 
18002
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18003
            }
18004
            break;
18005
          default:
18006
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18007
        }
18008
        iprot.readFieldEnd();
18009
      }
18010
      iprot.readStructEnd();
18011
      validate();
18012
    }
18013
 
18014
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18015
      oprot.writeStructBegin(STRUCT_DESC);
18016
 
18017
      if (this.isSetSuccess()) {
18018
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
18019
        {
18020
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
18021
          for (Vendor _iter39 : this.success)
18022
          {
18023
            _iter39.write(oprot);
18024
          }
18025
          oprot.writeListEnd();
18026
        }
18027
        oprot.writeFieldEnd();
18028
      }
18029
      oprot.writeFieldStop();
18030
      oprot.writeStructEnd();
18031
    }
18032
 
18033
    @Override
18034
    public String toString() {
18035
      StringBuilder sb = new StringBuilder("getAllVendors_result(");
18036
      boolean first = true;
18037
 
18038
      sb.append("success:");
18039
      if (this.success == null) {
18040
        sb.append("null");
18041
      } else {
18042
        sb.append(this.success);
18043
      }
18044
      first = false;
18045
      sb.append(")");
18046
      return sb.toString();
18047
    }
18048
 
18049
    public void validate() throws org.apache.thrift.TException {
18050
      // check for required fields
18051
    }
18052
 
18053
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18054
      try {
18055
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18056
      } catch (org.apache.thrift.TException te) {
18057
        throw new java.io.IOException(te);
18058
      }
18059
    }
18060
 
18061
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18062
      try {
18063
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18064
      } catch (org.apache.thrift.TException te) {
18065
        throw new java.io.IOException(te);
18066
      }
18067
    }
18068
 
18069
  }
18070
 
18071
  public static class addVendorItemMapping_args implements org.apache.thrift.TBase<addVendorItemMapping_args, addVendorItemMapping_args._Fields>, java.io.Serializable, Cloneable   {
18072
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemMapping_args");
18073
 
18074
    private static final org.apache.thrift.protocol.TField KEY_FIELD_DESC = new org.apache.thrift.protocol.TField("key", org.apache.thrift.protocol.TType.STRING, (short)1);
18075
    private static final org.apache.thrift.protocol.TField VENDOR_ITEM_MAPPING_FIELD_DESC = new org.apache.thrift.protocol.TField("vendorItemMapping", org.apache.thrift.protocol.TType.STRUCT, (short)2);
18076
 
18077
    private String key; // required
18078
    private VendorItemMapping vendorItemMapping; // required
18079
 
18080
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18081
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18082
      KEY((short)1, "key"),
18083
      VENDOR_ITEM_MAPPING((short)2, "vendorItemMapping");
18084
 
18085
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18086
 
18087
      static {
18088
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18089
          byName.put(field.getFieldName(), field);
18090
        }
18091
      }
18092
 
18093
      /**
18094
       * Find the _Fields constant that matches fieldId, or null if its not found.
18095
       */
18096
      public static _Fields findByThriftId(int fieldId) {
18097
        switch(fieldId) {
18098
          case 1: // KEY
18099
            return KEY;
18100
          case 2: // VENDOR_ITEM_MAPPING
18101
            return VENDOR_ITEM_MAPPING;
18102
          default:
18103
            return null;
18104
        }
18105
      }
18106
 
18107
      /**
18108
       * Find the _Fields constant that matches fieldId, throwing an exception
18109
       * if it is not found.
18110
       */
18111
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18112
        _Fields fields = findByThriftId(fieldId);
18113
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18114
        return fields;
18115
      }
18116
 
18117
      /**
18118
       * Find the _Fields constant that matches name, or null if its not found.
18119
       */
18120
      public static _Fields findByName(String name) {
18121
        return byName.get(name);
18122
      }
18123
 
18124
      private final short _thriftId;
18125
      private final String _fieldName;
18126
 
18127
      _Fields(short thriftId, String fieldName) {
18128
        _thriftId = thriftId;
18129
        _fieldName = fieldName;
18130
      }
18131
 
18132
      public short getThriftFieldId() {
18133
        return _thriftId;
18134
      }
18135
 
18136
      public String getFieldName() {
18137
        return _fieldName;
18138
      }
18139
    }
18140
 
18141
    // isset id assignments
18142
 
18143
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18144
    static {
18145
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18146
      tmpMap.put(_Fields.KEY, new org.apache.thrift.meta_data.FieldMetaData("key", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18147
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
18148
      tmpMap.put(_Fields.VENDOR_ITEM_MAPPING, new org.apache.thrift.meta_data.FieldMetaData("vendorItemMapping", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18149
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class)));
18150
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18151
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemMapping_args.class, metaDataMap);
18152
    }
18153
 
18154
    public addVendorItemMapping_args() {
18155
    }
18156
 
18157
    public addVendorItemMapping_args(
18158
      String key,
18159
      VendorItemMapping vendorItemMapping)
18160
    {
18161
      this();
18162
      this.key = key;
18163
      this.vendorItemMapping = vendorItemMapping;
18164
    }
18165
 
18166
    /**
18167
     * Performs a deep copy on <i>other</i>.
18168
     */
18169
    public addVendorItemMapping_args(addVendorItemMapping_args other) {
18170
      if (other.isSetKey()) {
18171
        this.key = other.key;
18172
      }
18173
      if (other.isSetVendorItemMapping()) {
18174
        this.vendorItemMapping = new VendorItemMapping(other.vendorItemMapping);
18175
      }
18176
    }
18177
 
18178
    public addVendorItemMapping_args deepCopy() {
18179
      return new addVendorItemMapping_args(this);
18180
    }
18181
 
18182
    @Override
18183
    public void clear() {
18184
      this.key = null;
18185
      this.vendorItemMapping = null;
18186
    }
18187
 
18188
    public String getKey() {
18189
      return this.key;
18190
    }
18191
 
18192
    public void setKey(String key) {
18193
      this.key = key;
18194
    }
18195
 
18196
    public void unsetKey() {
18197
      this.key = null;
18198
    }
18199
 
18200
    /** Returns true if field key is set (has been assigned a value) and false otherwise */
18201
    public boolean isSetKey() {
18202
      return this.key != null;
18203
    }
18204
 
18205
    public void setKeyIsSet(boolean value) {
18206
      if (!value) {
18207
        this.key = null;
18208
      }
18209
    }
18210
 
18211
    public VendorItemMapping getVendorItemMapping() {
18212
      return this.vendorItemMapping;
18213
    }
18214
 
18215
    public void setVendorItemMapping(VendorItemMapping vendorItemMapping) {
18216
      this.vendorItemMapping = vendorItemMapping;
18217
    }
18218
 
18219
    public void unsetVendorItemMapping() {
18220
      this.vendorItemMapping = null;
18221
    }
18222
 
18223
    /** Returns true if field vendorItemMapping is set (has been assigned a value) and false otherwise */
18224
    public boolean isSetVendorItemMapping() {
18225
      return this.vendorItemMapping != null;
18226
    }
18227
 
18228
    public void setVendorItemMappingIsSet(boolean value) {
18229
      if (!value) {
18230
        this.vendorItemMapping = null;
18231
      }
18232
    }
18233
 
18234
    public void setFieldValue(_Fields field, Object value) {
18235
      switch (field) {
18236
      case KEY:
18237
        if (value == null) {
18238
          unsetKey();
18239
        } else {
18240
          setKey((String)value);
18241
        }
18242
        break;
18243
 
18244
      case VENDOR_ITEM_MAPPING:
18245
        if (value == null) {
18246
          unsetVendorItemMapping();
18247
        } else {
18248
          setVendorItemMapping((VendorItemMapping)value);
18249
        }
18250
        break;
18251
 
18252
      }
18253
    }
18254
 
18255
    public Object getFieldValue(_Fields field) {
18256
      switch (field) {
18257
      case KEY:
18258
        return getKey();
18259
 
18260
      case VENDOR_ITEM_MAPPING:
18261
        return getVendorItemMapping();
18262
 
18263
      }
18264
      throw new IllegalStateException();
18265
    }
18266
 
18267
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18268
    public boolean isSet(_Fields field) {
18269
      if (field == null) {
18270
        throw new IllegalArgumentException();
18271
      }
18272
 
18273
      switch (field) {
18274
      case KEY:
18275
        return isSetKey();
18276
      case VENDOR_ITEM_MAPPING:
18277
        return isSetVendorItemMapping();
18278
      }
18279
      throw new IllegalStateException();
18280
    }
18281
 
18282
    @Override
18283
    public boolean equals(Object that) {
18284
      if (that == null)
18285
        return false;
18286
      if (that instanceof addVendorItemMapping_args)
18287
        return this.equals((addVendorItemMapping_args)that);
18288
      return false;
18289
    }
18290
 
18291
    public boolean equals(addVendorItemMapping_args that) {
18292
      if (that == null)
18293
        return false;
18294
 
18295
      boolean this_present_key = true && this.isSetKey();
18296
      boolean that_present_key = true && that.isSetKey();
18297
      if (this_present_key || that_present_key) {
18298
        if (!(this_present_key && that_present_key))
18299
          return false;
18300
        if (!this.key.equals(that.key))
18301
          return false;
18302
      }
18303
 
18304
      boolean this_present_vendorItemMapping = true && this.isSetVendorItemMapping();
18305
      boolean that_present_vendorItemMapping = true && that.isSetVendorItemMapping();
18306
      if (this_present_vendorItemMapping || that_present_vendorItemMapping) {
18307
        if (!(this_present_vendorItemMapping && that_present_vendorItemMapping))
18308
          return false;
18309
        if (!this.vendorItemMapping.equals(that.vendorItemMapping))
18310
          return false;
18311
      }
18312
 
18313
      return true;
18314
    }
18315
 
18316
    @Override
18317
    public int hashCode() {
18318
      return 0;
18319
    }
18320
 
18321
    public int compareTo(addVendorItemMapping_args other) {
18322
      if (!getClass().equals(other.getClass())) {
18323
        return getClass().getName().compareTo(other.getClass().getName());
18324
      }
18325
 
18326
      int lastComparison = 0;
18327
      addVendorItemMapping_args typedOther = (addVendorItemMapping_args)other;
18328
 
18329
      lastComparison = Boolean.valueOf(isSetKey()).compareTo(typedOther.isSetKey());
18330
      if (lastComparison != 0) {
18331
        return lastComparison;
18332
      }
18333
      if (isSetKey()) {
18334
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.key, typedOther.key);
18335
        if (lastComparison != 0) {
18336
          return lastComparison;
18337
        }
18338
      }
18339
      lastComparison = Boolean.valueOf(isSetVendorItemMapping()).compareTo(typedOther.isSetVendorItemMapping());
18340
      if (lastComparison != 0) {
18341
        return lastComparison;
18342
      }
18343
      if (isSetVendorItemMapping()) {
18344
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorItemMapping, typedOther.vendorItemMapping);
18345
        if (lastComparison != 0) {
18346
          return lastComparison;
18347
        }
18348
      }
18349
      return 0;
18350
    }
18351
 
18352
    public _Fields fieldForId(int fieldId) {
18353
      return _Fields.findByThriftId(fieldId);
18354
    }
18355
 
18356
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18357
      org.apache.thrift.protocol.TField field;
18358
      iprot.readStructBegin();
18359
      while (true)
18360
      {
18361
        field = iprot.readFieldBegin();
18362
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18363
          break;
18364
        }
18365
        switch (field.id) {
18366
          case 1: // KEY
18367
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
18368
              this.key = iprot.readString();
18369
            } else { 
18370
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18371
            }
18372
            break;
18373
          case 2: // VENDOR_ITEM_MAPPING
18374
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
18375
              this.vendorItemMapping = new VendorItemMapping();
18376
              this.vendorItemMapping.read(iprot);
18377
            } else { 
18378
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18379
            }
18380
            break;
18381
          default:
18382
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18383
        }
18384
        iprot.readFieldEnd();
18385
      }
18386
      iprot.readStructEnd();
18387
      validate();
18388
    }
18389
 
18390
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18391
      validate();
18392
 
18393
      oprot.writeStructBegin(STRUCT_DESC);
18394
      if (this.key != null) {
18395
        oprot.writeFieldBegin(KEY_FIELD_DESC);
18396
        oprot.writeString(this.key);
18397
        oprot.writeFieldEnd();
18398
      }
18399
      if (this.vendorItemMapping != null) {
18400
        oprot.writeFieldBegin(VENDOR_ITEM_MAPPING_FIELD_DESC);
18401
        this.vendorItemMapping.write(oprot);
18402
        oprot.writeFieldEnd();
18403
      }
18404
      oprot.writeFieldStop();
18405
      oprot.writeStructEnd();
18406
    }
18407
 
18408
    @Override
18409
    public String toString() {
18410
      StringBuilder sb = new StringBuilder("addVendorItemMapping_args(");
18411
      boolean first = true;
18412
 
18413
      sb.append("key:");
18414
      if (this.key == null) {
18415
        sb.append("null");
18416
      } else {
18417
        sb.append(this.key);
18418
      }
18419
      first = false;
18420
      if (!first) sb.append(", ");
18421
      sb.append("vendorItemMapping:");
18422
      if (this.vendorItemMapping == null) {
18423
        sb.append("null");
18424
      } else {
18425
        sb.append(this.vendorItemMapping);
18426
      }
18427
      first = false;
18428
      sb.append(")");
18429
      return sb.toString();
18430
    }
18431
 
18432
    public void validate() throws org.apache.thrift.TException {
18433
      // check for required fields
18434
    }
18435
 
18436
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18437
      try {
18438
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18439
      } catch (org.apache.thrift.TException te) {
18440
        throw new java.io.IOException(te);
18441
      }
18442
    }
18443
 
18444
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18445
      try {
18446
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18447
      } catch (org.apache.thrift.TException te) {
18448
        throw new java.io.IOException(te);
18449
      }
18450
    }
18451
 
18452
  }
18453
 
18454
  public static class addVendorItemMapping_result implements org.apache.thrift.TBase<addVendorItemMapping_result, addVendorItemMapping_result._Fields>, java.io.Serializable, Cloneable   {
18455
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemMapping_result");
18456
 
18457
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
18458
 
18459
    private InventoryServiceException cex; // required
18460
 
18461
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18462
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18463
      CEX((short)1, "cex");
18464
 
18465
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18466
 
18467
      static {
18468
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18469
          byName.put(field.getFieldName(), field);
18470
        }
18471
      }
18472
 
18473
      /**
18474
       * Find the _Fields constant that matches fieldId, or null if its not found.
18475
       */
18476
      public static _Fields findByThriftId(int fieldId) {
18477
        switch(fieldId) {
18478
          case 1: // CEX
18479
            return CEX;
18480
          default:
18481
            return null;
18482
        }
18483
      }
18484
 
18485
      /**
18486
       * Find the _Fields constant that matches fieldId, throwing an exception
18487
       * if it is not found.
18488
       */
18489
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18490
        _Fields fields = findByThriftId(fieldId);
18491
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18492
        return fields;
18493
      }
18494
 
18495
      /**
18496
       * Find the _Fields constant that matches name, or null if its not found.
18497
       */
18498
      public static _Fields findByName(String name) {
18499
        return byName.get(name);
18500
      }
18501
 
18502
      private final short _thriftId;
18503
      private final String _fieldName;
18504
 
18505
      _Fields(short thriftId, String fieldName) {
18506
        _thriftId = thriftId;
18507
        _fieldName = fieldName;
18508
      }
18509
 
18510
      public short getThriftFieldId() {
18511
        return _thriftId;
18512
      }
18513
 
18514
      public String getFieldName() {
18515
        return _fieldName;
18516
      }
18517
    }
18518
 
18519
    // isset id assignments
18520
 
18521
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18522
    static {
18523
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18524
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18525
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
18526
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18527
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemMapping_result.class, metaDataMap);
18528
    }
18529
 
18530
    public addVendorItemMapping_result() {
18531
    }
18532
 
18533
    public addVendorItemMapping_result(
18534
      InventoryServiceException cex)
18535
    {
18536
      this();
18537
      this.cex = cex;
18538
    }
18539
 
18540
    /**
18541
     * Performs a deep copy on <i>other</i>.
18542
     */
18543
    public addVendorItemMapping_result(addVendorItemMapping_result other) {
18544
      if (other.isSetCex()) {
18545
        this.cex = new InventoryServiceException(other.cex);
18546
      }
18547
    }
18548
 
18549
    public addVendorItemMapping_result deepCopy() {
18550
      return new addVendorItemMapping_result(this);
18551
    }
18552
 
18553
    @Override
18554
    public void clear() {
18555
      this.cex = null;
18556
    }
18557
 
18558
    public InventoryServiceException getCex() {
18559
      return this.cex;
18560
    }
18561
 
18562
    public void setCex(InventoryServiceException cex) {
18563
      this.cex = cex;
18564
    }
18565
 
18566
    public void unsetCex() {
18567
      this.cex = null;
18568
    }
18569
 
18570
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
18571
    public boolean isSetCex() {
18572
      return this.cex != null;
18573
    }
18574
 
18575
    public void setCexIsSet(boolean value) {
18576
      if (!value) {
18577
        this.cex = null;
18578
      }
18579
    }
18580
 
18581
    public void setFieldValue(_Fields field, Object value) {
18582
      switch (field) {
18583
      case CEX:
18584
        if (value == null) {
18585
          unsetCex();
18586
        } else {
18587
          setCex((InventoryServiceException)value);
18588
        }
18589
        break;
18590
 
18591
      }
18592
    }
18593
 
18594
    public Object getFieldValue(_Fields field) {
18595
      switch (field) {
18596
      case CEX:
18597
        return getCex();
18598
 
18599
      }
18600
      throw new IllegalStateException();
18601
    }
18602
 
18603
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18604
    public boolean isSet(_Fields field) {
18605
      if (field == null) {
18606
        throw new IllegalArgumentException();
18607
      }
18608
 
18609
      switch (field) {
18610
      case CEX:
18611
        return isSetCex();
18612
      }
18613
      throw new IllegalStateException();
18614
    }
18615
 
18616
    @Override
18617
    public boolean equals(Object that) {
18618
      if (that == null)
18619
        return false;
18620
      if (that instanceof addVendorItemMapping_result)
18621
        return this.equals((addVendorItemMapping_result)that);
18622
      return false;
18623
    }
18624
 
18625
    public boolean equals(addVendorItemMapping_result that) {
18626
      if (that == null)
18627
        return false;
18628
 
18629
      boolean this_present_cex = true && this.isSetCex();
18630
      boolean that_present_cex = true && that.isSetCex();
18631
      if (this_present_cex || that_present_cex) {
18632
        if (!(this_present_cex && that_present_cex))
18633
          return false;
18634
        if (!this.cex.equals(that.cex))
18635
          return false;
18636
      }
18637
 
18638
      return true;
18639
    }
18640
 
18641
    @Override
18642
    public int hashCode() {
18643
      return 0;
18644
    }
18645
 
18646
    public int compareTo(addVendorItemMapping_result other) {
18647
      if (!getClass().equals(other.getClass())) {
18648
        return getClass().getName().compareTo(other.getClass().getName());
18649
      }
18650
 
18651
      int lastComparison = 0;
18652
      addVendorItemMapping_result typedOther = (addVendorItemMapping_result)other;
18653
 
18654
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
18655
      if (lastComparison != 0) {
18656
        return lastComparison;
18657
      }
18658
      if (isSetCex()) {
18659
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
18660
        if (lastComparison != 0) {
18661
          return lastComparison;
18662
        }
18663
      }
18664
      return 0;
18665
    }
18666
 
18667
    public _Fields fieldForId(int fieldId) {
18668
      return _Fields.findByThriftId(fieldId);
18669
    }
18670
 
18671
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18672
      org.apache.thrift.protocol.TField field;
18673
      iprot.readStructBegin();
18674
      while (true)
18675
      {
18676
        field = iprot.readFieldBegin();
18677
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18678
          break;
18679
        }
18680
        switch (field.id) {
18681
          case 1: // CEX
18682
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
18683
              this.cex = new InventoryServiceException();
18684
              this.cex.read(iprot);
18685
            } else { 
18686
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18687
            }
18688
            break;
18689
          default:
18690
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18691
        }
18692
        iprot.readFieldEnd();
18693
      }
18694
      iprot.readStructEnd();
18695
      validate();
18696
    }
18697
 
18698
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18699
      oprot.writeStructBegin(STRUCT_DESC);
18700
 
18701
      if (this.isSetCex()) {
18702
        oprot.writeFieldBegin(CEX_FIELD_DESC);
18703
        this.cex.write(oprot);
18704
        oprot.writeFieldEnd();
18705
      }
18706
      oprot.writeFieldStop();
18707
      oprot.writeStructEnd();
18708
    }
18709
 
18710
    @Override
18711
    public String toString() {
18712
      StringBuilder sb = new StringBuilder("addVendorItemMapping_result(");
18713
      boolean first = true;
18714
 
18715
      sb.append("cex:");
18716
      if (this.cex == null) {
18717
        sb.append("null");
18718
      } else {
18719
        sb.append(this.cex);
18720
      }
18721
      first = false;
18722
      sb.append(")");
18723
      return sb.toString();
18724
    }
18725
 
18726
    public void validate() throws org.apache.thrift.TException {
18727
      // check for required fields
18728
    }
18729
 
18730
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18731
      try {
18732
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18733
      } catch (org.apache.thrift.TException te) {
18734
        throw new java.io.IOException(te);
18735
      }
18736
    }
18737
 
18738
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18739
      try {
18740
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18741
      } catch (org.apache.thrift.TException te) {
18742
        throw new java.io.IOException(te);
18743
      }
18744
    }
18745
 
18746
  }
18747
 
18748
  public static class getVendorItemMappings_args implements org.apache.thrift.TBase<getVendorItemMappings_args, getVendorItemMappings_args._Fields>, java.io.Serializable, Cloneable   {
18749
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendorItemMappings_args");
18750
 
18751
    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);
18752
 
18753
    private long itemId; // required
18754
 
18755
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18756
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18757
      ITEM_ID((short)1, "itemId");
18758
 
18759
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18760
 
18761
      static {
18762
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18763
          byName.put(field.getFieldName(), field);
18764
        }
18765
      }
18766
 
18767
      /**
18768
       * Find the _Fields constant that matches fieldId, or null if its not found.
18769
       */
18770
      public static _Fields findByThriftId(int fieldId) {
18771
        switch(fieldId) {
18772
          case 1: // ITEM_ID
18773
            return ITEM_ID;
18774
          default:
18775
            return null;
18776
        }
18777
      }
18778
 
18779
      /**
18780
       * Find the _Fields constant that matches fieldId, throwing an exception
18781
       * if it is not found.
18782
       */
18783
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18784
        _Fields fields = findByThriftId(fieldId);
18785
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18786
        return fields;
18787
      }
18788
 
18789
      /**
18790
       * Find the _Fields constant that matches name, or null if its not found.
18791
       */
18792
      public static _Fields findByName(String name) {
18793
        return byName.get(name);
18794
      }
18795
 
18796
      private final short _thriftId;
18797
      private final String _fieldName;
18798
 
18799
      _Fields(short thriftId, String fieldName) {
18800
        _thriftId = thriftId;
18801
        _fieldName = fieldName;
18802
      }
18803
 
18804
      public short getThriftFieldId() {
18805
        return _thriftId;
18806
      }
18807
 
18808
      public String getFieldName() {
18809
        return _fieldName;
18810
      }
18811
    }
18812
 
18813
    // isset id assignments
18814
    private static final int __ITEMID_ISSET_ID = 0;
18815
    private BitSet __isset_bit_vector = new BitSet(1);
18816
 
18817
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18818
    static {
18819
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18820
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18821
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
18822
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18823
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendorItemMappings_args.class, metaDataMap);
18824
    }
18825
 
18826
    public getVendorItemMappings_args() {
18827
    }
18828
 
18829
    public getVendorItemMappings_args(
18830
      long itemId)
18831
    {
18832
      this();
18833
      this.itemId = itemId;
18834
      setItemIdIsSet(true);
18835
    }
18836
 
18837
    /**
18838
     * Performs a deep copy on <i>other</i>.
18839
     */
18840
    public getVendorItemMappings_args(getVendorItemMappings_args other) {
18841
      __isset_bit_vector.clear();
18842
      __isset_bit_vector.or(other.__isset_bit_vector);
18843
      this.itemId = other.itemId;
18844
    }
18845
 
18846
    public getVendorItemMappings_args deepCopy() {
18847
      return new getVendorItemMappings_args(this);
18848
    }
18849
 
18850
    @Override
18851
    public void clear() {
18852
      setItemIdIsSet(false);
18853
      this.itemId = 0;
18854
    }
18855
 
18856
    public long getItemId() {
18857
      return this.itemId;
18858
    }
18859
 
18860
    public void setItemId(long itemId) {
18861
      this.itemId = itemId;
18862
      setItemIdIsSet(true);
18863
    }
18864
 
18865
    public void unsetItemId() {
18866
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
18867
    }
18868
 
18869
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
18870
    public boolean isSetItemId() {
18871
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
18872
    }
18873
 
18874
    public void setItemIdIsSet(boolean value) {
18875
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
18876
    }
18877
 
18878
    public void setFieldValue(_Fields field, Object value) {
18879
      switch (field) {
18880
      case ITEM_ID:
18881
        if (value == null) {
18882
          unsetItemId();
18883
        } else {
18884
          setItemId((Long)value);
18885
        }
18886
        break;
18887
 
18888
      }
18889
    }
18890
 
18891
    public Object getFieldValue(_Fields field) {
18892
      switch (field) {
18893
      case ITEM_ID:
18894
        return Long.valueOf(getItemId());
18895
 
18896
      }
18897
      throw new IllegalStateException();
18898
    }
18899
 
18900
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18901
    public boolean isSet(_Fields field) {
18902
      if (field == null) {
18903
        throw new IllegalArgumentException();
18904
      }
18905
 
18906
      switch (field) {
18907
      case ITEM_ID:
18908
        return isSetItemId();
18909
      }
18910
      throw new IllegalStateException();
18911
    }
18912
 
18913
    @Override
18914
    public boolean equals(Object that) {
18915
      if (that == null)
18916
        return false;
18917
      if (that instanceof getVendorItemMappings_args)
18918
        return this.equals((getVendorItemMappings_args)that);
18919
      return false;
18920
    }
18921
 
18922
    public boolean equals(getVendorItemMappings_args that) {
18923
      if (that == null)
18924
        return false;
18925
 
18926
      boolean this_present_itemId = true;
18927
      boolean that_present_itemId = true;
18928
      if (this_present_itemId || that_present_itemId) {
18929
        if (!(this_present_itemId && that_present_itemId))
18930
          return false;
18931
        if (this.itemId != that.itemId)
18932
          return false;
18933
      }
18934
 
18935
      return true;
18936
    }
18937
 
18938
    @Override
18939
    public int hashCode() {
18940
      return 0;
18941
    }
18942
 
18943
    public int compareTo(getVendorItemMappings_args other) {
18944
      if (!getClass().equals(other.getClass())) {
18945
        return getClass().getName().compareTo(other.getClass().getName());
18946
      }
18947
 
18948
      int lastComparison = 0;
18949
      getVendorItemMappings_args typedOther = (getVendorItemMappings_args)other;
18950
 
18951
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
18952
      if (lastComparison != 0) {
18953
        return lastComparison;
18954
      }
18955
      if (isSetItemId()) {
18956
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
18957
        if (lastComparison != 0) {
18958
          return lastComparison;
18959
        }
18960
      }
18961
      return 0;
18962
    }
18963
 
18964
    public _Fields fieldForId(int fieldId) {
18965
      return _Fields.findByThriftId(fieldId);
18966
    }
18967
 
18968
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18969
      org.apache.thrift.protocol.TField field;
18970
      iprot.readStructBegin();
18971
      while (true)
18972
      {
18973
        field = iprot.readFieldBegin();
18974
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18975
          break;
18976
        }
18977
        switch (field.id) {
18978
          case 1: // ITEM_ID
18979
            if (field.type == org.apache.thrift.protocol.TType.I64) {
18980
              this.itemId = iprot.readI64();
18981
              setItemIdIsSet(true);
18982
            } else { 
18983
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18984
            }
18985
            break;
18986
          default:
18987
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18988
        }
18989
        iprot.readFieldEnd();
18990
      }
18991
      iprot.readStructEnd();
18992
      validate();
18993
    }
18994
 
18995
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18996
      validate();
18997
 
18998
      oprot.writeStructBegin(STRUCT_DESC);
18999
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
19000
      oprot.writeI64(this.itemId);
19001
      oprot.writeFieldEnd();
19002
      oprot.writeFieldStop();
19003
      oprot.writeStructEnd();
19004
    }
19005
 
19006
    @Override
19007
    public String toString() {
19008
      StringBuilder sb = new StringBuilder("getVendorItemMappings_args(");
19009
      boolean first = true;
19010
 
19011
      sb.append("itemId:");
19012
      sb.append(this.itemId);
19013
      first = false;
19014
      sb.append(")");
19015
      return sb.toString();
19016
    }
19017
 
19018
    public void validate() throws org.apache.thrift.TException {
19019
      // check for required fields
19020
    }
19021
 
19022
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19023
      try {
19024
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19025
      } catch (org.apache.thrift.TException te) {
19026
        throw new java.io.IOException(te);
19027
      }
19028
    }
19029
 
19030
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19031
      try {
19032
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19033
      } catch (org.apache.thrift.TException te) {
19034
        throw new java.io.IOException(te);
19035
      }
19036
    }
19037
 
19038
  }
19039
 
19040
  public static class getVendorItemMappings_result implements org.apache.thrift.TBase<getVendorItemMappings_result, getVendorItemMappings_result._Fields>, java.io.Serializable, Cloneable   {
19041
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendorItemMappings_result");
19042
 
19043
    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);
19044
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
19045
 
19046
    private List<VendorItemMapping> success; // required
19047
    private InventoryServiceException cex; // required
19048
 
19049
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19050
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19051
      SUCCESS((short)0, "success"),
19052
      CEX((short)1, "cex");
19053
 
19054
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19055
 
19056
      static {
19057
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19058
          byName.put(field.getFieldName(), field);
19059
        }
19060
      }
19061
 
19062
      /**
19063
       * Find the _Fields constant that matches fieldId, or null if its not found.
19064
       */
19065
      public static _Fields findByThriftId(int fieldId) {
19066
        switch(fieldId) {
19067
          case 0: // SUCCESS
19068
            return SUCCESS;
19069
          case 1: // CEX
19070
            return CEX;
19071
          default:
19072
            return null;
19073
        }
19074
      }
19075
 
19076
      /**
19077
       * Find the _Fields constant that matches fieldId, throwing an exception
19078
       * if it is not found.
19079
       */
19080
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19081
        _Fields fields = findByThriftId(fieldId);
19082
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19083
        return fields;
19084
      }
19085
 
19086
      /**
19087
       * Find the _Fields constant that matches name, or null if its not found.
19088
       */
19089
      public static _Fields findByName(String name) {
19090
        return byName.get(name);
19091
      }
19092
 
19093
      private final short _thriftId;
19094
      private final String _fieldName;
19095
 
19096
      _Fields(short thriftId, String fieldName) {
19097
        _thriftId = thriftId;
19098
        _fieldName = fieldName;
19099
      }
19100
 
19101
      public short getThriftFieldId() {
19102
        return _thriftId;
19103
      }
19104
 
19105
      public String getFieldName() {
19106
        return _fieldName;
19107
      }
19108
    }
19109
 
19110
    // isset id assignments
19111
 
19112
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19113
    static {
19114
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19115
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19116
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
19117
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class))));
19118
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19119
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
19120
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19121
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendorItemMappings_result.class, metaDataMap);
19122
    }
19123
 
19124
    public getVendorItemMappings_result() {
19125
    }
19126
 
19127
    public getVendorItemMappings_result(
19128
      List<VendorItemMapping> success,
19129
      InventoryServiceException cex)
19130
    {
19131
      this();
19132
      this.success = success;
19133
      this.cex = cex;
19134
    }
19135
 
19136
    /**
19137
     * Performs a deep copy on <i>other</i>.
19138
     */
19139
    public getVendorItemMappings_result(getVendorItemMappings_result other) {
19140
      if (other.isSetSuccess()) {
19141
        List<VendorItemMapping> __this__success = new ArrayList<VendorItemMapping>();
19142
        for (VendorItemMapping other_element : other.success) {
19143
          __this__success.add(new VendorItemMapping(other_element));
19144
        }
19145
        this.success = __this__success;
19146
      }
19147
      if (other.isSetCex()) {
19148
        this.cex = new InventoryServiceException(other.cex);
19149
      }
19150
    }
19151
 
19152
    public getVendorItemMappings_result deepCopy() {
19153
      return new getVendorItemMappings_result(this);
19154
    }
19155
 
19156
    @Override
19157
    public void clear() {
19158
      this.success = null;
19159
      this.cex = null;
19160
    }
19161
 
19162
    public int getSuccessSize() {
19163
      return (this.success == null) ? 0 : this.success.size();
19164
    }
19165
 
19166
    public java.util.Iterator<VendorItemMapping> getSuccessIterator() {
19167
      return (this.success == null) ? null : this.success.iterator();
19168
    }
19169
 
19170
    public void addToSuccess(VendorItemMapping elem) {
19171
      if (this.success == null) {
19172
        this.success = new ArrayList<VendorItemMapping>();
19173
      }
19174
      this.success.add(elem);
19175
    }
19176
 
19177
    public List<VendorItemMapping> getSuccess() {
19178
      return this.success;
19179
    }
19180
 
19181
    public void setSuccess(List<VendorItemMapping> success) {
19182
      this.success = success;
19183
    }
19184
 
19185
    public void unsetSuccess() {
19186
      this.success = null;
19187
    }
19188
 
19189
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
19190
    public boolean isSetSuccess() {
19191
      return this.success != null;
19192
    }
19193
 
19194
    public void setSuccessIsSet(boolean value) {
19195
      if (!value) {
19196
        this.success = null;
19197
      }
19198
    }
19199
 
19200
    public InventoryServiceException getCex() {
19201
      return this.cex;
19202
    }
19203
 
19204
    public void setCex(InventoryServiceException cex) {
19205
      this.cex = cex;
19206
    }
19207
 
19208
    public void unsetCex() {
19209
      this.cex = null;
19210
    }
19211
 
19212
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
19213
    public boolean isSetCex() {
19214
      return this.cex != null;
19215
    }
19216
 
19217
    public void setCexIsSet(boolean value) {
19218
      if (!value) {
19219
        this.cex = null;
19220
      }
19221
    }
19222
 
19223
    public void setFieldValue(_Fields field, Object value) {
19224
      switch (field) {
19225
      case SUCCESS:
19226
        if (value == null) {
19227
          unsetSuccess();
19228
        } else {
19229
          setSuccess((List<VendorItemMapping>)value);
19230
        }
19231
        break;
19232
 
19233
      case CEX:
19234
        if (value == null) {
19235
          unsetCex();
19236
        } else {
19237
          setCex((InventoryServiceException)value);
19238
        }
19239
        break;
19240
 
19241
      }
19242
    }
19243
 
19244
    public Object getFieldValue(_Fields field) {
19245
      switch (field) {
19246
      case SUCCESS:
19247
        return getSuccess();
19248
 
19249
      case CEX:
19250
        return getCex();
19251
 
19252
      }
19253
      throw new IllegalStateException();
19254
    }
19255
 
19256
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19257
    public boolean isSet(_Fields field) {
19258
      if (field == null) {
19259
        throw new IllegalArgumentException();
19260
      }
19261
 
19262
      switch (field) {
19263
      case SUCCESS:
19264
        return isSetSuccess();
19265
      case CEX:
19266
        return isSetCex();
19267
      }
19268
      throw new IllegalStateException();
19269
    }
19270
 
19271
    @Override
19272
    public boolean equals(Object that) {
19273
      if (that == null)
19274
        return false;
19275
      if (that instanceof getVendorItemMappings_result)
19276
        return this.equals((getVendorItemMappings_result)that);
19277
      return false;
19278
    }
19279
 
19280
    public boolean equals(getVendorItemMappings_result that) {
19281
      if (that == null)
19282
        return false;
19283
 
19284
      boolean this_present_success = true && this.isSetSuccess();
19285
      boolean that_present_success = true && that.isSetSuccess();
19286
      if (this_present_success || that_present_success) {
19287
        if (!(this_present_success && that_present_success))
19288
          return false;
19289
        if (!this.success.equals(that.success))
19290
          return false;
19291
      }
19292
 
19293
      boolean this_present_cex = true && this.isSetCex();
19294
      boolean that_present_cex = true && that.isSetCex();
19295
      if (this_present_cex || that_present_cex) {
19296
        if (!(this_present_cex && that_present_cex))
19297
          return false;
19298
        if (!this.cex.equals(that.cex))
19299
          return false;
19300
      }
19301
 
19302
      return true;
19303
    }
19304
 
19305
    @Override
19306
    public int hashCode() {
19307
      return 0;
19308
    }
19309
 
19310
    public int compareTo(getVendorItemMappings_result other) {
19311
      if (!getClass().equals(other.getClass())) {
19312
        return getClass().getName().compareTo(other.getClass().getName());
19313
      }
19314
 
19315
      int lastComparison = 0;
19316
      getVendorItemMappings_result typedOther = (getVendorItemMappings_result)other;
19317
 
19318
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
19319
      if (lastComparison != 0) {
19320
        return lastComparison;
19321
      }
19322
      if (isSetSuccess()) {
19323
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
19324
        if (lastComparison != 0) {
19325
          return lastComparison;
19326
        }
19327
      }
19328
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
19329
      if (lastComparison != 0) {
19330
        return lastComparison;
19331
      }
19332
      if (isSetCex()) {
19333
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
19334
        if (lastComparison != 0) {
19335
          return lastComparison;
19336
        }
19337
      }
19338
      return 0;
19339
    }
19340
 
19341
    public _Fields fieldForId(int fieldId) {
19342
      return _Fields.findByThriftId(fieldId);
19343
    }
19344
 
19345
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19346
      org.apache.thrift.protocol.TField field;
19347
      iprot.readStructBegin();
19348
      while (true)
19349
      {
19350
        field = iprot.readFieldBegin();
19351
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19352
          break;
19353
        }
19354
        switch (field.id) {
19355
          case 0: // SUCCESS
19356
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
19357
              {
19358
                org.apache.thrift.protocol.TList _list40 = iprot.readListBegin();
19359
                this.success = new ArrayList<VendorItemMapping>(_list40.size);
19360
                for (int _i41 = 0; _i41 < _list40.size; ++_i41)
19361
                {
19362
                  VendorItemMapping _elem42; // required
19363
                  _elem42 = new VendorItemMapping();
19364
                  _elem42.read(iprot);
19365
                  this.success.add(_elem42);
19366
                }
19367
                iprot.readListEnd();
19368
              }
19369
            } else { 
19370
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19371
            }
19372
            break;
19373
          case 1: // CEX
19374
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
19375
              this.cex = new InventoryServiceException();
19376
              this.cex.read(iprot);
19377
            } else { 
19378
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19379
            }
19380
            break;
19381
          default:
19382
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19383
        }
19384
        iprot.readFieldEnd();
19385
      }
19386
      iprot.readStructEnd();
19387
      validate();
19388
    }
19389
 
19390
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19391
      oprot.writeStructBegin(STRUCT_DESC);
19392
 
19393
      if (this.isSetSuccess()) {
19394
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
19395
        {
19396
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
19397
          for (VendorItemMapping _iter43 : this.success)
19398
          {
19399
            _iter43.write(oprot);
19400
          }
19401
          oprot.writeListEnd();
19402
        }
19403
        oprot.writeFieldEnd();
19404
      } else if (this.isSetCex()) {
19405
        oprot.writeFieldBegin(CEX_FIELD_DESC);
19406
        this.cex.write(oprot);
19407
        oprot.writeFieldEnd();
19408
      }
19409
      oprot.writeFieldStop();
19410
      oprot.writeStructEnd();
19411
    }
19412
 
19413
    @Override
19414
    public String toString() {
19415
      StringBuilder sb = new StringBuilder("getVendorItemMappings_result(");
19416
      boolean first = true;
19417
 
19418
      sb.append("success:");
19419
      if (this.success == null) {
19420
        sb.append("null");
19421
      } else {
19422
        sb.append(this.success);
19423
      }
19424
      first = false;
19425
      if (!first) sb.append(", ");
19426
      sb.append("cex:");
19427
      if (this.cex == null) {
19428
        sb.append("null");
19429
      } else {
19430
        sb.append(this.cex);
19431
      }
19432
      first = false;
19433
      sb.append(")");
19434
      return sb.toString();
19435
    }
19436
 
19437
    public void validate() throws org.apache.thrift.TException {
19438
      // check for required fields
19439
    }
19440
 
19441
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19442
      try {
19443
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19444
      } catch (org.apache.thrift.TException te) {
19445
        throw new java.io.IOException(te);
19446
      }
19447
    }
19448
 
19449
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19450
      try {
19451
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19452
      } catch (org.apache.thrift.TException te) {
19453
        throw new java.io.IOException(te);
19454
      }
19455
    }
19456
 
19457
  }
19458
 
19459
  public static class getPendingOrdersInventory_args implements org.apache.thrift.TBase<getPendingOrdersInventory_args, getPendingOrdersInventory_args._Fields>, java.io.Serializable, Cloneable   {
19460
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPendingOrdersInventory_args");
19461
 
19462
    private static final org.apache.thrift.protocol.TField VENDORID_FIELD_DESC = new org.apache.thrift.protocol.TField("vendorid", org.apache.thrift.protocol.TType.I64, (short)1);
19463
 
19464
    private long vendorid; // required
19465
 
19466
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19467
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19468
      VENDORID((short)1, "vendorid");
19469
 
19470
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19471
 
19472
      static {
19473
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19474
          byName.put(field.getFieldName(), field);
19475
        }
19476
      }
19477
 
19478
      /**
19479
       * Find the _Fields constant that matches fieldId, or null if its not found.
19480
       */
19481
      public static _Fields findByThriftId(int fieldId) {
19482
        switch(fieldId) {
19483
          case 1: // VENDORID
19484
            return VENDORID;
19485
          default:
19486
            return null;
19487
        }
19488
      }
19489
 
19490
      /**
19491
       * Find the _Fields constant that matches fieldId, throwing an exception
19492
       * if it is not found.
19493
       */
19494
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19495
        _Fields fields = findByThriftId(fieldId);
19496
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19497
        return fields;
19498
      }
19499
 
19500
      /**
19501
       * Find the _Fields constant that matches name, or null if its not found.
19502
       */
19503
      public static _Fields findByName(String name) {
19504
        return byName.get(name);
19505
      }
19506
 
19507
      private final short _thriftId;
19508
      private final String _fieldName;
19509
 
19510
      _Fields(short thriftId, String fieldName) {
19511
        _thriftId = thriftId;
19512
        _fieldName = fieldName;
19513
      }
19514
 
19515
      public short getThriftFieldId() {
19516
        return _thriftId;
19517
      }
19518
 
19519
      public String getFieldName() {
19520
        return _fieldName;
19521
      }
19522
    }
19523
 
19524
    // isset id assignments
19525
    private static final int __VENDORID_ISSET_ID = 0;
19526
    private BitSet __isset_bit_vector = new BitSet(1);
19527
 
19528
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19529
    static {
19530
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19531
      tmpMap.put(_Fields.VENDORID, new org.apache.thrift.meta_data.FieldMetaData("vendorid", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19532
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
19533
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19534
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPendingOrdersInventory_args.class, metaDataMap);
19535
    }
19536
 
19537
    public getPendingOrdersInventory_args() {
19538
    }
19539
 
19540
    public getPendingOrdersInventory_args(
19541
      long vendorid)
19542
    {
19543
      this();
19544
      this.vendorid = vendorid;
19545
      setVendoridIsSet(true);
19546
    }
19547
 
19548
    /**
19549
     * Performs a deep copy on <i>other</i>.
19550
     */
19551
    public getPendingOrdersInventory_args(getPendingOrdersInventory_args other) {
19552
      __isset_bit_vector.clear();
19553
      __isset_bit_vector.or(other.__isset_bit_vector);
19554
      this.vendorid = other.vendorid;
19555
    }
19556
 
19557
    public getPendingOrdersInventory_args deepCopy() {
19558
      return new getPendingOrdersInventory_args(this);
19559
    }
19560
 
19561
    @Override
19562
    public void clear() {
19563
      setVendoridIsSet(false);
19564
      this.vendorid = 0;
19565
    }
19566
 
19567
    public long getVendorid() {
19568
      return this.vendorid;
19569
    }
19570
 
19571
    public void setVendorid(long vendorid) {
19572
      this.vendorid = vendorid;
19573
      setVendoridIsSet(true);
19574
    }
19575
 
19576
    public void unsetVendorid() {
19577
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
19578
    }
19579
 
19580
    /** Returns true if field vendorid is set (has been assigned a value) and false otherwise */
19581
    public boolean isSetVendorid() {
19582
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
19583
    }
19584
 
19585
    public void setVendoridIsSet(boolean value) {
19586
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
19587
    }
19588
 
19589
    public void setFieldValue(_Fields field, Object value) {
19590
      switch (field) {
19591
      case VENDORID:
19592
        if (value == null) {
19593
          unsetVendorid();
19594
        } else {
19595
          setVendorid((Long)value);
19596
        }
19597
        break;
19598
 
19599
      }
19600
    }
19601
 
19602
    public Object getFieldValue(_Fields field) {
19603
      switch (field) {
19604
      case VENDORID:
19605
        return Long.valueOf(getVendorid());
19606
 
19607
      }
19608
      throw new IllegalStateException();
19609
    }
19610
 
19611
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19612
    public boolean isSet(_Fields field) {
19613
      if (field == null) {
19614
        throw new IllegalArgumentException();
19615
      }
19616
 
19617
      switch (field) {
19618
      case VENDORID:
19619
        return isSetVendorid();
19620
      }
19621
      throw new IllegalStateException();
19622
    }
19623
 
19624
    @Override
19625
    public boolean equals(Object that) {
19626
      if (that == null)
19627
        return false;
19628
      if (that instanceof getPendingOrdersInventory_args)
19629
        return this.equals((getPendingOrdersInventory_args)that);
19630
      return false;
19631
    }
19632
 
19633
    public boolean equals(getPendingOrdersInventory_args that) {
19634
      if (that == null)
19635
        return false;
19636
 
19637
      boolean this_present_vendorid = true;
19638
      boolean that_present_vendorid = true;
19639
      if (this_present_vendorid || that_present_vendorid) {
19640
        if (!(this_present_vendorid && that_present_vendorid))
19641
          return false;
19642
        if (this.vendorid != that.vendorid)
19643
          return false;
19644
      }
19645
 
19646
      return true;
19647
    }
19648
 
19649
    @Override
19650
    public int hashCode() {
19651
      return 0;
19652
    }
19653
 
19654
    public int compareTo(getPendingOrdersInventory_args other) {
19655
      if (!getClass().equals(other.getClass())) {
19656
        return getClass().getName().compareTo(other.getClass().getName());
19657
      }
19658
 
19659
      int lastComparison = 0;
19660
      getPendingOrdersInventory_args typedOther = (getPendingOrdersInventory_args)other;
19661
 
19662
      lastComparison = Boolean.valueOf(isSetVendorid()).compareTo(typedOther.isSetVendorid());
19663
      if (lastComparison != 0) {
19664
        return lastComparison;
19665
      }
19666
      if (isSetVendorid()) {
19667
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorid, typedOther.vendorid);
19668
        if (lastComparison != 0) {
19669
          return lastComparison;
19670
        }
19671
      }
19672
      return 0;
19673
    }
19674
 
19675
    public _Fields fieldForId(int fieldId) {
19676
      return _Fields.findByThriftId(fieldId);
19677
    }
19678
 
19679
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19680
      org.apache.thrift.protocol.TField field;
19681
      iprot.readStructBegin();
19682
      while (true)
19683
      {
19684
        field = iprot.readFieldBegin();
19685
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19686
          break;
19687
        }
19688
        switch (field.id) {
19689
          case 1: // VENDORID
19690
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19691
              this.vendorid = iprot.readI64();
19692
              setVendoridIsSet(true);
19693
            } else { 
19694
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19695
            }
19696
            break;
19697
          default:
19698
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19699
        }
19700
        iprot.readFieldEnd();
19701
      }
19702
      iprot.readStructEnd();
19703
      validate();
19704
    }
19705
 
19706
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19707
      validate();
19708
 
19709
      oprot.writeStructBegin(STRUCT_DESC);
19710
      oprot.writeFieldBegin(VENDORID_FIELD_DESC);
19711
      oprot.writeI64(this.vendorid);
19712
      oprot.writeFieldEnd();
19713
      oprot.writeFieldStop();
19714
      oprot.writeStructEnd();
19715
    }
19716
 
19717
    @Override
19718
    public String toString() {
19719
      StringBuilder sb = new StringBuilder("getPendingOrdersInventory_args(");
19720
      boolean first = true;
19721
 
19722
      sb.append("vendorid:");
19723
      sb.append(this.vendorid);
19724
      first = false;
19725
      sb.append(")");
19726
      return sb.toString();
19727
    }
19728
 
19729
    public void validate() throws org.apache.thrift.TException {
19730
      // check for required fields
19731
    }
19732
 
19733
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19734
      try {
19735
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19736
      } catch (org.apache.thrift.TException te) {
19737
        throw new java.io.IOException(te);
19738
      }
19739
    }
19740
 
19741
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19742
      try {
19743
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
19744
        __isset_bit_vector = new BitSet(1);
19745
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19746
      } catch (org.apache.thrift.TException te) {
19747
        throw new java.io.IOException(te);
19748
      }
19749
    }
19750
 
19751
  }
19752
 
19753
  public static class getPendingOrdersInventory_result implements org.apache.thrift.TBase<getPendingOrdersInventory_result, getPendingOrdersInventory_result._Fields>, java.io.Serializable, Cloneable   {
19754
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPendingOrdersInventory_result");
19755
 
19756
    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);
19757
 
19758
    private List<AvailableAndReservedStock> success; // required
19759
 
19760
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19761
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19762
      SUCCESS((short)0, "success");
19763
 
19764
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19765
 
19766
      static {
19767
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19768
          byName.put(field.getFieldName(), field);
19769
        }
19770
      }
19771
 
19772
      /**
19773
       * Find the _Fields constant that matches fieldId, or null if its not found.
19774
       */
19775
      public static _Fields findByThriftId(int fieldId) {
19776
        switch(fieldId) {
19777
          case 0: // SUCCESS
19778
            return SUCCESS;
19779
          default:
19780
            return null;
19781
        }
19782
      }
19783
 
19784
      /**
19785
       * Find the _Fields constant that matches fieldId, throwing an exception
19786
       * if it is not found.
19787
       */
19788
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19789
        _Fields fields = findByThriftId(fieldId);
19790
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19791
        return fields;
19792
      }
19793
 
19794
      /**
19795
       * Find the _Fields constant that matches name, or null if its not found.
19796
       */
19797
      public static _Fields findByName(String name) {
19798
        return byName.get(name);
19799
      }
19800
 
19801
      private final short _thriftId;
19802
      private final String _fieldName;
19803
 
19804
      _Fields(short thriftId, String fieldName) {
19805
        _thriftId = thriftId;
19806
        _fieldName = fieldName;
19807
      }
19808
 
19809
      public short getThriftFieldId() {
19810
        return _thriftId;
19811
      }
19812
 
19813
      public String getFieldName() {
19814
        return _fieldName;
19815
      }
19816
    }
19817
 
19818
    // isset id assignments
19819
 
19820
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19821
    static {
19822
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19823
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19824
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
19825
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, AvailableAndReservedStock.class))));
19826
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19827
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPendingOrdersInventory_result.class, metaDataMap);
19828
    }
19829
 
19830
    public getPendingOrdersInventory_result() {
19831
    }
19832
 
19833
    public getPendingOrdersInventory_result(
19834
      List<AvailableAndReservedStock> success)
19835
    {
19836
      this();
19837
      this.success = success;
19838
    }
19839
 
19840
    /**
19841
     * Performs a deep copy on <i>other</i>.
19842
     */
19843
    public getPendingOrdersInventory_result(getPendingOrdersInventory_result other) {
19844
      if (other.isSetSuccess()) {
19845
        List<AvailableAndReservedStock> __this__success = new ArrayList<AvailableAndReservedStock>();
19846
        for (AvailableAndReservedStock other_element : other.success) {
19847
          __this__success.add(new AvailableAndReservedStock(other_element));
19848
        }
19849
        this.success = __this__success;
19850
      }
19851
    }
19852
 
19853
    public getPendingOrdersInventory_result deepCopy() {
19854
      return new getPendingOrdersInventory_result(this);
19855
    }
19856
 
19857
    @Override
19858
    public void clear() {
19859
      this.success = null;
19860
    }
19861
 
19862
    public int getSuccessSize() {
19863
      return (this.success == null) ? 0 : this.success.size();
19864
    }
19865
 
19866
    public java.util.Iterator<AvailableAndReservedStock> getSuccessIterator() {
19867
      return (this.success == null) ? null : this.success.iterator();
19868
    }
19869
 
19870
    public void addToSuccess(AvailableAndReservedStock elem) {
19871
      if (this.success == null) {
19872
        this.success = new ArrayList<AvailableAndReservedStock>();
19873
      }
19874
      this.success.add(elem);
19875
    }
19876
 
19877
    public List<AvailableAndReservedStock> getSuccess() {
19878
      return this.success;
19879
    }
19880
 
19881
    public void setSuccess(List<AvailableAndReservedStock> success) {
19882
      this.success = success;
19883
    }
19884
 
19885
    public void unsetSuccess() {
19886
      this.success = null;
19887
    }
19888
 
19889
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
19890
    public boolean isSetSuccess() {
19891
      return this.success != null;
19892
    }
19893
 
19894
    public void setSuccessIsSet(boolean value) {
19895
      if (!value) {
19896
        this.success = null;
19897
      }
19898
    }
19899
 
19900
    public void setFieldValue(_Fields field, Object value) {
19901
      switch (field) {
19902
      case SUCCESS:
19903
        if (value == null) {
19904
          unsetSuccess();
19905
        } else {
19906
          setSuccess((List<AvailableAndReservedStock>)value);
19907
        }
19908
        break;
19909
 
19910
      }
19911
    }
19912
 
19913
    public Object getFieldValue(_Fields field) {
19914
      switch (field) {
19915
      case SUCCESS:
19916
        return getSuccess();
19917
 
19918
      }
19919
      throw new IllegalStateException();
19920
    }
19921
 
19922
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19923
    public boolean isSet(_Fields field) {
19924
      if (field == null) {
19925
        throw new IllegalArgumentException();
19926
      }
19927
 
19928
      switch (field) {
19929
      case SUCCESS:
19930
        return isSetSuccess();
19931
      }
19932
      throw new IllegalStateException();
19933
    }
19934
 
19935
    @Override
19936
    public boolean equals(Object that) {
19937
      if (that == null)
19938
        return false;
19939
      if (that instanceof getPendingOrdersInventory_result)
19940
        return this.equals((getPendingOrdersInventory_result)that);
19941
      return false;
19942
    }
19943
 
19944
    public boolean equals(getPendingOrdersInventory_result that) {
19945
      if (that == null)
19946
        return false;
19947
 
19948
      boolean this_present_success = true && this.isSetSuccess();
19949
      boolean that_present_success = true && that.isSetSuccess();
19950
      if (this_present_success || that_present_success) {
19951
        if (!(this_present_success && that_present_success))
19952
          return false;
19953
        if (!this.success.equals(that.success))
19954
          return false;
19955
      }
19956
 
19957
      return true;
19958
    }
19959
 
19960
    @Override
19961
    public int hashCode() {
19962
      return 0;
19963
    }
19964
 
19965
    public int compareTo(getPendingOrdersInventory_result other) {
19966
      if (!getClass().equals(other.getClass())) {
19967
        return getClass().getName().compareTo(other.getClass().getName());
19968
      }
19969
 
19970
      int lastComparison = 0;
19971
      getPendingOrdersInventory_result typedOther = (getPendingOrdersInventory_result)other;
19972
 
19973
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
19974
      if (lastComparison != 0) {
19975
        return lastComparison;
19976
      }
19977
      if (isSetSuccess()) {
19978
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
19979
        if (lastComparison != 0) {
19980
          return lastComparison;
19981
        }
19982
      }
19983
      return 0;
19984
    }
19985
 
19986
    public _Fields fieldForId(int fieldId) {
19987
      return _Fields.findByThriftId(fieldId);
19988
    }
19989
 
19990
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19991
      org.apache.thrift.protocol.TField field;
19992
      iprot.readStructBegin();
19993
      while (true)
19994
      {
19995
        field = iprot.readFieldBegin();
19996
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19997
          break;
19998
        }
19999
        switch (field.id) {
20000
          case 0: // SUCCESS
20001
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
20002
              {
20003
                org.apache.thrift.protocol.TList _list44 = iprot.readListBegin();
20004
                this.success = new ArrayList<AvailableAndReservedStock>(_list44.size);
20005
                for (int _i45 = 0; _i45 < _list44.size; ++_i45)
20006
                {
20007
                  AvailableAndReservedStock _elem46; // required
20008
                  _elem46 = new AvailableAndReservedStock();
20009
                  _elem46.read(iprot);
20010
                  this.success.add(_elem46);
20011
                }
20012
                iprot.readListEnd();
20013
              }
20014
            } else { 
20015
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20016
            }
20017
            break;
20018
          default:
20019
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20020
        }
20021
        iprot.readFieldEnd();
20022
      }
20023
      iprot.readStructEnd();
20024
      validate();
20025
    }
20026
 
20027
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20028
      oprot.writeStructBegin(STRUCT_DESC);
20029
 
20030
      if (this.isSetSuccess()) {
20031
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
20032
        {
20033
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
20034
          for (AvailableAndReservedStock _iter47 : this.success)
20035
          {
20036
            _iter47.write(oprot);
20037
          }
20038
          oprot.writeListEnd();
20039
        }
20040
        oprot.writeFieldEnd();
20041
      }
20042
      oprot.writeFieldStop();
20043
      oprot.writeStructEnd();
20044
    }
20045
 
20046
    @Override
20047
    public String toString() {
20048
      StringBuilder sb = new StringBuilder("getPendingOrdersInventory_result(");
20049
      boolean first = true;
20050
 
20051
      sb.append("success:");
20052
      if (this.success == null) {
20053
        sb.append("null");
20054
      } else {
20055
        sb.append(this.success);
20056
      }
20057
      first = false;
20058
      sb.append(")");
20059
      return sb.toString();
20060
    }
20061
 
20062
    public void validate() throws org.apache.thrift.TException {
20063
      // check for required fields
20064
    }
20065
 
20066
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20067
      try {
20068
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20069
      } catch (org.apache.thrift.TException te) {
20070
        throw new java.io.IOException(te);
20071
      }
20072
    }
20073
 
20074
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20075
      try {
20076
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20077
      } catch (org.apache.thrift.TException te) {
20078
        throw new java.io.IOException(te);
20079
      }
20080
    }
20081
 
20082
  }
20083
 
20084
  public static class getWarehouses_args implements org.apache.thrift.TBase<getWarehouses_args, getWarehouses_args._Fields>, java.io.Serializable, Cloneable   {
20085
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouses_args");
20086
 
20087
    private static final org.apache.thrift.protocol.TField WAREHOUSE_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouseType", org.apache.thrift.protocol.TType.I32, (short)1);
20088
    private static final org.apache.thrift.protocol.TField INVENTORY_TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("inventoryType", org.apache.thrift.protocol.TType.I32, (short)2);
20089
    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)3);
20090
    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);
20091
    private static final org.apache.thrift.protocol.TField SHIPPING_WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("shippingWarehouseId", org.apache.thrift.protocol.TType.I64, (short)5);
20092
 
20093
    private WarehouseType warehouseType; // required
20094
    private InventoryType inventoryType; // required
20095
    private long vendorId; // required
20096
    private long billingWarehouseId; // required
20097
    private long shippingWarehouseId; // required
20098
 
20099
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20100
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20101
      /**
20102
       * 
20103
       * @see WarehouseType
20104
       */
20105
      WAREHOUSE_TYPE((short)1, "warehouseType"),
20106
      /**
20107
       * 
20108
       * @see InventoryType
20109
       */
20110
      INVENTORY_TYPE((short)2, "inventoryType"),
20111
      VENDOR_ID((short)3, "vendorId"),
20112
      BILLING_WAREHOUSE_ID((short)4, "billingWarehouseId"),
20113
      SHIPPING_WAREHOUSE_ID((short)5, "shippingWarehouseId");
20114
 
20115
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20116
 
20117
      static {
20118
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20119
          byName.put(field.getFieldName(), field);
20120
        }
20121
      }
20122
 
20123
      /**
20124
       * Find the _Fields constant that matches fieldId, or null if its not found.
20125
       */
20126
      public static _Fields findByThriftId(int fieldId) {
20127
        switch(fieldId) {
20128
          case 1: // WAREHOUSE_TYPE
20129
            return WAREHOUSE_TYPE;
20130
          case 2: // INVENTORY_TYPE
20131
            return INVENTORY_TYPE;
20132
          case 3: // VENDOR_ID
20133
            return VENDOR_ID;
20134
          case 4: // BILLING_WAREHOUSE_ID
20135
            return BILLING_WAREHOUSE_ID;
20136
          case 5: // SHIPPING_WAREHOUSE_ID
20137
            return SHIPPING_WAREHOUSE_ID;
20138
          default:
20139
            return null;
20140
        }
20141
      }
20142
 
20143
      /**
20144
       * Find the _Fields constant that matches fieldId, throwing an exception
20145
       * if it is not found.
20146
       */
20147
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20148
        _Fields fields = findByThriftId(fieldId);
20149
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20150
        return fields;
20151
      }
20152
 
20153
      /**
20154
       * Find the _Fields constant that matches name, or null if its not found.
20155
       */
20156
      public static _Fields findByName(String name) {
20157
        return byName.get(name);
20158
      }
20159
 
20160
      private final short _thriftId;
20161
      private final String _fieldName;
20162
 
20163
      _Fields(short thriftId, String fieldName) {
20164
        _thriftId = thriftId;
20165
        _fieldName = fieldName;
20166
      }
20167
 
20168
      public short getThriftFieldId() {
20169
        return _thriftId;
20170
      }
20171
 
20172
      public String getFieldName() {
20173
        return _fieldName;
20174
      }
20175
    }
20176
 
20177
    // isset id assignments
20178
    private static final int __VENDORID_ISSET_ID = 0;
20179
    private static final int __BILLINGWAREHOUSEID_ISSET_ID = 1;
20180
    private static final int __SHIPPINGWAREHOUSEID_ISSET_ID = 2;
20181
    private BitSet __isset_bit_vector = new BitSet(3);
20182
 
20183
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20184
    static {
20185
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20186
      tmpMap.put(_Fields.WAREHOUSE_TYPE, new org.apache.thrift.meta_data.FieldMetaData("warehouseType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20187
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, WarehouseType.class)));
20188
      tmpMap.put(_Fields.INVENTORY_TYPE, new org.apache.thrift.meta_data.FieldMetaData("inventoryType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20189
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, InventoryType.class)));
20190
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20191
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20192
      tmpMap.put(_Fields.BILLING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("billingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20193
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20194
      tmpMap.put(_Fields.SHIPPING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("shippingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20195
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20196
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20197
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouses_args.class, metaDataMap);
20198
    }
20199
 
20200
    public getWarehouses_args() {
20201
    }
20202
 
20203
    public getWarehouses_args(
20204
      WarehouseType warehouseType,
20205
      InventoryType inventoryType,
20206
      long vendorId,
20207
      long billingWarehouseId,
20208
      long shippingWarehouseId)
20209
    {
20210
      this();
20211
      this.warehouseType = warehouseType;
20212
      this.inventoryType = inventoryType;
20213
      this.vendorId = vendorId;
20214
      setVendorIdIsSet(true);
20215
      this.billingWarehouseId = billingWarehouseId;
20216
      setBillingWarehouseIdIsSet(true);
20217
      this.shippingWarehouseId = shippingWarehouseId;
20218
      setShippingWarehouseIdIsSet(true);
20219
    }
20220
 
20221
    /**
20222
     * Performs a deep copy on <i>other</i>.
20223
     */
20224
    public getWarehouses_args(getWarehouses_args other) {
20225
      __isset_bit_vector.clear();
20226
      __isset_bit_vector.or(other.__isset_bit_vector);
20227
      if (other.isSetWarehouseType()) {
20228
        this.warehouseType = other.warehouseType;
20229
      }
20230
      if (other.isSetInventoryType()) {
20231
        this.inventoryType = other.inventoryType;
20232
      }
20233
      this.vendorId = other.vendorId;
20234
      this.billingWarehouseId = other.billingWarehouseId;
20235
      this.shippingWarehouseId = other.shippingWarehouseId;
20236
    }
20237
 
20238
    public getWarehouses_args deepCopy() {
20239
      return new getWarehouses_args(this);
20240
    }
20241
 
20242
    @Override
20243
    public void clear() {
20244
      this.warehouseType = null;
20245
      this.inventoryType = null;
20246
      setVendorIdIsSet(false);
20247
      this.vendorId = 0;
20248
      setBillingWarehouseIdIsSet(false);
20249
      this.billingWarehouseId = 0;
20250
      setShippingWarehouseIdIsSet(false);
20251
      this.shippingWarehouseId = 0;
20252
    }
20253
 
20254
    /**
20255
     * 
20256
     * @see WarehouseType
20257
     */
20258
    public WarehouseType getWarehouseType() {
20259
      return this.warehouseType;
20260
    }
20261
 
20262
    /**
20263
     * 
20264
     * @see WarehouseType
20265
     */
20266
    public void setWarehouseType(WarehouseType warehouseType) {
20267
      this.warehouseType = warehouseType;
20268
    }
20269
 
20270
    public void unsetWarehouseType() {
20271
      this.warehouseType = null;
20272
    }
20273
 
20274
    /** Returns true if field warehouseType is set (has been assigned a value) and false otherwise */
20275
    public boolean isSetWarehouseType() {
20276
      return this.warehouseType != null;
20277
    }
20278
 
20279
    public void setWarehouseTypeIsSet(boolean value) {
20280
      if (!value) {
20281
        this.warehouseType = null;
20282
      }
20283
    }
20284
 
20285
    /**
20286
     * 
20287
     * @see InventoryType
20288
     */
20289
    public InventoryType getInventoryType() {
20290
      return this.inventoryType;
20291
    }
20292
 
20293
    /**
20294
     * 
20295
     * @see InventoryType
20296
     */
20297
    public void setInventoryType(InventoryType inventoryType) {
20298
      this.inventoryType = inventoryType;
20299
    }
20300
 
20301
    public void unsetInventoryType() {
20302
      this.inventoryType = null;
20303
    }
20304
 
20305
    /** Returns true if field inventoryType is set (has been assigned a value) and false otherwise */
20306
    public boolean isSetInventoryType() {
20307
      return this.inventoryType != null;
20308
    }
20309
 
20310
    public void setInventoryTypeIsSet(boolean value) {
20311
      if (!value) {
20312
        this.inventoryType = null;
20313
      }
20314
    }
20315
 
20316
    public long getVendorId() {
20317
      return this.vendorId;
20318
    }
20319
 
20320
    public void setVendorId(long vendorId) {
20321
      this.vendorId = vendorId;
20322
      setVendorIdIsSet(true);
20323
    }
20324
 
20325
    public void unsetVendorId() {
20326
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
20327
    }
20328
 
20329
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
20330
    public boolean isSetVendorId() {
20331
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
20332
    }
20333
 
20334
    public void setVendorIdIsSet(boolean value) {
20335
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
20336
    }
20337
 
20338
    public long getBillingWarehouseId() {
20339
      return this.billingWarehouseId;
20340
    }
20341
 
20342
    public void setBillingWarehouseId(long billingWarehouseId) {
20343
      this.billingWarehouseId = billingWarehouseId;
20344
      setBillingWarehouseIdIsSet(true);
20345
    }
20346
 
20347
    public void unsetBillingWarehouseId() {
20348
      __isset_bit_vector.clear(__BILLINGWAREHOUSEID_ISSET_ID);
20349
    }
20350
 
20351
    /** Returns true if field billingWarehouseId is set (has been assigned a value) and false otherwise */
20352
    public boolean isSetBillingWarehouseId() {
20353
      return __isset_bit_vector.get(__BILLINGWAREHOUSEID_ISSET_ID);
20354
    }
20355
 
20356
    public void setBillingWarehouseIdIsSet(boolean value) {
20357
      __isset_bit_vector.set(__BILLINGWAREHOUSEID_ISSET_ID, value);
20358
    }
20359
 
20360
    public long getShippingWarehouseId() {
20361
      return this.shippingWarehouseId;
20362
    }
20363
 
20364
    public void setShippingWarehouseId(long shippingWarehouseId) {
20365
      this.shippingWarehouseId = shippingWarehouseId;
20366
      setShippingWarehouseIdIsSet(true);
20367
    }
20368
 
20369
    public void unsetShippingWarehouseId() {
20370
      __isset_bit_vector.clear(__SHIPPINGWAREHOUSEID_ISSET_ID);
20371
    }
20372
 
20373
    /** Returns true if field shippingWarehouseId is set (has been assigned a value) and false otherwise */
20374
    public boolean isSetShippingWarehouseId() {
20375
      return __isset_bit_vector.get(__SHIPPINGWAREHOUSEID_ISSET_ID);
20376
    }
20377
 
20378
    public void setShippingWarehouseIdIsSet(boolean value) {
20379
      __isset_bit_vector.set(__SHIPPINGWAREHOUSEID_ISSET_ID, value);
20380
    }
20381
 
20382
    public void setFieldValue(_Fields field, Object value) {
20383
      switch (field) {
20384
      case WAREHOUSE_TYPE:
20385
        if (value == null) {
20386
          unsetWarehouseType();
20387
        } else {
20388
          setWarehouseType((WarehouseType)value);
20389
        }
20390
        break;
20391
 
20392
      case INVENTORY_TYPE:
20393
        if (value == null) {
20394
          unsetInventoryType();
20395
        } else {
20396
          setInventoryType((InventoryType)value);
20397
        }
20398
        break;
20399
 
20400
      case VENDOR_ID:
20401
        if (value == null) {
20402
          unsetVendorId();
20403
        } else {
20404
          setVendorId((Long)value);
20405
        }
20406
        break;
20407
 
20408
      case BILLING_WAREHOUSE_ID:
20409
        if (value == null) {
20410
          unsetBillingWarehouseId();
20411
        } else {
20412
          setBillingWarehouseId((Long)value);
20413
        }
20414
        break;
20415
 
20416
      case SHIPPING_WAREHOUSE_ID:
20417
        if (value == null) {
20418
          unsetShippingWarehouseId();
20419
        } else {
20420
          setShippingWarehouseId((Long)value);
20421
        }
20422
        break;
20423
 
20424
      }
20425
    }
20426
 
20427
    public Object getFieldValue(_Fields field) {
20428
      switch (field) {
20429
      case WAREHOUSE_TYPE:
20430
        return getWarehouseType();
20431
 
20432
      case INVENTORY_TYPE:
20433
        return getInventoryType();
20434
 
20435
      case VENDOR_ID:
20436
        return Long.valueOf(getVendorId());
20437
 
20438
      case BILLING_WAREHOUSE_ID:
20439
        return Long.valueOf(getBillingWarehouseId());
20440
 
20441
      case SHIPPING_WAREHOUSE_ID:
20442
        return Long.valueOf(getShippingWarehouseId());
20443
 
20444
      }
20445
      throw new IllegalStateException();
20446
    }
20447
 
20448
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20449
    public boolean isSet(_Fields field) {
20450
      if (field == null) {
20451
        throw new IllegalArgumentException();
20452
      }
20453
 
20454
      switch (field) {
20455
      case WAREHOUSE_TYPE:
20456
        return isSetWarehouseType();
20457
      case INVENTORY_TYPE:
20458
        return isSetInventoryType();
20459
      case VENDOR_ID:
20460
        return isSetVendorId();
20461
      case BILLING_WAREHOUSE_ID:
20462
        return isSetBillingWarehouseId();
20463
      case SHIPPING_WAREHOUSE_ID:
20464
        return isSetShippingWarehouseId();
20465
      }
20466
      throw new IllegalStateException();
20467
    }
20468
 
20469
    @Override
20470
    public boolean equals(Object that) {
20471
      if (that == null)
20472
        return false;
20473
      if (that instanceof getWarehouses_args)
20474
        return this.equals((getWarehouses_args)that);
20475
      return false;
20476
    }
20477
 
20478
    public boolean equals(getWarehouses_args that) {
20479
      if (that == null)
20480
        return false;
20481
 
20482
      boolean this_present_warehouseType = true && this.isSetWarehouseType();
20483
      boolean that_present_warehouseType = true && that.isSetWarehouseType();
20484
      if (this_present_warehouseType || that_present_warehouseType) {
20485
        if (!(this_present_warehouseType && that_present_warehouseType))
20486
          return false;
20487
        if (!this.warehouseType.equals(that.warehouseType))
20488
          return false;
20489
      }
20490
 
20491
      boolean this_present_inventoryType = true && this.isSetInventoryType();
20492
      boolean that_present_inventoryType = true && that.isSetInventoryType();
20493
      if (this_present_inventoryType || that_present_inventoryType) {
20494
        if (!(this_present_inventoryType && that_present_inventoryType))
20495
          return false;
20496
        if (!this.inventoryType.equals(that.inventoryType))
20497
          return false;
20498
      }
20499
 
20500
      boolean this_present_vendorId = true;
20501
      boolean that_present_vendorId = true;
20502
      if (this_present_vendorId || that_present_vendorId) {
20503
        if (!(this_present_vendorId && that_present_vendorId))
20504
          return false;
20505
        if (this.vendorId != that.vendorId)
20506
          return false;
20507
      }
20508
 
20509
      boolean this_present_billingWarehouseId = true;
20510
      boolean that_present_billingWarehouseId = true;
20511
      if (this_present_billingWarehouseId || that_present_billingWarehouseId) {
20512
        if (!(this_present_billingWarehouseId && that_present_billingWarehouseId))
20513
          return false;
20514
        if (this.billingWarehouseId != that.billingWarehouseId)
20515
          return false;
20516
      }
20517
 
20518
      boolean this_present_shippingWarehouseId = true;
20519
      boolean that_present_shippingWarehouseId = true;
20520
      if (this_present_shippingWarehouseId || that_present_shippingWarehouseId) {
20521
        if (!(this_present_shippingWarehouseId && that_present_shippingWarehouseId))
20522
          return false;
20523
        if (this.shippingWarehouseId != that.shippingWarehouseId)
20524
          return false;
20525
      }
20526
 
20527
      return true;
20528
    }
20529
 
20530
    @Override
20531
    public int hashCode() {
20532
      return 0;
20533
    }
20534
 
20535
    public int compareTo(getWarehouses_args other) {
20536
      if (!getClass().equals(other.getClass())) {
20537
        return getClass().getName().compareTo(other.getClass().getName());
20538
      }
20539
 
20540
      int lastComparison = 0;
20541
      getWarehouses_args typedOther = (getWarehouses_args)other;
20542
 
20543
      lastComparison = Boolean.valueOf(isSetWarehouseType()).compareTo(typedOther.isSetWarehouseType());
20544
      if (lastComparison != 0) {
20545
        return lastComparison;
20546
      }
20547
      if (isSetWarehouseType()) {
20548
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseType, typedOther.warehouseType);
20549
        if (lastComparison != 0) {
20550
          return lastComparison;
20551
        }
20552
      }
20553
      lastComparison = Boolean.valueOf(isSetInventoryType()).compareTo(typedOther.isSetInventoryType());
20554
      if (lastComparison != 0) {
20555
        return lastComparison;
20556
      }
20557
      if (isSetInventoryType()) {
20558
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.inventoryType, typedOther.inventoryType);
20559
        if (lastComparison != 0) {
20560
          return lastComparison;
20561
        }
20562
      }
20563
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
20564
      if (lastComparison != 0) {
20565
        return lastComparison;
20566
      }
20567
      if (isSetVendorId()) {
20568
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
20569
        if (lastComparison != 0) {
20570
          return lastComparison;
20571
        }
20572
      }
20573
      lastComparison = Boolean.valueOf(isSetBillingWarehouseId()).compareTo(typedOther.isSetBillingWarehouseId());
20574
      if (lastComparison != 0) {
20575
        return lastComparison;
20576
      }
20577
      if (isSetBillingWarehouseId()) {
20578
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.billingWarehouseId, typedOther.billingWarehouseId);
20579
        if (lastComparison != 0) {
20580
          return lastComparison;
20581
        }
20582
      }
20583
      lastComparison = Boolean.valueOf(isSetShippingWarehouseId()).compareTo(typedOther.isSetShippingWarehouseId());
20584
      if (lastComparison != 0) {
20585
        return lastComparison;
20586
      }
20587
      if (isSetShippingWarehouseId()) {
20588
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.shippingWarehouseId, typedOther.shippingWarehouseId);
20589
        if (lastComparison != 0) {
20590
          return lastComparison;
20591
        }
20592
      }
20593
      return 0;
20594
    }
20595
 
20596
    public _Fields fieldForId(int fieldId) {
20597
      return _Fields.findByThriftId(fieldId);
20598
    }
20599
 
20600
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20601
      org.apache.thrift.protocol.TField field;
20602
      iprot.readStructBegin();
20603
      while (true)
20604
      {
20605
        field = iprot.readFieldBegin();
20606
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20607
          break;
20608
        }
20609
        switch (field.id) {
20610
          case 1: // WAREHOUSE_TYPE
20611
            if (field.type == org.apache.thrift.protocol.TType.I32) {
20612
              this.warehouseType = WarehouseType.findByValue(iprot.readI32());
20613
            } else { 
20614
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20615
            }
20616
            break;
20617
          case 2: // INVENTORY_TYPE
20618
            if (field.type == org.apache.thrift.protocol.TType.I32) {
20619
              this.inventoryType = InventoryType.findByValue(iprot.readI32());
20620
            } else { 
20621
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20622
            }
20623
            break;
20624
          case 3: // VENDOR_ID
20625
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20626
              this.vendorId = iprot.readI64();
20627
              setVendorIdIsSet(true);
20628
            } else { 
20629
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20630
            }
20631
            break;
20632
          case 4: // BILLING_WAREHOUSE_ID
20633
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20634
              this.billingWarehouseId = iprot.readI64();
20635
              setBillingWarehouseIdIsSet(true);
20636
            } else { 
20637
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20638
            }
20639
            break;
20640
          case 5: // SHIPPING_WAREHOUSE_ID
20641
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20642
              this.shippingWarehouseId = iprot.readI64();
20643
              setShippingWarehouseIdIsSet(true);
20644
            } else { 
20645
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20646
            }
20647
            break;
20648
          default:
20649
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20650
        }
20651
        iprot.readFieldEnd();
20652
      }
20653
      iprot.readStructEnd();
20654
      validate();
20655
    }
20656
 
20657
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20658
      validate();
20659
 
20660
      oprot.writeStructBegin(STRUCT_DESC);
20661
      if (this.warehouseType != null) {
20662
        oprot.writeFieldBegin(WAREHOUSE_TYPE_FIELD_DESC);
20663
        oprot.writeI32(this.warehouseType.getValue());
20664
        oprot.writeFieldEnd();
20665
      }
20666
      if (this.inventoryType != null) {
20667
        oprot.writeFieldBegin(INVENTORY_TYPE_FIELD_DESC);
20668
        oprot.writeI32(this.inventoryType.getValue());
20669
        oprot.writeFieldEnd();
20670
      }
20671
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
20672
      oprot.writeI64(this.vendorId);
20673
      oprot.writeFieldEnd();
20674
      oprot.writeFieldBegin(BILLING_WAREHOUSE_ID_FIELD_DESC);
20675
      oprot.writeI64(this.billingWarehouseId);
20676
      oprot.writeFieldEnd();
20677
      oprot.writeFieldBegin(SHIPPING_WAREHOUSE_ID_FIELD_DESC);
20678
      oprot.writeI64(this.shippingWarehouseId);
20679
      oprot.writeFieldEnd();
20680
      oprot.writeFieldStop();
20681
      oprot.writeStructEnd();
20682
    }
20683
 
20684
    @Override
20685
    public String toString() {
20686
      StringBuilder sb = new StringBuilder("getWarehouses_args(");
20687
      boolean first = true;
20688
 
20689
      sb.append("warehouseType:");
20690
      if (this.warehouseType == null) {
20691
        sb.append("null");
20692
      } else {
20693
        sb.append(this.warehouseType);
20694
      }
20695
      first = false;
20696
      if (!first) sb.append(", ");
20697
      sb.append("inventoryType:");
20698
      if (this.inventoryType == null) {
20699
        sb.append("null");
20700
      } else {
20701
        sb.append(this.inventoryType);
20702
      }
20703
      first = false;
20704
      if (!first) sb.append(", ");
20705
      sb.append("vendorId:");
20706
      sb.append(this.vendorId);
20707
      first = false;
20708
      if (!first) sb.append(", ");
20709
      sb.append("billingWarehouseId:");
20710
      sb.append(this.billingWarehouseId);
20711
      first = false;
20712
      if (!first) sb.append(", ");
20713
      sb.append("shippingWarehouseId:");
20714
      sb.append(this.shippingWarehouseId);
20715
      first = false;
20716
      sb.append(")");
20717
      return sb.toString();
20718
    }
20719
 
20720
    public void validate() throws org.apache.thrift.TException {
20721
      // check for required fields
20722
    }
20723
 
20724
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20725
      try {
20726
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20727
      } catch (org.apache.thrift.TException te) {
20728
        throw new java.io.IOException(te);
20729
      }
20730
    }
20731
 
20732
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20733
      try {
20734
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20735
      } catch (org.apache.thrift.TException te) {
20736
        throw new java.io.IOException(te);
20737
      }
20738
    }
20739
 
20740
  }
20741
 
20742
  public static class getWarehouses_result implements org.apache.thrift.TBase<getWarehouses_result, getWarehouses_result._Fields>, java.io.Serializable, Cloneable   {
20743
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouses_result");
20744
 
20745
    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);
20746
 
20747
    private List<Warehouse> success; // required
20748
 
20749
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20750
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20751
      SUCCESS((short)0, "success");
20752
 
20753
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20754
 
20755
      static {
20756
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20757
          byName.put(field.getFieldName(), field);
20758
        }
20759
      }
20760
 
20761
      /**
20762
       * Find the _Fields constant that matches fieldId, or null if its not found.
20763
       */
20764
      public static _Fields findByThriftId(int fieldId) {
20765
        switch(fieldId) {
20766
          case 0: // SUCCESS
20767
            return SUCCESS;
20768
          default:
20769
            return null;
20770
        }
20771
      }
20772
 
20773
      /**
20774
       * Find the _Fields constant that matches fieldId, throwing an exception
20775
       * if it is not found.
20776
       */
20777
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20778
        _Fields fields = findByThriftId(fieldId);
20779
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20780
        return fields;
20781
      }
20782
 
20783
      /**
20784
       * Find the _Fields constant that matches name, or null if its not found.
20785
       */
20786
      public static _Fields findByName(String name) {
20787
        return byName.get(name);
20788
      }
20789
 
20790
      private final short _thriftId;
20791
      private final String _fieldName;
20792
 
20793
      _Fields(short thriftId, String fieldName) {
20794
        _thriftId = thriftId;
20795
        _fieldName = fieldName;
20796
      }
20797
 
20798
      public short getThriftFieldId() {
20799
        return _thriftId;
20800
      }
20801
 
20802
      public String getFieldName() {
20803
        return _fieldName;
20804
      }
20805
    }
20806
 
20807
    // isset id assignments
20808
 
20809
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20810
    static {
20811
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20812
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20813
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
20814
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
20815
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20816
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouses_result.class, metaDataMap);
20817
    }
20818
 
20819
    public getWarehouses_result() {
20820
    }
20821
 
20822
    public getWarehouses_result(
20823
      List<Warehouse> success)
20824
    {
20825
      this();
20826
      this.success = success;
20827
    }
20828
 
20829
    /**
20830
     * Performs a deep copy on <i>other</i>.
20831
     */
20832
    public getWarehouses_result(getWarehouses_result other) {
20833
      if (other.isSetSuccess()) {
20834
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
20835
        for (Warehouse other_element : other.success) {
20836
          __this__success.add(new Warehouse(other_element));
20837
        }
20838
        this.success = __this__success;
20839
      }
20840
    }
20841
 
20842
    public getWarehouses_result deepCopy() {
20843
      return new getWarehouses_result(this);
20844
    }
20845
 
20846
    @Override
20847
    public void clear() {
20848
      this.success = null;
20849
    }
20850
 
20851
    public int getSuccessSize() {
20852
      return (this.success == null) ? 0 : this.success.size();
20853
    }
20854
 
20855
    public java.util.Iterator<Warehouse> getSuccessIterator() {
20856
      return (this.success == null) ? null : this.success.iterator();
20857
    }
20858
 
20859
    public void addToSuccess(Warehouse elem) {
20860
      if (this.success == null) {
20861
        this.success = new ArrayList<Warehouse>();
20862
      }
20863
      this.success.add(elem);
20864
    }
20865
 
20866
    public List<Warehouse> getSuccess() {
20867
      return this.success;
20868
    }
20869
 
20870
    public void setSuccess(List<Warehouse> success) {
20871
      this.success = success;
20872
    }
20873
 
20874
    public void unsetSuccess() {
20875
      this.success = null;
20876
    }
20877
 
20878
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
20879
    public boolean isSetSuccess() {
20880
      return this.success != null;
20881
    }
20882
 
20883
    public void setSuccessIsSet(boolean value) {
20884
      if (!value) {
20885
        this.success = null;
20886
      }
20887
    }
20888
 
20889
    public void setFieldValue(_Fields field, Object value) {
20890
      switch (field) {
20891
      case SUCCESS:
20892
        if (value == null) {
20893
          unsetSuccess();
20894
        } else {
20895
          setSuccess((List<Warehouse>)value);
20896
        }
20897
        break;
20898
 
20899
      }
20900
    }
20901
 
20902
    public Object getFieldValue(_Fields field) {
20903
      switch (field) {
20904
      case SUCCESS:
20905
        return getSuccess();
20906
 
20907
      }
20908
      throw new IllegalStateException();
20909
    }
20910
 
20911
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20912
    public boolean isSet(_Fields field) {
20913
      if (field == null) {
20914
        throw new IllegalArgumentException();
20915
      }
20916
 
20917
      switch (field) {
20918
      case SUCCESS:
20919
        return isSetSuccess();
20920
      }
20921
      throw new IllegalStateException();
20922
    }
20923
 
20924
    @Override
20925
    public boolean equals(Object that) {
20926
      if (that == null)
20927
        return false;
20928
      if (that instanceof getWarehouses_result)
20929
        return this.equals((getWarehouses_result)that);
20930
      return false;
20931
    }
20932
 
20933
    public boolean equals(getWarehouses_result that) {
20934
      if (that == null)
20935
        return false;
20936
 
20937
      boolean this_present_success = true && this.isSetSuccess();
20938
      boolean that_present_success = true && that.isSetSuccess();
20939
      if (this_present_success || that_present_success) {
20940
        if (!(this_present_success && that_present_success))
20941
          return false;
20942
        if (!this.success.equals(that.success))
20943
          return false;
20944
      }
20945
 
20946
      return true;
20947
    }
20948
 
20949
    @Override
20950
    public int hashCode() {
20951
      return 0;
20952
    }
20953
 
20954
    public int compareTo(getWarehouses_result other) {
20955
      if (!getClass().equals(other.getClass())) {
20956
        return getClass().getName().compareTo(other.getClass().getName());
20957
      }
20958
 
20959
      int lastComparison = 0;
20960
      getWarehouses_result typedOther = (getWarehouses_result)other;
20961
 
20962
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
20963
      if (lastComparison != 0) {
20964
        return lastComparison;
20965
      }
20966
      if (isSetSuccess()) {
20967
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
20968
        if (lastComparison != 0) {
20969
          return lastComparison;
20970
        }
20971
      }
20972
      return 0;
20973
    }
20974
 
20975
    public _Fields fieldForId(int fieldId) {
20976
      return _Fields.findByThriftId(fieldId);
20977
    }
20978
 
20979
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20980
      org.apache.thrift.protocol.TField field;
20981
      iprot.readStructBegin();
20982
      while (true)
20983
      {
20984
        field = iprot.readFieldBegin();
20985
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20986
          break;
20987
        }
20988
        switch (field.id) {
20989
          case 0: // SUCCESS
20990
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
20991
              {
20992
                org.apache.thrift.protocol.TList _list48 = iprot.readListBegin();
20993
                this.success = new ArrayList<Warehouse>(_list48.size);
20994
                for (int _i49 = 0; _i49 < _list48.size; ++_i49)
20995
                {
20996
                  Warehouse _elem50; // required
20997
                  _elem50 = new Warehouse();
20998
                  _elem50.read(iprot);
20999
                  this.success.add(_elem50);
21000
                }
21001
                iprot.readListEnd();
21002
              }
21003
            } else { 
21004
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21005
            }
21006
            break;
21007
          default:
21008
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21009
        }
21010
        iprot.readFieldEnd();
21011
      }
21012
      iprot.readStructEnd();
21013
      validate();
21014
    }
21015
 
21016
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21017
      oprot.writeStructBegin(STRUCT_DESC);
21018
 
21019
      if (this.isSetSuccess()) {
21020
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
21021
        {
21022
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
21023
          for (Warehouse _iter51 : this.success)
21024
          {
21025
            _iter51.write(oprot);
21026
          }
21027
          oprot.writeListEnd();
21028
        }
21029
        oprot.writeFieldEnd();
21030
      }
21031
      oprot.writeFieldStop();
21032
      oprot.writeStructEnd();
21033
    }
21034
 
21035
    @Override
21036
    public String toString() {
21037
      StringBuilder sb = new StringBuilder("getWarehouses_result(");
21038
      boolean first = true;
21039
 
21040
      sb.append("success:");
21041
      if (this.success == null) {
21042
        sb.append("null");
21043
      } else {
21044
        sb.append(this.success);
21045
      }
21046
      first = false;
21047
      sb.append(")");
21048
      return sb.toString();
21049
    }
21050
 
21051
    public void validate() throws org.apache.thrift.TException {
21052
      // check for required fields
21053
    }
21054
 
21055
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21056
      try {
21057
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21058
      } catch (org.apache.thrift.TException te) {
21059
        throw new java.io.IOException(te);
21060
      }
21061
    }
21062
 
21063
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21064
      try {
21065
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21066
      } catch (org.apache.thrift.TException te) {
21067
        throw new java.io.IOException(te);
21068
      }
21069
    }
21070
 
21071
  }
21072
 
21073
  public static class resetAvailability_args implements org.apache.thrift.TBase<resetAvailability_args, resetAvailability_args._Fields>, java.io.Serializable, Cloneable   {
21074
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailability_args");
21075
 
21076
    private static final org.apache.thrift.protocol.TField ITEM_KEY_FIELD_DESC = new org.apache.thrift.protocol.TField("itemKey", org.apache.thrift.protocol.TType.STRING, (short)1);
21077
    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);
21078
    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);
21079
    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)4);
21080
 
21081
    private String itemKey; // required
21082
    private long vendorId; // required
21083
    private long quantity; // required
21084
    private long warehouseId; // required
21085
 
21086
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21087
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21088
      ITEM_KEY((short)1, "itemKey"),
21089
      VENDOR_ID((short)2, "vendorId"),
21090
      QUANTITY((short)3, "quantity"),
21091
      WAREHOUSE_ID((short)4, "warehouseId");
21092
 
21093
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21094
 
21095
      static {
21096
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21097
          byName.put(field.getFieldName(), field);
21098
        }
21099
      }
21100
 
21101
      /**
21102
       * Find the _Fields constant that matches fieldId, or null if its not found.
21103
       */
21104
      public static _Fields findByThriftId(int fieldId) {
21105
        switch(fieldId) {
21106
          case 1: // ITEM_KEY
21107
            return ITEM_KEY;
21108
          case 2: // VENDOR_ID
21109
            return VENDOR_ID;
21110
          case 3: // QUANTITY
21111
            return QUANTITY;
21112
          case 4: // WAREHOUSE_ID
21113
            return WAREHOUSE_ID;
21114
          default:
21115
            return null;
21116
        }
21117
      }
21118
 
21119
      /**
21120
       * Find the _Fields constant that matches fieldId, throwing an exception
21121
       * if it is not found.
21122
       */
21123
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21124
        _Fields fields = findByThriftId(fieldId);
21125
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21126
        return fields;
21127
      }
21128
 
21129
      /**
21130
       * Find the _Fields constant that matches name, or null if its not found.
21131
       */
21132
      public static _Fields findByName(String name) {
21133
        return byName.get(name);
21134
      }
21135
 
21136
      private final short _thriftId;
21137
      private final String _fieldName;
21138
 
21139
      _Fields(short thriftId, String fieldName) {
21140
        _thriftId = thriftId;
21141
        _fieldName = fieldName;
21142
      }
21143
 
21144
      public short getThriftFieldId() {
21145
        return _thriftId;
21146
      }
21147
 
21148
      public String getFieldName() {
21149
        return _fieldName;
21150
      }
21151
    }
21152
 
21153
    // isset id assignments
21154
    private static final int __VENDORID_ISSET_ID = 0;
21155
    private static final int __QUANTITY_ISSET_ID = 1;
21156
    private static final int __WAREHOUSEID_ISSET_ID = 2;
21157
    private BitSet __isset_bit_vector = new BitSet(3);
21158
 
21159
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21160
    static {
21161
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21162
      tmpMap.put(_Fields.ITEM_KEY, new org.apache.thrift.meta_data.FieldMetaData("itemKey", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21163
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
21164
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21165
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21166
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21167
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21168
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21169
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21170
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21171
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailability_args.class, metaDataMap);
21172
    }
21173
 
21174
    public resetAvailability_args() {
21175
    }
21176
 
21177
    public resetAvailability_args(
21178
      String itemKey,
21179
      long vendorId,
21180
      long quantity,
21181
      long warehouseId)
21182
    {
21183
      this();
21184
      this.itemKey = itemKey;
21185
      this.vendorId = vendorId;
21186
      setVendorIdIsSet(true);
21187
      this.quantity = quantity;
21188
      setQuantityIsSet(true);
21189
      this.warehouseId = warehouseId;
21190
      setWarehouseIdIsSet(true);
21191
    }
21192
 
21193
    /**
21194
     * Performs a deep copy on <i>other</i>.
21195
     */
21196
    public resetAvailability_args(resetAvailability_args other) {
21197
      __isset_bit_vector.clear();
21198
      __isset_bit_vector.or(other.__isset_bit_vector);
21199
      if (other.isSetItemKey()) {
21200
        this.itemKey = other.itemKey;
21201
      }
21202
      this.vendorId = other.vendorId;
21203
      this.quantity = other.quantity;
21204
      this.warehouseId = other.warehouseId;
21205
    }
21206
 
21207
    public resetAvailability_args deepCopy() {
21208
      return new resetAvailability_args(this);
21209
    }
21210
 
21211
    @Override
21212
    public void clear() {
21213
      this.itemKey = null;
21214
      setVendorIdIsSet(false);
21215
      this.vendorId = 0;
21216
      setQuantityIsSet(false);
21217
      this.quantity = 0;
21218
      setWarehouseIdIsSet(false);
21219
      this.warehouseId = 0;
21220
    }
21221
 
21222
    public String getItemKey() {
21223
      return this.itemKey;
21224
    }
21225
 
21226
    public void setItemKey(String itemKey) {
21227
      this.itemKey = itemKey;
21228
    }
21229
 
21230
    public void unsetItemKey() {
21231
      this.itemKey = null;
21232
    }
21233
 
21234
    /** Returns true if field itemKey is set (has been assigned a value) and false otherwise */
21235
    public boolean isSetItemKey() {
21236
      return this.itemKey != null;
21237
    }
21238
 
21239
    public void setItemKeyIsSet(boolean value) {
21240
      if (!value) {
21241
        this.itemKey = null;
21242
      }
21243
    }
21244
 
21245
    public long getVendorId() {
21246
      return this.vendorId;
21247
    }
21248
 
21249
    public void setVendorId(long vendorId) {
21250
      this.vendorId = vendorId;
21251
      setVendorIdIsSet(true);
21252
    }
21253
 
21254
    public void unsetVendorId() {
21255
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
21256
    }
21257
 
21258
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
21259
    public boolean isSetVendorId() {
21260
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
21261
    }
21262
 
21263
    public void setVendorIdIsSet(boolean value) {
21264
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
21265
    }
21266
 
21267
    public long getQuantity() {
21268
      return this.quantity;
21269
    }
21270
 
21271
    public void setQuantity(long quantity) {
21272
      this.quantity = quantity;
21273
      setQuantityIsSet(true);
21274
    }
21275
 
21276
    public void unsetQuantity() {
21277
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
21278
    }
21279
 
21280
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
21281
    public boolean isSetQuantity() {
21282
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
21283
    }
21284
 
21285
    public void setQuantityIsSet(boolean value) {
21286
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
21287
    }
21288
 
21289
    public long getWarehouseId() {
21290
      return this.warehouseId;
21291
    }
21292
 
21293
    public void setWarehouseId(long warehouseId) {
21294
      this.warehouseId = warehouseId;
21295
      setWarehouseIdIsSet(true);
21296
    }
21297
 
21298
    public void unsetWarehouseId() {
21299
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
21300
    }
21301
 
21302
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
21303
    public boolean isSetWarehouseId() {
21304
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
21305
    }
21306
 
21307
    public void setWarehouseIdIsSet(boolean value) {
21308
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
21309
    }
21310
 
21311
    public void setFieldValue(_Fields field, Object value) {
21312
      switch (field) {
21313
      case ITEM_KEY:
21314
        if (value == null) {
21315
          unsetItemKey();
21316
        } else {
21317
          setItemKey((String)value);
21318
        }
21319
        break;
21320
 
21321
      case VENDOR_ID:
21322
        if (value == null) {
21323
          unsetVendorId();
21324
        } else {
21325
          setVendorId((Long)value);
21326
        }
21327
        break;
21328
 
21329
      case QUANTITY:
21330
        if (value == null) {
21331
          unsetQuantity();
21332
        } else {
21333
          setQuantity((Long)value);
21334
        }
21335
        break;
21336
 
21337
      case WAREHOUSE_ID:
21338
        if (value == null) {
21339
          unsetWarehouseId();
21340
        } else {
21341
          setWarehouseId((Long)value);
21342
        }
21343
        break;
21344
 
21345
      }
21346
    }
21347
 
21348
    public Object getFieldValue(_Fields field) {
21349
      switch (field) {
21350
      case ITEM_KEY:
21351
        return getItemKey();
21352
 
21353
      case VENDOR_ID:
21354
        return Long.valueOf(getVendorId());
21355
 
21356
      case QUANTITY:
21357
        return Long.valueOf(getQuantity());
21358
 
21359
      case WAREHOUSE_ID:
21360
        return Long.valueOf(getWarehouseId());
21361
 
21362
      }
21363
      throw new IllegalStateException();
21364
    }
21365
 
21366
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21367
    public boolean isSet(_Fields field) {
21368
      if (field == null) {
21369
        throw new IllegalArgumentException();
21370
      }
21371
 
21372
      switch (field) {
21373
      case ITEM_KEY:
21374
        return isSetItemKey();
21375
      case VENDOR_ID:
21376
        return isSetVendorId();
21377
      case QUANTITY:
21378
        return isSetQuantity();
21379
      case WAREHOUSE_ID:
21380
        return isSetWarehouseId();
21381
      }
21382
      throw new IllegalStateException();
21383
    }
21384
 
21385
    @Override
21386
    public boolean equals(Object that) {
21387
      if (that == null)
21388
        return false;
21389
      if (that instanceof resetAvailability_args)
21390
        return this.equals((resetAvailability_args)that);
21391
      return false;
21392
    }
21393
 
21394
    public boolean equals(resetAvailability_args that) {
21395
      if (that == null)
21396
        return false;
21397
 
21398
      boolean this_present_itemKey = true && this.isSetItemKey();
21399
      boolean that_present_itemKey = true && that.isSetItemKey();
21400
      if (this_present_itemKey || that_present_itemKey) {
21401
        if (!(this_present_itemKey && that_present_itemKey))
21402
          return false;
21403
        if (!this.itemKey.equals(that.itemKey))
21404
          return false;
21405
      }
21406
 
21407
      boolean this_present_vendorId = true;
21408
      boolean that_present_vendorId = true;
21409
      if (this_present_vendorId || that_present_vendorId) {
21410
        if (!(this_present_vendorId && that_present_vendorId))
21411
          return false;
21412
        if (this.vendorId != that.vendorId)
21413
          return false;
21414
      }
21415
 
21416
      boolean this_present_quantity = true;
21417
      boolean that_present_quantity = true;
21418
      if (this_present_quantity || that_present_quantity) {
21419
        if (!(this_present_quantity && that_present_quantity))
21420
          return false;
21421
        if (this.quantity != that.quantity)
21422
          return false;
21423
      }
21424
 
21425
      boolean this_present_warehouseId = true;
21426
      boolean that_present_warehouseId = true;
21427
      if (this_present_warehouseId || that_present_warehouseId) {
21428
        if (!(this_present_warehouseId && that_present_warehouseId))
21429
          return false;
21430
        if (this.warehouseId != that.warehouseId)
21431
          return false;
21432
      }
21433
 
21434
      return true;
21435
    }
21436
 
21437
    @Override
21438
    public int hashCode() {
21439
      return 0;
21440
    }
21441
 
21442
    public int compareTo(resetAvailability_args other) {
21443
      if (!getClass().equals(other.getClass())) {
21444
        return getClass().getName().compareTo(other.getClass().getName());
21445
      }
21446
 
21447
      int lastComparison = 0;
21448
      resetAvailability_args typedOther = (resetAvailability_args)other;
21449
 
21450
      lastComparison = Boolean.valueOf(isSetItemKey()).compareTo(typedOther.isSetItemKey());
21451
      if (lastComparison != 0) {
21452
        return lastComparison;
21453
      }
21454
      if (isSetItemKey()) {
21455
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemKey, typedOther.itemKey);
21456
        if (lastComparison != 0) {
21457
          return lastComparison;
21458
        }
21459
      }
21460
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
21461
      if (lastComparison != 0) {
21462
        return lastComparison;
21463
      }
21464
      if (isSetVendorId()) {
21465
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
21466
        if (lastComparison != 0) {
21467
          return lastComparison;
21468
        }
21469
      }
21470
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
21471
      if (lastComparison != 0) {
21472
        return lastComparison;
21473
      }
21474
      if (isSetQuantity()) {
21475
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
21476
        if (lastComparison != 0) {
21477
          return lastComparison;
21478
        }
21479
      }
21480
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
21481
      if (lastComparison != 0) {
21482
        return lastComparison;
21483
      }
21484
      if (isSetWarehouseId()) {
21485
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
21486
        if (lastComparison != 0) {
21487
          return lastComparison;
21488
        }
21489
      }
21490
      return 0;
21491
    }
21492
 
21493
    public _Fields fieldForId(int fieldId) {
21494
      return _Fields.findByThriftId(fieldId);
21495
    }
21496
 
21497
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21498
      org.apache.thrift.protocol.TField field;
21499
      iprot.readStructBegin();
21500
      while (true)
21501
      {
21502
        field = iprot.readFieldBegin();
21503
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21504
          break;
21505
        }
21506
        switch (field.id) {
21507
          case 1: // ITEM_KEY
21508
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
21509
              this.itemKey = iprot.readString();
21510
            } else { 
21511
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21512
            }
21513
            break;
21514
          case 2: // VENDOR_ID
21515
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21516
              this.vendorId = iprot.readI64();
21517
              setVendorIdIsSet(true);
21518
            } else { 
21519
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21520
            }
21521
            break;
21522
          case 3: // QUANTITY
21523
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21524
              this.quantity = iprot.readI64();
21525
              setQuantityIsSet(true);
21526
            } else { 
21527
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21528
            }
21529
            break;
21530
          case 4: // WAREHOUSE_ID
21531
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21532
              this.warehouseId = iprot.readI64();
21533
              setWarehouseIdIsSet(true);
21534
            } else { 
21535
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21536
            }
21537
            break;
21538
          default:
21539
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21540
        }
21541
        iprot.readFieldEnd();
21542
      }
21543
      iprot.readStructEnd();
21544
      validate();
21545
    }
21546
 
21547
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21548
      validate();
21549
 
21550
      oprot.writeStructBegin(STRUCT_DESC);
21551
      if (this.itemKey != null) {
21552
        oprot.writeFieldBegin(ITEM_KEY_FIELD_DESC);
21553
        oprot.writeString(this.itemKey);
21554
        oprot.writeFieldEnd();
21555
      }
21556
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
21557
      oprot.writeI64(this.vendorId);
21558
      oprot.writeFieldEnd();
21559
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
21560
      oprot.writeI64(this.quantity);
21561
      oprot.writeFieldEnd();
21562
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
21563
      oprot.writeI64(this.warehouseId);
21564
      oprot.writeFieldEnd();
21565
      oprot.writeFieldStop();
21566
      oprot.writeStructEnd();
21567
    }
21568
 
21569
    @Override
21570
    public String toString() {
21571
      StringBuilder sb = new StringBuilder("resetAvailability_args(");
21572
      boolean first = true;
21573
 
21574
      sb.append("itemKey:");
21575
      if (this.itemKey == null) {
21576
        sb.append("null");
21577
      } else {
21578
        sb.append(this.itemKey);
21579
      }
21580
      first = false;
21581
      if (!first) sb.append(", ");
21582
      sb.append("vendorId:");
21583
      sb.append(this.vendorId);
21584
      first = false;
21585
      if (!first) sb.append(", ");
21586
      sb.append("quantity:");
21587
      sb.append(this.quantity);
21588
      first = false;
21589
      if (!first) sb.append(", ");
21590
      sb.append("warehouseId:");
21591
      sb.append(this.warehouseId);
21592
      first = false;
21593
      sb.append(")");
21594
      return sb.toString();
21595
    }
21596
 
21597
    public void validate() throws org.apache.thrift.TException {
21598
      // check for required fields
21599
    }
21600
 
21601
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21602
      try {
21603
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21604
      } catch (org.apache.thrift.TException te) {
21605
        throw new java.io.IOException(te);
21606
      }
21607
    }
21608
 
21609
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21610
      try {
21611
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
21612
        __isset_bit_vector = new BitSet(1);
21613
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21614
      } catch (org.apache.thrift.TException te) {
21615
        throw new java.io.IOException(te);
21616
      }
21617
    }
21618
 
21619
  }
21620
 
21621
  public static class resetAvailability_result implements org.apache.thrift.TBase<resetAvailability_result, resetAvailability_result._Fields>, java.io.Serializable, Cloneable   {
21622
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailability_result");
21623
 
21624
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
21625
 
21626
    private InventoryServiceException cex; // required
21627
 
21628
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21629
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21630
      CEX((short)1, "cex");
21631
 
21632
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21633
 
21634
      static {
21635
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21636
          byName.put(field.getFieldName(), field);
21637
        }
21638
      }
21639
 
21640
      /**
21641
       * Find the _Fields constant that matches fieldId, or null if its not found.
21642
       */
21643
      public static _Fields findByThriftId(int fieldId) {
21644
        switch(fieldId) {
21645
          case 1: // CEX
21646
            return CEX;
21647
          default:
21648
            return null;
21649
        }
21650
      }
21651
 
21652
      /**
21653
       * Find the _Fields constant that matches fieldId, throwing an exception
21654
       * if it is not found.
21655
       */
21656
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21657
        _Fields fields = findByThriftId(fieldId);
21658
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21659
        return fields;
21660
      }
21661
 
21662
      /**
21663
       * Find the _Fields constant that matches name, or null if its not found.
21664
       */
21665
      public static _Fields findByName(String name) {
21666
        return byName.get(name);
21667
      }
21668
 
21669
      private final short _thriftId;
21670
      private final String _fieldName;
21671
 
21672
      _Fields(short thriftId, String fieldName) {
21673
        _thriftId = thriftId;
21674
        _fieldName = fieldName;
21675
      }
21676
 
21677
      public short getThriftFieldId() {
21678
        return _thriftId;
21679
      }
21680
 
21681
      public String getFieldName() {
21682
        return _fieldName;
21683
      }
21684
    }
21685
 
21686
    // isset id assignments
21687
 
21688
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21689
    static {
21690
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21691
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21692
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
21693
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21694
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailability_result.class, metaDataMap);
21695
    }
21696
 
21697
    public resetAvailability_result() {
21698
    }
21699
 
21700
    public resetAvailability_result(
21701
      InventoryServiceException cex)
21702
    {
21703
      this();
21704
      this.cex = cex;
21705
    }
21706
 
21707
    /**
21708
     * Performs a deep copy on <i>other</i>.
21709
     */
21710
    public resetAvailability_result(resetAvailability_result other) {
21711
      if (other.isSetCex()) {
21712
        this.cex = new InventoryServiceException(other.cex);
21713
      }
21714
    }
21715
 
21716
    public resetAvailability_result deepCopy() {
21717
      return new resetAvailability_result(this);
21718
    }
21719
 
21720
    @Override
21721
    public void clear() {
21722
      this.cex = null;
21723
    }
21724
 
21725
    public InventoryServiceException getCex() {
21726
      return this.cex;
21727
    }
21728
 
21729
    public void setCex(InventoryServiceException cex) {
21730
      this.cex = cex;
21731
    }
21732
 
21733
    public void unsetCex() {
21734
      this.cex = null;
21735
    }
21736
 
21737
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
21738
    public boolean isSetCex() {
21739
      return this.cex != null;
21740
    }
21741
 
21742
    public void setCexIsSet(boolean value) {
21743
      if (!value) {
21744
        this.cex = null;
21745
      }
21746
    }
21747
 
21748
    public void setFieldValue(_Fields field, Object value) {
21749
      switch (field) {
21750
      case CEX:
21751
        if (value == null) {
21752
          unsetCex();
21753
        } else {
21754
          setCex((InventoryServiceException)value);
21755
        }
21756
        break;
21757
 
21758
      }
21759
    }
21760
 
21761
    public Object getFieldValue(_Fields field) {
21762
      switch (field) {
21763
      case CEX:
21764
        return getCex();
21765
 
21766
      }
21767
      throw new IllegalStateException();
21768
    }
21769
 
21770
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21771
    public boolean isSet(_Fields field) {
21772
      if (field == null) {
21773
        throw new IllegalArgumentException();
21774
      }
21775
 
21776
      switch (field) {
21777
      case CEX:
21778
        return isSetCex();
21779
      }
21780
      throw new IllegalStateException();
21781
    }
21782
 
21783
    @Override
21784
    public boolean equals(Object that) {
21785
      if (that == null)
21786
        return false;
21787
      if (that instanceof resetAvailability_result)
21788
        return this.equals((resetAvailability_result)that);
21789
      return false;
21790
    }
21791
 
21792
    public boolean equals(resetAvailability_result that) {
21793
      if (that == null)
21794
        return false;
21795
 
21796
      boolean this_present_cex = true && this.isSetCex();
21797
      boolean that_present_cex = true && that.isSetCex();
21798
      if (this_present_cex || that_present_cex) {
21799
        if (!(this_present_cex && that_present_cex))
21800
          return false;
21801
        if (!this.cex.equals(that.cex))
21802
          return false;
21803
      }
21804
 
21805
      return true;
21806
    }
21807
 
21808
    @Override
21809
    public int hashCode() {
21810
      return 0;
21811
    }
21812
 
21813
    public int compareTo(resetAvailability_result other) {
21814
      if (!getClass().equals(other.getClass())) {
21815
        return getClass().getName().compareTo(other.getClass().getName());
21816
      }
21817
 
21818
      int lastComparison = 0;
21819
      resetAvailability_result typedOther = (resetAvailability_result)other;
21820
 
21821
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
21822
      if (lastComparison != 0) {
21823
        return lastComparison;
21824
      }
21825
      if (isSetCex()) {
21826
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
21827
        if (lastComparison != 0) {
21828
          return lastComparison;
21829
        }
21830
      }
21831
      return 0;
21832
    }
21833
 
21834
    public _Fields fieldForId(int fieldId) {
21835
      return _Fields.findByThriftId(fieldId);
21836
    }
21837
 
21838
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21839
      org.apache.thrift.protocol.TField field;
21840
      iprot.readStructBegin();
21841
      while (true)
21842
      {
21843
        field = iprot.readFieldBegin();
21844
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21845
          break;
21846
        }
21847
        switch (field.id) {
21848
          case 1: // CEX
21849
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
21850
              this.cex = new InventoryServiceException();
21851
              this.cex.read(iprot);
21852
            } else { 
21853
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21854
            }
21855
            break;
21856
          default:
21857
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21858
        }
21859
        iprot.readFieldEnd();
21860
      }
21861
      iprot.readStructEnd();
21862
      validate();
21863
    }
21864
 
21865
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21866
      oprot.writeStructBegin(STRUCT_DESC);
21867
 
21868
      if (this.isSetCex()) {
21869
        oprot.writeFieldBegin(CEX_FIELD_DESC);
21870
        this.cex.write(oprot);
21871
        oprot.writeFieldEnd();
21872
      }
21873
      oprot.writeFieldStop();
21874
      oprot.writeStructEnd();
21875
    }
21876
 
21877
    @Override
21878
    public String toString() {
21879
      StringBuilder sb = new StringBuilder("resetAvailability_result(");
21880
      boolean first = true;
21881
 
21882
      sb.append("cex:");
21883
      if (this.cex == null) {
21884
        sb.append("null");
21885
      } else {
21886
        sb.append(this.cex);
21887
      }
21888
      first = false;
21889
      sb.append(")");
21890
      return sb.toString();
21891
    }
21892
 
21893
    public void validate() throws org.apache.thrift.TException {
21894
      // check for required fields
21895
    }
21896
 
21897
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21898
      try {
21899
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21900
      } catch (org.apache.thrift.TException te) {
21901
        throw new java.io.IOException(te);
21902
      }
21903
    }
21904
 
21905
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21906
      try {
21907
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21908
      } catch (org.apache.thrift.TException te) {
21909
        throw new java.io.IOException(te);
21910
      }
21911
    }
21912
 
21913
  }
21914
 
21915
  public static class resetAvailabilityForWarehouse_args implements org.apache.thrift.TBase<resetAvailabilityForWarehouse_args, resetAvailabilityForWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
21916
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailabilityForWarehouse_args");
21917
 
21918
    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)1);
21919
 
21920
    private long warehouseId; // required
21921
 
21922
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21923
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21924
      WAREHOUSE_ID((short)1, "warehouseId");
21925
 
21926
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21927
 
21928
      static {
21929
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21930
          byName.put(field.getFieldName(), field);
21931
        }
21932
      }
21933
 
21934
      /**
21935
       * Find the _Fields constant that matches fieldId, or null if its not found.
21936
       */
21937
      public static _Fields findByThriftId(int fieldId) {
21938
        switch(fieldId) {
21939
          case 1: // WAREHOUSE_ID
21940
            return WAREHOUSE_ID;
21941
          default:
21942
            return null;
21943
        }
21944
      }
21945
 
21946
      /**
21947
       * Find the _Fields constant that matches fieldId, throwing an exception
21948
       * if it is not found.
21949
       */
21950
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21951
        _Fields fields = findByThriftId(fieldId);
21952
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21953
        return fields;
21954
      }
21955
 
21956
      /**
21957
       * Find the _Fields constant that matches name, or null if its not found.
21958
       */
21959
      public static _Fields findByName(String name) {
21960
        return byName.get(name);
21961
      }
21962
 
21963
      private final short _thriftId;
21964
      private final String _fieldName;
21965
 
21966
      _Fields(short thriftId, String fieldName) {
21967
        _thriftId = thriftId;
21968
        _fieldName = fieldName;
21969
      }
21970
 
21971
      public short getThriftFieldId() {
21972
        return _thriftId;
21973
      }
21974
 
21975
      public String getFieldName() {
21976
        return _fieldName;
21977
      }
21978
    }
21979
 
21980
    // isset id assignments
21981
    private static final int __WAREHOUSEID_ISSET_ID = 0;
21982
    private BitSet __isset_bit_vector = new BitSet(1);
21983
 
21984
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21985
    static {
21986
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21987
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21988
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21989
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21990
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailabilityForWarehouse_args.class, metaDataMap);
21991
    }
21992
 
21993
    public resetAvailabilityForWarehouse_args() {
21994
    }
21995
 
21996
    public resetAvailabilityForWarehouse_args(
21997
      long warehouseId)
21998
    {
21999
      this();
22000
      this.warehouseId = warehouseId;
22001
      setWarehouseIdIsSet(true);
22002
    }
22003
 
22004
    /**
22005
     * Performs a deep copy on <i>other</i>.
22006
     */
22007
    public resetAvailabilityForWarehouse_args(resetAvailabilityForWarehouse_args other) {
22008
      __isset_bit_vector.clear();
22009
      __isset_bit_vector.or(other.__isset_bit_vector);
22010
      this.warehouseId = other.warehouseId;
22011
    }
22012
 
22013
    public resetAvailabilityForWarehouse_args deepCopy() {
22014
      return new resetAvailabilityForWarehouse_args(this);
22015
    }
22016
 
22017
    @Override
22018
    public void clear() {
22019
      setWarehouseIdIsSet(false);
22020
      this.warehouseId = 0;
22021
    }
22022
 
22023
    public long getWarehouseId() {
22024
      return this.warehouseId;
22025
    }
22026
 
22027
    public void setWarehouseId(long warehouseId) {
22028
      this.warehouseId = warehouseId;
22029
      setWarehouseIdIsSet(true);
22030
    }
22031
 
22032
    public void unsetWarehouseId() {
22033
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
22034
    }
22035
 
22036
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
22037
    public boolean isSetWarehouseId() {
22038
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
22039
    }
22040
 
22041
    public void setWarehouseIdIsSet(boolean value) {
22042
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
22043
    }
22044
 
22045
    public void setFieldValue(_Fields field, Object value) {
22046
      switch (field) {
22047
      case WAREHOUSE_ID:
22048
        if (value == null) {
22049
          unsetWarehouseId();
22050
        } else {
22051
          setWarehouseId((Long)value);
22052
        }
22053
        break;
22054
 
22055
      }
22056
    }
22057
 
22058
    public Object getFieldValue(_Fields field) {
22059
      switch (field) {
22060
      case WAREHOUSE_ID:
22061
        return Long.valueOf(getWarehouseId());
22062
 
22063
      }
22064
      throw new IllegalStateException();
22065
    }
22066
 
22067
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22068
    public boolean isSet(_Fields field) {
22069
      if (field == null) {
22070
        throw new IllegalArgumentException();
22071
      }
22072
 
22073
      switch (field) {
22074
      case WAREHOUSE_ID:
22075
        return isSetWarehouseId();
22076
      }
22077
      throw new IllegalStateException();
22078
    }
22079
 
22080
    @Override
22081
    public boolean equals(Object that) {
22082
      if (that == null)
22083
        return false;
22084
      if (that instanceof resetAvailabilityForWarehouse_args)
22085
        return this.equals((resetAvailabilityForWarehouse_args)that);
22086
      return false;
22087
    }
22088
 
22089
    public boolean equals(resetAvailabilityForWarehouse_args that) {
22090
      if (that == null)
22091
        return false;
22092
 
22093
      boolean this_present_warehouseId = true;
22094
      boolean that_present_warehouseId = true;
22095
      if (this_present_warehouseId || that_present_warehouseId) {
22096
        if (!(this_present_warehouseId && that_present_warehouseId))
22097
          return false;
22098
        if (this.warehouseId != that.warehouseId)
22099
          return false;
22100
      }
22101
 
22102
      return true;
22103
    }
22104
 
22105
    @Override
22106
    public int hashCode() {
22107
      return 0;
22108
    }
22109
 
22110
    public int compareTo(resetAvailabilityForWarehouse_args other) {
22111
      if (!getClass().equals(other.getClass())) {
22112
        return getClass().getName().compareTo(other.getClass().getName());
22113
      }
22114
 
22115
      int lastComparison = 0;
22116
      resetAvailabilityForWarehouse_args typedOther = (resetAvailabilityForWarehouse_args)other;
22117
 
22118
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
22119
      if (lastComparison != 0) {
22120
        return lastComparison;
22121
      }
22122
      if (isSetWarehouseId()) {
22123
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
22124
        if (lastComparison != 0) {
22125
          return lastComparison;
22126
        }
22127
      }
22128
      return 0;
22129
    }
22130
 
22131
    public _Fields fieldForId(int fieldId) {
22132
      return _Fields.findByThriftId(fieldId);
22133
    }
22134
 
22135
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22136
      org.apache.thrift.protocol.TField field;
22137
      iprot.readStructBegin();
22138
      while (true)
22139
      {
22140
        field = iprot.readFieldBegin();
22141
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22142
          break;
22143
        }
22144
        switch (field.id) {
22145
          case 1: // WAREHOUSE_ID
22146
            if (field.type == org.apache.thrift.protocol.TType.I64) {
22147
              this.warehouseId = iprot.readI64();
22148
              setWarehouseIdIsSet(true);
22149
            } else { 
22150
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22151
            }
22152
            break;
22153
          default:
22154
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22155
        }
22156
        iprot.readFieldEnd();
22157
      }
22158
      iprot.readStructEnd();
22159
      validate();
22160
    }
22161
 
22162
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22163
      validate();
22164
 
22165
      oprot.writeStructBegin(STRUCT_DESC);
22166
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
22167
      oprot.writeI64(this.warehouseId);
22168
      oprot.writeFieldEnd();
22169
      oprot.writeFieldStop();
22170
      oprot.writeStructEnd();
22171
    }
22172
 
22173
    @Override
22174
    public String toString() {
22175
      StringBuilder sb = new StringBuilder("resetAvailabilityForWarehouse_args(");
22176
      boolean first = true;
22177
 
22178
      sb.append("warehouseId:");
22179
      sb.append(this.warehouseId);
22180
      first = false;
22181
      sb.append(")");
22182
      return sb.toString();
22183
    }
22184
 
22185
    public void validate() throws org.apache.thrift.TException {
22186
      // check for required fields
22187
    }
22188
 
22189
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22190
      try {
22191
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22192
      } catch (org.apache.thrift.TException te) {
22193
        throw new java.io.IOException(te);
22194
      }
22195
    }
22196
 
22197
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22198
      try {
22199
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
22200
        __isset_bit_vector = new BitSet(1);
22201
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22202
      } catch (org.apache.thrift.TException te) {
22203
        throw new java.io.IOException(te);
22204
      }
22205
    }
22206
 
22207
  }
22208
 
22209
  public static class resetAvailabilityForWarehouse_result implements org.apache.thrift.TBase<resetAvailabilityForWarehouse_result, resetAvailabilityForWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
22210
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailabilityForWarehouse_result");
22211
 
22212
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
22213
 
22214
    private InventoryServiceException cex; // required
22215
 
22216
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22217
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22218
      CEX((short)1, "cex");
22219
 
22220
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22221
 
22222
      static {
22223
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22224
          byName.put(field.getFieldName(), field);
22225
        }
22226
      }
22227
 
22228
      /**
22229
       * Find the _Fields constant that matches fieldId, or null if its not found.
22230
       */
22231
      public static _Fields findByThriftId(int fieldId) {
22232
        switch(fieldId) {
22233
          case 1: // CEX
22234
            return CEX;
22235
          default:
22236
            return null;
22237
        }
22238
      }
22239
 
22240
      /**
22241
       * Find the _Fields constant that matches fieldId, throwing an exception
22242
       * if it is not found.
22243
       */
22244
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22245
        _Fields fields = findByThriftId(fieldId);
22246
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22247
        return fields;
22248
      }
22249
 
22250
      /**
22251
       * Find the _Fields constant that matches name, or null if its not found.
22252
       */
22253
      public static _Fields findByName(String name) {
22254
        return byName.get(name);
22255
      }
22256
 
22257
      private final short _thriftId;
22258
      private final String _fieldName;
22259
 
22260
      _Fields(short thriftId, String fieldName) {
22261
        _thriftId = thriftId;
22262
        _fieldName = fieldName;
22263
      }
22264
 
22265
      public short getThriftFieldId() {
22266
        return _thriftId;
22267
      }
22268
 
22269
      public String getFieldName() {
22270
        return _fieldName;
22271
      }
22272
    }
22273
 
22274
    // isset id assignments
22275
 
22276
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22277
    static {
22278
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22279
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22280
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
22281
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22282
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailabilityForWarehouse_result.class, metaDataMap);
22283
    }
22284
 
22285
    public resetAvailabilityForWarehouse_result() {
22286
    }
22287
 
22288
    public resetAvailabilityForWarehouse_result(
22289
      InventoryServiceException cex)
22290
    {
22291
      this();
22292
      this.cex = cex;
22293
    }
22294
 
22295
    /**
22296
     * Performs a deep copy on <i>other</i>.
22297
     */
22298
    public resetAvailabilityForWarehouse_result(resetAvailabilityForWarehouse_result other) {
22299
      if (other.isSetCex()) {
22300
        this.cex = new InventoryServiceException(other.cex);
22301
      }
22302
    }
22303
 
22304
    public resetAvailabilityForWarehouse_result deepCopy() {
22305
      return new resetAvailabilityForWarehouse_result(this);
22306
    }
22307
 
22308
    @Override
22309
    public void clear() {
22310
      this.cex = null;
22311
    }
22312
 
22313
    public InventoryServiceException getCex() {
22314
      return this.cex;
22315
    }
22316
 
22317
    public void setCex(InventoryServiceException cex) {
22318
      this.cex = cex;
22319
    }
22320
 
22321
    public void unsetCex() {
22322
      this.cex = null;
22323
    }
22324
 
22325
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
22326
    public boolean isSetCex() {
22327
      return this.cex != null;
22328
    }
22329
 
22330
    public void setCexIsSet(boolean value) {
22331
      if (!value) {
22332
        this.cex = null;
22333
      }
22334
    }
22335
 
22336
    public void setFieldValue(_Fields field, Object value) {
22337
      switch (field) {
22338
      case CEX:
22339
        if (value == null) {
22340
          unsetCex();
22341
        } else {
22342
          setCex((InventoryServiceException)value);
22343
        }
22344
        break;
22345
 
22346
      }
22347
    }
22348
 
22349
    public Object getFieldValue(_Fields field) {
22350
      switch (field) {
22351
      case CEX:
22352
        return getCex();
22353
 
22354
      }
22355
      throw new IllegalStateException();
22356
    }
22357
 
22358
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22359
    public boolean isSet(_Fields field) {
22360
      if (field == null) {
22361
        throw new IllegalArgumentException();
22362
      }
22363
 
22364
      switch (field) {
22365
      case CEX:
22366
        return isSetCex();
22367
      }
22368
      throw new IllegalStateException();
22369
    }
22370
 
22371
    @Override
22372
    public boolean equals(Object that) {
22373
      if (that == null)
22374
        return false;
22375
      if (that instanceof resetAvailabilityForWarehouse_result)
22376
        return this.equals((resetAvailabilityForWarehouse_result)that);
22377
      return false;
22378
    }
22379
 
22380
    public boolean equals(resetAvailabilityForWarehouse_result that) {
22381
      if (that == null)
22382
        return false;
22383
 
22384
      boolean this_present_cex = true && this.isSetCex();
22385
      boolean that_present_cex = true && that.isSetCex();
22386
      if (this_present_cex || that_present_cex) {
22387
        if (!(this_present_cex && that_present_cex))
22388
          return false;
22389
        if (!this.cex.equals(that.cex))
22390
          return false;
22391
      }
22392
 
22393
      return true;
22394
    }
22395
 
22396
    @Override
22397
    public int hashCode() {
22398
      return 0;
22399
    }
22400
 
22401
    public int compareTo(resetAvailabilityForWarehouse_result other) {
22402
      if (!getClass().equals(other.getClass())) {
22403
        return getClass().getName().compareTo(other.getClass().getName());
22404
      }
22405
 
22406
      int lastComparison = 0;
22407
      resetAvailabilityForWarehouse_result typedOther = (resetAvailabilityForWarehouse_result)other;
22408
 
22409
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
22410
      if (lastComparison != 0) {
22411
        return lastComparison;
22412
      }
22413
      if (isSetCex()) {
22414
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
22415
        if (lastComparison != 0) {
22416
          return lastComparison;
22417
        }
22418
      }
22419
      return 0;
22420
    }
22421
 
22422
    public _Fields fieldForId(int fieldId) {
22423
      return _Fields.findByThriftId(fieldId);
22424
    }
22425
 
22426
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22427
      org.apache.thrift.protocol.TField field;
22428
      iprot.readStructBegin();
22429
      while (true)
22430
      {
22431
        field = iprot.readFieldBegin();
22432
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22433
          break;
22434
        }
22435
        switch (field.id) {
22436
          case 1: // CEX
22437
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
22438
              this.cex = new InventoryServiceException();
22439
              this.cex.read(iprot);
22440
            } else { 
22441
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22442
            }
22443
            break;
22444
          default:
22445
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22446
        }
22447
        iprot.readFieldEnd();
22448
      }
22449
      iprot.readStructEnd();
22450
      validate();
22451
    }
22452
 
22453
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22454
      oprot.writeStructBegin(STRUCT_DESC);
22455
 
22456
      if (this.isSetCex()) {
22457
        oprot.writeFieldBegin(CEX_FIELD_DESC);
22458
        this.cex.write(oprot);
22459
        oprot.writeFieldEnd();
22460
      }
22461
      oprot.writeFieldStop();
22462
      oprot.writeStructEnd();
22463
    }
22464
 
22465
    @Override
22466
    public String toString() {
22467
      StringBuilder sb = new StringBuilder("resetAvailabilityForWarehouse_result(");
22468
      boolean first = true;
22469
 
22470
      sb.append("cex:");
22471
      if (this.cex == null) {
22472
        sb.append("null");
22473
      } else {
22474
        sb.append(this.cex);
22475
      }
22476
      first = false;
22477
      sb.append(")");
22478
      return sb.toString();
22479
    }
22480
 
22481
    public void validate() throws org.apache.thrift.TException {
22482
      // check for required fields
22483
    }
22484
 
22485
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22486
      try {
22487
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22488
      } catch (org.apache.thrift.TException te) {
22489
        throw new java.io.IOException(te);
22490
      }
22491
    }
22492
 
22493
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22494
      try {
22495
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22496
      } catch (org.apache.thrift.TException te) {
22497
        throw new java.io.IOException(te);
22498
      }
22499
    }
22500
 
22501
  }
22502
 
22503
  public static class getItemKeysToBeProcessed_args implements org.apache.thrift.TBase<getItemKeysToBeProcessed_args, getItemKeysToBeProcessed_args._Fields>, java.io.Serializable, Cloneable   {
22504
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemKeysToBeProcessed_args");
22505
 
22506
    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)1);
22507
 
22508
    private long warehouseId; // required
22509
 
22510
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22511
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22512
      WAREHOUSE_ID((short)1, "warehouseId");
22513
 
22514
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22515
 
22516
      static {
22517
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22518
          byName.put(field.getFieldName(), field);
22519
        }
22520
      }
22521
 
22522
      /**
22523
       * Find the _Fields constant that matches fieldId, or null if its not found.
22524
       */
22525
      public static _Fields findByThriftId(int fieldId) {
22526
        switch(fieldId) {
22527
          case 1: // WAREHOUSE_ID
22528
            return WAREHOUSE_ID;
22529
          default:
22530
            return null;
22531
        }
22532
      }
22533
 
22534
      /**
22535
       * Find the _Fields constant that matches fieldId, throwing an exception
22536
       * if it is not found.
22537
       */
22538
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22539
        _Fields fields = findByThriftId(fieldId);
22540
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22541
        return fields;
22542
      }
22543
 
22544
      /**
22545
       * Find the _Fields constant that matches name, or null if its not found.
22546
       */
22547
      public static _Fields findByName(String name) {
22548
        return byName.get(name);
22549
      }
22550
 
22551
      private final short _thriftId;
22552
      private final String _fieldName;
22553
 
22554
      _Fields(short thriftId, String fieldName) {
22555
        _thriftId = thriftId;
22556
        _fieldName = fieldName;
22557
      }
22558
 
22559
      public short getThriftFieldId() {
22560
        return _thriftId;
22561
      }
22562
 
22563
      public String getFieldName() {
22564
        return _fieldName;
22565
      }
22566
    }
22567
 
22568
    // isset id assignments
22569
    private static final int __WAREHOUSEID_ISSET_ID = 0;
22570
    private BitSet __isset_bit_vector = new BitSet(1);
22571
 
22572
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22573
    static {
22574
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22575
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22576
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
22577
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22578
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemKeysToBeProcessed_args.class, metaDataMap);
22579
    }
22580
 
22581
    public getItemKeysToBeProcessed_args() {
22582
    }
22583
 
22584
    public getItemKeysToBeProcessed_args(
22585
      long warehouseId)
22586
    {
22587
      this();
22588
      this.warehouseId = warehouseId;
22589
      setWarehouseIdIsSet(true);
22590
    }
22591
 
22592
    /**
22593
     * Performs a deep copy on <i>other</i>.
22594
     */
22595
    public getItemKeysToBeProcessed_args(getItemKeysToBeProcessed_args other) {
22596
      __isset_bit_vector.clear();
22597
      __isset_bit_vector.or(other.__isset_bit_vector);
22598
      this.warehouseId = other.warehouseId;
22599
    }
22600
 
22601
    public getItemKeysToBeProcessed_args deepCopy() {
22602
      return new getItemKeysToBeProcessed_args(this);
22603
    }
22604
 
22605
    @Override
22606
    public void clear() {
22607
      setWarehouseIdIsSet(false);
22608
      this.warehouseId = 0;
22609
    }
22610
 
22611
    public long getWarehouseId() {
22612
      return this.warehouseId;
22613
    }
22614
 
22615
    public void setWarehouseId(long warehouseId) {
22616
      this.warehouseId = warehouseId;
22617
      setWarehouseIdIsSet(true);
22618
    }
22619
 
22620
    public void unsetWarehouseId() {
22621
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
22622
    }
22623
 
22624
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
22625
    public boolean isSetWarehouseId() {
22626
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
22627
    }
22628
 
22629
    public void setWarehouseIdIsSet(boolean value) {
22630
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
22631
    }
22632
 
22633
    public void setFieldValue(_Fields field, Object value) {
22634
      switch (field) {
22635
      case WAREHOUSE_ID:
22636
        if (value == null) {
22637
          unsetWarehouseId();
22638
        } else {
22639
          setWarehouseId((Long)value);
22640
        }
22641
        break;
22642
 
22643
      }
22644
    }
22645
 
22646
    public Object getFieldValue(_Fields field) {
22647
      switch (field) {
22648
      case WAREHOUSE_ID:
22649
        return Long.valueOf(getWarehouseId());
22650
 
22651
      }
22652
      throw new IllegalStateException();
22653
    }
22654
 
22655
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22656
    public boolean isSet(_Fields field) {
22657
      if (field == null) {
22658
        throw new IllegalArgumentException();
22659
      }
22660
 
22661
      switch (field) {
22662
      case WAREHOUSE_ID:
22663
        return isSetWarehouseId();
22664
      }
22665
      throw new IllegalStateException();
22666
    }
22667
 
22668
    @Override
22669
    public boolean equals(Object that) {
22670
      if (that == null)
22671
        return false;
22672
      if (that instanceof getItemKeysToBeProcessed_args)
22673
        return this.equals((getItemKeysToBeProcessed_args)that);
22674
      return false;
22675
    }
22676
 
22677
    public boolean equals(getItemKeysToBeProcessed_args that) {
22678
      if (that == null)
22679
        return false;
22680
 
22681
      boolean this_present_warehouseId = true;
22682
      boolean that_present_warehouseId = true;
22683
      if (this_present_warehouseId || that_present_warehouseId) {
22684
        if (!(this_present_warehouseId && that_present_warehouseId))
22685
          return false;
22686
        if (this.warehouseId != that.warehouseId)
22687
          return false;
22688
      }
22689
 
22690
      return true;
22691
    }
22692
 
22693
    @Override
22694
    public int hashCode() {
22695
      return 0;
22696
    }
22697
 
22698
    public int compareTo(getItemKeysToBeProcessed_args other) {
22699
      if (!getClass().equals(other.getClass())) {
22700
        return getClass().getName().compareTo(other.getClass().getName());
22701
      }
22702
 
22703
      int lastComparison = 0;
22704
      getItemKeysToBeProcessed_args typedOther = (getItemKeysToBeProcessed_args)other;
22705
 
22706
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
22707
      if (lastComparison != 0) {
22708
        return lastComparison;
22709
      }
22710
      if (isSetWarehouseId()) {
22711
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
22712
        if (lastComparison != 0) {
22713
          return lastComparison;
22714
        }
22715
      }
22716
      return 0;
22717
    }
22718
 
22719
    public _Fields fieldForId(int fieldId) {
22720
      return _Fields.findByThriftId(fieldId);
22721
    }
22722
 
22723
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22724
      org.apache.thrift.protocol.TField field;
22725
      iprot.readStructBegin();
22726
      while (true)
22727
      {
22728
        field = iprot.readFieldBegin();
22729
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22730
          break;
22731
        }
22732
        switch (field.id) {
22733
          case 1: // WAREHOUSE_ID
22734
            if (field.type == org.apache.thrift.protocol.TType.I64) {
22735
              this.warehouseId = iprot.readI64();
22736
              setWarehouseIdIsSet(true);
22737
            } else { 
22738
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22739
            }
22740
            break;
22741
          default:
22742
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22743
        }
22744
        iprot.readFieldEnd();
22745
      }
22746
      iprot.readStructEnd();
22747
      validate();
22748
    }
22749
 
22750
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22751
      validate();
22752
 
22753
      oprot.writeStructBegin(STRUCT_DESC);
22754
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
22755
      oprot.writeI64(this.warehouseId);
22756
      oprot.writeFieldEnd();
22757
      oprot.writeFieldStop();
22758
      oprot.writeStructEnd();
22759
    }
22760
 
22761
    @Override
22762
    public String toString() {
22763
      StringBuilder sb = new StringBuilder("getItemKeysToBeProcessed_args(");
22764
      boolean first = true;
22765
 
22766
      sb.append("warehouseId:");
22767
      sb.append(this.warehouseId);
22768
      first = false;
22769
      sb.append(")");
22770
      return sb.toString();
22771
    }
22772
 
22773
    public void validate() throws org.apache.thrift.TException {
22774
      // check for required fields
22775
    }
22776
 
22777
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22778
      try {
22779
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22780
      } catch (org.apache.thrift.TException te) {
22781
        throw new java.io.IOException(te);
22782
      }
22783
    }
22784
 
22785
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22786
      try {
22787
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22788
      } catch (org.apache.thrift.TException te) {
22789
        throw new java.io.IOException(te);
22790
      }
22791
    }
22792
 
22793
  }
22794
 
22795
  public static class getItemKeysToBeProcessed_result implements org.apache.thrift.TBase<getItemKeysToBeProcessed_result, getItemKeysToBeProcessed_result._Fields>, java.io.Serializable, Cloneable   {
22796
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemKeysToBeProcessed_result");
22797
 
22798
    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);
22799
 
22800
    private List<String> success; // required
22801
 
22802
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22803
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22804
      SUCCESS((short)0, "success");
22805
 
22806
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22807
 
22808
      static {
22809
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22810
          byName.put(field.getFieldName(), field);
22811
        }
22812
      }
22813
 
22814
      /**
22815
       * Find the _Fields constant that matches fieldId, or null if its not found.
22816
       */
22817
      public static _Fields findByThriftId(int fieldId) {
22818
        switch(fieldId) {
22819
          case 0: // SUCCESS
22820
            return SUCCESS;
22821
          default:
22822
            return null;
22823
        }
22824
      }
22825
 
22826
      /**
22827
       * Find the _Fields constant that matches fieldId, throwing an exception
22828
       * if it is not found.
22829
       */
22830
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22831
        _Fields fields = findByThriftId(fieldId);
22832
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22833
        return fields;
22834
      }
22835
 
22836
      /**
22837
       * Find the _Fields constant that matches name, or null if its not found.
22838
       */
22839
      public static _Fields findByName(String name) {
22840
        return byName.get(name);
22841
      }
22842
 
22843
      private final short _thriftId;
22844
      private final String _fieldName;
22845
 
22846
      _Fields(short thriftId, String fieldName) {
22847
        _thriftId = thriftId;
22848
        _fieldName = fieldName;
22849
      }
22850
 
22851
      public short getThriftFieldId() {
22852
        return _thriftId;
22853
      }
22854
 
22855
      public String getFieldName() {
22856
        return _fieldName;
22857
      }
22858
    }
22859
 
22860
    // isset id assignments
22861
 
22862
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22863
    static {
22864
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22865
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22866
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
22867
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
22868
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22869
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemKeysToBeProcessed_result.class, metaDataMap);
22870
    }
22871
 
22872
    public getItemKeysToBeProcessed_result() {
22873
    }
22874
 
22875
    public getItemKeysToBeProcessed_result(
22876
      List<String> success)
22877
    {
22878
      this();
22879
      this.success = success;
22880
    }
22881
 
22882
    /**
22883
     * Performs a deep copy on <i>other</i>.
22884
     */
22885
    public getItemKeysToBeProcessed_result(getItemKeysToBeProcessed_result other) {
22886
      if (other.isSetSuccess()) {
22887
        List<String> __this__success = new ArrayList<String>();
22888
        for (String other_element : other.success) {
22889
          __this__success.add(other_element);
22890
        }
22891
        this.success = __this__success;
22892
      }
22893
    }
22894
 
22895
    public getItemKeysToBeProcessed_result deepCopy() {
22896
      return new getItemKeysToBeProcessed_result(this);
22897
    }
22898
 
22899
    @Override
22900
    public void clear() {
22901
      this.success = null;
22902
    }
22903
 
22904
    public int getSuccessSize() {
22905
      return (this.success == null) ? 0 : this.success.size();
22906
    }
22907
 
22908
    public java.util.Iterator<String> getSuccessIterator() {
22909
      return (this.success == null) ? null : this.success.iterator();
22910
    }
22911
 
22912
    public void addToSuccess(String elem) {
22913
      if (this.success == null) {
22914
        this.success = new ArrayList<String>();
22915
      }
22916
      this.success.add(elem);
22917
    }
22918
 
22919
    public List<String> getSuccess() {
22920
      return this.success;
22921
    }
22922
 
22923
    public void setSuccess(List<String> success) {
22924
      this.success = success;
22925
    }
22926
 
22927
    public void unsetSuccess() {
22928
      this.success = null;
22929
    }
22930
 
22931
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
22932
    public boolean isSetSuccess() {
22933
      return this.success != null;
22934
    }
22935
 
22936
    public void setSuccessIsSet(boolean value) {
22937
      if (!value) {
22938
        this.success = null;
22939
      }
22940
    }
22941
 
22942
    public void setFieldValue(_Fields field, Object value) {
22943
      switch (field) {
22944
      case SUCCESS:
22945
        if (value == null) {
22946
          unsetSuccess();
22947
        } else {
22948
          setSuccess((List<String>)value);
22949
        }
22950
        break;
22951
 
22952
      }
22953
    }
22954
 
22955
    public Object getFieldValue(_Fields field) {
22956
      switch (field) {
22957
      case SUCCESS:
22958
        return getSuccess();
22959
 
22960
      }
22961
      throw new IllegalStateException();
22962
    }
22963
 
22964
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22965
    public boolean isSet(_Fields field) {
22966
      if (field == null) {
22967
        throw new IllegalArgumentException();
22968
      }
22969
 
22970
      switch (field) {
22971
      case SUCCESS:
22972
        return isSetSuccess();
22973
      }
22974
      throw new IllegalStateException();
22975
    }
22976
 
22977
    @Override
22978
    public boolean equals(Object that) {
22979
      if (that == null)
22980
        return false;
22981
      if (that instanceof getItemKeysToBeProcessed_result)
22982
        return this.equals((getItemKeysToBeProcessed_result)that);
22983
      return false;
22984
    }
22985
 
22986
    public boolean equals(getItemKeysToBeProcessed_result that) {
22987
      if (that == null)
22988
        return false;
22989
 
22990
      boolean this_present_success = true && this.isSetSuccess();
22991
      boolean that_present_success = true && that.isSetSuccess();
22992
      if (this_present_success || that_present_success) {
22993
        if (!(this_present_success && that_present_success))
22994
          return false;
22995
        if (!this.success.equals(that.success))
22996
          return false;
22997
      }
22998
 
22999
      return true;
23000
    }
23001
 
23002
    @Override
23003
    public int hashCode() {
23004
      return 0;
23005
    }
23006
 
23007
    public int compareTo(getItemKeysToBeProcessed_result other) {
23008
      if (!getClass().equals(other.getClass())) {
23009
        return getClass().getName().compareTo(other.getClass().getName());
23010
      }
23011
 
23012
      int lastComparison = 0;
23013
      getItemKeysToBeProcessed_result typedOther = (getItemKeysToBeProcessed_result)other;
23014
 
23015
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
23016
      if (lastComparison != 0) {
23017
        return lastComparison;
23018
      }
23019
      if (isSetSuccess()) {
23020
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
23021
        if (lastComparison != 0) {
23022
          return lastComparison;
23023
        }
23024
      }
23025
      return 0;
23026
    }
23027
 
23028
    public _Fields fieldForId(int fieldId) {
23029
      return _Fields.findByThriftId(fieldId);
23030
    }
23031
 
23032
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23033
      org.apache.thrift.protocol.TField field;
23034
      iprot.readStructBegin();
23035
      while (true)
23036
      {
23037
        field = iprot.readFieldBegin();
23038
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23039
          break;
23040
        }
23041
        switch (field.id) {
23042
          case 0: // SUCCESS
23043
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
23044
              {
23045
                org.apache.thrift.protocol.TList _list52 = iprot.readListBegin();
23046
                this.success = new ArrayList<String>(_list52.size);
23047
                for (int _i53 = 0; _i53 < _list52.size; ++_i53)
23048
                {
23049
                  String _elem54; // required
23050
                  _elem54 = iprot.readString();
23051
                  this.success.add(_elem54);
23052
                }
23053
                iprot.readListEnd();
23054
              }
23055
            } else { 
23056
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23057
            }
23058
            break;
23059
          default:
23060
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23061
        }
23062
        iprot.readFieldEnd();
23063
      }
23064
      iprot.readStructEnd();
23065
      validate();
23066
    }
23067
 
23068
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23069
      oprot.writeStructBegin(STRUCT_DESC);
23070
 
23071
      if (this.isSetSuccess()) {
23072
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
23073
        {
23074
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, this.success.size()));
23075
          for (String _iter55 : this.success)
23076
          {
23077
            oprot.writeString(_iter55);
23078
          }
23079
          oprot.writeListEnd();
23080
        }
23081
        oprot.writeFieldEnd();
23082
      }
23083
      oprot.writeFieldStop();
23084
      oprot.writeStructEnd();
23085
    }
23086
 
23087
    @Override
23088
    public String toString() {
23089
      StringBuilder sb = new StringBuilder("getItemKeysToBeProcessed_result(");
23090
      boolean first = true;
23091
 
23092
      sb.append("success:");
23093
      if (this.success == null) {
23094
        sb.append("null");
23095
      } else {
23096
        sb.append(this.success);
23097
      }
23098
      first = false;
23099
      sb.append(")");
23100
      return sb.toString();
23101
    }
23102
 
23103
    public void validate() throws org.apache.thrift.TException {
23104
      // check for required fields
23105
    }
23106
 
23107
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23108
      try {
23109
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23110
      } catch (org.apache.thrift.TException te) {
23111
        throw new java.io.IOException(te);
23112
      }
23113
    }
23114
 
23115
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23116
      try {
23117
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23118
      } catch (org.apache.thrift.TException te) {
23119
        throw new java.io.IOException(te);
23120
      }
23121
    }
23122
 
23123
  }
23124
 
23125
  public static class markMissedInventoryUpdatesAsProcessed_args implements org.apache.thrift.TBase<markMissedInventoryUpdatesAsProcessed_args, markMissedInventoryUpdatesAsProcessed_args._Fields>, java.io.Serializable, Cloneable   {
23126
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markMissedInventoryUpdatesAsProcessed_args");
23127
 
23128
    private static final org.apache.thrift.protocol.TField ITEM_KEY_FIELD_DESC = new org.apache.thrift.protocol.TField("itemKey", org.apache.thrift.protocol.TType.STRING, (short)1);
23129
    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)2);
23130
 
23131
    private String itemKey; // required
23132
    private long warehouseId; // required
23133
 
23134
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23135
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23136
      ITEM_KEY((short)1, "itemKey"),
23137
      WAREHOUSE_ID((short)2, "warehouseId");
23138
 
23139
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23140
 
23141
      static {
23142
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23143
          byName.put(field.getFieldName(), field);
23144
        }
23145
      }
23146
 
23147
      /**
23148
       * Find the _Fields constant that matches fieldId, or null if its not found.
23149
       */
23150
      public static _Fields findByThriftId(int fieldId) {
23151
        switch(fieldId) {
23152
          case 1: // ITEM_KEY
23153
            return ITEM_KEY;
23154
          case 2: // WAREHOUSE_ID
23155
            return WAREHOUSE_ID;
23156
          default:
23157
            return null;
23158
        }
23159
      }
23160
 
23161
      /**
23162
       * Find the _Fields constant that matches fieldId, throwing an exception
23163
       * if it is not found.
23164
       */
23165
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23166
        _Fields fields = findByThriftId(fieldId);
23167
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23168
        return fields;
23169
      }
23170
 
23171
      /**
23172
       * Find the _Fields constant that matches name, or null if its not found.
23173
       */
23174
      public static _Fields findByName(String name) {
23175
        return byName.get(name);
23176
      }
23177
 
23178
      private final short _thriftId;
23179
      private final String _fieldName;
23180
 
23181
      _Fields(short thriftId, String fieldName) {
23182
        _thriftId = thriftId;
23183
        _fieldName = fieldName;
23184
      }
23185
 
23186
      public short getThriftFieldId() {
23187
        return _thriftId;
23188
      }
23189
 
23190
      public String getFieldName() {
23191
        return _fieldName;
23192
      }
23193
    }
23194
 
23195
    // isset id assignments
23196
    private static final int __WAREHOUSEID_ISSET_ID = 0;
23197
    private BitSet __isset_bit_vector = new BitSet(1);
23198
 
23199
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23200
    static {
23201
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23202
      tmpMap.put(_Fields.ITEM_KEY, new org.apache.thrift.meta_data.FieldMetaData("itemKey", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23203
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
23204
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23205
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
23206
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23207
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markMissedInventoryUpdatesAsProcessed_args.class, metaDataMap);
23208
    }
23209
 
23210
    public markMissedInventoryUpdatesAsProcessed_args() {
23211
    }
23212
 
23213
    public markMissedInventoryUpdatesAsProcessed_args(
23214
      String itemKey,
23215
      long warehouseId)
23216
    {
23217
      this();
23218
      this.itemKey = itemKey;
23219
      this.warehouseId = warehouseId;
23220
      setWarehouseIdIsSet(true);
23221
    }
23222
 
23223
    /**
23224
     * Performs a deep copy on <i>other</i>.
23225
     */
23226
    public markMissedInventoryUpdatesAsProcessed_args(markMissedInventoryUpdatesAsProcessed_args other) {
23227
      __isset_bit_vector.clear();
23228
      __isset_bit_vector.or(other.__isset_bit_vector);
23229
      if (other.isSetItemKey()) {
23230
        this.itemKey = other.itemKey;
23231
      }
23232
      this.warehouseId = other.warehouseId;
23233
    }
23234
 
23235
    public markMissedInventoryUpdatesAsProcessed_args deepCopy() {
23236
      return new markMissedInventoryUpdatesAsProcessed_args(this);
23237
    }
23238
 
23239
    @Override
23240
    public void clear() {
23241
      this.itemKey = null;
23242
      setWarehouseIdIsSet(false);
23243
      this.warehouseId = 0;
23244
    }
23245
 
23246
    public String getItemKey() {
23247
      return this.itemKey;
23248
    }
23249
 
23250
    public void setItemKey(String itemKey) {
23251
      this.itemKey = itemKey;
23252
    }
23253
 
23254
    public void unsetItemKey() {
23255
      this.itemKey = null;
23256
    }
23257
 
23258
    /** Returns true if field itemKey is set (has been assigned a value) and false otherwise */
23259
    public boolean isSetItemKey() {
23260
      return this.itemKey != null;
23261
    }
23262
 
23263
    public void setItemKeyIsSet(boolean value) {
23264
      if (!value) {
23265
        this.itemKey = null;
23266
      }
23267
    }
23268
 
23269
    public long getWarehouseId() {
23270
      return this.warehouseId;
23271
    }
23272
 
23273
    public void setWarehouseId(long warehouseId) {
23274
      this.warehouseId = warehouseId;
23275
      setWarehouseIdIsSet(true);
23276
    }
23277
 
23278
    public void unsetWarehouseId() {
23279
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
23280
    }
23281
 
23282
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
23283
    public boolean isSetWarehouseId() {
23284
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
23285
    }
23286
 
23287
    public void setWarehouseIdIsSet(boolean value) {
23288
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
23289
    }
23290
 
23291
    public void setFieldValue(_Fields field, Object value) {
23292
      switch (field) {
23293
      case ITEM_KEY:
23294
        if (value == null) {
23295
          unsetItemKey();
23296
        } else {
23297
          setItemKey((String)value);
23298
        }
23299
        break;
23300
 
23301
      case WAREHOUSE_ID:
23302
        if (value == null) {
23303
          unsetWarehouseId();
23304
        } else {
23305
          setWarehouseId((Long)value);
23306
        }
23307
        break;
23308
 
23309
      }
23310
    }
23311
 
23312
    public Object getFieldValue(_Fields field) {
23313
      switch (field) {
23314
      case ITEM_KEY:
23315
        return getItemKey();
23316
 
23317
      case WAREHOUSE_ID:
23318
        return Long.valueOf(getWarehouseId());
23319
 
23320
      }
23321
      throw new IllegalStateException();
23322
    }
23323
 
23324
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23325
    public boolean isSet(_Fields field) {
23326
      if (field == null) {
23327
        throw new IllegalArgumentException();
23328
      }
23329
 
23330
      switch (field) {
23331
      case ITEM_KEY:
23332
        return isSetItemKey();
23333
      case WAREHOUSE_ID:
23334
        return isSetWarehouseId();
23335
      }
23336
      throw new IllegalStateException();
23337
    }
23338
 
23339
    @Override
23340
    public boolean equals(Object that) {
23341
      if (that == null)
23342
        return false;
23343
      if (that instanceof markMissedInventoryUpdatesAsProcessed_args)
23344
        return this.equals((markMissedInventoryUpdatesAsProcessed_args)that);
23345
      return false;
23346
    }
23347
 
23348
    public boolean equals(markMissedInventoryUpdatesAsProcessed_args that) {
23349
      if (that == null)
23350
        return false;
23351
 
23352
      boolean this_present_itemKey = true && this.isSetItemKey();
23353
      boolean that_present_itemKey = true && that.isSetItemKey();
23354
      if (this_present_itemKey || that_present_itemKey) {
23355
        if (!(this_present_itemKey && that_present_itemKey))
23356
          return false;
23357
        if (!this.itemKey.equals(that.itemKey))
23358
          return false;
23359
      }
23360
 
23361
      boolean this_present_warehouseId = true;
23362
      boolean that_present_warehouseId = true;
23363
      if (this_present_warehouseId || that_present_warehouseId) {
23364
        if (!(this_present_warehouseId && that_present_warehouseId))
23365
          return false;
23366
        if (this.warehouseId != that.warehouseId)
23367
          return false;
23368
      }
23369
 
23370
      return true;
23371
    }
23372
 
23373
    @Override
23374
    public int hashCode() {
23375
      return 0;
23376
    }
23377
 
23378
    public int compareTo(markMissedInventoryUpdatesAsProcessed_args other) {
23379
      if (!getClass().equals(other.getClass())) {
23380
        return getClass().getName().compareTo(other.getClass().getName());
23381
      }
23382
 
23383
      int lastComparison = 0;
23384
      markMissedInventoryUpdatesAsProcessed_args typedOther = (markMissedInventoryUpdatesAsProcessed_args)other;
23385
 
23386
      lastComparison = Boolean.valueOf(isSetItemKey()).compareTo(typedOther.isSetItemKey());
23387
      if (lastComparison != 0) {
23388
        return lastComparison;
23389
      }
23390
      if (isSetItemKey()) {
23391
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemKey, typedOther.itemKey);
23392
        if (lastComparison != 0) {
23393
          return lastComparison;
23394
        }
23395
      }
23396
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
23397
      if (lastComparison != 0) {
23398
        return lastComparison;
23399
      }
23400
      if (isSetWarehouseId()) {
23401
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
23402
        if (lastComparison != 0) {
23403
          return lastComparison;
23404
        }
23405
      }
23406
      return 0;
23407
    }
23408
 
23409
    public _Fields fieldForId(int fieldId) {
23410
      return _Fields.findByThriftId(fieldId);
23411
    }
23412
 
23413
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23414
      org.apache.thrift.protocol.TField field;
23415
      iprot.readStructBegin();
23416
      while (true)
23417
      {
23418
        field = iprot.readFieldBegin();
23419
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23420
          break;
23421
        }
23422
        switch (field.id) {
23423
          case 1: // ITEM_KEY
23424
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
23425
              this.itemKey = iprot.readString();
23426
            } else { 
23427
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23428
            }
23429
            break;
23430
          case 2: // WAREHOUSE_ID
23431
            if (field.type == org.apache.thrift.protocol.TType.I64) {
23432
              this.warehouseId = iprot.readI64();
23433
              setWarehouseIdIsSet(true);
23434
            } else { 
23435
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23436
            }
23437
            break;
23438
          default:
23439
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23440
        }
23441
        iprot.readFieldEnd();
23442
      }
23443
      iprot.readStructEnd();
23444
      validate();
23445
    }
23446
 
23447
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23448
      validate();
23449
 
23450
      oprot.writeStructBegin(STRUCT_DESC);
23451
      if (this.itemKey != null) {
23452
        oprot.writeFieldBegin(ITEM_KEY_FIELD_DESC);
23453
        oprot.writeString(this.itemKey);
23454
        oprot.writeFieldEnd();
23455
      }
23456
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
23457
      oprot.writeI64(this.warehouseId);
23458
      oprot.writeFieldEnd();
23459
      oprot.writeFieldStop();
23460
      oprot.writeStructEnd();
23461
    }
23462
 
23463
    @Override
23464
    public String toString() {
23465
      StringBuilder sb = new StringBuilder("markMissedInventoryUpdatesAsProcessed_args(");
23466
      boolean first = true;
23467
 
23468
      sb.append("itemKey:");
23469
      if (this.itemKey == null) {
23470
        sb.append("null");
23471
      } else {
23472
        sb.append(this.itemKey);
23473
      }
23474
      first = false;
23475
      if (!first) sb.append(", ");
23476
      sb.append("warehouseId:");
23477
      sb.append(this.warehouseId);
23478
      first = false;
23479
      sb.append(")");
23480
      return sb.toString();
23481
    }
23482
 
23483
    public void validate() throws org.apache.thrift.TException {
23484
      // check for required fields
23485
    }
23486
 
23487
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23488
      try {
23489
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23490
      } catch (org.apache.thrift.TException te) {
23491
        throw new java.io.IOException(te);
23492
      }
23493
    }
23494
 
23495
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23496
      try {
23497
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23498
      } catch (org.apache.thrift.TException te) {
23499
        throw new java.io.IOException(te);
23500
      }
23501
    }
23502
 
23503
  }
23504
 
23505
  public static class markMissedInventoryUpdatesAsProcessed_result implements org.apache.thrift.TBase<markMissedInventoryUpdatesAsProcessed_result, markMissedInventoryUpdatesAsProcessed_result._Fields>, java.io.Serializable, Cloneable   {
23506
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markMissedInventoryUpdatesAsProcessed_result");
23507
 
23508
 
23509
 
23510
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23511
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23512
;
23513
 
23514
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23515
 
23516
      static {
23517
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23518
          byName.put(field.getFieldName(), field);
23519
        }
23520
      }
23521
 
23522
      /**
23523
       * Find the _Fields constant that matches fieldId, or null if its not found.
23524
       */
23525
      public static _Fields findByThriftId(int fieldId) {
23526
        switch(fieldId) {
23527
          default:
23528
            return null;
23529
        }
23530
      }
23531
 
23532
      /**
23533
       * Find the _Fields constant that matches fieldId, throwing an exception
23534
       * if it is not found.
23535
       */
23536
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23537
        _Fields fields = findByThriftId(fieldId);
23538
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23539
        return fields;
23540
      }
23541
 
23542
      /**
23543
       * Find the _Fields constant that matches name, or null if its not found.
23544
       */
23545
      public static _Fields findByName(String name) {
23546
        return byName.get(name);
23547
      }
23548
 
23549
      private final short _thriftId;
23550
      private final String _fieldName;
23551
 
23552
      _Fields(short thriftId, String fieldName) {
23553
        _thriftId = thriftId;
23554
        _fieldName = fieldName;
23555
      }
23556
 
23557
      public short getThriftFieldId() {
23558
        return _thriftId;
23559
      }
23560
 
23561
      public String getFieldName() {
23562
        return _fieldName;
23563
      }
23564
    }
23565
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23566
    static {
23567
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23568
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23569
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markMissedInventoryUpdatesAsProcessed_result.class, metaDataMap);
23570
    }
23571
 
23572
    public markMissedInventoryUpdatesAsProcessed_result() {
23573
    }
23574
 
23575
    /**
23576
     * Performs a deep copy on <i>other</i>.
23577
     */
23578
    public markMissedInventoryUpdatesAsProcessed_result(markMissedInventoryUpdatesAsProcessed_result other) {
23579
    }
23580
 
23581
    public markMissedInventoryUpdatesAsProcessed_result deepCopy() {
23582
      return new markMissedInventoryUpdatesAsProcessed_result(this);
23583
    }
23584
 
23585
    @Override
23586
    public void clear() {
23587
    }
23588
 
23589
    public void setFieldValue(_Fields field, Object value) {
23590
      switch (field) {
23591
      }
23592
    }
23593
 
23594
    public Object getFieldValue(_Fields field) {
23595
      switch (field) {
23596
      }
23597
      throw new IllegalStateException();
23598
    }
23599
 
23600
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23601
    public boolean isSet(_Fields field) {
23602
      if (field == null) {
23603
        throw new IllegalArgumentException();
23604
      }
23605
 
23606
      switch (field) {
23607
      }
23608
      throw new IllegalStateException();
23609
    }
23610
 
23611
    @Override
23612
    public boolean equals(Object that) {
23613
      if (that == null)
23614
        return false;
23615
      if (that instanceof markMissedInventoryUpdatesAsProcessed_result)
23616
        return this.equals((markMissedInventoryUpdatesAsProcessed_result)that);
23617
      return false;
23618
    }
23619
 
23620
    public boolean equals(markMissedInventoryUpdatesAsProcessed_result that) {
23621
      if (that == null)
23622
        return false;
23623
 
23624
      return true;
23625
    }
23626
 
23627
    @Override
23628
    public int hashCode() {
23629
      return 0;
23630
    }
23631
 
23632
    public int compareTo(markMissedInventoryUpdatesAsProcessed_result other) {
23633
      if (!getClass().equals(other.getClass())) {
23634
        return getClass().getName().compareTo(other.getClass().getName());
23635
      }
23636
 
23637
      int lastComparison = 0;
23638
      markMissedInventoryUpdatesAsProcessed_result typedOther = (markMissedInventoryUpdatesAsProcessed_result)other;
23639
 
23640
      return 0;
23641
    }
23642
 
23643
    public _Fields fieldForId(int fieldId) {
23644
      return _Fields.findByThriftId(fieldId);
23645
    }
23646
 
23647
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23648
      org.apache.thrift.protocol.TField field;
23649
      iprot.readStructBegin();
23650
      while (true)
23651
      {
23652
        field = iprot.readFieldBegin();
23653
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23654
          break;
23655
        }
23656
        switch (field.id) {
23657
          default:
23658
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23659
        }
23660
        iprot.readFieldEnd();
23661
      }
23662
      iprot.readStructEnd();
23663
      validate();
23664
    }
23665
 
23666
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23667
      oprot.writeStructBegin(STRUCT_DESC);
23668
 
23669
      oprot.writeFieldStop();
23670
      oprot.writeStructEnd();
23671
    }
23672
 
23673
    @Override
23674
    public String toString() {
23675
      StringBuilder sb = new StringBuilder("markMissedInventoryUpdatesAsProcessed_result(");
23676
      boolean first = true;
23677
 
23678
      sb.append(")");
23679
      return sb.toString();
23680
    }
23681
 
23682
    public void validate() throws org.apache.thrift.TException {
23683
      // check for required fields
23684
    }
23685
 
23686
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23687
      try {
23688
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23689
      } catch (org.apache.thrift.TException te) {
23690
        throw new java.io.IOException(te);
23691
      }
23692
    }
23693
 
23694
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23695
      try {
23696
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23697
      } catch (org.apache.thrift.TException te) {
23698
        throw new java.io.IOException(te);
23699
      }
23700
    }
23701
 
23702
  }
23703
 
23704
  public static class getIgnoredItemKeys_args implements org.apache.thrift.TBase<getIgnoredItemKeys_args, getIgnoredItemKeys_args._Fields>, java.io.Serializable, Cloneable   {
23705
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getIgnoredItemKeys_args");
23706
 
23707
 
23708
 
23709
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23710
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23711
;
23712
 
23713
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23714
 
23715
      static {
23716
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23717
          byName.put(field.getFieldName(), field);
23718
        }
23719
      }
23720
 
23721
      /**
23722
       * Find the _Fields constant that matches fieldId, or null if its not found.
23723
       */
23724
      public static _Fields findByThriftId(int fieldId) {
23725
        switch(fieldId) {
23726
          default:
23727
            return null;
23728
        }
23729
      }
23730
 
23731
      /**
23732
       * Find the _Fields constant that matches fieldId, throwing an exception
23733
       * if it is not found.
23734
       */
23735
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23736
        _Fields fields = findByThriftId(fieldId);
23737
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23738
        return fields;
23739
      }
23740
 
23741
      /**
23742
       * Find the _Fields constant that matches name, or null if its not found.
23743
       */
23744
      public static _Fields findByName(String name) {
23745
        return byName.get(name);
23746
      }
23747
 
23748
      private final short _thriftId;
23749
      private final String _fieldName;
23750
 
23751
      _Fields(short thriftId, String fieldName) {
23752
        _thriftId = thriftId;
23753
        _fieldName = fieldName;
23754
      }
23755
 
23756
      public short getThriftFieldId() {
23757
        return _thriftId;
23758
      }
23759
 
23760
      public String getFieldName() {
23761
        return _fieldName;
23762
      }
23763
    }
23764
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23765
    static {
23766
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23767
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23768
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getIgnoredItemKeys_args.class, metaDataMap);
23769
    }
23770
 
23771
    public getIgnoredItemKeys_args() {
23772
    }
23773
 
23774
    /**
23775
     * Performs a deep copy on <i>other</i>.
23776
     */
23777
    public getIgnoredItemKeys_args(getIgnoredItemKeys_args other) {
23778
    }
23779
 
23780
    public getIgnoredItemKeys_args deepCopy() {
23781
      return new getIgnoredItemKeys_args(this);
23782
    }
23783
 
23784
    @Override
23785
    public void clear() {
23786
    }
23787
 
23788
    public void setFieldValue(_Fields field, Object value) {
23789
      switch (field) {
23790
      }
23791
    }
23792
 
23793
    public Object getFieldValue(_Fields field) {
23794
      switch (field) {
23795
      }
23796
      throw new IllegalStateException();
23797
    }
23798
 
23799
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23800
    public boolean isSet(_Fields field) {
23801
      if (field == null) {
23802
        throw new IllegalArgumentException();
23803
      }
23804
 
23805
      switch (field) {
23806
      }
23807
      throw new IllegalStateException();
23808
    }
23809
 
23810
    @Override
23811
    public boolean equals(Object that) {
23812
      if (that == null)
23813
        return false;
23814
      if (that instanceof getIgnoredItemKeys_args)
23815
        return this.equals((getIgnoredItemKeys_args)that);
23816
      return false;
23817
    }
23818
 
23819
    public boolean equals(getIgnoredItemKeys_args that) {
23820
      if (that == null)
23821
        return false;
23822
 
23823
      return true;
23824
    }
23825
 
23826
    @Override
23827
    public int hashCode() {
23828
      return 0;
23829
    }
23830
 
23831
    public int compareTo(getIgnoredItemKeys_args other) {
23832
      if (!getClass().equals(other.getClass())) {
23833
        return getClass().getName().compareTo(other.getClass().getName());
23834
      }
23835
 
23836
      int lastComparison = 0;
23837
      getIgnoredItemKeys_args typedOther = (getIgnoredItemKeys_args)other;
23838
 
23839
      return 0;
23840
    }
23841
 
23842
    public _Fields fieldForId(int fieldId) {
23843
      return _Fields.findByThriftId(fieldId);
23844
    }
23845
 
23846
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23847
      org.apache.thrift.protocol.TField field;
23848
      iprot.readStructBegin();
23849
      while (true)
23850
      {
23851
        field = iprot.readFieldBegin();
23852
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23853
          break;
23854
        }
23855
        switch (field.id) {
23856
          default:
23857
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23858
        }
23859
        iprot.readFieldEnd();
23860
      }
23861
      iprot.readStructEnd();
23862
      validate();
23863
    }
23864
 
23865
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23866
      validate();
23867
 
23868
      oprot.writeStructBegin(STRUCT_DESC);
23869
      oprot.writeFieldStop();
23870
      oprot.writeStructEnd();
23871
    }
23872
 
23873
    @Override
23874
    public String toString() {
23875
      StringBuilder sb = new StringBuilder("getIgnoredItemKeys_args(");
23876
      boolean first = true;
23877
 
23878
      sb.append(")");
23879
      return sb.toString();
23880
    }
23881
 
23882
    public void validate() throws org.apache.thrift.TException {
23883
      // check for required fields
23884
    }
23885
 
23886
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23887
      try {
23888
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23889
      } catch (org.apache.thrift.TException te) {
23890
        throw new java.io.IOException(te);
23891
      }
23892
    }
23893
 
23894
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23895
      try {
23896
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23897
      } catch (org.apache.thrift.TException te) {
23898
        throw new java.io.IOException(te);
23899
      }
23900
    }
23901
 
23902
  }
23903
 
23904
  public static class getIgnoredItemKeys_result implements org.apache.thrift.TBase<getIgnoredItemKeys_result, getIgnoredItemKeys_result._Fields>, java.io.Serializable, Cloneable   {
23905
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getIgnoredItemKeys_result");
23906
 
23907
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.MAP, (short)0);
23908
 
23909
    private Map<String,Map<Long,Long>> success; // required
23910
 
23911
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23912
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23913
      SUCCESS((short)0, "success");
23914
 
23915
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23916
 
23917
      static {
23918
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23919
          byName.put(field.getFieldName(), field);
23920
        }
23921
      }
23922
 
23923
      /**
23924
       * Find the _Fields constant that matches fieldId, or null if its not found.
23925
       */
23926
      public static _Fields findByThriftId(int fieldId) {
23927
        switch(fieldId) {
23928
          case 0: // SUCCESS
23929
            return SUCCESS;
23930
          default:
23931
            return null;
23932
        }
23933
      }
23934
 
23935
      /**
23936
       * Find the _Fields constant that matches fieldId, throwing an exception
23937
       * if it is not found.
23938
       */
23939
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23940
        _Fields fields = findByThriftId(fieldId);
23941
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23942
        return fields;
23943
      }
23944
 
23945
      /**
23946
       * Find the _Fields constant that matches name, or null if its not found.
23947
       */
23948
      public static _Fields findByName(String name) {
23949
        return byName.get(name);
23950
      }
23951
 
23952
      private final short _thriftId;
23953
      private final String _fieldName;
23954
 
23955
      _Fields(short thriftId, String fieldName) {
23956
        _thriftId = thriftId;
23957
        _fieldName = fieldName;
23958
      }
23959
 
23960
      public short getThriftFieldId() {
23961
        return _thriftId;
23962
      }
23963
 
23964
      public String getFieldName() {
23965
        return _fieldName;
23966
      }
23967
    }
23968
 
23969
    // isset id assignments
23970
 
23971
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23972
    static {
23973
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23974
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23975
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
23976
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
23977
              new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
23978
                  new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
23979
                  new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)))));
23980
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23981
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getIgnoredItemKeys_result.class, metaDataMap);
23982
    }
23983
 
23984
    public getIgnoredItemKeys_result() {
23985
    }
23986
 
23987
    public getIgnoredItemKeys_result(
23988
      Map<String,Map<Long,Long>> success)
23989
    {
23990
      this();
23991
      this.success = success;
23992
    }
23993
 
23994
    /**
23995
     * Performs a deep copy on <i>other</i>.
23996
     */
23997
    public getIgnoredItemKeys_result(getIgnoredItemKeys_result other) {
23998
      if (other.isSetSuccess()) {
23999
        Map<String,Map<Long,Long>> __this__success = new HashMap<String,Map<Long,Long>>();
24000
        for (Map.Entry<String, Map<Long,Long>> other_element : other.success.entrySet()) {
24001
 
24002
          String other_element_key = other_element.getKey();
24003
          Map<Long,Long> other_element_value = other_element.getValue();
24004
 
24005
          String __this__success_copy_key = other_element_key;
24006
 
24007
          Map<Long,Long> __this__success_copy_value = new HashMap<Long,Long>();
24008
          for (Map.Entry<Long, Long> other_element_value_element : other_element_value.entrySet()) {
24009
 
24010
            Long other_element_value_element_key = other_element_value_element.getKey();
24011
            Long other_element_value_element_value = other_element_value_element.getValue();
24012
 
24013
            Long __this__success_copy_value_copy_key = other_element_value_element_key;
24014
 
24015
            Long __this__success_copy_value_copy_value = other_element_value_element_value;
24016
 
24017
            __this__success_copy_value.put(__this__success_copy_value_copy_key, __this__success_copy_value_copy_value);
24018
          }
24019
 
24020
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
24021
        }
24022
        this.success = __this__success;
24023
      }
24024
    }
24025
 
24026
    public getIgnoredItemKeys_result deepCopy() {
24027
      return new getIgnoredItemKeys_result(this);
24028
    }
24029
 
24030
    @Override
24031
    public void clear() {
24032
      this.success = null;
24033
    }
24034
 
24035
    public int getSuccessSize() {
24036
      return (this.success == null) ? 0 : this.success.size();
24037
    }
24038
 
24039
    public void putToSuccess(String key, Map<Long,Long> val) {
24040
      if (this.success == null) {
24041
        this.success = new HashMap<String,Map<Long,Long>>();
24042
      }
24043
      this.success.put(key, val);
24044
    }
24045
 
24046
    public Map<String,Map<Long,Long>> getSuccess() {
24047
      return this.success;
24048
    }
24049
 
24050
    public void setSuccess(Map<String,Map<Long,Long>> success) {
24051
      this.success = success;
24052
    }
24053
 
24054
    public void unsetSuccess() {
24055
      this.success = null;
24056
    }
24057
 
24058
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
24059
    public boolean isSetSuccess() {
24060
      return this.success != null;
24061
    }
24062
 
24063
    public void setSuccessIsSet(boolean value) {
24064
      if (!value) {
24065
        this.success = null;
24066
      }
24067
    }
24068
 
24069
    public void setFieldValue(_Fields field, Object value) {
24070
      switch (field) {
24071
      case SUCCESS:
24072
        if (value == null) {
24073
          unsetSuccess();
24074
        } else {
24075
          setSuccess((Map<String,Map<Long,Long>>)value);
24076
        }
24077
        break;
24078
 
24079
      }
24080
    }
24081
 
24082
    public Object getFieldValue(_Fields field) {
24083
      switch (field) {
24084
      case SUCCESS:
24085
        return getSuccess();
24086
 
24087
      }
24088
      throw new IllegalStateException();
24089
    }
24090
 
24091
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24092
    public boolean isSet(_Fields field) {
24093
      if (field == null) {
24094
        throw new IllegalArgumentException();
24095
      }
24096
 
24097
      switch (field) {
24098
      case SUCCESS:
24099
        return isSetSuccess();
24100
      }
24101
      throw new IllegalStateException();
24102
    }
24103
 
24104
    @Override
24105
    public boolean equals(Object that) {
24106
      if (that == null)
24107
        return false;
24108
      if (that instanceof getIgnoredItemKeys_result)
24109
        return this.equals((getIgnoredItemKeys_result)that);
24110
      return false;
24111
    }
24112
 
24113
    public boolean equals(getIgnoredItemKeys_result that) {
24114
      if (that == null)
24115
        return false;
24116
 
24117
      boolean this_present_success = true && this.isSetSuccess();
24118
      boolean that_present_success = true && that.isSetSuccess();
24119
      if (this_present_success || that_present_success) {
24120
        if (!(this_present_success && that_present_success))
24121
          return false;
24122
        if (!this.success.equals(that.success))
24123
          return false;
24124
      }
24125
 
24126
      return true;
24127
    }
24128
 
24129
    @Override
24130
    public int hashCode() {
24131
      return 0;
24132
    }
24133
 
24134
    public int compareTo(getIgnoredItemKeys_result other) {
24135
      if (!getClass().equals(other.getClass())) {
24136
        return getClass().getName().compareTo(other.getClass().getName());
24137
      }
24138
 
24139
      int lastComparison = 0;
24140
      getIgnoredItemKeys_result typedOther = (getIgnoredItemKeys_result)other;
24141
 
24142
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
24143
      if (lastComparison != 0) {
24144
        return lastComparison;
24145
      }
24146
      if (isSetSuccess()) {
24147
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
24148
        if (lastComparison != 0) {
24149
          return lastComparison;
24150
        }
24151
      }
24152
      return 0;
24153
    }
24154
 
24155
    public _Fields fieldForId(int fieldId) {
24156
      return _Fields.findByThriftId(fieldId);
24157
    }
24158
 
24159
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24160
      org.apache.thrift.protocol.TField field;
24161
      iprot.readStructBegin();
24162
      while (true)
24163
      {
24164
        field = iprot.readFieldBegin();
24165
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24166
          break;
24167
        }
24168
        switch (field.id) {
24169
          case 0: // SUCCESS
24170
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
24171
              {
24172
                org.apache.thrift.protocol.TMap _map56 = iprot.readMapBegin();
24173
                this.success = new HashMap<String,Map<Long,Long>>(2*_map56.size);
24174
                for (int _i57 = 0; _i57 < _map56.size; ++_i57)
24175
                {
24176
                  String _key58; // required
24177
                  Map<Long,Long> _val59; // required
24178
                  _key58 = iprot.readString();
24179
                  {
24180
                    org.apache.thrift.protocol.TMap _map60 = iprot.readMapBegin();
24181
                    _val59 = new HashMap<Long,Long>(2*_map60.size);
24182
                    for (int _i61 = 0; _i61 < _map60.size; ++_i61)
24183
                    {
24184
                      long _key62; // required
24185
                      long _val63; // required
24186
                      _key62 = iprot.readI64();
24187
                      _val63 = iprot.readI64();
24188
                      _val59.put(_key62, _val63);
24189
                    }
24190
                    iprot.readMapEnd();
24191
                  }
24192
                  this.success.put(_key58, _val59);
24193
                }
24194
                iprot.readMapEnd();
24195
              }
24196
            } else { 
24197
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24198
            }
24199
            break;
24200
          default:
24201
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24202
        }
24203
        iprot.readFieldEnd();
24204
      }
24205
      iprot.readStructEnd();
24206
      validate();
24207
    }
24208
 
24209
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24210
      oprot.writeStructBegin(STRUCT_DESC);
24211
 
24212
      if (this.isSetSuccess()) {
24213
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
24214
        {
24215
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.MAP, this.success.size()));
24216
          for (Map.Entry<String, Map<Long,Long>> _iter64 : this.success.entrySet())
24217
          {
24218
            oprot.writeString(_iter64.getKey());
24219
            {
24220
              oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.I64, _iter64.getValue().size()));
24221
              for (Map.Entry<Long, Long> _iter65 : _iter64.getValue().entrySet())
24222
              {
24223
                oprot.writeI64(_iter65.getKey());
24224
                oprot.writeI64(_iter65.getValue());
24225
              }
24226
              oprot.writeMapEnd();
24227
            }
24228
          }
24229
          oprot.writeMapEnd();
24230
        }
24231
        oprot.writeFieldEnd();
24232
      }
24233
      oprot.writeFieldStop();
24234
      oprot.writeStructEnd();
24235
    }
24236
 
24237
    @Override
24238
    public String toString() {
24239
      StringBuilder sb = new StringBuilder("getIgnoredItemKeys_result(");
24240
      boolean first = true;
24241
 
24242
      sb.append("success:");
24243
      if (this.success == null) {
24244
        sb.append("null");
24245
      } else {
24246
        sb.append(this.success);
24247
      }
24248
      first = false;
24249
      sb.append(")");
24250
      return sb.toString();
24251
    }
24252
 
24253
    public void validate() throws org.apache.thrift.TException {
24254
      // check for required fields
24255
    }
24256
 
24257
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24258
      try {
24259
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24260
      } catch (org.apache.thrift.TException te) {
24261
        throw new java.io.IOException(te);
24262
      }
24263
    }
24264
 
24265
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24266
      try {
24267
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24268
      } catch (org.apache.thrift.TException te) {
24269
        throw new java.io.IOException(te);
24270
      }
24271
    }
24272
 
24273
  }
24274
 
24275
  public static class addBadInventory_args implements org.apache.thrift.TBase<addBadInventory_args, addBadInventory_args._Fields>, java.io.Serializable, Cloneable   {
24276
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addBadInventory_args");
24277
 
24278
    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);
24279
    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)2);
24280
    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);
24281
 
24282
    private long itemId; // required
24283
    private long warehouseId; // required
24284
    private long quantity; // required
24285
 
24286
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24287
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24288
      ITEM_ID((short)1, "itemId"),
24289
      WAREHOUSE_ID((short)2, "warehouseId"),
24290
      QUANTITY((short)3, "quantity");
24291
 
24292
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24293
 
24294
      static {
24295
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24296
          byName.put(field.getFieldName(), field);
24297
        }
24298
      }
24299
 
24300
      /**
24301
       * Find the _Fields constant that matches fieldId, or null if its not found.
24302
       */
24303
      public static _Fields findByThriftId(int fieldId) {
24304
        switch(fieldId) {
24305
          case 1: // ITEM_ID
24306
            return ITEM_ID;
24307
          case 2: // WAREHOUSE_ID
24308
            return WAREHOUSE_ID;
24309
          case 3: // QUANTITY
24310
            return QUANTITY;
24311
          default:
24312
            return null;
24313
        }
24314
      }
24315
 
24316
      /**
24317
       * Find the _Fields constant that matches fieldId, throwing an exception
24318
       * if it is not found.
24319
       */
24320
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24321
        _Fields fields = findByThriftId(fieldId);
24322
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24323
        return fields;
24324
      }
24325
 
24326
      /**
24327
       * Find the _Fields constant that matches name, or null if its not found.
24328
       */
24329
      public static _Fields findByName(String name) {
24330
        return byName.get(name);
24331
      }
24332
 
24333
      private final short _thriftId;
24334
      private final String _fieldName;
24335
 
24336
      _Fields(short thriftId, String fieldName) {
24337
        _thriftId = thriftId;
24338
        _fieldName = fieldName;
24339
      }
24340
 
24341
      public short getThriftFieldId() {
24342
        return _thriftId;
24343
      }
24344
 
24345
      public String getFieldName() {
24346
        return _fieldName;
24347
      }
24348
    }
24349
 
24350
    // isset id assignments
24351
    private static final int __ITEMID_ISSET_ID = 0;
24352
    private static final int __WAREHOUSEID_ISSET_ID = 1;
24353
    private static final int __QUANTITY_ISSET_ID = 2;
24354
    private BitSet __isset_bit_vector = new BitSet(3);
24355
 
24356
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24357
    static {
24358
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24359
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24360
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24361
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24362
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24363
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24364
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24365
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24366
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addBadInventory_args.class, metaDataMap);
24367
    }
24368
 
24369
    public addBadInventory_args() {
24370
    }
24371
 
24372
    public addBadInventory_args(
24373
      long itemId,
24374
      long warehouseId,
24375
      long quantity)
24376
    {
24377
      this();
24378
      this.itemId = itemId;
24379
      setItemIdIsSet(true);
24380
      this.warehouseId = warehouseId;
24381
      setWarehouseIdIsSet(true);
24382
      this.quantity = quantity;
24383
      setQuantityIsSet(true);
24384
    }
24385
 
24386
    /**
24387
     * Performs a deep copy on <i>other</i>.
24388
     */
24389
    public addBadInventory_args(addBadInventory_args other) {
24390
      __isset_bit_vector.clear();
24391
      __isset_bit_vector.or(other.__isset_bit_vector);
24392
      this.itemId = other.itemId;
24393
      this.warehouseId = other.warehouseId;
24394
      this.quantity = other.quantity;
24395
    }
24396
 
24397
    public addBadInventory_args deepCopy() {
24398
      return new addBadInventory_args(this);
24399
    }
24400
 
24401
    @Override
24402
    public void clear() {
24403
      setItemIdIsSet(false);
24404
      this.itemId = 0;
24405
      setWarehouseIdIsSet(false);
24406
      this.warehouseId = 0;
24407
      setQuantityIsSet(false);
24408
      this.quantity = 0;
24409
    }
24410
 
24411
    public long getItemId() {
24412
      return this.itemId;
24413
    }
24414
 
24415
    public void setItemId(long itemId) {
24416
      this.itemId = itemId;
24417
      setItemIdIsSet(true);
24418
    }
24419
 
24420
    public void unsetItemId() {
24421
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
24422
    }
24423
 
24424
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
24425
    public boolean isSetItemId() {
24426
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
24427
    }
24428
 
24429
    public void setItemIdIsSet(boolean value) {
24430
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
24431
    }
24432
 
24433
    public long getWarehouseId() {
24434
      return this.warehouseId;
24435
    }
24436
 
24437
    public void setWarehouseId(long warehouseId) {
24438
      this.warehouseId = warehouseId;
24439
      setWarehouseIdIsSet(true);
24440
    }
24441
 
24442
    public void unsetWarehouseId() {
24443
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
24444
    }
24445
 
24446
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
24447
    public boolean isSetWarehouseId() {
24448
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
24449
    }
24450
 
24451
    public void setWarehouseIdIsSet(boolean value) {
24452
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
24453
    }
24454
 
24455
    public long getQuantity() {
24456
      return this.quantity;
24457
    }
24458
 
24459
    public void setQuantity(long quantity) {
24460
      this.quantity = quantity;
24461
      setQuantityIsSet(true);
24462
    }
24463
 
24464
    public void unsetQuantity() {
24465
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
24466
    }
24467
 
24468
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
24469
    public boolean isSetQuantity() {
24470
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
24471
    }
24472
 
24473
    public void setQuantityIsSet(boolean value) {
24474
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
24475
    }
24476
 
24477
    public void setFieldValue(_Fields field, Object value) {
24478
      switch (field) {
24479
      case ITEM_ID:
24480
        if (value == null) {
24481
          unsetItemId();
24482
        } else {
24483
          setItemId((Long)value);
24484
        }
24485
        break;
24486
 
24487
      case WAREHOUSE_ID:
24488
        if (value == null) {
24489
          unsetWarehouseId();
24490
        } else {
24491
          setWarehouseId((Long)value);
24492
        }
24493
        break;
24494
 
24495
      case QUANTITY:
24496
        if (value == null) {
24497
          unsetQuantity();
24498
        } else {
24499
          setQuantity((Long)value);
24500
        }
24501
        break;
24502
 
24503
      }
24504
    }
24505
 
24506
    public Object getFieldValue(_Fields field) {
24507
      switch (field) {
24508
      case ITEM_ID:
24509
        return Long.valueOf(getItemId());
24510
 
24511
      case WAREHOUSE_ID:
24512
        return Long.valueOf(getWarehouseId());
24513
 
24514
      case QUANTITY:
24515
        return Long.valueOf(getQuantity());
24516
 
24517
      }
24518
      throw new IllegalStateException();
24519
    }
24520
 
24521
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24522
    public boolean isSet(_Fields field) {
24523
      if (field == null) {
24524
        throw new IllegalArgumentException();
24525
      }
24526
 
24527
      switch (field) {
24528
      case ITEM_ID:
24529
        return isSetItemId();
24530
      case WAREHOUSE_ID:
24531
        return isSetWarehouseId();
24532
      case QUANTITY:
24533
        return isSetQuantity();
24534
      }
24535
      throw new IllegalStateException();
24536
    }
24537
 
24538
    @Override
24539
    public boolean equals(Object that) {
24540
      if (that == null)
24541
        return false;
24542
      if (that instanceof addBadInventory_args)
24543
        return this.equals((addBadInventory_args)that);
24544
      return false;
24545
    }
24546
 
24547
    public boolean equals(addBadInventory_args that) {
24548
      if (that == null)
24549
        return false;
24550
 
24551
      boolean this_present_itemId = true;
24552
      boolean that_present_itemId = true;
24553
      if (this_present_itemId || that_present_itemId) {
24554
        if (!(this_present_itemId && that_present_itemId))
24555
          return false;
24556
        if (this.itemId != that.itemId)
24557
          return false;
24558
      }
24559
 
24560
      boolean this_present_warehouseId = true;
24561
      boolean that_present_warehouseId = true;
24562
      if (this_present_warehouseId || that_present_warehouseId) {
24563
        if (!(this_present_warehouseId && that_present_warehouseId))
24564
          return false;
24565
        if (this.warehouseId != that.warehouseId)
24566
          return false;
24567
      }
24568
 
24569
      boolean this_present_quantity = true;
24570
      boolean that_present_quantity = true;
24571
      if (this_present_quantity || that_present_quantity) {
24572
        if (!(this_present_quantity && that_present_quantity))
24573
          return false;
24574
        if (this.quantity != that.quantity)
24575
          return false;
24576
      }
24577
 
24578
      return true;
24579
    }
24580
 
24581
    @Override
24582
    public int hashCode() {
24583
      return 0;
24584
    }
24585
 
24586
    public int compareTo(addBadInventory_args other) {
24587
      if (!getClass().equals(other.getClass())) {
24588
        return getClass().getName().compareTo(other.getClass().getName());
24589
      }
24590
 
24591
      int lastComparison = 0;
24592
      addBadInventory_args typedOther = (addBadInventory_args)other;
24593
 
24594
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
24595
      if (lastComparison != 0) {
24596
        return lastComparison;
24597
      }
24598
      if (isSetItemId()) {
24599
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
24600
        if (lastComparison != 0) {
24601
          return lastComparison;
24602
        }
24603
      }
24604
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
24605
      if (lastComparison != 0) {
24606
        return lastComparison;
24607
      }
24608
      if (isSetWarehouseId()) {
24609
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
24610
        if (lastComparison != 0) {
24611
          return lastComparison;
24612
        }
24613
      }
24614
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
24615
      if (lastComparison != 0) {
24616
        return lastComparison;
24617
      }
24618
      if (isSetQuantity()) {
24619
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
24620
        if (lastComparison != 0) {
24621
          return lastComparison;
24622
        }
24623
      }
24624
      return 0;
24625
    }
24626
 
24627
    public _Fields fieldForId(int fieldId) {
24628
      return _Fields.findByThriftId(fieldId);
24629
    }
24630
 
24631
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24632
      org.apache.thrift.protocol.TField field;
24633
      iprot.readStructBegin();
24634
      while (true)
24635
      {
24636
        field = iprot.readFieldBegin();
24637
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24638
          break;
24639
        }
24640
        switch (field.id) {
24641
          case 1: // ITEM_ID
24642
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24643
              this.itemId = iprot.readI64();
24644
              setItemIdIsSet(true);
24645
            } else { 
24646
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24647
            }
24648
            break;
24649
          case 2: // WAREHOUSE_ID
24650
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24651
              this.warehouseId = iprot.readI64();
24652
              setWarehouseIdIsSet(true);
24653
            } else { 
24654
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24655
            }
24656
            break;
24657
          case 3: // QUANTITY
24658
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24659
              this.quantity = iprot.readI64();
24660
              setQuantityIsSet(true);
24661
            } else { 
24662
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24663
            }
24664
            break;
24665
          default:
24666
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24667
        }
24668
        iprot.readFieldEnd();
24669
      }
24670
      iprot.readStructEnd();
24671
      validate();
24672
    }
24673
 
24674
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24675
      validate();
24676
 
24677
      oprot.writeStructBegin(STRUCT_DESC);
24678
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
24679
      oprot.writeI64(this.itemId);
24680
      oprot.writeFieldEnd();
24681
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
24682
      oprot.writeI64(this.warehouseId);
24683
      oprot.writeFieldEnd();
24684
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
24685
      oprot.writeI64(this.quantity);
24686
      oprot.writeFieldEnd();
24687
      oprot.writeFieldStop();
24688
      oprot.writeStructEnd();
24689
    }
24690
 
24691
    @Override
24692
    public String toString() {
24693
      StringBuilder sb = new StringBuilder("addBadInventory_args(");
24694
      boolean first = true;
24695
 
24696
      sb.append("itemId:");
24697
      sb.append(this.itemId);
24698
      first = false;
24699
      if (!first) sb.append(", ");
24700
      sb.append("warehouseId:");
24701
      sb.append(this.warehouseId);
24702
      first = false;
24703
      if (!first) sb.append(", ");
24704
      sb.append("quantity:");
24705
      sb.append(this.quantity);
24706
      first = false;
24707
      sb.append(")");
24708
      return sb.toString();
24709
    }
24710
 
24711
    public void validate() throws org.apache.thrift.TException {
24712
      // check for required fields
24713
    }
24714
 
24715
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24716
      try {
24717
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24718
      } catch (org.apache.thrift.TException te) {
24719
        throw new java.io.IOException(te);
24720
      }
24721
    }
24722
 
24723
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24724
      try {
24725
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
24726
        __isset_bit_vector = new BitSet(1);
24727
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24728
      } catch (org.apache.thrift.TException te) {
24729
        throw new java.io.IOException(te);
24730
      }
24731
    }
24732
 
24733
  }
24734
 
24735
  public static class addBadInventory_result implements org.apache.thrift.TBase<addBadInventory_result, addBadInventory_result._Fields>, java.io.Serializable, Cloneable   {
24736
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addBadInventory_result");
24737
 
24738
    private static final org.apache.thrift.protocol.TField CEX_FIELD_DESC = new org.apache.thrift.protocol.TField("cex", org.apache.thrift.protocol.TType.STRUCT, (short)1);
24739
 
24740
    private InventoryServiceException cex; // required
24741
 
24742
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24743
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24744
      CEX((short)1, "cex");
24745
 
24746
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24747
 
24748
      static {
24749
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24750
          byName.put(field.getFieldName(), field);
24751
        }
24752
      }
24753
 
24754
      /**
24755
       * Find the _Fields constant that matches fieldId, or null if its not found.
24756
       */
24757
      public static _Fields findByThriftId(int fieldId) {
24758
        switch(fieldId) {
24759
          case 1: // CEX
24760
            return CEX;
24761
          default:
24762
            return null;
24763
        }
24764
      }
24765
 
24766
      /**
24767
       * Find the _Fields constant that matches fieldId, throwing an exception
24768
       * if it is not found.
24769
       */
24770
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24771
        _Fields fields = findByThriftId(fieldId);
24772
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24773
        return fields;
24774
      }
24775
 
24776
      /**
24777
       * Find the _Fields constant that matches name, or null if its not found.
24778
       */
24779
      public static _Fields findByName(String name) {
24780
        return byName.get(name);
24781
      }
24782
 
24783
      private final short _thriftId;
24784
      private final String _fieldName;
24785
 
24786
      _Fields(short thriftId, String fieldName) {
24787
        _thriftId = thriftId;
24788
        _fieldName = fieldName;
24789
      }
24790
 
24791
      public short getThriftFieldId() {
24792
        return _thriftId;
24793
      }
24794
 
24795
      public String getFieldName() {
24796
        return _fieldName;
24797
      }
24798
    }
24799
 
24800
    // isset id assignments
24801
 
24802
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24803
    static {
24804
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24805
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24806
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
24807
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24808
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addBadInventory_result.class, metaDataMap);
24809
    }
24810
 
24811
    public addBadInventory_result() {
24812
    }
24813
 
24814
    public addBadInventory_result(
24815
      InventoryServiceException cex)
24816
    {
24817
      this();
24818
      this.cex = cex;
24819
    }
24820
 
24821
    /**
24822
     * Performs a deep copy on <i>other</i>.
24823
     */
24824
    public addBadInventory_result(addBadInventory_result other) {
24825
      if (other.isSetCex()) {
24826
        this.cex = new InventoryServiceException(other.cex);
24827
      }
24828
    }
24829
 
24830
    public addBadInventory_result deepCopy() {
24831
      return new addBadInventory_result(this);
24832
    }
24833
 
24834
    @Override
24835
    public void clear() {
24836
      this.cex = null;
24837
    }
24838
 
24839
    public InventoryServiceException getCex() {
24840
      return this.cex;
24841
    }
24842
 
24843
    public void setCex(InventoryServiceException cex) {
24844
      this.cex = cex;
24845
    }
24846
 
24847
    public void unsetCex() {
24848
      this.cex = null;
24849
    }
24850
 
24851
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
24852
    public boolean isSetCex() {
24853
      return this.cex != null;
24854
    }
24855
 
24856
    public void setCexIsSet(boolean value) {
24857
      if (!value) {
24858
        this.cex = null;
24859
      }
24860
    }
24861
 
24862
    public void setFieldValue(_Fields field, Object value) {
24863
      switch (field) {
24864
      case CEX:
24865
        if (value == null) {
24866
          unsetCex();
24867
        } else {
24868
          setCex((InventoryServiceException)value);
24869
        }
24870
        break;
24871
 
24872
      }
24873
    }
24874
 
24875
    public Object getFieldValue(_Fields field) {
24876
      switch (field) {
24877
      case CEX:
24878
        return getCex();
24879
 
24880
      }
24881
      throw new IllegalStateException();
24882
    }
24883
 
24884
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24885
    public boolean isSet(_Fields field) {
24886
      if (field == null) {
24887
        throw new IllegalArgumentException();
24888
      }
24889
 
24890
      switch (field) {
24891
      case CEX:
24892
        return isSetCex();
24893
      }
24894
      throw new IllegalStateException();
24895
    }
24896
 
24897
    @Override
24898
    public boolean equals(Object that) {
24899
      if (that == null)
24900
        return false;
24901
      if (that instanceof addBadInventory_result)
24902
        return this.equals((addBadInventory_result)that);
24903
      return false;
24904
    }
24905
 
24906
    public boolean equals(addBadInventory_result that) {
24907
      if (that == null)
24908
        return false;
24909
 
24910
      boolean this_present_cex = true && this.isSetCex();
24911
      boolean that_present_cex = true && that.isSetCex();
24912
      if (this_present_cex || that_present_cex) {
24913
        if (!(this_present_cex && that_present_cex))
24914
          return false;
24915
        if (!this.cex.equals(that.cex))
24916
          return false;
24917
      }
24918
 
24919
      return true;
24920
    }
24921
 
24922
    @Override
24923
    public int hashCode() {
24924
      return 0;
24925
    }
24926
 
24927
    public int compareTo(addBadInventory_result other) {
24928
      if (!getClass().equals(other.getClass())) {
24929
        return getClass().getName().compareTo(other.getClass().getName());
24930
      }
24931
 
24932
      int lastComparison = 0;
24933
      addBadInventory_result typedOther = (addBadInventory_result)other;
24934
 
24935
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
24936
      if (lastComparison != 0) {
24937
        return lastComparison;
24938
      }
24939
      if (isSetCex()) {
24940
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
24941
        if (lastComparison != 0) {
24942
          return lastComparison;
24943
        }
24944
      }
24945
      return 0;
24946
    }
24947
 
24948
    public _Fields fieldForId(int fieldId) {
24949
      return _Fields.findByThriftId(fieldId);
24950
    }
24951
 
24952
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24953
      org.apache.thrift.protocol.TField field;
24954
      iprot.readStructBegin();
24955
      while (true)
24956
      {
24957
        field = iprot.readFieldBegin();
24958
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24959
          break;
24960
        }
24961
        switch (field.id) {
24962
          case 1: // CEX
24963
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
24964
              this.cex = new InventoryServiceException();
24965
              this.cex.read(iprot);
24966
            } else { 
24967
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24968
            }
24969
            break;
24970
          default:
24971
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24972
        }
24973
        iprot.readFieldEnd();
24974
      }
24975
      iprot.readStructEnd();
24976
      validate();
24977
    }
24978
 
24979
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24980
      oprot.writeStructBegin(STRUCT_DESC);
24981
 
24982
      if (this.isSetCex()) {
24983
        oprot.writeFieldBegin(CEX_FIELD_DESC);
24984
        this.cex.write(oprot);
24985
        oprot.writeFieldEnd();
24986
      }
24987
      oprot.writeFieldStop();
24988
      oprot.writeStructEnd();
24989
    }
24990
 
24991
    @Override
24992
    public String toString() {
24993
      StringBuilder sb = new StringBuilder("addBadInventory_result(");
24994
      boolean first = true;
24995
 
24996
      sb.append("cex:");
24997
      if (this.cex == null) {
24998
        sb.append("null");
24999
      } else {
25000
        sb.append(this.cex);
25001
      }
25002
      first = false;
25003
      sb.append(")");
25004
      return sb.toString();
25005
    }
25006
 
25007
    public void validate() throws org.apache.thrift.TException {
25008
      // check for required fields
25009
    }
25010
 
25011
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25012
      try {
25013
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25014
      } catch (org.apache.thrift.TException te) {
25015
        throw new java.io.IOException(te);
25016
      }
25017
    }
25018
 
25019
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25020
      try {
25021
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25022
      } catch (org.apache.thrift.TException te) {
25023
        throw new java.io.IOException(te);
25024
      }
25025
    }
25026
 
25027
  }
25028
 
25029
  public static class getShippingLocations_args implements org.apache.thrift.TBase<getShippingLocations_args, getShippingLocations_args._Fields>, java.io.Serializable, Cloneable   {
25030
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShippingLocations_args");
25031
 
25032
 
25033
 
25034
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25035
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25036
;
25037
 
25038
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25039
 
25040
      static {
25041
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25042
          byName.put(field.getFieldName(), field);
25043
        }
25044
      }
25045
 
25046
      /**
25047
       * Find the _Fields constant that matches fieldId, or null if its not found.
25048
       */
25049
      public static _Fields findByThriftId(int fieldId) {
25050
        switch(fieldId) {
25051
          default:
25052
            return null;
25053
        }
25054
      }
25055
 
25056
      /**
25057
       * Find the _Fields constant that matches fieldId, throwing an exception
25058
       * if it is not found.
25059
       */
25060
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25061
        _Fields fields = findByThriftId(fieldId);
25062
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25063
        return fields;
25064
      }
25065
 
25066
      /**
25067
       * Find the _Fields constant that matches name, or null if its not found.
25068
       */
25069
      public static _Fields findByName(String name) {
25070
        return byName.get(name);
25071
      }
25072
 
25073
      private final short _thriftId;
25074
      private final String _fieldName;
25075
 
25076
      _Fields(short thriftId, String fieldName) {
25077
        _thriftId = thriftId;
25078
        _fieldName = fieldName;
25079
      }
25080
 
25081
      public short getThriftFieldId() {
25082
        return _thriftId;
25083
      }
25084
 
25085
      public String getFieldName() {
25086
        return _fieldName;
25087
      }
25088
    }
25089
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25090
    static {
25091
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25092
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25093
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShippingLocations_args.class, metaDataMap);
25094
    }
25095
 
25096
    public getShippingLocations_args() {
25097
    }
25098
 
25099
    /**
25100
     * Performs a deep copy on <i>other</i>.
25101
     */
25102
    public getShippingLocations_args(getShippingLocations_args other) {
25103
    }
25104
 
25105
    public getShippingLocations_args deepCopy() {
25106
      return new getShippingLocations_args(this);
25107
    }
25108
 
25109
    @Override
25110
    public void clear() {
25111
    }
25112
 
25113
    public void setFieldValue(_Fields field, Object value) {
25114
      switch (field) {
25115
      }
25116
    }
25117
 
25118
    public Object getFieldValue(_Fields field) {
25119
      switch (field) {
25120
      }
25121
      throw new IllegalStateException();
25122
    }
25123
 
25124
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25125
    public boolean isSet(_Fields field) {
25126
      if (field == null) {
25127
        throw new IllegalArgumentException();
25128
      }
25129
 
25130
      switch (field) {
25131
      }
25132
      throw new IllegalStateException();
25133
    }
25134
 
25135
    @Override
25136
    public boolean equals(Object that) {
25137
      if (that == null)
25138
        return false;
25139
      if (that instanceof getShippingLocations_args)
25140
        return this.equals((getShippingLocations_args)that);
25141
      return false;
25142
    }
25143
 
25144
    public boolean equals(getShippingLocations_args that) {
25145
      if (that == null)
25146
        return false;
25147
 
25148
      return true;
25149
    }
25150
 
25151
    @Override
25152
    public int hashCode() {
25153
      return 0;
25154
    }
25155
 
25156
    public int compareTo(getShippingLocations_args other) {
25157
      if (!getClass().equals(other.getClass())) {
25158
        return getClass().getName().compareTo(other.getClass().getName());
25159
      }
25160
 
25161
      int lastComparison = 0;
25162
      getShippingLocations_args typedOther = (getShippingLocations_args)other;
25163
 
25164
      return 0;
25165
    }
25166
 
25167
    public _Fields fieldForId(int fieldId) {
25168
      return _Fields.findByThriftId(fieldId);
25169
    }
25170
 
25171
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25172
      org.apache.thrift.protocol.TField field;
25173
      iprot.readStructBegin();
25174
      while (true)
25175
      {
25176
        field = iprot.readFieldBegin();
25177
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25178
          break;
25179
        }
25180
        switch (field.id) {
25181
          default:
25182
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25183
        }
25184
        iprot.readFieldEnd();
25185
      }
25186
      iprot.readStructEnd();
25187
      validate();
25188
    }
25189
 
25190
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25191
      validate();
25192
 
25193
      oprot.writeStructBegin(STRUCT_DESC);
25194
      oprot.writeFieldStop();
25195
      oprot.writeStructEnd();
25196
    }
25197
 
25198
    @Override
25199
    public String toString() {
25200
      StringBuilder sb = new StringBuilder("getShippingLocations_args(");
25201
      boolean first = true;
25202
 
25203
      sb.append(")");
25204
      return sb.toString();
25205
    }
25206
 
25207
    public void validate() throws org.apache.thrift.TException {
25208
      // check for required fields
25209
    }
25210
 
25211
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25212
      try {
25213
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25214
      } catch (org.apache.thrift.TException te) {
25215
        throw new java.io.IOException(te);
25216
      }
25217
    }
25218
 
25219
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25220
      try {
25221
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25222
      } catch (org.apache.thrift.TException te) {
25223
        throw new java.io.IOException(te);
25224
      }
25225
    }
25226
 
25227
  }
25228
 
25229
  public static class getShippingLocations_result implements org.apache.thrift.TBase<getShippingLocations_result, getShippingLocations_result._Fields>, java.io.Serializable, Cloneable   {
25230
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShippingLocations_result");
25231
 
25232
    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);
25233
 
25234
    private List<Warehouse> success; // required
25235
 
25236
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25237
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25238
      SUCCESS((short)0, "success");
25239
 
25240
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25241
 
25242
      static {
25243
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25244
          byName.put(field.getFieldName(), field);
25245
        }
25246
      }
25247
 
25248
      /**
25249
       * Find the _Fields constant that matches fieldId, or null if its not found.
25250
       */
25251
      public static _Fields findByThriftId(int fieldId) {
25252
        switch(fieldId) {
25253
          case 0: // SUCCESS
25254
            return SUCCESS;
25255
          default:
25256
            return null;
25257
        }
25258
      }
25259
 
25260
      /**
25261
       * Find the _Fields constant that matches fieldId, throwing an exception
25262
       * if it is not found.
25263
       */
25264
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25265
        _Fields fields = findByThriftId(fieldId);
25266
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25267
        return fields;
25268
      }
25269
 
25270
      /**
25271
       * Find the _Fields constant that matches name, or null if its not found.
25272
       */
25273
      public static _Fields findByName(String name) {
25274
        return byName.get(name);
25275
      }
25276
 
25277
      private final short _thriftId;
25278
      private final String _fieldName;
25279
 
25280
      _Fields(short thriftId, String fieldName) {
25281
        _thriftId = thriftId;
25282
        _fieldName = fieldName;
25283
      }
25284
 
25285
      public short getThriftFieldId() {
25286
        return _thriftId;
25287
      }
25288
 
25289
      public String getFieldName() {
25290
        return _fieldName;
25291
      }
25292
    }
25293
 
25294
    // isset id assignments
25295
 
25296
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25297
    static {
25298
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25299
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
25300
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
25301
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
25302
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25303
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShippingLocations_result.class, metaDataMap);
25304
    }
25305
 
25306
    public getShippingLocations_result() {
25307
    }
25308
 
25309
    public getShippingLocations_result(
25310
      List<Warehouse> success)
25311
    {
25312
      this();
25313
      this.success = success;
25314
    }
25315
 
25316
    /**
25317
     * Performs a deep copy on <i>other</i>.
25318
     */
25319
    public getShippingLocations_result(getShippingLocations_result other) {
25320
      if (other.isSetSuccess()) {
25321
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
25322
        for (Warehouse other_element : other.success) {
25323
          __this__success.add(new Warehouse(other_element));
25324
        }
25325
        this.success = __this__success;
25326
      }
25327
    }
25328
 
25329
    public getShippingLocations_result deepCopy() {
25330
      return new getShippingLocations_result(this);
25331
    }
25332
 
25333
    @Override
25334
    public void clear() {
25335
      this.success = null;
25336
    }
25337
 
25338
    public int getSuccessSize() {
25339
      return (this.success == null) ? 0 : this.success.size();
25340
    }
25341
 
25342
    public java.util.Iterator<Warehouse> getSuccessIterator() {
25343
      return (this.success == null) ? null : this.success.iterator();
25344
    }
25345
 
25346
    public void addToSuccess(Warehouse elem) {
25347
      if (this.success == null) {
25348
        this.success = new ArrayList<Warehouse>();
25349
      }
25350
      this.success.add(elem);
25351
    }
25352
 
25353
    public List<Warehouse> getSuccess() {
25354
      return this.success;
25355
    }
25356
 
25357
    public void setSuccess(List<Warehouse> success) {
25358
      this.success = success;
25359
    }
25360
 
25361
    public void unsetSuccess() {
25362
      this.success = null;
25363
    }
25364
 
25365
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
25366
    public boolean isSetSuccess() {
25367
      return this.success != null;
25368
    }
25369
 
25370
    public void setSuccessIsSet(boolean value) {
25371
      if (!value) {
25372
        this.success = null;
25373
      }
25374
    }
25375
 
25376
    public void setFieldValue(_Fields field, Object value) {
25377
      switch (field) {
25378
      case SUCCESS:
25379
        if (value == null) {
25380
          unsetSuccess();
25381
        } else {
25382
          setSuccess((List<Warehouse>)value);
25383
        }
25384
        break;
25385
 
25386
      }
25387
    }
25388
 
25389
    public Object getFieldValue(_Fields field) {
25390
      switch (field) {
25391
      case SUCCESS:
25392
        return getSuccess();
25393
 
25394
      }
25395
      throw new IllegalStateException();
25396
    }
25397
 
25398
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25399
    public boolean isSet(_Fields field) {
25400
      if (field == null) {
25401
        throw new IllegalArgumentException();
25402
      }
25403
 
25404
      switch (field) {
25405
      case SUCCESS:
25406
        return isSetSuccess();
25407
      }
25408
      throw new IllegalStateException();
25409
    }
25410
 
25411
    @Override
25412
    public boolean equals(Object that) {
25413
      if (that == null)
25414
        return false;
25415
      if (that instanceof getShippingLocations_result)
25416
        return this.equals((getShippingLocations_result)that);
25417
      return false;
25418
    }
25419
 
25420
    public boolean equals(getShippingLocations_result that) {
25421
      if (that == null)
25422
        return false;
25423
 
25424
      boolean this_present_success = true && this.isSetSuccess();
25425
      boolean that_present_success = true && that.isSetSuccess();
25426
      if (this_present_success || that_present_success) {
25427
        if (!(this_present_success && that_present_success))
25428
          return false;
25429
        if (!this.success.equals(that.success))
25430
          return false;
25431
      }
25432
 
25433
      return true;
25434
    }
25435
 
25436
    @Override
25437
    public int hashCode() {
25438
      return 0;
25439
    }
25440
 
25441
    public int compareTo(getShippingLocations_result other) {
25442
      if (!getClass().equals(other.getClass())) {
25443
        return getClass().getName().compareTo(other.getClass().getName());
25444
      }
25445
 
25446
      int lastComparison = 0;
25447
      getShippingLocations_result typedOther = (getShippingLocations_result)other;
25448
 
25449
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
25450
      if (lastComparison != 0) {
25451
        return lastComparison;
25452
      }
25453
      if (isSetSuccess()) {
25454
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
25455
        if (lastComparison != 0) {
25456
          return lastComparison;
25457
        }
25458
      }
25459
      return 0;
25460
    }
25461
 
25462
    public _Fields fieldForId(int fieldId) {
25463
      return _Fields.findByThriftId(fieldId);
25464
    }
25465
 
25466
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25467
      org.apache.thrift.protocol.TField field;
25468
      iprot.readStructBegin();
25469
      while (true)
25470
      {
25471
        field = iprot.readFieldBegin();
25472
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25473
          break;
25474
        }
25475
        switch (field.id) {
25476
          case 0: // SUCCESS
25477
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
25478
              {
25479
                org.apache.thrift.protocol.TList _list66 = iprot.readListBegin();
25480
                this.success = new ArrayList<Warehouse>(_list66.size);
25481
                for (int _i67 = 0; _i67 < _list66.size; ++_i67)
25482
                {
25483
                  Warehouse _elem68; // required
25484
                  _elem68 = new Warehouse();
25485
                  _elem68.read(iprot);
25486
                  this.success.add(_elem68);
25487
                }
25488
                iprot.readListEnd();
25489
              }
25490
            } else { 
25491
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25492
            }
25493
            break;
25494
          default:
25495
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25496
        }
25497
        iprot.readFieldEnd();
25498
      }
25499
      iprot.readStructEnd();
25500
      validate();
25501
    }
25502
 
25503
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25504
      oprot.writeStructBegin(STRUCT_DESC);
25505
 
25506
      if (this.isSetSuccess()) {
25507
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
25508
        {
25509
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
25510
          for (Warehouse _iter69 : this.success)
25511
          {
25512
            _iter69.write(oprot);
25513
          }
25514
          oprot.writeListEnd();
25515
        }
25516
        oprot.writeFieldEnd();
25517
      }
25518
      oprot.writeFieldStop();
25519
      oprot.writeStructEnd();
25520
    }
25521
 
25522
    @Override
25523
    public String toString() {
25524
      StringBuilder sb = new StringBuilder("getShippingLocations_result(");
25525
      boolean first = true;
25526
 
25527
      sb.append("success:");
25528
      if (this.success == null) {
25529
        sb.append("null");
25530
      } else {
25531
        sb.append(this.success);
25532
      }
25533
      first = false;
25534
      sb.append(")");
25535
      return sb.toString();
25536
    }
25537
 
25538
    public void validate() throws org.apache.thrift.TException {
25539
      // check for required fields
25540
    }
25541
 
25542
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25543
      try {
25544
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25545
      } catch (org.apache.thrift.TException te) {
25546
        throw new java.io.IOException(te);
25547
      }
25548
    }
25549
 
25550
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25551
      try {
25552
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25553
      } catch (org.apache.thrift.TException te) {
25554
        throw new java.io.IOException(te);
25555
      }
25556
    }
25557
 
25558
  }
25559
 
25560
  public static class getAllVendorItemMappings_args implements org.apache.thrift.TBase<getAllVendorItemMappings_args, getAllVendorItemMappings_args._Fields>, java.io.Serializable, Cloneable   {
25561
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendorItemMappings_args");
25562
 
25563
 
25564
 
25565
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25566
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25567
;
25568
 
25569
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25570
 
25571
      static {
25572
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25573
          byName.put(field.getFieldName(), field);
25574
        }
25575
      }
25576
 
25577
      /**
25578
       * Find the _Fields constant that matches fieldId, or null if its not found.
25579
       */
25580
      public static _Fields findByThriftId(int fieldId) {
25581
        switch(fieldId) {
25582
          default:
25583
            return null;
25584
        }
25585
      }
25586
 
25587
      /**
25588
       * Find the _Fields constant that matches fieldId, throwing an exception
25589
       * if it is not found.
25590
       */
25591
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25592
        _Fields fields = findByThriftId(fieldId);
25593
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25594
        return fields;
25595
      }
25596
 
25597
      /**
25598
       * Find the _Fields constant that matches name, or null if its not found.
25599
       */
25600
      public static _Fields findByName(String name) {
25601
        return byName.get(name);
25602
      }
25603
 
25604
      private final short _thriftId;
25605
      private final String _fieldName;
25606
 
25607
      _Fields(short thriftId, String fieldName) {
25608
        _thriftId = thriftId;
25609
        _fieldName = fieldName;
25610
      }
25611
 
25612
      public short getThriftFieldId() {
25613
        return _thriftId;
25614
      }
25615
 
25616
      public String getFieldName() {
25617
        return _fieldName;
25618
      }
25619
    }
25620
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25621
    static {
25622
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25623
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25624
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendorItemMappings_args.class, metaDataMap);
25625
    }
25626
 
25627
    public getAllVendorItemMappings_args() {
25628
    }
25629
 
25630
    /**
25631
     * Performs a deep copy on <i>other</i>.
25632
     */
25633
    public getAllVendorItemMappings_args(getAllVendorItemMappings_args other) {
25634
    }
25635
 
25636
    public getAllVendorItemMappings_args deepCopy() {
25637
      return new getAllVendorItemMappings_args(this);
25638
    }
25639
 
25640
    @Override
25641
    public void clear() {
25642
    }
25643
 
25644
    public void setFieldValue(_Fields field, Object value) {
25645
      switch (field) {
25646
      }
25647
    }
25648
 
25649
    public Object getFieldValue(_Fields field) {
25650
      switch (field) {
25651
      }
25652
      throw new IllegalStateException();
25653
    }
25654
 
25655
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25656
    public boolean isSet(_Fields field) {
25657
      if (field == null) {
25658
        throw new IllegalArgumentException();
25659
      }
25660
 
25661
      switch (field) {
25662
      }
25663
      throw new IllegalStateException();
25664
    }
25665
 
25666
    @Override
25667
    public boolean equals(Object that) {
25668
      if (that == null)
25669
        return false;
25670
      if (that instanceof getAllVendorItemMappings_args)
25671
        return this.equals((getAllVendorItemMappings_args)that);
25672
      return false;
25673
    }
25674
 
25675
    public boolean equals(getAllVendorItemMappings_args that) {
25676
      if (that == null)
25677
        return false;
25678
 
25679
      return true;
25680
    }
25681
 
25682
    @Override
25683
    public int hashCode() {
25684
      return 0;
25685
    }
25686
 
25687
    public int compareTo(getAllVendorItemMappings_args other) {
25688
      if (!getClass().equals(other.getClass())) {
25689
        return getClass().getName().compareTo(other.getClass().getName());
25690
      }
25691
 
25692
      int lastComparison = 0;
25693
      getAllVendorItemMappings_args typedOther = (getAllVendorItemMappings_args)other;
25694
 
25695
      return 0;
25696
    }
25697
 
25698
    public _Fields fieldForId(int fieldId) {
25699
      return _Fields.findByThriftId(fieldId);
25700
    }
25701
 
25702
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25703
      org.apache.thrift.protocol.TField field;
25704
      iprot.readStructBegin();
25705
      while (true)
25706
      {
25707
        field = iprot.readFieldBegin();
25708
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25709
          break;
25710
        }
25711
        switch (field.id) {
25712
          default:
25713
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25714
        }
25715
        iprot.readFieldEnd();
25716
      }
25717
      iprot.readStructEnd();
25718
      validate();
25719
    }
25720
 
25721
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25722
      validate();
25723
 
25724
      oprot.writeStructBegin(STRUCT_DESC);
25725
      oprot.writeFieldStop();
25726
      oprot.writeStructEnd();
25727
    }
25728
 
25729
    @Override
25730
    public String toString() {
25731
      StringBuilder sb = new StringBuilder("getAllVendorItemMappings_args(");
25732
      boolean first = true;
25733
 
25734
      sb.append(")");
25735
      return sb.toString();
25736
    }
25737
 
25738
    public void validate() throws org.apache.thrift.TException {
25739
      // check for required fields
25740
    }
25741
 
25742
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25743
      try {
25744
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25745
      } catch (org.apache.thrift.TException te) {
25746
        throw new java.io.IOException(te);
25747
      }
25748
    }
25749
 
25750
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25751
      try {
25752
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25753
      } catch (org.apache.thrift.TException te) {
25754
        throw new java.io.IOException(te);
25755
      }
25756
    }
25757
 
25758
  }
25759
 
25760
  public static class getAllVendorItemMappings_result implements org.apache.thrift.TBase<getAllVendorItemMappings_result, getAllVendorItemMappings_result._Fields>, java.io.Serializable, Cloneable   {
25761
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendorItemMappings_result");
25762
 
25763
    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);
25764
 
25765
    private List<VendorItemMapping> success; // required
25766
 
25767
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25768
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25769
      SUCCESS((short)0, "success");
25770
 
25771
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25772
 
25773
      static {
25774
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25775
          byName.put(field.getFieldName(), field);
25776
        }
25777
      }
25778
 
25779
      /**
25780
       * Find the _Fields constant that matches fieldId, or null if its not found.
25781
       */
25782
      public static _Fields findByThriftId(int fieldId) {
25783
        switch(fieldId) {
25784
          case 0: // SUCCESS
25785
            return SUCCESS;
25786
          default:
25787
            return null;
25788
        }
25789
      }
25790
 
25791
      /**
25792
       * Find the _Fields constant that matches fieldId, throwing an exception
25793
       * if it is not found.
25794
       */
25795
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25796
        _Fields fields = findByThriftId(fieldId);
25797
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25798
        return fields;
25799
      }
25800
 
25801
      /**
25802
       * Find the _Fields constant that matches name, or null if its not found.
25803
       */
25804
      public static _Fields findByName(String name) {
25805
        return byName.get(name);
25806
      }
25807
 
25808
      private final short _thriftId;
25809
      private final String _fieldName;
25810
 
25811
      _Fields(short thriftId, String fieldName) {
25812
        _thriftId = thriftId;
25813
        _fieldName = fieldName;
25814
      }
25815
 
25816
      public short getThriftFieldId() {
25817
        return _thriftId;
25818
      }
25819
 
25820
      public String getFieldName() {
25821
        return _fieldName;
25822
      }
25823
    }
25824
 
25825
    // isset id assignments
25826
 
25827
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25828
    static {
25829
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25830
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
25831
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
25832
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class))));
25833
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25834
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendorItemMappings_result.class, metaDataMap);
25835
    }
25836
 
25837
    public getAllVendorItemMappings_result() {
25838
    }
25839
 
25840
    public getAllVendorItemMappings_result(
25841
      List<VendorItemMapping> success)
25842
    {
25843
      this();
25844
      this.success = success;
25845
    }
25846
 
25847
    /**
25848
     * Performs a deep copy on <i>other</i>.
25849
     */
25850
    public getAllVendorItemMappings_result(getAllVendorItemMappings_result other) {
25851
      if (other.isSetSuccess()) {
25852
        List<VendorItemMapping> __this__success = new ArrayList<VendorItemMapping>();
25853
        for (VendorItemMapping other_element : other.success) {
25854
          __this__success.add(new VendorItemMapping(other_element));
25855
        }
25856
        this.success = __this__success;
25857
      }
25858
    }
25859
 
25860
    public getAllVendorItemMappings_result deepCopy() {
25861
      return new getAllVendorItemMappings_result(this);
25862
    }
25863
 
25864
    @Override
25865
    public void clear() {
25866
      this.success = null;
25867
    }
25868
 
25869
    public int getSuccessSize() {
25870
      return (this.success == null) ? 0 : this.success.size();
25871
    }
25872
 
25873
    public java.util.Iterator<VendorItemMapping> getSuccessIterator() {
25874
      return (this.success == null) ? null : this.success.iterator();
25875
    }
25876
 
25877
    public void addToSuccess(VendorItemMapping elem) {
25878
      if (this.success == null) {
25879
        this.success = new ArrayList<VendorItemMapping>();
25880
      }
25881
      this.success.add(elem);
25882
    }
25883
 
25884
    public List<VendorItemMapping> getSuccess() {
25885
      return this.success;
25886
    }
25887
 
25888
    public void setSuccess(List<VendorItemMapping> success) {
25889
      this.success = success;
25890
    }
25891
 
25892
    public void unsetSuccess() {
25893
      this.success = null;
25894
    }
25895
 
25896
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
25897
    public boolean isSetSuccess() {
25898
      return this.success != null;
25899
    }
25900
 
25901
    public void setSuccessIsSet(boolean value) {
25902
      if (!value) {
25903
        this.success = null;
25904
      }
25905
    }
25906
 
25907
    public void setFieldValue(_Fields field, Object value) {
25908
      switch (field) {
25909
      case SUCCESS:
25910
        if (value == null) {
25911
          unsetSuccess();
25912
        } else {
25913
          setSuccess((List<VendorItemMapping>)value);
25914
        }
25915
        break;
25916
 
25917
      }
25918
    }
25919
 
25920
    public Object getFieldValue(_Fields field) {
25921
      switch (field) {
25922
      case SUCCESS:
25923
        return getSuccess();
25924
 
25925
      }
25926
      throw new IllegalStateException();
25927
    }
25928
 
25929
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25930
    public boolean isSet(_Fields field) {
25931
      if (field == null) {
25932
        throw new IllegalArgumentException();
25933
      }
25934
 
25935
      switch (field) {
25936
      case SUCCESS:
25937
        return isSetSuccess();
25938
      }
25939
      throw new IllegalStateException();
25940
    }
25941
 
25942
    @Override
25943
    public boolean equals(Object that) {
25944
      if (that == null)
25945
        return false;
25946
      if (that instanceof getAllVendorItemMappings_result)
25947
        return this.equals((getAllVendorItemMappings_result)that);
25948
      return false;
25949
    }
25950
 
25951
    public boolean equals(getAllVendorItemMappings_result that) {
25952
      if (that == null)
25953
        return false;
25954
 
25955
      boolean this_present_success = true && this.isSetSuccess();
25956
      boolean that_present_success = true && that.isSetSuccess();
25957
      if (this_present_success || that_present_success) {
25958
        if (!(this_present_success && that_present_success))
25959
          return false;
25960
        if (!this.success.equals(that.success))
25961
          return false;
25962
      }
25963
 
25964
      return true;
25965
    }
25966
 
25967
    @Override
25968
    public int hashCode() {
25969
      return 0;
25970
    }
25971
 
25972
    public int compareTo(getAllVendorItemMappings_result other) {
25973
      if (!getClass().equals(other.getClass())) {
25974
        return getClass().getName().compareTo(other.getClass().getName());
25975
      }
25976
 
25977
      int lastComparison = 0;
25978
      getAllVendorItemMappings_result typedOther = (getAllVendorItemMappings_result)other;
25979
 
25980
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
25981
      if (lastComparison != 0) {
25982
        return lastComparison;
25983
      }
25984
      if (isSetSuccess()) {
25985
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
25986
        if (lastComparison != 0) {
25987
          return lastComparison;
25988
        }
25989
      }
25990
      return 0;
25991
    }
25992
 
25993
    public _Fields fieldForId(int fieldId) {
25994
      return _Fields.findByThriftId(fieldId);
25995
    }
25996
 
25997
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25998
      org.apache.thrift.protocol.TField field;
25999
      iprot.readStructBegin();
26000
      while (true)
26001
      {
26002
        field = iprot.readFieldBegin();
26003
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26004
          break;
26005
        }
26006
        switch (field.id) {
26007
          case 0: // SUCCESS
26008
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
26009
              {
26010
                org.apache.thrift.protocol.TList _list70 = iprot.readListBegin();
26011
                this.success = new ArrayList<VendorItemMapping>(_list70.size);
26012
                for (int _i71 = 0; _i71 < _list70.size; ++_i71)
26013
                {
26014
                  VendorItemMapping _elem72; // required
26015
                  _elem72 = new VendorItemMapping();
26016
                  _elem72.read(iprot);
26017
                  this.success.add(_elem72);
26018
                }
26019
                iprot.readListEnd();
26020
              }
26021
            } else { 
26022
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26023
            }
26024
            break;
26025
          default:
26026
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26027
        }
26028
        iprot.readFieldEnd();
26029
      }
26030
      iprot.readStructEnd();
26031
      validate();
26032
    }
26033
 
26034
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26035
      oprot.writeStructBegin(STRUCT_DESC);
26036
 
26037
      if (this.isSetSuccess()) {
26038
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
26039
        {
26040
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
26041
          for (VendorItemMapping _iter73 : this.success)
26042
          {
26043
            _iter73.write(oprot);
26044
          }
26045
          oprot.writeListEnd();
26046
        }
26047
        oprot.writeFieldEnd();
26048
      }
26049
      oprot.writeFieldStop();
26050
      oprot.writeStructEnd();
26051
    }
26052
 
26053
    @Override
26054
    public String toString() {
26055
      StringBuilder sb = new StringBuilder("getAllVendorItemMappings_result(");
26056
      boolean first = true;
26057
 
26058
      sb.append("success:");
26059
      if (this.success == null) {
26060
        sb.append("null");
26061
      } else {
26062
        sb.append(this.success);
26063
      }
26064
      first = false;
26065
      sb.append(")");
26066
      return sb.toString();
26067
    }
26068
 
26069
    public void validate() throws org.apache.thrift.TException {
26070
      // check for required fields
26071
    }
26072
 
26073
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26074
      try {
26075
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26076
      } catch (org.apache.thrift.TException te) {
26077
        throw new java.io.IOException(te);
26078
      }
26079
    }
26080
 
26081
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26082
      try {
26083
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26084
      } catch (org.apache.thrift.TException te) {
26085
        throw new java.io.IOException(te);
26086
      }
26087
    }
26088
 
26089
  }
26090
 
26091
  public static class getInventorySnapshot_args implements org.apache.thrift.TBase<getInventorySnapshot_args, getInventorySnapshot_args._Fields>, java.io.Serializable, Cloneable   {
26092
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventorySnapshot_args");
26093
 
26094
    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)1);
26095
 
26096
    private long warehouseId; // required
26097
 
26098
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26099
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26100
      WAREHOUSE_ID((short)1, "warehouseId");
26101
 
26102
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26103
 
26104
      static {
26105
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26106
          byName.put(field.getFieldName(), field);
26107
        }
26108
      }
26109
 
26110
      /**
26111
       * Find the _Fields constant that matches fieldId, or null if its not found.
26112
       */
26113
      public static _Fields findByThriftId(int fieldId) {
26114
        switch(fieldId) {
26115
          case 1: // WAREHOUSE_ID
26116
            return WAREHOUSE_ID;
26117
          default:
26118
            return null;
26119
        }
26120
      }
26121
 
26122
      /**
26123
       * Find the _Fields constant that matches fieldId, throwing an exception
26124
       * if it is not found.
26125
       */
26126
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26127
        _Fields fields = findByThriftId(fieldId);
26128
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26129
        return fields;
26130
      }
26131
 
26132
      /**
26133
       * Find the _Fields constant that matches name, or null if its not found.
26134
       */
26135
      public static _Fields findByName(String name) {
26136
        return byName.get(name);
26137
      }
26138
 
26139
      private final short _thriftId;
26140
      private final String _fieldName;
26141
 
26142
      _Fields(short thriftId, String fieldName) {
26143
        _thriftId = thriftId;
26144
        _fieldName = fieldName;
26145
      }
26146
 
26147
      public short getThriftFieldId() {
26148
        return _thriftId;
26149
      }
26150
 
26151
      public String getFieldName() {
26152
        return _fieldName;
26153
      }
26154
    }
26155
 
26156
    // isset id assignments
26157
    private static final int __WAREHOUSEID_ISSET_ID = 0;
26158
    private BitSet __isset_bit_vector = new BitSet(1);
26159
 
26160
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26161
    static {
26162
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26163
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
26164
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
26165
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26166
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventorySnapshot_args.class, metaDataMap);
26167
    }
26168
 
26169
    public getInventorySnapshot_args() {
26170
    }
26171
 
26172
    public getInventorySnapshot_args(
26173
      long warehouseId)
26174
    {
26175
      this();
26176
      this.warehouseId = warehouseId;
26177
      setWarehouseIdIsSet(true);
26178
    }
26179
 
26180
    /**
26181
     * Performs a deep copy on <i>other</i>.
26182
     */
26183
    public getInventorySnapshot_args(getInventorySnapshot_args other) {
26184
      __isset_bit_vector.clear();
26185
      __isset_bit_vector.or(other.__isset_bit_vector);
26186
      this.warehouseId = other.warehouseId;
26187
    }
26188
 
26189
    public getInventorySnapshot_args deepCopy() {
26190
      return new getInventorySnapshot_args(this);
26191
    }
26192
 
26193
    @Override
26194
    public void clear() {
26195
      setWarehouseIdIsSet(false);
26196
      this.warehouseId = 0;
26197
    }
26198
 
26199
    public long getWarehouseId() {
26200
      return this.warehouseId;
26201
    }
26202
 
26203
    public void setWarehouseId(long warehouseId) {
26204
      this.warehouseId = warehouseId;
26205
      setWarehouseIdIsSet(true);
26206
    }
26207
 
26208
    public void unsetWarehouseId() {
26209
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
26210
    }
26211
 
26212
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
26213
    public boolean isSetWarehouseId() {
26214
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
26215
    }
26216
 
26217
    public void setWarehouseIdIsSet(boolean value) {
26218
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
26219
    }
26220
 
26221
    public void setFieldValue(_Fields field, Object value) {
26222
      switch (field) {
26223
      case WAREHOUSE_ID:
26224
        if (value == null) {
26225
          unsetWarehouseId();
26226
        } else {
26227
          setWarehouseId((Long)value);
26228
        }
26229
        break;
26230
 
26231
      }
26232
    }
26233
 
26234
    public Object getFieldValue(_Fields field) {
26235
      switch (field) {
26236
      case WAREHOUSE_ID:
26237
        return Long.valueOf(getWarehouseId());
26238
 
26239
      }
26240
      throw new IllegalStateException();
26241
    }
26242
 
26243
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26244
    public boolean isSet(_Fields field) {
26245
      if (field == null) {
26246
        throw new IllegalArgumentException();
26247
      }
26248
 
26249
      switch (field) {
26250
      case WAREHOUSE_ID:
26251
        return isSetWarehouseId();
26252
      }
26253
      throw new IllegalStateException();
26254
    }
26255
 
26256
    @Override
26257
    public boolean equals(Object that) {
26258
      if (that == null)
26259
        return false;
26260
      if (that instanceof getInventorySnapshot_args)
26261
        return this.equals((getInventorySnapshot_args)that);
26262
      return false;
26263
    }
26264
 
26265
    public boolean equals(getInventorySnapshot_args that) {
26266
      if (that == null)
26267
        return false;
26268
 
26269
      boolean this_present_warehouseId = true;
26270
      boolean that_present_warehouseId = true;
26271
      if (this_present_warehouseId || that_present_warehouseId) {
26272
        if (!(this_present_warehouseId && that_present_warehouseId))
26273
          return false;
26274
        if (this.warehouseId != that.warehouseId)
26275
          return false;
26276
      }
26277
 
26278
      return true;
26279
    }
26280
 
26281
    @Override
26282
    public int hashCode() {
26283
      return 0;
26284
    }
26285
 
26286
    public int compareTo(getInventorySnapshot_args other) {
26287
      if (!getClass().equals(other.getClass())) {
26288
        return getClass().getName().compareTo(other.getClass().getName());
26289
      }
26290
 
26291
      int lastComparison = 0;
26292
      getInventorySnapshot_args typedOther = (getInventorySnapshot_args)other;
26293
 
26294
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
26295
      if (lastComparison != 0) {
26296
        return lastComparison;
26297
      }
26298
      if (isSetWarehouseId()) {
26299
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
26300
        if (lastComparison != 0) {
26301
          return lastComparison;
26302
        }
26303
      }
26304
      return 0;
26305
    }
26306
 
26307
    public _Fields fieldForId(int fieldId) {
26308
      return _Fields.findByThriftId(fieldId);
26309
    }
26310
 
26311
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26312
      org.apache.thrift.protocol.TField field;
26313
      iprot.readStructBegin();
26314
      while (true)
26315
      {
26316
        field = iprot.readFieldBegin();
26317
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26318
          break;
26319
        }
26320
        switch (field.id) {
26321
          case 1: // WAREHOUSE_ID
26322
            if (field.type == org.apache.thrift.protocol.TType.I64) {
26323
              this.warehouseId = iprot.readI64();
26324
              setWarehouseIdIsSet(true);
26325
            } else { 
26326
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26327
            }
26328
            break;
26329
          default:
26330
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26331
        }
26332
        iprot.readFieldEnd();
26333
      }
26334
      iprot.readStructEnd();
26335
      validate();
26336
    }
26337
 
26338
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26339
      validate();
26340
 
26341
      oprot.writeStructBegin(STRUCT_DESC);
26342
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
26343
      oprot.writeI64(this.warehouseId);
26344
      oprot.writeFieldEnd();
26345
      oprot.writeFieldStop();
26346
      oprot.writeStructEnd();
26347
    }
26348
 
26349
    @Override
26350
    public String toString() {
26351
      StringBuilder sb = new StringBuilder("getInventorySnapshot_args(");
26352
      boolean first = true;
26353
 
26354
      sb.append("warehouseId:");
26355
      sb.append(this.warehouseId);
26356
      first = false;
26357
      sb.append(")");
26358
      return sb.toString();
26359
    }
26360
 
26361
    public void validate() throws org.apache.thrift.TException {
26362
      // check for required fields
26363
    }
26364
 
26365
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26366
      try {
26367
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26368
      } catch (org.apache.thrift.TException te) {
26369
        throw new java.io.IOException(te);
26370
      }
26371
    }
26372
 
26373
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26374
      try {
26375
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
26376
        __isset_bit_vector = new BitSet(1);
26377
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26378
      } catch (org.apache.thrift.TException te) {
26379
        throw new java.io.IOException(te);
26380
      }
26381
    }
26382
 
26383
  }
26384
 
26385
  public static class getInventorySnapshot_result implements org.apache.thrift.TBase<getInventorySnapshot_result, getInventorySnapshot_result._Fields>, java.io.Serializable, Cloneable   {
26386
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventorySnapshot_result");
26387
 
26388
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.MAP, (short)0);
26389
 
26390
    private Map<Long,ItemInventory> success; // required
26391
 
26392
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26393
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26394
      SUCCESS((short)0, "success");
26395
 
26396
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26397
 
26398
      static {
26399
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26400
          byName.put(field.getFieldName(), field);
26401
        }
26402
      }
26403
 
26404
      /**
26405
       * Find the _Fields constant that matches fieldId, or null if its not found.
26406
       */
26407
      public static _Fields findByThriftId(int fieldId) {
26408
        switch(fieldId) {
26409
          case 0: // SUCCESS
26410
            return SUCCESS;
26411
          default:
26412
            return null;
26413
        }
26414
      }
26415
 
26416
      /**
26417
       * Find the _Fields constant that matches fieldId, throwing an exception
26418
       * if it is not found.
26419
       */
26420
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26421
        _Fields fields = findByThriftId(fieldId);
26422
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26423
        return fields;
26424
      }
26425
 
26426
      /**
26427
       * Find the _Fields constant that matches name, or null if its not found.
26428
       */
26429
      public static _Fields findByName(String name) {
26430
        return byName.get(name);
26431
      }
26432
 
26433
      private final short _thriftId;
26434
      private final String _fieldName;
26435
 
26436
      _Fields(short thriftId, String fieldName) {
26437
        _thriftId = thriftId;
26438
        _fieldName = fieldName;
26439
      }
26440
 
26441
      public short getThriftFieldId() {
26442
        return _thriftId;
26443
      }
26444
 
26445
      public String getFieldName() {
26446
        return _fieldName;
26447
      }
26448
    }
26449
 
26450
    // isset id assignments
26451
 
26452
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26453
    static {
26454
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26455
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
26456
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
26457
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
26458
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ItemInventory.class))));
26459
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26460
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventorySnapshot_result.class, metaDataMap);
26461
    }
26462
 
26463
    public getInventorySnapshot_result() {
26464
    }
26465
 
26466
    public getInventorySnapshot_result(
26467
      Map<Long,ItemInventory> success)
26468
    {
26469
      this();
26470
      this.success = success;
26471
    }
26472
 
26473
    /**
26474
     * Performs a deep copy on <i>other</i>.
26475
     */
26476
    public getInventorySnapshot_result(getInventorySnapshot_result other) {
26477
      if (other.isSetSuccess()) {
26478
        Map<Long,ItemInventory> __this__success = new HashMap<Long,ItemInventory>();
26479
        for (Map.Entry<Long, ItemInventory> other_element : other.success.entrySet()) {
26480
 
26481
          Long other_element_key = other_element.getKey();
26482
          ItemInventory other_element_value = other_element.getValue();
26483
 
26484
          Long __this__success_copy_key = other_element_key;
26485
 
26486
          ItemInventory __this__success_copy_value = new ItemInventory(other_element_value);
26487
 
26488
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
26489
        }
26490
        this.success = __this__success;
26491
      }
26492
    }
26493
 
26494
    public getInventorySnapshot_result deepCopy() {
26495
      return new getInventorySnapshot_result(this);
26496
    }
26497
 
26498
    @Override
26499
    public void clear() {
26500
      this.success = null;
26501
    }
26502
 
26503
    public int getSuccessSize() {
26504
      return (this.success == null) ? 0 : this.success.size();
26505
    }
26506
 
26507
    public void putToSuccess(long key, ItemInventory val) {
26508
      if (this.success == null) {
26509
        this.success = new HashMap<Long,ItemInventory>();
26510
      }
26511
      this.success.put(key, val);
26512
    }
26513
 
26514
    public Map<Long,ItemInventory> getSuccess() {
26515
      return this.success;
26516
    }
26517
 
26518
    public void setSuccess(Map<Long,ItemInventory> success) {
26519
      this.success = success;
26520
    }
26521
 
26522
    public void unsetSuccess() {
26523
      this.success = null;
26524
    }
26525
 
26526
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
26527
    public boolean isSetSuccess() {
26528
      return this.success != null;
26529
    }
26530
 
26531
    public void setSuccessIsSet(boolean value) {
26532
      if (!value) {
26533
        this.success = null;
26534
      }
26535
    }
26536
 
26537
    public void setFieldValue(_Fields field, Object value) {
26538
      switch (field) {
26539
      case SUCCESS:
26540
        if (value == null) {
26541
          unsetSuccess();
26542
        } else {
26543
          setSuccess((Map<Long,ItemInventory>)value);
26544
        }
26545
        break;
26546
 
26547
      }
26548
    }
26549
 
26550
    public Object getFieldValue(_Fields field) {
26551
      switch (field) {
26552
      case SUCCESS:
26553
        return getSuccess();
26554
 
26555
      }
26556
      throw new IllegalStateException();
26557
    }
26558
 
26559
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26560
    public boolean isSet(_Fields field) {
26561
      if (field == null) {
26562
        throw new IllegalArgumentException();
26563
      }
26564
 
26565
      switch (field) {
26566
      case SUCCESS:
26567
        return isSetSuccess();
26568
      }
26569
      throw new IllegalStateException();
26570
    }
26571
 
26572
    @Override
26573
    public boolean equals(Object that) {
26574
      if (that == null)
26575
        return false;
26576
      if (that instanceof getInventorySnapshot_result)
26577
        return this.equals((getInventorySnapshot_result)that);
26578
      return false;
26579
    }
26580
 
26581
    public boolean equals(getInventorySnapshot_result that) {
26582
      if (that == null)
26583
        return false;
26584
 
26585
      boolean this_present_success = true && this.isSetSuccess();
26586
      boolean that_present_success = true && that.isSetSuccess();
26587
      if (this_present_success || that_present_success) {
26588
        if (!(this_present_success && that_present_success))
26589
          return false;
26590
        if (!this.success.equals(that.success))
26591
          return false;
26592
      }
26593
 
26594
      return true;
26595
    }
26596
 
26597
    @Override
26598
    public int hashCode() {
26599
      return 0;
26600
    }
26601
 
26602
    public int compareTo(getInventorySnapshot_result other) {
26603
      if (!getClass().equals(other.getClass())) {
26604
        return getClass().getName().compareTo(other.getClass().getName());
26605
      }
26606
 
26607
      int lastComparison = 0;
26608
      getInventorySnapshot_result typedOther = (getInventorySnapshot_result)other;
26609
 
26610
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
26611
      if (lastComparison != 0) {
26612
        return lastComparison;
26613
      }
26614
      if (isSetSuccess()) {
26615
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
26616
        if (lastComparison != 0) {
26617
          return lastComparison;
26618
        }
26619
      }
26620
      return 0;
26621
    }
26622
 
26623
    public _Fields fieldForId(int fieldId) {
26624
      return _Fields.findByThriftId(fieldId);
26625
    }
26626
 
26627
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26628
      org.apache.thrift.protocol.TField field;
26629
      iprot.readStructBegin();
26630
      while (true)
26631
      {
26632
        field = iprot.readFieldBegin();
26633
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26634
          break;
26635
        }
26636
        switch (field.id) {
26637
          case 0: // SUCCESS
26638
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
26639
              {
26640
                org.apache.thrift.protocol.TMap _map74 = iprot.readMapBegin();
26641
                this.success = new HashMap<Long,ItemInventory>(2*_map74.size);
26642
                for (int _i75 = 0; _i75 < _map74.size; ++_i75)
26643
                {
26644
                  long _key76; // required
26645
                  ItemInventory _val77; // required
26646
                  _key76 = iprot.readI64();
26647
                  _val77 = new ItemInventory();
26648
                  _val77.read(iprot);
26649
                  this.success.put(_key76, _val77);
26650
                }
26651
                iprot.readMapEnd();
26652
              }
26653
            } else { 
26654
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26655
            }
26656
            break;
26657
          default:
26658
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26659
        }
26660
        iprot.readFieldEnd();
26661
      }
26662
      iprot.readStructEnd();
26663
      validate();
26664
    }
26665
 
26666
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26667
      oprot.writeStructBegin(STRUCT_DESC);
26668
 
26669
      if (this.isSetSuccess()) {
26670
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
26671
        {
26672
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
26673
          for (Map.Entry<Long, ItemInventory> _iter78 : this.success.entrySet())
26674
          {
26675
            oprot.writeI64(_iter78.getKey());
26676
            _iter78.getValue().write(oprot);
26677
          }
26678
          oprot.writeMapEnd();
26679
        }
26680
        oprot.writeFieldEnd();
26681
      }
26682
      oprot.writeFieldStop();
26683
      oprot.writeStructEnd();
26684
    }
26685
 
26686
    @Override
26687
    public String toString() {
26688
      StringBuilder sb = new StringBuilder("getInventorySnapshot_result(");
26689
      boolean first = true;
26690
 
26691
      sb.append("success:");
26692
      if (this.success == null) {
26693
        sb.append("null");
26694
      } else {
26695
        sb.append(this.success);
26696
      }
26697
      first = false;
26698
      sb.append(")");
26699
      return sb.toString();
26700
    }
26701
 
26702
    public void validate() throws org.apache.thrift.TException {
26703
      // check for required fields
26704
    }
26705
 
26706
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26707
      try {
26708
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26709
      } catch (org.apache.thrift.TException te) {
26710
        throw new java.io.IOException(te);
26711
      }
26712
    }
26713
 
26714
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26715
      try {
26716
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26717
      } catch (org.apache.thrift.TException te) {
26718
        throw new java.io.IOException(te);
26719
      }
26720
    }
26721
 
26722
  }
26723
 
26724
  public static class clearItemAvailabilityCache_args implements org.apache.thrift.TBase<clearItemAvailabilityCache_args, clearItemAvailabilityCache_args._Fields>, java.io.Serializable, Cloneable   {
26725
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCache_args");
26726
 
26727
 
26728
 
26729
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26730
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26731
;
26732
 
26733
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26734
 
26735
      static {
26736
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26737
          byName.put(field.getFieldName(), field);
26738
        }
26739
      }
26740
 
26741
      /**
26742
       * Find the _Fields constant that matches fieldId, or null if its not found.
26743
       */
26744
      public static _Fields findByThriftId(int fieldId) {
26745
        switch(fieldId) {
26746
          default:
26747
            return null;
26748
        }
26749
      }
26750
 
26751
      /**
26752
       * Find the _Fields constant that matches fieldId, throwing an exception
26753
       * if it is not found.
26754
       */
26755
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26756
        _Fields fields = findByThriftId(fieldId);
26757
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26758
        return fields;
26759
      }
26760
 
26761
      /**
26762
       * Find the _Fields constant that matches name, or null if its not found.
26763
       */
26764
      public static _Fields findByName(String name) {
26765
        return byName.get(name);
26766
      }
26767
 
26768
      private final short _thriftId;
26769
      private final String _fieldName;
26770
 
26771
      _Fields(short thriftId, String fieldName) {
26772
        _thriftId = thriftId;
26773
        _fieldName = fieldName;
26774
      }
26775
 
26776
      public short getThriftFieldId() {
26777
        return _thriftId;
26778
      }
26779
 
26780
      public String getFieldName() {
26781
        return _fieldName;
26782
      }
26783
    }
26784
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26785
    static {
26786
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26787
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26788
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCache_args.class, metaDataMap);
26789
    }
26790
 
26791
    public clearItemAvailabilityCache_args() {
26792
    }
26793
 
26794
    /**
26795
     * Performs a deep copy on <i>other</i>.
26796
     */
26797
    public clearItemAvailabilityCache_args(clearItemAvailabilityCache_args other) {
26798
    }
26799
 
26800
    public clearItemAvailabilityCache_args deepCopy() {
26801
      return new clearItemAvailabilityCache_args(this);
26802
    }
26803
 
26804
    @Override
26805
    public void clear() {
26806
    }
26807
 
26808
    public void setFieldValue(_Fields field, Object value) {
26809
      switch (field) {
26810
      }
26811
    }
26812
 
26813
    public Object getFieldValue(_Fields field) {
26814
      switch (field) {
26815
      }
26816
      throw new IllegalStateException();
26817
    }
26818
 
26819
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26820
    public boolean isSet(_Fields field) {
26821
      if (field == null) {
26822
        throw new IllegalArgumentException();
26823
      }
26824
 
26825
      switch (field) {
26826
      }
26827
      throw new IllegalStateException();
26828
    }
26829
 
26830
    @Override
26831
    public boolean equals(Object that) {
26832
      if (that == null)
26833
        return false;
26834
      if (that instanceof clearItemAvailabilityCache_args)
26835
        return this.equals((clearItemAvailabilityCache_args)that);
26836
      return false;
26837
    }
26838
 
26839
    public boolean equals(clearItemAvailabilityCache_args that) {
26840
      if (that == null)
26841
        return false;
26842
 
26843
      return true;
26844
    }
26845
 
26846
    @Override
26847
    public int hashCode() {
26848
      return 0;
26849
    }
26850
 
26851
    public int compareTo(clearItemAvailabilityCache_args other) {
26852
      if (!getClass().equals(other.getClass())) {
26853
        return getClass().getName().compareTo(other.getClass().getName());
26854
      }
26855
 
26856
      int lastComparison = 0;
26857
      clearItemAvailabilityCache_args typedOther = (clearItemAvailabilityCache_args)other;
26858
 
26859
      return 0;
26860
    }
26861
 
26862
    public _Fields fieldForId(int fieldId) {
26863
      return _Fields.findByThriftId(fieldId);
26864
    }
26865
 
26866
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26867
      org.apache.thrift.protocol.TField field;
26868
      iprot.readStructBegin();
26869
      while (true)
26870
      {
26871
        field = iprot.readFieldBegin();
26872
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26873
          break;
26874
        }
26875
        switch (field.id) {
26876
          default:
26877
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26878
        }
26879
        iprot.readFieldEnd();
26880
      }
26881
      iprot.readStructEnd();
26882
      validate();
26883
    }
26884
 
26885
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26886
      validate();
26887
 
26888
      oprot.writeStructBegin(STRUCT_DESC);
26889
      oprot.writeFieldStop();
26890
      oprot.writeStructEnd();
26891
    }
26892
 
26893
    @Override
26894
    public String toString() {
26895
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCache_args(");
26896
      boolean first = true;
26897
 
26898
      sb.append(")");
26899
      return sb.toString();
26900
    }
26901
 
26902
    public void validate() throws org.apache.thrift.TException {
26903
      // check for required fields
26904
    }
26905
 
26906
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26907
      try {
26908
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26909
      } catch (org.apache.thrift.TException te) {
26910
        throw new java.io.IOException(te);
26911
      }
26912
    }
26913
 
26914
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26915
      try {
26916
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26917
      } catch (org.apache.thrift.TException te) {
26918
        throw new java.io.IOException(te);
26919
      }
26920
    }
26921
 
26922
  }
26923
 
26924
  public static class clearItemAvailabilityCache_result implements org.apache.thrift.TBase<clearItemAvailabilityCache_result, clearItemAvailabilityCache_result._Fields>, java.io.Serializable, Cloneable   {
26925
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCache_result");
26926
 
26927
 
26928
 
26929
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26930
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26931
;
26932
 
26933
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26934
 
26935
      static {
26936
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26937
          byName.put(field.getFieldName(), field);
26938
        }
26939
      }
26940
 
26941
      /**
26942
       * Find the _Fields constant that matches fieldId, or null if its not found.
26943
       */
26944
      public static _Fields findByThriftId(int fieldId) {
26945
        switch(fieldId) {
26946
          default:
26947
            return null;
26948
        }
26949
      }
26950
 
26951
      /**
26952
       * Find the _Fields constant that matches fieldId, throwing an exception
26953
       * if it is not found.
26954
       */
26955
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26956
        _Fields fields = findByThriftId(fieldId);
26957
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26958
        return fields;
26959
      }
26960
 
26961
      /**
26962
       * Find the _Fields constant that matches name, or null if its not found.
26963
       */
26964
      public static _Fields findByName(String name) {
26965
        return byName.get(name);
26966
      }
26967
 
26968
      private final short _thriftId;
26969
      private final String _fieldName;
26970
 
26971
      _Fields(short thriftId, String fieldName) {
26972
        _thriftId = thriftId;
26973
        _fieldName = fieldName;
26974
      }
26975
 
26976
      public short getThriftFieldId() {
26977
        return _thriftId;
26978
      }
26979
 
26980
      public String getFieldName() {
26981
        return _fieldName;
26982
      }
26983
    }
26984
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26985
    static {
26986
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26987
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26988
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCache_result.class, metaDataMap);
26989
    }
26990
 
26991
    public clearItemAvailabilityCache_result() {
26992
    }
26993
 
26994
    /**
26995
     * Performs a deep copy on <i>other</i>.
26996
     */
26997
    public clearItemAvailabilityCache_result(clearItemAvailabilityCache_result other) {
26998
    }
26999
 
27000
    public clearItemAvailabilityCache_result deepCopy() {
27001
      return new clearItemAvailabilityCache_result(this);
27002
    }
27003
 
27004
    @Override
27005
    public void clear() {
27006
    }
27007
 
27008
    public void setFieldValue(_Fields field, Object value) {
27009
      switch (field) {
27010
      }
27011
    }
27012
 
27013
    public Object getFieldValue(_Fields field) {
27014
      switch (field) {
27015
      }
27016
      throw new IllegalStateException();
27017
    }
27018
 
27019
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
27020
    public boolean isSet(_Fields field) {
27021
      if (field == null) {
27022
        throw new IllegalArgumentException();
27023
      }
27024
 
27025
      switch (field) {
27026
      }
27027
      throw new IllegalStateException();
27028
    }
27029
 
27030
    @Override
27031
    public boolean equals(Object that) {
27032
      if (that == null)
27033
        return false;
27034
      if (that instanceof clearItemAvailabilityCache_result)
27035
        return this.equals((clearItemAvailabilityCache_result)that);
27036
      return false;
27037
    }
27038
 
27039
    public boolean equals(clearItemAvailabilityCache_result that) {
27040
      if (that == null)
27041
        return false;
27042
 
27043
      return true;
27044
    }
27045
 
27046
    @Override
27047
    public int hashCode() {
27048
      return 0;
27049
    }
27050
 
27051
    public int compareTo(clearItemAvailabilityCache_result other) {
27052
      if (!getClass().equals(other.getClass())) {
27053
        return getClass().getName().compareTo(other.getClass().getName());
27054
      }
27055
 
27056
      int lastComparison = 0;
27057
      clearItemAvailabilityCache_result typedOther = (clearItemAvailabilityCache_result)other;
27058
 
27059
      return 0;
27060
    }
27061
 
27062
    public _Fields fieldForId(int fieldId) {
27063
      return _Fields.findByThriftId(fieldId);
27064
    }
27065
 
27066
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
27067
      org.apache.thrift.protocol.TField field;
27068
      iprot.readStructBegin();
27069
      while (true)
27070
      {
27071
        field = iprot.readFieldBegin();
27072
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
27073
          break;
27074
        }
27075
        switch (field.id) {
27076
          default:
27077
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27078
        }
27079
        iprot.readFieldEnd();
27080
      }
27081
      iprot.readStructEnd();
27082
      validate();
27083
    }
27084
 
27085
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
27086
      oprot.writeStructBegin(STRUCT_DESC);
27087
 
27088
      oprot.writeFieldStop();
27089
      oprot.writeStructEnd();
27090
    }
27091
 
27092
    @Override
27093
    public String toString() {
27094
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCache_result(");
27095
      boolean first = true;
27096
 
27097
      sb.append(")");
27098
      return sb.toString();
27099
    }
27100
 
27101
    public void validate() throws org.apache.thrift.TException {
27102
      // check for required fields
27103
    }
27104
 
27105
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
27106
      try {
27107
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
27108
      } catch (org.apache.thrift.TException te) {
27109
        throw new java.io.IOException(te);
27110
      }
27111
    }
27112
 
27113
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
27114
      try {
27115
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
27116
      } catch (org.apache.thrift.TException te) {
27117
        throw new java.io.IOException(te);
27118
      }
27119
    }
27120
 
27121
  }
27122
 
27123
  public static class updateVendorString_args implements org.apache.thrift.TBase<updateVendorString_args, updateVendorString_args._Fields>, java.io.Serializable, Cloneable   {
27124
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateVendorString_args");
27125
 
27126
    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)1);
27127
    private static final org.apache.thrift.protocol.TField VENDOR_STRING_FIELD_DESC = new org.apache.thrift.protocol.TField("vendorString", org.apache.thrift.protocol.TType.STRING, (short)2);
27128
 
27129
    private long warehouseId; // required
27130
    private String vendorString; // required
27131
 
27132
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
27133
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
27134
      WAREHOUSE_ID((short)1, "warehouseId"),
27135
      VENDOR_STRING((short)2, "vendorString");
27136
 
27137
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
27138
 
27139
      static {
27140
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
27141
          byName.put(field.getFieldName(), field);
27142
        }
27143
      }
27144
 
27145
      /**
27146
       * Find the _Fields constant that matches fieldId, or null if its not found.
27147
       */
27148
      public static _Fields findByThriftId(int fieldId) {
27149
        switch(fieldId) {
27150
          case 1: // WAREHOUSE_ID
27151
            return WAREHOUSE_ID;
27152
          case 2: // VENDOR_STRING
27153
            return VENDOR_STRING;
27154
          default:
27155
            return null;
27156
        }
27157
      }
27158
 
27159
      /**
27160
       * Find the _Fields constant that matches fieldId, throwing an exception
27161
       * if it is not found.
27162
       */
27163
      public static _Fields findByThriftIdOrThrow(int fieldId) {
27164
        _Fields fields = findByThriftId(fieldId);
27165
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
27166
        return fields;
27167
      }
27168
 
27169
      /**
27170
       * Find the _Fields constant that matches name, or null if its not found.
27171
       */
27172
      public static _Fields findByName(String name) {
27173
        return byName.get(name);
27174
      }
27175
 
27176
      private final short _thriftId;
27177
      private final String _fieldName;
27178
 
27179
      _Fields(short thriftId, String fieldName) {
27180
        _thriftId = thriftId;
27181
        _fieldName = fieldName;
27182
      }
27183
 
27184
      public short getThriftFieldId() {
27185
        return _thriftId;
27186
      }
27187
 
27188
      public String getFieldName() {
27189
        return _fieldName;
27190
      }
27191
    }
27192
 
27193
    // isset id assignments
27194
    private static final int __WAREHOUSEID_ISSET_ID = 0;
27195
    private BitSet __isset_bit_vector = new BitSet(1);
27196
 
27197
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
27198
    static {
27199
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
27200
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
27201
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
27202
      tmpMap.put(_Fields.VENDOR_STRING, new org.apache.thrift.meta_data.FieldMetaData("vendorString", org.apache.thrift.TFieldRequirementType.DEFAULT, 
27203
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
27204
      metaDataMap = Collections.unmodifiableMap(tmpMap);
27205
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateVendorString_args.class, metaDataMap);
27206
    }
27207
 
27208
    public updateVendorString_args() {
27209
    }
27210
 
27211
    public updateVendorString_args(
27212
      long warehouseId,
27213
      String vendorString)
27214
    {
27215
      this();
27216
      this.warehouseId = warehouseId;
27217
      setWarehouseIdIsSet(true);
27218
      this.vendorString = vendorString;
27219
    }
27220
 
27221
    /**
27222
     * Performs a deep copy on <i>other</i>.
27223
     */
27224
    public updateVendorString_args(updateVendorString_args other) {
27225
      __isset_bit_vector.clear();
27226
      __isset_bit_vector.or(other.__isset_bit_vector);
27227
      this.warehouseId = other.warehouseId;
27228
      if (other.isSetVendorString()) {
27229
        this.vendorString = other.vendorString;
27230
      }
27231
    }
27232
 
27233
    public updateVendorString_args deepCopy() {
27234
      return new updateVendorString_args(this);
27235
    }
27236
 
27237
    @Override
27238
    public void clear() {
27239
      setWarehouseIdIsSet(false);
27240
      this.warehouseId = 0;
27241
      this.vendorString = null;
27242
    }
27243
 
27244
    public long getWarehouseId() {
27245
      return this.warehouseId;
27246
    }
27247
 
27248
    public void setWarehouseId(long warehouseId) {
27249
      this.warehouseId = warehouseId;
27250
      setWarehouseIdIsSet(true);
27251
    }
27252
 
27253
    public void unsetWarehouseId() {
27254
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
27255
    }
27256
 
27257
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
27258
    public boolean isSetWarehouseId() {
27259
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
27260
    }
27261
 
27262
    public void setWarehouseIdIsSet(boolean value) {
27263
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
27264
    }
27265
 
27266
    public String getVendorString() {
27267
      return this.vendorString;
27268
    }
27269
 
27270
    public void setVendorString(String vendorString) {
27271
      this.vendorString = vendorString;
27272
    }
27273
 
27274
    public void unsetVendorString() {
27275
      this.vendorString = null;
27276
    }
27277
 
27278
    /** Returns true if field vendorString is set (has been assigned a value) and false otherwise */
27279
    public boolean isSetVendorString() {
27280
      return this.vendorString != null;
27281
    }
27282
 
27283
    public void setVendorStringIsSet(boolean value) {
27284
      if (!value) {
27285
        this.vendorString = null;
27286
      }
27287
    }
27288
 
27289
    public void setFieldValue(_Fields field, Object value) {
27290
      switch (field) {
27291
      case WAREHOUSE_ID:
27292
        if (value == null) {
27293
          unsetWarehouseId();
27294
        } else {
27295
          setWarehouseId((Long)value);
27296
        }
27297
        break;
27298
 
27299
      case VENDOR_STRING:
27300
        if (value == null) {
27301
          unsetVendorString();
27302
        } else {
27303
          setVendorString((String)value);
27304
        }
27305
        break;
27306
 
27307
      }
27308
    }
27309
 
27310
    public Object getFieldValue(_Fields field) {
27311
      switch (field) {
27312
      case WAREHOUSE_ID:
27313
        return Long.valueOf(getWarehouseId());
27314
 
27315
      case VENDOR_STRING:
27316
        return getVendorString();
27317
 
27318
      }
27319
      throw new IllegalStateException();
27320
    }
27321
 
27322
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
27323
    public boolean isSet(_Fields field) {
27324
      if (field == null) {
27325
        throw new IllegalArgumentException();
27326
      }
27327
 
27328
      switch (field) {
27329
      case WAREHOUSE_ID:
27330
        return isSetWarehouseId();
27331
      case VENDOR_STRING:
27332
        return isSetVendorString();
27333
      }
27334
      throw new IllegalStateException();
27335
    }
27336
 
27337
    @Override
27338
    public boolean equals(Object that) {
27339
      if (that == null)
27340
        return false;
27341
      if (that instanceof updateVendorString_args)
27342
        return this.equals((updateVendorString_args)that);
27343
      return false;
27344
    }
27345
 
27346
    public boolean equals(updateVendorString_args that) {
27347
      if (that == null)
27348
        return false;
27349
 
27350
      boolean this_present_warehouseId = true;
27351
      boolean that_present_warehouseId = true;
27352
      if (this_present_warehouseId || that_present_warehouseId) {
27353
        if (!(this_present_warehouseId && that_present_warehouseId))
27354
          return false;
27355
        if (this.warehouseId != that.warehouseId)
27356
          return false;
27357
      }
27358
 
27359
      boolean this_present_vendorString = true && this.isSetVendorString();
27360
      boolean that_present_vendorString = true && that.isSetVendorString();
27361
      if (this_present_vendorString || that_present_vendorString) {
27362
        if (!(this_present_vendorString && that_present_vendorString))
27363
          return false;
27364
        if (!this.vendorString.equals(that.vendorString))
27365
          return false;
27366
      }
27367
 
27368
      return true;
27369
    }
27370
 
27371
    @Override
27372
    public int hashCode() {
27373
      return 0;
27374
    }
27375
 
27376
    public int compareTo(updateVendorString_args other) {
27377
      if (!getClass().equals(other.getClass())) {
27378
        return getClass().getName().compareTo(other.getClass().getName());
27379
      }
27380
 
27381
      int lastComparison = 0;
27382
      updateVendorString_args typedOther = (updateVendorString_args)other;
27383
 
27384
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
27385
      if (lastComparison != 0) {
27386
        return lastComparison;
27387
      }
27388
      if (isSetWarehouseId()) {
27389
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
27390
        if (lastComparison != 0) {
27391
          return lastComparison;
27392
        }
27393
      }
27394
      lastComparison = Boolean.valueOf(isSetVendorString()).compareTo(typedOther.isSetVendorString());
27395
      if (lastComparison != 0) {
27396
        return lastComparison;
27397
      }
27398
      if (isSetVendorString()) {
27399
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorString, typedOther.vendorString);
27400
        if (lastComparison != 0) {
27401
          return lastComparison;
27402
        }
27403
      }
27404
      return 0;
27405
    }
27406
 
27407
    public _Fields fieldForId(int fieldId) {
27408
      return _Fields.findByThriftId(fieldId);
27409
    }
27410
 
27411
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
27412
      org.apache.thrift.protocol.TField field;
27413
      iprot.readStructBegin();
27414
      while (true)
27415
      {
27416
        field = iprot.readFieldBegin();
27417
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
27418
          break;
27419
        }
27420
        switch (field.id) {
27421
          case 1: // WAREHOUSE_ID
27422
            if (field.type == org.apache.thrift.protocol.TType.I64) {
27423
              this.warehouseId = iprot.readI64();
27424
              setWarehouseIdIsSet(true);
27425
            } else { 
27426
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27427
            }
27428
            break;
27429
          case 2: // VENDOR_STRING
27430
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
27431
              this.vendorString = iprot.readString();
27432
            } else { 
27433
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27434
            }
27435
            break;
27436
          default:
27437
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27438
        }
27439
        iprot.readFieldEnd();
27440
      }
27441
      iprot.readStructEnd();
27442
      validate();
27443
    }
27444
 
27445
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
27446
      validate();
27447
 
27448
      oprot.writeStructBegin(STRUCT_DESC);
27449
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
27450
      oprot.writeI64(this.warehouseId);
27451
      oprot.writeFieldEnd();
27452
      if (this.vendorString != null) {
27453
        oprot.writeFieldBegin(VENDOR_STRING_FIELD_DESC);
27454
        oprot.writeString(this.vendorString);
27455
        oprot.writeFieldEnd();
27456
      }
27457
      oprot.writeFieldStop();
27458
      oprot.writeStructEnd();
27459
    }
27460
 
27461
    @Override
27462
    public String toString() {
27463
      StringBuilder sb = new StringBuilder("updateVendorString_args(");
27464
      boolean first = true;
27465
 
27466
      sb.append("warehouseId:");
27467
      sb.append(this.warehouseId);
27468
      first = false;
27469
      if (!first) sb.append(", ");
27470
      sb.append("vendorString:");
27471
      if (this.vendorString == null) {
27472
        sb.append("null");
27473
      } else {
27474
        sb.append(this.vendorString);
27475
      }
27476
      first = false;
27477
      sb.append(")");
27478
      return sb.toString();
27479
    }
27480
 
27481
    public void validate() throws org.apache.thrift.TException {
27482
      // check for required fields
27483
    }
27484
 
27485
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
27486
      try {
27487
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
27488
      } catch (org.apache.thrift.TException te) {
27489
        throw new java.io.IOException(te);
27490
      }
27491
    }
27492
 
27493
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
27494
      try {
5967 rajveer 27495
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
27496
        __isset_bit_vector = new BitSet(1);
5945 mandeep.dh 27497
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
27498
      } catch (org.apache.thrift.TException te) {
27499
        throw new java.io.IOException(te);
27500
      }
27501
    }
27502
 
27503
  }
27504
 
27505
  public static class updateVendorString_result implements org.apache.thrift.TBase<updateVendorString_result, updateVendorString_result._Fields>, java.io.Serializable, Cloneable   {
27506
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateVendorString_result");
27507
 
27508
 
27509
 
27510
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
27511
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
27512
;
27513
 
27514
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
27515
 
27516
      static {
27517
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
27518
          byName.put(field.getFieldName(), field);
27519
        }
27520
      }
27521
 
27522
      /**
27523
       * Find the _Fields constant that matches fieldId, or null if its not found.
27524
       */
27525
      public static _Fields findByThriftId(int fieldId) {
27526
        switch(fieldId) {
27527
          default:
27528
            return null;
27529
        }
27530
      }
27531
 
27532
      /**
27533
       * Find the _Fields constant that matches fieldId, throwing an exception
27534
       * if it is not found.
27535
       */
27536
      public static _Fields findByThriftIdOrThrow(int fieldId) {
27537
        _Fields fields = findByThriftId(fieldId);
27538
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
27539
        return fields;
27540
      }
27541
 
27542
      /**
27543
       * Find the _Fields constant that matches name, or null if its not found.
27544
       */
27545
      public static _Fields findByName(String name) {
27546
        return byName.get(name);
27547
      }
27548
 
27549
      private final short _thriftId;
27550
      private final String _fieldName;
27551
 
27552
      _Fields(short thriftId, String fieldName) {
27553
        _thriftId = thriftId;
27554
        _fieldName = fieldName;
27555
      }
27556
 
27557
      public short getThriftFieldId() {
27558
        return _thriftId;
27559
      }
27560
 
27561
      public String getFieldName() {
27562
        return _fieldName;
27563
      }
27564
    }
27565
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
27566
    static {
27567
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
27568
      metaDataMap = Collections.unmodifiableMap(tmpMap);
27569
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateVendorString_result.class, metaDataMap);
27570
    }
27571
 
27572
    public updateVendorString_result() {
27573
    }
27574
 
27575
    /**
27576
     * Performs a deep copy on <i>other</i>.
27577
     */
27578
    public updateVendorString_result(updateVendorString_result other) {
27579
    }
27580
 
27581
    public updateVendorString_result deepCopy() {
27582
      return new updateVendorString_result(this);
27583
    }
27584
 
27585
    @Override
27586
    public void clear() {
27587
    }
27588
 
27589
    public void setFieldValue(_Fields field, Object value) {
27590
      switch (field) {
27591
      }
27592
    }
27593
 
27594
    public Object getFieldValue(_Fields field) {
27595
      switch (field) {
27596
      }
27597
      throw new IllegalStateException();
27598
    }
27599
 
27600
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
27601
    public boolean isSet(_Fields field) {
27602
      if (field == null) {
27603
        throw new IllegalArgumentException();
27604
      }
27605
 
27606
      switch (field) {
27607
      }
27608
      throw new IllegalStateException();
27609
    }
27610
 
27611
    @Override
27612
    public boolean equals(Object that) {
27613
      if (that == null)
27614
        return false;
27615
      if (that instanceof updateVendorString_result)
27616
        return this.equals((updateVendorString_result)that);
27617
      return false;
27618
    }
27619
 
27620
    public boolean equals(updateVendorString_result that) {
27621
      if (that == null)
27622
        return false;
27623
 
27624
      return true;
27625
    }
27626
 
27627
    @Override
27628
    public int hashCode() {
27629
      return 0;
27630
    }
27631
 
27632
    public int compareTo(updateVendorString_result other) {
27633
      if (!getClass().equals(other.getClass())) {
27634
        return getClass().getName().compareTo(other.getClass().getName());
27635
      }
27636
 
27637
      int lastComparison = 0;
27638
      updateVendorString_result typedOther = (updateVendorString_result)other;
27639
 
27640
      return 0;
27641
    }
27642
 
27643
    public _Fields fieldForId(int fieldId) {
27644
      return _Fields.findByThriftId(fieldId);
27645
    }
27646
 
27647
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
27648
      org.apache.thrift.protocol.TField field;
27649
      iprot.readStructBegin();
27650
      while (true)
27651
      {
27652
        field = iprot.readFieldBegin();
27653
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
27654
          break;
27655
        }
27656
        switch (field.id) {
27657
          default:
27658
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27659
        }
27660
        iprot.readFieldEnd();
27661
      }
27662
      iprot.readStructEnd();
27663
      validate();
27664
    }
27665
 
27666
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
27667
      oprot.writeStructBegin(STRUCT_DESC);
27668
 
27669
      oprot.writeFieldStop();
27670
      oprot.writeStructEnd();
27671
    }
27672
 
27673
    @Override
27674
    public String toString() {
27675
      StringBuilder sb = new StringBuilder("updateVendorString_result(");
27676
      boolean first = true;
27677
 
27678
      sb.append(")");
27679
      return sb.toString();
27680
    }
27681
 
27682
    public void validate() throws org.apache.thrift.TException {
27683
      // check for required fields
27684
    }
27685
 
27686
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
27687
      try {
27688
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
27689
      } catch (org.apache.thrift.TException te) {
27690
        throw new java.io.IOException(te);
27691
      }
27692
    }
27693
 
27694
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
27695
      try {
27696
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
27697
      } catch (org.apache.thrift.TException te) {
27698
        throw new java.io.IOException(te);
27699
      }
27700
    }
27701
 
27702
  }
27703
 
6096 amit.gupta 27704
  public static class clearItemAvailabilityCacheForItem_args implements org.apache.thrift.TBase<clearItemAvailabilityCacheForItem_args, clearItemAvailabilityCacheForItem_args._Fields>, java.io.Serializable, Cloneable   {
27705
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCacheForItem_args");
27706
 
27707
    private static final org.apache.thrift.protocol.TField ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("item_id", org.apache.thrift.protocol.TType.I64, (short)1);
27708
 
27709
    private long item_id; // required
27710
 
27711
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
27712
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
27713
      ITEM_ID((short)1, "item_id");
27714
 
27715
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
27716
 
27717
      static {
27718
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
27719
          byName.put(field.getFieldName(), field);
27720
        }
27721
      }
27722
 
27723
      /**
27724
       * Find the _Fields constant that matches fieldId, or null if its not found.
27725
       */
27726
      public static _Fields findByThriftId(int fieldId) {
27727
        switch(fieldId) {
27728
          case 1: // ITEM_ID
27729
            return ITEM_ID;
27730
          default:
27731
            return null;
27732
        }
27733
      }
27734
 
27735
      /**
27736
       * Find the _Fields constant that matches fieldId, throwing an exception
27737
       * if it is not found.
27738
       */
27739
      public static _Fields findByThriftIdOrThrow(int fieldId) {
27740
        _Fields fields = findByThriftId(fieldId);
27741
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
27742
        return fields;
27743
      }
27744
 
27745
      /**
27746
       * Find the _Fields constant that matches name, or null if its not found.
27747
       */
27748
      public static _Fields findByName(String name) {
27749
        return byName.get(name);
27750
      }
27751
 
27752
      private final short _thriftId;
27753
      private final String _fieldName;
27754
 
27755
      _Fields(short thriftId, String fieldName) {
27756
        _thriftId = thriftId;
27757
        _fieldName = fieldName;
27758
      }
27759
 
27760
      public short getThriftFieldId() {
27761
        return _thriftId;
27762
      }
27763
 
27764
      public String getFieldName() {
27765
        return _fieldName;
27766
      }
27767
    }
27768
 
27769
    // isset id assignments
27770
    private static final int __ITEM_ID_ISSET_ID = 0;
27771
    private BitSet __isset_bit_vector = new BitSet(1);
27772
 
27773
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
27774
    static {
27775
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
27776
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
27777
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
27778
      metaDataMap = Collections.unmodifiableMap(tmpMap);
27779
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCacheForItem_args.class, metaDataMap);
27780
    }
27781
 
27782
    public clearItemAvailabilityCacheForItem_args() {
27783
    }
27784
 
27785
    public clearItemAvailabilityCacheForItem_args(
27786
      long item_id)
27787
    {
27788
      this();
27789
      this.item_id = item_id;
27790
      setItem_idIsSet(true);
27791
    }
27792
 
27793
    /**
27794
     * Performs a deep copy on <i>other</i>.
27795
     */
27796
    public clearItemAvailabilityCacheForItem_args(clearItemAvailabilityCacheForItem_args other) {
27797
      __isset_bit_vector.clear();
27798
      __isset_bit_vector.or(other.__isset_bit_vector);
27799
      this.item_id = other.item_id;
27800
    }
27801
 
27802
    public clearItemAvailabilityCacheForItem_args deepCopy() {
27803
      return new clearItemAvailabilityCacheForItem_args(this);
27804
    }
27805
 
27806
    @Override
27807
    public void clear() {
27808
      setItem_idIsSet(false);
27809
      this.item_id = 0;
27810
    }
27811
 
27812
    public long getItem_id() {
27813
      return this.item_id;
27814
    }
27815
 
27816
    public void setItem_id(long item_id) {
27817
      this.item_id = item_id;
27818
      setItem_idIsSet(true);
27819
    }
27820
 
27821
    public void unsetItem_id() {
27822
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
27823
    }
27824
 
27825
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
27826
    public boolean isSetItem_id() {
27827
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
27828
    }
27829
 
27830
    public void setItem_idIsSet(boolean value) {
27831
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
27832
    }
27833
 
27834
    public void setFieldValue(_Fields field, Object value) {
27835
      switch (field) {
27836
      case ITEM_ID:
27837
        if (value == null) {
27838
          unsetItem_id();
27839
        } else {
27840
          setItem_id((Long)value);
27841
        }
27842
        break;
27843
 
27844
      }
27845
    }
27846
 
27847
    public Object getFieldValue(_Fields field) {
27848
      switch (field) {
27849
      case ITEM_ID:
27850
        return Long.valueOf(getItem_id());
27851
 
27852
      }
27853
      throw new IllegalStateException();
27854
    }
27855
 
27856
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
27857
    public boolean isSet(_Fields field) {
27858
      if (field == null) {
27859
        throw new IllegalArgumentException();
27860
      }
27861
 
27862
      switch (field) {
27863
      case ITEM_ID:
27864
        return isSetItem_id();
27865
      }
27866
      throw new IllegalStateException();
27867
    }
27868
 
27869
    @Override
27870
    public boolean equals(Object that) {
27871
      if (that == null)
27872
        return false;
27873
      if (that instanceof clearItemAvailabilityCacheForItem_args)
27874
        return this.equals((clearItemAvailabilityCacheForItem_args)that);
27875
      return false;
27876
    }
27877
 
27878
    public boolean equals(clearItemAvailabilityCacheForItem_args that) {
27879
      if (that == null)
27880
        return false;
27881
 
27882
      boolean this_present_item_id = true;
27883
      boolean that_present_item_id = true;
27884
      if (this_present_item_id || that_present_item_id) {
27885
        if (!(this_present_item_id && that_present_item_id))
27886
          return false;
27887
        if (this.item_id != that.item_id)
27888
          return false;
27889
      }
27890
 
27891
      return true;
27892
    }
27893
 
27894
    @Override
27895
    public int hashCode() {
27896
      return 0;
27897
    }
27898
 
27899
    public int compareTo(clearItemAvailabilityCacheForItem_args other) {
27900
      if (!getClass().equals(other.getClass())) {
27901
        return getClass().getName().compareTo(other.getClass().getName());
27902
      }
27903
 
27904
      int lastComparison = 0;
27905
      clearItemAvailabilityCacheForItem_args typedOther = (clearItemAvailabilityCacheForItem_args)other;
27906
 
27907
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
27908
      if (lastComparison != 0) {
27909
        return lastComparison;
27910
      }
27911
      if (isSetItem_id()) {
27912
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
27913
        if (lastComparison != 0) {
27914
          return lastComparison;
27915
        }
27916
      }
27917
      return 0;
27918
    }
27919
 
27920
    public _Fields fieldForId(int fieldId) {
27921
      return _Fields.findByThriftId(fieldId);
27922
    }
27923
 
27924
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
27925
      org.apache.thrift.protocol.TField field;
27926
      iprot.readStructBegin();
27927
      while (true)
27928
      {
27929
        field = iprot.readFieldBegin();
27930
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
27931
          break;
27932
        }
27933
        switch (field.id) {
27934
          case 1: // ITEM_ID
27935
            if (field.type == org.apache.thrift.protocol.TType.I64) {
27936
              this.item_id = iprot.readI64();
27937
              setItem_idIsSet(true);
27938
            } else { 
27939
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27940
            }
27941
            break;
27942
          default:
27943
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27944
        }
27945
        iprot.readFieldEnd();
27946
      }
27947
      iprot.readStructEnd();
27948
      validate();
27949
    }
27950
 
27951
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
27952
      validate();
27953
 
27954
      oprot.writeStructBegin(STRUCT_DESC);
27955
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
27956
      oprot.writeI64(this.item_id);
27957
      oprot.writeFieldEnd();
27958
      oprot.writeFieldStop();
27959
      oprot.writeStructEnd();
27960
    }
27961
 
27962
    @Override
27963
    public String toString() {
27964
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCacheForItem_args(");
27965
      boolean first = true;
27966
 
27967
      sb.append("item_id:");
27968
      sb.append(this.item_id);
27969
      first = false;
27970
      sb.append(")");
27971
      return sb.toString();
27972
    }
27973
 
27974
    public void validate() throws org.apache.thrift.TException {
27975
      // check for required fields
27976
    }
27977
 
27978
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
27979
      try {
27980
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
27981
      } catch (org.apache.thrift.TException te) {
27982
        throw new java.io.IOException(te);
27983
      }
27984
    }
27985
 
27986
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
27987
      try {
27988
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
27989
        __isset_bit_vector = new BitSet(1);
27990
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
27991
      } catch (org.apache.thrift.TException te) {
27992
        throw new java.io.IOException(te);
27993
      }
27994
    }
27995
 
27996
  }
27997
 
27998
  public static class clearItemAvailabilityCacheForItem_result implements org.apache.thrift.TBase<clearItemAvailabilityCacheForItem_result, clearItemAvailabilityCacheForItem_result._Fields>, java.io.Serializable, Cloneable   {
27999
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCacheForItem_result");
28000
 
28001
 
28002
 
28003
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
28004
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
28005
;
28006
 
28007
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
28008
 
28009
      static {
28010
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
28011
          byName.put(field.getFieldName(), field);
28012
        }
28013
      }
28014
 
28015
      /**
28016
       * Find the _Fields constant that matches fieldId, or null if its not found.
28017
       */
28018
      public static _Fields findByThriftId(int fieldId) {
28019
        switch(fieldId) {
28020
          default:
28021
            return null;
28022
        }
28023
      }
28024
 
28025
      /**
28026
       * Find the _Fields constant that matches fieldId, throwing an exception
28027
       * if it is not found.
28028
       */
28029
      public static _Fields findByThriftIdOrThrow(int fieldId) {
28030
        _Fields fields = findByThriftId(fieldId);
28031
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
28032
        return fields;
28033
      }
28034
 
28035
      /**
28036
       * Find the _Fields constant that matches name, or null if its not found.
28037
       */
28038
      public static _Fields findByName(String name) {
28039
        return byName.get(name);
28040
      }
28041
 
28042
      private final short _thriftId;
28043
      private final String _fieldName;
28044
 
28045
      _Fields(short thriftId, String fieldName) {
28046
        _thriftId = thriftId;
28047
        _fieldName = fieldName;
28048
      }
28049
 
28050
      public short getThriftFieldId() {
28051
        return _thriftId;
28052
      }
28053
 
28054
      public String getFieldName() {
28055
        return _fieldName;
28056
      }
28057
    }
28058
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
28059
    static {
28060
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
28061
      metaDataMap = Collections.unmodifiableMap(tmpMap);
28062
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCacheForItem_result.class, metaDataMap);
28063
    }
28064
 
28065
    public clearItemAvailabilityCacheForItem_result() {
28066
    }
28067
 
28068
    /**
28069
     * Performs a deep copy on <i>other</i>.
28070
     */
28071
    public clearItemAvailabilityCacheForItem_result(clearItemAvailabilityCacheForItem_result other) {
28072
    }
28073
 
28074
    public clearItemAvailabilityCacheForItem_result deepCopy() {
28075
      return new clearItemAvailabilityCacheForItem_result(this);
28076
    }
28077
 
28078
    @Override
28079
    public void clear() {
28080
    }
28081
 
28082
    public void setFieldValue(_Fields field, Object value) {
28083
      switch (field) {
28084
      }
28085
    }
28086
 
28087
    public Object getFieldValue(_Fields field) {
28088
      switch (field) {
28089
      }
28090
      throw new IllegalStateException();
28091
    }
28092
 
28093
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
28094
    public boolean isSet(_Fields field) {
28095
      if (field == null) {
28096
        throw new IllegalArgumentException();
28097
      }
28098
 
28099
      switch (field) {
28100
      }
28101
      throw new IllegalStateException();
28102
    }
28103
 
28104
    @Override
28105
    public boolean equals(Object that) {
28106
      if (that == null)
28107
        return false;
28108
      if (that instanceof clearItemAvailabilityCacheForItem_result)
28109
        return this.equals((clearItemAvailabilityCacheForItem_result)that);
28110
      return false;
28111
    }
28112
 
28113
    public boolean equals(clearItemAvailabilityCacheForItem_result that) {
28114
      if (that == null)
28115
        return false;
28116
 
28117
      return true;
28118
    }
28119
 
28120
    @Override
28121
    public int hashCode() {
28122
      return 0;
28123
    }
28124
 
28125
    public int compareTo(clearItemAvailabilityCacheForItem_result other) {
28126
      if (!getClass().equals(other.getClass())) {
28127
        return getClass().getName().compareTo(other.getClass().getName());
28128
      }
28129
 
28130
      int lastComparison = 0;
28131
      clearItemAvailabilityCacheForItem_result typedOther = (clearItemAvailabilityCacheForItem_result)other;
28132
 
28133
      return 0;
28134
    }
28135
 
28136
    public _Fields fieldForId(int fieldId) {
28137
      return _Fields.findByThriftId(fieldId);
28138
    }
28139
 
28140
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
28141
      org.apache.thrift.protocol.TField field;
28142
      iprot.readStructBegin();
28143
      while (true)
28144
      {
28145
        field = iprot.readFieldBegin();
28146
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
28147
          break;
28148
        }
28149
        switch (field.id) {
28150
          default:
28151
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
28152
        }
28153
        iprot.readFieldEnd();
28154
      }
28155
      iprot.readStructEnd();
28156
      validate();
28157
    }
28158
 
28159
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
28160
      oprot.writeStructBegin(STRUCT_DESC);
28161
 
28162
      oprot.writeFieldStop();
28163
      oprot.writeStructEnd();
28164
    }
28165
 
28166
    @Override
28167
    public String toString() {
28168
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCacheForItem_result(");
28169
      boolean first = true;
28170
 
28171
      sb.append(")");
28172
      return sb.toString();
28173
    }
28174
 
28175
    public void validate() throws org.apache.thrift.TException {
28176
      // check for required fields
28177
    }
28178
 
28179
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
28180
      try {
28181
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
28182
      } catch (org.apache.thrift.TException te) {
28183
        throw new java.io.IOException(te);
28184
      }
28185
    }
28186
 
28187
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
28188
      try {
28189
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
28190
      } catch (org.apache.thrift.TException te) {
28191
        throw new java.io.IOException(te);
28192
      }
28193
    }
28194
 
28195
  }
28196
 
5945 mandeep.dh 28197
}