Subversion Repositories SmartDukaan

Rev

Rev 5967 | Rev 6096 | 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
 
280
  }
281
 
282
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
283
 
284
    public void addWarehouse(Warehouse warehouse, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addWarehouse_call> resultHandler) throws org.apache.thrift.TException;
285
 
286
    public void addVendor(Vendor vendor, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendor_call> resultHandler) throws org.apache.thrift.TException;
287
 
288
    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;
289
 
290
    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;
291
 
292
    public void addInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addInventory_call> resultHandler) throws org.apache.thrift.TException;
293
 
294
    public void retireWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.retireWarehouse_call> resultHandler) throws org.apache.thrift.TException;
295
 
296
    public void getItemInventoryByItemId(long item_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemInventoryByItemId_call> resultHandler) throws org.apache.thrift.TException;
297
 
298
    public void getItemAvailibilityAtWarehouse(long warehouse_id, long item_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemAvailibilityAtWarehouse_call> resultHandler) throws org.apache.thrift.TException;
299
 
5978 rajveer 300
    public void getItemAvailabilityAtLocation(long itemId, long sourceId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemAvailabilityAtLocation_call> resultHandler) throws org.apache.thrift.TException;
5945 mandeep.dh 301
 
302
    public void getAllWarehouses(boolean isActive, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllWarehouses_call> resultHandler) throws org.apache.thrift.TException;
303
 
304
    public void getWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getWarehouse_call> resultHandler) throws org.apache.thrift.TException;
305
 
306
    public void getAllItemsForWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllItemsForWarehouse_call> resultHandler) throws org.apache.thrift.TException;
307
 
5967 rajveer 308
    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 309
 
5967 rajveer 310
    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 311
 
5967 rajveer 312
    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;
313
 
5945 mandeep.dh 314
    public void getItemPricing(long itemId, long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemPricing_call> resultHandler) throws org.apache.thrift.TException;
315
 
316
    public void getAllItemPricing(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllItemPricing_call> resultHandler) throws org.apache.thrift.TException;
317
 
318
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendorItemPricing_call> resultHandler) throws org.apache.thrift.TException;
319
 
320
    public void getVendor(long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getVendor_call> resultHandler) throws org.apache.thrift.TException;
321
 
322
    public void getAllVendors(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllVendors_call> resultHandler) throws org.apache.thrift.TException;
323
 
324
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendorItemMapping_call> resultHandler) throws org.apache.thrift.TException;
325
 
326
    public void getVendorItemMappings(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException;
327
 
328
    public void getPendingOrdersInventory(long vendorid, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPendingOrdersInventory_call> resultHandler) throws org.apache.thrift.TException;
329
 
330
    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;
331
 
332
    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;
333
 
334
    public void resetAvailabilityForWarehouse(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.resetAvailabilityForWarehouse_call> resultHandler) throws org.apache.thrift.TException;
335
 
336
    public void getItemKeysToBeProcessed(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemKeysToBeProcessed_call> resultHandler) throws org.apache.thrift.TException;
337
 
338
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.markMissedInventoryUpdatesAsProcessed_call> resultHandler) throws org.apache.thrift.TException;
339
 
340
    public void getIgnoredItemKeys(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getIgnoredItemKeys_call> resultHandler) throws org.apache.thrift.TException;
341
 
342
    public void addBadInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addBadInventory_call> resultHandler) throws org.apache.thrift.TException;
343
 
344
    public void getShippingLocations(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getShippingLocations_call> resultHandler) throws org.apache.thrift.TException;
345
 
346
    public void getAllVendorItemMappings(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException;
347
 
348
    public void getInventorySnapshot(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventorySnapshot_call> resultHandler) throws org.apache.thrift.TException;
349
 
350
    public void clearItemAvailabilityCache(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.clearItemAvailabilityCache_call> resultHandler) throws org.apache.thrift.TException;
351
 
352
    public void updateVendorString(long warehouseId, String vendorString, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updateVendorString_call> resultHandler) throws org.apache.thrift.TException;
353
 
354
  }
355
 
356
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
357
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
358
      public Factory() {}
359
      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
360
        return new Client(prot);
361
      }
362
      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
363
        return new Client(iprot, oprot);
364
      }
365
    }
366
 
367
    public Client(org.apache.thrift.protocol.TProtocol prot)
368
    {
369
      super(prot, prot);
370
    }
371
 
372
    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
373
      super(iprot, oprot);
374
    }
375
 
376
    public long addWarehouse(Warehouse warehouse) throws InventoryServiceException, org.apache.thrift.TException
377
    {
378
      send_addWarehouse(warehouse);
379
      return recv_addWarehouse();
380
    }
381
 
382
    public void send_addWarehouse(Warehouse warehouse) throws org.apache.thrift.TException
383
    {
384
      addWarehouse_args args = new addWarehouse_args();
385
      args.setWarehouse(warehouse);
386
      sendBase("addWarehouse", args);
387
    }
388
 
389
    public long recv_addWarehouse() throws InventoryServiceException, org.apache.thrift.TException
390
    {
391
      addWarehouse_result result = new addWarehouse_result();
392
      receiveBase(result, "addWarehouse");
393
      if (result.isSetSuccess()) {
394
        return result.success;
395
      }
396
      if (result.cex != null) {
397
        throw result.cex;
398
      }
399
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addWarehouse failed: unknown result");
400
    }
401
 
402
    public long addVendor(Vendor vendor) throws InventoryServiceException, org.apache.thrift.TException
403
    {
404
      send_addVendor(vendor);
405
      return recv_addVendor();
406
    }
407
 
408
    public void send_addVendor(Vendor vendor) throws org.apache.thrift.TException
409
    {
410
      addVendor_args args = new addVendor_args();
411
      args.setVendor(vendor);
412
      sendBase("addVendor", args);
413
    }
414
 
415
    public long recv_addVendor() throws InventoryServiceException, org.apache.thrift.TException
416
    {
417
      addVendor_result result = new addVendor_result();
418
      receiveBase(result, "addVendor");
419
      if (result.isSetSuccess()) {
420
        return result.success;
421
      }
422
      if (result.cex != null) {
423
        throw result.cex;
424
      }
425
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addVendor failed: unknown result");
426
    }
427
 
428
    public void updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException
429
    {
430
      send_updateInventoryHistory(warehouse_id, timestamp, availability);
431
      recv_updateInventoryHistory();
432
    }
433
 
434
    public void send_updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws org.apache.thrift.TException
435
    {
436
      updateInventoryHistory_args args = new updateInventoryHistory_args();
437
      args.setWarehouse_id(warehouse_id);
438
      args.setTimestamp(timestamp);
439
      args.setAvailability(availability);
440
      sendBase("updateInventoryHistory", args);
441
    }
442
 
443
    public void recv_updateInventoryHistory() throws InventoryServiceException, org.apache.thrift.TException
444
    {
445
      updateInventoryHistory_result result = new updateInventoryHistory_result();
446
      receiveBase(result, "updateInventoryHistory");
447
      if (result.cex != null) {
448
        throw result.cex;
449
      }
450
      return;
451
    }
452
 
453
    public void updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException
454
    {
455
      send_updateInventory(warehouse_id, timestamp, availability);
456
      recv_updateInventory();
457
    }
458
 
459
    public void send_updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws org.apache.thrift.TException
460
    {
461
      updateInventory_args args = new updateInventory_args();
462
      args.setWarehouse_id(warehouse_id);
463
      args.setTimestamp(timestamp);
464
      args.setAvailability(availability);
465
      sendBase("updateInventory", args);
466
    }
467
 
468
    public void recv_updateInventory() throws InventoryServiceException, org.apache.thrift.TException
469
    {
470
      updateInventory_result result = new updateInventory_result();
471
      receiveBase(result, "updateInventory");
472
      if (result.cex != null) {
473
        throw result.cex;
474
      }
475
      return;
476
    }
477
 
478
    public void addInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException
479
    {
480
      send_addInventory(itemId, warehouseId, quantity);
481
      recv_addInventory();
482
    }
483
 
484
    public void send_addInventory(long itemId, long warehouseId, long quantity) throws org.apache.thrift.TException
485
    {
486
      addInventory_args args = new addInventory_args();
487
      args.setItemId(itemId);
488
      args.setWarehouseId(warehouseId);
489
      args.setQuantity(quantity);
490
      sendBase("addInventory", args);
491
    }
492
 
493
    public void recv_addInventory() throws InventoryServiceException, org.apache.thrift.TException
494
    {
495
      addInventory_result result = new addInventory_result();
496
      receiveBase(result, "addInventory");
497
      if (result.cex != null) {
498
        throw result.cex;
499
      }
500
      return;
501
    }
502
 
503
    public void retireWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
504
    {
505
      send_retireWarehouse(warehouse_id);
506
      recv_retireWarehouse();
507
    }
508
 
509
    public void send_retireWarehouse(long warehouse_id) throws org.apache.thrift.TException
510
    {
511
      retireWarehouse_args args = new retireWarehouse_args();
512
      args.setWarehouse_id(warehouse_id);
513
      sendBase("retireWarehouse", args);
514
    }
515
 
516
    public void recv_retireWarehouse() throws InventoryServiceException, org.apache.thrift.TException
517
    {
518
      retireWarehouse_result result = new retireWarehouse_result();
519
      receiveBase(result, "retireWarehouse");
520
      if (result.cex != null) {
521
        throw result.cex;
522
      }
523
      return;
524
    }
525
 
526
    public ItemInventory getItemInventoryByItemId(long item_id) throws InventoryServiceException, org.apache.thrift.TException
527
    {
528
      send_getItemInventoryByItemId(item_id);
529
      return recv_getItemInventoryByItemId();
530
    }
531
 
532
    public void send_getItemInventoryByItemId(long item_id) throws org.apache.thrift.TException
533
    {
534
      getItemInventoryByItemId_args args = new getItemInventoryByItemId_args();
535
      args.setItem_id(item_id);
536
      sendBase("getItemInventoryByItemId", args);
537
    }
538
 
539
    public ItemInventory recv_getItemInventoryByItemId() throws InventoryServiceException, org.apache.thrift.TException
540
    {
541
      getItemInventoryByItemId_result result = new getItemInventoryByItemId_result();
542
      receiveBase(result, "getItemInventoryByItemId");
543
      if (result.isSetSuccess()) {
544
        return result.success;
545
      }
546
      if (result.cex != null) {
547
        throw result.cex;
548
      }
549
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemInventoryByItemId failed: unknown result");
550
    }
551
 
552
    public long getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws InventoryServiceException, org.apache.thrift.TException
553
    {
554
      send_getItemAvailibilityAtWarehouse(warehouse_id, item_id);
555
      return recv_getItemAvailibilityAtWarehouse();
556
    }
557
 
558
    public void send_getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws org.apache.thrift.TException
559
    {
560
      getItemAvailibilityAtWarehouse_args args = new getItemAvailibilityAtWarehouse_args();
561
      args.setWarehouse_id(warehouse_id);
562
      args.setItem_id(item_id);
563
      sendBase("getItemAvailibilityAtWarehouse", args);
564
    }
565
 
566
    public long recv_getItemAvailibilityAtWarehouse() throws InventoryServiceException, org.apache.thrift.TException
567
    {
568
      getItemAvailibilityAtWarehouse_result result = new getItemAvailibilityAtWarehouse_result();
569
      receiveBase(result, "getItemAvailibilityAtWarehouse");
570
      if (result.isSetSuccess()) {
571
        return result.success;
572
      }
573
      if (result.cex != null) {
574
        throw result.cex;
575
      }
576
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemAvailibilityAtWarehouse failed: unknown result");
577
    }
578
 
5978 rajveer 579
    public List<Long> getItemAvailabilityAtLocation(long itemId, long sourceId) throws InventoryServiceException, org.apache.thrift.TException
5945 mandeep.dh 580
    {
5978 rajveer 581
      send_getItemAvailabilityAtLocation(itemId, sourceId);
5945 mandeep.dh 582
      return recv_getItemAvailabilityAtLocation();
583
    }
584
 
5978 rajveer 585
    public void send_getItemAvailabilityAtLocation(long itemId, long sourceId) throws org.apache.thrift.TException
5945 mandeep.dh 586
    {
587
      getItemAvailabilityAtLocation_args args = new getItemAvailabilityAtLocation_args();
588
      args.setItemId(itemId);
5978 rajveer 589
      args.setSourceId(sourceId);
5945 mandeep.dh 590
      sendBase("getItemAvailabilityAtLocation", args);
591
    }
592
 
593
    public List<Long> recv_getItemAvailabilityAtLocation() throws InventoryServiceException, org.apache.thrift.TException
594
    {
595
      getItemAvailabilityAtLocation_result result = new getItemAvailabilityAtLocation_result();
596
      receiveBase(result, "getItemAvailabilityAtLocation");
597
      if (result.isSetSuccess()) {
598
        return result.success;
599
      }
600
      if (result.isex != null) {
601
        throw result.isex;
602
      }
603
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemAvailabilityAtLocation failed: unknown result");
604
    }
605
 
606
    public List<Warehouse> getAllWarehouses(boolean isActive) throws InventoryServiceException, org.apache.thrift.TException
607
    {
608
      send_getAllWarehouses(isActive);
609
      return recv_getAllWarehouses();
610
    }
611
 
612
    public void send_getAllWarehouses(boolean isActive) throws org.apache.thrift.TException
613
    {
614
      getAllWarehouses_args args = new getAllWarehouses_args();
615
      args.setIsActive(isActive);
616
      sendBase("getAllWarehouses", args);
617
    }
618
 
619
    public List<Warehouse> recv_getAllWarehouses() throws InventoryServiceException, org.apache.thrift.TException
620
    {
621
      getAllWarehouses_result result = new getAllWarehouses_result();
622
      receiveBase(result, "getAllWarehouses");
623
      if (result.isSetSuccess()) {
624
        return result.success;
625
      }
626
      if (result.cex != null) {
627
        throw result.cex;
628
      }
629
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllWarehouses failed: unknown result");
630
    }
631
 
632
    public Warehouse getWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
633
    {
634
      send_getWarehouse(warehouse_id);
635
      return recv_getWarehouse();
636
    }
637
 
638
    public void send_getWarehouse(long warehouse_id) throws org.apache.thrift.TException
639
    {
640
      getWarehouse_args args = new getWarehouse_args();
641
      args.setWarehouse_id(warehouse_id);
642
      sendBase("getWarehouse", args);
643
    }
644
 
645
    public Warehouse recv_getWarehouse() throws InventoryServiceException, org.apache.thrift.TException
646
    {
647
      getWarehouse_result result = new getWarehouse_result();
648
      receiveBase(result, "getWarehouse");
649
      if (result.isSetSuccess()) {
650
        return result.success;
651
      }
652
      if (result.cex != null) {
653
        throw result.cex;
654
      }
655
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getWarehouse failed: unknown result");
656
    }
657
 
658
    public List<Long> getAllItemsForWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
659
    {
660
      send_getAllItemsForWarehouse(warehouse_id);
661
      return recv_getAllItemsForWarehouse();
662
    }
663
 
664
    public void send_getAllItemsForWarehouse(long warehouse_id) throws org.apache.thrift.TException
665
    {
666
      getAllItemsForWarehouse_args args = new getAllItemsForWarehouse_args();
667
      args.setWarehouse_id(warehouse_id);
668
      sendBase("getAllItemsForWarehouse", args);
669
    }
670
 
671
    public List<Long> recv_getAllItemsForWarehouse() throws InventoryServiceException, org.apache.thrift.TException
672
    {
673
      getAllItemsForWarehouse_result result = new getAllItemsForWarehouse_result();
674
      receiveBase(result, "getAllItemsForWarehouse");
675
      if (result.isSetSuccess()) {
676
        return result.success;
677
      }
678
      if (result.cex != null) {
679
        throw result.cex;
680
      }
681
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllItemsForWarehouse failed: unknown result");
682
    }
683
 
5967 rajveer 684
    public boolean isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId) throws org.apache.thrift.TException
5945 mandeep.dh 685
    {
5967 rajveer 686
      send_isOrderBillable(itemId, warehouseId, sourceId, orderId);
687
      return recv_isOrderBillable();
688
    }
689
 
690
    public void send_isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId) throws org.apache.thrift.TException
691
    {
692
      isOrderBillable_args args = new isOrderBillable_args();
693
      args.setItemId(itemId);
694
      args.setWarehouseId(warehouseId);
695
      args.setSourceId(sourceId);
696
      args.setOrderId(orderId);
697
      sendBase("isOrderBillable", args);
698
    }
699
 
700
    public boolean recv_isOrderBillable() throws org.apache.thrift.TException
701
    {
702
      isOrderBillable_result result = new isOrderBillable_result();
703
      receiveBase(result, "isOrderBillable");
704
      if (result.isSetSuccess()) {
705
        return result.success;
706
      }
707
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "isOrderBillable failed: unknown result");
708
    }
709
 
710
    public boolean reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity) throws InventoryServiceException, org.apache.thrift.TException
711
    {
712
      send_reserveItemInWarehouse(itemId, warehouseId, sourceId, orderId, createdTimestamp, promisedShippingTimestamp, quantity);
5945 mandeep.dh 713
      return recv_reserveItemInWarehouse();
714
    }
715
 
5967 rajveer 716
    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 717
    {
718
      reserveItemInWarehouse_args args = new reserveItemInWarehouse_args();
719
      args.setItemId(itemId);
720
      args.setWarehouseId(warehouseId);
5967 rajveer 721
      args.setSourceId(sourceId);
722
      args.setOrderId(orderId);
723
      args.setCreatedTimestamp(createdTimestamp);
724
      args.setPromisedShippingTimestamp(promisedShippingTimestamp);
5945 mandeep.dh 725
      args.setQuantity(quantity);
726
      sendBase("reserveItemInWarehouse", args);
727
    }
728
 
729
    public boolean recv_reserveItemInWarehouse() throws InventoryServiceException, org.apache.thrift.TException
730
    {
731
      reserveItemInWarehouse_result result = new reserveItemInWarehouse_result();
732
      receiveBase(result, "reserveItemInWarehouse");
733
      if (result.isSetSuccess()) {
734
        return result.success;
735
      }
736
      if (result.cex != null) {
737
        throw result.cex;
738
      }
739
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "reserveItemInWarehouse failed: unknown result");
740
    }
741
 
5967 rajveer 742
    public boolean reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity) throws InventoryServiceException, org.apache.thrift.TException
5945 mandeep.dh 743
    {
5967 rajveer 744
      send_reduceReservationCount(itemId, warehouseId, sourceId, orderId, quantity);
5945 mandeep.dh 745
      return recv_reduceReservationCount();
746
    }
747
 
5967 rajveer 748
    public void send_reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity) throws org.apache.thrift.TException
5945 mandeep.dh 749
    {
750
      reduceReservationCount_args args = new reduceReservationCount_args();
751
      args.setItemId(itemId);
752
      args.setWarehouseId(warehouseId);
5967 rajveer 753
      args.setSourceId(sourceId);
754
      args.setOrderId(orderId);
5945 mandeep.dh 755
      args.setQuantity(quantity);
756
      sendBase("reduceReservationCount", args);
757
    }
758
 
759
    public boolean recv_reduceReservationCount() throws InventoryServiceException, org.apache.thrift.TException
760
    {
761
      reduceReservationCount_result result = new reduceReservationCount_result();
762
      receiveBase(result, "reduceReservationCount");
763
      if (result.isSetSuccess()) {
764
        return result.success;
765
      }
766
      if (result.cex != null) {
767
        throw result.cex;
768
      }
769
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "reduceReservationCount failed: unknown result");
770
    }
771
 
772
    public VendorItemPricing getItemPricing(long itemId, long vendorId) throws InventoryServiceException, org.apache.thrift.TException
773
    {
774
      send_getItemPricing(itemId, vendorId);
775
      return recv_getItemPricing();
776
    }
777
 
778
    public void send_getItemPricing(long itemId, long vendorId) throws org.apache.thrift.TException
779
    {
780
      getItemPricing_args args = new getItemPricing_args();
781
      args.setItemId(itemId);
782
      args.setVendorId(vendorId);
783
      sendBase("getItemPricing", args);
784
    }
785
 
786
    public VendorItemPricing recv_getItemPricing() throws InventoryServiceException, org.apache.thrift.TException
787
    {
788
      getItemPricing_result result = new getItemPricing_result();
789
      receiveBase(result, "getItemPricing");
790
      if (result.isSetSuccess()) {
791
        return result.success;
792
      }
793
      if (result.cex != null) {
794
        throw result.cex;
795
      }
796
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemPricing failed: unknown result");
797
    }
798
 
799
    public List<VendorItemPricing> getAllItemPricing(long itemId) throws InventoryServiceException, org.apache.thrift.TException
800
    {
801
      send_getAllItemPricing(itemId);
802
      return recv_getAllItemPricing();
803
    }
804
 
805
    public void send_getAllItemPricing(long itemId) throws org.apache.thrift.TException
806
    {
807
      getAllItemPricing_args args = new getAllItemPricing_args();
808
      args.setItemId(itemId);
809
      sendBase("getAllItemPricing", args);
810
    }
811
 
812
    public List<VendorItemPricing> recv_getAllItemPricing() throws InventoryServiceException, org.apache.thrift.TException
813
    {
814
      getAllItemPricing_result result = new getAllItemPricing_result();
815
      receiveBase(result, "getAllItemPricing");
816
      if (result.isSetSuccess()) {
817
        return result.success;
818
      }
819
      if (result.cex != null) {
820
        throw result.cex;
821
      }
822
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllItemPricing failed: unknown result");
823
    }
824
 
825
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing) throws InventoryServiceException, org.apache.thrift.TException
826
    {
827
      send_addVendorItemPricing(vendorItemPricing);
828
      recv_addVendorItemPricing();
829
    }
830
 
831
    public void send_addVendorItemPricing(VendorItemPricing vendorItemPricing) throws org.apache.thrift.TException
832
    {
833
      addVendorItemPricing_args args = new addVendorItemPricing_args();
834
      args.setVendorItemPricing(vendorItemPricing);
835
      sendBase("addVendorItemPricing", args);
836
    }
837
 
838
    public void recv_addVendorItemPricing() throws InventoryServiceException, org.apache.thrift.TException
839
    {
840
      addVendorItemPricing_result result = new addVendorItemPricing_result();
841
      receiveBase(result, "addVendorItemPricing");
842
      if (result.cex != null) {
843
        throw result.cex;
844
      }
845
      return;
846
    }
847
 
848
    public Vendor getVendor(long vendorId) throws org.apache.thrift.TException
849
    {
850
      send_getVendor(vendorId);
851
      return recv_getVendor();
852
    }
853
 
854
    public void send_getVendor(long vendorId) throws org.apache.thrift.TException
855
    {
856
      getVendor_args args = new getVendor_args();
857
      args.setVendorId(vendorId);
858
      sendBase("getVendor", args);
859
    }
860
 
861
    public Vendor recv_getVendor() throws org.apache.thrift.TException
862
    {
863
      getVendor_result result = new getVendor_result();
864
      receiveBase(result, "getVendor");
865
      if (result.isSetSuccess()) {
866
        return result.success;
867
      }
868
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getVendor failed: unknown result");
869
    }
870
 
871
    public List<Vendor> getAllVendors() throws org.apache.thrift.TException
872
    {
873
      send_getAllVendors();
874
      return recv_getAllVendors();
875
    }
876
 
877
    public void send_getAllVendors() throws org.apache.thrift.TException
878
    {
879
      getAllVendors_args args = new getAllVendors_args();
880
      sendBase("getAllVendors", args);
881
    }
882
 
883
    public List<Vendor> recv_getAllVendors() throws org.apache.thrift.TException
884
    {
885
      getAllVendors_result result = new getAllVendors_result();
886
      receiveBase(result, "getAllVendors");
887
      if (result.isSetSuccess()) {
888
        return result.success;
889
      }
890
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllVendors failed: unknown result");
891
    }
892
 
893
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws InventoryServiceException, org.apache.thrift.TException
894
    {
895
      send_addVendorItemMapping(key, vendorItemMapping);
896
      recv_addVendorItemMapping();
897
    }
898
 
899
    public void send_addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws org.apache.thrift.TException
900
    {
901
      addVendorItemMapping_args args = new addVendorItemMapping_args();
902
      args.setKey(key);
903
      args.setVendorItemMapping(vendorItemMapping);
904
      sendBase("addVendorItemMapping", args);
905
    }
906
 
907
    public void recv_addVendorItemMapping() throws InventoryServiceException, org.apache.thrift.TException
908
    {
909
      addVendorItemMapping_result result = new addVendorItemMapping_result();
910
      receiveBase(result, "addVendorItemMapping");
911
      if (result.cex != null) {
912
        throw result.cex;
913
      }
914
      return;
915
    }
916
 
917
    public List<VendorItemMapping> getVendorItemMappings(long itemId) throws InventoryServiceException, org.apache.thrift.TException
918
    {
919
      send_getVendorItemMappings(itemId);
920
      return recv_getVendorItemMappings();
921
    }
922
 
923
    public void send_getVendorItemMappings(long itemId) throws org.apache.thrift.TException
924
    {
925
      getVendorItemMappings_args args = new getVendorItemMappings_args();
926
      args.setItemId(itemId);
927
      sendBase("getVendorItemMappings", args);
928
    }
929
 
930
    public List<VendorItemMapping> recv_getVendorItemMappings() throws InventoryServiceException, org.apache.thrift.TException
931
    {
932
      getVendorItemMappings_result result = new getVendorItemMappings_result();
933
      receiveBase(result, "getVendorItemMappings");
934
      if (result.isSetSuccess()) {
935
        return result.success;
936
      }
937
      if (result.cex != null) {
938
        throw result.cex;
939
      }
940
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getVendorItemMappings failed: unknown result");
941
    }
942
 
943
    public List<AvailableAndReservedStock> getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException
944
    {
945
      send_getPendingOrdersInventory(vendorid);
946
      return recv_getPendingOrdersInventory();
947
    }
948
 
949
    public void send_getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException
950
    {
951
      getPendingOrdersInventory_args args = new getPendingOrdersInventory_args();
952
      args.setVendorid(vendorid);
953
      sendBase("getPendingOrdersInventory", args);
954
    }
955
 
956
    public List<AvailableAndReservedStock> recv_getPendingOrdersInventory() throws org.apache.thrift.TException
957
    {
958
      getPendingOrdersInventory_result result = new getPendingOrdersInventory_result();
959
      receiveBase(result, "getPendingOrdersInventory");
960
      if (result.isSetSuccess()) {
961
        return result.success;
962
      }
963
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPendingOrdersInventory failed: unknown result");
964
    }
965
 
966
    public List<Warehouse> getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException
967
    {
968
      send_getWarehouses(warehouseType, inventoryType, vendorId, billingWarehouseId, shippingWarehouseId);
969
      return recv_getWarehouses();
970
    }
971
 
972
    public void send_getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException
973
    {
974
      getWarehouses_args args = new getWarehouses_args();
975
      args.setWarehouseType(warehouseType);
976
      args.setInventoryType(inventoryType);
977
      args.setVendorId(vendorId);
978
      args.setBillingWarehouseId(billingWarehouseId);
979
      args.setShippingWarehouseId(shippingWarehouseId);
980
      sendBase("getWarehouses", args);
981
    }
982
 
983
    public List<Warehouse> recv_getWarehouses() throws org.apache.thrift.TException
984
    {
985
      getWarehouses_result result = new getWarehouses_result();
986
      receiveBase(result, "getWarehouses");
987
      if (result.isSetSuccess()) {
988
        return result.success;
989
      }
990
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getWarehouses failed: unknown result");
991
    }
992
 
993
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws InventoryServiceException, org.apache.thrift.TException
994
    {
995
      send_resetAvailability(itemKey, vendorId, quantity, warehouseId);
996
      recv_resetAvailability();
997
    }
998
 
999
    public void send_resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws org.apache.thrift.TException
1000
    {
1001
      resetAvailability_args args = new resetAvailability_args();
1002
      args.setItemKey(itemKey);
1003
      args.setVendorId(vendorId);
1004
      args.setQuantity(quantity);
1005
      args.setWarehouseId(warehouseId);
1006
      sendBase("resetAvailability", args);
1007
    }
1008
 
1009
    public void recv_resetAvailability() throws InventoryServiceException, org.apache.thrift.TException
1010
    {
1011
      resetAvailability_result result = new resetAvailability_result();
1012
      receiveBase(result, "resetAvailability");
1013
      if (result.cex != null) {
1014
        throw result.cex;
1015
      }
1016
      return;
1017
    }
1018
 
1019
    public void resetAvailabilityForWarehouse(long warehouseId) throws InventoryServiceException, org.apache.thrift.TException
1020
    {
1021
      send_resetAvailabilityForWarehouse(warehouseId);
1022
      recv_resetAvailabilityForWarehouse();
1023
    }
1024
 
1025
    public void send_resetAvailabilityForWarehouse(long warehouseId) throws org.apache.thrift.TException
1026
    {
1027
      resetAvailabilityForWarehouse_args args = new resetAvailabilityForWarehouse_args();
1028
      args.setWarehouseId(warehouseId);
1029
      sendBase("resetAvailabilityForWarehouse", args);
1030
    }
1031
 
1032
    public void recv_resetAvailabilityForWarehouse() throws InventoryServiceException, org.apache.thrift.TException
1033
    {
1034
      resetAvailabilityForWarehouse_result result = new resetAvailabilityForWarehouse_result();
1035
      receiveBase(result, "resetAvailabilityForWarehouse");
1036
      if (result.cex != null) {
1037
        throw result.cex;
1038
      }
1039
      return;
1040
    }
1041
 
1042
    public List<String> getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException
1043
    {
1044
      send_getItemKeysToBeProcessed(warehouseId);
1045
      return recv_getItemKeysToBeProcessed();
1046
    }
1047
 
1048
    public void send_getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException
1049
    {
1050
      getItemKeysToBeProcessed_args args = new getItemKeysToBeProcessed_args();
1051
      args.setWarehouseId(warehouseId);
1052
      sendBase("getItemKeysToBeProcessed", args);
1053
    }
1054
 
1055
    public List<String> recv_getItemKeysToBeProcessed() throws org.apache.thrift.TException
1056
    {
1057
      getItemKeysToBeProcessed_result result = new getItemKeysToBeProcessed_result();
1058
      receiveBase(result, "getItemKeysToBeProcessed");
1059
      if (result.isSetSuccess()) {
1060
        return result.success;
1061
      }
1062
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemKeysToBeProcessed failed: unknown result");
1063
    }
1064
 
1065
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException
1066
    {
1067
      send_markMissedInventoryUpdatesAsProcessed(itemKey, warehouseId);
1068
      recv_markMissedInventoryUpdatesAsProcessed();
1069
    }
1070
 
1071
    public void send_markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException
1072
    {
1073
      markMissedInventoryUpdatesAsProcessed_args args = new markMissedInventoryUpdatesAsProcessed_args();
1074
      args.setItemKey(itemKey);
1075
      args.setWarehouseId(warehouseId);
1076
      sendBase("markMissedInventoryUpdatesAsProcessed", args);
1077
    }
1078
 
1079
    public void recv_markMissedInventoryUpdatesAsProcessed() throws org.apache.thrift.TException
1080
    {
1081
      markMissedInventoryUpdatesAsProcessed_result result = new markMissedInventoryUpdatesAsProcessed_result();
1082
      receiveBase(result, "markMissedInventoryUpdatesAsProcessed");
1083
      return;
1084
    }
1085
 
1086
    public Map<String,Map<Long,Long>> getIgnoredItemKeys() throws org.apache.thrift.TException
1087
    {
1088
      send_getIgnoredItemKeys();
1089
      return recv_getIgnoredItemKeys();
1090
    }
1091
 
1092
    public void send_getIgnoredItemKeys() throws org.apache.thrift.TException
1093
    {
1094
      getIgnoredItemKeys_args args = new getIgnoredItemKeys_args();
1095
      sendBase("getIgnoredItemKeys", args);
1096
    }
1097
 
1098
    public Map<String,Map<Long,Long>> recv_getIgnoredItemKeys() throws org.apache.thrift.TException
1099
    {
1100
      getIgnoredItemKeys_result result = new getIgnoredItemKeys_result();
1101
      receiveBase(result, "getIgnoredItemKeys");
1102
      if (result.isSetSuccess()) {
1103
        return result.success;
1104
      }
1105
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getIgnoredItemKeys failed: unknown result");
1106
    }
1107
 
1108
    public void addBadInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException
1109
    {
1110
      send_addBadInventory(itemId, warehouseId, quantity);
1111
      recv_addBadInventory();
1112
    }
1113
 
1114
    public void send_addBadInventory(long itemId, long warehouseId, long quantity) throws org.apache.thrift.TException
1115
    {
1116
      addBadInventory_args args = new addBadInventory_args();
1117
      args.setItemId(itemId);
1118
      args.setWarehouseId(warehouseId);
1119
      args.setQuantity(quantity);
1120
      sendBase("addBadInventory", args);
1121
    }
1122
 
1123
    public void recv_addBadInventory() throws InventoryServiceException, org.apache.thrift.TException
1124
    {
1125
      addBadInventory_result result = new addBadInventory_result();
1126
      receiveBase(result, "addBadInventory");
1127
      if (result.cex != null) {
1128
        throw result.cex;
1129
      }
1130
      return;
1131
    }
1132
 
1133
    public List<Warehouse> getShippingLocations() throws org.apache.thrift.TException
1134
    {
1135
      send_getShippingLocations();
1136
      return recv_getShippingLocations();
1137
    }
1138
 
1139
    public void send_getShippingLocations() throws org.apache.thrift.TException
1140
    {
1141
      getShippingLocations_args args = new getShippingLocations_args();
1142
      sendBase("getShippingLocations", args);
1143
    }
1144
 
1145
    public List<Warehouse> recv_getShippingLocations() throws org.apache.thrift.TException
1146
    {
1147
      getShippingLocations_result result = new getShippingLocations_result();
1148
      receiveBase(result, "getShippingLocations");
1149
      if (result.isSetSuccess()) {
1150
        return result.success;
1151
      }
1152
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getShippingLocations failed: unknown result");
1153
    }
1154
 
1155
    public List<VendorItemMapping> getAllVendorItemMappings() throws org.apache.thrift.TException
1156
    {
1157
      send_getAllVendorItemMappings();
1158
      return recv_getAllVendorItemMappings();
1159
    }
1160
 
1161
    public void send_getAllVendorItemMappings() throws org.apache.thrift.TException
1162
    {
1163
      getAllVendorItemMappings_args args = new getAllVendorItemMappings_args();
1164
      sendBase("getAllVendorItemMappings", args);
1165
    }
1166
 
1167
    public List<VendorItemMapping> recv_getAllVendorItemMappings() throws org.apache.thrift.TException
1168
    {
1169
      getAllVendorItemMappings_result result = new getAllVendorItemMappings_result();
1170
      receiveBase(result, "getAllVendorItemMappings");
1171
      if (result.isSetSuccess()) {
1172
        return result.success;
1173
      }
1174
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllVendorItemMappings failed: unknown result");
1175
    }
1176
 
1177
    public Map<Long,ItemInventory> getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException
1178
    {
1179
      send_getInventorySnapshot(warehouseId);
1180
      return recv_getInventorySnapshot();
1181
    }
1182
 
1183
    public void send_getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException
1184
    {
1185
      getInventorySnapshot_args args = new getInventorySnapshot_args();
1186
      args.setWarehouseId(warehouseId);
1187
      sendBase("getInventorySnapshot", args);
1188
    }
1189
 
1190
    public Map<Long,ItemInventory> recv_getInventorySnapshot() throws org.apache.thrift.TException
1191
    {
1192
      getInventorySnapshot_result result = new getInventorySnapshot_result();
1193
      receiveBase(result, "getInventorySnapshot");
1194
      if (result.isSetSuccess()) {
1195
        return result.success;
1196
      }
1197
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventorySnapshot failed: unknown result");
1198
    }
1199
 
1200
    public void clearItemAvailabilityCache() throws org.apache.thrift.TException
1201
    {
1202
      send_clearItemAvailabilityCache();
1203
      recv_clearItemAvailabilityCache();
1204
    }
1205
 
1206
    public void send_clearItemAvailabilityCache() throws org.apache.thrift.TException
1207
    {
1208
      clearItemAvailabilityCache_args args = new clearItemAvailabilityCache_args();
1209
      sendBase("clearItemAvailabilityCache", args);
1210
    }
1211
 
1212
    public void recv_clearItemAvailabilityCache() throws org.apache.thrift.TException
1213
    {
1214
      clearItemAvailabilityCache_result result = new clearItemAvailabilityCache_result();
1215
      receiveBase(result, "clearItemAvailabilityCache");
1216
      return;
1217
    }
1218
 
1219
    public void updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException
1220
    {
1221
      send_updateVendorString(warehouseId, vendorString);
1222
      recv_updateVendorString();
1223
    }
1224
 
1225
    public void send_updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException
1226
    {
1227
      updateVendorString_args args = new updateVendorString_args();
1228
      args.setWarehouseId(warehouseId);
1229
      args.setVendorString(vendorString);
1230
      sendBase("updateVendorString", args);
1231
    }
1232
 
1233
    public void recv_updateVendorString() throws org.apache.thrift.TException
1234
    {
1235
      updateVendorString_result result = new updateVendorString_result();
1236
      receiveBase(result, "updateVendorString");
1237
      return;
1238
    }
1239
 
1240
  }
1241
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
1242
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
1243
      private org.apache.thrift.async.TAsyncClientManager clientManager;
1244
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
1245
      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
1246
        this.clientManager = clientManager;
1247
        this.protocolFactory = protocolFactory;
1248
      }
1249
      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
1250
        return new AsyncClient(protocolFactory, clientManager, transport);
1251
      }
1252
    }
1253
 
1254
    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
1255
      super(protocolFactory, clientManager, transport);
1256
    }
1257
 
1258
    public void addWarehouse(Warehouse warehouse, org.apache.thrift.async.AsyncMethodCallback<addWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1259
      checkReady();
1260
      addWarehouse_call method_call = new addWarehouse_call(warehouse, resultHandler, this, ___protocolFactory, ___transport);
1261
      this.___currentMethod = method_call;
1262
      ___manager.call(method_call);
1263
    }
1264
 
1265
    public static class addWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1266
      private Warehouse warehouse;
1267
      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 {
1268
        super(client, protocolFactory, transport, resultHandler, false);
1269
        this.warehouse = warehouse;
1270
      }
1271
 
1272
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1273
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1274
        addWarehouse_args args = new addWarehouse_args();
1275
        args.setWarehouse(warehouse);
1276
        args.write(prot);
1277
        prot.writeMessageEnd();
1278
      }
1279
 
1280
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1281
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1282
          throw new IllegalStateException("Method call not finished!");
1283
        }
1284
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1285
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1286
        return (new Client(prot)).recv_addWarehouse();
1287
      }
1288
    }
1289
 
1290
    public void addVendor(Vendor vendor, org.apache.thrift.async.AsyncMethodCallback<addVendor_call> resultHandler) throws org.apache.thrift.TException {
1291
      checkReady();
1292
      addVendor_call method_call = new addVendor_call(vendor, resultHandler, this, ___protocolFactory, ___transport);
1293
      this.___currentMethod = method_call;
1294
      ___manager.call(method_call);
1295
    }
1296
 
1297
    public static class addVendor_call extends org.apache.thrift.async.TAsyncMethodCall {
1298
      private Vendor vendor;
1299
      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 {
1300
        super(client, protocolFactory, transport, resultHandler, false);
1301
        this.vendor = vendor;
1302
      }
1303
 
1304
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1305
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendor", org.apache.thrift.protocol.TMessageType.CALL, 0));
1306
        addVendor_args args = new addVendor_args();
1307
        args.setVendor(vendor);
1308
        args.write(prot);
1309
        prot.writeMessageEnd();
1310
      }
1311
 
1312
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1313
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1314
          throw new IllegalStateException("Method call not finished!");
1315
        }
1316
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1317
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1318
        return (new Client(prot)).recv_addVendor();
1319
      }
1320
    }
1321
 
1322
    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 {
1323
      checkReady();
1324
      updateInventoryHistory_call method_call = new updateInventoryHistory_call(warehouse_id, timestamp, availability, resultHandler, this, ___protocolFactory, ___transport);
1325
      this.___currentMethod = method_call;
1326
      ___manager.call(method_call);
1327
    }
1328
 
1329
    public static class updateInventoryHistory_call extends org.apache.thrift.async.TAsyncMethodCall {
1330
      private long warehouse_id;
1331
      private String timestamp;
1332
      private Map<String,Long> availability;
1333
      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 {
1334
        super(client, protocolFactory, transport, resultHandler, false);
1335
        this.warehouse_id = warehouse_id;
1336
        this.timestamp = timestamp;
1337
        this.availability = availability;
1338
      }
1339
 
1340
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1341
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateInventoryHistory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1342
        updateInventoryHistory_args args = new updateInventoryHistory_args();
1343
        args.setWarehouse_id(warehouse_id);
1344
        args.setTimestamp(timestamp);
1345
        args.setAvailability(availability);
1346
        args.write(prot);
1347
        prot.writeMessageEnd();
1348
      }
1349
 
1350
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1351
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1352
          throw new IllegalStateException("Method call not finished!");
1353
        }
1354
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1355
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1356
        (new Client(prot)).recv_updateInventoryHistory();
1357
      }
1358
    }
1359
 
1360
    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 {
1361
      checkReady();
1362
      updateInventory_call method_call = new updateInventory_call(warehouse_id, timestamp, availability, resultHandler, this, ___protocolFactory, ___transport);
1363
      this.___currentMethod = method_call;
1364
      ___manager.call(method_call);
1365
    }
1366
 
1367
    public static class updateInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
1368
      private long warehouse_id;
1369
      private String timestamp;
1370
      private Map<String,Long> availability;
1371
      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 {
1372
        super(client, protocolFactory, transport, resultHandler, false);
1373
        this.warehouse_id = warehouse_id;
1374
        this.timestamp = timestamp;
1375
        this.availability = availability;
1376
      }
1377
 
1378
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1379
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1380
        updateInventory_args args = new updateInventory_args();
1381
        args.setWarehouse_id(warehouse_id);
1382
        args.setTimestamp(timestamp);
1383
        args.setAvailability(availability);
1384
        args.write(prot);
1385
        prot.writeMessageEnd();
1386
      }
1387
 
1388
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1389
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1390
          throw new IllegalStateException("Method call not finished!");
1391
        }
1392
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1393
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1394
        (new Client(prot)).recv_updateInventory();
1395
      }
1396
    }
1397
 
1398
    public void addInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addInventory_call> resultHandler) throws org.apache.thrift.TException {
1399
      checkReady();
1400
      addInventory_call method_call = new addInventory_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
1401
      this.___currentMethod = method_call;
1402
      ___manager.call(method_call);
1403
    }
1404
 
1405
    public static class addInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
1406
      private long itemId;
1407
      private long warehouseId;
1408
      private long quantity;
1409
      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 {
1410
        super(client, protocolFactory, transport, resultHandler, false);
1411
        this.itemId = itemId;
1412
        this.warehouseId = warehouseId;
1413
        this.quantity = quantity;
1414
      }
1415
 
1416
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1417
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1418
        addInventory_args args = new addInventory_args();
1419
        args.setItemId(itemId);
1420
        args.setWarehouseId(warehouseId);
1421
        args.setQuantity(quantity);
1422
        args.write(prot);
1423
        prot.writeMessageEnd();
1424
      }
1425
 
1426
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1427
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1428
          throw new IllegalStateException("Method call not finished!");
1429
        }
1430
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1431
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1432
        (new Client(prot)).recv_addInventory();
1433
      }
1434
    }
1435
 
1436
    public void retireWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<retireWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1437
      checkReady();
1438
      retireWarehouse_call method_call = new retireWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1439
      this.___currentMethod = method_call;
1440
      ___manager.call(method_call);
1441
    }
1442
 
1443
    public static class retireWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1444
      private long warehouse_id;
1445
      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 {
1446
        super(client, protocolFactory, transport, resultHandler, false);
1447
        this.warehouse_id = warehouse_id;
1448
      }
1449
 
1450
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1451
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("retireWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1452
        retireWarehouse_args args = new retireWarehouse_args();
1453
        args.setWarehouse_id(warehouse_id);
1454
        args.write(prot);
1455
        prot.writeMessageEnd();
1456
      }
1457
 
1458
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1459
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1460
          throw new IllegalStateException("Method call not finished!");
1461
        }
1462
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1463
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1464
        (new Client(prot)).recv_retireWarehouse();
1465
      }
1466
    }
1467
 
1468
    public void getItemInventoryByItemId(long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemInventoryByItemId_call> resultHandler) throws org.apache.thrift.TException {
1469
      checkReady();
1470
      getItemInventoryByItemId_call method_call = new getItemInventoryByItemId_call(item_id, resultHandler, this, ___protocolFactory, ___transport);
1471
      this.___currentMethod = method_call;
1472
      ___manager.call(method_call);
1473
    }
1474
 
1475
    public static class getItemInventoryByItemId_call extends org.apache.thrift.async.TAsyncMethodCall {
1476
      private long item_id;
1477
      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 {
1478
        super(client, protocolFactory, transport, resultHandler, false);
1479
        this.item_id = item_id;
1480
      }
1481
 
1482
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1483
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemInventoryByItemId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1484
        getItemInventoryByItemId_args args = new getItemInventoryByItemId_args();
1485
        args.setItem_id(item_id);
1486
        args.write(prot);
1487
        prot.writeMessageEnd();
1488
      }
1489
 
1490
      public ItemInventory getResult() throws InventoryServiceException, org.apache.thrift.TException {
1491
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1492
          throw new IllegalStateException("Method call not finished!");
1493
        }
1494
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1495
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1496
        return (new Client(prot)).recv_getItemInventoryByItemId();
1497
      }
1498
    }
1499
 
1500
    public void getItemAvailibilityAtWarehouse(long warehouse_id, long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemAvailibilityAtWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1501
      checkReady();
1502
      getItemAvailibilityAtWarehouse_call method_call = new getItemAvailibilityAtWarehouse_call(warehouse_id, item_id, resultHandler, this, ___protocolFactory, ___transport);
1503
      this.___currentMethod = method_call;
1504
      ___manager.call(method_call);
1505
    }
1506
 
1507
    public static class getItemAvailibilityAtWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1508
      private long warehouse_id;
1509
      private long item_id;
1510
      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 {
1511
        super(client, protocolFactory, transport, resultHandler, false);
1512
        this.warehouse_id = warehouse_id;
1513
        this.item_id = item_id;
1514
      }
1515
 
1516
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1517
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemAvailibilityAtWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1518
        getItemAvailibilityAtWarehouse_args args = new getItemAvailibilityAtWarehouse_args();
1519
        args.setWarehouse_id(warehouse_id);
1520
        args.setItem_id(item_id);
1521
        args.write(prot);
1522
        prot.writeMessageEnd();
1523
      }
1524
 
1525
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1526
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1527
          throw new IllegalStateException("Method call not finished!");
1528
        }
1529
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1530
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1531
        return (new Client(prot)).recv_getItemAvailibilityAtWarehouse();
1532
      }
1533
    }
1534
 
5978 rajveer 1535
    public void getItemAvailabilityAtLocation(long itemId, long sourceId, org.apache.thrift.async.AsyncMethodCallback<getItemAvailabilityAtLocation_call> resultHandler) throws org.apache.thrift.TException {
5945 mandeep.dh 1536
      checkReady();
5978 rajveer 1537
      getItemAvailabilityAtLocation_call method_call = new getItemAvailabilityAtLocation_call(itemId, sourceId, resultHandler, this, ___protocolFactory, ___transport);
5945 mandeep.dh 1538
      this.___currentMethod = method_call;
1539
      ___manager.call(method_call);
1540
    }
1541
 
1542
    public static class getItemAvailabilityAtLocation_call extends org.apache.thrift.async.TAsyncMethodCall {
1543
      private long itemId;
5978 rajveer 1544
      private long sourceId;
1545
      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 1546
        super(client, protocolFactory, transport, resultHandler, false);
1547
        this.itemId = itemId;
5978 rajveer 1548
        this.sourceId = sourceId;
5945 mandeep.dh 1549
      }
1550
 
1551
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1552
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemAvailabilityAtLocation", org.apache.thrift.protocol.TMessageType.CALL, 0));
1553
        getItemAvailabilityAtLocation_args args = new getItemAvailabilityAtLocation_args();
1554
        args.setItemId(itemId);
5978 rajveer 1555
        args.setSourceId(sourceId);
5945 mandeep.dh 1556
        args.write(prot);
1557
        prot.writeMessageEnd();
1558
      }
1559
 
1560
      public List<Long> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1561
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1562
          throw new IllegalStateException("Method call not finished!");
1563
        }
1564
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1565
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1566
        return (new Client(prot)).recv_getItemAvailabilityAtLocation();
1567
      }
1568
    }
1569
 
1570
    public void getAllWarehouses(boolean isActive, org.apache.thrift.async.AsyncMethodCallback<getAllWarehouses_call> resultHandler) throws org.apache.thrift.TException {
1571
      checkReady();
1572
      getAllWarehouses_call method_call = new getAllWarehouses_call(isActive, resultHandler, this, ___protocolFactory, ___transport);
1573
      this.___currentMethod = method_call;
1574
      ___manager.call(method_call);
1575
    }
1576
 
1577
    public static class getAllWarehouses_call extends org.apache.thrift.async.TAsyncMethodCall {
1578
      private boolean isActive;
1579
      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 {
1580
        super(client, protocolFactory, transport, resultHandler, false);
1581
        this.isActive = isActive;
1582
      }
1583
 
1584
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1585
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllWarehouses", org.apache.thrift.protocol.TMessageType.CALL, 0));
1586
        getAllWarehouses_args args = new getAllWarehouses_args();
1587
        args.setIsActive(isActive);
1588
        args.write(prot);
1589
        prot.writeMessageEnd();
1590
      }
1591
 
1592
      public List<Warehouse> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1593
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1594
          throw new IllegalStateException("Method call not finished!");
1595
        }
1596
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1597
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1598
        return (new Client(prot)).recv_getAllWarehouses();
1599
      }
1600
    }
1601
 
1602
    public void getWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1603
      checkReady();
1604
      getWarehouse_call method_call = new getWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1605
      this.___currentMethod = method_call;
1606
      ___manager.call(method_call);
1607
    }
1608
 
1609
    public static class getWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1610
      private long warehouse_id;
1611
      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 {
1612
        super(client, protocolFactory, transport, resultHandler, false);
1613
        this.warehouse_id = warehouse_id;
1614
      }
1615
 
1616
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1617
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1618
        getWarehouse_args args = new getWarehouse_args();
1619
        args.setWarehouse_id(warehouse_id);
1620
        args.write(prot);
1621
        prot.writeMessageEnd();
1622
      }
1623
 
1624
      public Warehouse getResult() throws InventoryServiceException, org.apache.thrift.TException {
1625
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1626
          throw new IllegalStateException("Method call not finished!");
1627
        }
1628
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1629
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1630
        return (new Client(prot)).recv_getWarehouse();
1631
      }
1632
    }
1633
 
1634
    public void getAllItemsForWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getAllItemsForWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1635
      checkReady();
1636
      getAllItemsForWarehouse_call method_call = new getAllItemsForWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1637
      this.___currentMethod = method_call;
1638
      ___manager.call(method_call);
1639
    }
1640
 
1641
    public static class getAllItemsForWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1642
      private long warehouse_id;
1643
      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 {
1644
        super(client, protocolFactory, transport, resultHandler, false);
1645
        this.warehouse_id = warehouse_id;
1646
      }
1647
 
1648
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1649
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllItemsForWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1650
        getAllItemsForWarehouse_args args = new getAllItemsForWarehouse_args();
1651
        args.setWarehouse_id(warehouse_id);
1652
        args.write(prot);
1653
        prot.writeMessageEnd();
1654
      }
1655
 
1656
      public List<Long> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1657
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1658
          throw new IllegalStateException("Method call not finished!");
1659
        }
1660
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1661
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1662
        return (new Client(prot)).recv_getAllItemsForWarehouse();
1663
      }
1664
    }
1665
 
5967 rajveer 1666
    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 1667
      checkReady();
5967 rajveer 1668
      isOrderBillable_call method_call = new isOrderBillable_call(itemId, warehouseId, sourceId, orderId, resultHandler, this, ___protocolFactory, ___transport);
5945 mandeep.dh 1669
      this.___currentMethod = method_call;
1670
      ___manager.call(method_call);
1671
    }
1672
 
5967 rajveer 1673
    public static class isOrderBillable_call extends org.apache.thrift.async.TAsyncMethodCall {
1674
      private long itemId;
1675
      private long warehouseId;
1676
      private long sourceId;
1677
      private long orderId;
1678
      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 {
1679
        super(client, protocolFactory, transport, resultHandler, false);
1680
        this.itemId = itemId;
1681
        this.warehouseId = warehouseId;
1682
        this.sourceId = sourceId;
1683
        this.orderId = orderId;
1684
      }
1685
 
1686
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1687
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("isOrderBillable", org.apache.thrift.protocol.TMessageType.CALL, 0));
1688
        isOrderBillable_args args = new isOrderBillable_args();
1689
        args.setItemId(itemId);
1690
        args.setWarehouseId(warehouseId);
1691
        args.setSourceId(sourceId);
1692
        args.setOrderId(orderId);
1693
        args.write(prot);
1694
        prot.writeMessageEnd();
1695
      }
1696
 
1697
      public boolean getResult() throws org.apache.thrift.TException {
1698
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1699
          throw new IllegalStateException("Method call not finished!");
1700
        }
1701
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1702
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1703
        return (new Client(prot)).recv_isOrderBillable();
1704
      }
1705
    }
1706
 
1707
    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 {
1708
      checkReady();
1709
      reserveItemInWarehouse_call method_call = new reserveItemInWarehouse_call(itemId, warehouseId, sourceId, orderId, createdTimestamp, promisedShippingTimestamp, quantity, resultHandler, this, ___protocolFactory, ___transport);
1710
      this.___currentMethod = method_call;
1711
      ___manager.call(method_call);
1712
    }
1713
 
5945 mandeep.dh 1714
    public static class reserveItemInWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1715
      private long itemId;
1716
      private long warehouseId;
5967 rajveer 1717
      private long sourceId;
1718
      private long orderId;
1719
      private long createdTimestamp;
1720
      private long promisedShippingTimestamp;
5945 mandeep.dh 1721
      private double quantity;
5967 rajveer 1722
      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 1723
        super(client, protocolFactory, transport, resultHandler, false);
1724
        this.itemId = itemId;
1725
        this.warehouseId = warehouseId;
5967 rajveer 1726
        this.sourceId = sourceId;
1727
        this.orderId = orderId;
1728
        this.createdTimestamp = createdTimestamp;
1729
        this.promisedShippingTimestamp = promisedShippingTimestamp;
5945 mandeep.dh 1730
        this.quantity = quantity;
1731
      }
1732
 
1733
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1734
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("reserveItemInWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1735
        reserveItemInWarehouse_args args = new reserveItemInWarehouse_args();
1736
        args.setItemId(itemId);
1737
        args.setWarehouseId(warehouseId);
5967 rajveer 1738
        args.setSourceId(sourceId);
1739
        args.setOrderId(orderId);
1740
        args.setCreatedTimestamp(createdTimestamp);
1741
        args.setPromisedShippingTimestamp(promisedShippingTimestamp);
5945 mandeep.dh 1742
        args.setQuantity(quantity);
1743
        args.write(prot);
1744
        prot.writeMessageEnd();
1745
      }
1746
 
1747
      public boolean getResult() throws InventoryServiceException, org.apache.thrift.TException {
1748
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1749
          throw new IllegalStateException("Method call not finished!");
1750
        }
1751
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1752
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1753
        return (new Client(prot)).recv_reserveItemInWarehouse();
1754
      }
1755
    }
1756
 
5967 rajveer 1757
    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 1758
      checkReady();
5967 rajveer 1759
      reduceReservationCount_call method_call = new reduceReservationCount_call(itemId, warehouseId, sourceId, orderId, quantity, resultHandler, this, ___protocolFactory, ___transport);
5945 mandeep.dh 1760
      this.___currentMethod = method_call;
1761
      ___manager.call(method_call);
1762
    }
1763
 
1764
    public static class reduceReservationCount_call extends org.apache.thrift.async.TAsyncMethodCall {
1765
      private long itemId;
1766
      private long warehouseId;
5967 rajveer 1767
      private long sourceId;
1768
      private long orderId;
5945 mandeep.dh 1769
      private double quantity;
5967 rajveer 1770
      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 1771
        super(client, protocolFactory, transport, resultHandler, false);
1772
        this.itemId = itemId;
1773
        this.warehouseId = warehouseId;
5967 rajveer 1774
        this.sourceId = sourceId;
1775
        this.orderId = orderId;
5945 mandeep.dh 1776
        this.quantity = quantity;
1777
      }
1778
 
1779
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1780
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("reduceReservationCount", org.apache.thrift.protocol.TMessageType.CALL, 0));
1781
        reduceReservationCount_args args = new reduceReservationCount_args();
1782
        args.setItemId(itemId);
1783
        args.setWarehouseId(warehouseId);
5967 rajveer 1784
        args.setSourceId(sourceId);
1785
        args.setOrderId(orderId);
5945 mandeep.dh 1786
        args.setQuantity(quantity);
1787
        args.write(prot);
1788
        prot.writeMessageEnd();
1789
      }
1790
 
1791
      public boolean getResult() throws InventoryServiceException, org.apache.thrift.TException {
1792
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1793
          throw new IllegalStateException("Method call not finished!");
1794
        }
1795
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1796
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1797
        return (new Client(prot)).recv_reduceReservationCount();
1798
      }
1799
    }
1800
 
1801
    public void getItemPricing(long itemId, long vendorId, org.apache.thrift.async.AsyncMethodCallback<getItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1802
      checkReady();
1803
      getItemPricing_call method_call = new getItemPricing_call(itemId, vendorId, resultHandler, this, ___protocolFactory, ___transport);
1804
      this.___currentMethod = method_call;
1805
      ___manager.call(method_call);
1806
    }
1807
 
1808
    public static class getItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1809
      private long itemId;
1810
      private long vendorId;
1811
      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 {
1812
        super(client, protocolFactory, transport, resultHandler, false);
1813
        this.itemId = itemId;
1814
        this.vendorId = vendorId;
1815
      }
1816
 
1817
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1818
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1819
        getItemPricing_args args = new getItemPricing_args();
1820
        args.setItemId(itemId);
1821
        args.setVendorId(vendorId);
1822
        args.write(prot);
1823
        prot.writeMessageEnd();
1824
      }
1825
 
1826
      public VendorItemPricing getResult() throws InventoryServiceException, org.apache.thrift.TException {
1827
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1828
          throw new IllegalStateException("Method call not finished!");
1829
        }
1830
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1831
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1832
        return (new Client(prot)).recv_getItemPricing();
1833
      }
1834
    }
1835
 
1836
    public void getAllItemPricing(long itemId, org.apache.thrift.async.AsyncMethodCallback<getAllItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1837
      checkReady();
1838
      getAllItemPricing_call method_call = new getAllItemPricing_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1839
      this.___currentMethod = method_call;
1840
      ___manager.call(method_call);
1841
    }
1842
 
1843
    public static class getAllItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1844
      private long itemId;
1845
      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 {
1846
        super(client, protocolFactory, transport, resultHandler, false);
1847
        this.itemId = itemId;
1848
      }
1849
 
1850
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1851
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1852
        getAllItemPricing_args args = new getAllItemPricing_args();
1853
        args.setItemId(itemId);
1854
        args.write(prot);
1855
        prot.writeMessageEnd();
1856
      }
1857
 
1858
      public List<VendorItemPricing> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1859
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1860
          throw new IllegalStateException("Method call not finished!");
1861
        }
1862
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1863
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1864
        return (new Client(prot)).recv_getAllItemPricing();
1865
      }
1866
    }
1867
 
1868
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing, org.apache.thrift.async.AsyncMethodCallback<addVendorItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1869
      checkReady();
1870
      addVendorItemPricing_call method_call = new addVendorItemPricing_call(vendorItemPricing, resultHandler, this, ___protocolFactory, ___transport);
1871
      this.___currentMethod = method_call;
1872
      ___manager.call(method_call);
1873
    }
1874
 
1875
    public static class addVendorItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1876
      private VendorItemPricing vendorItemPricing;
1877
      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 {
1878
        super(client, protocolFactory, transport, resultHandler, false);
1879
        this.vendorItemPricing = vendorItemPricing;
1880
      }
1881
 
1882
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1883
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendorItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1884
        addVendorItemPricing_args args = new addVendorItemPricing_args();
1885
        args.setVendorItemPricing(vendorItemPricing);
1886
        args.write(prot);
1887
        prot.writeMessageEnd();
1888
      }
1889
 
1890
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1891
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1892
          throw new IllegalStateException("Method call not finished!");
1893
        }
1894
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1895
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1896
        (new Client(prot)).recv_addVendorItemPricing();
1897
      }
1898
    }
1899
 
1900
    public void getVendor(long vendorId, org.apache.thrift.async.AsyncMethodCallback<getVendor_call> resultHandler) throws org.apache.thrift.TException {
1901
      checkReady();
1902
      getVendor_call method_call = new getVendor_call(vendorId, resultHandler, this, ___protocolFactory, ___transport);
1903
      this.___currentMethod = method_call;
1904
      ___manager.call(method_call);
1905
    }
1906
 
1907
    public static class getVendor_call extends org.apache.thrift.async.TAsyncMethodCall {
1908
      private long vendorId;
1909
      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 {
1910
        super(client, protocolFactory, transport, resultHandler, false);
1911
        this.vendorId = vendorId;
1912
      }
1913
 
1914
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1915
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getVendor", org.apache.thrift.protocol.TMessageType.CALL, 0));
1916
        getVendor_args args = new getVendor_args();
1917
        args.setVendorId(vendorId);
1918
        args.write(prot);
1919
        prot.writeMessageEnd();
1920
      }
1921
 
1922
      public Vendor getResult() throws org.apache.thrift.TException {
1923
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1924
          throw new IllegalStateException("Method call not finished!");
1925
        }
1926
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1927
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1928
        return (new Client(prot)).recv_getVendor();
1929
      }
1930
    }
1931
 
1932
    public void getAllVendors(org.apache.thrift.async.AsyncMethodCallback<getAllVendors_call> resultHandler) throws org.apache.thrift.TException {
1933
      checkReady();
1934
      getAllVendors_call method_call = new getAllVendors_call(resultHandler, this, ___protocolFactory, ___transport);
1935
      this.___currentMethod = method_call;
1936
      ___manager.call(method_call);
1937
    }
1938
 
1939
    public static class getAllVendors_call extends org.apache.thrift.async.TAsyncMethodCall {
1940
      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 {
1941
        super(client, protocolFactory, transport, resultHandler, false);
1942
      }
1943
 
1944
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1945
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllVendors", org.apache.thrift.protocol.TMessageType.CALL, 0));
1946
        getAllVendors_args args = new getAllVendors_args();
1947
        args.write(prot);
1948
        prot.writeMessageEnd();
1949
      }
1950
 
1951
      public List<Vendor> getResult() throws org.apache.thrift.TException {
1952
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1953
          throw new IllegalStateException("Method call not finished!");
1954
        }
1955
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1956
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1957
        return (new Client(prot)).recv_getAllVendors();
1958
      }
1959
    }
1960
 
1961
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping, org.apache.thrift.async.AsyncMethodCallback<addVendorItemMapping_call> resultHandler) throws org.apache.thrift.TException {
1962
      checkReady();
1963
      addVendorItemMapping_call method_call = new addVendorItemMapping_call(key, vendorItemMapping, resultHandler, this, ___protocolFactory, ___transport);
1964
      this.___currentMethod = method_call;
1965
      ___manager.call(method_call);
1966
    }
1967
 
1968
    public static class addVendorItemMapping_call extends org.apache.thrift.async.TAsyncMethodCall {
1969
      private String key;
1970
      private VendorItemMapping vendorItemMapping;
1971
      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 {
1972
        super(client, protocolFactory, transport, resultHandler, false);
1973
        this.key = key;
1974
        this.vendorItemMapping = vendorItemMapping;
1975
      }
1976
 
1977
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1978
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendorItemMapping", org.apache.thrift.protocol.TMessageType.CALL, 0));
1979
        addVendorItemMapping_args args = new addVendorItemMapping_args();
1980
        args.setKey(key);
1981
        args.setVendorItemMapping(vendorItemMapping);
1982
        args.write(prot);
1983
        prot.writeMessageEnd();
1984
      }
1985
 
1986
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1987
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1988
          throw new IllegalStateException("Method call not finished!");
1989
        }
1990
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1991
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1992
        (new Client(prot)).recv_addVendorItemMapping();
1993
      }
1994
    }
1995
 
1996
    public void getVendorItemMappings(long itemId, org.apache.thrift.async.AsyncMethodCallback<getVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException {
1997
      checkReady();
1998
      getVendorItemMappings_call method_call = new getVendorItemMappings_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1999
      this.___currentMethod = method_call;
2000
      ___manager.call(method_call);
2001
    }
2002
 
2003
    public static class getVendorItemMappings_call extends org.apache.thrift.async.TAsyncMethodCall {
2004
      private long itemId;
2005
      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 {
2006
        super(client, protocolFactory, transport, resultHandler, false);
2007
        this.itemId = itemId;
2008
      }
2009
 
2010
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2011
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getVendorItemMappings", org.apache.thrift.protocol.TMessageType.CALL, 0));
2012
        getVendorItemMappings_args args = new getVendorItemMappings_args();
2013
        args.setItemId(itemId);
2014
        args.write(prot);
2015
        prot.writeMessageEnd();
2016
      }
2017
 
2018
      public List<VendorItemMapping> getResult() throws InventoryServiceException, org.apache.thrift.TException {
2019
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2020
          throw new IllegalStateException("Method call not finished!");
2021
        }
2022
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2023
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2024
        return (new Client(prot)).recv_getVendorItemMappings();
2025
      }
2026
    }
2027
 
2028
    public void getPendingOrdersInventory(long vendorid, org.apache.thrift.async.AsyncMethodCallback<getPendingOrdersInventory_call> resultHandler) throws org.apache.thrift.TException {
2029
      checkReady();
2030
      getPendingOrdersInventory_call method_call = new getPendingOrdersInventory_call(vendorid, resultHandler, this, ___protocolFactory, ___transport);
2031
      this.___currentMethod = method_call;
2032
      ___manager.call(method_call);
2033
    }
2034
 
2035
    public static class getPendingOrdersInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
2036
      private long vendorid;
2037
      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 {
2038
        super(client, protocolFactory, transport, resultHandler, false);
2039
        this.vendorid = vendorid;
2040
      }
2041
 
2042
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2043
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPendingOrdersInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
2044
        getPendingOrdersInventory_args args = new getPendingOrdersInventory_args();
2045
        args.setVendorid(vendorid);
2046
        args.write(prot);
2047
        prot.writeMessageEnd();
2048
      }
2049
 
2050
      public List<AvailableAndReservedStock> getResult() throws org.apache.thrift.TException {
2051
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2052
          throw new IllegalStateException("Method call not finished!");
2053
        }
2054
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2055
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2056
        return (new Client(prot)).recv_getPendingOrdersInventory();
2057
      }
2058
    }
2059
 
2060
    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 {
2061
      checkReady();
2062
      getWarehouses_call method_call = new getWarehouses_call(warehouseType, inventoryType, vendorId, billingWarehouseId, shippingWarehouseId, resultHandler, this, ___protocolFactory, ___transport);
2063
      this.___currentMethod = method_call;
2064
      ___manager.call(method_call);
2065
    }
2066
 
2067
    public static class getWarehouses_call extends org.apache.thrift.async.TAsyncMethodCall {
2068
      private WarehouseType warehouseType;
2069
      private InventoryType inventoryType;
2070
      private long vendorId;
2071
      private long billingWarehouseId;
2072
      private long shippingWarehouseId;
2073
      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 {
2074
        super(client, protocolFactory, transport, resultHandler, false);
2075
        this.warehouseType = warehouseType;
2076
        this.inventoryType = inventoryType;
2077
        this.vendorId = vendorId;
2078
        this.billingWarehouseId = billingWarehouseId;
2079
        this.shippingWarehouseId = shippingWarehouseId;
2080
      }
2081
 
2082
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2083
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getWarehouses", org.apache.thrift.protocol.TMessageType.CALL, 0));
2084
        getWarehouses_args args = new getWarehouses_args();
2085
        args.setWarehouseType(warehouseType);
2086
        args.setInventoryType(inventoryType);
2087
        args.setVendorId(vendorId);
2088
        args.setBillingWarehouseId(billingWarehouseId);
2089
        args.setShippingWarehouseId(shippingWarehouseId);
2090
        args.write(prot);
2091
        prot.writeMessageEnd();
2092
      }
2093
 
2094
      public List<Warehouse> getResult() throws org.apache.thrift.TException {
2095
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2096
          throw new IllegalStateException("Method call not finished!");
2097
        }
2098
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2099
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2100
        return (new Client(prot)).recv_getWarehouses();
2101
      }
2102
    }
2103
 
2104
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailability_call> resultHandler) throws org.apache.thrift.TException {
2105
      checkReady();
2106
      resetAvailability_call method_call = new resetAvailability_call(itemKey, vendorId, quantity, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2107
      this.___currentMethod = method_call;
2108
      ___manager.call(method_call);
2109
    }
2110
 
2111
    public static class resetAvailability_call extends org.apache.thrift.async.TAsyncMethodCall {
2112
      private String itemKey;
2113
      private long vendorId;
2114
      private long quantity;
2115
      private long warehouseId;
2116
      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 {
2117
        super(client, protocolFactory, transport, resultHandler, false);
2118
        this.itemKey = itemKey;
2119
        this.vendorId = vendorId;
2120
        this.quantity = quantity;
2121
        this.warehouseId = warehouseId;
2122
      }
2123
 
2124
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2125
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("resetAvailability", org.apache.thrift.protocol.TMessageType.CALL, 0));
2126
        resetAvailability_args args = new resetAvailability_args();
2127
        args.setItemKey(itemKey);
2128
        args.setVendorId(vendorId);
2129
        args.setQuantity(quantity);
2130
        args.setWarehouseId(warehouseId);
2131
        args.write(prot);
2132
        prot.writeMessageEnd();
2133
      }
2134
 
2135
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2136
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2137
          throw new IllegalStateException("Method call not finished!");
2138
        }
2139
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2140
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2141
        (new Client(prot)).recv_resetAvailability();
2142
      }
2143
    }
2144
 
2145
    public void resetAvailabilityForWarehouse(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailabilityForWarehouse_call> resultHandler) throws org.apache.thrift.TException {
2146
      checkReady();
2147
      resetAvailabilityForWarehouse_call method_call = new resetAvailabilityForWarehouse_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2148
      this.___currentMethod = method_call;
2149
      ___manager.call(method_call);
2150
    }
2151
 
2152
    public static class resetAvailabilityForWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
2153
      private long warehouseId;
2154
      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 {
2155
        super(client, protocolFactory, transport, resultHandler, false);
2156
        this.warehouseId = warehouseId;
2157
      }
2158
 
2159
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2160
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("resetAvailabilityForWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
2161
        resetAvailabilityForWarehouse_args args = new resetAvailabilityForWarehouse_args();
2162
        args.setWarehouseId(warehouseId);
2163
        args.write(prot);
2164
        prot.writeMessageEnd();
2165
      }
2166
 
2167
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2168
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2169
          throw new IllegalStateException("Method call not finished!");
2170
        }
2171
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2172
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2173
        (new Client(prot)).recv_resetAvailabilityForWarehouse();
2174
      }
2175
    }
2176
 
2177
    public void getItemKeysToBeProcessed(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getItemKeysToBeProcessed_call> resultHandler) throws org.apache.thrift.TException {
2178
      checkReady();
2179
      getItemKeysToBeProcessed_call method_call = new getItemKeysToBeProcessed_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2180
      this.___currentMethod = method_call;
2181
      ___manager.call(method_call);
2182
    }
2183
 
2184
    public static class getItemKeysToBeProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
2185
      private long warehouseId;
2186
      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 {
2187
        super(client, protocolFactory, transport, resultHandler, false);
2188
        this.warehouseId = warehouseId;
2189
      }
2190
 
2191
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2192
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemKeysToBeProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
2193
        getItemKeysToBeProcessed_args args = new getItemKeysToBeProcessed_args();
2194
        args.setWarehouseId(warehouseId);
2195
        args.write(prot);
2196
        prot.writeMessageEnd();
2197
      }
2198
 
2199
      public List<String> getResult() throws org.apache.thrift.TException {
2200
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2201
          throw new IllegalStateException("Method call not finished!");
2202
        }
2203
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2204
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2205
        return (new Client(prot)).recv_getItemKeysToBeProcessed();
2206
      }
2207
    }
2208
 
2209
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<markMissedInventoryUpdatesAsProcessed_call> resultHandler) throws org.apache.thrift.TException {
2210
      checkReady();
2211
      markMissedInventoryUpdatesAsProcessed_call method_call = new markMissedInventoryUpdatesAsProcessed_call(itemKey, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2212
      this.___currentMethod = method_call;
2213
      ___manager.call(method_call);
2214
    }
2215
 
2216
    public static class markMissedInventoryUpdatesAsProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
2217
      private String itemKey;
2218
      private long warehouseId;
2219
      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 {
2220
        super(client, protocolFactory, transport, resultHandler, false);
2221
        this.itemKey = itemKey;
2222
        this.warehouseId = warehouseId;
2223
      }
2224
 
2225
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2226
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("markMissedInventoryUpdatesAsProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
2227
        markMissedInventoryUpdatesAsProcessed_args args = new markMissedInventoryUpdatesAsProcessed_args();
2228
        args.setItemKey(itemKey);
2229
        args.setWarehouseId(warehouseId);
2230
        args.write(prot);
2231
        prot.writeMessageEnd();
2232
      }
2233
 
2234
      public void getResult() throws org.apache.thrift.TException {
2235
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2236
          throw new IllegalStateException("Method call not finished!");
2237
        }
2238
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2239
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2240
        (new Client(prot)).recv_markMissedInventoryUpdatesAsProcessed();
2241
      }
2242
    }
2243
 
2244
    public void getIgnoredItemKeys(org.apache.thrift.async.AsyncMethodCallback<getIgnoredItemKeys_call> resultHandler) throws org.apache.thrift.TException {
2245
      checkReady();
2246
      getIgnoredItemKeys_call method_call = new getIgnoredItemKeys_call(resultHandler, this, ___protocolFactory, ___transport);
2247
      this.___currentMethod = method_call;
2248
      ___manager.call(method_call);
2249
    }
2250
 
2251
    public static class getIgnoredItemKeys_call extends org.apache.thrift.async.TAsyncMethodCall {
2252
      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 {
2253
        super(client, protocolFactory, transport, resultHandler, false);
2254
      }
2255
 
2256
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2257
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getIgnoredItemKeys", org.apache.thrift.protocol.TMessageType.CALL, 0));
2258
        getIgnoredItemKeys_args args = new getIgnoredItemKeys_args();
2259
        args.write(prot);
2260
        prot.writeMessageEnd();
2261
      }
2262
 
2263
      public Map<String,Map<Long,Long>> getResult() throws org.apache.thrift.TException {
2264
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2265
          throw new IllegalStateException("Method call not finished!");
2266
        }
2267
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2268
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2269
        return (new Client(prot)).recv_getIgnoredItemKeys();
2270
      }
2271
    }
2272
 
2273
    public void addBadInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addBadInventory_call> resultHandler) throws org.apache.thrift.TException {
2274
      checkReady();
2275
      addBadInventory_call method_call = new addBadInventory_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
2276
      this.___currentMethod = method_call;
2277
      ___manager.call(method_call);
2278
    }
2279
 
2280
    public static class addBadInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
2281
      private long itemId;
2282
      private long warehouseId;
2283
      private long quantity;
2284
      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 {
2285
        super(client, protocolFactory, transport, resultHandler, false);
2286
        this.itemId = itemId;
2287
        this.warehouseId = warehouseId;
2288
        this.quantity = quantity;
2289
      }
2290
 
2291
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2292
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addBadInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
2293
        addBadInventory_args args = new addBadInventory_args();
2294
        args.setItemId(itemId);
2295
        args.setWarehouseId(warehouseId);
2296
        args.setQuantity(quantity);
2297
        args.write(prot);
2298
        prot.writeMessageEnd();
2299
      }
2300
 
2301
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2302
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2303
          throw new IllegalStateException("Method call not finished!");
2304
        }
2305
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2306
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2307
        (new Client(prot)).recv_addBadInventory();
2308
      }
2309
    }
2310
 
2311
    public void getShippingLocations(org.apache.thrift.async.AsyncMethodCallback<getShippingLocations_call> resultHandler) throws org.apache.thrift.TException {
2312
      checkReady();
2313
      getShippingLocations_call method_call = new getShippingLocations_call(resultHandler, this, ___protocolFactory, ___transport);
2314
      this.___currentMethod = method_call;
2315
      ___manager.call(method_call);
2316
    }
2317
 
2318
    public static class getShippingLocations_call extends org.apache.thrift.async.TAsyncMethodCall {
2319
      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 {
2320
        super(client, protocolFactory, transport, resultHandler, false);
2321
      }
2322
 
2323
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2324
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getShippingLocations", org.apache.thrift.protocol.TMessageType.CALL, 0));
2325
        getShippingLocations_args args = new getShippingLocations_args();
2326
        args.write(prot);
2327
        prot.writeMessageEnd();
2328
      }
2329
 
2330
      public List<Warehouse> getResult() throws org.apache.thrift.TException {
2331
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2332
          throw new IllegalStateException("Method call not finished!");
2333
        }
2334
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2335
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2336
        return (new Client(prot)).recv_getShippingLocations();
2337
      }
2338
    }
2339
 
2340
    public void getAllVendorItemMappings(org.apache.thrift.async.AsyncMethodCallback<getAllVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException {
2341
      checkReady();
2342
      getAllVendorItemMappings_call method_call = new getAllVendorItemMappings_call(resultHandler, this, ___protocolFactory, ___transport);
2343
      this.___currentMethod = method_call;
2344
      ___manager.call(method_call);
2345
    }
2346
 
2347
    public static class getAllVendorItemMappings_call extends org.apache.thrift.async.TAsyncMethodCall {
2348
      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 {
2349
        super(client, protocolFactory, transport, resultHandler, false);
2350
      }
2351
 
2352
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2353
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllVendorItemMappings", org.apache.thrift.protocol.TMessageType.CALL, 0));
2354
        getAllVendorItemMappings_args args = new getAllVendorItemMappings_args();
2355
        args.write(prot);
2356
        prot.writeMessageEnd();
2357
      }
2358
 
2359
      public List<VendorItemMapping> getResult() throws org.apache.thrift.TException {
2360
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2361
          throw new IllegalStateException("Method call not finished!");
2362
        }
2363
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2364
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2365
        return (new Client(prot)).recv_getAllVendorItemMappings();
2366
      }
2367
    }
2368
 
2369
    public void getInventorySnapshot(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getInventorySnapshot_call> resultHandler) throws org.apache.thrift.TException {
2370
      checkReady();
2371
      getInventorySnapshot_call method_call = new getInventorySnapshot_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2372
      this.___currentMethod = method_call;
2373
      ___manager.call(method_call);
2374
    }
2375
 
2376
    public static class getInventorySnapshot_call extends org.apache.thrift.async.TAsyncMethodCall {
2377
      private long warehouseId;
2378
      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 {
2379
        super(client, protocolFactory, transport, resultHandler, false);
2380
        this.warehouseId = warehouseId;
2381
      }
2382
 
2383
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2384
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventorySnapshot", org.apache.thrift.protocol.TMessageType.CALL, 0));
2385
        getInventorySnapshot_args args = new getInventorySnapshot_args();
2386
        args.setWarehouseId(warehouseId);
2387
        args.write(prot);
2388
        prot.writeMessageEnd();
2389
      }
2390
 
2391
      public Map<Long,ItemInventory> getResult() throws org.apache.thrift.TException {
2392
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2393
          throw new IllegalStateException("Method call not finished!");
2394
        }
2395
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2396
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2397
        return (new Client(prot)).recv_getInventorySnapshot();
2398
      }
2399
    }
2400
 
2401
    public void clearItemAvailabilityCache(org.apache.thrift.async.AsyncMethodCallback<clearItemAvailabilityCache_call> resultHandler) throws org.apache.thrift.TException {
2402
      checkReady();
2403
      clearItemAvailabilityCache_call method_call = new clearItemAvailabilityCache_call(resultHandler, this, ___protocolFactory, ___transport);
2404
      this.___currentMethod = method_call;
2405
      ___manager.call(method_call);
2406
    }
2407
 
2408
    public static class clearItemAvailabilityCache_call extends org.apache.thrift.async.TAsyncMethodCall {
2409
      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 {
2410
        super(client, protocolFactory, transport, resultHandler, false);
2411
      }
2412
 
2413
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2414
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("clearItemAvailabilityCache", org.apache.thrift.protocol.TMessageType.CALL, 0));
2415
        clearItemAvailabilityCache_args args = new clearItemAvailabilityCache_args();
2416
        args.write(prot);
2417
        prot.writeMessageEnd();
2418
      }
2419
 
2420
      public void getResult() throws org.apache.thrift.TException {
2421
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2422
          throw new IllegalStateException("Method call not finished!");
2423
        }
2424
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2425
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2426
        (new Client(prot)).recv_clearItemAvailabilityCache();
2427
      }
2428
    }
2429
 
2430
    public void updateVendorString(long warehouseId, String vendorString, org.apache.thrift.async.AsyncMethodCallback<updateVendorString_call> resultHandler) throws org.apache.thrift.TException {
2431
      checkReady();
2432
      updateVendorString_call method_call = new updateVendorString_call(warehouseId, vendorString, resultHandler, this, ___protocolFactory, ___transport);
2433
      this.___currentMethod = method_call;
2434
      ___manager.call(method_call);
2435
    }
2436
 
2437
    public static class updateVendorString_call extends org.apache.thrift.async.TAsyncMethodCall {
2438
      private long warehouseId;
2439
      private String vendorString;
2440
      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 {
2441
        super(client, protocolFactory, transport, resultHandler, false);
2442
        this.warehouseId = warehouseId;
2443
        this.vendorString = vendorString;
2444
      }
2445
 
2446
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2447
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateVendorString", org.apache.thrift.protocol.TMessageType.CALL, 0));
2448
        updateVendorString_args args = new updateVendorString_args();
2449
        args.setWarehouseId(warehouseId);
2450
        args.setVendorString(vendorString);
2451
        args.write(prot);
2452
        prot.writeMessageEnd();
2453
      }
2454
 
2455
      public void getResult() throws org.apache.thrift.TException {
2456
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2457
          throw new IllegalStateException("Method call not finished!");
2458
        }
2459
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2460
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2461
        (new Client(prot)).recv_updateVendorString();
2462
      }
2463
    }
2464
 
2465
  }
2466
 
2467
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
2468
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
2469
    public Processor(I iface) {
2470
      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
2471
    }
2472
 
2473
    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
2474
      super(iface, getProcessMap(processMap));
2475
    }
2476
 
2477
    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) {
2478
      processMap.put("addWarehouse", new addWarehouse());
2479
      processMap.put("addVendor", new addVendor());
2480
      processMap.put("updateInventoryHistory", new updateInventoryHistory());
2481
      processMap.put("updateInventory", new updateInventory());
2482
      processMap.put("addInventory", new addInventory());
2483
      processMap.put("retireWarehouse", new retireWarehouse());
2484
      processMap.put("getItemInventoryByItemId", new getItemInventoryByItemId());
2485
      processMap.put("getItemAvailibilityAtWarehouse", new getItemAvailibilityAtWarehouse());
2486
      processMap.put("getItemAvailabilityAtLocation", new getItemAvailabilityAtLocation());
2487
      processMap.put("getAllWarehouses", new getAllWarehouses());
2488
      processMap.put("getWarehouse", new getWarehouse());
2489
      processMap.put("getAllItemsForWarehouse", new getAllItemsForWarehouse());
5967 rajveer 2490
      processMap.put("isOrderBillable", new isOrderBillable());
5945 mandeep.dh 2491
      processMap.put("reserveItemInWarehouse", new reserveItemInWarehouse());
2492
      processMap.put("reduceReservationCount", new reduceReservationCount());
2493
      processMap.put("getItemPricing", new getItemPricing());
2494
      processMap.put("getAllItemPricing", new getAllItemPricing());
2495
      processMap.put("addVendorItemPricing", new addVendorItemPricing());
2496
      processMap.put("getVendor", new getVendor());
2497
      processMap.put("getAllVendors", new getAllVendors());
2498
      processMap.put("addVendorItemMapping", new addVendorItemMapping());
2499
      processMap.put("getVendorItemMappings", new getVendorItemMappings());
2500
      processMap.put("getPendingOrdersInventory", new getPendingOrdersInventory());
2501
      processMap.put("getWarehouses", new getWarehouses());
2502
      processMap.put("resetAvailability", new resetAvailability());
2503
      processMap.put("resetAvailabilityForWarehouse", new resetAvailabilityForWarehouse());
2504
      processMap.put("getItemKeysToBeProcessed", new getItemKeysToBeProcessed());
2505
      processMap.put("markMissedInventoryUpdatesAsProcessed", new markMissedInventoryUpdatesAsProcessed());
2506
      processMap.put("getIgnoredItemKeys", new getIgnoredItemKeys());
2507
      processMap.put("addBadInventory", new addBadInventory());
2508
      processMap.put("getShippingLocations", new getShippingLocations());
2509
      processMap.put("getAllVendorItemMappings", new getAllVendorItemMappings());
2510
      processMap.put("getInventorySnapshot", new getInventorySnapshot());
2511
      processMap.put("clearItemAvailabilityCache", new clearItemAvailabilityCache());
2512
      processMap.put("updateVendorString", new updateVendorString());
2513
      return processMap;
2514
    }
2515
 
2516
    private static class addWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addWarehouse_args> {
2517
      public addWarehouse() {
2518
        super("addWarehouse");
2519
      }
2520
 
2521
      protected addWarehouse_args getEmptyArgsInstance() {
2522
        return new addWarehouse_args();
2523
      }
2524
 
2525
      protected addWarehouse_result getResult(I iface, addWarehouse_args args) throws org.apache.thrift.TException {
2526
        addWarehouse_result result = new addWarehouse_result();
2527
        try {
2528
          result.success = iface.addWarehouse(args.warehouse);
2529
          result.setSuccessIsSet(true);
2530
        } catch (InventoryServiceException cex) {
2531
          result.cex = cex;
2532
        }
2533
        return result;
2534
      }
2535
    }
2536
 
2537
    private static class addVendor<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendor_args> {
2538
      public addVendor() {
2539
        super("addVendor");
2540
      }
2541
 
2542
      protected addVendor_args getEmptyArgsInstance() {
2543
        return new addVendor_args();
2544
      }
2545
 
2546
      protected addVendor_result getResult(I iface, addVendor_args args) throws org.apache.thrift.TException {
2547
        addVendor_result result = new addVendor_result();
2548
        try {
2549
          result.success = iface.addVendor(args.vendor);
2550
          result.setSuccessIsSet(true);
2551
        } catch (InventoryServiceException cex) {
2552
          result.cex = cex;
2553
        }
2554
        return result;
2555
      }
2556
    }
2557
 
2558
    private static class updateInventoryHistory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateInventoryHistory_args> {
2559
      public updateInventoryHistory() {
2560
        super("updateInventoryHistory");
2561
      }
2562
 
2563
      protected updateInventoryHistory_args getEmptyArgsInstance() {
2564
        return new updateInventoryHistory_args();
2565
      }
2566
 
2567
      protected updateInventoryHistory_result getResult(I iface, updateInventoryHistory_args args) throws org.apache.thrift.TException {
2568
        updateInventoryHistory_result result = new updateInventoryHistory_result();
2569
        try {
2570
          iface.updateInventoryHistory(args.warehouse_id, args.timestamp, args.availability);
2571
        } catch (InventoryServiceException cex) {
2572
          result.cex = cex;
2573
        }
2574
        return result;
2575
      }
2576
    }
2577
 
2578
    private static class updateInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateInventory_args> {
2579
      public updateInventory() {
2580
        super("updateInventory");
2581
      }
2582
 
2583
      protected updateInventory_args getEmptyArgsInstance() {
2584
        return new updateInventory_args();
2585
      }
2586
 
2587
      protected updateInventory_result getResult(I iface, updateInventory_args args) throws org.apache.thrift.TException {
2588
        updateInventory_result result = new updateInventory_result();
2589
        try {
2590
          iface.updateInventory(args.warehouse_id, args.timestamp, args.availability);
2591
        } catch (InventoryServiceException cex) {
2592
          result.cex = cex;
2593
        }
2594
        return result;
2595
      }
2596
    }
2597
 
2598
    private static class addInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addInventory_args> {
2599
      public addInventory() {
2600
        super("addInventory");
2601
      }
2602
 
2603
      protected addInventory_args getEmptyArgsInstance() {
2604
        return new addInventory_args();
2605
      }
2606
 
2607
      protected addInventory_result getResult(I iface, addInventory_args args) throws org.apache.thrift.TException {
2608
        addInventory_result result = new addInventory_result();
2609
        try {
2610
          iface.addInventory(args.itemId, args.warehouseId, args.quantity);
2611
        } catch (InventoryServiceException cex) {
2612
          result.cex = cex;
2613
        }
2614
        return result;
2615
      }
2616
    }
2617
 
2618
    private static class retireWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, retireWarehouse_args> {
2619
      public retireWarehouse() {
2620
        super("retireWarehouse");
2621
      }
2622
 
2623
      protected retireWarehouse_args getEmptyArgsInstance() {
2624
        return new retireWarehouse_args();
2625
      }
2626
 
2627
      protected retireWarehouse_result getResult(I iface, retireWarehouse_args args) throws org.apache.thrift.TException {
2628
        retireWarehouse_result result = new retireWarehouse_result();
2629
        try {
2630
          iface.retireWarehouse(args.warehouse_id);
2631
        } catch (InventoryServiceException cex) {
2632
          result.cex = cex;
2633
        }
2634
        return result;
2635
      }
2636
    }
2637
 
2638
    private static class getItemInventoryByItemId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemInventoryByItemId_args> {
2639
      public getItemInventoryByItemId() {
2640
        super("getItemInventoryByItemId");
2641
      }
2642
 
2643
      protected getItemInventoryByItemId_args getEmptyArgsInstance() {
2644
        return new getItemInventoryByItemId_args();
2645
      }
2646
 
2647
      protected getItemInventoryByItemId_result getResult(I iface, getItemInventoryByItemId_args args) throws org.apache.thrift.TException {
2648
        getItemInventoryByItemId_result result = new getItemInventoryByItemId_result();
2649
        try {
2650
          result.success = iface.getItemInventoryByItemId(args.item_id);
2651
        } catch (InventoryServiceException cex) {
2652
          result.cex = cex;
2653
        }
2654
        return result;
2655
      }
2656
    }
2657
 
2658
    private static class getItemAvailibilityAtWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemAvailibilityAtWarehouse_args> {
2659
      public getItemAvailibilityAtWarehouse() {
2660
        super("getItemAvailibilityAtWarehouse");
2661
      }
2662
 
2663
      protected getItemAvailibilityAtWarehouse_args getEmptyArgsInstance() {
2664
        return new getItemAvailibilityAtWarehouse_args();
2665
      }
2666
 
2667
      protected getItemAvailibilityAtWarehouse_result getResult(I iface, getItemAvailibilityAtWarehouse_args args) throws org.apache.thrift.TException {
2668
        getItemAvailibilityAtWarehouse_result result = new getItemAvailibilityAtWarehouse_result();
2669
        try {
2670
          result.success = iface.getItemAvailibilityAtWarehouse(args.warehouse_id, args.item_id);
2671
          result.setSuccessIsSet(true);
2672
        } catch (InventoryServiceException cex) {
2673
          result.cex = cex;
2674
        }
2675
        return result;
2676
      }
2677
    }
2678
 
2679
    private static class getItemAvailabilityAtLocation<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemAvailabilityAtLocation_args> {
2680
      public getItemAvailabilityAtLocation() {
2681
        super("getItemAvailabilityAtLocation");
2682
      }
2683
 
2684
      protected getItemAvailabilityAtLocation_args getEmptyArgsInstance() {
2685
        return new getItemAvailabilityAtLocation_args();
2686
      }
2687
 
2688
      protected getItemAvailabilityAtLocation_result getResult(I iface, getItemAvailabilityAtLocation_args args) throws org.apache.thrift.TException {
2689
        getItemAvailabilityAtLocation_result result = new getItemAvailabilityAtLocation_result();
2690
        try {
5978 rajveer 2691
          result.success = iface.getItemAvailabilityAtLocation(args.itemId, args.sourceId);
5945 mandeep.dh 2692
        } catch (InventoryServiceException isex) {
2693
          result.isex = isex;
2694
        }
2695
        return result;
2696
      }
2697
    }
2698
 
2699
    private static class getAllWarehouses<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllWarehouses_args> {
2700
      public getAllWarehouses() {
2701
        super("getAllWarehouses");
2702
      }
2703
 
2704
      protected getAllWarehouses_args getEmptyArgsInstance() {
2705
        return new getAllWarehouses_args();
2706
      }
2707
 
2708
      protected getAllWarehouses_result getResult(I iface, getAllWarehouses_args args) throws org.apache.thrift.TException {
2709
        getAllWarehouses_result result = new getAllWarehouses_result();
2710
        try {
2711
          result.success = iface.getAllWarehouses(args.isActive);
2712
        } catch (InventoryServiceException cex) {
2713
          result.cex = cex;
2714
        }
2715
        return result;
2716
      }
2717
    }
2718
 
2719
    private static class getWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getWarehouse_args> {
2720
      public getWarehouse() {
2721
        super("getWarehouse");
2722
      }
2723
 
2724
      protected getWarehouse_args getEmptyArgsInstance() {
2725
        return new getWarehouse_args();
2726
      }
2727
 
2728
      protected getWarehouse_result getResult(I iface, getWarehouse_args args) throws org.apache.thrift.TException {
2729
        getWarehouse_result result = new getWarehouse_result();
2730
        try {
2731
          result.success = iface.getWarehouse(args.warehouse_id);
2732
        } catch (InventoryServiceException cex) {
2733
          result.cex = cex;
2734
        }
2735
        return result;
2736
      }
2737
    }
2738
 
2739
    private static class getAllItemsForWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllItemsForWarehouse_args> {
2740
      public getAllItemsForWarehouse() {
2741
        super("getAllItemsForWarehouse");
2742
      }
2743
 
2744
      protected getAllItemsForWarehouse_args getEmptyArgsInstance() {
2745
        return new getAllItemsForWarehouse_args();
2746
      }
2747
 
2748
      protected getAllItemsForWarehouse_result getResult(I iface, getAllItemsForWarehouse_args args) throws org.apache.thrift.TException {
2749
        getAllItemsForWarehouse_result result = new getAllItemsForWarehouse_result();
2750
        try {
2751
          result.success = iface.getAllItemsForWarehouse(args.warehouse_id);
2752
        } catch (InventoryServiceException cex) {
2753
          result.cex = cex;
2754
        }
2755
        return result;
2756
      }
2757
    }
2758
 
5967 rajveer 2759
    private static class isOrderBillable<I extends Iface> extends org.apache.thrift.ProcessFunction<I, isOrderBillable_args> {
2760
      public isOrderBillable() {
2761
        super("isOrderBillable");
2762
      }
2763
 
2764
      protected isOrderBillable_args getEmptyArgsInstance() {
2765
        return new isOrderBillable_args();
2766
      }
2767
 
2768
      protected isOrderBillable_result getResult(I iface, isOrderBillable_args args) throws org.apache.thrift.TException {
2769
        isOrderBillable_result result = new isOrderBillable_result();
2770
        result.success = iface.isOrderBillable(args.itemId, args.warehouseId, args.sourceId, args.orderId);
2771
        result.setSuccessIsSet(true);
2772
        return result;
2773
      }
2774
    }
2775
 
5945 mandeep.dh 2776
    private static class reserveItemInWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, reserveItemInWarehouse_args> {
2777
      public reserveItemInWarehouse() {
2778
        super("reserveItemInWarehouse");
2779
      }
2780
 
2781
      protected reserveItemInWarehouse_args getEmptyArgsInstance() {
2782
        return new reserveItemInWarehouse_args();
2783
      }
2784
 
2785
      protected reserveItemInWarehouse_result getResult(I iface, reserveItemInWarehouse_args args) throws org.apache.thrift.TException {
2786
        reserveItemInWarehouse_result result = new reserveItemInWarehouse_result();
2787
        try {
5967 rajveer 2788
          result.success = iface.reserveItemInWarehouse(args.itemId, args.warehouseId, args.sourceId, args.orderId, args.createdTimestamp, args.promisedShippingTimestamp, args.quantity);
5945 mandeep.dh 2789
          result.setSuccessIsSet(true);
2790
        } catch (InventoryServiceException cex) {
2791
          result.cex = cex;
2792
        }
2793
        return result;
2794
      }
2795
    }
2796
 
2797
    private static class reduceReservationCount<I extends Iface> extends org.apache.thrift.ProcessFunction<I, reduceReservationCount_args> {
2798
      public reduceReservationCount() {
2799
        super("reduceReservationCount");
2800
      }
2801
 
2802
      protected reduceReservationCount_args getEmptyArgsInstance() {
2803
        return new reduceReservationCount_args();
2804
      }
2805
 
2806
      protected reduceReservationCount_result getResult(I iface, reduceReservationCount_args args) throws org.apache.thrift.TException {
2807
        reduceReservationCount_result result = new reduceReservationCount_result();
2808
        try {
5967 rajveer 2809
          result.success = iface.reduceReservationCount(args.itemId, args.warehouseId, args.sourceId, args.orderId, args.quantity);
5945 mandeep.dh 2810
          result.setSuccessIsSet(true);
2811
        } catch (InventoryServiceException cex) {
2812
          result.cex = cex;
2813
        }
2814
        return result;
2815
      }
2816
    }
2817
 
2818
    private static class getItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemPricing_args> {
2819
      public getItemPricing() {
2820
        super("getItemPricing");
2821
      }
2822
 
2823
      protected getItemPricing_args getEmptyArgsInstance() {
2824
        return new getItemPricing_args();
2825
      }
2826
 
2827
      protected getItemPricing_result getResult(I iface, getItemPricing_args args) throws org.apache.thrift.TException {
2828
        getItemPricing_result result = new getItemPricing_result();
2829
        try {
2830
          result.success = iface.getItemPricing(args.itemId, args.vendorId);
2831
        } catch (InventoryServiceException cex) {
2832
          result.cex = cex;
2833
        }
2834
        return result;
2835
      }
2836
    }
2837
 
2838
    private static class getAllItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllItemPricing_args> {
2839
      public getAllItemPricing() {
2840
        super("getAllItemPricing");
2841
      }
2842
 
2843
      protected getAllItemPricing_args getEmptyArgsInstance() {
2844
        return new getAllItemPricing_args();
2845
      }
2846
 
2847
      protected getAllItemPricing_result getResult(I iface, getAllItemPricing_args args) throws org.apache.thrift.TException {
2848
        getAllItemPricing_result result = new getAllItemPricing_result();
2849
        try {
2850
          result.success = iface.getAllItemPricing(args.itemId);
2851
        } catch (InventoryServiceException cex) {
2852
          result.cex = cex;
2853
        }
2854
        return result;
2855
      }
2856
    }
2857
 
2858
    private static class addVendorItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendorItemPricing_args> {
2859
      public addVendorItemPricing() {
2860
        super("addVendorItemPricing");
2861
      }
2862
 
2863
      protected addVendorItemPricing_args getEmptyArgsInstance() {
2864
        return new addVendorItemPricing_args();
2865
      }
2866
 
2867
      protected addVendorItemPricing_result getResult(I iface, addVendorItemPricing_args args) throws org.apache.thrift.TException {
2868
        addVendorItemPricing_result result = new addVendorItemPricing_result();
2869
        try {
2870
          iface.addVendorItemPricing(args.vendorItemPricing);
2871
        } catch (InventoryServiceException cex) {
2872
          result.cex = cex;
2873
        }
2874
        return result;
2875
      }
2876
    }
2877
 
2878
    private static class getVendor<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getVendor_args> {
2879
      public getVendor() {
2880
        super("getVendor");
2881
      }
2882
 
2883
      protected getVendor_args getEmptyArgsInstance() {
2884
        return new getVendor_args();
2885
      }
2886
 
2887
      protected getVendor_result getResult(I iface, getVendor_args args) throws org.apache.thrift.TException {
2888
        getVendor_result result = new getVendor_result();
2889
        result.success = iface.getVendor(args.vendorId);
2890
        return result;
2891
      }
2892
    }
2893
 
2894
    private static class getAllVendors<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllVendors_args> {
2895
      public getAllVendors() {
2896
        super("getAllVendors");
2897
      }
2898
 
2899
      protected getAllVendors_args getEmptyArgsInstance() {
2900
        return new getAllVendors_args();
2901
      }
2902
 
2903
      protected getAllVendors_result getResult(I iface, getAllVendors_args args) throws org.apache.thrift.TException {
2904
        getAllVendors_result result = new getAllVendors_result();
2905
        result.success = iface.getAllVendors();
2906
        return result;
2907
      }
2908
    }
2909
 
2910
    private static class addVendorItemMapping<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendorItemMapping_args> {
2911
      public addVendorItemMapping() {
2912
        super("addVendorItemMapping");
2913
      }
2914
 
2915
      protected addVendorItemMapping_args getEmptyArgsInstance() {
2916
        return new addVendorItemMapping_args();
2917
      }
2918
 
2919
      protected addVendorItemMapping_result getResult(I iface, addVendorItemMapping_args args) throws org.apache.thrift.TException {
2920
        addVendorItemMapping_result result = new addVendorItemMapping_result();
2921
        try {
2922
          iface.addVendorItemMapping(args.key, args.vendorItemMapping);
2923
        } catch (InventoryServiceException cex) {
2924
          result.cex = cex;
2925
        }
2926
        return result;
2927
      }
2928
    }
2929
 
2930
    private static class getVendorItemMappings<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getVendorItemMappings_args> {
2931
      public getVendorItemMappings() {
2932
        super("getVendorItemMappings");
2933
      }
2934
 
2935
      protected getVendorItemMappings_args getEmptyArgsInstance() {
2936
        return new getVendorItemMappings_args();
2937
      }
2938
 
2939
      protected getVendorItemMappings_result getResult(I iface, getVendorItemMappings_args args) throws org.apache.thrift.TException {
2940
        getVendorItemMappings_result result = new getVendorItemMappings_result();
2941
        try {
2942
          result.success = iface.getVendorItemMappings(args.itemId);
2943
        } catch (InventoryServiceException cex) {
2944
          result.cex = cex;
2945
        }
2946
        return result;
2947
      }
2948
    }
2949
 
2950
    private static class getPendingOrdersInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPendingOrdersInventory_args> {
2951
      public getPendingOrdersInventory() {
2952
        super("getPendingOrdersInventory");
2953
      }
2954
 
2955
      protected getPendingOrdersInventory_args getEmptyArgsInstance() {
2956
        return new getPendingOrdersInventory_args();
2957
      }
2958
 
2959
      protected getPendingOrdersInventory_result getResult(I iface, getPendingOrdersInventory_args args) throws org.apache.thrift.TException {
2960
        getPendingOrdersInventory_result result = new getPendingOrdersInventory_result();
2961
        result.success = iface.getPendingOrdersInventory(args.vendorid);
2962
        return result;
2963
      }
2964
    }
2965
 
2966
    private static class getWarehouses<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getWarehouses_args> {
2967
      public getWarehouses() {
2968
        super("getWarehouses");
2969
      }
2970
 
2971
      protected getWarehouses_args getEmptyArgsInstance() {
2972
        return new getWarehouses_args();
2973
      }
2974
 
2975
      protected getWarehouses_result getResult(I iface, getWarehouses_args args) throws org.apache.thrift.TException {
2976
        getWarehouses_result result = new getWarehouses_result();
2977
        result.success = iface.getWarehouses(args.warehouseType, args.inventoryType, args.vendorId, args.billingWarehouseId, args.shippingWarehouseId);
2978
        return result;
2979
      }
2980
    }
2981
 
2982
    private static class resetAvailability<I extends Iface> extends org.apache.thrift.ProcessFunction<I, resetAvailability_args> {
2983
      public resetAvailability() {
2984
        super("resetAvailability");
2985
      }
2986
 
2987
      protected resetAvailability_args getEmptyArgsInstance() {
2988
        return new resetAvailability_args();
2989
      }
2990
 
2991
      protected resetAvailability_result getResult(I iface, resetAvailability_args args) throws org.apache.thrift.TException {
2992
        resetAvailability_result result = new resetAvailability_result();
2993
        try {
2994
          iface.resetAvailability(args.itemKey, args.vendorId, args.quantity, args.warehouseId);
2995
        } catch (InventoryServiceException cex) {
2996
          result.cex = cex;
2997
        }
2998
        return result;
2999
      }
3000
    }
3001
 
3002
    private static class resetAvailabilityForWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, resetAvailabilityForWarehouse_args> {
3003
      public resetAvailabilityForWarehouse() {
3004
        super("resetAvailabilityForWarehouse");
3005
      }
3006
 
3007
      protected resetAvailabilityForWarehouse_args getEmptyArgsInstance() {
3008
        return new resetAvailabilityForWarehouse_args();
3009
      }
3010
 
3011
      protected resetAvailabilityForWarehouse_result getResult(I iface, resetAvailabilityForWarehouse_args args) throws org.apache.thrift.TException {
3012
        resetAvailabilityForWarehouse_result result = new resetAvailabilityForWarehouse_result();
3013
        try {
3014
          iface.resetAvailabilityForWarehouse(args.warehouseId);
3015
        } catch (InventoryServiceException cex) {
3016
          result.cex = cex;
3017
        }
3018
        return result;
3019
      }
3020
    }
3021
 
3022
    private static class getItemKeysToBeProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemKeysToBeProcessed_args> {
3023
      public getItemKeysToBeProcessed() {
3024
        super("getItemKeysToBeProcessed");
3025
      }
3026
 
3027
      protected getItemKeysToBeProcessed_args getEmptyArgsInstance() {
3028
        return new getItemKeysToBeProcessed_args();
3029
      }
3030
 
3031
      protected getItemKeysToBeProcessed_result getResult(I iface, getItemKeysToBeProcessed_args args) throws org.apache.thrift.TException {
3032
        getItemKeysToBeProcessed_result result = new getItemKeysToBeProcessed_result();
3033
        result.success = iface.getItemKeysToBeProcessed(args.warehouseId);
3034
        return result;
3035
      }
3036
    }
3037
 
3038
    private static class markMissedInventoryUpdatesAsProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, markMissedInventoryUpdatesAsProcessed_args> {
3039
      public markMissedInventoryUpdatesAsProcessed() {
3040
        super("markMissedInventoryUpdatesAsProcessed");
3041
      }
3042
 
3043
      protected markMissedInventoryUpdatesAsProcessed_args getEmptyArgsInstance() {
3044
        return new markMissedInventoryUpdatesAsProcessed_args();
3045
      }
3046
 
3047
      protected markMissedInventoryUpdatesAsProcessed_result getResult(I iface, markMissedInventoryUpdatesAsProcessed_args args) throws org.apache.thrift.TException {
3048
        markMissedInventoryUpdatesAsProcessed_result result = new markMissedInventoryUpdatesAsProcessed_result();
3049
        iface.markMissedInventoryUpdatesAsProcessed(args.itemKey, args.warehouseId);
3050
        return result;
3051
      }
3052
    }
3053
 
3054
    private static class getIgnoredItemKeys<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getIgnoredItemKeys_args> {
3055
      public getIgnoredItemKeys() {
3056
        super("getIgnoredItemKeys");
3057
      }
3058
 
3059
      protected getIgnoredItemKeys_args getEmptyArgsInstance() {
3060
        return new getIgnoredItemKeys_args();
3061
      }
3062
 
3063
      protected getIgnoredItemKeys_result getResult(I iface, getIgnoredItemKeys_args args) throws org.apache.thrift.TException {
3064
        getIgnoredItemKeys_result result = new getIgnoredItemKeys_result();
3065
        result.success = iface.getIgnoredItemKeys();
3066
        return result;
3067
      }
3068
    }
3069
 
3070
    private static class addBadInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addBadInventory_args> {
3071
      public addBadInventory() {
3072
        super("addBadInventory");
3073
      }
3074
 
3075
      protected addBadInventory_args getEmptyArgsInstance() {
3076
        return new addBadInventory_args();
3077
      }
3078
 
3079
      protected addBadInventory_result getResult(I iface, addBadInventory_args args) throws org.apache.thrift.TException {
3080
        addBadInventory_result result = new addBadInventory_result();
3081
        try {
3082
          iface.addBadInventory(args.itemId, args.warehouseId, args.quantity);
3083
        } catch (InventoryServiceException cex) {
3084
          result.cex = cex;
3085
        }
3086
        return result;
3087
      }
3088
    }
3089
 
3090
    private static class getShippingLocations<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getShippingLocations_args> {
3091
      public getShippingLocations() {
3092
        super("getShippingLocations");
3093
      }
3094
 
3095
      protected getShippingLocations_args getEmptyArgsInstance() {
3096
        return new getShippingLocations_args();
3097
      }
3098
 
3099
      protected getShippingLocations_result getResult(I iface, getShippingLocations_args args) throws org.apache.thrift.TException {
3100
        getShippingLocations_result result = new getShippingLocations_result();
3101
        result.success = iface.getShippingLocations();
3102
        return result;
3103
      }
3104
    }
3105
 
3106
    private static class getAllVendorItemMappings<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllVendorItemMappings_args> {
3107
      public getAllVendorItemMappings() {
3108
        super("getAllVendorItemMappings");
3109
      }
3110
 
3111
      protected getAllVendorItemMappings_args getEmptyArgsInstance() {
3112
        return new getAllVendorItemMappings_args();
3113
      }
3114
 
3115
      protected getAllVendorItemMappings_result getResult(I iface, getAllVendorItemMappings_args args) throws org.apache.thrift.TException {
3116
        getAllVendorItemMappings_result result = new getAllVendorItemMappings_result();
3117
        result.success = iface.getAllVendorItemMappings();
3118
        return result;
3119
      }
3120
    }
3121
 
3122
    private static class getInventorySnapshot<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventorySnapshot_args> {
3123
      public getInventorySnapshot() {
3124
        super("getInventorySnapshot");
3125
      }
3126
 
3127
      protected getInventorySnapshot_args getEmptyArgsInstance() {
3128
        return new getInventorySnapshot_args();
3129
      }
3130
 
3131
      protected getInventorySnapshot_result getResult(I iface, getInventorySnapshot_args args) throws org.apache.thrift.TException {
3132
        getInventorySnapshot_result result = new getInventorySnapshot_result();
3133
        result.success = iface.getInventorySnapshot(args.warehouseId);
3134
        return result;
3135
      }
3136
    }
3137
 
3138
    private static class clearItemAvailabilityCache<I extends Iface> extends org.apache.thrift.ProcessFunction<I, clearItemAvailabilityCache_args> {
3139
      public clearItemAvailabilityCache() {
3140
        super("clearItemAvailabilityCache");
3141
      }
3142
 
3143
      protected clearItemAvailabilityCache_args getEmptyArgsInstance() {
3144
        return new clearItemAvailabilityCache_args();
3145
      }
3146
 
3147
      protected clearItemAvailabilityCache_result getResult(I iface, clearItemAvailabilityCache_args args) throws org.apache.thrift.TException {
3148
        clearItemAvailabilityCache_result result = new clearItemAvailabilityCache_result();
3149
        iface.clearItemAvailabilityCache();
3150
        return result;
3151
      }
3152
    }
3153
 
3154
    private static class updateVendorString<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateVendorString_args> {
3155
      public updateVendorString() {
3156
        super("updateVendorString");
3157
      }
3158
 
3159
      protected updateVendorString_args getEmptyArgsInstance() {
3160
        return new updateVendorString_args();
3161
      }
3162
 
3163
      protected updateVendorString_result getResult(I iface, updateVendorString_args args) throws org.apache.thrift.TException {
3164
        updateVendorString_result result = new updateVendorString_result();
3165
        iface.updateVendorString(args.warehouseId, args.vendorString);
3166
        return result;
3167
      }
3168
    }
3169
 
3170
  }
3171
 
3172
  public static class addWarehouse_args implements org.apache.thrift.TBase<addWarehouse_args, addWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
3173
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addWarehouse_args");
3174
 
3175
    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);
3176
 
3177
    private Warehouse warehouse; // required
3178
 
3179
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3180
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3181
      WAREHOUSE((short)1, "warehouse");
3182
 
3183
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3184
 
3185
      static {
3186
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3187
          byName.put(field.getFieldName(), field);
3188
        }
3189
      }
3190
 
3191
      /**
3192
       * Find the _Fields constant that matches fieldId, or null if its not found.
3193
       */
3194
      public static _Fields findByThriftId(int fieldId) {
3195
        switch(fieldId) {
3196
          case 1: // WAREHOUSE
3197
            return WAREHOUSE;
3198
          default:
3199
            return null;
3200
        }
3201
      }
3202
 
3203
      /**
3204
       * Find the _Fields constant that matches fieldId, throwing an exception
3205
       * if it is not found.
3206
       */
3207
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3208
        _Fields fields = findByThriftId(fieldId);
3209
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3210
        return fields;
3211
      }
3212
 
3213
      /**
3214
       * Find the _Fields constant that matches name, or null if its not found.
3215
       */
3216
      public static _Fields findByName(String name) {
3217
        return byName.get(name);
3218
      }
3219
 
3220
      private final short _thriftId;
3221
      private final String _fieldName;
3222
 
3223
      _Fields(short thriftId, String fieldName) {
3224
        _thriftId = thriftId;
3225
        _fieldName = fieldName;
3226
      }
3227
 
3228
      public short getThriftFieldId() {
3229
        return _thriftId;
3230
      }
3231
 
3232
      public String getFieldName() {
3233
        return _fieldName;
3234
      }
3235
    }
3236
 
3237
    // isset id assignments
3238
 
3239
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3240
    static {
3241
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3242
      tmpMap.put(_Fields.WAREHOUSE, new org.apache.thrift.meta_data.FieldMetaData("warehouse", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3243
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class)));
3244
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3245
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addWarehouse_args.class, metaDataMap);
3246
    }
3247
 
3248
    public addWarehouse_args() {
3249
    }
3250
 
3251
    public addWarehouse_args(
3252
      Warehouse warehouse)
3253
    {
3254
      this();
3255
      this.warehouse = warehouse;
3256
    }
3257
 
3258
    /**
3259
     * Performs a deep copy on <i>other</i>.
3260
     */
3261
    public addWarehouse_args(addWarehouse_args other) {
3262
      if (other.isSetWarehouse()) {
3263
        this.warehouse = new Warehouse(other.warehouse);
3264
      }
3265
    }
3266
 
3267
    public addWarehouse_args deepCopy() {
3268
      return new addWarehouse_args(this);
3269
    }
3270
 
3271
    @Override
3272
    public void clear() {
3273
      this.warehouse = null;
3274
    }
3275
 
3276
    public Warehouse getWarehouse() {
3277
      return this.warehouse;
3278
    }
3279
 
3280
    public void setWarehouse(Warehouse warehouse) {
3281
      this.warehouse = warehouse;
3282
    }
3283
 
3284
    public void unsetWarehouse() {
3285
      this.warehouse = null;
3286
    }
3287
 
3288
    /** Returns true if field warehouse is set (has been assigned a value) and false otherwise */
3289
    public boolean isSetWarehouse() {
3290
      return this.warehouse != null;
3291
    }
3292
 
3293
    public void setWarehouseIsSet(boolean value) {
3294
      if (!value) {
3295
        this.warehouse = null;
3296
      }
3297
    }
3298
 
3299
    public void setFieldValue(_Fields field, Object value) {
3300
      switch (field) {
3301
      case WAREHOUSE:
3302
        if (value == null) {
3303
          unsetWarehouse();
3304
        } else {
3305
          setWarehouse((Warehouse)value);
3306
        }
3307
        break;
3308
 
3309
      }
3310
    }
3311
 
3312
    public Object getFieldValue(_Fields field) {
3313
      switch (field) {
3314
      case WAREHOUSE:
3315
        return getWarehouse();
3316
 
3317
      }
3318
      throw new IllegalStateException();
3319
    }
3320
 
3321
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3322
    public boolean isSet(_Fields field) {
3323
      if (field == null) {
3324
        throw new IllegalArgumentException();
3325
      }
3326
 
3327
      switch (field) {
3328
      case WAREHOUSE:
3329
        return isSetWarehouse();
3330
      }
3331
      throw new IllegalStateException();
3332
    }
3333
 
3334
    @Override
3335
    public boolean equals(Object that) {
3336
      if (that == null)
3337
        return false;
3338
      if (that instanceof addWarehouse_args)
3339
        return this.equals((addWarehouse_args)that);
3340
      return false;
3341
    }
3342
 
3343
    public boolean equals(addWarehouse_args that) {
3344
      if (that == null)
3345
        return false;
3346
 
3347
      boolean this_present_warehouse = true && this.isSetWarehouse();
3348
      boolean that_present_warehouse = true && that.isSetWarehouse();
3349
      if (this_present_warehouse || that_present_warehouse) {
3350
        if (!(this_present_warehouse && that_present_warehouse))
3351
          return false;
3352
        if (!this.warehouse.equals(that.warehouse))
3353
          return false;
3354
      }
3355
 
3356
      return true;
3357
    }
3358
 
3359
    @Override
3360
    public int hashCode() {
3361
      return 0;
3362
    }
3363
 
3364
    public int compareTo(addWarehouse_args other) {
3365
      if (!getClass().equals(other.getClass())) {
3366
        return getClass().getName().compareTo(other.getClass().getName());
3367
      }
3368
 
3369
      int lastComparison = 0;
3370
      addWarehouse_args typedOther = (addWarehouse_args)other;
3371
 
3372
      lastComparison = Boolean.valueOf(isSetWarehouse()).compareTo(typedOther.isSetWarehouse());
3373
      if (lastComparison != 0) {
3374
        return lastComparison;
3375
      }
3376
      if (isSetWarehouse()) {
3377
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse, typedOther.warehouse);
3378
        if (lastComparison != 0) {
3379
          return lastComparison;
3380
        }
3381
      }
3382
      return 0;
3383
    }
3384
 
3385
    public _Fields fieldForId(int fieldId) {
3386
      return _Fields.findByThriftId(fieldId);
3387
    }
3388
 
3389
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3390
      org.apache.thrift.protocol.TField field;
3391
      iprot.readStructBegin();
3392
      while (true)
3393
      {
3394
        field = iprot.readFieldBegin();
3395
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3396
          break;
3397
        }
3398
        switch (field.id) {
3399
          case 1: // WAREHOUSE
3400
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3401
              this.warehouse = new Warehouse();
3402
              this.warehouse.read(iprot);
3403
            } else { 
3404
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3405
            }
3406
            break;
3407
          default:
3408
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3409
        }
3410
        iprot.readFieldEnd();
3411
      }
3412
      iprot.readStructEnd();
3413
      validate();
3414
    }
3415
 
3416
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3417
      validate();
3418
 
3419
      oprot.writeStructBegin(STRUCT_DESC);
3420
      if (this.warehouse != null) {
3421
        oprot.writeFieldBegin(WAREHOUSE_FIELD_DESC);
3422
        this.warehouse.write(oprot);
3423
        oprot.writeFieldEnd();
3424
      }
3425
      oprot.writeFieldStop();
3426
      oprot.writeStructEnd();
3427
    }
3428
 
3429
    @Override
3430
    public String toString() {
3431
      StringBuilder sb = new StringBuilder("addWarehouse_args(");
3432
      boolean first = true;
3433
 
3434
      sb.append("warehouse:");
3435
      if (this.warehouse == null) {
3436
        sb.append("null");
3437
      } else {
3438
        sb.append(this.warehouse);
3439
      }
3440
      first = false;
3441
      sb.append(")");
3442
      return sb.toString();
3443
    }
3444
 
3445
    public void validate() throws org.apache.thrift.TException {
3446
      // check for required fields
3447
    }
3448
 
3449
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3450
      try {
3451
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3452
      } catch (org.apache.thrift.TException te) {
3453
        throw new java.io.IOException(te);
3454
      }
3455
    }
3456
 
3457
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3458
      try {
3459
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3460
      } catch (org.apache.thrift.TException te) {
3461
        throw new java.io.IOException(te);
3462
      }
3463
    }
3464
 
3465
  }
3466
 
3467
  public static class addWarehouse_result implements org.apache.thrift.TBase<addWarehouse_result, addWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
3468
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addWarehouse_result");
3469
 
3470
    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);
3471
    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);
3472
 
3473
    private long success; // required
3474
    private InventoryServiceException cex; // required
3475
 
3476
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3477
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3478
      SUCCESS((short)0, "success"),
3479
      CEX((short)1, "cex");
3480
 
3481
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3482
 
3483
      static {
3484
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3485
          byName.put(field.getFieldName(), field);
3486
        }
3487
      }
3488
 
3489
      /**
3490
       * Find the _Fields constant that matches fieldId, or null if its not found.
3491
       */
3492
      public static _Fields findByThriftId(int fieldId) {
3493
        switch(fieldId) {
3494
          case 0: // SUCCESS
3495
            return SUCCESS;
3496
          case 1: // CEX
3497
            return CEX;
3498
          default:
3499
            return null;
3500
        }
3501
      }
3502
 
3503
      /**
3504
       * Find the _Fields constant that matches fieldId, throwing an exception
3505
       * if it is not found.
3506
       */
3507
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3508
        _Fields fields = findByThriftId(fieldId);
3509
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3510
        return fields;
3511
      }
3512
 
3513
      /**
3514
       * Find the _Fields constant that matches name, or null if its not found.
3515
       */
3516
      public static _Fields findByName(String name) {
3517
        return byName.get(name);
3518
      }
3519
 
3520
      private final short _thriftId;
3521
      private final String _fieldName;
3522
 
3523
      _Fields(short thriftId, String fieldName) {
3524
        _thriftId = thriftId;
3525
        _fieldName = fieldName;
3526
      }
3527
 
3528
      public short getThriftFieldId() {
3529
        return _thriftId;
3530
      }
3531
 
3532
      public String getFieldName() {
3533
        return _fieldName;
3534
      }
3535
    }
3536
 
3537
    // isset id assignments
3538
    private static final int __SUCCESS_ISSET_ID = 0;
3539
    private BitSet __isset_bit_vector = new BitSet(1);
3540
 
3541
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3542
    static {
3543
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3544
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3545
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3546
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3547
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3548
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3549
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addWarehouse_result.class, metaDataMap);
3550
    }
3551
 
3552
    public addWarehouse_result() {
3553
    }
3554
 
3555
    public addWarehouse_result(
3556
      long success,
3557
      InventoryServiceException cex)
3558
    {
3559
      this();
3560
      this.success = success;
3561
      setSuccessIsSet(true);
3562
      this.cex = cex;
3563
    }
3564
 
3565
    /**
3566
     * Performs a deep copy on <i>other</i>.
3567
     */
3568
    public addWarehouse_result(addWarehouse_result other) {
3569
      __isset_bit_vector.clear();
3570
      __isset_bit_vector.or(other.__isset_bit_vector);
3571
      this.success = other.success;
3572
      if (other.isSetCex()) {
3573
        this.cex = new InventoryServiceException(other.cex);
3574
      }
3575
    }
3576
 
3577
    public addWarehouse_result deepCopy() {
3578
      return new addWarehouse_result(this);
3579
    }
3580
 
3581
    @Override
3582
    public void clear() {
3583
      setSuccessIsSet(false);
3584
      this.success = 0;
3585
      this.cex = null;
3586
    }
3587
 
3588
    public long getSuccess() {
3589
      return this.success;
3590
    }
3591
 
3592
    public void setSuccess(long success) {
3593
      this.success = success;
3594
      setSuccessIsSet(true);
3595
    }
3596
 
3597
    public void unsetSuccess() {
3598
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
3599
    }
3600
 
3601
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
3602
    public boolean isSetSuccess() {
3603
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
3604
    }
3605
 
3606
    public void setSuccessIsSet(boolean value) {
3607
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
3608
    }
3609
 
3610
    public InventoryServiceException getCex() {
3611
      return this.cex;
3612
    }
3613
 
3614
    public void setCex(InventoryServiceException cex) {
3615
      this.cex = cex;
3616
    }
3617
 
3618
    public void unsetCex() {
3619
      this.cex = null;
3620
    }
3621
 
3622
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
3623
    public boolean isSetCex() {
3624
      return this.cex != null;
3625
    }
3626
 
3627
    public void setCexIsSet(boolean value) {
3628
      if (!value) {
3629
        this.cex = null;
3630
      }
3631
    }
3632
 
3633
    public void setFieldValue(_Fields field, Object value) {
3634
      switch (field) {
3635
      case SUCCESS:
3636
        if (value == null) {
3637
          unsetSuccess();
3638
        } else {
3639
          setSuccess((Long)value);
3640
        }
3641
        break;
3642
 
3643
      case CEX:
3644
        if (value == null) {
3645
          unsetCex();
3646
        } else {
3647
          setCex((InventoryServiceException)value);
3648
        }
3649
        break;
3650
 
3651
      }
3652
    }
3653
 
3654
    public Object getFieldValue(_Fields field) {
3655
      switch (field) {
3656
      case SUCCESS:
3657
        return Long.valueOf(getSuccess());
3658
 
3659
      case CEX:
3660
        return getCex();
3661
 
3662
      }
3663
      throw new IllegalStateException();
3664
    }
3665
 
3666
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3667
    public boolean isSet(_Fields field) {
3668
      if (field == null) {
3669
        throw new IllegalArgumentException();
3670
      }
3671
 
3672
      switch (field) {
3673
      case SUCCESS:
3674
        return isSetSuccess();
3675
      case CEX:
3676
        return isSetCex();
3677
      }
3678
      throw new IllegalStateException();
3679
    }
3680
 
3681
    @Override
3682
    public boolean equals(Object that) {
3683
      if (that == null)
3684
        return false;
3685
      if (that instanceof addWarehouse_result)
3686
        return this.equals((addWarehouse_result)that);
3687
      return false;
3688
    }
3689
 
3690
    public boolean equals(addWarehouse_result that) {
3691
      if (that == null)
3692
        return false;
3693
 
3694
      boolean this_present_success = true;
3695
      boolean that_present_success = true;
3696
      if (this_present_success || that_present_success) {
3697
        if (!(this_present_success && that_present_success))
3698
          return false;
3699
        if (this.success != that.success)
3700
          return false;
3701
      }
3702
 
3703
      boolean this_present_cex = true && this.isSetCex();
3704
      boolean that_present_cex = true && that.isSetCex();
3705
      if (this_present_cex || that_present_cex) {
3706
        if (!(this_present_cex && that_present_cex))
3707
          return false;
3708
        if (!this.cex.equals(that.cex))
3709
          return false;
3710
      }
3711
 
3712
      return true;
3713
    }
3714
 
3715
    @Override
3716
    public int hashCode() {
3717
      return 0;
3718
    }
3719
 
3720
    public int compareTo(addWarehouse_result other) {
3721
      if (!getClass().equals(other.getClass())) {
3722
        return getClass().getName().compareTo(other.getClass().getName());
3723
      }
3724
 
3725
      int lastComparison = 0;
3726
      addWarehouse_result typedOther = (addWarehouse_result)other;
3727
 
3728
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
3729
      if (lastComparison != 0) {
3730
        return lastComparison;
3731
      }
3732
      if (isSetSuccess()) {
3733
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3734
        if (lastComparison != 0) {
3735
          return lastComparison;
3736
        }
3737
      }
3738
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
3739
      if (lastComparison != 0) {
3740
        return lastComparison;
3741
      }
3742
      if (isSetCex()) {
3743
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
3744
        if (lastComparison != 0) {
3745
          return lastComparison;
3746
        }
3747
      }
3748
      return 0;
3749
    }
3750
 
3751
    public _Fields fieldForId(int fieldId) {
3752
      return _Fields.findByThriftId(fieldId);
3753
    }
3754
 
3755
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3756
      org.apache.thrift.protocol.TField field;
3757
      iprot.readStructBegin();
3758
      while (true)
3759
      {
3760
        field = iprot.readFieldBegin();
3761
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3762
          break;
3763
        }
3764
        switch (field.id) {
3765
          case 0: // SUCCESS
3766
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3767
              this.success = iprot.readI64();
3768
              setSuccessIsSet(true);
3769
            } else { 
3770
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3771
            }
3772
            break;
3773
          case 1: // CEX
3774
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3775
              this.cex = new InventoryServiceException();
3776
              this.cex.read(iprot);
3777
            } else { 
3778
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3779
            }
3780
            break;
3781
          default:
3782
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3783
        }
3784
        iprot.readFieldEnd();
3785
      }
3786
      iprot.readStructEnd();
3787
      validate();
3788
    }
3789
 
3790
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3791
      oprot.writeStructBegin(STRUCT_DESC);
3792
 
3793
      if (this.isSetSuccess()) {
3794
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3795
        oprot.writeI64(this.success);
3796
        oprot.writeFieldEnd();
3797
      } else if (this.isSetCex()) {
3798
        oprot.writeFieldBegin(CEX_FIELD_DESC);
3799
        this.cex.write(oprot);
3800
        oprot.writeFieldEnd();
3801
      }
3802
      oprot.writeFieldStop();
3803
      oprot.writeStructEnd();
3804
    }
3805
 
3806
    @Override
3807
    public String toString() {
3808
      StringBuilder sb = new StringBuilder("addWarehouse_result(");
3809
      boolean first = true;
3810
 
3811
      sb.append("success:");
3812
      sb.append(this.success);
3813
      first = false;
3814
      if (!first) sb.append(", ");
3815
      sb.append("cex:");
3816
      if (this.cex == null) {
3817
        sb.append("null");
3818
      } else {
3819
        sb.append(this.cex);
3820
      }
3821
      first = false;
3822
      sb.append(")");
3823
      return sb.toString();
3824
    }
3825
 
3826
    public void validate() throws org.apache.thrift.TException {
3827
      // check for required fields
3828
    }
3829
 
3830
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3831
      try {
3832
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3833
      } catch (org.apache.thrift.TException te) {
3834
        throw new java.io.IOException(te);
3835
      }
3836
    }
3837
 
3838
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3839
      try {
3840
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3841
      } catch (org.apache.thrift.TException te) {
3842
        throw new java.io.IOException(te);
3843
      }
3844
    }
3845
 
3846
  }
3847
 
3848
  public static class addVendor_args implements org.apache.thrift.TBase<addVendor_args, addVendor_args._Fields>, java.io.Serializable, Cloneable   {
3849
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendor_args");
3850
 
3851
    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);
3852
 
3853
    private Vendor vendor; // required
3854
 
3855
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3856
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3857
      VENDOR((short)1, "vendor");
3858
 
3859
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3860
 
3861
      static {
3862
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3863
          byName.put(field.getFieldName(), field);
3864
        }
3865
      }
3866
 
3867
      /**
3868
       * Find the _Fields constant that matches fieldId, or null if its not found.
3869
       */
3870
      public static _Fields findByThriftId(int fieldId) {
3871
        switch(fieldId) {
3872
          case 1: // VENDOR
3873
            return VENDOR;
3874
          default:
3875
            return null;
3876
        }
3877
      }
3878
 
3879
      /**
3880
       * Find the _Fields constant that matches fieldId, throwing an exception
3881
       * if it is not found.
3882
       */
3883
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3884
        _Fields fields = findByThriftId(fieldId);
3885
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3886
        return fields;
3887
      }
3888
 
3889
      /**
3890
       * Find the _Fields constant that matches name, or null if its not found.
3891
       */
3892
      public static _Fields findByName(String name) {
3893
        return byName.get(name);
3894
      }
3895
 
3896
      private final short _thriftId;
3897
      private final String _fieldName;
3898
 
3899
      _Fields(short thriftId, String fieldName) {
3900
        _thriftId = thriftId;
3901
        _fieldName = fieldName;
3902
      }
3903
 
3904
      public short getThriftFieldId() {
3905
        return _thriftId;
3906
      }
3907
 
3908
      public String getFieldName() {
3909
        return _fieldName;
3910
      }
3911
    }
3912
 
3913
    // isset id assignments
3914
 
3915
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3916
    static {
3917
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3918
      tmpMap.put(_Fields.VENDOR, new org.apache.thrift.meta_data.FieldMetaData("vendor", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3919
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class)));
3920
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3921
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendor_args.class, metaDataMap);
3922
    }
3923
 
3924
    public addVendor_args() {
3925
    }
3926
 
3927
    public addVendor_args(
3928
      Vendor vendor)
3929
    {
3930
      this();
3931
      this.vendor = vendor;
3932
    }
3933
 
3934
    /**
3935
     * Performs a deep copy on <i>other</i>.
3936
     */
3937
    public addVendor_args(addVendor_args other) {
3938
      if (other.isSetVendor()) {
3939
        this.vendor = new Vendor(other.vendor);
3940
      }
3941
    }
3942
 
3943
    public addVendor_args deepCopy() {
3944
      return new addVendor_args(this);
3945
    }
3946
 
3947
    @Override
3948
    public void clear() {
3949
      this.vendor = null;
3950
    }
3951
 
3952
    public Vendor getVendor() {
3953
      return this.vendor;
3954
    }
3955
 
3956
    public void setVendor(Vendor vendor) {
3957
      this.vendor = vendor;
3958
    }
3959
 
3960
    public void unsetVendor() {
3961
      this.vendor = null;
3962
    }
3963
 
3964
    /** Returns true if field vendor is set (has been assigned a value) and false otherwise */
3965
    public boolean isSetVendor() {
3966
      return this.vendor != null;
3967
    }
3968
 
3969
    public void setVendorIsSet(boolean value) {
3970
      if (!value) {
3971
        this.vendor = null;
3972
      }
3973
    }
3974
 
3975
    public void setFieldValue(_Fields field, Object value) {
3976
      switch (field) {
3977
      case VENDOR:
3978
        if (value == null) {
3979
          unsetVendor();
3980
        } else {
3981
          setVendor((Vendor)value);
3982
        }
3983
        break;
3984
 
3985
      }
3986
    }
3987
 
3988
    public Object getFieldValue(_Fields field) {
3989
      switch (field) {
3990
      case VENDOR:
3991
        return getVendor();
3992
 
3993
      }
3994
      throw new IllegalStateException();
3995
    }
3996
 
3997
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3998
    public boolean isSet(_Fields field) {
3999
      if (field == null) {
4000
        throw new IllegalArgumentException();
4001
      }
4002
 
4003
      switch (field) {
4004
      case VENDOR:
4005
        return isSetVendor();
4006
      }
4007
      throw new IllegalStateException();
4008
    }
4009
 
4010
    @Override
4011
    public boolean equals(Object that) {
4012
      if (that == null)
4013
        return false;
4014
      if (that instanceof addVendor_args)
4015
        return this.equals((addVendor_args)that);
4016
      return false;
4017
    }
4018
 
4019
    public boolean equals(addVendor_args that) {
4020
      if (that == null)
4021
        return false;
4022
 
4023
      boolean this_present_vendor = true && this.isSetVendor();
4024
      boolean that_present_vendor = true && that.isSetVendor();
4025
      if (this_present_vendor || that_present_vendor) {
4026
        if (!(this_present_vendor && that_present_vendor))
4027
          return false;
4028
        if (!this.vendor.equals(that.vendor))
4029
          return false;
4030
      }
4031
 
4032
      return true;
4033
    }
4034
 
4035
    @Override
4036
    public int hashCode() {
4037
      return 0;
4038
    }
4039
 
4040
    public int compareTo(addVendor_args other) {
4041
      if (!getClass().equals(other.getClass())) {
4042
        return getClass().getName().compareTo(other.getClass().getName());
4043
      }
4044
 
4045
      int lastComparison = 0;
4046
      addVendor_args typedOther = (addVendor_args)other;
4047
 
4048
      lastComparison = Boolean.valueOf(isSetVendor()).compareTo(typedOther.isSetVendor());
4049
      if (lastComparison != 0) {
4050
        return lastComparison;
4051
      }
4052
      if (isSetVendor()) {
4053
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendor, typedOther.vendor);
4054
        if (lastComparison != 0) {
4055
          return lastComparison;
4056
        }
4057
      }
4058
      return 0;
4059
    }
4060
 
4061
    public _Fields fieldForId(int fieldId) {
4062
      return _Fields.findByThriftId(fieldId);
4063
    }
4064
 
4065
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4066
      org.apache.thrift.protocol.TField field;
4067
      iprot.readStructBegin();
4068
      while (true)
4069
      {
4070
        field = iprot.readFieldBegin();
4071
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4072
          break;
4073
        }
4074
        switch (field.id) {
4075
          case 1: // VENDOR
4076
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4077
              this.vendor = new Vendor();
4078
              this.vendor.read(iprot);
4079
            } else { 
4080
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4081
            }
4082
            break;
4083
          default:
4084
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4085
        }
4086
        iprot.readFieldEnd();
4087
      }
4088
      iprot.readStructEnd();
4089
      validate();
4090
    }
4091
 
4092
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4093
      validate();
4094
 
4095
      oprot.writeStructBegin(STRUCT_DESC);
4096
      if (this.vendor != null) {
4097
        oprot.writeFieldBegin(VENDOR_FIELD_DESC);
4098
        this.vendor.write(oprot);
4099
        oprot.writeFieldEnd();
4100
      }
4101
      oprot.writeFieldStop();
4102
      oprot.writeStructEnd();
4103
    }
4104
 
4105
    @Override
4106
    public String toString() {
4107
      StringBuilder sb = new StringBuilder("addVendor_args(");
4108
      boolean first = true;
4109
 
4110
      sb.append("vendor:");
4111
      if (this.vendor == null) {
4112
        sb.append("null");
4113
      } else {
4114
        sb.append(this.vendor);
4115
      }
4116
      first = false;
4117
      sb.append(")");
4118
      return sb.toString();
4119
    }
4120
 
4121
    public void validate() throws org.apache.thrift.TException {
4122
      // check for required fields
4123
    }
4124
 
4125
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4126
      try {
4127
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4128
      } catch (org.apache.thrift.TException te) {
4129
        throw new java.io.IOException(te);
4130
      }
4131
    }
4132
 
4133
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4134
      try {
4135
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4136
      } catch (org.apache.thrift.TException te) {
4137
        throw new java.io.IOException(te);
4138
      }
4139
    }
4140
 
4141
  }
4142
 
4143
  public static class addVendor_result implements org.apache.thrift.TBase<addVendor_result, addVendor_result._Fields>, java.io.Serializable, Cloneable   {
4144
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendor_result");
4145
 
4146
    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);
4147
    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);
4148
 
4149
    private long success; // required
4150
    private InventoryServiceException cex; // required
4151
 
4152
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4153
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4154
      SUCCESS((short)0, "success"),
4155
      CEX((short)1, "cex");
4156
 
4157
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4158
 
4159
      static {
4160
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4161
          byName.put(field.getFieldName(), field);
4162
        }
4163
      }
4164
 
4165
      /**
4166
       * Find the _Fields constant that matches fieldId, or null if its not found.
4167
       */
4168
      public static _Fields findByThriftId(int fieldId) {
4169
        switch(fieldId) {
4170
          case 0: // SUCCESS
4171
            return SUCCESS;
4172
          case 1: // CEX
4173
            return CEX;
4174
          default:
4175
            return null;
4176
        }
4177
      }
4178
 
4179
      /**
4180
       * Find the _Fields constant that matches fieldId, throwing an exception
4181
       * if it is not found.
4182
       */
4183
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4184
        _Fields fields = findByThriftId(fieldId);
4185
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4186
        return fields;
4187
      }
4188
 
4189
      /**
4190
       * Find the _Fields constant that matches name, or null if its not found.
4191
       */
4192
      public static _Fields findByName(String name) {
4193
        return byName.get(name);
4194
      }
4195
 
4196
      private final short _thriftId;
4197
      private final String _fieldName;
4198
 
4199
      _Fields(short thriftId, String fieldName) {
4200
        _thriftId = thriftId;
4201
        _fieldName = fieldName;
4202
      }
4203
 
4204
      public short getThriftFieldId() {
4205
        return _thriftId;
4206
      }
4207
 
4208
      public String getFieldName() {
4209
        return _fieldName;
4210
      }
4211
    }
4212
 
4213
    // isset id assignments
4214
    private static final int __SUCCESS_ISSET_ID = 0;
4215
    private BitSet __isset_bit_vector = new BitSet(1);
4216
 
4217
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4218
    static {
4219
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4220
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4221
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4222
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4223
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4224
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4225
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendor_result.class, metaDataMap);
4226
    }
4227
 
4228
    public addVendor_result() {
4229
    }
4230
 
4231
    public addVendor_result(
4232
      long success,
4233
      InventoryServiceException cex)
4234
    {
4235
      this();
4236
      this.success = success;
4237
      setSuccessIsSet(true);
4238
      this.cex = cex;
4239
    }
4240
 
4241
    /**
4242
     * Performs a deep copy on <i>other</i>.
4243
     */
4244
    public addVendor_result(addVendor_result other) {
4245
      __isset_bit_vector.clear();
4246
      __isset_bit_vector.or(other.__isset_bit_vector);
4247
      this.success = other.success;
4248
      if (other.isSetCex()) {
4249
        this.cex = new InventoryServiceException(other.cex);
4250
      }
4251
    }
4252
 
4253
    public addVendor_result deepCopy() {
4254
      return new addVendor_result(this);
4255
    }
4256
 
4257
    @Override
4258
    public void clear() {
4259
      setSuccessIsSet(false);
4260
      this.success = 0;
4261
      this.cex = null;
4262
    }
4263
 
4264
    public long getSuccess() {
4265
      return this.success;
4266
    }
4267
 
4268
    public void setSuccess(long success) {
4269
      this.success = success;
4270
      setSuccessIsSet(true);
4271
    }
4272
 
4273
    public void unsetSuccess() {
4274
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
4275
    }
4276
 
4277
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
4278
    public boolean isSetSuccess() {
4279
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
4280
    }
4281
 
4282
    public void setSuccessIsSet(boolean value) {
4283
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
4284
    }
4285
 
4286
    public InventoryServiceException getCex() {
4287
      return this.cex;
4288
    }
4289
 
4290
    public void setCex(InventoryServiceException cex) {
4291
      this.cex = cex;
4292
    }
4293
 
4294
    public void unsetCex() {
4295
      this.cex = null;
4296
    }
4297
 
4298
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
4299
    public boolean isSetCex() {
4300
      return this.cex != null;
4301
    }
4302
 
4303
    public void setCexIsSet(boolean value) {
4304
      if (!value) {
4305
        this.cex = null;
4306
      }
4307
    }
4308
 
4309
    public void setFieldValue(_Fields field, Object value) {
4310
      switch (field) {
4311
      case SUCCESS:
4312
        if (value == null) {
4313
          unsetSuccess();
4314
        } else {
4315
          setSuccess((Long)value);
4316
        }
4317
        break;
4318
 
4319
      case CEX:
4320
        if (value == null) {
4321
          unsetCex();
4322
        } else {
4323
          setCex((InventoryServiceException)value);
4324
        }
4325
        break;
4326
 
4327
      }
4328
    }
4329
 
4330
    public Object getFieldValue(_Fields field) {
4331
      switch (field) {
4332
      case SUCCESS:
4333
        return Long.valueOf(getSuccess());
4334
 
4335
      case CEX:
4336
        return getCex();
4337
 
4338
      }
4339
      throw new IllegalStateException();
4340
    }
4341
 
4342
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4343
    public boolean isSet(_Fields field) {
4344
      if (field == null) {
4345
        throw new IllegalArgumentException();
4346
      }
4347
 
4348
      switch (field) {
4349
      case SUCCESS:
4350
        return isSetSuccess();
4351
      case CEX:
4352
        return isSetCex();
4353
      }
4354
      throw new IllegalStateException();
4355
    }
4356
 
4357
    @Override
4358
    public boolean equals(Object that) {
4359
      if (that == null)
4360
        return false;
4361
      if (that instanceof addVendor_result)
4362
        return this.equals((addVendor_result)that);
4363
      return false;
4364
    }
4365
 
4366
    public boolean equals(addVendor_result that) {
4367
      if (that == null)
4368
        return false;
4369
 
4370
      boolean this_present_success = true;
4371
      boolean that_present_success = true;
4372
      if (this_present_success || that_present_success) {
4373
        if (!(this_present_success && that_present_success))
4374
          return false;
4375
        if (this.success != that.success)
4376
          return false;
4377
      }
4378
 
4379
      boolean this_present_cex = true && this.isSetCex();
4380
      boolean that_present_cex = true && that.isSetCex();
4381
      if (this_present_cex || that_present_cex) {
4382
        if (!(this_present_cex && that_present_cex))
4383
          return false;
4384
        if (!this.cex.equals(that.cex))
4385
          return false;
4386
      }
4387
 
4388
      return true;
4389
    }
4390
 
4391
    @Override
4392
    public int hashCode() {
4393
      return 0;
4394
    }
4395
 
4396
    public int compareTo(addVendor_result other) {
4397
      if (!getClass().equals(other.getClass())) {
4398
        return getClass().getName().compareTo(other.getClass().getName());
4399
      }
4400
 
4401
      int lastComparison = 0;
4402
      addVendor_result typedOther = (addVendor_result)other;
4403
 
4404
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
4405
      if (lastComparison != 0) {
4406
        return lastComparison;
4407
      }
4408
      if (isSetSuccess()) {
4409
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
4410
        if (lastComparison != 0) {
4411
          return lastComparison;
4412
        }
4413
      }
4414
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
4415
      if (lastComparison != 0) {
4416
        return lastComparison;
4417
      }
4418
      if (isSetCex()) {
4419
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
4420
        if (lastComparison != 0) {
4421
          return lastComparison;
4422
        }
4423
      }
4424
      return 0;
4425
    }
4426
 
4427
    public _Fields fieldForId(int fieldId) {
4428
      return _Fields.findByThriftId(fieldId);
4429
    }
4430
 
4431
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4432
      org.apache.thrift.protocol.TField field;
4433
      iprot.readStructBegin();
4434
      while (true)
4435
      {
4436
        field = iprot.readFieldBegin();
4437
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4438
          break;
4439
        }
4440
        switch (field.id) {
4441
          case 0: // SUCCESS
4442
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4443
              this.success = iprot.readI64();
4444
              setSuccessIsSet(true);
4445
            } else { 
4446
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4447
            }
4448
            break;
4449
          case 1: // CEX
4450
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4451
              this.cex = new InventoryServiceException();
4452
              this.cex.read(iprot);
4453
            } else { 
4454
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4455
            }
4456
            break;
4457
          default:
4458
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4459
        }
4460
        iprot.readFieldEnd();
4461
      }
4462
      iprot.readStructEnd();
4463
      validate();
4464
    }
4465
 
4466
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4467
      oprot.writeStructBegin(STRUCT_DESC);
4468
 
4469
      if (this.isSetSuccess()) {
4470
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
4471
        oprot.writeI64(this.success);
4472
        oprot.writeFieldEnd();
4473
      } else if (this.isSetCex()) {
4474
        oprot.writeFieldBegin(CEX_FIELD_DESC);
4475
        this.cex.write(oprot);
4476
        oprot.writeFieldEnd();
4477
      }
4478
      oprot.writeFieldStop();
4479
      oprot.writeStructEnd();
4480
    }
4481
 
4482
    @Override
4483
    public String toString() {
4484
      StringBuilder sb = new StringBuilder("addVendor_result(");
4485
      boolean first = true;
4486
 
4487
      sb.append("success:");
4488
      sb.append(this.success);
4489
      first = false;
4490
      if (!first) sb.append(", ");
4491
      sb.append("cex:");
4492
      if (this.cex == null) {
4493
        sb.append("null");
4494
      } else {
4495
        sb.append(this.cex);
4496
      }
4497
      first = false;
4498
      sb.append(")");
4499
      return sb.toString();
4500
    }
4501
 
4502
    public void validate() throws org.apache.thrift.TException {
4503
      // check for required fields
4504
    }
4505
 
4506
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4507
      try {
4508
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4509
      } catch (org.apache.thrift.TException te) {
4510
        throw new java.io.IOException(te);
4511
      }
4512
    }
4513
 
4514
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4515
      try {
4516
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4517
      } catch (org.apache.thrift.TException te) {
4518
        throw new java.io.IOException(te);
4519
      }
4520
    }
4521
 
4522
  }
4523
 
4524
  public static class updateInventoryHistory_args implements org.apache.thrift.TBase<updateInventoryHistory_args, updateInventoryHistory_args._Fields>, java.io.Serializable, Cloneable   {
4525
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventoryHistory_args");
4526
 
4527
    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);
4528
    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);
4529
    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);
4530
 
4531
    private long warehouse_id; // required
4532
    private String timestamp; // required
4533
    private Map<String,Long> availability; // required
4534
 
4535
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4536
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4537
      WAREHOUSE_ID((short)1, "warehouse_id"),
4538
      TIMESTAMP((short)2, "timestamp"),
4539
      AVAILABILITY((short)3, "availability");
4540
 
4541
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4542
 
4543
      static {
4544
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4545
          byName.put(field.getFieldName(), field);
4546
        }
4547
      }
4548
 
4549
      /**
4550
       * Find the _Fields constant that matches fieldId, or null if its not found.
4551
       */
4552
      public static _Fields findByThriftId(int fieldId) {
4553
        switch(fieldId) {
4554
          case 1: // WAREHOUSE_ID
4555
            return WAREHOUSE_ID;
4556
          case 2: // TIMESTAMP
4557
            return TIMESTAMP;
4558
          case 3: // AVAILABILITY
4559
            return AVAILABILITY;
4560
          default:
4561
            return null;
4562
        }
4563
      }
4564
 
4565
      /**
4566
       * Find the _Fields constant that matches fieldId, throwing an exception
4567
       * if it is not found.
4568
       */
4569
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4570
        _Fields fields = findByThriftId(fieldId);
4571
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4572
        return fields;
4573
      }
4574
 
4575
      /**
4576
       * Find the _Fields constant that matches name, or null if its not found.
4577
       */
4578
      public static _Fields findByName(String name) {
4579
        return byName.get(name);
4580
      }
4581
 
4582
      private final short _thriftId;
4583
      private final String _fieldName;
4584
 
4585
      _Fields(short thriftId, String fieldName) {
4586
        _thriftId = thriftId;
4587
        _fieldName = fieldName;
4588
      }
4589
 
4590
      public short getThriftFieldId() {
4591
        return _thriftId;
4592
      }
4593
 
4594
      public String getFieldName() {
4595
        return _fieldName;
4596
      }
4597
    }
4598
 
4599
    // isset id assignments
4600
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
4601
    private BitSet __isset_bit_vector = new BitSet(1);
4602
 
4603
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4604
    static {
4605
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4606
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4607
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4608
      tmpMap.put(_Fields.TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("timestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4609
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
4610
      tmpMap.put(_Fields.AVAILABILITY, new org.apache.thrift.meta_data.FieldMetaData("availability", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4611
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
4612
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
4613
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
4614
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4615
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventoryHistory_args.class, metaDataMap);
4616
    }
4617
 
4618
    public updateInventoryHistory_args() {
4619
    }
4620
 
4621
    public updateInventoryHistory_args(
4622
      long warehouse_id,
4623
      String timestamp,
4624
      Map<String,Long> availability)
4625
    {
4626
      this();
4627
      this.warehouse_id = warehouse_id;
4628
      setWarehouse_idIsSet(true);
4629
      this.timestamp = timestamp;
4630
      this.availability = availability;
4631
    }
4632
 
4633
    /**
4634
     * Performs a deep copy on <i>other</i>.
4635
     */
4636
    public updateInventoryHistory_args(updateInventoryHistory_args other) {
4637
      __isset_bit_vector.clear();
4638
      __isset_bit_vector.or(other.__isset_bit_vector);
4639
      this.warehouse_id = other.warehouse_id;
4640
      if (other.isSetTimestamp()) {
4641
        this.timestamp = other.timestamp;
4642
      }
4643
      if (other.isSetAvailability()) {
4644
        Map<String,Long> __this__availability = new HashMap<String,Long>();
4645
        for (Map.Entry<String, Long> other_element : other.availability.entrySet()) {
4646
 
4647
          String other_element_key = other_element.getKey();
4648
          Long other_element_value = other_element.getValue();
4649
 
4650
          String __this__availability_copy_key = other_element_key;
4651
 
4652
          Long __this__availability_copy_value = other_element_value;
4653
 
4654
          __this__availability.put(__this__availability_copy_key, __this__availability_copy_value);
4655
        }
4656
        this.availability = __this__availability;
4657
      }
4658
    }
4659
 
4660
    public updateInventoryHistory_args deepCopy() {
4661
      return new updateInventoryHistory_args(this);
4662
    }
4663
 
4664
    @Override
4665
    public void clear() {
4666
      setWarehouse_idIsSet(false);
4667
      this.warehouse_id = 0;
4668
      this.timestamp = null;
4669
      this.availability = null;
4670
    }
4671
 
4672
    public long getWarehouse_id() {
4673
      return this.warehouse_id;
4674
    }
4675
 
4676
    public void setWarehouse_id(long warehouse_id) {
4677
      this.warehouse_id = warehouse_id;
4678
      setWarehouse_idIsSet(true);
4679
    }
4680
 
4681
    public void unsetWarehouse_id() {
4682
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
4683
    }
4684
 
4685
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
4686
    public boolean isSetWarehouse_id() {
4687
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
4688
    }
4689
 
4690
    public void setWarehouse_idIsSet(boolean value) {
4691
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
4692
    }
4693
 
4694
    public String getTimestamp() {
4695
      return this.timestamp;
4696
    }
4697
 
4698
    public void setTimestamp(String timestamp) {
4699
      this.timestamp = timestamp;
4700
    }
4701
 
4702
    public void unsetTimestamp() {
4703
      this.timestamp = null;
4704
    }
4705
 
4706
    /** Returns true if field timestamp is set (has been assigned a value) and false otherwise */
4707
    public boolean isSetTimestamp() {
4708
      return this.timestamp != null;
4709
    }
4710
 
4711
    public void setTimestampIsSet(boolean value) {
4712
      if (!value) {
4713
        this.timestamp = null;
4714
      }
4715
    }
4716
 
4717
    public int getAvailabilitySize() {
4718
      return (this.availability == null) ? 0 : this.availability.size();
4719
    }
4720
 
4721
    public void putToAvailability(String key, long val) {
4722
      if (this.availability == null) {
4723
        this.availability = new HashMap<String,Long>();
4724
      }
4725
      this.availability.put(key, val);
4726
    }
4727
 
4728
    public Map<String,Long> getAvailability() {
4729
      return this.availability;
4730
    }
4731
 
4732
    public void setAvailability(Map<String,Long> availability) {
4733
      this.availability = availability;
4734
    }
4735
 
4736
    public void unsetAvailability() {
4737
      this.availability = null;
4738
    }
4739
 
4740
    /** Returns true if field availability is set (has been assigned a value) and false otherwise */
4741
    public boolean isSetAvailability() {
4742
      return this.availability != null;
4743
    }
4744
 
4745
    public void setAvailabilityIsSet(boolean value) {
4746
      if (!value) {
4747
        this.availability = null;
4748
      }
4749
    }
4750
 
4751
    public void setFieldValue(_Fields field, Object value) {
4752
      switch (field) {
4753
      case WAREHOUSE_ID:
4754
        if (value == null) {
4755
          unsetWarehouse_id();
4756
        } else {
4757
          setWarehouse_id((Long)value);
4758
        }
4759
        break;
4760
 
4761
      case TIMESTAMP:
4762
        if (value == null) {
4763
          unsetTimestamp();
4764
        } else {
4765
          setTimestamp((String)value);
4766
        }
4767
        break;
4768
 
4769
      case AVAILABILITY:
4770
        if (value == null) {
4771
          unsetAvailability();
4772
        } else {
4773
          setAvailability((Map<String,Long>)value);
4774
        }
4775
        break;
4776
 
4777
      }
4778
    }
4779
 
4780
    public Object getFieldValue(_Fields field) {
4781
      switch (field) {
4782
      case WAREHOUSE_ID:
4783
        return Long.valueOf(getWarehouse_id());
4784
 
4785
      case TIMESTAMP:
4786
        return getTimestamp();
4787
 
4788
      case AVAILABILITY:
4789
        return getAvailability();
4790
 
4791
      }
4792
      throw new IllegalStateException();
4793
    }
4794
 
4795
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4796
    public boolean isSet(_Fields field) {
4797
      if (field == null) {
4798
        throw new IllegalArgumentException();
4799
      }
4800
 
4801
      switch (field) {
4802
      case WAREHOUSE_ID:
4803
        return isSetWarehouse_id();
4804
      case TIMESTAMP:
4805
        return isSetTimestamp();
4806
      case AVAILABILITY:
4807
        return isSetAvailability();
4808
      }
4809
      throw new IllegalStateException();
4810
    }
4811
 
4812
    @Override
4813
    public boolean equals(Object that) {
4814
      if (that == null)
4815
        return false;
4816
      if (that instanceof updateInventoryHistory_args)
4817
        return this.equals((updateInventoryHistory_args)that);
4818
      return false;
4819
    }
4820
 
4821
    public boolean equals(updateInventoryHistory_args that) {
4822
      if (that == null)
4823
        return false;
4824
 
4825
      boolean this_present_warehouse_id = true;
4826
      boolean that_present_warehouse_id = true;
4827
      if (this_present_warehouse_id || that_present_warehouse_id) {
4828
        if (!(this_present_warehouse_id && that_present_warehouse_id))
4829
          return false;
4830
        if (this.warehouse_id != that.warehouse_id)
4831
          return false;
4832
      }
4833
 
4834
      boolean this_present_timestamp = true && this.isSetTimestamp();
4835
      boolean that_present_timestamp = true && that.isSetTimestamp();
4836
      if (this_present_timestamp || that_present_timestamp) {
4837
        if (!(this_present_timestamp && that_present_timestamp))
4838
          return false;
4839
        if (!this.timestamp.equals(that.timestamp))
4840
          return false;
4841
      }
4842
 
4843
      boolean this_present_availability = true && this.isSetAvailability();
4844
      boolean that_present_availability = true && that.isSetAvailability();
4845
      if (this_present_availability || that_present_availability) {
4846
        if (!(this_present_availability && that_present_availability))
4847
          return false;
4848
        if (!this.availability.equals(that.availability))
4849
          return false;
4850
      }
4851
 
4852
      return true;
4853
    }
4854
 
4855
    @Override
4856
    public int hashCode() {
4857
      return 0;
4858
    }
4859
 
4860
    public int compareTo(updateInventoryHistory_args other) {
4861
      if (!getClass().equals(other.getClass())) {
4862
        return getClass().getName().compareTo(other.getClass().getName());
4863
      }
4864
 
4865
      int lastComparison = 0;
4866
      updateInventoryHistory_args typedOther = (updateInventoryHistory_args)other;
4867
 
4868
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
4869
      if (lastComparison != 0) {
4870
        return lastComparison;
4871
      }
4872
      if (isSetWarehouse_id()) {
4873
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
4874
        if (lastComparison != 0) {
4875
          return lastComparison;
4876
        }
4877
      }
4878
      lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(typedOther.isSetTimestamp());
4879
      if (lastComparison != 0) {
4880
        return lastComparison;
4881
      }
4882
      if (isSetTimestamp()) {
4883
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.timestamp, typedOther.timestamp);
4884
        if (lastComparison != 0) {
4885
          return lastComparison;
4886
        }
4887
      }
4888
      lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(typedOther.isSetAvailability());
4889
      if (lastComparison != 0) {
4890
        return lastComparison;
4891
      }
4892
      if (isSetAvailability()) {
4893
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.availability, typedOther.availability);
4894
        if (lastComparison != 0) {
4895
          return lastComparison;
4896
        }
4897
      }
4898
      return 0;
4899
    }
4900
 
4901
    public _Fields fieldForId(int fieldId) {
4902
      return _Fields.findByThriftId(fieldId);
4903
    }
4904
 
4905
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4906
      org.apache.thrift.protocol.TField field;
4907
      iprot.readStructBegin();
4908
      while (true)
4909
      {
4910
        field = iprot.readFieldBegin();
4911
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4912
          break;
4913
        }
4914
        switch (field.id) {
4915
          case 1: // WAREHOUSE_ID
4916
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4917
              this.warehouse_id = iprot.readI64();
4918
              setWarehouse_idIsSet(true);
4919
            } else { 
4920
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4921
            }
4922
            break;
4923
          case 2: // TIMESTAMP
4924
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
4925
              this.timestamp = iprot.readString();
4926
            } else { 
4927
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4928
            }
4929
            break;
4930
          case 3: // AVAILABILITY
4931
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
4932
              {
4933
                org.apache.thrift.protocol.TMap _map10 = iprot.readMapBegin();
4934
                this.availability = new HashMap<String,Long>(2*_map10.size);
4935
                for (int _i11 = 0; _i11 < _map10.size; ++_i11)
4936
                {
4937
                  String _key12; // required
4938
                  long _val13; // required
4939
                  _key12 = iprot.readString();
4940
                  _val13 = iprot.readI64();
4941
                  this.availability.put(_key12, _val13);
4942
                }
4943
                iprot.readMapEnd();
4944
              }
4945
            } else { 
4946
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4947
            }
4948
            break;
4949
          default:
4950
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4951
        }
4952
        iprot.readFieldEnd();
4953
      }
4954
      iprot.readStructEnd();
4955
      validate();
4956
    }
4957
 
4958
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4959
      validate();
4960
 
4961
      oprot.writeStructBegin(STRUCT_DESC);
4962
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
4963
      oprot.writeI64(this.warehouse_id);
4964
      oprot.writeFieldEnd();
4965
      if (this.timestamp != null) {
4966
        oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
4967
        oprot.writeString(this.timestamp);
4968
        oprot.writeFieldEnd();
4969
      }
4970
      if (this.availability != null) {
4971
        oprot.writeFieldBegin(AVAILABILITY_FIELD_DESC);
4972
        {
4973
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.I64, this.availability.size()));
4974
          for (Map.Entry<String, Long> _iter14 : this.availability.entrySet())
4975
          {
4976
            oprot.writeString(_iter14.getKey());
4977
            oprot.writeI64(_iter14.getValue());
4978
          }
4979
          oprot.writeMapEnd();
4980
        }
4981
        oprot.writeFieldEnd();
4982
      }
4983
      oprot.writeFieldStop();
4984
      oprot.writeStructEnd();
4985
    }
4986
 
4987
    @Override
4988
    public String toString() {
4989
      StringBuilder sb = new StringBuilder("updateInventoryHistory_args(");
4990
      boolean first = true;
4991
 
4992
      sb.append("warehouse_id:");
4993
      sb.append(this.warehouse_id);
4994
      first = false;
4995
      if (!first) sb.append(", ");
4996
      sb.append("timestamp:");
4997
      if (this.timestamp == null) {
4998
        sb.append("null");
4999
      } else {
5000
        sb.append(this.timestamp);
5001
      }
5002
      first = false;
5003
      if (!first) sb.append(", ");
5004
      sb.append("availability:");
5005
      if (this.availability == null) {
5006
        sb.append("null");
5007
      } else {
5008
        sb.append(this.availability);
5009
      }
5010
      first = false;
5011
      sb.append(")");
5012
      return sb.toString();
5013
    }
5014
 
5015
    public void validate() throws org.apache.thrift.TException {
5016
      // check for required fields
5017
    }
5018
 
5019
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5020
      try {
5021
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5022
      } catch (org.apache.thrift.TException te) {
5023
        throw new java.io.IOException(te);
5024
      }
5025
    }
5026
 
5027
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5028
      try {
5029
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
5030
        __isset_bit_vector = new BitSet(1);
5031
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5032
      } catch (org.apache.thrift.TException te) {
5033
        throw new java.io.IOException(te);
5034
      }
5035
    }
5036
 
5037
  }
5038
 
5039
  public static class updateInventoryHistory_result implements org.apache.thrift.TBase<updateInventoryHistory_result, updateInventoryHistory_result._Fields>, java.io.Serializable, Cloneable   {
5040
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventoryHistory_result");
5041
 
5042
    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);
5043
 
5044
    private InventoryServiceException cex; // required
5045
 
5046
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5047
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5048
      CEX((short)1, "cex");
5049
 
5050
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5051
 
5052
      static {
5053
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5054
          byName.put(field.getFieldName(), field);
5055
        }
5056
      }
5057
 
5058
      /**
5059
       * Find the _Fields constant that matches fieldId, or null if its not found.
5060
       */
5061
      public static _Fields findByThriftId(int fieldId) {
5062
        switch(fieldId) {
5063
          case 1: // CEX
5064
            return CEX;
5065
          default:
5066
            return null;
5067
        }
5068
      }
5069
 
5070
      /**
5071
       * Find the _Fields constant that matches fieldId, throwing an exception
5072
       * if it is not found.
5073
       */
5074
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5075
        _Fields fields = findByThriftId(fieldId);
5076
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5077
        return fields;
5078
      }
5079
 
5080
      /**
5081
       * Find the _Fields constant that matches name, or null if its not found.
5082
       */
5083
      public static _Fields findByName(String name) {
5084
        return byName.get(name);
5085
      }
5086
 
5087
      private final short _thriftId;
5088
      private final String _fieldName;
5089
 
5090
      _Fields(short thriftId, String fieldName) {
5091
        _thriftId = thriftId;
5092
        _fieldName = fieldName;
5093
      }
5094
 
5095
      public short getThriftFieldId() {
5096
        return _thriftId;
5097
      }
5098
 
5099
      public String getFieldName() {
5100
        return _fieldName;
5101
      }
5102
    }
5103
 
5104
    // isset id assignments
5105
 
5106
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5107
    static {
5108
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5109
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5110
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5111
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5112
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventoryHistory_result.class, metaDataMap);
5113
    }
5114
 
5115
    public updateInventoryHistory_result() {
5116
    }
5117
 
5118
    public updateInventoryHistory_result(
5119
      InventoryServiceException cex)
5120
    {
5121
      this();
5122
      this.cex = cex;
5123
    }
5124
 
5125
    /**
5126
     * Performs a deep copy on <i>other</i>.
5127
     */
5128
    public updateInventoryHistory_result(updateInventoryHistory_result other) {
5129
      if (other.isSetCex()) {
5130
        this.cex = new InventoryServiceException(other.cex);
5131
      }
5132
    }
5133
 
5134
    public updateInventoryHistory_result deepCopy() {
5135
      return new updateInventoryHistory_result(this);
5136
    }
5137
 
5138
    @Override
5139
    public void clear() {
5140
      this.cex = null;
5141
    }
5142
 
5143
    public InventoryServiceException getCex() {
5144
      return this.cex;
5145
    }
5146
 
5147
    public void setCex(InventoryServiceException cex) {
5148
      this.cex = cex;
5149
    }
5150
 
5151
    public void unsetCex() {
5152
      this.cex = null;
5153
    }
5154
 
5155
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
5156
    public boolean isSetCex() {
5157
      return this.cex != null;
5158
    }
5159
 
5160
    public void setCexIsSet(boolean value) {
5161
      if (!value) {
5162
        this.cex = null;
5163
      }
5164
    }
5165
 
5166
    public void setFieldValue(_Fields field, Object value) {
5167
      switch (field) {
5168
      case CEX:
5169
        if (value == null) {
5170
          unsetCex();
5171
        } else {
5172
          setCex((InventoryServiceException)value);
5173
        }
5174
        break;
5175
 
5176
      }
5177
    }
5178
 
5179
    public Object getFieldValue(_Fields field) {
5180
      switch (field) {
5181
      case CEX:
5182
        return getCex();
5183
 
5184
      }
5185
      throw new IllegalStateException();
5186
    }
5187
 
5188
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5189
    public boolean isSet(_Fields field) {
5190
      if (field == null) {
5191
        throw new IllegalArgumentException();
5192
      }
5193
 
5194
      switch (field) {
5195
      case CEX:
5196
        return isSetCex();
5197
      }
5198
      throw new IllegalStateException();
5199
    }
5200
 
5201
    @Override
5202
    public boolean equals(Object that) {
5203
      if (that == null)
5204
        return false;
5205
      if (that instanceof updateInventoryHistory_result)
5206
        return this.equals((updateInventoryHistory_result)that);
5207
      return false;
5208
    }
5209
 
5210
    public boolean equals(updateInventoryHistory_result that) {
5211
      if (that == null)
5212
        return false;
5213
 
5214
      boolean this_present_cex = true && this.isSetCex();
5215
      boolean that_present_cex = true && that.isSetCex();
5216
      if (this_present_cex || that_present_cex) {
5217
        if (!(this_present_cex && that_present_cex))
5218
          return false;
5219
        if (!this.cex.equals(that.cex))
5220
          return false;
5221
      }
5222
 
5223
      return true;
5224
    }
5225
 
5226
    @Override
5227
    public int hashCode() {
5228
      return 0;
5229
    }
5230
 
5231
    public int compareTo(updateInventoryHistory_result other) {
5232
      if (!getClass().equals(other.getClass())) {
5233
        return getClass().getName().compareTo(other.getClass().getName());
5234
      }
5235
 
5236
      int lastComparison = 0;
5237
      updateInventoryHistory_result typedOther = (updateInventoryHistory_result)other;
5238
 
5239
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
5240
      if (lastComparison != 0) {
5241
        return lastComparison;
5242
      }
5243
      if (isSetCex()) {
5244
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
5245
        if (lastComparison != 0) {
5246
          return lastComparison;
5247
        }
5248
      }
5249
      return 0;
5250
    }
5251
 
5252
    public _Fields fieldForId(int fieldId) {
5253
      return _Fields.findByThriftId(fieldId);
5254
    }
5255
 
5256
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5257
      org.apache.thrift.protocol.TField field;
5258
      iprot.readStructBegin();
5259
      while (true)
5260
      {
5261
        field = iprot.readFieldBegin();
5262
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5263
          break;
5264
        }
5265
        switch (field.id) {
5266
          case 1: // CEX
5267
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5268
              this.cex = new InventoryServiceException();
5269
              this.cex.read(iprot);
5270
            } else { 
5271
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5272
            }
5273
            break;
5274
          default:
5275
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5276
        }
5277
        iprot.readFieldEnd();
5278
      }
5279
      iprot.readStructEnd();
5280
      validate();
5281
    }
5282
 
5283
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5284
      oprot.writeStructBegin(STRUCT_DESC);
5285
 
5286
      if (this.isSetCex()) {
5287
        oprot.writeFieldBegin(CEX_FIELD_DESC);
5288
        this.cex.write(oprot);
5289
        oprot.writeFieldEnd();
5290
      }
5291
      oprot.writeFieldStop();
5292
      oprot.writeStructEnd();
5293
    }
5294
 
5295
    @Override
5296
    public String toString() {
5297
      StringBuilder sb = new StringBuilder("updateInventoryHistory_result(");
5298
      boolean first = true;
5299
 
5300
      sb.append("cex:");
5301
      if (this.cex == null) {
5302
        sb.append("null");
5303
      } else {
5304
        sb.append(this.cex);
5305
      }
5306
      first = false;
5307
      sb.append(")");
5308
      return sb.toString();
5309
    }
5310
 
5311
    public void validate() throws org.apache.thrift.TException {
5312
      // check for required fields
5313
    }
5314
 
5315
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5316
      try {
5317
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5318
      } catch (org.apache.thrift.TException te) {
5319
        throw new java.io.IOException(te);
5320
      }
5321
    }
5322
 
5323
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5324
      try {
5325
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5326
      } catch (org.apache.thrift.TException te) {
5327
        throw new java.io.IOException(te);
5328
      }
5329
    }
5330
 
5331
  }
5332
 
5333
  public static class updateInventory_args implements org.apache.thrift.TBase<updateInventory_args, updateInventory_args._Fields>, java.io.Serializable, Cloneable   {
5334
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventory_args");
5335
 
5336
    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);
5337
    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);
5338
    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);
5339
 
5340
    private long warehouse_id; // required
5341
    private String timestamp; // required
5342
    private Map<String,Long> availability; // required
5343
 
5344
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5345
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5346
      WAREHOUSE_ID((short)1, "warehouse_id"),
5347
      TIMESTAMP((short)2, "timestamp"),
5348
      AVAILABILITY((short)3, "availability");
5349
 
5350
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5351
 
5352
      static {
5353
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5354
          byName.put(field.getFieldName(), field);
5355
        }
5356
      }
5357
 
5358
      /**
5359
       * Find the _Fields constant that matches fieldId, or null if its not found.
5360
       */
5361
      public static _Fields findByThriftId(int fieldId) {
5362
        switch(fieldId) {
5363
          case 1: // WAREHOUSE_ID
5364
            return WAREHOUSE_ID;
5365
          case 2: // TIMESTAMP
5366
            return TIMESTAMP;
5367
          case 3: // AVAILABILITY
5368
            return AVAILABILITY;
5369
          default:
5370
            return null;
5371
        }
5372
      }
5373
 
5374
      /**
5375
       * Find the _Fields constant that matches fieldId, throwing an exception
5376
       * if it is not found.
5377
       */
5378
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5379
        _Fields fields = findByThriftId(fieldId);
5380
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5381
        return fields;
5382
      }
5383
 
5384
      /**
5385
       * Find the _Fields constant that matches name, or null if its not found.
5386
       */
5387
      public static _Fields findByName(String name) {
5388
        return byName.get(name);
5389
      }
5390
 
5391
      private final short _thriftId;
5392
      private final String _fieldName;
5393
 
5394
      _Fields(short thriftId, String fieldName) {
5395
        _thriftId = thriftId;
5396
        _fieldName = fieldName;
5397
      }
5398
 
5399
      public short getThriftFieldId() {
5400
        return _thriftId;
5401
      }
5402
 
5403
      public String getFieldName() {
5404
        return _fieldName;
5405
      }
5406
    }
5407
 
5408
    // isset id assignments
5409
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
5410
    private BitSet __isset_bit_vector = new BitSet(1);
5411
 
5412
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5413
    static {
5414
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5415
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5416
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5417
      tmpMap.put(_Fields.TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("timestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5418
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
5419
      tmpMap.put(_Fields.AVAILABILITY, new org.apache.thrift.meta_data.FieldMetaData("availability", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5420
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
5421
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
5422
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
5423
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5424
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventory_args.class, metaDataMap);
5425
    }
5426
 
5427
    public updateInventory_args() {
5428
    }
5429
 
5430
    public updateInventory_args(
5431
      long warehouse_id,
5432
      String timestamp,
5433
      Map<String,Long> availability)
5434
    {
5435
      this();
5436
      this.warehouse_id = warehouse_id;
5437
      setWarehouse_idIsSet(true);
5438
      this.timestamp = timestamp;
5439
      this.availability = availability;
5440
    }
5441
 
5442
    /**
5443
     * Performs a deep copy on <i>other</i>.
5444
     */
5445
    public updateInventory_args(updateInventory_args other) {
5446
      __isset_bit_vector.clear();
5447
      __isset_bit_vector.or(other.__isset_bit_vector);
5448
      this.warehouse_id = other.warehouse_id;
5449
      if (other.isSetTimestamp()) {
5450
        this.timestamp = other.timestamp;
5451
      }
5452
      if (other.isSetAvailability()) {
5453
        Map<String,Long> __this__availability = new HashMap<String,Long>();
5454
        for (Map.Entry<String, Long> other_element : other.availability.entrySet()) {
5455
 
5456
          String other_element_key = other_element.getKey();
5457
          Long other_element_value = other_element.getValue();
5458
 
5459
          String __this__availability_copy_key = other_element_key;
5460
 
5461
          Long __this__availability_copy_value = other_element_value;
5462
 
5463
          __this__availability.put(__this__availability_copy_key, __this__availability_copy_value);
5464
        }
5465
        this.availability = __this__availability;
5466
      }
5467
    }
5468
 
5469
    public updateInventory_args deepCopy() {
5470
      return new updateInventory_args(this);
5471
    }
5472
 
5473
    @Override
5474
    public void clear() {
5475
      setWarehouse_idIsSet(false);
5476
      this.warehouse_id = 0;
5477
      this.timestamp = null;
5478
      this.availability = null;
5479
    }
5480
 
5481
    public long getWarehouse_id() {
5482
      return this.warehouse_id;
5483
    }
5484
 
5485
    public void setWarehouse_id(long warehouse_id) {
5486
      this.warehouse_id = warehouse_id;
5487
      setWarehouse_idIsSet(true);
5488
    }
5489
 
5490
    public void unsetWarehouse_id() {
5491
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
5492
    }
5493
 
5494
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
5495
    public boolean isSetWarehouse_id() {
5496
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
5497
    }
5498
 
5499
    public void setWarehouse_idIsSet(boolean value) {
5500
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
5501
    }
5502
 
5503
    public String getTimestamp() {
5504
      return this.timestamp;
5505
    }
5506
 
5507
    public void setTimestamp(String timestamp) {
5508
      this.timestamp = timestamp;
5509
    }
5510
 
5511
    public void unsetTimestamp() {
5512
      this.timestamp = null;
5513
    }
5514
 
5515
    /** Returns true if field timestamp is set (has been assigned a value) and false otherwise */
5516
    public boolean isSetTimestamp() {
5517
      return this.timestamp != null;
5518
    }
5519
 
5520
    public void setTimestampIsSet(boolean value) {
5521
      if (!value) {
5522
        this.timestamp = null;
5523
      }
5524
    }
5525
 
5526
    public int getAvailabilitySize() {
5527
      return (this.availability == null) ? 0 : this.availability.size();
5528
    }
5529
 
5530
    public void putToAvailability(String key, long val) {
5531
      if (this.availability == null) {
5532
        this.availability = new HashMap<String,Long>();
5533
      }
5534
      this.availability.put(key, val);
5535
    }
5536
 
5537
    public Map<String,Long> getAvailability() {
5538
      return this.availability;
5539
    }
5540
 
5541
    public void setAvailability(Map<String,Long> availability) {
5542
      this.availability = availability;
5543
    }
5544
 
5545
    public void unsetAvailability() {
5546
      this.availability = null;
5547
    }
5548
 
5549
    /** Returns true if field availability is set (has been assigned a value) and false otherwise */
5550
    public boolean isSetAvailability() {
5551
      return this.availability != null;
5552
    }
5553
 
5554
    public void setAvailabilityIsSet(boolean value) {
5555
      if (!value) {
5556
        this.availability = null;
5557
      }
5558
    }
5559
 
5560
    public void setFieldValue(_Fields field, Object value) {
5561
      switch (field) {
5562
      case WAREHOUSE_ID:
5563
        if (value == null) {
5564
          unsetWarehouse_id();
5565
        } else {
5566
          setWarehouse_id((Long)value);
5567
        }
5568
        break;
5569
 
5570
      case TIMESTAMP:
5571
        if (value == null) {
5572
          unsetTimestamp();
5573
        } else {
5574
          setTimestamp((String)value);
5575
        }
5576
        break;
5577
 
5578
      case AVAILABILITY:
5579
        if (value == null) {
5580
          unsetAvailability();
5581
        } else {
5582
          setAvailability((Map<String,Long>)value);
5583
        }
5584
        break;
5585
 
5586
      }
5587
    }
5588
 
5589
    public Object getFieldValue(_Fields field) {
5590
      switch (field) {
5591
      case WAREHOUSE_ID:
5592
        return Long.valueOf(getWarehouse_id());
5593
 
5594
      case TIMESTAMP:
5595
        return getTimestamp();
5596
 
5597
      case AVAILABILITY:
5598
        return getAvailability();
5599
 
5600
      }
5601
      throw new IllegalStateException();
5602
    }
5603
 
5604
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5605
    public boolean isSet(_Fields field) {
5606
      if (field == null) {
5607
        throw new IllegalArgumentException();
5608
      }
5609
 
5610
      switch (field) {
5611
      case WAREHOUSE_ID:
5612
        return isSetWarehouse_id();
5613
      case TIMESTAMP:
5614
        return isSetTimestamp();
5615
      case AVAILABILITY:
5616
        return isSetAvailability();
5617
      }
5618
      throw new IllegalStateException();
5619
    }
5620
 
5621
    @Override
5622
    public boolean equals(Object that) {
5623
      if (that == null)
5624
        return false;
5625
      if (that instanceof updateInventory_args)
5626
        return this.equals((updateInventory_args)that);
5627
      return false;
5628
    }
5629
 
5630
    public boolean equals(updateInventory_args that) {
5631
      if (that == null)
5632
        return false;
5633
 
5634
      boolean this_present_warehouse_id = true;
5635
      boolean that_present_warehouse_id = true;
5636
      if (this_present_warehouse_id || that_present_warehouse_id) {
5637
        if (!(this_present_warehouse_id && that_present_warehouse_id))
5638
          return false;
5639
        if (this.warehouse_id != that.warehouse_id)
5640
          return false;
5641
      }
5642
 
5643
      boolean this_present_timestamp = true && this.isSetTimestamp();
5644
      boolean that_present_timestamp = true && that.isSetTimestamp();
5645
      if (this_present_timestamp || that_present_timestamp) {
5646
        if (!(this_present_timestamp && that_present_timestamp))
5647
          return false;
5648
        if (!this.timestamp.equals(that.timestamp))
5649
          return false;
5650
      }
5651
 
5652
      boolean this_present_availability = true && this.isSetAvailability();
5653
      boolean that_present_availability = true && that.isSetAvailability();
5654
      if (this_present_availability || that_present_availability) {
5655
        if (!(this_present_availability && that_present_availability))
5656
          return false;
5657
        if (!this.availability.equals(that.availability))
5658
          return false;
5659
      }
5660
 
5661
      return true;
5662
    }
5663
 
5664
    @Override
5665
    public int hashCode() {
5666
      return 0;
5667
    }
5668
 
5669
    public int compareTo(updateInventory_args other) {
5670
      if (!getClass().equals(other.getClass())) {
5671
        return getClass().getName().compareTo(other.getClass().getName());
5672
      }
5673
 
5674
      int lastComparison = 0;
5675
      updateInventory_args typedOther = (updateInventory_args)other;
5676
 
5677
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
5678
      if (lastComparison != 0) {
5679
        return lastComparison;
5680
      }
5681
      if (isSetWarehouse_id()) {
5682
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
5683
        if (lastComparison != 0) {
5684
          return lastComparison;
5685
        }
5686
      }
5687
      lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(typedOther.isSetTimestamp());
5688
      if (lastComparison != 0) {
5689
        return lastComparison;
5690
      }
5691
      if (isSetTimestamp()) {
5692
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.timestamp, typedOther.timestamp);
5693
        if (lastComparison != 0) {
5694
          return lastComparison;
5695
        }
5696
      }
5697
      lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(typedOther.isSetAvailability());
5698
      if (lastComparison != 0) {
5699
        return lastComparison;
5700
      }
5701
      if (isSetAvailability()) {
5702
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.availability, typedOther.availability);
5703
        if (lastComparison != 0) {
5704
          return lastComparison;
5705
        }
5706
      }
5707
      return 0;
5708
    }
5709
 
5710
    public _Fields fieldForId(int fieldId) {
5711
      return _Fields.findByThriftId(fieldId);
5712
    }
5713
 
5714
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5715
      org.apache.thrift.protocol.TField field;
5716
      iprot.readStructBegin();
5717
      while (true)
5718
      {
5719
        field = iprot.readFieldBegin();
5720
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5721
          break;
5722
        }
5723
        switch (field.id) {
5724
          case 1: // WAREHOUSE_ID
5725
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5726
              this.warehouse_id = iprot.readI64();
5727
              setWarehouse_idIsSet(true);
5728
            } else { 
5729
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5730
            }
5731
            break;
5732
          case 2: // TIMESTAMP
5733
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
5734
              this.timestamp = iprot.readString();
5735
            } else { 
5736
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5737
            }
5738
            break;
5739
          case 3: // AVAILABILITY
5740
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
5741
              {
5742
                org.apache.thrift.protocol.TMap _map15 = iprot.readMapBegin();
5743
                this.availability = new HashMap<String,Long>(2*_map15.size);
5744
                for (int _i16 = 0; _i16 < _map15.size; ++_i16)
5745
                {
5746
                  String _key17; // required
5747
                  long _val18; // required
5748
                  _key17 = iprot.readString();
5749
                  _val18 = iprot.readI64();
5750
                  this.availability.put(_key17, _val18);
5751
                }
5752
                iprot.readMapEnd();
5753
              }
5754
            } else { 
5755
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5756
            }
5757
            break;
5758
          default:
5759
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5760
        }
5761
        iprot.readFieldEnd();
5762
      }
5763
      iprot.readStructEnd();
5764
      validate();
5765
    }
5766
 
5767
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5768
      validate();
5769
 
5770
      oprot.writeStructBegin(STRUCT_DESC);
5771
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
5772
      oprot.writeI64(this.warehouse_id);
5773
      oprot.writeFieldEnd();
5774
      if (this.timestamp != null) {
5775
        oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
5776
        oprot.writeString(this.timestamp);
5777
        oprot.writeFieldEnd();
5778
      }
5779
      if (this.availability != null) {
5780
        oprot.writeFieldBegin(AVAILABILITY_FIELD_DESC);
5781
        {
5782
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.I64, this.availability.size()));
5783
          for (Map.Entry<String, Long> _iter19 : this.availability.entrySet())
5784
          {
5785
            oprot.writeString(_iter19.getKey());
5786
            oprot.writeI64(_iter19.getValue());
5787
          }
5788
          oprot.writeMapEnd();
5789
        }
5790
        oprot.writeFieldEnd();
5791
      }
5792
      oprot.writeFieldStop();
5793
      oprot.writeStructEnd();
5794
    }
5795
 
5796
    @Override
5797
    public String toString() {
5798
      StringBuilder sb = new StringBuilder("updateInventory_args(");
5799
      boolean first = true;
5800
 
5801
      sb.append("warehouse_id:");
5802
      sb.append(this.warehouse_id);
5803
      first = false;
5804
      if (!first) sb.append(", ");
5805
      sb.append("timestamp:");
5806
      if (this.timestamp == null) {
5807
        sb.append("null");
5808
      } else {
5809
        sb.append(this.timestamp);
5810
      }
5811
      first = false;
5812
      if (!first) sb.append(", ");
5813
      sb.append("availability:");
5814
      if (this.availability == null) {
5815
        sb.append("null");
5816
      } else {
5817
        sb.append(this.availability);
5818
      }
5819
      first = false;
5820
      sb.append(")");
5821
      return sb.toString();
5822
    }
5823
 
5824
    public void validate() throws org.apache.thrift.TException {
5825
      // check for required fields
5826
    }
5827
 
5828
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5829
      try {
5830
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5831
      } catch (org.apache.thrift.TException te) {
5832
        throw new java.io.IOException(te);
5833
      }
5834
    }
5835
 
5836
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5837
      try {
5838
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
5839
        __isset_bit_vector = new BitSet(1);
5840
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5841
      } catch (org.apache.thrift.TException te) {
5842
        throw new java.io.IOException(te);
5843
      }
5844
    }
5845
 
5846
  }
5847
 
5848
  public static class updateInventory_result implements org.apache.thrift.TBase<updateInventory_result, updateInventory_result._Fields>, java.io.Serializable, Cloneable   {
5849
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventory_result");
5850
 
5851
    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);
5852
 
5853
    private InventoryServiceException cex; // required
5854
 
5855
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5856
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5857
      CEX((short)1, "cex");
5858
 
5859
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5860
 
5861
      static {
5862
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5863
          byName.put(field.getFieldName(), field);
5864
        }
5865
      }
5866
 
5867
      /**
5868
       * Find the _Fields constant that matches fieldId, or null if its not found.
5869
       */
5870
      public static _Fields findByThriftId(int fieldId) {
5871
        switch(fieldId) {
5872
          case 1: // CEX
5873
            return CEX;
5874
          default:
5875
            return null;
5876
        }
5877
      }
5878
 
5879
      /**
5880
       * Find the _Fields constant that matches fieldId, throwing an exception
5881
       * if it is not found.
5882
       */
5883
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5884
        _Fields fields = findByThriftId(fieldId);
5885
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5886
        return fields;
5887
      }
5888
 
5889
      /**
5890
       * Find the _Fields constant that matches name, or null if its not found.
5891
       */
5892
      public static _Fields findByName(String name) {
5893
        return byName.get(name);
5894
      }
5895
 
5896
      private final short _thriftId;
5897
      private final String _fieldName;
5898
 
5899
      _Fields(short thriftId, String fieldName) {
5900
        _thriftId = thriftId;
5901
        _fieldName = fieldName;
5902
      }
5903
 
5904
      public short getThriftFieldId() {
5905
        return _thriftId;
5906
      }
5907
 
5908
      public String getFieldName() {
5909
        return _fieldName;
5910
      }
5911
    }
5912
 
5913
    // isset id assignments
5914
 
5915
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5916
    static {
5917
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5918
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5919
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5920
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5921
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventory_result.class, metaDataMap);
5922
    }
5923
 
5924
    public updateInventory_result() {
5925
    }
5926
 
5927
    public updateInventory_result(
5928
      InventoryServiceException cex)
5929
    {
5930
      this();
5931
      this.cex = cex;
5932
    }
5933
 
5934
    /**
5935
     * Performs a deep copy on <i>other</i>.
5936
     */
5937
    public updateInventory_result(updateInventory_result other) {
5938
      if (other.isSetCex()) {
5939
        this.cex = new InventoryServiceException(other.cex);
5940
      }
5941
    }
5942
 
5943
    public updateInventory_result deepCopy() {
5944
      return new updateInventory_result(this);
5945
    }
5946
 
5947
    @Override
5948
    public void clear() {
5949
      this.cex = null;
5950
    }
5951
 
5952
    public InventoryServiceException getCex() {
5953
      return this.cex;
5954
    }
5955
 
5956
    public void setCex(InventoryServiceException cex) {
5957
      this.cex = cex;
5958
    }
5959
 
5960
    public void unsetCex() {
5961
      this.cex = null;
5962
    }
5963
 
5964
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
5965
    public boolean isSetCex() {
5966
      return this.cex != null;
5967
    }
5968
 
5969
    public void setCexIsSet(boolean value) {
5970
      if (!value) {
5971
        this.cex = null;
5972
      }
5973
    }
5974
 
5975
    public void setFieldValue(_Fields field, Object value) {
5976
      switch (field) {
5977
      case CEX:
5978
        if (value == null) {
5979
          unsetCex();
5980
        } else {
5981
          setCex((InventoryServiceException)value);
5982
        }
5983
        break;
5984
 
5985
      }
5986
    }
5987
 
5988
    public Object getFieldValue(_Fields field) {
5989
      switch (field) {
5990
      case CEX:
5991
        return getCex();
5992
 
5993
      }
5994
      throw new IllegalStateException();
5995
    }
5996
 
5997
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5998
    public boolean isSet(_Fields field) {
5999
      if (field == null) {
6000
        throw new IllegalArgumentException();
6001
      }
6002
 
6003
      switch (field) {
6004
      case CEX:
6005
        return isSetCex();
6006
      }
6007
      throw new IllegalStateException();
6008
    }
6009
 
6010
    @Override
6011
    public boolean equals(Object that) {
6012
      if (that == null)
6013
        return false;
6014
      if (that instanceof updateInventory_result)
6015
        return this.equals((updateInventory_result)that);
6016
      return false;
6017
    }
6018
 
6019
    public boolean equals(updateInventory_result that) {
6020
      if (that == null)
6021
        return false;
6022
 
6023
      boolean this_present_cex = true && this.isSetCex();
6024
      boolean that_present_cex = true && that.isSetCex();
6025
      if (this_present_cex || that_present_cex) {
6026
        if (!(this_present_cex && that_present_cex))
6027
          return false;
6028
        if (!this.cex.equals(that.cex))
6029
          return false;
6030
      }
6031
 
6032
      return true;
6033
    }
6034
 
6035
    @Override
6036
    public int hashCode() {
6037
      return 0;
6038
    }
6039
 
6040
    public int compareTo(updateInventory_result other) {
6041
      if (!getClass().equals(other.getClass())) {
6042
        return getClass().getName().compareTo(other.getClass().getName());
6043
      }
6044
 
6045
      int lastComparison = 0;
6046
      updateInventory_result typedOther = (updateInventory_result)other;
6047
 
6048
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
6049
      if (lastComparison != 0) {
6050
        return lastComparison;
6051
      }
6052
      if (isSetCex()) {
6053
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
6054
        if (lastComparison != 0) {
6055
          return lastComparison;
6056
        }
6057
      }
6058
      return 0;
6059
    }
6060
 
6061
    public _Fields fieldForId(int fieldId) {
6062
      return _Fields.findByThriftId(fieldId);
6063
    }
6064
 
6065
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6066
      org.apache.thrift.protocol.TField field;
6067
      iprot.readStructBegin();
6068
      while (true)
6069
      {
6070
        field = iprot.readFieldBegin();
6071
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6072
          break;
6073
        }
6074
        switch (field.id) {
6075
          case 1: // CEX
6076
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6077
              this.cex = new InventoryServiceException();
6078
              this.cex.read(iprot);
6079
            } else { 
6080
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6081
            }
6082
            break;
6083
          default:
6084
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6085
        }
6086
        iprot.readFieldEnd();
6087
      }
6088
      iprot.readStructEnd();
6089
      validate();
6090
    }
6091
 
6092
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6093
      oprot.writeStructBegin(STRUCT_DESC);
6094
 
6095
      if (this.isSetCex()) {
6096
        oprot.writeFieldBegin(CEX_FIELD_DESC);
6097
        this.cex.write(oprot);
6098
        oprot.writeFieldEnd();
6099
      }
6100
      oprot.writeFieldStop();
6101
      oprot.writeStructEnd();
6102
    }
6103
 
6104
    @Override
6105
    public String toString() {
6106
      StringBuilder sb = new StringBuilder("updateInventory_result(");
6107
      boolean first = true;
6108
 
6109
      sb.append("cex:");
6110
      if (this.cex == null) {
6111
        sb.append("null");
6112
      } else {
6113
        sb.append(this.cex);
6114
      }
6115
      first = false;
6116
      sb.append(")");
6117
      return sb.toString();
6118
    }
6119
 
6120
    public void validate() throws org.apache.thrift.TException {
6121
      // check for required fields
6122
    }
6123
 
6124
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6125
      try {
6126
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6127
      } catch (org.apache.thrift.TException te) {
6128
        throw new java.io.IOException(te);
6129
      }
6130
    }
6131
 
6132
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6133
      try {
6134
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6135
      } catch (org.apache.thrift.TException te) {
6136
        throw new java.io.IOException(te);
6137
      }
6138
    }
6139
 
6140
  }
6141
 
6142
  public static class addInventory_args implements org.apache.thrift.TBase<addInventory_args, addInventory_args._Fields>, java.io.Serializable, Cloneable   {
6143
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addInventory_args");
6144
 
6145
    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);
6146
    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);
6147
    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);
6148
 
6149
    private long itemId; // required
6150
    private long warehouseId; // required
6151
    private long quantity; // required
6152
 
6153
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6154
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6155
      ITEM_ID((short)1, "itemId"),
6156
      WAREHOUSE_ID((short)2, "warehouseId"),
6157
      QUANTITY((short)3, "quantity");
6158
 
6159
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6160
 
6161
      static {
6162
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6163
          byName.put(field.getFieldName(), field);
6164
        }
6165
      }
6166
 
6167
      /**
6168
       * Find the _Fields constant that matches fieldId, or null if its not found.
6169
       */
6170
      public static _Fields findByThriftId(int fieldId) {
6171
        switch(fieldId) {
6172
          case 1: // ITEM_ID
6173
            return ITEM_ID;
6174
          case 2: // WAREHOUSE_ID
6175
            return WAREHOUSE_ID;
6176
          case 3: // QUANTITY
6177
            return QUANTITY;
6178
          default:
6179
            return null;
6180
        }
6181
      }
6182
 
6183
      /**
6184
       * Find the _Fields constant that matches fieldId, throwing an exception
6185
       * if it is not found.
6186
       */
6187
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6188
        _Fields fields = findByThriftId(fieldId);
6189
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6190
        return fields;
6191
      }
6192
 
6193
      /**
6194
       * Find the _Fields constant that matches name, or null if its not found.
6195
       */
6196
      public static _Fields findByName(String name) {
6197
        return byName.get(name);
6198
      }
6199
 
6200
      private final short _thriftId;
6201
      private final String _fieldName;
6202
 
6203
      _Fields(short thriftId, String fieldName) {
6204
        _thriftId = thriftId;
6205
        _fieldName = fieldName;
6206
      }
6207
 
6208
      public short getThriftFieldId() {
6209
        return _thriftId;
6210
      }
6211
 
6212
      public String getFieldName() {
6213
        return _fieldName;
6214
      }
6215
    }
6216
 
6217
    // isset id assignments
6218
    private static final int __ITEMID_ISSET_ID = 0;
6219
    private static final int __WAREHOUSEID_ISSET_ID = 1;
6220
    private static final int __QUANTITY_ISSET_ID = 2;
6221
    private BitSet __isset_bit_vector = new BitSet(3);
6222
 
6223
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6224
    static {
6225
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6226
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6227
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6228
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6229
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6230
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6231
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6232
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6233
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addInventory_args.class, metaDataMap);
6234
    }
6235
 
6236
    public addInventory_args() {
6237
    }
6238
 
6239
    public addInventory_args(
6240
      long itemId,
6241
      long warehouseId,
6242
      long quantity)
6243
    {
6244
      this();
6245
      this.itemId = itemId;
6246
      setItemIdIsSet(true);
6247
      this.warehouseId = warehouseId;
6248
      setWarehouseIdIsSet(true);
6249
      this.quantity = quantity;
6250
      setQuantityIsSet(true);
6251
    }
6252
 
6253
    /**
6254
     * Performs a deep copy on <i>other</i>.
6255
     */
6256
    public addInventory_args(addInventory_args other) {
6257
      __isset_bit_vector.clear();
6258
      __isset_bit_vector.or(other.__isset_bit_vector);
6259
      this.itemId = other.itemId;
6260
      this.warehouseId = other.warehouseId;
6261
      this.quantity = other.quantity;
6262
    }
6263
 
6264
    public addInventory_args deepCopy() {
6265
      return new addInventory_args(this);
6266
    }
6267
 
6268
    @Override
6269
    public void clear() {
6270
      setItemIdIsSet(false);
6271
      this.itemId = 0;
6272
      setWarehouseIdIsSet(false);
6273
      this.warehouseId = 0;
6274
      setQuantityIsSet(false);
6275
      this.quantity = 0;
6276
    }
6277
 
6278
    public long getItemId() {
6279
      return this.itemId;
6280
    }
6281
 
6282
    public void setItemId(long itemId) {
6283
      this.itemId = itemId;
6284
      setItemIdIsSet(true);
6285
    }
6286
 
6287
    public void unsetItemId() {
6288
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
6289
    }
6290
 
6291
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
6292
    public boolean isSetItemId() {
6293
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
6294
    }
6295
 
6296
    public void setItemIdIsSet(boolean value) {
6297
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
6298
    }
6299
 
6300
    public long getWarehouseId() {
6301
      return this.warehouseId;
6302
    }
6303
 
6304
    public void setWarehouseId(long warehouseId) {
6305
      this.warehouseId = warehouseId;
6306
      setWarehouseIdIsSet(true);
6307
    }
6308
 
6309
    public void unsetWarehouseId() {
6310
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
6311
    }
6312
 
6313
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
6314
    public boolean isSetWarehouseId() {
6315
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
6316
    }
6317
 
6318
    public void setWarehouseIdIsSet(boolean value) {
6319
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
6320
    }
6321
 
6322
    public long getQuantity() {
6323
      return this.quantity;
6324
    }
6325
 
6326
    public void setQuantity(long quantity) {
6327
      this.quantity = quantity;
6328
      setQuantityIsSet(true);
6329
    }
6330
 
6331
    public void unsetQuantity() {
6332
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
6333
    }
6334
 
6335
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
6336
    public boolean isSetQuantity() {
6337
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
6338
    }
6339
 
6340
    public void setQuantityIsSet(boolean value) {
6341
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
6342
    }
6343
 
6344
    public void setFieldValue(_Fields field, Object value) {
6345
      switch (field) {
6346
      case ITEM_ID:
6347
        if (value == null) {
6348
          unsetItemId();
6349
        } else {
6350
          setItemId((Long)value);
6351
        }
6352
        break;
6353
 
6354
      case WAREHOUSE_ID:
6355
        if (value == null) {
6356
          unsetWarehouseId();
6357
        } else {
6358
          setWarehouseId((Long)value);
6359
        }
6360
        break;
6361
 
6362
      case QUANTITY:
6363
        if (value == null) {
6364
          unsetQuantity();
6365
        } else {
6366
          setQuantity((Long)value);
6367
        }
6368
        break;
6369
 
6370
      }
6371
    }
6372
 
6373
    public Object getFieldValue(_Fields field) {
6374
      switch (field) {
6375
      case ITEM_ID:
6376
        return Long.valueOf(getItemId());
6377
 
6378
      case WAREHOUSE_ID:
6379
        return Long.valueOf(getWarehouseId());
6380
 
6381
      case QUANTITY:
6382
        return Long.valueOf(getQuantity());
6383
 
6384
      }
6385
      throw new IllegalStateException();
6386
    }
6387
 
6388
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6389
    public boolean isSet(_Fields field) {
6390
      if (field == null) {
6391
        throw new IllegalArgumentException();
6392
      }
6393
 
6394
      switch (field) {
6395
      case ITEM_ID:
6396
        return isSetItemId();
6397
      case WAREHOUSE_ID:
6398
        return isSetWarehouseId();
6399
      case QUANTITY:
6400
        return isSetQuantity();
6401
      }
6402
      throw new IllegalStateException();
6403
    }
6404
 
6405
    @Override
6406
    public boolean equals(Object that) {
6407
      if (that == null)
6408
        return false;
6409
      if (that instanceof addInventory_args)
6410
        return this.equals((addInventory_args)that);
6411
      return false;
6412
    }
6413
 
6414
    public boolean equals(addInventory_args that) {
6415
      if (that == null)
6416
        return false;
6417
 
6418
      boolean this_present_itemId = true;
6419
      boolean that_present_itemId = true;
6420
      if (this_present_itemId || that_present_itemId) {
6421
        if (!(this_present_itemId && that_present_itemId))
6422
          return false;
6423
        if (this.itemId != that.itemId)
6424
          return false;
6425
      }
6426
 
6427
      boolean this_present_warehouseId = true;
6428
      boolean that_present_warehouseId = true;
6429
      if (this_present_warehouseId || that_present_warehouseId) {
6430
        if (!(this_present_warehouseId && that_present_warehouseId))
6431
          return false;
6432
        if (this.warehouseId != that.warehouseId)
6433
          return false;
6434
      }
6435
 
6436
      boolean this_present_quantity = true;
6437
      boolean that_present_quantity = true;
6438
      if (this_present_quantity || that_present_quantity) {
6439
        if (!(this_present_quantity && that_present_quantity))
6440
          return false;
6441
        if (this.quantity != that.quantity)
6442
          return false;
6443
      }
6444
 
6445
      return true;
6446
    }
6447
 
6448
    @Override
6449
    public int hashCode() {
6450
      return 0;
6451
    }
6452
 
6453
    public int compareTo(addInventory_args other) {
6454
      if (!getClass().equals(other.getClass())) {
6455
        return getClass().getName().compareTo(other.getClass().getName());
6456
      }
6457
 
6458
      int lastComparison = 0;
6459
      addInventory_args typedOther = (addInventory_args)other;
6460
 
6461
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
6462
      if (lastComparison != 0) {
6463
        return lastComparison;
6464
      }
6465
      if (isSetItemId()) {
6466
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
6467
        if (lastComparison != 0) {
6468
          return lastComparison;
6469
        }
6470
      }
6471
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
6472
      if (lastComparison != 0) {
6473
        return lastComparison;
6474
      }
6475
      if (isSetWarehouseId()) {
6476
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
6477
        if (lastComparison != 0) {
6478
          return lastComparison;
6479
        }
6480
      }
6481
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
6482
      if (lastComparison != 0) {
6483
        return lastComparison;
6484
      }
6485
      if (isSetQuantity()) {
6486
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
6487
        if (lastComparison != 0) {
6488
          return lastComparison;
6489
        }
6490
      }
6491
      return 0;
6492
    }
6493
 
6494
    public _Fields fieldForId(int fieldId) {
6495
      return _Fields.findByThriftId(fieldId);
6496
    }
6497
 
6498
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6499
      org.apache.thrift.protocol.TField field;
6500
      iprot.readStructBegin();
6501
      while (true)
6502
      {
6503
        field = iprot.readFieldBegin();
6504
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6505
          break;
6506
        }
6507
        switch (field.id) {
6508
          case 1: // ITEM_ID
6509
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6510
              this.itemId = iprot.readI64();
6511
              setItemIdIsSet(true);
6512
            } else { 
6513
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6514
            }
6515
            break;
6516
          case 2: // WAREHOUSE_ID
6517
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6518
              this.warehouseId = iprot.readI64();
6519
              setWarehouseIdIsSet(true);
6520
            } else { 
6521
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6522
            }
6523
            break;
6524
          case 3: // QUANTITY
6525
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6526
              this.quantity = iprot.readI64();
6527
              setQuantityIsSet(true);
6528
            } else { 
6529
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6530
            }
6531
            break;
6532
          default:
6533
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6534
        }
6535
        iprot.readFieldEnd();
6536
      }
6537
      iprot.readStructEnd();
6538
      validate();
6539
    }
6540
 
6541
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6542
      validate();
6543
 
6544
      oprot.writeStructBegin(STRUCT_DESC);
6545
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
6546
      oprot.writeI64(this.itemId);
6547
      oprot.writeFieldEnd();
6548
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
6549
      oprot.writeI64(this.warehouseId);
6550
      oprot.writeFieldEnd();
6551
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
6552
      oprot.writeI64(this.quantity);
6553
      oprot.writeFieldEnd();
6554
      oprot.writeFieldStop();
6555
      oprot.writeStructEnd();
6556
    }
6557
 
6558
    @Override
6559
    public String toString() {
6560
      StringBuilder sb = new StringBuilder("addInventory_args(");
6561
      boolean first = true;
6562
 
6563
      sb.append("itemId:");
6564
      sb.append(this.itemId);
6565
      first = false;
6566
      if (!first) sb.append(", ");
6567
      sb.append("warehouseId:");
6568
      sb.append(this.warehouseId);
6569
      first = false;
6570
      if (!first) sb.append(", ");
6571
      sb.append("quantity:");
6572
      sb.append(this.quantity);
6573
      first = false;
6574
      sb.append(")");
6575
      return sb.toString();
6576
    }
6577
 
6578
    public void validate() throws org.apache.thrift.TException {
6579
      // check for required fields
6580
    }
6581
 
6582
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6583
      try {
6584
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6585
      } catch (org.apache.thrift.TException te) {
6586
        throw new java.io.IOException(te);
6587
      }
6588
    }
6589
 
6590
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6591
      try {
6592
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
6593
        __isset_bit_vector = new BitSet(1);
6594
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6595
      } catch (org.apache.thrift.TException te) {
6596
        throw new java.io.IOException(te);
6597
      }
6598
    }
6599
 
6600
  }
6601
 
6602
  public static class addInventory_result implements org.apache.thrift.TBase<addInventory_result, addInventory_result._Fields>, java.io.Serializable, Cloneable   {
6603
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addInventory_result");
6604
 
6605
    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);
6606
 
6607
    private InventoryServiceException cex; // required
6608
 
6609
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6610
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6611
      CEX((short)1, "cex");
6612
 
6613
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6614
 
6615
      static {
6616
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6617
          byName.put(field.getFieldName(), field);
6618
        }
6619
      }
6620
 
6621
      /**
6622
       * Find the _Fields constant that matches fieldId, or null if its not found.
6623
       */
6624
      public static _Fields findByThriftId(int fieldId) {
6625
        switch(fieldId) {
6626
          case 1: // CEX
6627
            return CEX;
6628
          default:
6629
            return null;
6630
        }
6631
      }
6632
 
6633
      /**
6634
       * Find the _Fields constant that matches fieldId, throwing an exception
6635
       * if it is not found.
6636
       */
6637
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6638
        _Fields fields = findByThriftId(fieldId);
6639
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6640
        return fields;
6641
      }
6642
 
6643
      /**
6644
       * Find the _Fields constant that matches name, or null if its not found.
6645
       */
6646
      public static _Fields findByName(String name) {
6647
        return byName.get(name);
6648
      }
6649
 
6650
      private final short _thriftId;
6651
      private final String _fieldName;
6652
 
6653
      _Fields(short thriftId, String fieldName) {
6654
        _thriftId = thriftId;
6655
        _fieldName = fieldName;
6656
      }
6657
 
6658
      public short getThriftFieldId() {
6659
        return _thriftId;
6660
      }
6661
 
6662
      public String getFieldName() {
6663
        return _fieldName;
6664
      }
6665
    }
6666
 
6667
    // isset id assignments
6668
 
6669
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6670
    static {
6671
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6672
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6673
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6674
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6675
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addInventory_result.class, metaDataMap);
6676
    }
6677
 
6678
    public addInventory_result() {
6679
    }
6680
 
6681
    public addInventory_result(
6682
      InventoryServiceException cex)
6683
    {
6684
      this();
6685
      this.cex = cex;
6686
    }
6687
 
6688
    /**
6689
     * Performs a deep copy on <i>other</i>.
6690
     */
6691
    public addInventory_result(addInventory_result other) {
6692
      if (other.isSetCex()) {
6693
        this.cex = new InventoryServiceException(other.cex);
6694
      }
6695
    }
6696
 
6697
    public addInventory_result deepCopy() {
6698
      return new addInventory_result(this);
6699
    }
6700
 
6701
    @Override
6702
    public void clear() {
6703
      this.cex = null;
6704
    }
6705
 
6706
    public InventoryServiceException getCex() {
6707
      return this.cex;
6708
    }
6709
 
6710
    public void setCex(InventoryServiceException cex) {
6711
      this.cex = cex;
6712
    }
6713
 
6714
    public void unsetCex() {
6715
      this.cex = null;
6716
    }
6717
 
6718
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
6719
    public boolean isSetCex() {
6720
      return this.cex != null;
6721
    }
6722
 
6723
    public void setCexIsSet(boolean value) {
6724
      if (!value) {
6725
        this.cex = null;
6726
      }
6727
    }
6728
 
6729
    public void setFieldValue(_Fields field, Object value) {
6730
      switch (field) {
6731
      case CEX:
6732
        if (value == null) {
6733
          unsetCex();
6734
        } else {
6735
          setCex((InventoryServiceException)value);
6736
        }
6737
        break;
6738
 
6739
      }
6740
    }
6741
 
6742
    public Object getFieldValue(_Fields field) {
6743
      switch (field) {
6744
      case CEX:
6745
        return getCex();
6746
 
6747
      }
6748
      throw new IllegalStateException();
6749
    }
6750
 
6751
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6752
    public boolean isSet(_Fields field) {
6753
      if (field == null) {
6754
        throw new IllegalArgumentException();
6755
      }
6756
 
6757
      switch (field) {
6758
      case CEX:
6759
        return isSetCex();
6760
      }
6761
      throw new IllegalStateException();
6762
    }
6763
 
6764
    @Override
6765
    public boolean equals(Object that) {
6766
      if (that == null)
6767
        return false;
6768
      if (that instanceof addInventory_result)
6769
        return this.equals((addInventory_result)that);
6770
      return false;
6771
    }
6772
 
6773
    public boolean equals(addInventory_result that) {
6774
      if (that == null)
6775
        return false;
6776
 
6777
      boolean this_present_cex = true && this.isSetCex();
6778
      boolean that_present_cex = true && that.isSetCex();
6779
      if (this_present_cex || that_present_cex) {
6780
        if (!(this_present_cex && that_present_cex))
6781
          return false;
6782
        if (!this.cex.equals(that.cex))
6783
          return false;
6784
      }
6785
 
6786
      return true;
6787
    }
6788
 
6789
    @Override
6790
    public int hashCode() {
6791
      return 0;
6792
    }
6793
 
6794
    public int compareTo(addInventory_result other) {
6795
      if (!getClass().equals(other.getClass())) {
6796
        return getClass().getName().compareTo(other.getClass().getName());
6797
      }
6798
 
6799
      int lastComparison = 0;
6800
      addInventory_result typedOther = (addInventory_result)other;
6801
 
6802
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
6803
      if (lastComparison != 0) {
6804
        return lastComparison;
6805
      }
6806
      if (isSetCex()) {
6807
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
6808
        if (lastComparison != 0) {
6809
          return lastComparison;
6810
        }
6811
      }
6812
      return 0;
6813
    }
6814
 
6815
    public _Fields fieldForId(int fieldId) {
6816
      return _Fields.findByThriftId(fieldId);
6817
    }
6818
 
6819
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6820
      org.apache.thrift.protocol.TField field;
6821
      iprot.readStructBegin();
6822
      while (true)
6823
      {
6824
        field = iprot.readFieldBegin();
6825
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6826
          break;
6827
        }
6828
        switch (field.id) {
6829
          case 1: // CEX
6830
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6831
              this.cex = new InventoryServiceException();
6832
              this.cex.read(iprot);
6833
            } else { 
6834
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6835
            }
6836
            break;
6837
          default:
6838
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6839
        }
6840
        iprot.readFieldEnd();
6841
      }
6842
      iprot.readStructEnd();
6843
      validate();
6844
    }
6845
 
6846
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6847
      oprot.writeStructBegin(STRUCT_DESC);
6848
 
6849
      if (this.isSetCex()) {
6850
        oprot.writeFieldBegin(CEX_FIELD_DESC);
6851
        this.cex.write(oprot);
6852
        oprot.writeFieldEnd();
6853
      }
6854
      oprot.writeFieldStop();
6855
      oprot.writeStructEnd();
6856
    }
6857
 
6858
    @Override
6859
    public String toString() {
6860
      StringBuilder sb = new StringBuilder("addInventory_result(");
6861
      boolean first = true;
6862
 
6863
      sb.append("cex:");
6864
      if (this.cex == null) {
6865
        sb.append("null");
6866
      } else {
6867
        sb.append(this.cex);
6868
      }
6869
      first = false;
6870
      sb.append(")");
6871
      return sb.toString();
6872
    }
6873
 
6874
    public void validate() throws org.apache.thrift.TException {
6875
      // check for required fields
6876
    }
6877
 
6878
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6879
      try {
6880
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6881
      } catch (org.apache.thrift.TException te) {
6882
        throw new java.io.IOException(te);
6883
      }
6884
    }
6885
 
6886
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6887
      try {
6888
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6889
      } catch (org.apache.thrift.TException te) {
6890
        throw new java.io.IOException(te);
6891
      }
6892
    }
6893
 
6894
  }
6895
 
6896
  public static class retireWarehouse_args implements org.apache.thrift.TBase<retireWarehouse_args, retireWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
6897
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("retireWarehouse_args");
6898
 
6899
    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);
6900
 
6901
    private long warehouse_id; // required
6902
 
6903
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6904
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6905
      WAREHOUSE_ID((short)1, "warehouse_id");
6906
 
6907
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6908
 
6909
      static {
6910
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6911
          byName.put(field.getFieldName(), field);
6912
        }
6913
      }
6914
 
6915
      /**
6916
       * Find the _Fields constant that matches fieldId, or null if its not found.
6917
       */
6918
      public static _Fields findByThriftId(int fieldId) {
6919
        switch(fieldId) {
6920
          case 1: // WAREHOUSE_ID
6921
            return WAREHOUSE_ID;
6922
          default:
6923
            return null;
6924
        }
6925
      }
6926
 
6927
      /**
6928
       * Find the _Fields constant that matches fieldId, throwing an exception
6929
       * if it is not found.
6930
       */
6931
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6932
        _Fields fields = findByThriftId(fieldId);
6933
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6934
        return fields;
6935
      }
6936
 
6937
      /**
6938
       * Find the _Fields constant that matches name, or null if its not found.
6939
       */
6940
      public static _Fields findByName(String name) {
6941
        return byName.get(name);
6942
      }
6943
 
6944
      private final short _thriftId;
6945
      private final String _fieldName;
6946
 
6947
      _Fields(short thriftId, String fieldName) {
6948
        _thriftId = thriftId;
6949
        _fieldName = fieldName;
6950
      }
6951
 
6952
      public short getThriftFieldId() {
6953
        return _thriftId;
6954
      }
6955
 
6956
      public String getFieldName() {
6957
        return _fieldName;
6958
      }
6959
    }
6960
 
6961
    // isset id assignments
6962
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
6963
    private BitSet __isset_bit_vector = new BitSet(1);
6964
 
6965
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6966
    static {
6967
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6968
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6969
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6970
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6971
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(retireWarehouse_args.class, metaDataMap);
6972
    }
6973
 
6974
    public retireWarehouse_args() {
6975
    }
6976
 
6977
    public retireWarehouse_args(
6978
      long warehouse_id)
6979
    {
6980
      this();
6981
      this.warehouse_id = warehouse_id;
6982
      setWarehouse_idIsSet(true);
6983
    }
6984
 
6985
    /**
6986
     * Performs a deep copy on <i>other</i>.
6987
     */
6988
    public retireWarehouse_args(retireWarehouse_args other) {
6989
      __isset_bit_vector.clear();
6990
      __isset_bit_vector.or(other.__isset_bit_vector);
6991
      this.warehouse_id = other.warehouse_id;
6992
    }
6993
 
6994
    public retireWarehouse_args deepCopy() {
6995
      return new retireWarehouse_args(this);
6996
    }
6997
 
6998
    @Override
6999
    public void clear() {
7000
      setWarehouse_idIsSet(false);
7001
      this.warehouse_id = 0;
7002
    }
7003
 
7004
    public long getWarehouse_id() {
7005
      return this.warehouse_id;
7006
    }
7007
 
7008
    public void setWarehouse_id(long warehouse_id) {
7009
      this.warehouse_id = warehouse_id;
7010
      setWarehouse_idIsSet(true);
7011
    }
7012
 
7013
    public void unsetWarehouse_id() {
7014
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
7015
    }
7016
 
7017
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
7018
    public boolean isSetWarehouse_id() {
7019
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
7020
    }
7021
 
7022
    public void setWarehouse_idIsSet(boolean value) {
7023
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
7024
    }
7025
 
7026
    public void setFieldValue(_Fields field, Object value) {
7027
      switch (field) {
7028
      case WAREHOUSE_ID:
7029
        if (value == null) {
7030
          unsetWarehouse_id();
7031
        } else {
7032
          setWarehouse_id((Long)value);
7033
        }
7034
        break;
7035
 
7036
      }
7037
    }
7038
 
7039
    public Object getFieldValue(_Fields field) {
7040
      switch (field) {
7041
      case WAREHOUSE_ID:
7042
        return Long.valueOf(getWarehouse_id());
7043
 
7044
      }
7045
      throw new IllegalStateException();
7046
    }
7047
 
7048
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7049
    public boolean isSet(_Fields field) {
7050
      if (field == null) {
7051
        throw new IllegalArgumentException();
7052
      }
7053
 
7054
      switch (field) {
7055
      case WAREHOUSE_ID:
7056
        return isSetWarehouse_id();
7057
      }
7058
      throw new IllegalStateException();
7059
    }
7060
 
7061
    @Override
7062
    public boolean equals(Object that) {
7063
      if (that == null)
7064
        return false;
7065
      if (that instanceof retireWarehouse_args)
7066
        return this.equals((retireWarehouse_args)that);
7067
      return false;
7068
    }
7069
 
7070
    public boolean equals(retireWarehouse_args that) {
7071
      if (that == null)
7072
        return false;
7073
 
7074
      boolean this_present_warehouse_id = true;
7075
      boolean that_present_warehouse_id = true;
7076
      if (this_present_warehouse_id || that_present_warehouse_id) {
7077
        if (!(this_present_warehouse_id && that_present_warehouse_id))
7078
          return false;
7079
        if (this.warehouse_id != that.warehouse_id)
7080
          return false;
7081
      }
7082
 
7083
      return true;
7084
    }
7085
 
7086
    @Override
7087
    public int hashCode() {
7088
      return 0;
7089
    }
7090
 
7091
    public int compareTo(retireWarehouse_args other) {
7092
      if (!getClass().equals(other.getClass())) {
7093
        return getClass().getName().compareTo(other.getClass().getName());
7094
      }
7095
 
7096
      int lastComparison = 0;
7097
      retireWarehouse_args typedOther = (retireWarehouse_args)other;
7098
 
7099
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
7100
      if (lastComparison != 0) {
7101
        return lastComparison;
7102
      }
7103
      if (isSetWarehouse_id()) {
7104
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
7105
        if (lastComparison != 0) {
7106
          return lastComparison;
7107
        }
7108
      }
7109
      return 0;
7110
    }
7111
 
7112
    public _Fields fieldForId(int fieldId) {
7113
      return _Fields.findByThriftId(fieldId);
7114
    }
7115
 
7116
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7117
      org.apache.thrift.protocol.TField field;
7118
      iprot.readStructBegin();
7119
      while (true)
7120
      {
7121
        field = iprot.readFieldBegin();
7122
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7123
          break;
7124
        }
7125
        switch (field.id) {
7126
          case 1: // WAREHOUSE_ID
7127
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7128
              this.warehouse_id = iprot.readI64();
7129
              setWarehouse_idIsSet(true);
7130
            } else { 
7131
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7132
            }
7133
            break;
7134
          default:
7135
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7136
        }
7137
        iprot.readFieldEnd();
7138
      }
7139
      iprot.readStructEnd();
7140
      validate();
7141
    }
7142
 
7143
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7144
      validate();
7145
 
7146
      oprot.writeStructBegin(STRUCT_DESC);
7147
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
7148
      oprot.writeI64(this.warehouse_id);
7149
      oprot.writeFieldEnd();
7150
      oprot.writeFieldStop();
7151
      oprot.writeStructEnd();
7152
    }
7153
 
7154
    @Override
7155
    public String toString() {
7156
      StringBuilder sb = new StringBuilder("retireWarehouse_args(");
7157
      boolean first = true;
7158
 
7159
      sb.append("warehouse_id:");
7160
      sb.append(this.warehouse_id);
7161
      first = false;
7162
      sb.append(")");
7163
      return sb.toString();
7164
    }
7165
 
7166
    public void validate() throws org.apache.thrift.TException {
7167
      // check for required fields
7168
    }
7169
 
7170
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7171
      try {
7172
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7173
      } catch (org.apache.thrift.TException te) {
7174
        throw new java.io.IOException(te);
7175
      }
7176
    }
7177
 
7178
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7179
      try {
7180
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7181
        __isset_bit_vector = new BitSet(1);
7182
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7183
      } catch (org.apache.thrift.TException te) {
7184
        throw new java.io.IOException(te);
7185
      }
7186
    }
7187
 
7188
  }
7189
 
7190
  public static class retireWarehouse_result implements org.apache.thrift.TBase<retireWarehouse_result, retireWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
7191
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("retireWarehouse_result");
7192
 
7193
    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);
7194
 
7195
    private InventoryServiceException cex; // required
7196
 
7197
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7198
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7199
      CEX((short)1, "cex");
7200
 
7201
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7202
 
7203
      static {
7204
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7205
          byName.put(field.getFieldName(), field);
7206
        }
7207
      }
7208
 
7209
      /**
7210
       * Find the _Fields constant that matches fieldId, or null if its not found.
7211
       */
7212
      public static _Fields findByThriftId(int fieldId) {
7213
        switch(fieldId) {
7214
          case 1: // CEX
7215
            return CEX;
7216
          default:
7217
            return null;
7218
        }
7219
      }
7220
 
7221
      /**
7222
       * Find the _Fields constant that matches fieldId, throwing an exception
7223
       * if it is not found.
7224
       */
7225
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7226
        _Fields fields = findByThriftId(fieldId);
7227
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7228
        return fields;
7229
      }
7230
 
7231
      /**
7232
       * Find the _Fields constant that matches name, or null if its not found.
7233
       */
7234
      public static _Fields findByName(String name) {
7235
        return byName.get(name);
7236
      }
7237
 
7238
      private final short _thriftId;
7239
      private final String _fieldName;
7240
 
7241
      _Fields(short thriftId, String fieldName) {
7242
        _thriftId = thriftId;
7243
        _fieldName = fieldName;
7244
      }
7245
 
7246
      public short getThriftFieldId() {
7247
        return _thriftId;
7248
      }
7249
 
7250
      public String getFieldName() {
7251
        return _fieldName;
7252
      }
7253
    }
7254
 
7255
    // isset id assignments
7256
 
7257
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7258
    static {
7259
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7260
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7261
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7262
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7263
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(retireWarehouse_result.class, metaDataMap);
7264
    }
7265
 
7266
    public retireWarehouse_result() {
7267
    }
7268
 
7269
    public retireWarehouse_result(
7270
      InventoryServiceException cex)
7271
    {
7272
      this();
7273
      this.cex = cex;
7274
    }
7275
 
7276
    /**
7277
     * Performs a deep copy on <i>other</i>.
7278
     */
7279
    public retireWarehouse_result(retireWarehouse_result other) {
7280
      if (other.isSetCex()) {
7281
        this.cex = new InventoryServiceException(other.cex);
7282
      }
7283
    }
7284
 
7285
    public retireWarehouse_result deepCopy() {
7286
      return new retireWarehouse_result(this);
7287
    }
7288
 
7289
    @Override
7290
    public void clear() {
7291
      this.cex = null;
7292
    }
7293
 
7294
    public InventoryServiceException getCex() {
7295
      return this.cex;
7296
    }
7297
 
7298
    public void setCex(InventoryServiceException cex) {
7299
      this.cex = cex;
7300
    }
7301
 
7302
    public void unsetCex() {
7303
      this.cex = null;
7304
    }
7305
 
7306
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
7307
    public boolean isSetCex() {
7308
      return this.cex != null;
7309
    }
7310
 
7311
    public void setCexIsSet(boolean value) {
7312
      if (!value) {
7313
        this.cex = null;
7314
      }
7315
    }
7316
 
7317
    public void setFieldValue(_Fields field, Object value) {
7318
      switch (field) {
7319
      case CEX:
7320
        if (value == null) {
7321
          unsetCex();
7322
        } else {
7323
          setCex((InventoryServiceException)value);
7324
        }
7325
        break;
7326
 
7327
      }
7328
    }
7329
 
7330
    public Object getFieldValue(_Fields field) {
7331
      switch (field) {
7332
      case CEX:
7333
        return getCex();
7334
 
7335
      }
7336
      throw new IllegalStateException();
7337
    }
7338
 
7339
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7340
    public boolean isSet(_Fields field) {
7341
      if (field == null) {
7342
        throw new IllegalArgumentException();
7343
      }
7344
 
7345
      switch (field) {
7346
      case CEX:
7347
        return isSetCex();
7348
      }
7349
      throw new IllegalStateException();
7350
    }
7351
 
7352
    @Override
7353
    public boolean equals(Object that) {
7354
      if (that == null)
7355
        return false;
7356
      if (that instanceof retireWarehouse_result)
7357
        return this.equals((retireWarehouse_result)that);
7358
      return false;
7359
    }
7360
 
7361
    public boolean equals(retireWarehouse_result that) {
7362
      if (that == null)
7363
        return false;
7364
 
7365
      boolean this_present_cex = true && this.isSetCex();
7366
      boolean that_present_cex = true && that.isSetCex();
7367
      if (this_present_cex || that_present_cex) {
7368
        if (!(this_present_cex && that_present_cex))
7369
          return false;
7370
        if (!this.cex.equals(that.cex))
7371
          return false;
7372
      }
7373
 
7374
      return true;
7375
    }
7376
 
7377
    @Override
7378
    public int hashCode() {
7379
      return 0;
7380
    }
7381
 
7382
    public int compareTo(retireWarehouse_result other) {
7383
      if (!getClass().equals(other.getClass())) {
7384
        return getClass().getName().compareTo(other.getClass().getName());
7385
      }
7386
 
7387
      int lastComparison = 0;
7388
      retireWarehouse_result typedOther = (retireWarehouse_result)other;
7389
 
7390
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
7391
      if (lastComparison != 0) {
7392
        return lastComparison;
7393
      }
7394
      if (isSetCex()) {
7395
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
7396
        if (lastComparison != 0) {
7397
          return lastComparison;
7398
        }
7399
      }
7400
      return 0;
7401
    }
7402
 
7403
    public _Fields fieldForId(int fieldId) {
7404
      return _Fields.findByThriftId(fieldId);
7405
    }
7406
 
7407
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7408
      org.apache.thrift.protocol.TField field;
7409
      iprot.readStructBegin();
7410
      while (true)
7411
      {
7412
        field = iprot.readFieldBegin();
7413
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7414
          break;
7415
        }
7416
        switch (field.id) {
7417
          case 1: // CEX
7418
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7419
              this.cex = new InventoryServiceException();
7420
              this.cex.read(iprot);
7421
            } else { 
7422
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7423
            }
7424
            break;
7425
          default:
7426
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7427
        }
7428
        iprot.readFieldEnd();
7429
      }
7430
      iprot.readStructEnd();
7431
      validate();
7432
    }
7433
 
7434
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7435
      oprot.writeStructBegin(STRUCT_DESC);
7436
 
7437
      if (this.isSetCex()) {
7438
        oprot.writeFieldBegin(CEX_FIELD_DESC);
7439
        this.cex.write(oprot);
7440
        oprot.writeFieldEnd();
7441
      }
7442
      oprot.writeFieldStop();
7443
      oprot.writeStructEnd();
7444
    }
7445
 
7446
    @Override
7447
    public String toString() {
7448
      StringBuilder sb = new StringBuilder("retireWarehouse_result(");
7449
      boolean first = true;
7450
 
7451
      sb.append("cex:");
7452
      if (this.cex == null) {
7453
        sb.append("null");
7454
      } else {
7455
        sb.append(this.cex);
7456
      }
7457
      first = false;
7458
      sb.append(")");
7459
      return sb.toString();
7460
    }
7461
 
7462
    public void validate() throws org.apache.thrift.TException {
7463
      // check for required fields
7464
    }
7465
 
7466
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7467
      try {
7468
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7469
      } catch (org.apache.thrift.TException te) {
7470
        throw new java.io.IOException(te);
7471
      }
7472
    }
7473
 
7474
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7475
      try {
7476
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7477
      } catch (org.apache.thrift.TException te) {
7478
        throw new java.io.IOException(te);
7479
      }
7480
    }
7481
 
7482
  }
7483
 
7484
  public static class getItemInventoryByItemId_args implements org.apache.thrift.TBase<getItemInventoryByItemId_args, getItemInventoryByItemId_args._Fields>, java.io.Serializable, Cloneable   {
7485
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemInventoryByItemId_args");
7486
 
7487
    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);
7488
 
7489
    private long item_id; // required
7490
 
7491
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7492
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7493
      ITEM_ID((short)1, "item_id");
7494
 
7495
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7496
 
7497
      static {
7498
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7499
          byName.put(field.getFieldName(), field);
7500
        }
7501
      }
7502
 
7503
      /**
7504
       * Find the _Fields constant that matches fieldId, or null if its not found.
7505
       */
7506
      public static _Fields findByThriftId(int fieldId) {
7507
        switch(fieldId) {
7508
          case 1: // ITEM_ID
7509
            return ITEM_ID;
7510
          default:
7511
            return null;
7512
        }
7513
      }
7514
 
7515
      /**
7516
       * Find the _Fields constant that matches fieldId, throwing an exception
7517
       * if it is not found.
7518
       */
7519
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7520
        _Fields fields = findByThriftId(fieldId);
7521
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7522
        return fields;
7523
      }
7524
 
7525
      /**
7526
       * Find the _Fields constant that matches name, or null if its not found.
7527
       */
7528
      public static _Fields findByName(String name) {
7529
        return byName.get(name);
7530
      }
7531
 
7532
      private final short _thriftId;
7533
      private final String _fieldName;
7534
 
7535
      _Fields(short thriftId, String fieldName) {
7536
        _thriftId = thriftId;
7537
        _fieldName = fieldName;
7538
      }
7539
 
7540
      public short getThriftFieldId() {
7541
        return _thriftId;
7542
      }
7543
 
7544
      public String getFieldName() {
7545
        return _fieldName;
7546
      }
7547
    }
7548
 
7549
    // isset id assignments
7550
    private static final int __ITEM_ID_ISSET_ID = 0;
7551
    private BitSet __isset_bit_vector = new BitSet(1);
7552
 
7553
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7554
    static {
7555
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7556
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7557
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7558
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7559
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemInventoryByItemId_args.class, metaDataMap);
7560
    }
7561
 
7562
    public getItemInventoryByItemId_args() {
7563
    }
7564
 
7565
    public getItemInventoryByItemId_args(
7566
      long item_id)
7567
    {
7568
      this();
7569
      this.item_id = item_id;
7570
      setItem_idIsSet(true);
7571
    }
7572
 
7573
    /**
7574
     * Performs a deep copy on <i>other</i>.
7575
     */
7576
    public getItemInventoryByItemId_args(getItemInventoryByItemId_args other) {
7577
      __isset_bit_vector.clear();
7578
      __isset_bit_vector.or(other.__isset_bit_vector);
7579
      this.item_id = other.item_id;
7580
    }
7581
 
7582
    public getItemInventoryByItemId_args deepCopy() {
7583
      return new getItemInventoryByItemId_args(this);
7584
    }
7585
 
7586
    @Override
7587
    public void clear() {
7588
      setItem_idIsSet(false);
7589
      this.item_id = 0;
7590
    }
7591
 
7592
    public long getItem_id() {
7593
      return this.item_id;
7594
    }
7595
 
7596
    public void setItem_id(long item_id) {
7597
      this.item_id = item_id;
7598
      setItem_idIsSet(true);
7599
    }
7600
 
7601
    public void unsetItem_id() {
7602
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
7603
    }
7604
 
7605
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
7606
    public boolean isSetItem_id() {
7607
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
7608
    }
7609
 
7610
    public void setItem_idIsSet(boolean value) {
7611
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
7612
    }
7613
 
7614
    public void setFieldValue(_Fields field, Object value) {
7615
      switch (field) {
7616
      case ITEM_ID:
7617
        if (value == null) {
7618
          unsetItem_id();
7619
        } else {
7620
          setItem_id((Long)value);
7621
        }
7622
        break;
7623
 
7624
      }
7625
    }
7626
 
7627
    public Object getFieldValue(_Fields field) {
7628
      switch (field) {
7629
      case ITEM_ID:
7630
        return Long.valueOf(getItem_id());
7631
 
7632
      }
7633
      throw new IllegalStateException();
7634
    }
7635
 
7636
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7637
    public boolean isSet(_Fields field) {
7638
      if (field == null) {
7639
        throw new IllegalArgumentException();
7640
      }
7641
 
7642
      switch (field) {
7643
      case ITEM_ID:
7644
        return isSetItem_id();
7645
      }
7646
      throw new IllegalStateException();
7647
    }
7648
 
7649
    @Override
7650
    public boolean equals(Object that) {
7651
      if (that == null)
7652
        return false;
7653
      if (that instanceof getItemInventoryByItemId_args)
7654
        return this.equals((getItemInventoryByItemId_args)that);
7655
      return false;
7656
    }
7657
 
7658
    public boolean equals(getItemInventoryByItemId_args that) {
7659
      if (that == null)
7660
        return false;
7661
 
7662
      boolean this_present_item_id = true;
7663
      boolean that_present_item_id = true;
7664
      if (this_present_item_id || that_present_item_id) {
7665
        if (!(this_present_item_id && that_present_item_id))
7666
          return false;
7667
        if (this.item_id != that.item_id)
7668
          return false;
7669
      }
7670
 
7671
      return true;
7672
    }
7673
 
7674
    @Override
7675
    public int hashCode() {
7676
      return 0;
7677
    }
7678
 
7679
    public int compareTo(getItemInventoryByItemId_args other) {
7680
      if (!getClass().equals(other.getClass())) {
7681
        return getClass().getName().compareTo(other.getClass().getName());
7682
      }
7683
 
7684
      int lastComparison = 0;
7685
      getItemInventoryByItemId_args typedOther = (getItemInventoryByItemId_args)other;
7686
 
7687
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
7688
      if (lastComparison != 0) {
7689
        return lastComparison;
7690
      }
7691
      if (isSetItem_id()) {
7692
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
7693
        if (lastComparison != 0) {
7694
          return lastComparison;
7695
        }
7696
      }
7697
      return 0;
7698
    }
7699
 
7700
    public _Fields fieldForId(int fieldId) {
7701
      return _Fields.findByThriftId(fieldId);
7702
    }
7703
 
7704
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7705
      org.apache.thrift.protocol.TField field;
7706
      iprot.readStructBegin();
7707
      while (true)
7708
      {
7709
        field = iprot.readFieldBegin();
7710
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7711
          break;
7712
        }
7713
        switch (field.id) {
7714
          case 1: // ITEM_ID
7715
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7716
              this.item_id = iprot.readI64();
7717
              setItem_idIsSet(true);
7718
            } else { 
7719
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7720
            }
7721
            break;
7722
          default:
7723
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7724
        }
7725
        iprot.readFieldEnd();
7726
      }
7727
      iprot.readStructEnd();
7728
      validate();
7729
    }
7730
 
7731
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7732
      validate();
7733
 
7734
      oprot.writeStructBegin(STRUCT_DESC);
7735
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
7736
      oprot.writeI64(this.item_id);
7737
      oprot.writeFieldEnd();
7738
      oprot.writeFieldStop();
7739
      oprot.writeStructEnd();
7740
    }
7741
 
7742
    @Override
7743
    public String toString() {
7744
      StringBuilder sb = new StringBuilder("getItemInventoryByItemId_args(");
7745
      boolean first = true;
7746
 
7747
      sb.append("item_id:");
7748
      sb.append(this.item_id);
7749
      first = false;
7750
      sb.append(")");
7751
      return sb.toString();
7752
    }
7753
 
7754
    public void validate() throws org.apache.thrift.TException {
7755
      // check for required fields
7756
    }
7757
 
7758
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7759
      try {
7760
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7761
      } catch (org.apache.thrift.TException te) {
7762
        throw new java.io.IOException(te);
7763
      }
7764
    }
7765
 
7766
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7767
      try {
7768
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7769
        __isset_bit_vector = new BitSet(1);
7770
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7771
      } catch (org.apache.thrift.TException te) {
7772
        throw new java.io.IOException(te);
7773
      }
7774
    }
7775
 
7776
  }
7777
 
7778
  public static class getItemInventoryByItemId_result implements org.apache.thrift.TBase<getItemInventoryByItemId_result, getItemInventoryByItemId_result._Fields>, java.io.Serializable, Cloneable   {
7779
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemInventoryByItemId_result");
7780
 
7781
    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);
7782
    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);
7783
 
7784
    private ItemInventory success; // required
7785
    private InventoryServiceException cex; // required
7786
 
7787
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7788
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7789
      SUCCESS((short)0, "success"),
7790
      CEX((short)1, "cex");
7791
 
7792
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7793
 
7794
      static {
7795
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7796
          byName.put(field.getFieldName(), field);
7797
        }
7798
      }
7799
 
7800
      /**
7801
       * Find the _Fields constant that matches fieldId, or null if its not found.
7802
       */
7803
      public static _Fields findByThriftId(int fieldId) {
7804
        switch(fieldId) {
7805
          case 0: // SUCCESS
7806
            return SUCCESS;
7807
          case 1: // CEX
7808
            return CEX;
7809
          default:
7810
            return null;
7811
        }
7812
      }
7813
 
7814
      /**
7815
       * Find the _Fields constant that matches fieldId, throwing an exception
7816
       * if it is not found.
7817
       */
7818
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7819
        _Fields fields = findByThriftId(fieldId);
7820
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7821
        return fields;
7822
      }
7823
 
7824
      /**
7825
       * Find the _Fields constant that matches name, or null if its not found.
7826
       */
7827
      public static _Fields findByName(String name) {
7828
        return byName.get(name);
7829
      }
7830
 
7831
      private final short _thriftId;
7832
      private final String _fieldName;
7833
 
7834
      _Fields(short thriftId, String fieldName) {
7835
        _thriftId = thriftId;
7836
        _fieldName = fieldName;
7837
      }
7838
 
7839
      public short getThriftFieldId() {
7840
        return _thriftId;
7841
      }
7842
 
7843
      public String getFieldName() {
7844
        return _fieldName;
7845
      }
7846
    }
7847
 
7848
    // isset id assignments
7849
 
7850
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7851
    static {
7852
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7853
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7854
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ItemInventory.class)));
7855
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7856
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7857
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7858
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemInventoryByItemId_result.class, metaDataMap);
7859
    }
7860
 
7861
    public getItemInventoryByItemId_result() {
7862
    }
7863
 
7864
    public getItemInventoryByItemId_result(
7865
      ItemInventory success,
7866
      InventoryServiceException cex)
7867
    {
7868
      this();
7869
      this.success = success;
7870
      this.cex = cex;
7871
    }
7872
 
7873
    /**
7874
     * Performs a deep copy on <i>other</i>.
7875
     */
7876
    public getItemInventoryByItemId_result(getItemInventoryByItemId_result other) {
7877
      if (other.isSetSuccess()) {
7878
        this.success = new ItemInventory(other.success);
7879
      }
7880
      if (other.isSetCex()) {
7881
        this.cex = new InventoryServiceException(other.cex);
7882
      }
7883
    }
7884
 
7885
    public getItemInventoryByItemId_result deepCopy() {
7886
      return new getItemInventoryByItemId_result(this);
7887
    }
7888
 
7889
    @Override
7890
    public void clear() {
7891
      this.success = null;
7892
      this.cex = null;
7893
    }
7894
 
7895
    public ItemInventory getSuccess() {
7896
      return this.success;
7897
    }
7898
 
7899
    public void setSuccess(ItemInventory success) {
7900
      this.success = success;
7901
    }
7902
 
7903
    public void unsetSuccess() {
7904
      this.success = null;
7905
    }
7906
 
7907
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
7908
    public boolean isSetSuccess() {
7909
      return this.success != null;
7910
    }
7911
 
7912
    public void setSuccessIsSet(boolean value) {
7913
      if (!value) {
7914
        this.success = null;
7915
      }
7916
    }
7917
 
7918
    public InventoryServiceException getCex() {
7919
      return this.cex;
7920
    }
7921
 
7922
    public void setCex(InventoryServiceException cex) {
7923
      this.cex = cex;
7924
    }
7925
 
7926
    public void unsetCex() {
7927
      this.cex = null;
7928
    }
7929
 
7930
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
7931
    public boolean isSetCex() {
7932
      return this.cex != null;
7933
    }
7934
 
7935
    public void setCexIsSet(boolean value) {
7936
      if (!value) {
7937
        this.cex = null;
7938
      }
7939
    }
7940
 
7941
    public void setFieldValue(_Fields field, Object value) {
7942
      switch (field) {
7943
      case SUCCESS:
7944
        if (value == null) {
7945
          unsetSuccess();
7946
        } else {
7947
          setSuccess((ItemInventory)value);
7948
        }
7949
        break;
7950
 
7951
      case CEX:
7952
        if (value == null) {
7953
          unsetCex();
7954
        } else {
7955
          setCex((InventoryServiceException)value);
7956
        }
7957
        break;
7958
 
7959
      }
7960
    }
7961
 
7962
    public Object getFieldValue(_Fields field) {
7963
      switch (field) {
7964
      case SUCCESS:
7965
        return getSuccess();
7966
 
7967
      case CEX:
7968
        return getCex();
7969
 
7970
      }
7971
      throw new IllegalStateException();
7972
    }
7973
 
7974
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7975
    public boolean isSet(_Fields field) {
7976
      if (field == null) {
7977
        throw new IllegalArgumentException();
7978
      }
7979
 
7980
      switch (field) {
7981
      case SUCCESS:
7982
        return isSetSuccess();
7983
      case CEX:
7984
        return isSetCex();
7985
      }
7986
      throw new IllegalStateException();
7987
    }
7988
 
7989
    @Override
7990
    public boolean equals(Object that) {
7991
      if (that == null)
7992
        return false;
7993
      if (that instanceof getItemInventoryByItemId_result)
7994
        return this.equals((getItemInventoryByItemId_result)that);
7995
      return false;
7996
    }
7997
 
7998
    public boolean equals(getItemInventoryByItemId_result that) {
7999
      if (that == null)
8000
        return false;
8001
 
8002
      boolean this_present_success = true && this.isSetSuccess();
8003
      boolean that_present_success = true && that.isSetSuccess();
8004
      if (this_present_success || that_present_success) {
8005
        if (!(this_present_success && that_present_success))
8006
          return false;
8007
        if (!this.success.equals(that.success))
8008
          return false;
8009
      }
8010
 
8011
      boolean this_present_cex = true && this.isSetCex();
8012
      boolean that_present_cex = true && that.isSetCex();
8013
      if (this_present_cex || that_present_cex) {
8014
        if (!(this_present_cex && that_present_cex))
8015
          return false;
8016
        if (!this.cex.equals(that.cex))
8017
          return false;
8018
      }
8019
 
8020
      return true;
8021
    }
8022
 
8023
    @Override
8024
    public int hashCode() {
8025
      return 0;
8026
    }
8027
 
8028
    public int compareTo(getItemInventoryByItemId_result other) {
8029
      if (!getClass().equals(other.getClass())) {
8030
        return getClass().getName().compareTo(other.getClass().getName());
8031
      }
8032
 
8033
      int lastComparison = 0;
8034
      getItemInventoryByItemId_result typedOther = (getItemInventoryByItemId_result)other;
8035
 
8036
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
8037
      if (lastComparison != 0) {
8038
        return lastComparison;
8039
      }
8040
      if (isSetSuccess()) {
8041
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8042
        if (lastComparison != 0) {
8043
          return lastComparison;
8044
        }
8045
      }
8046
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
8047
      if (lastComparison != 0) {
8048
        return lastComparison;
8049
      }
8050
      if (isSetCex()) {
8051
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
8052
        if (lastComparison != 0) {
8053
          return lastComparison;
8054
        }
8055
      }
8056
      return 0;
8057
    }
8058
 
8059
    public _Fields fieldForId(int fieldId) {
8060
      return _Fields.findByThriftId(fieldId);
8061
    }
8062
 
8063
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8064
      org.apache.thrift.protocol.TField field;
8065
      iprot.readStructBegin();
8066
      while (true)
8067
      {
8068
        field = iprot.readFieldBegin();
8069
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8070
          break;
8071
        }
8072
        switch (field.id) {
8073
          case 0: // SUCCESS
8074
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8075
              this.success = new ItemInventory();
8076
              this.success.read(iprot);
8077
            } else { 
8078
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8079
            }
8080
            break;
8081
          case 1: // CEX
8082
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8083
              this.cex = new InventoryServiceException();
8084
              this.cex.read(iprot);
8085
            } else { 
8086
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8087
            }
8088
            break;
8089
          default:
8090
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8091
        }
8092
        iprot.readFieldEnd();
8093
      }
8094
      iprot.readStructEnd();
8095
      validate();
8096
    }
8097
 
8098
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8099
      oprot.writeStructBegin(STRUCT_DESC);
8100
 
8101
      if (this.isSetSuccess()) {
8102
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8103
        this.success.write(oprot);
8104
        oprot.writeFieldEnd();
8105
      } else if (this.isSetCex()) {
8106
        oprot.writeFieldBegin(CEX_FIELD_DESC);
8107
        this.cex.write(oprot);
8108
        oprot.writeFieldEnd();
8109
      }
8110
      oprot.writeFieldStop();
8111
      oprot.writeStructEnd();
8112
    }
8113
 
8114
    @Override
8115
    public String toString() {
8116
      StringBuilder sb = new StringBuilder("getItemInventoryByItemId_result(");
8117
      boolean first = true;
8118
 
8119
      sb.append("success:");
8120
      if (this.success == null) {
8121
        sb.append("null");
8122
      } else {
8123
        sb.append(this.success);
8124
      }
8125
      first = false;
8126
      if (!first) sb.append(", ");
8127
      sb.append("cex:");
8128
      if (this.cex == null) {
8129
        sb.append("null");
8130
      } else {
8131
        sb.append(this.cex);
8132
      }
8133
      first = false;
8134
      sb.append(")");
8135
      return sb.toString();
8136
    }
8137
 
8138
    public void validate() throws org.apache.thrift.TException {
8139
      // check for required fields
8140
    }
8141
 
8142
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8143
      try {
8144
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8145
      } catch (org.apache.thrift.TException te) {
8146
        throw new java.io.IOException(te);
8147
      }
8148
    }
8149
 
8150
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8151
      try {
8152
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8153
      } catch (org.apache.thrift.TException te) {
8154
        throw new java.io.IOException(te);
8155
      }
8156
    }
8157
 
8158
  }
8159
 
8160
  public static class getItemAvailibilityAtWarehouse_args implements org.apache.thrift.TBase<getItemAvailibilityAtWarehouse_args, getItemAvailibilityAtWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
8161
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailibilityAtWarehouse_args");
8162
 
8163
    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);
8164
    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);
8165
 
8166
    private long warehouse_id; // required
8167
    private long item_id; // required
8168
 
8169
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8170
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8171
      WAREHOUSE_ID((short)1, "warehouse_id"),
8172
      ITEM_ID((short)2, "item_id");
8173
 
8174
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8175
 
8176
      static {
8177
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8178
          byName.put(field.getFieldName(), field);
8179
        }
8180
      }
8181
 
8182
      /**
8183
       * Find the _Fields constant that matches fieldId, or null if its not found.
8184
       */
8185
      public static _Fields findByThriftId(int fieldId) {
8186
        switch(fieldId) {
8187
          case 1: // WAREHOUSE_ID
8188
            return WAREHOUSE_ID;
8189
          case 2: // ITEM_ID
8190
            return ITEM_ID;
8191
          default:
8192
            return null;
8193
        }
8194
      }
8195
 
8196
      /**
8197
       * Find the _Fields constant that matches fieldId, throwing an exception
8198
       * if it is not found.
8199
       */
8200
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8201
        _Fields fields = findByThriftId(fieldId);
8202
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8203
        return fields;
8204
      }
8205
 
8206
      /**
8207
       * Find the _Fields constant that matches name, or null if its not found.
8208
       */
8209
      public static _Fields findByName(String name) {
8210
        return byName.get(name);
8211
      }
8212
 
8213
      private final short _thriftId;
8214
      private final String _fieldName;
8215
 
8216
      _Fields(short thriftId, String fieldName) {
8217
        _thriftId = thriftId;
8218
        _fieldName = fieldName;
8219
      }
8220
 
8221
      public short getThriftFieldId() {
8222
        return _thriftId;
8223
      }
8224
 
8225
      public String getFieldName() {
8226
        return _fieldName;
8227
      }
8228
    }
8229
 
8230
    // isset id assignments
8231
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
8232
    private static final int __ITEM_ID_ISSET_ID = 1;
8233
    private BitSet __isset_bit_vector = new BitSet(2);
8234
 
8235
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8236
    static {
8237
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8238
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8239
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8240
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8241
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8242
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8243
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailibilityAtWarehouse_args.class, metaDataMap);
8244
    }
8245
 
8246
    public getItemAvailibilityAtWarehouse_args() {
8247
    }
8248
 
8249
    public getItemAvailibilityAtWarehouse_args(
8250
      long warehouse_id,
8251
      long item_id)
8252
    {
8253
      this();
8254
      this.warehouse_id = warehouse_id;
8255
      setWarehouse_idIsSet(true);
8256
      this.item_id = item_id;
8257
      setItem_idIsSet(true);
8258
    }
8259
 
8260
    /**
8261
     * Performs a deep copy on <i>other</i>.
8262
     */
8263
    public getItemAvailibilityAtWarehouse_args(getItemAvailibilityAtWarehouse_args other) {
8264
      __isset_bit_vector.clear();
8265
      __isset_bit_vector.or(other.__isset_bit_vector);
8266
      this.warehouse_id = other.warehouse_id;
8267
      this.item_id = other.item_id;
8268
    }
8269
 
8270
    public getItemAvailibilityAtWarehouse_args deepCopy() {
8271
      return new getItemAvailibilityAtWarehouse_args(this);
8272
    }
8273
 
8274
    @Override
8275
    public void clear() {
8276
      setWarehouse_idIsSet(false);
8277
      this.warehouse_id = 0;
8278
      setItem_idIsSet(false);
8279
      this.item_id = 0;
8280
    }
8281
 
8282
    public long getWarehouse_id() {
8283
      return this.warehouse_id;
8284
    }
8285
 
8286
    public void setWarehouse_id(long warehouse_id) {
8287
      this.warehouse_id = warehouse_id;
8288
      setWarehouse_idIsSet(true);
8289
    }
8290
 
8291
    public void unsetWarehouse_id() {
8292
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
8293
    }
8294
 
8295
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
8296
    public boolean isSetWarehouse_id() {
8297
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
8298
    }
8299
 
8300
    public void setWarehouse_idIsSet(boolean value) {
8301
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
8302
    }
8303
 
8304
    public long getItem_id() {
8305
      return this.item_id;
8306
    }
8307
 
8308
    public void setItem_id(long item_id) {
8309
      this.item_id = item_id;
8310
      setItem_idIsSet(true);
8311
    }
8312
 
8313
    public void unsetItem_id() {
8314
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
8315
    }
8316
 
8317
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
8318
    public boolean isSetItem_id() {
8319
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
8320
    }
8321
 
8322
    public void setItem_idIsSet(boolean value) {
8323
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
8324
    }
8325
 
8326
    public void setFieldValue(_Fields field, Object value) {
8327
      switch (field) {
8328
      case WAREHOUSE_ID:
8329
        if (value == null) {
8330
          unsetWarehouse_id();
8331
        } else {
8332
          setWarehouse_id((Long)value);
8333
        }
8334
        break;
8335
 
8336
      case ITEM_ID:
8337
        if (value == null) {
8338
          unsetItem_id();
8339
        } else {
8340
          setItem_id((Long)value);
8341
        }
8342
        break;
8343
 
8344
      }
8345
    }
8346
 
8347
    public Object getFieldValue(_Fields field) {
8348
      switch (field) {
8349
      case WAREHOUSE_ID:
8350
        return Long.valueOf(getWarehouse_id());
8351
 
8352
      case ITEM_ID:
8353
        return Long.valueOf(getItem_id());
8354
 
8355
      }
8356
      throw new IllegalStateException();
8357
    }
8358
 
8359
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8360
    public boolean isSet(_Fields field) {
8361
      if (field == null) {
8362
        throw new IllegalArgumentException();
8363
      }
8364
 
8365
      switch (field) {
8366
      case WAREHOUSE_ID:
8367
        return isSetWarehouse_id();
8368
      case ITEM_ID:
8369
        return isSetItem_id();
8370
      }
8371
      throw new IllegalStateException();
8372
    }
8373
 
8374
    @Override
8375
    public boolean equals(Object that) {
8376
      if (that == null)
8377
        return false;
8378
      if (that instanceof getItemAvailibilityAtWarehouse_args)
8379
        return this.equals((getItemAvailibilityAtWarehouse_args)that);
8380
      return false;
8381
    }
8382
 
8383
    public boolean equals(getItemAvailibilityAtWarehouse_args that) {
8384
      if (that == null)
8385
        return false;
8386
 
8387
      boolean this_present_warehouse_id = true;
8388
      boolean that_present_warehouse_id = true;
8389
      if (this_present_warehouse_id || that_present_warehouse_id) {
8390
        if (!(this_present_warehouse_id && that_present_warehouse_id))
8391
          return false;
8392
        if (this.warehouse_id != that.warehouse_id)
8393
          return false;
8394
      }
8395
 
8396
      boolean this_present_item_id = true;
8397
      boolean that_present_item_id = true;
8398
      if (this_present_item_id || that_present_item_id) {
8399
        if (!(this_present_item_id && that_present_item_id))
8400
          return false;
8401
        if (this.item_id != that.item_id)
8402
          return false;
8403
      }
8404
 
8405
      return true;
8406
    }
8407
 
8408
    @Override
8409
    public int hashCode() {
8410
      return 0;
8411
    }
8412
 
8413
    public int compareTo(getItemAvailibilityAtWarehouse_args other) {
8414
      if (!getClass().equals(other.getClass())) {
8415
        return getClass().getName().compareTo(other.getClass().getName());
8416
      }
8417
 
8418
      int lastComparison = 0;
8419
      getItemAvailibilityAtWarehouse_args typedOther = (getItemAvailibilityAtWarehouse_args)other;
8420
 
8421
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
8422
      if (lastComparison != 0) {
8423
        return lastComparison;
8424
      }
8425
      if (isSetWarehouse_id()) {
8426
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
8427
        if (lastComparison != 0) {
8428
          return lastComparison;
8429
        }
8430
      }
8431
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
8432
      if (lastComparison != 0) {
8433
        return lastComparison;
8434
      }
8435
      if (isSetItem_id()) {
8436
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
8437
        if (lastComparison != 0) {
8438
          return lastComparison;
8439
        }
8440
      }
8441
      return 0;
8442
    }
8443
 
8444
    public _Fields fieldForId(int fieldId) {
8445
      return _Fields.findByThriftId(fieldId);
8446
    }
8447
 
8448
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8449
      org.apache.thrift.protocol.TField field;
8450
      iprot.readStructBegin();
8451
      while (true)
8452
      {
8453
        field = iprot.readFieldBegin();
8454
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8455
          break;
8456
        }
8457
        switch (field.id) {
8458
          case 1: // WAREHOUSE_ID
8459
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8460
              this.warehouse_id = iprot.readI64();
8461
              setWarehouse_idIsSet(true);
8462
            } else { 
8463
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8464
            }
8465
            break;
8466
          case 2: // ITEM_ID
8467
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8468
              this.item_id = iprot.readI64();
8469
              setItem_idIsSet(true);
8470
            } else { 
8471
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8472
            }
8473
            break;
8474
          default:
8475
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8476
        }
8477
        iprot.readFieldEnd();
8478
      }
8479
      iprot.readStructEnd();
8480
      validate();
8481
    }
8482
 
8483
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8484
      validate();
8485
 
8486
      oprot.writeStructBegin(STRUCT_DESC);
8487
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
8488
      oprot.writeI64(this.warehouse_id);
8489
      oprot.writeFieldEnd();
8490
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
8491
      oprot.writeI64(this.item_id);
8492
      oprot.writeFieldEnd();
8493
      oprot.writeFieldStop();
8494
      oprot.writeStructEnd();
8495
    }
8496
 
8497
    @Override
8498
    public String toString() {
8499
      StringBuilder sb = new StringBuilder("getItemAvailibilityAtWarehouse_args(");
8500
      boolean first = true;
8501
 
8502
      sb.append("warehouse_id:");
8503
      sb.append(this.warehouse_id);
8504
      first = false;
8505
      if (!first) sb.append(", ");
8506
      sb.append("item_id:");
8507
      sb.append(this.item_id);
8508
      first = false;
8509
      sb.append(")");
8510
      return sb.toString();
8511
    }
8512
 
8513
    public void validate() throws org.apache.thrift.TException {
8514
      // check for required fields
8515
    }
8516
 
8517
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8518
      try {
8519
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8520
      } catch (org.apache.thrift.TException te) {
8521
        throw new java.io.IOException(te);
8522
      }
8523
    }
8524
 
8525
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8526
      try {
8527
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
8528
        __isset_bit_vector = new BitSet(1);
8529
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8530
      } catch (org.apache.thrift.TException te) {
8531
        throw new java.io.IOException(te);
8532
      }
8533
    }
8534
 
8535
  }
8536
 
8537
  public static class getItemAvailibilityAtWarehouse_result implements org.apache.thrift.TBase<getItemAvailibilityAtWarehouse_result, getItemAvailibilityAtWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
8538
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailibilityAtWarehouse_result");
8539
 
8540
    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);
8541
    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);
8542
 
8543
    private long success; // required
8544
    private InventoryServiceException cex; // required
8545
 
8546
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8547
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8548
      SUCCESS((short)0, "success"),
8549
      CEX((short)1, "cex");
8550
 
8551
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8552
 
8553
      static {
8554
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8555
          byName.put(field.getFieldName(), field);
8556
        }
8557
      }
8558
 
8559
      /**
8560
       * Find the _Fields constant that matches fieldId, or null if its not found.
8561
       */
8562
      public static _Fields findByThriftId(int fieldId) {
8563
        switch(fieldId) {
8564
          case 0: // SUCCESS
8565
            return SUCCESS;
8566
          case 1: // CEX
8567
            return CEX;
8568
          default:
8569
            return null;
8570
        }
8571
      }
8572
 
8573
      /**
8574
       * Find the _Fields constant that matches fieldId, throwing an exception
8575
       * if it is not found.
8576
       */
8577
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8578
        _Fields fields = findByThriftId(fieldId);
8579
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8580
        return fields;
8581
      }
8582
 
8583
      /**
8584
       * Find the _Fields constant that matches name, or null if its not found.
8585
       */
8586
      public static _Fields findByName(String name) {
8587
        return byName.get(name);
8588
      }
8589
 
8590
      private final short _thriftId;
8591
      private final String _fieldName;
8592
 
8593
      _Fields(short thriftId, String fieldName) {
8594
        _thriftId = thriftId;
8595
        _fieldName = fieldName;
8596
      }
8597
 
8598
      public short getThriftFieldId() {
8599
        return _thriftId;
8600
      }
8601
 
8602
      public String getFieldName() {
8603
        return _fieldName;
8604
      }
8605
    }
8606
 
8607
    // isset id assignments
8608
    private static final int __SUCCESS_ISSET_ID = 0;
8609
    private BitSet __isset_bit_vector = new BitSet(1);
8610
 
8611
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8612
    static {
8613
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8614
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8615
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8616
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8617
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
8618
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8619
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailibilityAtWarehouse_result.class, metaDataMap);
8620
    }
8621
 
8622
    public getItemAvailibilityAtWarehouse_result() {
8623
    }
8624
 
8625
    public getItemAvailibilityAtWarehouse_result(
8626
      long success,
8627
      InventoryServiceException cex)
8628
    {
8629
      this();
8630
      this.success = success;
8631
      setSuccessIsSet(true);
8632
      this.cex = cex;
8633
    }
8634
 
8635
    /**
8636
     * Performs a deep copy on <i>other</i>.
8637
     */
8638
    public getItemAvailibilityAtWarehouse_result(getItemAvailibilityAtWarehouse_result other) {
8639
      __isset_bit_vector.clear();
8640
      __isset_bit_vector.or(other.__isset_bit_vector);
8641
      this.success = other.success;
8642
      if (other.isSetCex()) {
8643
        this.cex = new InventoryServiceException(other.cex);
8644
      }
8645
    }
8646
 
8647
    public getItemAvailibilityAtWarehouse_result deepCopy() {
8648
      return new getItemAvailibilityAtWarehouse_result(this);
8649
    }
8650
 
8651
    @Override
8652
    public void clear() {
8653
      setSuccessIsSet(false);
8654
      this.success = 0;
8655
      this.cex = null;
8656
    }
8657
 
8658
    public long getSuccess() {
8659
      return this.success;
8660
    }
8661
 
8662
    public void setSuccess(long success) {
8663
      this.success = success;
8664
      setSuccessIsSet(true);
8665
    }
8666
 
8667
    public void unsetSuccess() {
8668
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
8669
    }
8670
 
8671
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
8672
    public boolean isSetSuccess() {
8673
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
8674
    }
8675
 
8676
    public void setSuccessIsSet(boolean value) {
8677
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
8678
    }
8679
 
8680
    public InventoryServiceException getCex() {
8681
      return this.cex;
8682
    }
8683
 
8684
    public void setCex(InventoryServiceException cex) {
8685
      this.cex = cex;
8686
    }
8687
 
8688
    public void unsetCex() {
8689
      this.cex = null;
8690
    }
8691
 
8692
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
8693
    public boolean isSetCex() {
8694
      return this.cex != null;
8695
    }
8696
 
8697
    public void setCexIsSet(boolean value) {
8698
      if (!value) {
8699
        this.cex = null;
8700
      }
8701
    }
8702
 
8703
    public void setFieldValue(_Fields field, Object value) {
8704
      switch (field) {
8705
      case SUCCESS:
8706
        if (value == null) {
8707
          unsetSuccess();
8708
        } else {
8709
          setSuccess((Long)value);
8710
        }
8711
        break;
8712
 
8713
      case CEX:
8714
        if (value == null) {
8715
          unsetCex();
8716
        } else {
8717
          setCex((InventoryServiceException)value);
8718
        }
8719
        break;
8720
 
8721
      }
8722
    }
8723
 
8724
    public Object getFieldValue(_Fields field) {
8725
      switch (field) {
8726
      case SUCCESS:
8727
        return Long.valueOf(getSuccess());
8728
 
8729
      case CEX:
8730
        return getCex();
8731
 
8732
      }
8733
      throw new IllegalStateException();
8734
    }
8735
 
8736
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8737
    public boolean isSet(_Fields field) {
8738
      if (field == null) {
8739
        throw new IllegalArgumentException();
8740
      }
8741
 
8742
      switch (field) {
8743
      case SUCCESS:
8744
        return isSetSuccess();
8745
      case CEX:
8746
        return isSetCex();
8747
      }
8748
      throw new IllegalStateException();
8749
    }
8750
 
8751
    @Override
8752
    public boolean equals(Object that) {
8753
      if (that == null)
8754
        return false;
8755
      if (that instanceof getItemAvailibilityAtWarehouse_result)
8756
        return this.equals((getItemAvailibilityAtWarehouse_result)that);
8757
      return false;
8758
    }
8759
 
8760
    public boolean equals(getItemAvailibilityAtWarehouse_result that) {
8761
      if (that == null)
8762
        return false;
8763
 
8764
      boolean this_present_success = true;
8765
      boolean that_present_success = true;
8766
      if (this_present_success || that_present_success) {
8767
        if (!(this_present_success && that_present_success))
8768
          return false;
8769
        if (this.success != that.success)
8770
          return false;
8771
      }
8772
 
8773
      boolean this_present_cex = true && this.isSetCex();
8774
      boolean that_present_cex = true && that.isSetCex();
8775
      if (this_present_cex || that_present_cex) {
8776
        if (!(this_present_cex && that_present_cex))
8777
          return false;
8778
        if (!this.cex.equals(that.cex))
8779
          return false;
8780
      }
8781
 
8782
      return true;
8783
    }
8784
 
8785
    @Override
8786
    public int hashCode() {
8787
      return 0;
8788
    }
8789
 
8790
    public int compareTo(getItemAvailibilityAtWarehouse_result other) {
8791
      if (!getClass().equals(other.getClass())) {
8792
        return getClass().getName().compareTo(other.getClass().getName());
8793
      }
8794
 
8795
      int lastComparison = 0;
8796
      getItemAvailibilityAtWarehouse_result typedOther = (getItemAvailibilityAtWarehouse_result)other;
8797
 
8798
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
8799
      if (lastComparison != 0) {
8800
        return lastComparison;
8801
      }
8802
      if (isSetSuccess()) {
8803
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8804
        if (lastComparison != 0) {
8805
          return lastComparison;
8806
        }
8807
      }
8808
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
8809
      if (lastComparison != 0) {
8810
        return lastComparison;
8811
      }
8812
      if (isSetCex()) {
8813
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
8814
        if (lastComparison != 0) {
8815
          return lastComparison;
8816
        }
8817
      }
8818
      return 0;
8819
    }
8820
 
8821
    public _Fields fieldForId(int fieldId) {
8822
      return _Fields.findByThriftId(fieldId);
8823
    }
8824
 
8825
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8826
      org.apache.thrift.protocol.TField field;
8827
      iprot.readStructBegin();
8828
      while (true)
8829
      {
8830
        field = iprot.readFieldBegin();
8831
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8832
          break;
8833
        }
8834
        switch (field.id) {
8835
          case 0: // SUCCESS
8836
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8837
              this.success = iprot.readI64();
8838
              setSuccessIsSet(true);
8839
            } else { 
8840
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8841
            }
8842
            break;
8843
          case 1: // CEX
8844
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8845
              this.cex = new InventoryServiceException();
8846
              this.cex.read(iprot);
8847
            } else { 
8848
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8849
            }
8850
            break;
8851
          default:
8852
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8853
        }
8854
        iprot.readFieldEnd();
8855
      }
8856
      iprot.readStructEnd();
8857
      validate();
8858
    }
8859
 
8860
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8861
      oprot.writeStructBegin(STRUCT_DESC);
8862
 
8863
      if (this.isSetSuccess()) {
8864
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8865
        oprot.writeI64(this.success);
8866
        oprot.writeFieldEnd();
8867
      } else if (this.isSetCex()) {
8868
        oprot.writeFieldBegin(CEX_FIELD_DESC);
8869
        this.cex.write(oprot);
8870
        oprot.writeFieldEnd();
8871
      }
8872
      oprot.writeFieldStop();
8873
      oprot.writeStructEnd();
8874
    }
8875
 
8876
    @Override
8877
    public String toString() {
8878
      StringBuilder sb = new StringBuilder("getItemAvailibilityAtWarehouse_result(");
8879
      boolean first = true;
8880
 
8881
      sb.append("success:");
8882
      sb.append(this.success);
8883
      first = false;
8884
      if (!first) sb.append(", ");
8885
      sb.append("cex:");
8886
      if (this.cex == null) {
8887
        sb.append("null");
8888
      } else {
8889
        sb.append(this.cex);
8890
      }
8891
      first = false;
8892
      sb.append(")");
8893
      return sb.toString();
8894
    }
8895
 
8896
    public void validate() throws org.apache.thrift.TException {
8897
      // check for required fields
8898
    }
8899
 
8900
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8901
      try {
8902
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8903
      } catch (org.apache.thrift.TException te) {
8904
        throw new java.io.IOException(te);
8905
      }
8906
    }
8907
 
8908
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8909
      try {
8910
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8911
      } catch (org.apache.thrift.TException te) {
8912
        throw new java.io.IOException(te);
8913
      }
8914
    }
8915
 
8916
  }
8917
 
8918
  public static class getItemAvailabilityAtLocation_args implements org.apache.thrift.TBase<getItemAvailabilityAtLocation_args, getItemAvailabilityAtLocation_args._Fields>, java.io.Serializable, Cloneable   {
8919
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailabilityAtLocation_args");
8920
 
8921
    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 8922
    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 8923
 
8924
    private long itemId; // required
5978 rajveer 8925
    private long sourceId; // required
5945 mandeep.dh 8926
 
8927
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8928
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5978 rajveer 8929
      ITEM_ID((short)1, "itemId"),
8930
      SOURCE_ID((short)2, "sourceId");
5945 mandeep.dh 8931
 
8932
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8933
 
8934
      static {
8935
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8936
          byName.put(field.getFieldName(), field);
8937
        }
8938
      }
8939
 
8940
      /**
8941
       * Find the _Fields constant that matches fieldId, or null if its not found.
8942
       */
8943
      public static _Fields findByThriftId(int fieldId) {
8944
        switch(fieldId) {
8945
          case 1: // ITEM_ID
8946
            return ITEM_ID;
5978 rajveer 8947
          case 2: // SOURCE_ID
8948
            return SOURCE_ID;
5945 mandeep.dh 8949
          default:
8950
            return null;
8951
        }
8952
      }
8953
 
8954
      /**
8955
       * Find the _Fields constant that matches fieldId, throwing an exception
8956
       * if it is not found.
8957
       */
8958
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8959
        _Fields fields = findByThriftId(fieldId);
8960
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8961
        return fields;
8962
      }
8963
 
8964
      /**
8965
       * Find the _Fields constant that matches name, or null if its not found.
8966
       */
8967
      public static _Fields findByName(String name) {
8968
        return byName.get(name);
8969
      }
8970
 
8971
      private final short _thriftId;
8972
      private final String _fieldName;
8973
 
8974
      _Fields(short thriftId, String fieldName) {
8975
        _thriftId = thriftId;
8976
        _fieldName = fieldName;
8977
      }
8978
 
8979
      public short getThriftFieldId() {
8980
        return _thriftId;
8981
      }
8982
 
8983
      public String getFieldName() {
8984
        return _fieldName;
8985
      }
8986
    }
8987
 
8988
    // isset id assignments
8989
    private static final int __ITEMID_ISSET_ID = 0;
5978 rajveer 8990
    private static final int __SOURCEID_ISSET_ID = 1;
8991
    private BitSet __isset_bit_vector = new BitSet(2);
5945 mandeep.dh 8992
 
8993
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8994
    static {
8995
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8996
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8997
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5978 rajveer 8998
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8999
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5945 mandeep.dh 9000
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9001
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailabilityAtLocation_args.class, metaDataMap);
9002
    }
9003
 
9004
    public getItemAvailabilityAtLocation_args() {
9005
    }
9006
 
9007
    public getItemAvailabilityAtLocation_args(
5978 rajveer 9008
      long itemId,
9009
      long sourceId)
5945 mandeep.dh 9010
    {
9011
      this();
9012
      this.itemId = itemId;
9013
      setItemIdIsSet(true);
5978 rajveer 9014
      this.sourceId = sourceId;
9015
      setSourceIdIsSet(true);
5945 mandeep.dh 9016
    }
9017
 
9018
    /**
9019
     * Performs a deep copy on <i>other</i>.
9020
     */
9021
    public getItemAvailabilityAtLocation_args(getItemAvailabilityAtLocation_args other) {
9022
      __isset_bit_vector.clear();
9023
      __isset_bit_vector.or(other.__isset_bit_vector);
9024
      this.itemId = other.itemId;
5978 rajveer 9025
      this.sourceId = other.sourceId;
5945 mandeep.dh 9026
    }
9027
 
9028
    public getItemAvailabilityAtLocation_args deepCopy() {
9029
      return new getItemAvailabilityAtLocation_args(this);
9030
    }
9031
 
9032
    @Override
9033
    public void clear() {
9034
      setItemIdIsSet(false);
9035
      this.itemId = 0;
5978 rajveer 9036
      setSourceIdIsSet(false);
9037
      this.sourceId = 0;
5945 mandeep.dh 9038
    }
9039
 
9040
    public long getItemId() {
9041
      return this.itemId;
9042
    }
9043
 
9044
    public void setItemId(long itemId) {
9045
      this.itemId = itemId;
9046
      setItemIdIsSet(true);
9047
    }
9048
 
9049
    public void unsetItemId() {
9050
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
9051
    }
9052
 
9053
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
9054
    public boolean isSetItemId() {
9055
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
9056
    }
9057
 
9058
    public void setItemIdIsSet(boolean value) {
9059
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
9060
    }
9061
 
5978 rajveer 9062
    public long getSourceId() {
9063
      return this.sourceId;
9064
    }
9065
 
9066
    public void setSourceId(long sourceId) {
9067
      this.sourceId = sourceId;
9068
      setSourceIdIsSet(true);
9069
    }
9070
 
9071
    public void unsetSourceId() {
9072
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
9073
    }
9074
 
9075
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
9076
    public boolean isSetSourceId() {
9077
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
9078
    }
9079
 
9080
    public void setSourceIdIsSet(boolean value) {
9081
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
9082
    }
9083
 
5945 mandeep.dh 9084
    public void setFieldValue(_Fields field, Object value) {
9085
      switch (field) {
9086
      case ITEM_ID:
9087
        if (value == null) {
9088
          unsetItemId();
9089
        } else {
9090
          setItemId((Long)value);
9091
        }
9092
        break;
9093
 
5978 rajveer 9094
      case SOURCE_ID:
9095
        if (value == null) {
9096
          unsetSourceId();
9097
        } else {
9098
          setSourceId((Long)value);
9099
        }
9100
        break;
9101
 
5945 mandeep.dh 9102
      }
9103
    }
9104
 
9105
    public Object getFieldValue(_Fields field) {
9106
      switch (field) {
9107
      case ITEM_ID:
9108
        return Long.valueOf(getItemId());
9109
 
5978 rajveer 9110
      case SOURCE_ID:
9111
        return Long.valueOf(getSourceId());
9112
 
5945 mandeep.dh 9113
      }
9114
      throw new IllegalStateException();
9115
    }
9116
 
9117
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9118
    public boolean isSet(_Fields field) {
9119
      if (field == null) {
9120
        throw new IllegalArgumentException();
9121
      }
9122
 
9123
      switch (field) {
9124
      case ITEM_ID:
9125
        return isSetItemId();
5978 rajveer 9126
      case SOURCE_ID:
9127
        return isSetSourceId();
5945 mandeep.dh 9128
      }
9129
      throw new IllegalStateException();
9130
    }
9131
 
9132
    @Override
9133
    public boolean equals(Object that) {
9134
      if (that == null)
9135
        return false;
9136
      if (that instanceof getItemAvailabilityAtLocation_args)
9137
        return this.equals((getItemAvailabilityAtLocation_args)that);
9138
      return false;
9139
    }
9140
 
9141
    public boolean equals(getItemAvailabilityAtLocation_args that) {
9142
      if (that == null)
9143
        return false;
9144
 
9145
      boolean this_present_itemId = true;
9146
      boolean that_present_itemId = true;
9147
      if (this_present_itemId || that_present_itemId) {
9148
        if (!(this_present_itemId && that_present_itemId))
9149
          return false;
9150
        if (this.itemId != that.itemId)
9151
          return false;
9152
      }
9153
 
5978 rajveer 9154
      boolean this_present_sourceId = true;
9155
      boolean that_present_sourceId = true;
9156
      if (this_present_sourceId || that_present_sourceId) {
9157
        if (!(this_present_sourceId && that_present_sourceId))
9158
          return false;
9159
        if (this.sourceId != that.sourceId)
9160
          return false;
9161
      }
9162
 
5945 mandeep.dh 9163
      return true;
9164
    }
9165
 
9166
    @Override
9167
    public int hashCode() {
9168
      return 0;
9169
    }
9170
 
9171
    public int compareTo(getItemAvailabilityAtLocation_args other) {
9172
      if (!getClass().equals(other.getClass())) {
9173
        return getClass().getName().compareTo(other.getClass().getName());
9174
      }
9175
 
9176
      int lastComparison = 0;
9177
      getItemAvailabilityAtLocation_args typedOther = (getItemAvailabilityAtLocation_args)other;
9178
 
9179
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
9180
      if (lastComparison != 0) {
9181
        return lastComparison;
9182
      }
9183
      if (isSetItemId()) {
9184
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
9185
        if (lastComparison != 0) {
9186
          return lastComparison;
9187
        }
9188
      }
5978 rajveer 9189
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
9190
      if (lastComparison != 0) {
9191
        return lastComparison;
9192
      }
9193
      if (isSetSourceId()) {
9194
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
9195
        if (lastComparison != 0) {
9196
          return lastComparison;
9197
        }
9198
      }
5945 mandeep.dh 9199
      return 0;
9200
    }
9201
 
9202
    public _Fields fieldForId(int fieldId) {
9203
      return _Fields.findByThriftId(fieldId);
9204
    }
9205
 
9206
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9207
      org.apache.thrift.protocol.TField field;
9208
      iprot.readStructBegin();
9209
      while (true)
9210
      {
9211
        field = iprot.readFieldBegin();
9212
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9213
          break;
9214
        }
9215
        switch (field.id) {
9216
          case 1: // ITEM_ID
9217
            if (field.type == org.apache.thrift.protocol.TType.I64) {
9218
              this.itemId = iprot.readI64();
9219
              setItemIdIsSet(true);
9220
            } else { 
9221
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9222
            }
9223
            break;
5978 rajveer 9224
          case 2: // SOURCE_ID
9225
            if (field.type == org.apache.thrift.protocol.TType.I64) {
9226
              this.sourceId = iprot.readI64();
9227
              setSourceIdIsSet(true);
9228
            } else { 
9229
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9230
            }
9231
            break;
5945 mandeep.dh 9232
          default:
9233
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9234
        }
9235
        iprot.readFieldEnd();
9236
      }
9237
      iprot.readStructEnd();
9238
      validate();
9239
    }
9240
 
9241
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9242
      validate();
9243
 
9244
      oprot.writeStructBegin(STRUCT_DESC);
9245
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
9246
      oprot.writeI64(this.itemId);
9247
      oprot.writeFieldEnd();
5978 rajveer 9248
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
9249
      oprot.writeI64(this.sourceId);
9250
      oprot.writeFieldEnd();
5945 mandeep.dh 9251
      oprot.writeFieldStop();
9252
      oprot.writeStructEnd();
9253
    }
9254
 
9255
    @Override
9256
    public String toString() {
9257
      StringBuilder sb = new StringBuilder("getItemAvailabilityAtLocation_args(");
9258
      boolean first = true;
9259
 
9260
      sb.append("itemId:");
9261
      sb.append(this.itemId);
9262
      first = false;
5978 rajveer 9263
      if (!first) sb.append(", ");
9264
      sb.append("sourceId:");
9265
      sb.append(this.sourceId);
9266
      first = false;
5945 mandeep.dh 9267
      sb.append(")");
9268
      return sb.toString();
9269
    }
9270
 
9271
    public void validate() throws org.apache.thrift.TException {
9272
      // check for required fields
9273
    }
9274
 
9275
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9276
      try {
9277
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9278
      } catch (org.apache.thrift.TException te) {
9279
        throw new java.io.IOException(te);
9280
      }
9281
    }
9282
 
9283
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9284
      try {
9285
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9286
      } catch (org.apache.thrift.TException te) {
9287
        throw new java.io.IOException(te);
9288
      }
9289
    }
9290
 
9291
  }
9292
 
9293
  public static class getItemAvailabilityAtLocation_result implements org.apache.thrift.TBase<getItemAvailabilityAtLocation_result, getItemAvailabilityAtLocation_result._Fields>, java.io.Serializable, Cloneable   {
9294
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailabilityAtLocation_result");
9295
 
9296
    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);
9297
    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);
9298
 
9299
    private List<Long> success; // required
9300
    private InventoryServiceException isex; // required
9301
 
9302
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9303
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9304
      SUCCESS((short)0, "success"),
9305
      ISEX((short)1, "isex");
9306
 
9307
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9308
 
9309
      static {
9310
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9311
          byName.put(field.getFieldName(), field);
9312
        }
9313
      }
9314
 
9315
      /**
9316
       * Find the _Fields constant that matches fieldId, or null if its not found.
9317
       */
9318
      public static _Fields findByThriftId(int fieldId) {
9319
        switch(fieldId) {
9320
          case 0: // SUCCESS
9321
            return SUCCESS;
9322
          case 1: // ISEX
9323
            return ISEX;
9324
          default:
9325
            return null;
9326
        }
9327
      }
9328
 
9329
      /**
9330
       * Find the _Fields constant that matches fieldId, throwing an exception
9331
       * if it is not found.
9332
       */
9333
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9334
        _Fields fields = findByThriftId(fieldId);
9335
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9336
        return fields;
9337
      }
9338
 
9339
      /**
9340
       * Find the _Fields constant that matches name, or null if its not found.
9341
       */
9342
      public static _Fields findByName(String name) {
9343
        return byName.get(name);
9344
      }
9345
 
9346
      private final short _thriftId;
9347
      private final String _fieldName;
9348
 
9349
      _Fields(short thriftId, String fieldName) {
9350
        _thriftId = thriftId;
9351
        _fieldName = fieldName;
9352
      }
9353
 
9354
      public short getThriftFieldId() {
9355
        return _thriftId;
9356
      }
9357
 
9358
      public String getFieldName() {
9359
        return _fieldName;
9360
      }
9361
    }
9362
 
9363
    // isset id assignments
9364
 
9365
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9366
    static {
9367
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9368
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9369
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9370
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
9371
      tmpMap.put(_Fields.ISEX, new org.apache.thrift.meta_data.FieldMetaData("isex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9372
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9373
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9374
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailabilityAtLocation_result.class, metaDataMap);
9375
    }
9376
 
9377
    public getItemAvailabilityAtLocation_result() {
9378
    }
9379
 
9380
    public getItemAvailabilityAtLocation_result(
9381
      List<Long> success,
9382
      InventoryServiceException isex)
9383
    {
9384
      this();
9385
      this.success = success;
9386
      this.isex = isex;
9387
    }
9388
 
9389
    /**
9390
     * Performs a deep copy on <i>other</i>.
9391
     */
9392
    public getItemAvailabilityAtLocation_result(getItemAvailabilityAtLocation_result other) {
9393
      if (other.isSetSuccess()) {
9394
        List<Long> __this__success = new ArrayList<Long>();
9395
        for (Long other_element : other.success) {
9396
          __this__success.add(other_element);
9397
        }
9398
        this.success = __this__success;
9399
      }
9400
      if (other.isSetIsex()) {
9401
        this.isex = new InventoryServiceException(other.isex);
9402
      }
9403
    }
9404
 
9405
    public getItemAvailabilityAtLocation_result deepCopy() {
9406
      return new getItemAvailabilityAtLocation_result(this);
9407
    }
9408
 
9409
    @Override
9410
    public void clear() {
9411
      this.success = null;
9412
      this.isex = null;
9413
    }
9414
 
9415
    public int getSuccessSize() {
9416
      return (this.success == null) ? 0 : this.success.size();
9417
    }
9418
 
9419
    public java.util.Iterator<Long> getSuccessIterator() {
9420
      return (this.success == null) ? null : this.success.iterator();
9421
    }
9422
 
9423
    public void addToSuccess(long elem) {
9424
      if (this.success == null) {
9425
        this.success = new ArrayList<Long>();
9426
      }
9427
      this.success.add(elem);
9428
    }
9429
 
9430
    public List<Long> getSuccess() {
9431
      return this.success;
9432
    }
9433
 
9434
    public void setSuccess(List<Long> success) {
9435
      this.success = success;
9436
    }
9437
 
9438
    public void unsetSuccess() {
9439
      this.success = null;
9440
    }
9441
 
9442
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9443
    public boolean isSetSuccess() {
9444
      return this.success != null;
9445
    }
9446
 
9447
    public void setSuccessIsSet(boolean value) {
9448
      if (!value) {
9449
        this.success = null;
9450
      }
9451
    }
9452
 
9453
    public InventoryServiceException getIsex() {
9454
      return this.isex;
9455
    }
9456
 
9457
    public void setIsex(InventoryServiceException isex) {
9458
      this.isex = isex;
9459
    }
9460
 
9461
    public void unsetIsex() {
9462
      this.isex = null;
9463
    }
9464
 
9465
    /** Returns true if field isex is set (has been assigned a value) and false otherwise */
9466
    public boolean isSetIsex() {
9467
      return this.isex != null;
9468
    }
9469
 
9470
    public void setIsexIsSet(boolean value) {
9471
      if (!value) {
9472
        this.isex = null;
9473
      }
9474
    }
9475
 
9476
    public void setFieldValue(_Fields field, Object value) {
9477
      switch (field) {
9478
      case SUCCESS:
9479
        if (value == null) {
9480
          unsetSuccess();
9481
        } else {
9482
          setSuccess((List<Long>)value);
9483
        }
9484
        break;
9485
 
9486
      case ISEX:
9487
        if (value == null) {
9488
          unsetIsex();
9489
        } else {
9490
          setIsex((InventoryServiceException)value);
9491
        }
9492
        break;
9493
 
9494
      }
9495
    }
9496
 
9497
    public Object getFieldValue(_Fields field) {
9498
      switch (field) {
9499
      case SUCCESS:
9500
        return getSuccess();
9501
 
9502
      case ISEX:
9503
        return getIsex();
9504
 
9505
      }
9506
      throw new IllegalStateException();
9507
    }
9508
 
9509
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9510
    public boolean isSet(_Fields field) {
9511
      if (field == null) {
9512
        throw new IllegalArgumentException();
9513
      }
9514
 
9515
      switch (field) {
9516
      case SUCCESS:
9517
        return isSetSuccess();
9518
      case ISEX:
9519
        return isSetIsex();
9520
      }
9521
      throw new IllegalStateException();
9522
    }
9523
 
9524
    @Override
9525
    public boolean equals(Object that) {
9526
      if (that == null)
9527
        return false;
9528
      if (that instanceof getItemAvailabilityAtLocation_result)
9529
        return this.equals((getItemAvailabilityAtLocation_result)that);
9530
      return false;
9531
    }
9532
 
9533
    public boolean equals(getItemAvailabilityAtLocation_result that) {
9534
      if (that == null)
9535
        return false;
9536
 
9537
      boolean this_present_success = true && this.isSetSuccess();
9538
      boolean that_present_success = true && that.isSetSuccess();
9539
      if (this_present_success || that_present_success) {
9540
        if (!(this_present_success && that_present_success))
9541
          return false;
9542
        if (!this.success.equals(that.success))
9543
          return false;
9544
      }
9545
 
9546
      boolean this_present_isex = true && this.isSetIsex();
9547
      boolean that_present_isex = true && that.isSetIsex();
9548
      if (this_present_isex || that_present_isex) {
9549
        if (!(this_present_isex && that_present_isex))
9550
          return false;
9551
        if (!this.isex.equals(that.isex))
9552
          return false;
9553
      }
9554
 
9555
      return true;
9556
    }
9557
 
9558
    @Override
9559
    public int hashCode() {
9560
      return 0;
9561
    }
9562
 
9563
    public int compareTo(getItemAvailabilityAtLocation_result other) {
9564
      if (!getClass().equals(other.getClass())) {
9565
        return getClass().getName().compareTo(other.getClass().getName());
9566
      }
9567
 
9568
      int lastComparison = 0;
9569
      getItemAvailabilityAtLocation_result typedOther = (getItemAvailabilityAtLocation_result)other;
9570
 
9571
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
9572
      if (lastComparison != 0) {
9573
        return lastComparison;
9574
      }
9575
      if (isSetSuccess()) {
9576
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9577
        if (lastComparison != 0) {
9578
          return lastComparison;
9579
        }
9580
      }
9581
      lastComparison = Boolean.valueOf(isSetIsex()).compareTo(typedOther.isSetIsex());
9582
      if (lastComparison != 0) {
9583
        return lastComparison;
9584
      }
9585
      if (isSetIsex()) {
9586
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isex, typedOther.isex);
9587
        if (lastComparison != 0) {
9588
          return lastComparison;
9589
        }
9590
      }
9591
      return 0;
9592
    }
9593
 
9594
    public _Fields fieldForId(int fieldId) {
9595
      return _Fields.findByThriftId(fieldId);
9596
    }
9597
 
9598
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9599
      org.apache.thrift.protocol.TField field;
9600
      iprot.readStructBegin();
9601
      while (true)
9602
      {
9603
        field = iprot.readFieldBegin();
9604
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9605
          break;
9606
        }
9607
        switch (field.id) {
9608
          case 0: // SUCCESS
9609
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
9610
              {
9611
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
9612
                this.success = new ArrayList<Long>(_list20.size);
9613
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
9614
                {
9615
                  long _elem22; // required
9616
                  _elem22 = iprot.readI64();
9617
                  this.success.add(_elem22);
9618
                }
9619
                iprot.readListEnd();
9620
              }
9621
            } else { 
9622
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9623
            }
9624
            break;
9625
          case 1: // ISEX
9626
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9627
              this.isex = new InventoryServiceException();
9628
              this.isex.read(iprot);
9629
            } else { 
9630
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9631
            }
9632
            break;
9633
          default:
9634
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9635
        }
9636
        iprot.readFieldEnd();
9637
      }
9638
      iprot.readStructEnd();
9639
      validate();
9640
    }
9641
 
9642
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9643
      oprot.writeStructBegin(STRUCT_DESC);
9644
 
9645
      if (this.isSetSuccess()) {
9646
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9647
        {
9648
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
9649
          for (long _iter23 : this.success)
9650
          {
9651
            oprot.writeI64(_iter23);
9652
          }
9653
          oprot.writeListEnd();
9654
        }
9655
        oprot.writeFieldEnd();
9656
      } else if (this.isSetIsex()) {
9657
        oprot.writeFieldBegin(ISEX_FIELD_DESC);
9658
        this.isex.write(oprot);
9659
        oprot.writeFieldEnd();
9660
      }
9661
      oprot.writeFieldStop();
9662
      oprot.writeStructEnd();
9663
    }
9664
 
9665
    @Override
9666
    public String toString() {
9667
      StringBuilder sb = new StringBuilder("getItemAvailabilityAtLocation_result(");
9668
      boolean first = true;
9669
 
9670
      sb.append("success:");
9671
      if (this.success == null) {
9672
        sb.append("null");
9673
      } else {
9674
        sb.append(this.success);
9675
      }
9676
      first = false;
9677
      if (!first) sb.append(", ");
9678
      sb.append("isex:");
9679
      if (this.isex == null) {
9680
        sb.append("null");
9681
      } else {
9682
        sb.append(this.isex);
9683
      }
9684
      first = false;
9685
      sb.append(")");
9686
      return sb.toString();
9687
    }
9688
 
9689
    public void validate() throws org.apache.thrift.TException {
9690
      // check for required fields
9691
    }
9692
 
9693
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9694
      try {
9695
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9696
      } catch (org.apache.thrift.TException te) {
9697
        throw new java.io.IOException(te);
9698
      }
9699
    }
9700
 
9701
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9702
      try {
9703
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9704
      } catch (org.apache.thrift.TException te) {
9705
        throw new java.io.IOException(te);
9706
      }
9707
    }
9708
 
9709
  }
9710
 
9711
  public static class getAllWarehouses_args implements org.apache.thrift.TBase<getAllWarehouses_args, getAllWarehouses_args._Fields>, java.io.Serializable, Cloneable   {
9712
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllWarehouses_args");
9713
 
9714
    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);
9715
 
9716
    private boolean isActive; // required
9717
 
9718
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9719
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9720
      IS_ACTIVE((short)1, "isActive");
9721
 
9722
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9723
 
9724
      static {
9725
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9726
          byName.put(field.getFieldName(), field);
9727
        }
9728
      }
9729
 
9730
      /**
9731
       * Find the _Fields constant that matches fieldId, or null if its not found.
9732
       */
9733
      public static _Fields findByThriftId(int fieldId) {
9734
        switch(fieldId) {
9735
          case 1: // IS_ACTIVE
9736
            return IS_ACTIVE;
9737
          default:
9738
            return null;
9739
        }
9740
      }
9741
 
9742
      /**
9743
       * Find the _Fields constant that matches fieldId, throwing an exception
9744
       * if it is not found.
9745
       */
9746
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9747
        _Fields fields = findByThriftId(fieldId);
9748
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9749
        return fields;
9750
      }
9751
 
9752
      /**
9753
       * Find the _Fields constant that matches name, or null if its not found.
9754
       */
9755
      public static _Fields findByName(String name) {
9756
        return byName.get(name);
9757
      }
9758
 
9759
      private final short _thriftId;
9760
      private final String _fieldName;
9761
 
9762
      _Fields(short thriftId, String fieldName) {
9763
        _thriftId = thriftId;
9764
        _fieldName = fieldName;
9765
      }
9766
 
9767
      public short getThriftFieldId() {
9768
        return _thriftId;
9769
      }
9770
 
9771
      public String getFieldName() {
9772
        return _fieldName;
9773
      }
9774
    }
9775
 
9776
    // isset id assignments
9777
    private static final int __ISACTIVE_ISSET_ID = 0;
9778
    private BitSet __isset_bit_vector = new BitSet(1);
9779
 
9780
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9781
    static {
9782
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9783
      tmpMap.put(_Fields.IS_ACTIVE, new org.apache.thrift.meta_data.FieldMetaData("isActive", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9784
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
9785
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9786
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllWarehouses_args.class, metaDataMap);
9787
    }
9788
 
9789
    public getAllWarehouses_args() {
9790
    }
9791
 
9792
    public getAllWarehouses_args(
9793
      boolean isActive)
9794
    {
9795
      this();
9796
      this.isActive = isActive;
9797
      setIsActiveIsSet(true);
9798
    }
9799
 
9800
    /**
9801
     * Performs a deep copy on <i>other</i>.
9802
     */
9803
    public getAllWarehouses_args(getAllWarehouses_args other) {
9804
      __isset_bit_vector.clear();
9805
      __isset_bit_vector.or(other.__isset_bit_vector);
9806
      this.isActive = other.isActive;
9807
    }
9808
 
9809
    public getAllWarehouses_args deepCopy() {
9810
      return new getAllWarehouses_args(this);
9811
    }
9812
 
9813
    @Override
9814
    public void clear() {
9815
      setIsActiveIsSet(false);
9816
      this.isActive = false;
9817
    }
9818
 
9819
    public boolean isIsActive() {
9820
      return this.isActive;
9821
    }
9822
 
9823
    public void setIsActive(boolean isActive) {
9824
      this.isActive = isActive;
9825
      setIsActiveIsSet(true);
9826
    }
9827
 
9828
    public void unsetIsActive() {
9829
      __isset_bit_vector.clear(__ISACTIVE_ISSET_ID);
9830
    }
9831
 
9832
    /** Returns true if field isActive is set (has been assigned a value) and false otherwise */
9833
    public boolean isSetIsActive() {
9834
      return __isset_bit_vector.get(__ISACTIVE_ISSET_ID);
9835
    }
9836
 
9837
    public void setIsActiveIsSet(boolean value) {
9838
      __isset_bit_vector.set(__ISACTIVE_ISSET_ID, value);
9839
    }
9840
 
9841
    public void setFieldValue(_Fields field, Object value) {
9842
      switch (field) {
9843
      case IS_ACTIVE:
9844
        if (value == null) {
9845
          unsetIsActive();
9846
        } else {
9847
          setIsActive((Boolean)value);
9848
        }
9849
        break;
9850
 
9851
      }
9852
    }
9853
 
9854
    public Object getFieldValue(_Fields field) {
9855
      switch (field) {
9856
      case IS_ACTIVE:
9857
        return Boolean.valueOf(isIsActive());
9858
 
9859
      }
9860
      throw new IllegalStateException();
9861
    }
9862
 
9863
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9864
    public boolean isSet(_Fields field) {
9865
      if (field == null) {
9866
        throw new IllegalArgumentException();
9867
      }
9868
 
9869
      switch (field) {
9870
      case IS_ACTIVE:
9871
        return isSetIsActive();
9872
      }
9873
      throw new IllegalStateException();
9874
    }
9875
 
9876
    @Override
9877
    public boolean equals(Object that) {
9878
      if (that == null)
9879
        return false;
9880
      if (that instanceof getAllWarehouses_args)
9881
        return this.equals((getAllWarehouses_args)that);
9882
      return false;
9883
    }
9884
 
9885
    public boolean equals(getAllWarehouses_args that) {
9886
      if (that == null)
9887
        return false;
9888
 
9889
      boolean this_present_isActive = true;
9890
      boolean that_present_isActive = true;
9891
      if (this_present_isActive || that_present_isActive) {
9892
        if (!(this_present_isActive && that_present_isActive))
9893
          return false;
9894
        if (this.isActive != that.isActive)
9895
          return false;
9896
      }
9897
 
9898
      return true;
9899
    }
9900
 
9901
    @Override
9902
    public int hashCode() {
9903
      return 0;
9904
    }
9905
 
9906
    public int compareTo(getAllWarehouses_args other) {
9907
      if (!getClass().equals(other.getClass())) {
9908
        return getClass().getName().compareTo(other.getClass().getName());
9909
      }
9910
 
9911
      int lastComparison = 0;
9912
      getAllWarehouses_args typedOther = (getAllWarehouses_args)other;
9913
 
9914
      lastComparison = Boolean.valueOf(isSetIsActive()).compareTo(typedOther.isSetIsActive());
9915
      if (lastComparison != 0) {
9916
        return lastComparison;
9917
      }
9918
      if (isSetIsActive()) {
9919
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isActive, typedOther.isActive);
9920
        if (lastComparison != 0) {
9921
          return lastComparison;
9922
        }
9923
      }
9924
      return 0;
9925
    }
9926
 
9927
    public _Fields fieldForId(int fieldId) {
9928
      return _Fields.findByThriftId(fieldId);
9929
    }
9930
 
9931
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9932
      org.apache.thrift.protocol.TField field;
9933
      iprot.readStructBegin();
9934
      while (true)
9935
      {
9936
        field = iprot.readFieldBegin();
9937
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9938
          break;
9939
        }
9940
        switch (field.id) {
9941
          case 1: // IS_ACTIVE
9942
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
9943
              this.isActive = iprot.readBool();
9944
              setIsActiveIsSet(true);
9945
            } else { 
9946
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9947
            }
9948
            break;
9949
          default:
9950
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9951
        }
9952
        iprot.readFieldEnd();
9953
      }
9954
      iprot.readStructEnd();
9955
      validate();
9956
    }
9957
 
9958
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9959
      validate();
9960
 
9961
      oprot.writeStructBegin(STRUCT_DESC);
9962
      oprot.writeFieldBegin(IS_ACTIVE_FIELD_DESC);
9963
      oprot.writeBool(this.isActive);
9964
      oprot.writeFieldEnd();
9965
      oprot.writeFieldStop();
9966
      oprot.writeStructEnd();
9967
    }
9968
 
9969
    @Override
9970
    public String toString() {
9971
      StringBuilder sb = new StringBuilder("getAllWarehouses_args(");
9972
      boolean first = true;
9973
 
9974
      sb.append("isActive:");
9975
      sb.append(this.isActive);
9976
      first = false;
9977
      sb.append(")");
9978
      return sb.toString();
9979
    }
9980
 
9981
    public void validate() throws org.apache.thrift.TException {
9982
      // check for required fields
9983
    }
9984
 
9985
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9986
      try {
9987
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9988
      } catch (org.apache.thrift.TException te) {
9989
        throw new java.io.IOException(te);
9990
      }
9991
    }
9992
 
9993
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9994
      try {
9995
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
9996
        __isset_bit_vector = new BitSet(1);
9997
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9998
      } catch (org.apache.thrift.TException te) {
9999
        throw new java.io.IOException(te);
10000
      }
10001
    }
10002
 
10003
  }
10004
 
10005
  public static class getAllWarehouses_result implements org.apache.thrift.TBase<getAllWarehouses_result, getAllWarehouses_result._Fields>, java.io.Serializable, Cloneable   {
10006
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllWarehouses_result");
10007
 
10008
    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);
10009
    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);
10010
 
10011
    private List<Warehouse> success; // required
10012
    private InventoryServiceException cex; // required
10013
 
10014
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10015
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10016
      SUCCESS((short)0, "success"),
10017
      CEX((short)1, "cex");
10018
 
10019
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10020
 
10021
      static {
10022
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10023
          byName.put(field.getFieldName(), field);
10024
        }
10025
      }
10026
 
10027
      /**
10028
       * Find the _Fields constant that matches fieldId, or null if its not found.
10029
       */
10030
      public static _Fields findByThriftId(int fieldId) {
10031
        switch(fieldId) {
10032
          case 0: // SUCCESS
10033
            return SUCCESS;
10034
          case 1: // CEX
10035
            return CEX;
10036
          default:
10037
            return null;
10038
        }
10039
      }
10040
 
10041
      /**
10042
       * Find the _Fields constant that matches fieldId, throwing an exception
10043
       * if it is not found.
10044
       */
10045
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10046
        _Fields fields = findByThriftId(fieldId);
10047
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10048
        return fields;
10049
      }
10050
 
10051
      /**
10052
       * Find the _Fields constant that matches name, or null if its not found.
10053
       */
10054
      public static _Fields findByName(String name) {
10055
        return byName.get(name);
10056
      }
10057
 
10058
      private final short _thriftId;
10059
      private final String _fieldName;
10060
 
10061
      _Fields(short thriftId, String fieldName) {
10062
        _thriftId = thriftId;
10063
        _fieldName = fieldName;
10064
      }
10065
 
10066
      public short getThriftFieldId() {
10067
        return _thriftId;
10068
      }
10069
 
10070
      public String getFieldName() {
10071
        return _fieldName;
10072
      }
10073
    }
10074
 
10075
    // isset id assignments
10076
 
10077
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10078
    static {
10079
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10080
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10081
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
10082
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
10083
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10084
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
10085
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10086
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllWarehouses_result.class, metaDataMap);
10087
    }
10088
 
10089
    public getAllWarehouses_result() {
10090
    }
10091
 
10092
    public getAllWarehouses_result(
10093
      List<Warehouse> success,
10094
      InventoryServiceException cex)
10095
    {
10096
      this();
10097
      this.success = success;
10098
      this.cex = cex;
10099
    }
10100
 
10101
    /**
10102
     * Performs a deep copy on <i>other</i>.
10103
     */
10104
    public getAllWarehouses_result(getAllWarehouses_result other) {
10105
      if (other.isSetSuccess()) {
10106
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
10107
        for (Warehouse other_element : other.success) {
10108
          __this__success.add(new Warehouse(other_element));
10109
        }
10110
        this.success = __this__success;
10111
      }
10112
      if (other.isSetCex()) {
10113
        this.cex = new InventoryServiceException(other.cex);
10114
      }
10115
    }
10116
 
10117
    public getAllWarehouses_result deepCopy() {
10118
      return new getAllWarehouses_result(this);
10119
    }
10120
 
10121
    @Override
10122
    public void clear() {
10123
      this.success = null;
10124
      this.cex = null;
10125
    }
10126
 
10127
    public int getSuccessSize() {
10128
      return (this.success == null) ? 0 : this.success.size();
10129
    }
10130
 
10131
    public java.util.Iterator<Warehouse> getSuccessIterator() {
10132
      return (this.success == null) ? null : this.success.iterator();
10133
    }
10134
 
10135
    public void addToSuccess(Warehouse elem) {
10136
      if (this.success == null) {
10137
        this.success = new ArrayList<Warehouse>();
10138
      }
10139
      this.success.add(elem);
10140
    }
10141
 
10142
    public List<Warehouse> getSuccess() {
10143
      return this.success;
10144
    }
10145
 
10146
    public void setSuccess(List<Warehouse> success) {
10147
      this.success = success;
10148
    }
10149
 
10150
    public void unsetSuccess() {
10151
      this.success = null;
10152
    }
10153
 
10154
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
10155
    public boolean isSetSuccess() {
10156
      return this.success != null;
10157
    }
10158
 
10159
    public void setSuccessIsSet(boolean value) {
10160
      if (!value) {
10161
        this.success = null;
10162
      }
10163
    }
10164
 
10165
    public InventoryServiceException getCex() {
10166
      return this.cex;
10167
    }
10168
 
10169
    public void setCex(InventoryServiceException cex) {
10170
      this.cex = cex;
10171
    }
10172
 
10173
    public void unsetCex() {
10174
      this.cex = null;
10175
    }
10176
 
10177
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
10178
    public boolean isSetCex() {
10179
      return this.cex != null;
10180
    }
10181
 
10182
    public void setCexIsSet(boolean value) {
10183
      if (!value) {
10184
        this.cex = null;
10185
      }
10186
    }
10187
 
10188
    public void setFieldValue(_Fields field, Object value) {
10189
      switch (field) {
10190
      case SUCCESS:
10191
        if (value == null) {
10192
          unsetSuccess();
10193
        } else {
10194
          setSuccess((List<Warehouse>)value);
10195
        }
10196
        break;
10197
 
10198
      case CEX:
10199
        if (value == null) {
10200
          unsetCex();
10201
        } else {
10202
          setCex((InventoryServiceException)value);
10203
        }
10204
        break;
10205
 
10206
      }
10207
    }
10208
 
10209
    public Object getFieldValue(_Fields field) {
10210
      switch (field) {
10211
      case SUCCESS:
10212
        return getSuccess();
10213
 
10214
      case CEX:
10215
        return getCex();
10216
 
10217
      }
10218
      throw new IllegalStateException();
10219
    }
10220
 
10221
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10222
    public boolean isSet(_Fields field) {
10223
      if (field == null) {
10224
        throw new IllegalArgumentException();
10225
      }
10226
 
10227
      switch (field) {
10228
      case SUCCESS:
10229
        return isSetSuccess();
10230
      case CEX:
10231
        return isSetCex();
10232
      }
10233
      throw new IllegalStateException();
10234
    }
10235
 
10236
    @Override
10237
    public boolean equals(Object that) {
10238
      if (that == null)
10239
        return false;
10240
      if (that instanceof getAllWarehouses_result)
10241
        return this.equals((getAllWarehouses_result)that);
10242
      return false;
10243
    }
10244
 
10245
    public boolean equals(getAllWarehouses_result that) {
10246
      if (that == null)
10247
        return false;
10248
 
10249
      boolean this_present_success = true && this.isSetSuccess();
10250
      boolean that_present_success = true && that.isSetSuccess();
10251
      if (this_present_success || that_present_success) {
10252
        if (!(this_present_success && that_present_success))
10253
          return false;
10254
        if (!this.success.equals(that.success))
10255
          return false;
10256
      }
10257
 
10258
      boolean this_present_cex = true && this.isSetCex();
10259
      boolean that_present_cex = true && that.isSetCex();
10260
      if (this_present_cex || that_present_cex) {
10261
        if (!(this_present_cex && that_present_cex))
10262
          return false;
10263
        if (!this.cex.equals(that.cex))
10264
          return false;
10265
      }
10266
 
10267
      return true;
10268
    }
10269
 
10270
    @Override
10271
    public int hashCode() {
10272
      return 0;
10273
    }
10274
 
10275
    public int compareTo(getAllWarehouses_result other) {
10276
      if (!getClass().equals(other.getClass())) {
10277
        return getClass().getName().compareTo(other.getClass().getName());
10278
      }
10279
 
10280
      int lastComparison = 0;
10281
      getAllWarehouses_result typedOther = (getAllWarehouses_result)other;
10282
 
10283
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10284
      if (lastComparison != 0) {
10285
        return lastComparison;
10286
      }
10287
      if (isSetSuccess()) {
10288
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10289
        if (lastComparison != 0) {
10290
          return lastComparison;
10291
        }
10292
      }
10293
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
10294
      if (lastComparison != 0) {
10295
        return lastComparison;
10296
      }
10297
      if (isSetCex()) {
10298
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
10299
        if (lastComparison != 0) {
10300
          return lastComparison;
10301
        }
10302
      }
10303
      return 0;
10304
    }
10305
 
10306
    public _Fields fieldForId(int fieldId) {
10307
      return _Fields.findByThriftId(fieldId);
10308
    }
10309
 
10310
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10311
      org.apache.thrift.protocol.TField field;
10312
      iprot.readStructBegin();
10313
      while (true)
10314
      {
10315
        field = iprot.readFieldBegin();
10316
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10317
          break;
10318
        }
10319
        switch (field.id) {
10320
          case 0: // SUCCESS
10321
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
10322
              {
10323
                org.apache.thrift.protocol.TList _list24 = iprot.readListBegin();
10324
                this.success = new ArrayList<Warehouse>(_list24.size);
10325
                for (int _i25 = 0; _i25 < _list24.size; ++_i25)
10326
                {
10327
                  Warehouse _elem26; // required
10328
                  _elem26 = new Warehouse();
10329
                  _elem26.read(iprot);
10330
                  this.success.add(_elem26);
10331
                }
10332
                iprot.readListEnd();
10333
              }
10334
            } else { 
10335
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10336
            }
10337
            break;
10338
          case 1: // CEX
10339
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10340
              this.cex = new InventoryServiceException();
10341
              this.cex.read(iprot);
10342
            } else { 
10343
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10344
            }
10345
            break;
10346
          default:
10347
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10348
        }
10349
        iprot.readFieldEnd();
10350
      }
10351
      iprot.readStructEnd();
10352
      validate();
10353
    }
10354
 
10355
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10356
      oprot.writeStructBegin(STRUCT_DESC);
10357
 
10358
      if (this.isSetSuccess()) {
10359
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10360
        {
10361
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
10362
          for (Warehouse _iter27 : this.success)
10363
          {
10364
            _iter27.write(oprot);
10365
          }
10366
          oprot.writeListEnd();
10367
        }
10368
        oprot.writeFieldEnd();
10369
      } else if (this.isSetCex()) {
10370
        oprot.writeFieldBegin(CEX_FIELD_DESC);
10371
        this.cex.write(oprot);
10372
        oprot.writeFieldEnd();
10373
      }
10374
      oprot.writeFieldStop();
10375
      oprot.writeStructEnd();
10376
    }
10377
 
10378
    @Override
10379
    public String toString() {
10380
      StringBuilder sb = new StringBuilder("getAllWarehouses_result(");
10381
      boolean first = true;
10382
 
10383
      sb.append("success:");
10384
      if (this.success == null) {
10385
        sb.append("null");
10386
      } else {
10387
        sb.append(this.success);
10388
      }
10389
      first = false;
10390
      if (!first) sb.append(", ");
10391
      sb.append("cex:");
10392
      if (this.cex == null) {
10393
        sb.append("null");
10394
      } else {
10395
        sb.append(this.cex);
10396
      }
10397
      first = false;
10398
      sb.append(")");
10399
      return sb.toString();
10400
    }
10401
 
10402
    public void validate() throws org.apache.thrift.TException {
10403
      // check for required fields
10404
    }
10405
 
10406
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10407
      try {
10408
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10409
      } catch (org.apache.thrift.TException te) {
10410
        throw new java.io.IOException(te);
10411
      }
10412
    }
10413
 
10414
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10415
      try {
10416
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10417
      } catch (org.apache.thrift.TException te) {
10418
        throw new java.io.IOException(te);
10419
      }
10420
    }
10421
 
10422
  }
10423
 
10424
  public static class getWarehouse_args implements org.apache.thrift.TBase<getWarehouse_args, getWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
10425
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouse_args");
10426
 
10427
    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);
10428
 
10429
    private long warehouse_id; // required
10430
 
10431
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10432
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10433
      WAREHOUSE_ID((short)1, "warehouse_id");
10434
 
10435
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10436
 
10437
      static {
10438
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10439
          byName.put(field.getFieldName(), field);
10440
        }
10441
      }
10442
 
10443
      /**
10444
       * Find the _Fields constant that matches fieldId, or null if its not found.
10445
       */
10446
      public static _Fields findByThriftId(int fieldId) {
10447
        switch(fieldId) {
10448
          case 1: // WAREHOUSE_ID
10449
            return WAREHOUSE_ID;
10450
          default:
10451
            return null;
10452
        }
10453
      }
10454
 
10455
      /**
10456
       * Find the _Fields constant that matches fieldId, throwing an exception
10457
       * if it is not found.
10458
       */
10459
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10460
        _Fields fields = findByThriftId(fieldId);
10461
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10462
        return fields;
10463
      }
10464
 
10465
      /**
10466
       * Find the _Fields constant that matches name, or null if its not found.
10467
       */
10468
      public static _Fields findByName(String name) {
10469
        return byName.get(name);
10470
      }
10471
 
10472
      private final short _thriftId;
10473
      private final String _fieldName;
10474
 
10475
      _Fields(short thriftId, String fieldName) {
10476
        _thriftId = thriftId;
10477
        _fieldName = fieldName;
10478
      }
10479
 
10480
      public short getThriftFieldId() {
10481
        return _thriftId;
10482
      }
10483
 
10484
      public String getFieldName() {
10485
        return _fieldName;
10486
      }
10487
    }
10488
 
10489
    // isset id assignments
10490
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
10491
    private BitSet __isset_bit_vector = new BitSet(1);
10492
 
10493
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10494
    static {
10495
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10496
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10497
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10498
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10499
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouse_args.class, metaDataMap);
10500
    }
10501
 
10502
    public getWarehouse_args() {
10503
    }
10504
 
10505
    public getWarehouse_args(
10506
      long warehouse_id)
10507
    {
10508
      this();
10509
      this.warehouse_id = warehouse_id;
10510
      setWarehouse_idIsSet(true);
10511
    }
10512
 
10513
    /**
10514
     * Performs a deep copy on <i>other</i>.
10515
     */
10516
    public getWarehouse_args(getWarehouse_args other) {
10517
      __isset_bit_vector.clear();
10518
      __isset_bit_vector.or(other.__isset_bit_vector);
10519
      this.warehouse_id = other.warehouse_id;
10520
    }
10521
 
10522
    public getWarehouse_args deepCopy() {
10523
      return new getWarehouse_args(this);
10524
    }
10525
 
10526
    @Override
10527
    public void clear() {
10528
      setWarehouse_idIsSet(false);
10529
      this.warehouse_id = 0;
10530
    }
10531
 
10532
    public long getWarehouse_id() {
10533
      return this.warehouse_id;
10534
    }
10535
 
10536
    public void setWarehouse_id(long warehouse_id) {
10537
      this.warehouse_id = warehouse_id;
10538
      setWarehouse_idIsSet(true);
10539
    }
10540
 
10541
    public void unsetWarehouse_id() {
10542
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
10543
    }
10544
 
10545
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
10546
    public boolean isSetWarehouse_id() {
10547
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
10548
    }
10549
 
10550
    public void setWarehouse_idIsSet(boolean value) {
10551
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
10552
    }
10553
 
10554
    public void setFieldValue(_Fields field, Object value) {
10555
      switch (field) {
10556
      case WAREHOUSE_ID:
10557
        if (value == null) {
10558
          unsetWarehouse_id();
10559
        } else {
10560
          setWarehouse_id((Long)value);
10561
        }
10562
        break;
10563
 
10564
      }
10565
    }
10566
 
10567
    public Object getFieldValue(_Fields field) {
10568
      switch (field) {
10569
      case WAREHOUSE_ID:
10570
        return Long.valueOf(getWarehouse_id());
10571
 
10572
      }
10573
      throw new IllegalStateException();
10574
    }
10575
 
10576
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10577
    public boolean isSet(_Fields field) {
10578
      if (field == null) {
10579
        throw new IllegalArgumentException();
10580
      }
10581
 
10582
      switch (field) {
10583
      case WAREHOUSE_ID:
10584
        return isSetWarehouse_id();
10585
      }
10586
      throw new IllegalStateException();
10587
    }
10588
 
10589
    @Override
10590
    public boolean equals(Object that) {
10591
      if (that == null)
10592
        return false;
10593
      if (that instanceof getWarehouse_args)
10594
        return this.equals((getWarehouse_args)that);
10595
      return false;
10596
    }
10597
 
10598
    public boolean equals(getWarehouse_args that) {
10599
      if (that == null)
10600
        return false;
10601
 
10602
      boolean this_present_warehouse_id = true;
10603
      boolean that_present_warehouse_id = true;
10604
      if (this_present_warehouse_id || that_present_warehouse_id) {
10605
        if (!(this_present_warehouse_id && that_present_warehouse_id))
10606
          return false;
10607
        if (this.warehouse_id != that.warehouse_id)
10608
          return false;
10609
      }
10610
 
10611
      return true;
10612
    }
10613
 
10614
    @Override
10615
    public int hashCode() {
10616
      return 0;
10617
    }
10618
 
10619
    public int compareTo(getWarehouse_args other) {
10620
      if (!getClass().equals(other.getClass())) {
10621
        return getClass().getName().compareTo(other.getClass().getName());
10622
      }
10623
 
10624
      int lastComparison = 0;
10625
      getWarehouse_args typedOther = (getWarehouse_args)other;
10626
 
10627
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
10628
      if (lastComparison != 0) {
10629
        return lastComparison;
10630
      }
10631
      if (isSetWarehouse_id()) {
10632
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
10633
        if (lastComparison != 0) {
10634
          return lastComparison;
10635
        }
10636
      }
10637
      return 0;
10638
    }
10639
 
10640
    public _Fields fieldForId(int fieldId) {
10641
      return _Fields.findByThriftId(fieldId);
10642
    }
10643
 
10644
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10645
      org.apache.thrift.protocol.TField field;
10646
      iprot.readStructBegin();
10647
      while (true)
10648
      {
10649
        field = iprot.readFieldBegin();
10650
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10651
          break;
10652
        }
10653
        switch (field.id) {
10654
          case 1: // WAREHOUSE_ID
10655
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10656
              this.warehouse_id = iprot.readI64();
10657
              setWarehouse_idIsSet(true);
10658
            } else { 
10659
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10660
            }
10661
            break;
10662
          default:
10663
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10664
        }
10665
        iprot.readFieldEnd();
10666
      }
10667
      iprot.readStructEnd();
10668
      validate();
10669
    }
10670
 
10671
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10672
      validate();
10673
 
10674
      oprot.writeStructBegin(STRUCT_DESC);
10675
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
10676
      oprot.writeI64(this.warehouse_id);
10677
      oprot.writeFieldEnd();
10678
      oprot.writeFieldStop();
10679
      oprot.writeStructEnd();
10680
    }
10681
 
10682
    @Override
10683
    public String toString() {
10684
      StringBuilder sb = new StringBuilder("getWarehouse_args(");
10685
      boolean first = true;
10686
 
10687
      sb.append("warehouse_id:");
10688
      sb.append(this.warehouse_id);
10689
      first = false;
10690
      sb.append(")");
10691
      return sb.toString();
10692
    }
10693
 
10694
    public void validate() throws org.apache.thrift.TException {
10695
      // check for required fields
10696
    }
10697
 
10698
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10699
      try {
10700
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10701
      } catch (org.apache.thrift.TException te) {
10702
        throw new java.io.IOException(te);
10703
      }
10704
    }
10705
 
10706
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10707
      try {
10708
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
10709
        __isset_bit_vector = new BitSet(1);
10710
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10711
      } catch (org.apache.thrift.TException te) {
10712
        throw new java.io.IOException(te);
10713
      }
10714
    }
10715
 
10716
  }
10717
 
10718
  public static class getWarehouse_result implements org.apache.thrift.TBase<getWarehouse_result, getWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
10719
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouse_result");
10720
 
10721
    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);
10722
    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);
10723
 
10724
    private Warehouse success; // required
10725
    private InventoryServiceException cex; // required
10726
 
10727
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10728
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10729
      SUCCESS((short)0, "success"),
10730
      CEX((short)1, "cex");
10731
 
10732
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10733
 
10734
      static {
10735
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10736
          byName.put(field.getFieldName(), field);
10737
        }
10738
      }
10739
 
10740
      /**
10741
       * Find the _Fields constant that matches fieldId, or null if its not found.
10742
       */
10743
      public static _Fields findByThriftId(int fieldId) {
10744
        switch(fieldId) {
10745
          case 0: // SUCCESS
10746
            return SUCCESS;
10747
          case 1: // CEX
10748
            return CEX;
10749
          default:
10750
            return null;
10751
        }
10752
      }
10753
 
10754
      /**
10755
       * Find the _Fields constant that matches fieldId, throwing an exception
10756
       * if it is not found.
10757
       */
10758
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10759
        _Fields fields = findByThriftId(fieldId);
10760
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10761
        return fields;
10762
      }
10763
 
10764
      /**
10765
       * Find the _Fields constant that matches name, or null if its not found.
10766
       */
10767
      public static _Fields findByName(String name) {
10768
        return byName.get(name);
10769
      }
10770
 
10771
      private final short _thriftId;
10772
      private final String _fieldName;
10773
 
10774
      _Fields(short thriftId, String fieldName) {
10775
        _thriftId = thriftId;
10776
        _fieldName = fieldName;
10777
      }
10778
 
10779
      public short getThriftFieldId() {
10780
        return _thriftId;
10781
      }
10782
 
10783
      public String getFieldName() {
10784
        return _fieldName;
10785
      }
10786
    }
10787
 
10788
    // isset id assignments
10789
 
10790
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10791
    static {
10792
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10793
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10794
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class)));
10795
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10796
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
10797
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10798
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouse_result.class, metaDataMap);
10799
    }
10800
 
10801
    public getWarehouse_result() {
10802
    }
10803
 
10804
    public getWarehouse_result(
10805
      Warehouse success,
10806
      InventoryServiceException cex)
10807
    {
10808
      this();
10809
      this.success = success;
10810
      this.cex = cex;
10811
    }
10812
 
10813
    /**
10814
     * Performs a deep copy on <i>other</i>.
10815
     */
10816
    public getWarehouse_result(getWarehouse_result other) {
10817
      if (other.isSetSuccess()) {
10818
        this.success = new Warehouse(other.success);
10819
      }
10820
      if (other.isSetCex()) {
10821
        this.cex = new InventoryServiceException(other.cex);
10822
      }
10823
    }
10824
 
10825
    public getWarehouse_result deepCopy() {
10826
      return new getWarehouse_result(this);
10827
    }
10828
 
10829
    @Override
10830
    public void clear() {
10831
      this.success = null;
10832
      this.cex = null;
10833
    }
10834
 
10835
    public Warehouse getSuccess() {
10836
      return this.success;
10837
    }
10838
 
10839
    public void setSuccess(Warehouse success) {
10840
      this.success = success;
10841
    }
10842
 
10843
    public void unsetSuccess() {
10844
      this.success = null;
10845
    }
10846
 
10847
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
10848
    public boolean isSetSuccess() {
10849
      return this.success != null;
10850
    }
10851
 
10852
    public void setSuccessIsSet(boolean value) {
10853
      if (!value) {
10854
        this.success = null;
10855
      }
10856
    }
10857
 
10858
    public InventoryServiceException getCex() {
10859
      return this.cex;
10860
    }
10861
 
10862
    public void setCex(InventoryServiceException cex) {
10863
      this.cex = cex;
10864
    }
10865
 
10866
    public void unsetCex() {
10867
      this.cex = null;
10868
    }
10869
 
10870
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
10871
    public boolean isSetCex() {
10872
      return this.cex != null;
10873
    }
10874
 
10875
    public void setCexIsSet(boolean value) {
10876
      if (!value) {
10877
        this.cex = null;
10878
      }
10879
    }
10880
 
10881
    public void setFieldValue(_Fields field, Object value) {
10882
      switch (field) {
10883
      case SUCCESS:
10884
        if (value == null) {
10885
          unsetSuccess();
10886
        } else {
10887
          setSuccess((Warehouse)value);
10888
        }
10889
        break;
10890
 
10891
      case CEX:
10892
        if (value == null) {
10893
          unsetCex();
10894
        } else {
10895
          setCex((InventoryServiceException)value);
10896
        }
10897
        break;
10898
 
10899
      }
10900
    }
10901
 
10902
    public Object getFieldValue(_Fields field) {
10903
      switch (field) {
10904
      case SUCCESS:
10905
        return getSuccess();
10906
 
10907
      case CEX:
10908
        return getCex();
10909
 
10910
      }
10911
      throw new IllegalStateException();
10912
    }
10913
 
10914
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10915
    public boolean isSet(_Fields field) {
10916
      if (field == null) {
10917
        throw new IllegalArgumentException();
10918
      }
10919
 
10920
      switch (field) {
10921
      case SUCCESS:
10922
        return isSetSuccess();
10923
      case CEX:
10924
        return isSetCex();
10925
      }
10926
      throw new IllegalStateException();
10927
    }
10928
 
10929
    @Override
10930
    public boolean equals(Object that) {
10931
      if (that == null)
10932
        return false;
10933
      if (that instanceof getWarehouse_result)
10934
        return this.equals((getWarehouse_result)that);
10935
      return false;
10936
    }
10937
 
10938
    public boolean equals(getWarehouse_result that) {
10939
      if (that == null)
10940
        return false;
10941
 
10942
      boolean this_present_success = true && this.isSetSuccess();
10943
      boolean that_present_success = true && that.isSetSuccess();
10944
      if (this_present_success || that_present_success) {
10945
        if (!(this_present_success && that_present_success))
10946
          return false;
10947
        if (!this.success.equals(that.success))
10948
          return false;
10949
      }
10950
 
10951
      boolean this_present_cex = true && this.isSetCex();
10952
      boolean that_present_cex = true && that.isSetCex();
10953
      if (this_present_cex || that_present_cex) {
10954
        if (!(this_present_cex && that_present_cex))
10955
          return false;
10956
        if (!this.cex.equals(that.cex))
10957
          return false;
10958
      }
10959
 
10960
      return true;
10961
    }
10962
 
10963
    @Override
10964
    public int hashCode() {
10965
      return 0;
10966
    }
10967
 
10968
    public int compareTo(getWarehouse_result other) {
10969
      if (!getClass().equals(other.getClass())) {
10970
        return getClass().getName().compareTo(other.getClass().getName());
10971
      }
10972
 
10973
      int lastComparison = 0;
10974
      getWarehouse_result typedOther = (getWarehouse_result)other;
10975
 
10976
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10977
      if (lastComparison != 0) {
10978
        return lastComparison;
10979
      }
10980
      if (isSetSuccess()) {
10981
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10982
        if (lastComparison != 0) {
10983
          return lastComparison;
10984
        }
10985
      }
10986
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
10987
      if (lastComparison != 0) {
10988
        return lastComparison;
10989
      }
10990
      if (isSetCex()) {
10991
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
10992
        if (lastComparison != 0) {
10993
          return lastComparison;
10994
        }
10995
      }
10996
      return 0;
10997
    }
10998
 
10999
    public _Fields fieldForId(int fieldId) {
11000
      return _Fields.findByThriftId(fieldId);
11001
    }
11002
 
11003
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11004
      org.apache.thrift.protocol.TField field;
11005
      iprot.readStructBegin();
11006
      while (true)
11007
      {
11008
        field = iprot.readFieldBegin();
11009
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11010
          break;
11011
        }
11012
        switch (field.id) {
11013
          case 0: // SUCCESS
11014
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11015
              this.success = new Warehouse();
11016
              this.success.read(iprot);
11017
            } else { 
11018
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11019
            }
11020
            break;
11021
          case 1: // CEX
11022
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11023
              this.cex = new InventoryServiceException();
11024
              this.cex.read(iprot);
11025
            } else { 
11026
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11027
            }
11028
            break;
11029
          default:
11030
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11031
        }
11032
        iprot.readFieldEnd();
11033
      }
11034
      iprot.readStructEnd();
11035
      validate();
11036
    }
11037
 
11038
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11039
      oprot.writeStructBegin(STRUCT_DESC);
11040
 
11041
      if (this.isSetSuccess()) {
11042
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11043
        this.success.write(oprot);
11044
        oprot.writeFieldEnd();
11045
      } else if (this.isSetCex()) {
11046
        oprot.writeFieldBegin(CEX_FIELD_DESC);
11047
        this.cex.write(oprot);
11048
        oprot.writeFieldEnd();
11049
      }
11050
      oprot.writeFieldStop();
11051
      oprot.writeStructEnd();
11052
    }
11053
 
11054
    @Override
11055
    public String toString() {
11056
      StringBuilder sb = new StringBuilder("getWarehouse_result(");
11057
      boolean first = true;
11058
 
11059
      sb.append("success:");
11060
      if (this.success == null) {
11061
        sb.append("null");
11062
      } else {
11063
        sb.append(this.success);
11064
      }
11065
      first = false;
11066
      if (!first) sb.append(", ");
11067
      sb.append("cex:");
11068
      if (this.cex == null) {
11069
        sb.append("null");
11070
      } else {
11071
        sb.append(this.cex);
11072
      }
11073
      first = false;
11074
      sb.append(")");
11075
      return sb.toString();
11076
    }
11077
 
11078
    public void validate() throws org.apache.thrift.TException {
11079
      // check for required fields
11080
    }
11081
 
11082
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11083
      try {
11084
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11085
      } catch (org.apache.thrift.TException te) {
11086
        throw new java.io.IOException(te);
11087
      }
11088
    }
11089
 
11090
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11091
      try {
11092
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11093
      } catch (org.apache.thrift.TException te) {
11094
        throw new java.io.IOException(te);
11095
      }
11096
    }
11097
 
11098
  }
11099
 
11100
  public static class getAllItemsForWarehouse_args implements org.apache.thrift.TBase<getAllItemsForWarehouse_args, getAllItemsForWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
11101
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemsForWarehouse_args");
11102
 
11103
    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);
11104
 
11105
    private long warehouse_id; // required
11106
 
11107
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11108
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11109
      WAREHOUSE_ID((short)1, "warehouse_id");
11110
 
11111
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11112
 
11113
      static {
11114
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11115
          byName.put(field.getFieldName(), field);
11116
        }
11117
      }
11118
 
11119
      /**
11120
       * Find the _Fields constant that matches fieldId, or null if its not found.
11121
       */
11122
      public static _Fields findByThriftId(int fieldId) {
11123
        switch(fieldId) {
11124
          case 1: // WAREHOUSE_ID
11125
            return WAREHOUSE_ID;
11126
          default:
11127
            return null;
11128
        }
11129
      }
11130
 
11131
      /**
11132
       * Find the _Fields constant that matches fieldId, throwing an exception
11133
       * if it is not found.
11134
       */
11135
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11136
        _Fields fields = findByThriftId(fieldId);
11137
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11138
        return fields;
11139
      }
11140
 
11141
      /**
11142
       * Find the _Fields constant that matches name, or null if its not found.
11143
       */
11144
      public static _Fields findByName(String name) {
11145
        return byName.get(name);
11146
      }
11147
 
11148
      private final short _thriftId;
11149
      private final String _fieldName;
11150
 
11151
      _Fields(short thriftId, String fieldName) {
11152
        _thriftId = thriftId;
11153
        _fieldName = fieldName;
11154
      }
11155
 
11156
      public short getThriftFieldId() {
11157
        return _thriftId;
11158
      }
11159
 
11160
      public String getFieldName() {
11161
        return _fieldName;
11162
      }
11163
    }
11164
 
11165
    // isset id assignments
11166
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
11167
    private BitSet __isset_bit_vector = new BitSet(1);
11168
 
11169
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11170
    static {
11171
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11172
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11173
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11174
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11175
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemsForWarehouse_args.class, metaDataMap);
11176
    }
11177
 
11178
    public getAllItemsForWarehouse_args() {
11179
    }
11180
 
11181
    public getAllItemsForWarehouse_args(
11182
      long warehouse_id)
11183
    {
11184
      this();
11185
      this.warehouse_id = warehouse_id;
11186
      setWarehouse_idIsSet(true);
11187
    }
11188
 
11189
    /**
11190
     * Performs a deep copy on <i>other</i>.
11191
     */
11192
    public getAllItemsForWarehouse_args(getAllItemsForWarehouse_args other) {
11193
      __isset_bit_vector.clear();
11194
      __isset_bit_vector.or(other.__isset_bit_vector);
11195
      this.warehouse_id = other.warehouse_id;
11196
    }
11197
 
11198
    public getAllItemsForWarehouse_args deepCopy() {
11199
      return new getAllItemsForWarehouse_args(this);
11200
    }
11201
 
11202
    @Override
11203
    public void clear() {
11204
      setWarehouse_idIsSet(false);
11205
      this.warehouse_id = 0;
11206
    }
11207
 
11208
    public long getWarehouse_id() {
11209
      return this.warehouse_id;
11210
    }
11211
 
11212
    public void setWarehouse_id(long warehouse_id) {
11213
      this.warehouse_id = warehouse_id;
11214
      setWarehouse_idIsSet(true);
11215
    }
11216
 
11217
    public void unsetWarehouse_id() {
11218
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
11219
    }
11220
 
11221
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
11222
    public boolean isSetWarehouse_id() {
11223
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
11224
    }
11225
 
11226
    public void setWarehouse_idIsSet(boolean value) {
11227
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
11228
    }
11229
 
11230
    public void setFieldValue(_Fields field, Object value) {
11231
      switch (field) {
11232
      case WAREHOUSE_ID:
11233
        if (value == null) {
11234
          unsetWarehouse_id();
11235
        } else {
11236
          setWarehouse_id((Long)value);
11237
        }
11238
        break;
11239
 
11240
      }
11241
    }
11242
 
11243
    public Object getFieldValue(_Fields field) {
11244
      switch (field) {
11245
      case WAREHOUSE_ID:
11246
        return Long.valueOf(getWarehouse_id());
11247
 
11248
      }
11249
      throw new IllegalStateException();
11250
    }
11251
 
11252
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11253
    public boolean isSet(_Fields field) {
11254
      if (field == null) {
11255
        throw new IllegalArgumentException();
11256
      }
11257
 
11258
      switch (field) {
11259
      case WAREHOUSE_ID:
11260
        return isSetWarehouse_id();
11261
      }
11262
      throw new IllegalStateException();
11263
    }
11264
 
11265
    @Override
11266
    public boolean equals(Object that) {
11267
      if (that == null)
11268
        return false;
11269
      if (that instanceof getAllItemsForWarehouse_args)
11270
        return this.equals((getAllItemsForWarehouse_args)that);
11271
      return false;
11272
    }
11273
 
11274
    public boolean equals(getAllItemsForWarehouse_args that) {
11275
      if (that == null)
11276
        return false;
11277
 
11278
      boolean this_present_warehouse_id = true;
11279
      boolean that_present_warehouse_id = true;
11280
      if (this_present_warehouse_id || that_present_warehouse_id) {
11281
        if (!(this_present_warehouse_id && that_present_warehouse_id))
11282
          return false;
11283
        if (this.warehouse_id != that.warehouse_id)
11284
          return false;
11285
      }
11286
 
11287
      return true;
11288
    }
11289
 
11290
    @Override
11291
    public int hashCode() {
11292
      return 0;
11293
    }
11294
 
11295
    public int compareTo(getAllItemsForWarehouse_args other) {
11296
      if (!getClass().equals(other.getClass())) {
11297
        return getClass().getName().compareTo(other.getClass().getName());
11298
      }
11299
 
11300
      int lastComparison = 0;
11301
      getAllItemsForWarehouse_args typedOther = (getAllItemsForWarehouse_args)other;
11302
 
11303
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
11304
      if (lastComparison != 0) {
11305
        return lastComparison;
11306
      }
11307
      if (isSetWarehouse_id()) {
11308
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
11309
        if (lastComparison != 0) {
11310
          return lastComparison;
11311
        }
11312
      }
11313
      return 0;
11314
    }
11315
 
11316
    public _Fields fieldForId(int fieldId) {
11317
      return _Fields.findByThriftId(fieldId);
11318
    }
11319
 
11320
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11321
      org.apache.thrift.protocol.TField field;
11322
      iprot.readStructBegin();
11323
      while (true)
11324
      {
11325
        field = iprot.readFieldBegin();
11326
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11327
          break;
11328
        }
11329
        switch (field.id) {
11330
          case 1: // WAREHOUSE_ID
11331
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11332
              this.warehouse_id = iprot.readI64();
11333
              setWarehouse_idIsSet(true);
11334
            } else { 
11335
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11336
            }
11337
            break;
11338
          default:
11339
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11340
        }
11341
        iprot.readFieldEnd();
11342
      }
11343
      iprot.readStructEnd();
11344
      validate();
11345
    }
11346
 
11347
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11348
      validate();
11349
 
11350
      oprot.writeStructBegin(STRUCT_DESC);
11351
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
11352
      oprot.writeI64(this.warehouse_id);
11353
      oprot.writeFieldEnd();
11354
      oprot.writeFieldStop();
11355
      oprot.writeStructEnd();
11356
    }
11357
 
11358
    @Override
11359
    public String toString() {
11360
      StringBuilder sb = new StringBuilder("getAllItemsForWarehouse_args(");
11361
      boolean first = true;
11362
 
11363
      sb.append("warehouse_id:");
11364
      sb.append(this.warehouse_id);
11365
      first = false;
11366
      sb.append(")");
11367
      return sb.toString();
11368
    }
11369
 
11370
    public void validate() throws org.apache.thrift.TException {
11371
      // check for required fields
11372
    }
11373
 
11374
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11375
      try {
11376
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11377
      } catch (org.apache.thrift.TException te) {
11378
        throw new java.io.IOException(te);
11379
      }
11380
    }
11381
 
11382
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11383
      try {
11384
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
11385
        __isset_bit_vector = new BitSet(1);
11386
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11387
      } catch (org.apache.thrift.TException te) {
11388
        throw new java.io.IOException(te);
11389
      }
11390
    }
11391
 
11392
  }
11393
 
11394
  public static class getAllItemsForWarehouse_result implements org.apache.thrift.TBase<getAllItemsForWarehouse_result, getAllItemsForWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
11395
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemsForWarehouse_result");
11396
 
11397
    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);
11398
    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);
11399
 
11400
    private List<Long> success; // required
11401
    private InventoryServiceException cex; // required
11402
 
11403
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11404
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11405
      SUCCESS((short)0, "success"),
11406
      CEX((short)1, "cex");
11407
 
11408
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11409
 
11410
      static {
11411
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11412
          byName.put(field.getFieldName(), field);
11413
        }
11414
      }
11415
 
11416
      /**
11417
       * Find the _Fields constant that matches fieldId, or null if its not found.
11418
       */
11419
      public static _Fields findByThriftId(int fieldId) {
11420
        switch(fieldId) {
11421
          case 0: // SUCCESS
11422
            return SUCCESS;
11423
          case 1: // CEX
11424
            return CEX;
11425
          default:
11426
            return null;
11427
        }
11428
      }
11429
 
11430
      /**
11431
       * Find the _Fields constant that matches fieldId, throwing an exception
11432
       * if it is not found.
11433
       */
11434
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11435
        _Fields fields = findByThriftId(fieldId);
11436
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11437
        return fields;
11438
      }
11439
 
11440
      /**
11441
       * Find the _Fields constant that matches name, or null if its not found.
11442
       */
11443
      public static _Fields findByName(String name) {
11444
        return byName.get(name);
11445
      }
11446
 
11447
      private final short _thriftId;
11448
      private final String _fieldName;
11449
 
11450
      _Fields(short thriftId, String fieldName) {
11451
        _thriftId = thriftId;
11452
        _fieldName = fieldName;
11453
      }
11454
 
11455
      public short getThriftFieldId() {
11456
        return _thriftId;
11457
      }
11458
 
11459
      public String getFieldName() {
11460
        return _fieldName;
11461
      }
11462
    }
11463
 
11464
    // isset id assignments
11465
 
11466
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11467
    static {
11468
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11469
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11470
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
11471
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
11472
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11473
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
11474
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11475
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemsForWarehouse_result.class, metaDataMap);
11476
    }
11477
 
11478
    public getAllItemsForWarehouse_result() {
11479
    }
11480
 
11481
    public getAllItemsForWarehouse_result(
11482
      List<Long> success,
11483
      InventoryServiceException cex)
11484
    {
11485
      this();
11486
      this.success = success;
11487
      this.cex = cex;
11488
    }
11489
 
11490
    /**
11491
     * Performs a deep copy on <i>other</i>.
11492
     */
11493
    public getAllItemsForWarehouse_result(getAllItemsForWarehouse_result other) {
11494
      if (other.isSetSuccess()) {
11495
        List<Long> __this__success = new ArrayList<Long>();
11496
        for (Long other_element : other.success) {
11497
          __this__success.add(other_element);
11498
        }
11499
        this.success = __this__success;
11500
      }
11501
      if (other.isSetCex()) {
11502
        this.cex = new InventoryServiceException(other.cex);
11503
      }
11504
    }
11505
 
11506
    public getAllItemsForWarehouse_result deepCopy() {
11507
      return new getAllItemsForWarehouse_result(this);
11508
    }
11509
 
11510
    @Override
11511
    public void clear() {
11512
      this.success = null;
11513
      this.cex = null;
11514
    }
11515
 
11516
    public int getSuccessSize() {
11517
      return (this.success == null) ? 0 : this.success.size();
11518
    }
11519
 
11520
    public java.util.Iterator<Long> getSuccessIterator() {
11521
      return (this.success == null) ? null : this.success.iterator();
11522
    }
11523
 
11524
    public void addToSuccess(long elem) {
11525
      if (this.success == null) {
11526
        this.success = new ArrayList<Long>();
11527
      }
11528
      this.success.add(elem);
11529
    }
11530
 
11531
    public List<Long> getSuccess() {
11532
      return this.success;
11533
    }
11534
 
11535
    public void setSuccess(List<Long> success) {
11536
      this.success = success;
11537
    }
11538
 
11539
    public void unsetSuccess() {
11540
      this.success = null;
11541
    }
11542
 
11543
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
11544
    public boolean isSetSuccess() {
11545
      return this.success != null;
11546
    }
11547
 
11548
    public void setSuccessIsSet(boolean value) {
11549
      if (!value) {
11550
        this.success = null;
11551
      }
11552
    }
11553
 
11554
    public InventoryServiceException getCex() {
11555
      return this.cex;
11556
    }
11557
 
11558
    public void setCex(InventoryServiceException cex) {
11559
      this.cex = cex;
11560
    }
11561
 
11562
    public void unsetCex() {
11563
      this.cex = null;
11564
    }
11565
 
11566
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
11567
    public boolean isSetCex() {
11568
      return this.cex != null;
11569
    }
11570
 
11571
    public void setCexIsSet(boolean value) {
11572
      if (!value) {
11573
        this.cex = null;
11574
      }
11575
    }
11576
 
11577
    public void setFieldValue(_Fields field, Object value) {
11578
      switch (field) {
11579
      case SUCCESS:
11580
        if (value == null) {
11581
          unsetSuccess();
11582
        } else {
11583
          setSuccess((List<Long>)value);
11584
        }
11585
        break;
11586
 
11587
      case CEX:
11588
        if (value == null) {
11589
          unsetCex();
11590
        } else {
11591
          setCex((InventoryServiceException)value);
11592
        }
11593
        break;
11594
 
11595
      }
11596
    }
11597
 
11598
    public Object getFieldValue(_Fields field) {
11599
      switch (field) {
11600
      case SUCCESS:
11601
        return getSuccess();
11602
 
11603
      case CEX:
11604
        return getCex();
11605
 
11606
      }
11607
      throw new IllegalStateException();
11608
    }
11609
 
11610
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11611
    public boolean isSet(_Fields field) {
11612
      if (field == null) {
11613
        throw new IllegalArgumentException();
11614
      }
11615
 
11616
      switch (field) {
11617
      case SUCCESS:
11618
        return isSetSuccess();
11619
      case CEX:
11620
        return isSetCex();
11621
      }
11622
      throw new IllegalStateException();
11623
    }
11624
 
11625
    @Override
11626
    public boolean equals(Object that) {
11627
      if (that == null)
11628
        return false;
11629
      if (that instanceof getAllItemsForWarehouse_result)
11630
        return this.equals((getAllItemsForWarehouse_result)that);
11631
      return false;
11632
    }
11633
 
11634
    public boolean equals(getAllItemsForWarehouse_result that) {
11635
      if (that == null)
11636
        return false;
11637
 
11638
      boolean this_present_success = true && this.isSetSuccess();
11639
      boolean that_present_success = true && that.isSetSuccess();
11640
      if (this_present_success || that_present_success) {
11641
        if (!(this_present_success && that_present_success))
11642
          return false;
11643
        if (!this.success.equals(that.success))
11644
          return false;
11645
      }
11646
 
11647
      boolean this_present_cex = true && this.isSetCex();
11648
      boolean that_present_cex = true && that.isSetCex();
11649
      if (this_present_cex || that_present_cex) {
11650
        if (!(this_present_cex && that_present_cex))
11651
          return false;
11652
        if (!this.cex.equals(that.cex))
11653
          return false;
11654
      }
11655
 
11656
      return true;
11657
    }
11658
 
11659
    @Override
11660
    public int hashCode() {
11661
      return 0;
11662
    }
11663
 
11664
    public int compareTo(getAllItemsForWarehouse_result other) {
11665
      if (!getClass().equals(other.getClass())) {
11666
        return getClass().getName().compareTo(other.getClass().getName());
11667
      }
11668
 
11669
      int lastComparison = 0;
11670
      getAllItemsForWarehouse_result typedOther = (getAllItemsForWarehouse_result)other;
11671
 
11672
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
11673
      if (lastComparison != 0) {
11674
        return lastComparison;
11675
      }
11676
      if (isSetSuccess()) {
11677
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11678
        if (lastComparison != 0) {
11679
          return lastComparison;
11680
        }
11681
      }
11682
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
11683
      if (lastComparison != 0) {
11684
        return lastComparison;
11685
      }
11686
      if (isSetCex()) {
11687
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
11688
        if (lastComparison != 0) {
11689
          return lastComparison;
11690
        }
11691
      }
11692
      return 0;
11693
    }
11694
 
11695
    public _Fields fieldForId(int fieldId) {
11696
      return _Fields.findByThriftId(fieldId);
11697
    }
11698
 
11699
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11700
      org.apache.thrift.protocol.TField field;
11701
      iprot.readStructBegin();
11702
      while (true)
11703
      {
11704
        field = iprot.readFieldBegin();
11705
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11706
          break;
11707
        }
11708
        switch (field.id) {
11709
          case 0: // SUCCESS
11710
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
11711
              {
11712
                org.apache.thrift.protocol.TList _list28 = iprot.readListBegin();
11713
                this.success = new ArrayList<Long>(_list28.size);
11714
                for (int _i29 = 0; _i29 < _list28.size; ++_i29)
11715
                {
11716
                  long _elem30; // required
11717
                  _elem30 = iprot.readI64();
11718
                  this.success.add(_elem30);
11719
                }
11720
                iprot.readListEnd();
11721
              }
11722
            } else { 
11723
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11724
            }
11725
            break;
11726
          case 1: // CEX
11727
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11728
              this.cex = new InventoryServiceException();
11729
              this.cex.read(iprot);
11730
            } else { 
11731
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11732
            }
11733
            break;
11734
          default:
11735
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11736
        }
11737
        iprot.readFieldEnd();
11738
      }
11739
      iprot.readStructEnd();
11740
      validate();
11741
    }
11742
 
11743
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11744
      oprot.writeStructBegin(STRUCT_DESC);
11745
 
11746
      if (this.isSetSuccess()) {
11747
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11748
        {
11749
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
11750
          for (long _iter31 : this.success)
11751
          {
11752
            oprot.writeI64(_iter31);
11753
          }
11754
          oprot.writeListEnd();
11755
        }
11756
        oprot.writeFieldEnd();
11757
      } else if (this.isSetCex()) {
11758
        oprot.writeFieldBegin(CEX_FIELD_DESC);
11759
        this.cex.write(oprot);
11760
        oprot.writeFieldEnd();
11761
      }
11762
      oprot.writeFieldStop();
11763
      oprot.writeStructEnd();
11764
    }
11765
 
11766
    @Override
11767
    public String toString() {
11768
      StringBuilder sb = new StringBuilder("getAllItemsForWarehouse_result(");
11769
      boolean first = true;
11770
 
11771
      sb.append("success:");
11772
      if (this.success == null) {
11773
        sb.append("null");
11774
      } else {
11775
        sb.append(this.success);
11776
      }
11777
      first = false;
11778
      if (!first) sb.append(", ");
11779
      sb.append("cex:");
11780
      if (this.cex == null) {
11781
        sb.append("null");
11782
      } else {
11783
        sb.append(this.cex);
11784
      }
11785
      first = false;
11786
      sb.append(")");
11787
      return sb.toString();
11788
    }
11789
 
11790
    public void validate() throws org.apache.thrift.TException {
11791
      // check for required fields
11792
    }
11793
 
11794
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11795
      try {
11796
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11797
      } catch (org.apache.thrift.TException te) {
11798
        throw new java.io.IOException(te);
11799
      }
11800
    }
11801
 
11802
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11803
      try {
11804
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11805
      } catch (org.apache.thrift.TException te) {
11806
        throw new java.io.IOException(te);
11807
      }
11808
    }
11809
 
11810
  }
11811
 
5967 rajveer 11812
  public static class isOrderBillable_args implements org.apache.thrift.TBase<isOrderBillable_args, isOrderBillable_args._Fields>, java.io.Serializable, Cloneable   {
11813
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("isOrderBillable_args");
11814
 
11815
    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);
11816
    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);
11817
    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);
11818
    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);
11819
 
11820
    private long itemId; // required
11821
    private long warehouseId; // required
11822
    private long sourceId; // required
11823
    private long orderId; // required
11824
 
11825
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11826
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11827
      ITEM_ID((short)1, "itemId"),
11828
      WAREHOUSE_ID((short)2, "warehouseId"),
11829
      SOURCE_ID((short)3, "sourceId"),
11830
      ORDER_ID((short)4, "orderId");
11831
 
11832
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11833
 
11834
      static {
11835
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11836
          byName.put(field.getFieldName(), field);
11837
        }
11838
      }
11839
 
11840
      /**
11841
       * Find the _Fields constant that matches fieldId, or null if its not found.
11842
       */
11843
      public static _Fields findByThriftId(int fieldId) {
11844
        switch(fieldId) {
11845
          case 1: // ITEM_ID
11846
            return ITEM_ID;
11847
          case 2: // WAREHOUSE_ID
11848
            return WAREHOUSE_ID;
11849
          case 3: // SOURCE_ID
11850
            return SOURCE_ID;
11851
          case 4: // ORDER_ID
11852
            return ORDER_ID;
11853
          default:
11854
            return null;
11855
        }
11856
      }
11857
 
11858
      /**
11859
       * Find the _Fields constant that matches fieldId, throwing an exception
11860
       * if it is not found.
11861
       */
11862
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11863
        _Fields fields = findByThriftId(fieldId);
11864
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11865
        return fields;
11866
      }
11867
 
11868
      /**
11869
       * Find the _Fields constant that matches name, or null if its not found.
11870
       */
11871
      public static _Fields findByName(String name) {
11872
        return byName.get(name);
11873
      }
11874
 
11875
      private final short _thriftId;
11876
      private final String _fieldName;
11877
 
11878
      _Fields(short thriftId, String fieldName) {
11879
        _thriftId = thriftId;
11880
        _fieldName = fieldName;
11881
      }
11882
 
11883
      public short getThriftFieldId() {
11884
        return _thriftId;
11885
      }
11886
 
11887
      public String getFieldName() {
11888
        return _fieldName;
11889
      }
11890
    }
11891
 
11892
    // isset id assignments
11893
    private static final int __ITEMID_ISSET_ID = 0;
11894
    private static final int __WAREHOUSEID_ISSET_ID = 1;
11895
    private static final int __SOURCEID_ISSET_ID = 2;
11896
    private static final int __ORDERID_ISSET_ID = 3;
11897
    private BitSet __isset_bit_vector = new BitSet(4);
11898
 
11899
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11900
    static {
11901
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11902
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11903
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11904
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11905
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11906
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11907
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11908
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11909
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11910
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11911
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(isOrderBillable_args.class, metaDataMap);
11912
    }
11913
 
11914
    public isOrderBillable_args() {
11915
    }
11916
 
11917
    public isOrderBillable_args(
11918
      long itemId,
11919
      long warehouseId,
11920
      long sourceId,
11921
      long orderId)
11922
    {
11923
      this();
11924
      this.itemId = itemId;
11925
      setItemIdIsSet(true);
11926
      this.warehouseId = warehouseId;
11927
      setWarehouseIdIsSet(true);
11928
      this.sourceId = sourceId;
11929
      setSourceIdIsSet(true);
11930
      this.orderId = orderId;
11931
      setOrderIdIsSet(true);
11932
    }
11933
 
11934
    /**
11935
     * Performs a deep copy on <i>other</i>.
11936
     */
11937
    public isOrderBillable_args(isOrderBillable_args other) {
11938
      __isset_bit_vector.clear();
11939
      __isset_bit_vector.or(other.__isset_bit_vector);
11940
      this.itemId = other.itemId;
11941
      this.warehouseId = other.warehouseId;
11942
      this.sourceId = other.sourceId;
11943
      this.orderId = other.orderId;
11944
    }
11945
 
11946
    public isOrderBillable_args deepCopy() {
11947
      return new isOrderBillable_args(this);
11948
    }
11949
 
11950
    @Override
11951
    public void clear() {
11952
      setItemIdIsSet(false);
11953
      this.itemId = 0;
11954
      setWarehouseIdIsSet(false);
11955
      this.warehouseId = 0;
11956
      setSourceIdIsSet(false);
11957
      this.sourceId = 0;
11958
      setOrderIdIsSet(false);
11959
      this.orderId = 0;
11960
    }
11961
 
11962
    public long getItemId() {
11963
      return this.itemId;
11964
    }
11965
 
11966
    public void setItemId(long itemId) {
11967
      this.itemId = itemId;
11968
      setItemIdIsSet(true);
11969
    }
11970
 
11971
    public void unsetItemId() {
11972
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
11973
    }
11974
 
11975
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
11976
    public boolean isSetItemId() {
11977
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
11978
    }
11979
 
11980
    public void setItemIdIsSet(boolean value) {
11981
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
11982
    }
11983
 
11984
    public long getWarehouseId() {
11985
      return this.warehouseId;
11986
    }
11987
 
11988
    public void setWarehouseId(long warehouseId) {
11989
      this.warehouseId = warehouseId;
11990
      setWarehouseIdIsSet(true);
11991
    }
11992
 
11993
    public void unsetWarehouseId() {
11994
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
11995
    }
11996
 
11997
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
11998
    public boolean isSetWarehouseId() {
11999
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
12000
    }
12001
 
12002
    public void setWarehouseIdIsSet(boolean value) {
12003
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
12004
    }
12005
 
12006
    public long getSourceId() {
12007
      return this.sourceId;
12008
    }
12009
 
12010
    public void setSourceId(long sourceId) {
12011
      this.sourceId = sourceId;
12012
      setSourceIdIsSet(true);
12013
    }
12014
 
12015
    public void unsetSourceId() {
12016
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
12017
    }
12018
 
12019
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
12020
    public boolean isSetSourceId() {
12021
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
12022
    }
12023
 
12024
    public void setSourceIdIsSet(boolean value) {
12025
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
12026
    }
12027
 
12028
    public long getOrderId() {
12029
      return this.orderId;
12030
    }
12031
 
12032
    public void setOrderId(long orderId) {
12033
      this.orderId = orderId;
12034
      setOrderIdIsSet(true);
12035
    }
12036
 
12037
    public void unsetOrderId() {
12038
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
12039
    }
12040
 
12041
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
12042
    public boolean isSetOrderId() {
12043
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
12044
    }
12045
 
12046
    public void setOrderIdIsSet(boolean value) {
12047
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
12048
    }
12049
 
12050
    public void setFieldValue(_Fields field, Object value) {
12051
      switch (field) {
12052
      case ITEM_ID:
12053
        if (value == null) {
12054
          unsetItemId();
12055
        } else {
12056
          setItemId((Long)value);
12057
        }
12058
        break;
12059
 
12060
      case WAREHOUSE_ID:
12061
        if (value == null) {
12062
          unsetWarehouseId();
12063
        } else {
12064
          setWarehouseId((Long)value);
12065
        }
12066
        break;
12067
 
12068
      case SOURCE_ID:
12069
        if (value == null) {
12070
          unsetSourceId();
12071
        } else {
12072
          setSourceId((Long)value);
12073
        }
12074
        break;
12075
 
12076
      case ORDER_ID:
12077
        if (value == null) {
12078
          unsetOrderId();
12079
        } else {
12080
          setOrderId((Long)value);
12081
        }
12082
        break;
12083
 
12084
      }
12085
    }
12086
 
12087
    public Object getFieldValue(_Fields field) {
12088
      switch (field) {
12089
      case ITEM_ID:
12090
        return Long.valueOf(getItemId());
12091
 
12092
      case WAREHOUSE_ID:
12093
        return Long.valueOf(getWarehouseId());
12094
 
12095
      case SOURCE_ID:
12096
        return Long.valueOf(getSourceId());
12097
 
12098
      case ORDER_ID:
12099
        return Long.valueOf(getOrderId());
12100
 
12101
      }
12102
      throw new IllegalStateException();
12103
    }
12104
 
12105
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12106
    public boolean isSet(_Fields field) {
12107
      if (field == null) {
12108
        throw new IllegalArgumentException();
12109
      }
12110
 
12111
      switch (field) {
12112
      case ITEM_ID:
12113
        return isSetItemId();
12114
      case WAREHOUSE_ID:
12115
        return isSetWarehouseId();
12116
      case SOURCE_ID:
12117
        return isSetSourceId();
12118
      case ORDER_ID:
12119
        return isSetOrderId();
12120
      }
12121
      throw new IllegalStateException();
12122
    }
12123
 
12124
    @Override
12125
    public boolean equals(Object that) {
12126
      if (that == null)
12127
        return false;
12128
      if (that instanceof isOrderBillable_args)
12129
        return this.equals((isOrderBillable_args)that);
12130
      return false;
12131
    }
12132
 
12133
    public boolean equals(isOrderBillable_args that) {
12134
      if (that == null)
12135
        return false;
12136
 
12137
      boolean this_present_itemId = true;
12138
      boolean that_present_itemId = true;
12139
      if (this_present_itemId || that_present_itemId) {
12140
        if (!(this_present_itemId && that_present_itemId))
12141
          return false;
12142
        if (this.itemId != that.itemId)
12143
          return false;
12144
      }
12145
 
12146
      boolean this_present_warehouseId = true;
12147
      boolean that_present_warehouseId = true;
12148
      if (this_present_warehouseId || that_present_warehouseId) {
12149
        if (!(this_present_warehouseId && that_present_warehouseId))
12150
          return false;
12151
        if (this.warehouseId != that.warehouseId)
12152
          return false;
12153
      }
12154
 
12155
      boolean this_present_sourceId = true;
12156
      boolean that_present_sourceId = true;
12157
      if (this_present_sourceId || that_present_sourceId) {
12158
        if (!(this_present_sourceId && that_present_sourceId))
12159
          return false;
12160
        if (this.sourceId != that.sourceId)
12161
          return false;
12162
      }
12163
 
12164
      boolean this_present_orderId = true;
12165
      boolean that_present_orderId = true;
12166
      if (this_present_orderId || that_present_orderId) {
12167
        if (!(this_present_orderId && that_present_orderId))
12168
          return false;
12169
        if (this.orderId != that.orderId)
12170
          return false;
12171
      }
12172
 
12173
      return true;
12174
    }
12175
 
12176
    @Override
12177
    public int hashCode() {
12178
      return 0;
12179
    }
12180
 
12181
    public int compareTo(isOrderBillable_args other) {
12182
      if (!getClass().equals(other.getClass())) {
12183
        return getClass().getName().compareTo(other.getClass().getName());
12184
      }
12185
 
12186
      int lastComparison = 0;
12187
      isOrderBillable_args typedOther = (isOrderBillable_args)other;
12188
 
12189
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
12190
      if (lastComparison != 0) {
12191
        return lastComparison;
12192
      }
12193
      if (isSetItemId()) {
12194
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
12195
        if (lastComparison != 0) {
12196
          return lastComparison;
12197
        }
12198
      }
12199
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
12200
      if (lastComparison != 0) {
12201
        return lastComparison;
12202
      }
12203
      if (isSetWarehouseId()) {
12204
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
12205
        if (lastComparison != 0) {
12206
          return lastComparison;
12207
        }
12208
      }
12209
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
12210
      if (lastComparison != 0) {
12211
        return lastComparison;
12212
      }
12213
      if (isSetSourceId()) {
12214
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
12215
        if (lastComparison != 0) {
12216
          return lastComparison;
12217
        }
12218
      }
12219
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
12220
      if (lastComparison != 0) {
12221
        return lastComparison;
12222
      }
12223
      if (isSetOrderId()) {
12224
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
12225
        if (lastComparison != 0) {
12226
          return lastComparison;
12227
        }
12228
      }
12229
      return 0;
12230
    }
12231
 
12232
    public _Fields fieldForId(int fieldId) {
12233
      return _Fields.findByThriftId(fieldId);
12234
    }
12235
 
12236
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12237
      org.apache.thrift.protocol.TField field;
12238
      iprot.readStructBegin();
12239
      while (true)
12240
      {
12241
        field = iprot.readFieldBegin();
12242
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12243
          break;
12244
        }
12245
        switch (field.id) {
12246
          case 1: // ITEM_ID
12247
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12248
              this.itemId = iprot.readI64();
12249
              setItemIdIsSet(true);
12250
            } else { 
12251
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12252
            }
12253
            break;
12254
          case 2: // WAREHOUSE_ID
12255
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12256
              this.warehouseId = iprot.readI64();
12257
              setWarehouseIdIsSet(true);
12258
            } else { 
12259
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12260
            }
12261
            break;
12262
          case 3: // SOURCE_ID
12263
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12264
              this.sourceId = iprot.readI64();
12265
              setSourceIdIsSet(true);
12266
            } else { 
12267
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12268
            }
12269
            break;
12270
          case 4: // ORDER_ID
12271
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12272
              this.orderId = iprot.readI64();
12273
              setOrderIdIsSet(true);
12274
            } else { 
12275
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12276
            }
12277
            break;
12278
          default:
12279
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12280
        }
12281
        iprot.readFieldEnd();
12282
      }
12283
      iprot.readStructEnd();
12284
      validate();
12285
    }
12286
 
12287
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12288
      validate();
12289
 
12290
      oprot.writeStructBegin(STRUCT_DESC);
12291
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
12292
      oprot.writeI64(this.itemId);
12293
      oprot.writeFieldEnd();
12294
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
12295
      oprot.writeI64(this.warehouseId);
12296
      oprot.writeFieldEnd();
12297
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
12298
      oprot.writeI64(this.sourceId);
12299
      oprot.writeFieldEnd();
12300
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
12301
      oprot.writeI64(this.orderId);
12302
      oprot.writeFieldEnd();
12303
      oprot.writeFieldStop();
12304
      oprot.writeStructEnd();
12305
    }
12306
 
12307
    @Override
12308
    public String toString() {
12309
      StringBuilder sb = new StringBuilder("isOrderBillable_args(");
12310
      boolean first = true;
12311
 
12312
      sb.append("itemId:");
12313
      sb.append(this.itemId);
12314
      first = false;
12315
      if (!first) sb.append(", ");
12316
      sb.append("warehouseId:");
12317
      sb.append(this.warehouseId);
12318
      first = false;
12319
      if (!first) sb.append(", ");
12320
      sb.append("sourceId:");
12321
      sb.append(this.sourceId);
12322
      first = false;
12323
      if (!first) sb.append(", ");
12324
      sb.append("orderId:");
12325
      sb.append(this.orderId);
12326
      first = false;
12327
      sb.append(")");
12328
      return sb.toString();
12329
    }
12330
 
12331
    public void validate() throws org.apache.thrift.TException {
12332
      // check for required fields
12333
    }
12334
 
12335
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12336
      try {
12337
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12338
      } catch (org.apache.thrift.TException te) {
12339
        throw new java.io.IOException(te);
12340
      }
12341
    }
12342
 
12343
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12344
      try {
12345
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12346
      } catch (org.apache.thrift.TException te) {
12347
        throw new java.io.IOException(te);
12348
      }
12349
    }
12350
 
12351
  }
12352
 
12353
  public static class isOrderBillable_result implements org.apache.thrift.TBase<isOrderBillable_result, isOrderBillable_result._Fields>, java.io.Serializable, Cloneable   {
12354
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("isOrderBillable_result");
12355
 
12356
    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);
12357
 
12358
    private boolean success; // required
12359
 
12360
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12361
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12362
      SUCCESS((short)0, "success");
12363
 
12364
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12365
 
12366
      static {
12367
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12368
          byName.put(field.getFieldName(), field);
12369
        }
12370
      }
12371
 
12372
      /**
12373
       * Find the _Fields constant that matches fieldId, or null if its not found.
12374
       */
12375
      public static _Fields findByThriftId(int fieldId) {
12376
        switch(fieldId) {
12377
          case 0: // SUCCESS
12378
            return SUCCESS;
12379
          default:
12380
            return null;
12381
        }
12382
      }
12383
 
12384
      /**
12385
       * Find the _Fields constant that matches fieldId, throwing an exception
12386
       * if it is not found.
12387
       */
12388
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12389
        _Fields fields = findByThriftId(fieldId);
12390
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12391
        return fields;
12392
      }
12393
 
12394
      /**
12395
       * Find the _Fields constant that matches name, or null if its not found.
12396
       */
12397
      public static _Fields findByName(String name) {
12398
        return byName.get(name);
12399
      }
12400
 
12401
      private final short _thriftId;
12402
      private final String _fieldName;
12403
 
12404
      _Fields(short thriftId, String fieldName) {
12405
        _thriftId = thriftId;
12406
        _fieldName = fieldName;
12407
      }
12408
 
12409
      public short getThriftFieldId() {
12410
        return _thriftId;
12411
      }
12412
 
12413
      public String getFieldName() {
12414
        return _fieldName;
12415
      }
12416
    }
12417
 
12418
    // isset id assignments
12419
    private static final int __SUCCESS_ISSET_ID = 0;
12420
    private BitSet __isset_bit_vector = new BitSet(1);
12421
 
12422
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12423
    static {
12424
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12425
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12426
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
12427
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12428
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(isOrderBillable_result.class, metaDataMap);
12429
    }
12430
 
12431
    public isOrderBillable_result() {
12432
    }
12433
 
12434
    public isOrderBillable_result(
12435
      boolean success)
12436
    {
12437
      this();
12438
      this.success = success;
12439
      setSuccessIsSet(true);
12440
    }
12441
 
12442
    /**
12443
     * Performs a deep copy on <i>other</i>.
12444
     */
12445
    public isOrderBillable_result(isOrderBillable_result other) {
12446
      __isset_bit_vector.clear();
12447
      __isset_bit_vector.or(other.__isset_bit_vector);
12448
      this.success = other.success;
12449
    }
12450
 
12451
    public isOrderBillable_result deepCopy() {
12452
      return new isOrderBillable_result(this);
12453
    }
12454
 
12455
    @Override
12456
    public void clear() {
12457
      setSuccessIsSet(false);
12458
      this.success = false;
12459
    }
12460
 
12461
    public boolean isSuccess() {
12462
      return this.success;
12463
    }
12464
 
12465
    public void setSuccess(boolean success) {
12466
      this.success = success;
12467
      setSuccessIsSet(true);
12468
    }
12469
 
12470
    public void unsetSuccess() {
12471
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
12472
    }
12473
 
12474
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
12475
    public boolean isSetSuccess() {
12476
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
12477
    }
12478
 
12479
    public void setSuccessIsSet(boolean value) {
12480
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
12481
    }
12482
 
12483
    public void setFieldValue(_Fields field, Object value) {
12484
      switch (field) {
12485
      case SUCCESS:
12486
        if (value == null) {
12487
          unsetSuccess();
12488
        } else {
12489
          setSuccess((Boolean)value);
12490
        }
12491
        break;
12492
 
12493
      }
12494
    }
12495
 
12496
    public Object getFieldValue(_Fields field) {
12497
      switch (field) {
12498
      case SUCCESS:
12499
        return Boolean.valueOf(isSuccess());
12500
 
12501
      }
12502
      throw new IllegalStateException();
12503
    }
12504
 
12505
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12506
    public boolean isSet(_Fields field) {
12507
      if (field == null) {
12508
        throw new IllegalArgumentException();
12509
      }
12510
 
12511
      switch (field) {
12512
      case SUCCESS:
12513
        return isSetSuccess();
12514
      }
12515
      throw new IllegalStateException();
12516
    }
12517
 
12518
    @Override
12519
    public boolean equals(Object that) {
12520
      if (that == null)
12521
        return false;
12522
      if (that instanceof isOrderBillable_result)
12523
        return this.equals((isOrderBillable_result)that);
12524
      return false;
12525
    }
12526
 
12527
    public boolean equals(isOrderBillable_result that) {
12528
      if (that == null)
12529
        return false;
12530
 
12531
      boolean this_present_success = true;
12532
      boolean that_present_success = true;
12533
      if (this_present_success || that_present_success) {
12534
        if (!(this_present_success && that_present_success))
12535
          return false;
12536
        if (this.success != that.success)
12537
          return false;
12538
      }
12539
 
12540
      return true;
12541
    }
12542
 
12543
    @Override
12544
    public int hashCode() {
12545
      return 0;
12546
    }
12547
 
12548
    public int compareTo(isOrderBillable_result other) {
12549
      if (!getClass().equals(other.getClass())) {
12550
        return getClass().getName().compareTo(other.getClass().getName());
12551
      }
12552
 
12553
      int lastComparison = 0;
12554
      isOrderBillable_result typedOther = (isOrderBillable_result)other;
12555
 
12556
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
12557
      if (lastComparison != 0) {
12558
        return lastComparison;
12559
      }
12560
      if (isSetSuccess()) {
12561
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
12562
        if (lastComparison != 0) {
12563
          return lastComparison;
12564
        }
12565
      }
12566
      return 0;
12567
    }
12568
 
12569
    public _Fields fieldForId(int fieldId) {
12570
      return _Fields.findByThriftId(fieldId);
12571
    }
12572
 
12573
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12574
      org.apache.thrift.protocol.TField field;
12575
      iprot.readStructBegin();
12576
      while (true)
12577
      {
12578
        field = iprot.readFieldBegin();
12579
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12580
          break;
12581
        }
12582
        switch (field.id) {
12583
          case 0: // SUCCESS
12584
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
12585
              this.success = iprot.readBool();
12586
              setSuccessIsSet(true);
12587
            } else { 
12588
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12589
            }
12590
            break;
12591
          default:
12592
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12593
        }
12594
        iprot.readFieldEnd();
12595
      }
12596
      iprot.readStructEnd();
12597
      validate();
12598
    }
12599
 
12600
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12601
      oprot.writeStructBegin(STRUCT_DESC);
12602
 
12603
      if (this.isSetSuccess()) {
12604
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
12605
        oprot.writeBool(this.success);
12606
        oprot.writeFieldEnd();
12607
      }
12608
      oprot.writeFieldStop();
12609
      oprot.writeStructEnd();
12610
    }
12611
 
12612
    @Override
12613
    public String toString() {
12614
      StringBuilder sb = new StringBuilder("isOrderBillable_result(");
12615
      boolean first = true;
12616
 
12617
      sb.append("success:");
12618
      sb.append(this.success);
12619
      first = false;
12620
      sb.append(")");
12621
      return sb.toString();
12622
    }
12623
 
12624
    public void validate() throws org.apache.thrift.TException {
12625
      // check for required fields
12626
    }
12627
 
12628
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12629
      try {
12630
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12631
      } catch (org.apache.thrift.TException te) {
12632
        throw new java.io.IOException(te);
12633
      }
12634
    }
12635
 
12636
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12637
      try {
12638
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12639
      } catch (org.apache.thrift.TException te) {
12640
        throw new java.io.IOException(te);
12641
      }
12642
    }
12643
 
12644
  }
12645
 
5945 mandeep.dh 12646
  public static class reserveItemInWarehouse_args implements org.apache.thrift.TBase<reserveItemInWarehouse_args, reserveItemInWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
12647
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reserveItemInWarehouse_args");
12648
 
12649
    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);
12650
    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 12651
    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);
12652
    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);
12653
    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);
12654
    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);
12655
    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 12656
 
12657
    private long itemId; // required
12658
    private long warehouseId; // required
5967 rajveer 12659
    private long sourceId; // required
12660
    private long orderId; // required
12661
    private long createdTimestamp; // required
12662
    private long promisedShippingTimestamp; // required
5945 mandeep.dh 12663
    private double quantity; // required
12664
 
12665
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12666
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12667
      ITEM_ID((short)1, "itemId"),
12668
      WAREHOUSE_ID((short)2, "warehouseId"),
5967 rajveer 12669
      SOURCE_ID((short)3, "sourceId"),
12670
      ORDER_ID((short)4, "orderId"),
12671
      CREATED_TIMESTAMP((short)5, "createdTimestamp"),
12672
      PROMISED_SHIPPING_TIMESTAMP((short)6, "promisedShippingTimestamp"),
12673
      QUANTITY((short)7, "quantity");
5945 mandeep.dh 12674
 
12675
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12676
 
12677
      static {
12678
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12679
          byName.put(field.getFieldName(), field);
12680
        }
12681
      }
12682
 
12683
      /**
12684
       * Find the _Fields constant that matches fieldId, or null if its not found.
12685
       */
12686
      public static _Fields findByThriftId(int fieldId) {
12687
        switch(fieldId) {
12688
          case 1: // ITEM_ID
12689
            return ITEM_ID;
12690
          case 2: // WAREHOUSE_ID
12691
            return WAREHOUSE_ID;
5967 rajveer 12692
          case 3: // SOURCE_ID
12693
            return SOURCE_ID;
12694
          case 4: // ORDER_ID
12695
            return ORDER_ID;
12696
          case 5: // CREATED_TIMESTAMP
12697
            return CREATED_TIMESTAMP;
12698
          case 6: // PROMISED_SHIPPING_TIMESTAMP
12699
            return PROMISED_SHIPPING_TIMESTAMP;
12700
          case 7: // QUANTITY
5945 mandeep.dh 12701
            return QUANTITY;
12702
          default:
12703
            return null;
12704
        }
12705
      }
12706
 
12707
      /**
12708
       * Find the _Fields constant that matches fieldId, throwing an exception
12709
       * if it is not found.
12710
       */
12711
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12712
        _Fields fields = findByThriftId(fieldId);
12713
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12714
        return fields;
12715
      }
12716
 
12717
      /**
12718
       * Find the _Fields constant that matches name, or null if its not found.
12719
       */
12720
      public static _Fields findByName(String name) {
12721
        return byName.get(name);
12722
      }
12723
 
12724
      private final short _thriftId;
12725
      private final String _fieldName;
12726
 
12727
      _Fields(short thriftId, String fieldName) {
12728
        _thriftId = thriftId;
12729
        _fieldName = fieldName;
12730
      }
12731
 
12732
      public short getThriftFieldId() {
12733
        return _thriftId;
12734
      }
12735
 
12736
      public String getFieldName() {
12737
        return _fieldName;
12738
      }
12739
    }
12740
 
12741
    // isset id assignments
12742
    private static final int __ITEMID_ISSET_ID = 0;
12743
    private static final int __WAREHOUSEID_ISSET_ID = 1;
5967 rajveer 12744
    private static final int __SOURCEID_ISSET_ID = 2;
12745
    private static final int __ORDERID_ISSET_ID = 3;
12746
    private static final int __CREATEDTIMESTAMP_ISSET_ID = 4;
12747
    private static final int __PROMISEDSHIPPINGTIMESTAMP_ISSET_ID = 5;
12748
    private static final int __QUANTITY_ISSET_ID = 6;
12749
    private BitSet __isset_bit_vector = new BitSet(7);
5945 mandeep.dh 12750
 
12751
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12752
    static {
12753
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12754
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12755
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12756
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12757
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5967 rajveer 12758
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12759
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12760
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12761
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12762
      tmpMap.put(_Fields.CREATED_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("createdTimestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12763
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12764
      tmpMap.put(_Fields.PROMISED_SHIPPING_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("promisedShippingTimestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12765
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5945 mandeep.dh 12766
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12767
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
12768
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12769
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reserveItemInWarehouse_args.class, metaDataMap);
12770
    }
12771
 
12772
    public reserveItemInWarehouse_args() {
12773
    }
12774
 
12775
    public reserveItemInWarehouse_args(
12776
      long itemId,
12777
      long warehouseId,
5967 rajveer 12778
      long sourceId,
12779
      long orderId,
12780
      long createdTimestamp,
12781
      long promisedShippingTimestamp,
5945 mandeep.dh 12782
      double quantity)
12783
    {
12784
      this();
12785
      this.itemId = itemId;
12786
      setItemIdIsSet(true);
12787
      this.warehouseId = warehouseId;
12788
      setWarehouseIdIsSet(true);
5967 rajveer 12789
      this.sourceId = sourceId;
12790
      setSourceIdIsSet(true);
12791
      this.orderId = orderId;
12792
      setOrderIdIsSet(true);
12793
      this.createdTimestamp = createdTimestamp;
12794
      setCreatedTimestampIsSet(true);
12795
      this.promisedShippingTimestamp = promisedShippingTimestamp;
12796
      setPromisedShippingTimestampIsSet(true);
5945 mandeep.dh 12797
      this.quantity = quantity;
12798
      setQuantityIsSet(true);
12799
    }
12800
 
12801
    /**
12802
     * Performs a deep copy on <i>other</i>.
12803
     */
12804
    public reserveItemInWarehouse_args(reserveItemInWarehouse_args other) {
12805
      __isset_bit_vector.clear();
12806
      __isset_bit_vector.or(other.__isset_bit_vector);
12807
      this.itemId = other.itemId;
12808
      this.warehouseId = other.warehouseId;
5967 rajveer 12809
      this.sourceId = other.sourceId;
12810
      this.orderId = other.orderId;
12811
      this.createdTimestamp = other.createdTimestamp;
12812
      this.promisedShippingTimestamp = other.promisedShippingTimestamp;
5945 mandeep.dh 12813
      this.quantity = other.quantity;
12814
    }
12815
 
12816
    public reserveItemInWarehouse_args deepCopy() {
12817
      return new reserveItemInWarehouse_args(this);
12818
    }
12819
 
12820
    @Override
12821
    public void clear() {
12822
      setItemIdIsSet(false);
12823
      this.itemId = 0;
12824
      setWarehouseIdIsSet(false);
12825
      this.warehouseId = 0;
5967 rajveer 12826
      setSourceIdIsSet(false);
12827
      this.sourceId = 0;
12828
      setOrderIdIsSet(false);
12829
      this.orderId = 0;
12830
      setCreatedTimestampIsSet(false);
12831
      this.createdTimestamp = 0;
12832
      setPromisedShippingTimestampIsSet(false);
12833
      this.promisedShippingTimestamp = 0;
5945 mandeep.dh 12834
      setQuantityIsSet(false);
12835
      this.quantity = 0.0;
12836
    }
12837
 
12838
    public long getItemId() {
12839
      return this.itemId;
12840
    }
12841
 
12842
    public void setItemId(long itemId) {
12843
      this.itemId = itemId;
12844
      setItemIdIsSet(true);
12845
    }
12846
 
12847
    public void unsetItemId() {
12848
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
12849
    }
12850
 
12851
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
12852
    public boolean isSetItemId() {
12853
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
12854
    }
12855
 
12856
    public void setItemIdIsSet(boolean value) {
12857
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
12858
    }
12859
 
12860
    public long getWarehouseId() {
12861
      return this.warehouseId;
12862
    }
12863
 
12864
    public void setWarehouseId(long warehouseId) {
12865
      this.warehouseId = warehouseId;
12866
      setWarehouseIdIsSet(true);
12867
    }
12868
 
12869
    public void unsetWarehouseId() {
12870
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
12871
    }
12872
 
12873
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
12874
    public boolean isSetWarehouseId() {
12875
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
12876
    }
12877
 
12878
    public void setWarehouseIdIsSet(boolean value) {
12879
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
12880
    }
12881
 
5967 rajveer 12882
    public long getSourceId() {
12883
      return this.sourceId;
12884
    }
12885
 
12886
    public void setSourceId(long sourceId) {
12887
      this.sourceId = sourceId;
12888
      setSourceIdIsSet(true);
12889
    }
12890
 
12891
    public void unsetSourceId() {
12892
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
12893
    }
12894
 
12895
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
12896
    public boolean isSetSourceId() {
12897
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
12898
    }
12899
 
12900
    public void setSourceIdIsSet(boolean value) {
12901
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
12902
    }
12903
 
12904
    public long getOrderId() {
12905
      return this.orderId;
12906
    }
12907
 
12908
    public void setOrderId(long orderId) {
12909
      this.orderId = orderId;
12910
      setOrderIdIsSet(true);
12911
    }
12912
 
12913
    public void unsetOrderId() {
12914
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
12915
    }
12916
 
12917
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
12918
    public boolean isSetOrderId() {
12919
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
12920
    }
12921
 
12922
    public void setOrderIdIsSet(boolean value) {
12923
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
12924
    }
12925
 
12926
    public long getCreatedTimestamp() {
12927
      return this.createdTimestamp;
12928
    }
12929
 
12930
    public void setCreatedTimestamp(long createdTimestamp) {
12931
      this.createdTimestamp = createdTimestamp;
12932
      setCreatedTimestampIsSet(true);
12933
    }
12934
 
12935
    public void unsetCreatedTimestamp() {
12936
      __isset_bit_vector.clear(__CREATEDTIMESTAMP_ISSET_ID);
12937
    }
12938
 
12939
    /** Returns true if field createdTimestamp is set (has been assigned a value) and false otherwise */
12940
    public boolean isSetCreatedTimestamp() {
12941
      return __isset_bit_vector.get(__CREATEDTIMESTAMP_ISSET_ID);
12942
    }
12943
 
12944
    public void setCreatedTimestampIsSet(boolean value) {
12945
      __isset_bit_vector.set(__CREATEDTIMESTAMP_ISSET_ID, value);
12946
    }
12947
 
12948
    public long getPromisedShippingTimestamp() {
12949
      return this.promisedShippingTimestamp;
12950
    }
12951
 
12952
    public void setPromisedShippingTimestamp(long promisedShippingTimestamp) {
12953
      this.promisedShippingTimestamp = promisedShippingTimestamp;
12954
      setPromisedShippingTimestampIsSet(true);
12955
    }
12956
 
12957
    public void unsetPromisedShippingTimestamp() {
12958
      __isset_bit_vector.clear(__PROMISEDSHIPPINGTIMESTAMP_ISSET_ID);
12959
    }
12960
 
12961
    /** Returns true if field promisedShippingTimestamp is set (has been assigned a value) and false otherwise */
12962
    public boolean isSetPromisedShippingTimestamp() {
12963
      return __isset_bit_vector.get(__PROMISEDSHIPPINGTIMESTAMP_ISSET_ID);
12964
    }
12965
 
12966
    public void setPromisedShippingTimestampIsSet(boolean value) {
12967
      __isset_bit_vector.set(__PROMISEDSHIPPINGTIMESTAMP_ISSET_ID, value);
12968
    }
12969
 
5945 mandeep.dh 12970
    public double getQuantity() {
12971
      return this.quantity;
12972
    }
12973
 
12974
    public void setQuantity(double quantity) {
12975
      this.quantity = quantity;
12976
      setQuantityIsSet(true);
12977
    }
12978
 
12979
    public void unsetQuantity() {
12980
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
12981
    }
12982
 
12983
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
12984
    public boolean isSetQuantity() {
12985
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
12986
    }
12987
 
12988
    public void setQuantityIsSet(boolean value) {
12989
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
12990
    }
12991
 
12992
    public void setFieldValue(_Fields field, Object value) {
12993
      switch (field) {
12994
      case ITEM_ID:
12995
        if (value == null) {
12996
          unsetItemId();
12997
        } else {
12998
          setItemId((Long)value);
12999
        }
13000
        break;
13001
 
13002
      case WAREHOUSE_ID:
13003
        if (value == null) {
13004
          unsetWarehouseId();
13005
        } else {
13006
          setWarehouseId((Long)value);
13007
        }
13008
        break;
13009
 
5967 rajveer 13010
      case SOURCE_ID:
13011
        if (value == null) {
13012
          unsetSourceId();
13013
        } else {
13014
          setSourceId((Long)value);
13015
        }
13016
        break;
13017
 
13018
      case ORDER_ID:
13019
        if (value == null) {
13020
          unsetOrderId();
13021
        } else {
13022
          setOrderId((Long)value);
13023
        }
13024
        break;
13025
 
13026
      case CREATED_TIMESTAMP:
13027
        if (value == null) {
13028
          unsetCreatedTimestamp();
13029
        } else {
13030
          setCreatedTimestamp((Long)value);
13031
        }
13032
        break;
13033
 
13034
      case PROMISED_SHIPPING_TIMESTAMP:
13035
        if (value == null) {
13036
          unsetPromisedShippingTimestamp();
13037
        } else {
13038
          setPromisedShippingTimestamp((Long)value);
13039
        }
13040
        break;
13041
 
5945 mandeep.dh 13042
      case QUANTITY:
13043
        if (value == null) {
13044
          unsetQuantity();
13045
        } else {
13046
          setQuantity((Double)value);
13047
        }
13048
        break;
13049
 
13050
      }
13051
    }
13052
 
13053
    public Object getFieldValue(_Fields field) {
13054
      switch (field) {
13055
      case ITEM_ID:
13056
        return Long.valueOf(getItemId());
13057
 
13058
      case WAREHOUSE_ID:
13059
        return Long.valueOf(getWarehouseId());
13060
 
5967 rajveer 13061
      case SOURCE_ID:
13062
        return Long.valueOf(getSourceId());
13063
 
13064
      case ORDER_ID:
13065
        return Long.valueOf(getOrderId());
13066
 
13067
      case CREATED_TIMESTAMP:
13068
        return Long.valueOf(getCreatedTimestamp());
13069
 
13070
      case PROMISED_SHIPPING_TIMESTAMP:
13071
        return Long.valueOf(getPromisedShippingTimestamp());
13072
 
5945 mandeep.dh 13073
      case QUANTITY:
13074
        return Double.valueOf(getQuantity());
13075
 
13076
      }
13077
      throw new IllegalStateException();
13078
    }
13079
 
13080
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13081
    public boolean isSet(_Fields field) {
13082
      if (field == null) {
13083
        throw new IllegalArgumentException();
13084
      }
13085
 
13086
      switch (field) {
13087
      case ITEM_ID:
13088
        return isSetItemId();
13089
      case WAREHOUSE_ID:
13090
        return isSetWarehouseId();
5967 rajveer 13091
      case SOURCE_ID:
13092
        return isSetSourceId();
13093
      case ORDER_ID:
13094
        return isSetOrderId();
13095
      case CREATED_TIMESTAMP:
13096
        return isSetCreatedTimestamp();
13097
      case PROMISED_SHIPPING_TIMESTAMP:
13098
        return isSetPromisedShippingTimestamp();
5945 mandeep.dh 13099
      case QUANTITY:
13100
        return isSetQuantity();
13101
      }
13102
      throw new IllegalStateException();
13103
    }
13104
 
13105
    @Override
13106
    public boolean equals(Object that) {
13107
      if (that == null)
13108
        return false;
13109
      if (that instanceof reserveItemInWarehouse_args)
13110
        return this.equals((reserveItemInWarehouse_args)that);
13111
      return false;
13112
    }
13113
 
13114
    public boolean equals(reserveItemInWarehouse_args that) {
13115
      if (that == null)
13116
        return false;
13117
 
13118
      boolean this_present_itemId = true;
13119
      boolean that_present_itemId = true;
13120
      if (this_present_itemId || that_present_itemId) {
13121
        if (!(this_present_itemId && that_present_itemId))
13122
          return false;
13123
        if (this.itemId != that.itemId)
13124
          return false;
13125
      }
13126
 
13127
      boolean this_present_warehouseId = true;
13128
      boolean that_present_warehouseId = true;
13129
      if (this_present_warehouseId || that_present_warehouseId) {
13130
        if (!(this_present_warehouseId && that_present_warehouseId))
13131
          return false;
13132
        if (this.warehouseId != that.warehouseId)
13133
          return false;
13134
      }
13135
 
5967 rajveer 13136
      boolean this_present_sourceId = true;
13137
      boolean that_present_sourceId = true;
13138
      if (this_present_sourceId || that_present_sourceId) {
13139
        if (!(this_present_sourceId && that_present_sourceId))
13140
          return false;
13141
        if (this.sourceId != that.sourceId)
13142
          return false;
13143
      }
13144
 
13145
      boolean this_present_orderId = true;
13146
      boolean that_present_orderId = true;
13147
      if (this_present_orderId || that_present_orderId) {
13148
        if (!(this_present_orderId && that_present_orderId))
13149
          return false;
13150
        if (this.orderId != that.orderId)
13151
          return false;
13152
      }
13153
 
13154
      boolean this_present_createdTimestamp = true;
13155
      boolean that_present_createdTimestamp = true;
13156
      if (this_present_createdTimestamp || that_present_createdTimestamp) {
13157
        if (!(this_present_createdTimestamp && that_present_createdTimestamp))
13158
          return false;
13159
        if (this.createdTimestamp != that.createdTimestamp)
13160
          return false;
13161
      }
13162
 
13163
      boolean this_present_promisedShippingTimestamp = true;
13164
      boolean that_present_promisedShippingTimestamp = true;
13165
      if (this_present_promisedShippingTimestamp || that_present_promisedShippingTimestamp) {
13166
        if (!(this_present_promisedShippingTimestamp && that_present_promisedShippingTimestamp))
13167
          return false;
13168
        if (this.promisedShippingTimestamp != that.promisedShippingTimestamp)
13169
          return false;
13170
      }
13171
 
5945 mandeep.dh 13172
      boolean this_present_quantity = true;
13173
      boolean that_present_quantity = true;
13174
      if (this_present_quantity || that_present_quantity) {
13175
        if (!(this_present_quantity && that_present_quantity))
13176
          return false;
13177
        if (this.quantity != that.quantity)
13178
          return false;
13179
      }
13180
 
13181
      return true;
13182
    }
13183
 
13184
    @Override
13185
    public int hashCode() {
13186
      return 0;
13187
    }
13188
 
13189
    public int compareTo(reserveItemInWarehouse_args other) {
13190
      if (!getClass().equals(other.getClass())) {
13191
        return getClass().getName().compareTo(other.getClass().getName());
13192
      }
13193
 
13194
      int lastComparison = 0;
13195
      reserveItemInWarehouse_args typedOther = (reserveItemInWarehouse_args)other;
13196
 
13197
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
13198
      if (lastComparison != 0) {
13199
        return lastComparison;
13200
      }
13201
      if (isSetItemId()) {
13202
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
13203
        if (lastComparison != 0) {
13204
          return lastComparison;
13205
        }
13206
      }
13207
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
13208
      if (lastComparison != 0) {
13209
        return lastComparison;
13210
      }
13211
      if (isSetWarehouseId()) {
13212
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
13213
        if (lastComparison != 0) {
13214
          return lastComparison;
13215
        }
13216
      }
5967 rajveer 13217
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
13218
      if (lastComparison != 0) {
13219
        return lastComparison;
13220
      }
13221
      if (isSetSourceId()) {
13222
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
13223
        if (lastComparison != 0) {
13224
          return lastComparison;
13225
        }
13226
      }
13227
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
13228
      if (lastComparison != 0) {
13229
        return lastComparison;
13230
      }
13231
      if (isSetOrderId()) {
13232
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
13233
        if (lastComparison != 0) {
13234
          return lastComparison;
13235
        }
13236
      }
13237
      lastComparison = Boolean.valueOf(isSetCreatedTimestamp()).compareTo(typedOther.isSetCreatedTimestamp());
13238
      if (lastComparison != 0) {
13239
        return lastComparison;
13240
      }
13241
      if (isSetCreatedTimestamp()) {
13242
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.createdTimestamp, typedOther.createdTimestamp);
13243
        if (lastComparison != 0) {
13244
          return lastComparison;
13245
        }
13246
      }
13247
      lastComparison = Boolean.valueOf(isSetPromisedShippingTimestamp()).compareTo(typedOther.isSetPromisedShippingTimestamp());
13248
      if (lastComparison != 0) {
13249
        return lastComparison;
13250
      }
13251
      if (isSetPromisedShippingTimestamp()) {
13252
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.promisedShippingTimestamp, typedOther.promisedShippingTimestamp);
13253
        if (lastComparison != 0) {
13254
          return lastComparison;
13255
        }
13256
      }
5945 mandeep.dh 13257
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
13258
      if (lastComparison != 0) {
13259
        return lastComparison;
13260
      }
13261
      if (isSetQuantity()) {
13262
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
13263
        if (lastComparison != 0) {
13264
          return lastComparison;
13265
        }
13266
      }
13267
      return 0;
13268
    }
13269
 
13270
    public _Fields fieldForId(int fieldId) {
13271
      return _Fields.findByThriftId(fieldId);
13272
    }
13273
 
13274
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13275
      org.apache.thrift.protocol.TField field;
13276
      iprot.readStructBegin();
13277
      while (true)
13278
      {
13279
        field = iprot.readFieldBegin();
13280
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13281
          break;
13282
        }
13283
        switch (field.id) {
13284
          case 1: // ITEM_ID
13285
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13286
              this.itemId = iprot.readI64();
13287
              setItemIdIsSet(true);
13288
            } else { 
13289
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13290
            }
13291
            break;
13292
          case 2: // WAREHOUSE_ID
13293
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13294
              this.warehouseId = iprot.readI64();
13295
              setWarehouseIdIsSet(true);
13296
            } else { 
13297
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13298
            }
13299
            break;
5967 rajveer 13300
          case 3: // SOURCE_ID
13301
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13302
              this.sourceId = iprot.readI64();
13303
              setSourceIdIsSet(true);
13304
            } else { 
13305
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13306
            }
13307
            break;
13308
          case 4: // ORDER_ID
13309
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13310
              this.orderId = iprot.readI64();
13311
              setOrderIdIsSet(true);
13312
            } else { 
13313
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13314
            }
13315
            break;
13316
          case 5: // CREATED_TIMESTAMP
13317
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13318
              this.createdTimestamp = iprot.readI64();
13319
              setCreatedTimestampIsSet(true);
13320
            } else { 
13321
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13322
            }
13323
            break;
13324
          case 6: // PROMISED_SHIPPING_TIMESTAMP
13325
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13326
              this.promisedShippingTimestamp = iprot.readI64();
13327
              setPromisedShippingTimestampIsSet(true);
13328
            } else { 
13329
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13330
            }
13331
            break;
13332
          case 7: // QUANTITY
5945 mandeep.dh 13333
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
13334
              this.quantity = iprot.readDouble();
13335
              setQuantityIsSet(true);
13336
            } else { 
13337
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13338
            }
13339
            break;
13340
          default:
13341
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13342
        }
13343
        iprot.readFieldEnd();
13344
      }
13345
      iprot.readStructEnd();
13346
      validate();
13347
    }
13348
 
13349
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13350
      validate();
13351
 
13352
      oprot.writeStructBegin(STRUCT_DESC);
13353
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
13354
      oprot.writeI64(this.itemId);
13355
      oprot.writeFieldEnd();
13356
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
13357
      oprot.writeI64(this.warehouseId);
13358
      oprot.writeFieldEnd();
5967 rajveer 13359
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
13360
      oprot.writeI64(this.sourceId);
13361
      oprot.writeFieldEnd();
13362
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
13363
      oprot.writeI64(this.orderId);
13364
      oprot.writeFieldEnd();
13365
      oprot.writeFieldBegin(CREATED_TIMESTAMP_FIELD_DESC);
13366
      oprot.writeI64(this.createdTimestamp);
13367
      oprot.writeFieldEnd();
13368
      oprot.writeFieldBegin(PROMISED_SHIPPING_TIMESTAMP_FIELD_DESC);
13369
      oprot.writeI64(this.promisedShippingTimestamp);
13370
      oprot.writeFieldEnd();
5945 mandeep.dh 13371
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
13372
      oprot.writeDouble(this.quantity);
13373
      oprot.writeFieldEnd();
13374
      oprot.writeFieldStop();
13375
      oprot.writeStructEnd();
13376
    }
13377
 
13378
    @Override
13379
    public String toString() {
13380
      StringBuilder sb = new StringBuilder("reserveItemInWarehouse_args(");
13381
      boolean first = true;
13382
 
13383
      sb.append("itemId:");
13384
      sb.append(this.itemId);
13385
      first = false;
13386
      if (!first) sb.append(", ");
13387
      sb.append("warehouseId:");
13388
      sb.append(this.warehouseId);
13389
      first = false;
13390
      if (!first) sb.append(", ");
5967 rajveer 13391
      sb.append("sourceId:");
13392
      sb.append(this.sourceId);
13393
      first = false;
13394
      if (!first) sb.append(", ");
13395
      sb.append("orderId:");
13396
      sb.append(this.orderId);
13397
      first = false;
13398
      if (!first) sb.append(", ");
13399
      sb.append("createdTimestamp:");
13400
      sb.append(this.createdTimestamp);
13401
      first = false;
13402
      if (!first) sb.append(", ");
13403
      sb.append("promisedShippingTimestamp:");
13404
      sb.append(this.promisedShippingTimestamp);
13405
      first = false;
13406
      if (!first) sb.append(", ");
5945 mandeep.dh 13407
      sb.append("quantity:");
13408
      sb.append(this.quantity);
13409
      first = false;
13410
      sb.append(")");
13411
      return sb.toString();
13412
    }
13413
 
13414
    public void validate() throws org.apache.thrift.TException {
13415
      // check for required fields
13416
    }
13417
 
13418
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13419
      try {
13420
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13421
      } catch (org.apache.thrift.TException te) {
13422
        throw new java.io.IOException(te);
13423
      }
13424
    }
13425
 
13426
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13427
      try {
13428
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13429
      } catch (org.apache.thrift.TException te) {
13430
        throw new java.io.IOException(te);
13431
      }
13432
    }
13433
 
13434
  }
13435
 
13436
  public static class reserveItemInWarehouse_result implements org.apache.thrift.TBase<reserveItemInWarehouse_result, reserveItemInWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
13437
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reserveItemInWarehouse_result");
13438
 
13439
    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);
13440
    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);
13441
 
13442
    private boolean success; // required
13443
    private InventoryServiceException cex; // required
13444
 
13445
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13446
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13447
      SUCCESS((short)0, "success"),
13448
      CEX((short)1, "cex");
13449
 
13450
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13451
 
13452
      static {
13453
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13454
          byName.put(field.getFieldName(), field);
13455
        }
13456
      }
13457
 
13458
      /**
13459
       * Find the _Fields constant that matches fieldId, or null if its not found.
13460
       */
13461
      public static _Fields findByThriftId(int fieldId) {
13462
        switch(fieldId) {
13463
          case 0: // SUCCESS
13464
            return SUCCESS;
13465
          case 1: // CEX
13466
            return CEX;
13467
          default:
13468
            return null;
13469
        }
13470
      }
13471
 
13472
      /**
13473
       * Find the _Fields constant that matches fieldId, throwing an exception
13474
       * if it is not found.
13475
       */
13476
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13477
        _Fields fields = findByThriftId(fieldId);
13478
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13479
        return fields;
13480
      }
13481
 
13482
      /**
13483
       * Find the _Fields constant that matches name, or null if its not found.
13484
       */
13485
      public static _Fields findByName(String name) {
13486
        return byName.get(name);
13487
      }
13488
 
13489
      private final short _thriftId;
13490
      private final String _fieldName;
13491
 
13492
      _Fields(short thriftId, String fieldName) {
13493
        _thriftId = thriftId;
13494
        _fieldName = fieldName;
13495
      }
13496
 
13497
      public short getThriftFieldId() {
13498
        return _thriftId;
13499
      }
13500
 
13501
      public String getFieldName() {
13502
        return _fieldName;
13503
      }
13504
    }
13505
 
13506
    // isset id assignments
13507
    private static final int __SUCCESS_ISSET_ID = 0;
13508
    private BitSet __isset_bit_vector = new BitSet(1);
13509
 
13510
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13511
    static {
13512
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13513
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13514
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
13515
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13516
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
13517
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13518
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reserveItemInWarehouse_result.class, metaDataMap);
13519
    }
13520
 
13521
    public reserveItemInWarehouse_result() {
13522
    }
13523
 
13524
    public reserveItemInWarehouse_result(
13525
      boolean success,
13526
      InventoryServiceException cex)
13527
    {
13528
      this();
13529
      this.success = success;
13530
      setSuccessIsSet(true);
13531
      this.cex = cex;
13532
    }
13533
 
13534
    /**
13535
     * Performs a deep copy on <i>other</i>.
13536
     */
13537
    public reserveItemInWarehouse_result(reserveItemInWarehouse_result other) {
13538
      __isset_bit_vector.clear();
13539
      __isset_bit_vector.or(other.__isset_bit_vector);
13540
      this.success = other.success;
13541
      if (other.isSetCex()) {
13542
        this.cex = new InventoryServiceException(other.cex);
13543
      }
13544
    }
13545
 
13546
    public reserveItemInWarehouse_result deepCopy() {
13547
      return new reserveItemInWarehouse_result(this);
13548
    }
13549
 
13550
    @Override
13551
    public void clear() {
13552
      setSuccessIsSet(false);
13553
      this.success = false;
13554
      this.cex = null;
13555
    }
13556
 
13557
    public boolean isSuccess() {
13558
      return this.success;
13559
    }
13560
 
13561
    public void setSuccess(boolean success) {
13562
      this.success = success;
13563
      setSuccessIsSet(true);
13564
    }
13565
 
13566
    public void unsetSuccess() {
13567
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
13568
    }
13569
 
13570
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13571
    public boolean isSetSuccess() {
13572
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
13573
    }
13574
 
13575
    public void setSuccessIsSet(boolean value) {
13576
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
13577
    }
13578
 
13579
    public InventoryServiceException getCex() {
13580
      return this.cex;
13581
    }
13582
 
13583
    public void setCex(InventoryServiceException cex) {
13584
      this.cex = cex;
13585
    }
13586
 
13587
    public void unsetCex() {
13588
      this.cex = null;
13589
    }
13590
 
13591
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
13592
    public boolean isSetCex() {
13593
      return this.cex != null;
13594
    }
13595
 
13596
    public void setCexIsSet(boolean value) {
13597
      if (!value) {
13598
        this.cex = null;
13599
      }
13600
    }
13601
 
13602
    public void setFieldValue(_Fields field, Object value) {
13603
      switch (field) {
13604
      case SUCCESS:
13605
        if (value == null) {
13606
          unsetSuccess();
13607
        } else {
13608
          setSuccess((Boolean)value);
13609
        }
13610
        break;
13611
 
13612
      case CEX:
13613
        if (value == null) {
13614
          unsetCex();
13615
        } else {
13616
          setCex((InventoryServiceException)value);
13617
        }
13618
        break;
13619
 
13620
      }
13621
    }
13622
 
13623
    public Object getFieldValue(_Fields field) {
13624
      switch (field) {
13625
      case SUCCESS:
13626
        return Boolean.valueOf(isSuccess());
13627
 
13628
      case CEX:
13629
        return getCex();
13630
 
13631
      }
13632
      throw new IllegalStateException();
13633
    }
13634
 
13635
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13636
    public boolean isSet(_Fields field) {
13637
      if (field == null) {
13638
        throw new IllegalArgumentException();
13639
      }
13640
 
13641
      switch (field) {
13642
      case SUCCESS:
13643
        return isSetSuccess();
13644
      case CEX:
13645
        return isSetCex();
13646
      }
13647
      throw new IllegalStateException();
13648
    }
13649
 
13650
    @Override
13651
    public boolean equals(Object that) {
13652
      if (that == null)
13653
        return false;
13654
      if (that instanceof reserveItemInWarehouse_result)
13655
        return this.equals((reserveItemInWarehouse_result)that);
13656
      return false;
13657
    }
13658
 
13659
    public boolean equals(reserveItemInWarehouse_result that) {
13660
      if (that == null)
13661
        return false;
13662
 
13663
      boolean this_present_success = true;
13664
      boolean that_present_success = true;
13665
      if (this_present_success || that_present_success) {
13666
        if (!(this_present_success && that_present_success))
13667
          return false;
13668
        if (this.success != that.success)
13669
          return false;
13670
      }
13671
 
13672
      boolean this_present_cex = true && this.isSetCex();
13673
      boolean that_present_cex = true && that.isSetCex();
13674
      if (this_present_cex || that_present_cex) {
13675
        if (!(this_present_cex && that_present_cex))
13676
          return false;
13677
        if (!this.cex.equals(that.cex))
13678
          return false;
13679
      }
13680
 
13681
      return true;
13682
    }
13683
 
13684
    @Override
13685
    public int hashCode() {
13686
      return 0;
13687
    }
13688
 
13689
    public int compareTo(reserveItemInWarehouse_result other) {
13690
      if (!getClass().equals(other.getClass())) {
13691
        return getClass().getName().compareTo(other.getClass().getName());
13692
      }
13693
 
13694
      int lastComparison = 0;
13695
      reserveItemInWarehouse_result typedOther = (reserveItemInWarehouse_result)other;
13696
 
13697
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13698
      if (lastComparison != 0) {
13699
        return lastComparison;
13700
      }
13701
      if (isSetSuccess()) {
13702
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13703
        if (lastComparison != 0) {
13704
          return lastComparison;
13705
        }
13706
      }
13707
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
13708
      if (lastComparison != 0) {
13709
        return lastComparison;
13710
      }
13711
      if (isSetCex()) {
13712
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
13713
        if (lastComparison != 0) {
13714
          return lastComparison;
13715
        }
13716
      }
13717
      return 0;
13718
    }
13719
 
13720
    public _Fields fieldForId(int fieldId) {
13721
      return _Fields.findByThriftId(fieldId);
13722
    }
13723
 
13724
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13725
      org.apache.thrift.protocol.TField field;
13726
      iprot.readStructBegin();
13727
      while (true)
13728
      {
13729
        field = iprot.readFieldBegin();
13730
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13731
          break;
13732
        }
13733
        switch (field.id) {
13734
          case 0: // SUCCESS
13735
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
13736
              this.success = iprot.readBool();
13737
              setSuccessIsSet(true);
13738
            } else { 
13739
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13740
            }
13741
            break;
13742
          case 1: // CEX
13743
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
13744
              this.cex = new InventoryServiceException();
13745
              this.cex.read(iprot);
13746
            } else { 
13747
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13748
            }
13749
            break;
13750
          default:
13751
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13752
        }
13753
        iprot.readFieldEnd();
13754
      }
13755
      iprot.readStructEnd();
13756
      validate();
13757
    }
13758
 
13759
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13760
      oprot.writeStructBegin(STRUCT_DESC);
13761
 
13762
      if (this.isSetSuccess()) {
13763
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
13764
        oprot.writeBool(this.success);
13765
        oprot.writeFieldEnd();
13766
      } else if (this.isSetCex()) {
13767
        oprot.writeFieldBegin(CEX_FIELD_DESC);
13768
        this.cex.write(oprot);
13769
        oprot.writeFieldEnd();
13770
      }
13771
      oprot.writeFieldStop();
13772
      oprot.writeStructEnd();
13773
    }
13774
 
13775
    @Override
13776
    public String toString() {
13777
      StringBuilder sb = new StringBuilder("reserveItemInWarehouse_result(");
13778
      boolean first = true;
13779
 
13780
      sb.append("success:");
13781
      sb.append(this.success);
13782
      first = false;
13783
      if (!first) sb.append(", ");
13784
      sb.append("cex:");
13785
      if (this.cex == null) {
13786
        sb.append("null");
13787
      } else {
13788
        sb.append(this.cex);
13789
      }
13790
      first = false;
13791
      sb.append(")");
13792
      return sb.toString();
13793
    }
13794
 
13795
    public void validate() throws org.apache.thrift.TException {
13796
      // check for required fields
13797
    }
13798
 
13799
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13800
      try {
13801
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13802
      } catch (org.apache.thrift.TException te) {
13803
        throw new java.io.IOException(te);
13804
      }
13805
    }
13806
 
13807
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13808
      try {
13809
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13810
      } catch (org.apache.thrift.TException te) {
13811
        throw new java.io.IOException(te);
13812
      }
13813
    }
13814
 
13815
  }
13816
 
13817
  public static class reduceReservationCount_args implements org.apache.thrift.TBase<reduceReservationCount_args, reduceReservationCount_args._Fields>, java.io.Serializable, Cloneable   {
13818
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reduceReservationCount_args");
13819
 
13820
    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);
13821
    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 13822
    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);
13823
    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);
13824
    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 13825
 
13826
    private long itemId; // required
13827
    private long warehouseId; // required
5967 rajveer 13828
    private long sourceId; // required
13829
    private long orderId; // required
5945 mandeep.dh 13830
    private double quantity; // required
13831
 
13832
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13833
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13834
      ITEM_ID((short)1, "itemId"),
13835
      WAREHOUSE_ID((short)2, "warehouseId"),
5967 rajveer 13836
      SOURCE_ID((short)3, "sourceId"),
13837
      ORDER_ID((short)4, "orderId"),
13838
      QUANTITY((short)5, "quantity");
5945 mandeep.dh 13839
 
13840
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13841
 
13842
      static {
13843
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13844
          byName.put(field.getFieldName(), field);
13845
        }
13846
      }
13847
 
13848
      /**
13849
       * Find the _Fields constant that matches fieldId, or null if its not found.
13850
       */
13851
      public static _Fields findByThriftId(int fieldId) {
13852
        switch(fieldId) {
13853
          case 1: // ITEM_ID
13854
            return ITEM_ID;
13855
          case 2: // WAREHOUSE_ID
13856
            return WAREHOUSE_ID;
5967 rajveer 13857
          case 3: // SOURCE_ID
13858
            return SOURCE_ID;
13859
          case 4: // ORDER_ID
13860
            return ORDER_ID;
13861
          case 5: // QUANTITY
5945 mandeep.dh 13862
            return QUANTITY;
13863
          default:
13864
            return null;
13865
        }
13866
      }
13867
 
13868
      /**
13869
       * Find the _Fields constant that matches fieldId, throwing an exception
13870
       * if it is not found.
13871
       */
13872
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13873
        _Fields fields = findByThriftId(fieldId);
13874
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13875
        return fields;
13876
      }
13877
 
13878
      /**
13879
       * Find the _Fields constant that matches name, or null if its not found.
13880
       */
13881
      public static _Fields findByName(String name) {
13882
        return byName.get(name);
13883
      }
13884
 
13885
      private final short _thriftId;
13886
      private final String _fieldName;
13887
 
13888
      _Fields(short thriftId, String fieldName) {
13889
        _thriftId = thriftId;
13890
        _fieldName = fieldName;
13891
      }
13892
 
13893
      public short getThriftFieldId() {
13894
        return _thriftId;
13895
      }
13896
 
13897
      public String getFieldName() {
13898
        return _fieldName;
13899
      }
13900
    }
13901
 
13902
    // isset id assignments
13903
    private static final int __ITEMID_ISSET_ID = 0;
13904
    private static final int __WAREHOUSEID_ISSET_ID = 1;
5967 rajveer 13905
    private static final int __SOURCEID_ISSET_ID = 2;
13906
    private static final int __ORDERID_ISSET_ID = 3;
13907
    private static final int __QUANTITY_ISSET_ID = 4;
13908
    private BitSet __isset_bit_vector = new BitSet(5);
5945 mandeep.dh 13909
 
13910
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13911
    static {
13912
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13913
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13914
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13915
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13916
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5967 rajveer 13917
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13918
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13919
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13920
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5945 mandeep.dh 13921
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13922
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
13923
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13924
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reduceReservationCount_args.class, metaDataMap);
13925
    }
13926
 
13927
    public reduceReservationCount_args() {
13928
    }
13929
 
13930
    public reduceReservationCount_args(
13931
      long itemId,
13932
      long warehouseId,
5967 rajveer 13933
      long sourceId,
13934
      long orderId,
5945 mandeep.dh 13935
      double quantity)
13936
    {
13937
      this();
13938
      this.itemId = itemId;
13939
      setItemIdIsSet(true);
13940
      this.warehouseId = warehouseId;
13941
      setWarehouseIdIsSet(true);
5967 rajveer 13942
      this.sourceId = sourceId;
13943
      setSourceIdIsSet(true);
13944
      this.orderId = orderId;
13945
      setOrderIdIsSet(true);
5945 mandeep.dh 13946
      this.quantity = quantity;
13947
      setQuantityIsSet(true);
13948
    }
13949
 
13950
    /**
13951
     * Performs a deep copy on <i>other</i>.
13952
     */
13953
    public reduceReservationCount_args(reduceReservationCount_args other) {
13954
      __isset_bit_vector.clear();
13955
      __isset_bit_vector.or(other.__isset_bit_vector);
13956
      this.itemId = other.itemId;
13957
      this.warehouseId = other.warehouseId;
5967 rajveer 13958
      this.sourceId = other.sourceId;
13959
      this.orderId = other.orderId;
5945 mandeep.dh 13960
      this.quantity = other.quantity;
13961
    }
13962
 
13963
    public reduceReservationCount_args deepCopy() {
13964
      return new reduceReservationCount_args(this);
13965
    }
13966
 
13967
    @Override
13968
    public void clear() {
13969
      setItemIdIsSet(false);
13970
      this.itemId = 0;
13971
      setWarehouseIdIsSet(false);
13972
      this.warehouseId = 0;
5967 rajveer 13973
      setSourceIdIsSet(false);
13974
      this.sourceId = 0;
13975
      setOrderIdIsSet(false);
13976
      this.orderId = 0;
5945 mandeep.dh 13977
      setQuantityIsSet(false);
13978
      this.quantity = 0.0;
13979
    }
13980
 
13981
    public long getItemId() {
13982
      return this.itemId;
13983
    }
13984
 
13985
    public void setItemId(long itemId) {
13986
      this.itemId = itemId;
13987
      setItemIdIsSet(true);
13988
    }
13989
 
13990
    public void unsetItemId() {
13991
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
13992
    }
13993
 
13994
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
13995
    public boolean isSetItemId() {
13996
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
13997
    }
13998
 
13999
    public void setItemIdIsSet(boolean value) {
14000
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
14001
    }
14002
 
14003
    public long getWarehouseId() {
14004
      return this.warehouseId;
14005
    }
14006
 
14007
    public void setWarehouseId(long warehouseId) {
14008
      this.warehouseId = warehouseId;
14009
      setWarehouseIdIsSet(true);
14010
    }
14011
 
14012
    public void unsetWarehouseId() {
14013
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
14014
    }
14015
 
14016
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
14017
    public boolean isSetWarehouseId() {
14018
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
14019
    }
14020
 
14021
    public void setWarehouseIdIsSet(boolean value) {
14022
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
14023
    }
14024
 
5967 rajveer 14025
    public long getSourceId() {
14026
      return this.sourceId;
14027
    }
14028
 
14029
    public void setSourceId(long sourceId) {
14030
      this.sourceId = sourceId;
14031
      setSourceIdIsSet(true);
14032
    }
14033
 
14034
    public void unsetSourceId() {
14035
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
14036
    }
14037
 
14038
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
14039
    public boolean isSetSourceId() {
14040
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
14041
    }
14042
 
14043
    public void setSourceIdIsSet(boolean value) {
14044
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
14045
    }
14046
 
14047
    public long getOrderId() {
14048
      return this.orderId;
14049
    }
14050
 
14051
    public void setOrderId(long orderId) {
14052
      this.orderId = orderId;
14053
      setOrderIdIsSet(true);
14054
    }
14055
 
14056
    public void unsetOrderId() {
14057
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
14058
    }
14059
 
14060
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
14061
    public boolean isSetOrderId() {
14062
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
14063
    }
14064
 
14065
    public void setOrderIdIsSet(boolean value) {
14066
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
14067
    }
14068
 
5945 mandeep.dh 14069
    public double getQuantity() {
14070
      return this.quantity;
14071
    }
14072
 
14073
    public void setQuantity(double quantity) {
14074
      this.quantity = quantity;
14075
      setQuantityIsSet(true);
14076
    }
14077
 
14078
    public void unsetQuantity() {
14079
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
14080
    }
14081
 
14082
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
14083
    public boolean isSetQuantity() {
14084
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
14085
    }
14086
 
14087
    public void setQuantityIsSet(boolean value) {
14088
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
14089
    }
14090
 
14091
    public void setFieldValue(_Fields field, Object value) {
14092
      switch (field) {
14093
      case ITEM_ID:
14094
        if (value == null) {
14095
          unsetItemId();
14096
        } else {
14097
          setItemId((Long)value);
14098
        }
14099
        break;
14100
 
14101
      case WAREHOUSE_ID:
14102
        if (value == null) {
14103
          unsetWarehouseId();
14104
        } else {
14105
          setWarehouseId((Long)value);
14106
        }
14107
        break;
14108
 
5967 rajveer 14109
      case SOURCE_ID:
14110
        if (value == null) {
14111
          unsetSourceId();
14112
        } else {
14113
          setSourceId((Long)value);
14114
        }
14115
        break;
14116
 
14117
      case ORDER_ID:
14118
        if (value == null) {
14119
          unsetOrderId();
14120
        } else {
14121
          setOrderId((Long)value);
14122
        }
14123
        break;
14124
 
5945 mandeep.dh 14125
      case QUANTITY:
14126
        if (value == null) {
14127
          unsetQuantity();
14128
        } else {
14129
          setQuantity((Double)value);
14130
        }
14131
        break;
14132
 
14133
      }
14134
    }
14135
 
14136
    public Object getFieldValue(_Fields field) {
14137
      switch (field) {
14138
      case ITEM_ID:
14139
        return Long.valueOf(getItemId());
14140
 
14141
      case WAREHOUSE_ID:
14142
        return Long.valueOf(getWarehouseId());
14143
 
5967 rajveer 14144
      case SOURCE_ID:
14145
        return Long.valueOf(getSourceId());
14146
 
14147
      case ORDER_ID:
14148
        return Long.valueOf(getOrderId());
14149
 
5945 mandeep.dh 14150
      case QUANTITY:
14151
        return Double.valueOf(getQuantity());
14152
 
14153
      }
14154
      throw new IllegalStateException();
14155
    }
14156
 
14157
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14158
    public boolean isSet(_Fields field) {
14159
      if (field == null) {
14160
        throw new IllegalArgumentException();
14161
      }
14162
 
14163
      switch (field) {
14164
      case ITEM_ID:
14165
        return isSetItemId();
14166
      case WAREHOUSE_ID:
14167
        return isSetWarehouseId();
5967 rajveer 14168
      case SOURCE_ID:
14169
        return isSetSourceId();
14170
      case ORDER_ID:
14171
        return isSetOrderId();
5945 mandeep.dh 14172
      case QUANTITY:
14173
        return isSetQuantity();
14174
      }
14175
      throw new IllegalStateException();
14176
    }
14177
 
14178
    @Override
14179
    public boolean equals(Object that) {
14180
      if (that == null)
14181
        return false;
14182
      if (that instanceof reduceReservationCount_args)
14183
        return this.equals((reduceReservationCount_args)that);
14184
      return false;
14185
    }
14186
 
14187
    public boolean equals(reduceReservationCount_args that) {
14188
      if (that == null)
14189
        return false;
14190
 
14191
      boolean this_present_itemId = true;
14192
      boolean that_present_itemId = true;
14193
      if (this_present_itemId || that_present_itemId) {
14194
        if (!(this_present_itemId && that_present_itemId))
14195
          return false;
14196
        if (this.itemId != that.itemId)
14197
          return false;
14198
      }
14199
 
14200
      boolean this_present_warehouseId = true;
14201
      boolean that_present_warehouseId = true;
14202
      if (this_present_warehouseId || that_present_warehouseId) {
14203
        if (!(this_present_warehouseId && that_present_warehouseId))
14204
          return false;
14205
        if (this.warehouseId != that.warehouseId)
14206
          return false;
14207
      }
14208
 
5967 rajveer 14209
      boolean this_present_sourceId = true;
14210
      boolean that_present_sourceId = true;
14211
      if (this_present_sourceId || that_present_sourceId) {
14212
        if (!(this_present_sourceId && that_present_sourceId))
14213
          return false;
14214
        if (this.sourceId != that.sourceId)
14215
          return false;
14216
      }
14217
 
14218
      boolean this_present_orderId = true;
14219
      boolean that_present_orderId = true;
14220
      if (this_present_orderId || that_present_orderId) {
14221
        if (!(this_present_orderId && that_present_orderId))
14222
          return false;
14223
        if (this.orderId != that.orderId)
14224
          return false;
14225
      }
14226
 
5945 mandeep.dh 14227
      boolean this_present_quantity = true;
14228
      boolean that_present_quantity = true;
14229
      if (this_present_quantity || that_present_quantity) {
14230
        if (!(this_present_quantity && that_present_quantity))
14231
          return false;
14232
        if (this.quantity != that.quantity)
14233
          return false;
14234
      }
14235
 
14236
      return true;
14237
    }
14238
 
14239
    @Override
14240
    public int hashCode() {
14241
      return 0;
14242
    }
14243
 
14244
    public int compareTo(reduceReservationCount_args other) {
14245
      if (!getClass().equals(other.getClass())) {
14246
        return getClass().getName().compareTo(other.getClass().getName());
14247
      }
14248
 
14249
      int lastComparison = 0;
14250
      reduceReservationCount_args typedOther = (reduceReservationCount_args)other;
14251
 
14252
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
14253
      if (lastComparison != 0) {
14254
        return lastComparison;
14255
      }
14256
      if (isSetItemId()) {
14257
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
14258
        if (lastComparison != 0) {
14259
          return lastComparison;
14260
        }
14261
      }
14262
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
14263
      if (lastComparison != 0) {
14264
        return lastComparison;
14265
      }
14266
      if (isSetWarehouseId()) {
14267
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
14268
        if (lastComparison != 0) {
14269
          return lastComparison;
14270
        }
14271
      }
5967 rajveer 14272
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
14273
      if (lastComparison != 0) {
14274
        return lastComparison;
14275
      }
14276
      if (isSetSourceId()) {
14277
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
14278
        if (lastComparison != 0) {
14279
          return lastComparison;
14280
        }
14281
      }
14282
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
14283
      if (lastComparison != 0) {
14284
        return lastComparison;
14285
      }
14286
      if (isSetOrderId()) {
14287
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
14288
        if (lastComparison != 0) {
14289
          return lastComparison;
14290
        }
14291
      }
5945 mandeep.dh 14292
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
14293
      if (lastComparison != 0) {
14294
        return lastComparison;
14295
      }
14296
      if (isSetQuantity()) {
14297
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
14298
        if (lastComparison != 0) {
14299
          return lastComparison;
14300
        }
14301
      }
14302
      return 0;
14303
    }
14304
 
14305
    public _Fields fieldForId(int fieldId) {
14306
      return _Fields.findByThriftId(fieldId);
14307
    }
14308
 
14309
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14310
      org.apache.thrift.protocol.TField field;
14311
      iprot.readStructBegin();
14312
      while (true)
14313
      {
14314
        field = iprot.readFieldBegin();
14315
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14316
          break;
14317
        }
14318
        switch (field.id) {
14319
          case 1: // ITEM_ID
14320
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14321
              this.itemId = iprot.readI64();
14322
              setItemIdIsSet(true);
14323
            } else { 
14324
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14325
            }
14326
            break;
14327
          case 2: // WAREHOUSE_ID
14328
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14329
              this.warehouseId = iprot.readI64();
14330
              setWarehouseIdIsSet(true);
14331
            } else { 
14332
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14333
            }
14334
            break;
5967 rajveer 14335
          case 3: // SOURCE_ID
14336
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14337
              this.sourceId = iprot.readI64();
14338
              setSourceIdIsSet(true);
14339
            } else { 
14340
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14341
            }
14342
            break;
14343
          case 4: // ORDER_ID
14344
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14345
              this.orderId = iprot.readI64();
14346
              setOrderIdIsSet(true);
14347
            } else { 
14348
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14349
            }
14350
            break;
14351
          case 5: // QUANTITY
5945 mandeep.dh 14352
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
14353
              this.quantity = iprot.readDouble();
14354
              setQuantityIsSet(true);
14355
            } else { 
14356
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14357
            }
14358
            break;
14359
          default:
14360
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14361
        }
14362
        iprot.readFieldEnd();
14363
      }
14364
      iprot.readStructEnd();
14365
      validate();
14366
    }
14367
 
14368
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14369
      validate();
14370
 
14371
      oprot.writeStructBegin(STRUCT_DESC);
14372
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
14373
      oprot.writeI64(this.itemId);
14374
      oprot.writeFieldEnd();
14375
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
14376
      oprot.writeI64(this.warehouseId);
14377
      oprot.writeFieldEnd();
5967 rajveer 14378
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
14379
      oprot.writeI64(this.sourceId);
14380
      oprot.writeFieldEnd();
14381
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
14382
      oprot.writeI64(this.orderId);
14383
      oprot.writeFieldEnd();
5945 mandeep.dh 14384
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
14385
      oprot.writeDouble(this.quantity);
14386
      oprot.writeFieldEnd();
14387
      oprot.writeFieldStop();
14388
      oprot.writeStructEnd();
14389
    }
14390
 
14391
    @Override
14392
    public String toString() {
14393
      StringBuilder sb = new StringBuilder("reduceReservationCount_args(");
14394
      boolean first = true;
14395
 
14396
      sb.append("itemId:");
14397
      sb.append(this.itemId);
14398
      first = false;
14399
      if (!first) sb.append(", ");
14400
      sb.append("warehouseId:");
14401
      sb.append(this.warehouseId);
14402
      first = false;
14403
      if (!first) sb.append(", ");
5967 rajveer 14404
      sb.append("sourceId:");
14405
      sb.append(this.sourceId);
14406
      first = false;
14407
      if (!first) sb.append(", ");
14408
      sb.append("orderId:");
14409
      sb.append(this.orderId);
14410
      first = false;
14411
      if (!first) sb.append(", ");
5945 mandeep.dh 14412
      sb.append("quantity:");
14413
      sb.append(this.quantity);
14414
      first = false;
14415
      sb.append(")");
14416
      return sb.toString();
14417
    }
14418
 
14419
    public void validate() throws org.apache.thrift.TException {
14420
      // check for required fields
14421
    }
14422
 
14423
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14424
      try {
14425
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14426
      } catch (org.apache.thrift.TException te) {
14427
        throw new java.io.IOException(te);
14428
      }
14429
    }
14430
 
14431
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14432
      try {
14433
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14434
      } catch (org.apache.thrift.TException te) {
14435
        throw new java.io.IOException(te);
14436
      }
14437
    }
14438
 
14439
  }
14440
 
14441
  public static class reduceReservationCount_result implements org.apache.thrift.TBase<reduceReservationCount_result, reduceReservationCount_result._Fields>, java.io.Serializable, Cloneable   {
14442
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reduceReservationCount_result");
14443
 
14444
    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);
14445
    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);
14446
 
14447
    private boolean success; // required
14448
    private InventoryServiceException cex; // required
14449
 
14450
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14451
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14452
      SUCCESS((short)0, "success"),
14453
      CEX((short)1, "cex");
14454
 
14455
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14456
 
14457
      static {
14458
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14459
          byName.put(field.getFieldName(), field);
14460
        }
14461
      }
14462
 
14463
      /**
14464
       * Find the _Fields constant that matches fieldId, or null if its not found.
14465
       */
14466
      public static _Fields findByThriftId(int fieldId) {
14467
        switch(fieldId) {
14468
          case 0: // SUCCESS
14469
            return SUCCESS;
14470
          case 1: // CEX
14471
            return CEX;
14472
          default:
14473
            return null;
14474
        }
14475
      }
14476
 
14477
      /**
14478
       * Find the _Fields constant that matches fieldId, throwing an exception
14479
       * if it is not found.
14480
       */
14481
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14482
        _Fields fields = findByThriftId(fieldId);
14483
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14484
        return fields;
14485
      }
14486
 
14487
      /**
14488
       * Find the _Fields constant that matches name, or null if its not found.
14489
       */
14490
      public static _Fields findByName(String name) {
14491
        return byName.get(name);
14492
      }
14493
 
14494
      private final short _thriftId;
14495
      private final String _fieldName;
14496
 
14497
      _Fields(short thriftId, String fieldName) {
14498
        _thriftId = thriftId;
14499
        _fieldName = fieldName;
14500
      }
14501
 
14502
      public short getThriftFieldId() {
14503
        return _thriftId;
14504
      }
14505
 
14506
      public String getFieldName() {
14507
        return _fieldName;
14508
      }
14509
    }
14510
 
14511
    // isset id assignments
14512
    private static final int __SUCCESS_ISSET_ID = 0;
14513
    private BitSet __isset_bit_vector = new BitSet(1);
14514
 
14515
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14516
    static {
14517
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14518
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14519
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
14520
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14521
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
14522
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14523
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reduceReservationCount_result.class, metaDataMap);
14524
    }
14525
 
14526
    public reduceReservationCount_result() {
14527
    }
14528
 
14529
    public reduceReservationCount_result(
14530
      boolean success,
14531
      InventoryServiceException cex)
14532
    {
14533
      this();
14534
      this.success = success;
14535
      setSuccessIsSet(true);
14536
      this.cex = cex;
14537
    }
14538
 
14539
    /**
14540
     * Performs a deep copy on <i>other</i>.
14541
     */
14542
    public reduceReservationCount_result(reduceReservationCount_result other) {
14543
      __isset_bit_vector.clear();
14544
      __isset_bit_vector.or(other.__isset_bit_vector);
14545
      this.success = other.success;
14546
      if (other.isSetCex()) {
14547
        this.cex = new InventoryServiceException(other.cex);
14548
      }
14549
    }
14550
 
14551
    public reduceReservationCount_result deepCopy() {
14552
      return new reduceReservationCount_result(this);
14553
    }
14554
 
14555
    @Override
14556
    public void clear() {
14557
      setSuccessIsSet(false);
14558
      this.success = false;
14559
      this.cex = null;
14560
    }
14561
 
14562
    public boolean isSuccess() {
14563
      return this.success;
14564
    }
14565
 
14566
    public void setSuccess(boolean success) {
14567
      this.success = success;
14568
      setSuccessIsSet(true);
14569
    }
14570
 
14571
    public void unsetSuccess() {
14572
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
14573
    }
14574
 
14575
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
14576
    public boolean isSetSuccess() {
14577
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
14578
    }
14579
 
14580
    public void setSuccessIsSet(boolean value) {
14581
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
14582
    }
14583
 
14584
    public InventoryServiceException getCex() {
14585
      return this.cex;
14586
    }
14587
 
14588
    public void setCex(InventoryServiceException cex) {
14589
      this.cex = cex;
14590
    }
14591
 
14592
    public void unsetCex() {
14593
      this.cex = null;
14594
    }
14595
 
14596
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
14597
    public boolean isSetCex() {
14598
      return this.cex != null;
14599
    }
14600
 
14601
    public void setCexIsSet(boolean value) {
14602
      if (!value) {
14603
        this.cex = null;
14604
      }
14605
    }
14606
 
14607
    public void setFieldValue(_Fields field, Object value) {
14608
      switch (field) {
14609
      case SUCCESS:
14610
        if (value == null) {
14611
          unsetSuccess();
14612
        } else {
14613
          setSuccess((Boolean)value);
14614
        }
14615
        break;
14616
 
14617
      case CEX:
14618
        if (value == null) {
14619
          unsetCex();
14620
        } else {
14621
          setCex((InventoryServiceException)value);
14622
        }
14623
        break;
14624
 
14625
      }
14626
    }
14627
 
14628
    public Object getFieldValue(_Fields field) {
14629
      switch (field) {
14630
      case SUCCESS:
14631
        return Boolean.valueOf(isSuccess());
14632
 
14633
      case CEX:
14634
        return getCex();
14635
 
14636
      }
14637
      throw new IllegalStateException();
14638
    }
14639
 
14640
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14641
    public boolean isSet(_Fields field) {
14642
      if (field == null) {
14643
        throw new IllegalArgumentException();
14644
      }
14645
 
14646
      switch (field) {
14647
      case SUCCESS:
14648
        return isSetSuccess();
14649
      case CEX:
14650
        return isSetCex();
14651
      }
14652
      throw new IllegalStateException();
14653
    }
14654
 
14655
    @Override
14656
    public boolean equals(Object that) {
14657
      if (that == null)
14658
        return false;
14659
      if (that instanceof reduceReservationCount_result)
14660
        return this.equals((reduceReservationCount_result)that);
14661
      return false;
14662
    }
14663
 
14664
    public boolean equals(reduceReservationCount_result that) {
14665
      if (that == null)
14666
        return false;
14667
 
14668
      boolean this_present_success = true;
14669
      boolean that_present_success = true;
14670
      if (this_present_success || that_present_success) {
14671
        if (!(this_present_success && that_present_success))
14672
          return false;
14673
        if (this.success != that.success)
14674
          return false;
14675
      }
14676
 
14677
      boolean this_present_cex = true && this.isSetCex();
14678
      boolean that_present_cex = true && that.isSetCex();
14679
      if (this_present_cex || that_present_cex) {
14680
        if (!(this_present_cex && that_present_cex))
14681
          return false;
14682
        if (!this.cex.equals(that.cex))
14683
          return false;
14684
      }
14685
 
14686
      return true;
14687
    }
14688
 
14689
    @Override
14690
    public int hashCode() {
14691
      return 0;
14692
    }
14693
 
14694
    public int compareTo(reduceReservationCount_result other) {
14695
      if (!getClass().equals(other.getClass())) {
14696
        return getClass().getName().compareTo(other.getClass().getName());
14697
      }
14698
 
14699
      int lastComparison = 0;
14700
      reduceReservationCount_result typedOther = (reduceReservationCount_result)other;
14701
 
14702
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
14703
      if (lastComparison != 0) {
14704
        return lastComparison;
14705
      }
14706
      if (isSetSuccess()) {
14707
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
14708
        if (lastComparison != 0) {
14709
          return lastComparison;
14710
        }
14711
      }
14712
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
14713
      if (lastComparison != 0) {
14714
        return lastComparison;
14715
      }
14716
      if (isSetCex()) {
14717
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
14718
        if (lastComparison != 0) {
14719
          return lastComparison;
14720
        }
14721
      }
14722
      return 0;
14723
    }
14724
 
14725
    public _Fields fieldForId(int fieldId) {
14726
      return _Fields.findByThriftId(fieldId);
14727
    }
14728
 
14729
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14730
      org.apache.thrift.protocol.TField field;
14731
      iprot.readStructBegin();
14732
      while (true)
14733
      {
14734
        field = iprot.readFieldBegin();
14735
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14736
          break;
14737
        }
14738
        switch (field.id) {
14739
          case 0: // SUCCESS
14740
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
14741
              this.success = iprot.readBool();
14742
              setSuccessIsSet(true);
14743
            } else { 
14744
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14745
            }
14746
            break;
14747
          case 1: // CEX
14748
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
14749
              this.cex = new InventoryServiceException();
14750
              this.cex.read(iprot);
14751
            } else { 
14752
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14753
            }
14754
            break;
14755
          default:
14756
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14757
        }
14758
        iprot.readFieldEnd();
14759
      }
14760
      iprot.readStructEnd();
14761
      validate();
14762
    }
14763
 
14764
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14765
      oprot.writeStructBegin(STRUCT_DESC);
14766
 
14767
      if (this.isSetSuccess()) {
14768
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
14769
        oprot.writeBool(this.success);
14770
        oprot.writeFieldEnd();
14771
      } else if (this.isSetCex()) {
14772
        oprot.writeFieldBegin(CEX_FIELD_DESC);
14773
        this.cex.write(oprot);
14774
        oprot.writeFieldEnd();
14775
      }
14776
      oprot.writeFieldStop();
14777
      oprot.writeStructEnd();
14778
    }
14779
 
14780
    @Override
14781
    public String toString() {
14782
      StringBuilder sb = new StringBuilder("reduceReservationCount_result(");
14783
      boolean first = true;
14784
 
14785
      sb.append("success:");
14786
      sb.append(this.success);
14787
      first = false;
14788
      if (!first) sb.append(", ");
14789
      sb.append("cex:");
14790
      if (this.cex == null) {
14791
        sb.append("null");
14792
      } else {
14793
        sb.append(this.cex);
14794
      }
14795
      first = false;
14796
      sb.append(")");
14797
      return sb.toString();
14798
    }
14799
 
14800
    public void validate() throws org.apache.thrift.TException {
14801
      // check for required fields
14802
    }
14803
 
14804
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14805
      try {
14806
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14807
      } catch (org.apache.thrift.TException te) {
14808
        throw new java.io.IOException(te);
14809
      }
14810
    }
14811
 
14812
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14813
      try {
14814
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14815
      } catch (org.apache.thrift.TException te) {
14816
        throw new java.io.IOException(te);
14817
      }
14818
    }
14819
 
14820
  }
14821
 
14822
  public static class getItemPricing_args implements org.apache.thrift.TBase<getItemPricing_args, getItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
14823
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemPricing_args");
14824
 
14825
    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);
14826
    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);
14827
 
14828
    private long itemId; // required
14829
    private long vendorId; // required
14830
 
14831
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14832
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14833
      ITEM_ID((short)1, "itemId"),
14834
      VENDOR_ID((short)2, "vendorId");
14835
 
14836
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14837
 
14838
      static {
14839
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14840
          byName.put(field.getFieldName(), field);
14841
        }
14842
      }
14843
 
14844
      /**
14845
       * Find the _Fields constant that matches fieldId, or null if its not found.
14846
       */
14847
      public static _Fields findByThriftId(int fieldId) {
14848
        switch(fieldId) {
14849
          case 1: // ITEM_ID
14850
            return ITEM_ID;
14851
          case 2: // VENDOR_ID
14852
            return VENDOR_ID;
14853
          default:
14854
            return null;
14855
        }
14856
      }
14857
 
14858
      /**
14859
       * Find the _Fields constant that matches fieldId, throwing an exception
14860
       * if it is not found.
14861
       */
14862
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14863
        _Fields fields = findByThriftId(fieldId);
14864
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14865
        return fields;
14866
      }
14867
 
14868
      /**
14869
       * Find the _Fields constant that matches name, or null if its not found.
14870
       */
14871
      public static _Fields findByName(String name) {
14872
        return byName.get(name);
14873
      }
14874
 
14875
      private final short _thriftId;
14876
      private final String _fieldName;
14877
 
14878
      _Fields(short thriftId, String fieldName) {
14879
        _thriftId = thriftId;
14880
        _fieldName = fieldName;
14881
      }
14882
 
14883
      public short getThriftFieldId() {
14884
        return _thriftId;
14885
      }
14886
 
14887
      public String getFieldName() {
14888
        return _fieldName;
14889
      }
14890
    }
14891
 
14892
    // isset id assignments
14893
    private static final int __ITEMID_ISSET_ID = 0;
14894
    private static final int __VENDORID_ISSET_ID = 1;
14895
    private BitSet __isset_bit_vector = new BitSet(2);
14896
 
14897
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14898
    static {
14899
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14900
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14901
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14902
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14903
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14904
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14905
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemPricing_args.class, metaDataMap);
14906
    }
14907
 
14908
    public getItemPricing_args() {
14909
    }
14910
 
14911
    public getItemPricing_args(
14912
      long itemId,
14913
      long vendorId)
14914
    {
14915
      this();
14916
      this.itemId = itemId;
14917
      setItemIdIsSet(true);
14918
      this.vendorId = vendorId;
14919
      setVendorIdIsSet(true);
14920
    }
14921
 
14922
    /**
14923
     * Performs a deep copy on <i>other</i>.
14924
     */
14925
    public getItemPricing_args(getItemPricing_args other) {
14926
      __isset_bit_vector.clear();
14927
      __isset_bit_vector.or(other.__isset_bit_vector);
14928
      this.itemId = other.itemId;
14929
      this.vendorId = other.vendorId;
14930
    }
14931
 
14932
    public getItemPricing_args deepCopy() {
14933
      return new getItemPricing_args(this);
14934
    }
14935
 
14936
    @Override
14937
    public void clear() {
14938
      setItemIdIsSet(false);
14939
      this.itemId = 0;
14940
      setVendorIdIsSet(false);
14941
      this.vendorId = 0;
14942
    }
14943
 
14944
    public long getItemId() {
14945
      return this.itemId;
14946
    }
14947
 
14948
    public void setItemId(long itemId) {
14949
      this.itemId = itemId;
14950
      setItemIdIsSet(true);
14951
    }
14952
 
14953
    public void unsetItemId() {
14954
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
14955
    }
14956
 
14957
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
14958
    public boolean isSetItemId() {
14959
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
14960
    }
14961
 
14962
    public void setItemIdIsSet(boolean value) {
14963
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
14964
    }
14965
 
14966
    public long getVendorId() {
14967
      return this.vendorId;
14968
    }
14969
 
14970
    public void setVendorId(long vendorId) {
14971
      this.vendorId = vendorId;
14972
      setVendorIdIsSet(true);
14973
    }
14974
 
14975
    public void unsetVendorId() {
14976
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
14977
    }
14978
 
14979
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
14980
    public boolean isSetVendorId() {
14981
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
14982
    }
14983
 
14984
    public void setVendorIdIsSet(boolean value) {
14985
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
14986
    }
14987
 
14988
    public void setFieldValue(_Fields field, Object value) {
14989
      switch (field) {
14990
      case ITEM_ID:
14991
        if (value == null) {
14992
          unsetItemId();
14993
        } else {
14994
          setItemId((Long)value);
14995
        }
14996
        break;
14997
 
14998
      case VENDOR_ID:
14999
        if (value == null) {
15000
          unsetVendorId();
15001
        } else {
15002
          setVendorId((Long)value);
15003
        }
15004
        break;
15005
 
15006
      }
15007
    }
15008
 
15009
    public Object getFieldValue(_Fields field) {
15010
      switch (field) {
15011
      case ITEM_ID:
15012
        return Long.valueOf(getItemId());
15013
 
15014
      case VENDOR_ID:
15015
        return Long.valueOf(getVendorId());
15016
 
15017
      }
15018
      throw new IllegalStateException();
15019
    }
15020
 
15021
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15022
    public boolean isSet(_Fields field) {
15023
      if (field == null) {
15024
        throw new IllegalArgumentException();
15025
      }
15026
 
15027
      switch (field) {
15028
      case ITEM_ID:
15029
        return isSetItemId();
15030
      case VENDOR_ID:
15031
        return isSetVendorId();
15032
      }
15033
      throw new IllegalStateException();
15034
    }
15035
 
15036
    @Override
15037
    public boolean equals(Object that) {
15038
      if (that == null)
15039
        return false;
15040
      if (that instanceof getItemPricing_args)
15041
        return this.equals((getItemPricing_args)that);
15042
      return false;
15043
    }
15044
 
15045
    public boolean equals(getItemPricing_args that) {
15046
      if (that == null)
15047
        return false;
15048
 
15049
      boolean this_present_itemId = true;
15050
      boolean that_present_itemId = true;
15051
      if (this_present_itemId || that_present_itemId) {
15052
        if (!(this_present_itemId && that_present_itemId))
15053
          return false;
15054
        if (this.itemId != that.itemId)
15055
          return false;
15056
      }
15057
 
15058
      boolean this_present_vendorId = true;
15059
      boolean that_present_vendorId = true;
15060
      if (this_present_vendorId || that_present_vendorId) {
15061
        if (!(this_present_vendorId && that_present_vendorId))
15062
          return false;
15063
        if (this.vendorId != that.vendorId)
15064
          return false;
15065
      }
15066
 
15067
      return true;
15068
    }
15069
 
15070
    @Override
15071
    public int hashCode() {
15072
      return 0;
15073
    }
15074
 
15075
    public int compareTo(getItemPricing_args other) {
15076
      if (!getClass().equals(other.getClass())) {
15077
        return getClass().getName().compareTo(other.getClass().getName());
15078
      }
15079
 
15080
      int lastComparison = 0;
15081
      getItemPricing_args typedOther = (getItemPricing_args)other;
15082
 
15083
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
15084
      if (lastComparison != 0) {
15085
        return lastComparison;
15086
      }
15087
      if (isSetItemId()) {
15088
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
15089
        if (lastComparison != 0) {
15090
          return lastComparison;
15091
        }
15092
      }
15093
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
15094
      if (lastComparison != 0) {
15095
        return lastComparison;
15096
      }
15097
      if (isSetVendorId()) {
15098
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
15099
        if (lastComparison != 0) {
15100
          return lastComparison;
15101
        }
15102
      }
15103
      return 0;
15104
    }
15105
 
15106
    public _Fields fieldForId(int fieldId) {
15107
      return _Fields.findByThriftId(fieldId);
15108
    }
15109
 
15110
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15111
      org.apache.thrift.protocol.TField field;
15112
      iprot.readStructBegin();
15113
      while (true)
15114
      {
15115
        field = iprot.readFieldBegin();
15116
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15117
          break;
15118
        }
15119
        switch (field.id) {
15120
          case 1: // ITEM_ID
15121
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15122
              this.itemId = iprot.readI64();
15123
              setItemIdIsSet(true);
15124
            } else { 
15125
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15126
            }
15127
            break;
15128
          case 2: // VENDOR_ID
15129
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15130
              this.vendorId = iprot.readI64();
15131
              setVendorIdIsSet(true);
15132
            } else { 
15133
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15134
            }
15135
            break;
15136
          default:
15137
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15138
        }
15139
        iprot.readFieldEnd();
15140
      }
15141
      iprot.readStructEnd();
15142
      validate();
15143
    }
15144
 
15145
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15146
      validate();
15147
 
15148
      oprot.writeStructBegin(STRUCT_DESC);
15149
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
15150
      oprot.writeI64(this.itemId);
15151
      oprot.writeFieldEnd();
15152
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
15153
      oprot.writeI64(this.vendorId);
15154
      oprot.writeFieldEnd();
15155
      oprot.writeFieldStop();
15156
      oprot.writeStructEnd();
15157
    }
15158
 
15159
    @Override
15160
    public String toString() {
15161
      StringBuilder sb = new StringBuilder("getItemPricing_args(");
15162
      boolean first = true;
15163
 
15164
      sb.append("itemId:");
15165
      sb.append(this.itemId);
15166
      first = false;
15167
      if (!first) sb.append(", ");
15168
      sb.append("vendorId:");
15169
      sb.append(this.vendorId);
15170
      first = false;
15171
      sb.append(")");
15172
      return sb.toString();
15173
    }
15174
 
15175
    public void validate() throws org.apache.thrift.TException {
15176
      // check for required fields
15177
    }
15178
 
15179
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15180
      try {
15181
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15182
      } catch (org.apache.thrift.TException te) {
15183
        throw new java.io.IOException(te);
15184
      }
15185
    }
15186
 
15187
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15188
      try {
15189
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15190
      } catch (org.apache.thrift.TException te) {
15191
        throw new java.io.IOException(te);
15192
      }
15193
    }
15194
 
15195
  }
15196
 
15197
  public static class getItemPricing_result implements org.apache.thrift.TBase<getItemPricing_result, getItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
15198
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemPricing_result");
15199
 
15200
    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);
15201
    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);
15202
 
15203
    private VendorItemPricing success; // required
15204
    private InventoryServiceException cex; // required
15205
 
15206
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15207
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15208
      SUCCESS((short)0, "success"),
15209
      CEX((short)1, "cex");
15210
 
15211
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15212
 
15213
      static {
15214
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15215
          byName.put(field.getFieldName(), field);
15216
        }
15217
      }
15218
 
15219
      /**
15220
       * Find the _Fields constant that matches fieldId, or null if its not found.
15221
       */
15222
      public static _Fields findByThriftId(int fieldId) {
15223
        switch(fieldId) {
15224
          case 0: // SUCCESS
15225
            return SUCCESS;
15226
          case 1: // CEX
15227
            return CEX;
15228
          default:
15229
            return null;
15230
        }
15231
      }
15232
 
15233
      /**
15234
       * Find the _Fields constant that matches fieldId, throwing an exception
15235
       * if it is not found.
15236
       */
15237
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15238
        _Fields fields = findByThriftId(fieldId);
15239
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15240
        return fields;
15241
      }
15242
 
15243
      /**
15244
       * Find the _Fields constant that matches name, or null if its not found.
15245
       */
15246
      public static _Fields findByName(String name) {
15247
        return byName.get(name);
15248
      }
15249
 
15250
      private final short _thriftId;
15251
      private final String _fieldName;
15252
 
15253
      _Fields(short thriftId, String fieldName) {
15254
        _thriftId = thriftId;
15255
        _fieldName = fieldName;
15256
      }
15257
 
15258
      public short getThriftFieldId() {
15259
        return _thriftId;
15260
      }
15261
 
15262
      public String getFieldName() {
15263
        return _fieldName;
15264
      }
15265
    }
15266
 
15267
    // isset id assignments
15268
 
15269
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15270
    static {
15271
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15272
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15273
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class)));
15274
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15275
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
15276
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15277
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemPricing_result.class, metaDataMap);
15278
    }
15279
 
15280
    public getItemPricing_result() {
15281
    }
15282
 
15283
    public getItemPricing_result(
15284
      VendorItemPricing success,
15285
      InventoryServiceException cex)
15286
    {
15287
      this();
15288
      this.success = success;
15289
      this.cex = cex;
15290
    }
15291
 
15292
    /**
15293
     * Performs a deep copy on <i>other</i>.
15294
     */
15295
    public getItemPricing_result(getItemPricing_result other) {
15296
      if (other.isSetSuccess()) {
15297
        this.success = new VendorItemPricing(other.success);
15298
      }
15299
      if (other.isSetCex()) {
15300
        this.cex = new InventoryServiceException(other.cex);
15301
      }
15302
    }
15303
 
15304
    public getItemPricing_result deepCopy() {
15305
      return new getItemPricing_result(this);
15306
    }
15307
 
15308
    @Override
15309
    public void clear() {
15310
      this.success = null;
15311
      this.cex = null;
15312
    }
15313
 
15314
    public VendorItemPricing getSuccess() {
15315
      return this.success;
15316
    }
15317
 
15318
    public void setSuccess(VendorItemPricing success) {
15319
      this.success = success;
15320
    }
15321
 
15322
    public void unsetSuccess() {
15323
      this.success = null;
15324
    }
15325
 
15326
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
15327
    public boolean isSetSuccess() {
15328
      return this.success != null;
15329
    }
15330
 
15331
    public void setSuccessIsSet(boolean value) {
15332
      if (!value) {
15333
        this.success = null;
15334
      }
15335
    }
15336
 
15337
    public InventoryServiceException getCex() {
15338
      return this.cex;
15339
    }
15340
 
15341
    public void setCex(InventoryServiceException cex) {
15342
      this.cex = cex;
15343
    }
15344
 
15345
    public void unsetCex() {
15346
      this.cex = null;
15347
    }
15348
 
15349
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
15350
    public boolean isSetCex() {
15351
      return this.cex != null;
15352
    }
15353
 
15354
    public void setCexIsSet(boolean value) {
15355
      if (!value) {
15356
        this.cex = null;
15357
      }
15358
    }
15359
 
15360
    public void setFieldValue(_Fields field, Object value) {
15361
      switch (field) {
15362
      case SUCCESS:
15363
        if (value == null) {
15364
          unsetSuccess();
15365
        } else {
15366
          setSuccess((VendorItemPricing)value);
15367
        }
15368
        break;
15369
 
15370
      case CEX:
15371
        if (value == null) {
15372
          unsetCex();
15373
        } else {
15374
          setCex((InventoryServiceException)value);
15375
        }
15376
        break;
15377
 
15378
      }
15379
    }
15380
 
15381
    public Object getFieldValue(_Fields field) {
15382
      switch (field) {
15383
      case SUCCESS:
15384
        return getSuccess();
15385
 
15386
      case CEX:
15387
        return getCex();
15388
 
15389
      }
15390
      throw new IllegalStateException();
15391
    }
15392
 
15393
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15394
    public boolean isSet(_Fields field) {
15395
      if (field == null) {
15396
        throw new IllegalArgumentException();
15397
      }
15398
 
15399
      switch (field) {
15400
      case SUCCESS:
15401
        return isSetSuccess();
15402
      case CEX:
15403
        return isSetCex();
15404
      }
15405
      throw new IllegalStateException();
15406
    }
15407
 
15408
    @Override
15409
    public boolean equals(Object that) {
15410
      if (that == null)
15411
        return false;
15412
      if (that instanceof getItemPricing_result)
15413
        return this.equals((getItemPricing_result)that);
15414
      return false;
15415
    }
15416
 
15417
    public boolean equals(getItemPricing_result that) {
15418
      if (that == null)
15419
        return false;
15420
 
15421
      boolean this_present_success = true && this.isSetSuccess();
15422
      boolean that_present_success = true && that.isSetSuccess();
15423
      if (this_present_success || that_present_success) {
15424
        if (!(this_present_success && that_present_success))
15425
          return false;
15426
        if (!this.success.equals(that.success))
15427
          return false;
15428
      }
15429
 
15430
      boolean this_present_cex = true && this.isSetCex();
15431
      boolean that_present_cex = true && that.isSetCex();
15432
      if (this_present_cex || that_present_cex) {
15433
        if (!(this_present_cex && that_present_cex))
15434
          return false;
15435
        if (!this.cex.equals(that.cex))
15436
          return false;
15437
      }
15438
 
15439
      return true;
15440
    }
15441
 
15442
    @Override
15443
    public int hashCode() {
15444
      return 0;
15445
    }
15446
 
15447
    public int compareTo(getItemPricing_result other) {
15448
      if (!getClass().equals(other.getClass())) {
15449
        return getClass().getName().compareTo(other.getClass().getName());
15450
      }
15451
 
15452
      int lastComparison = 0;
15453
      getItemPricing_result typedOther = (getItemPricing_result)other;
15454
 
15455
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
15456
      if (lastComparison != 0) {
15457
        return lastComparison;
15458
      }
15459
      if (isSetSuccess()) {
15460
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
15461
        if (lastComparison != 0) {
15462
          return lastComparison;
15463
        }
15464
      }
15465
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
15466
      if (lastComparison != 0) {
15467
        return lastComparison;
15468
      }
15469
      if (isSetCex()) {
15470
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
15471
        if (lastComparison != 0) {
15472
          return lastComparison;
15473
        }
15474
      }
15475
      return 0;
15476
    }
15477
 
15478
    public _Fields fieldForId(int fieldId) {
15479
      return _Fields.findByThriftId(fieldId);
15480
    }
15481
 
15482
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15483
      org.apache.thrift.protocol.TField field;
15484
      iprot.readStructBegin();
15485
      while (true)
15486
      {
15487
        field = iprot.readFieldBegin();
15488
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15489
          break;
15490
        }
15491
        switch (field.id) {
15492
          case 0: // SUCCESS
15493
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15494
              this.success = new VendorItemPricing();
15495
              this.success.read(iprot);
15496
            } else { 
15497
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15498
            }
15499
            break;
15500
          case 1: // CEX
15501
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15502
              this.cex = new InventoryServiceException();
15503
              this.cex.read(iprot);
15504
            } else { 
15505
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15506
            }
15507
            break;
15508
          default:
15509
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15510
        }
15511
        iprot.readFieldEnd();
15512
      }
15513
      iprot.readStructEnd();
15514
      validate();
15515
    }
15516
 
15517
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15518
      oprot.writeStructBegin(STRUCT_DESC);
15519
 
15520
      if (this.isSetSuccess()) {
15521
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
15522
        this.success.write(oprot);
15523
        oprot.writeFieldEnd();
15524
      } else if (this.isSetCex()) {
15525
        oprot.writeFieldBegin(CEX_FIELD_DESC);
15526
        this.cex.write(oprot);
15527
        oprot.writeFieldEnd();
15528
      }
15529
      oprot.writeFieldStop();
15530
      oprot.writeStructEnd();
15531
    }
15532
 
15533
    @Override
15534
    public String toString() {
15535
      StringBuilder sb = new StringBuilder("getItemPricing_result(");
15536
      boolean first = true;
15537
 
15538
      sb.append("success:");
15539
      if (this.success == null) {
15540
        sb.append("null");
15541
      } else {
15542
        sb.append(this.success);
15543
      }
15544
      first = false;
15545
      if (!first) sb.append(", ");
15546
      sb.append("cex:");
15547
      if (this.cex == null) {
15548
        sb.append("null");
15549
      } else {
15550
        sb.append(this.cex);
15551
      }
15552
      first = false;
15553
      sb.append(")");
15554
      return sb.toString();
15555
    }
15556
 
15557
    public void validate() throws org.apache.thrift.TException {
15558
      // check for required fields
15559
    }
15560
 
15561
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15562
      try {
15563
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15564
      } catch (org.apache.thrift.TException te) {
15565
        throw new java.io.IOException(te);
15566
      }
15567
    }
15568
 
15569
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15570
      try {
15571
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15572
      } catch (org.apache.thrift.TException te) {
15573
        throw new java.io.IOException(te);
15574
      }
15575
    }
15576
 
15577
  }
15578
 
15579
  public static class getAllItemPricing_args implements org.apache.thrift.TBase<getAllItemPricing_args, getAllItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
15580
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemPricing_args");
15581
 
15582
    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);
15583
 
15584
    private long itemId; // required
15585
 
15586
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15587
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15588
      ITEM_ID((short)1, "itemId");
15589
 
15590
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15591
 
15592
      static {
15593
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15594
          byName.put(field.getFieldName(), field);
15595
        }
15596
      }
15597
 
15598
      /**
15599
       * Find the _Fields constant that matches fieldId, or null if its not found.
15600
       */
15601
      public static _Fields findByThriftId(int fieldId) {
15602
        switch(fieldId) {
15603
          case 1: // ITEM_ID
15604
            return ITEM_ID;
15605
          default:
15606
            return null;
15607
        }
15608
      }
15609
 
15610
      /**
15611
       * Find the _Fields constant that matches fieldId, throwing an exception
15612
       * if it is not found.
15613
       */
15614
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15615
        _Fields fields = findByThriftId(fieldId);
15616
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15617
        return fields;
15618
      }
15619
 
15620
      /**
15621
       * Find the _Fields constant that matches name, or null if its not found.
15622
       */
15623
      public static _Fields findByName(String name) {
15624
        return byName.get(name);
15625
      }
15626
 
15627
      private final short _thriftId;
15628
      private final String _fieldName;
15629
 
15630
      _Fields(short thriftId, String fieldName) {
15631
        _thriftId = thriftId;
15632
        _fieldName = fieldName;
15633
      }
15634
 
15635
      public short getThriftFieldId() {
15636
        return _thriftId;
15637
      }
15638
 
15639
      public String getFieldName() {
15640
        return _fieldName;
15641
      }
15642
    }
15643
 
15644
    // isset id assignments
15645
    private static final int __ITEMID_ISSET_ID = 0;
15646
    private BitSet __isset_bit_vector = new BitSet(1);
15647
 
15648
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15649
    static {
15650
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15651
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15652
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
15653
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15654
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemPricing_args.class, metaDataMap);
15655
    }
15656
 
15657
    public getAllItemPricing_args() {
15658
    }
15659
 
15660
    public getAllItemPricing_args(
15661
      long itemId)
15662
    {
15663
      this();
15664
      this.itemId = itemId;
15665
      setItemIdIsSet(true);
15666
    }
15667
 
15668
    /**
15669
     * Performs a deep copy on <i>other</i>.
15670
     */
15671
    public getAllItemPricing_args(getAllItemPricing_args other) {
15672
      __isset_bit_vector.clear();
15673
      __isset_bit_vector.or(other.__isset_bit_vector);
15674
      this.itemId = other.itemId;
15675
    }
15676
 
15677
    public getAllItemPricing_args deepCopy() {
15678
      return new getAllItemPricing_args(this);
15679
    }
15680
 
15681
    @Override
15682
    public void clear() {
15683
      setItemIdIsSet(false);
15684
      this.itemId = 0;
15685
    }
15686
 
15687
    public long getItemId() {
15688
      return this.itemId;
15689
    }
15690
 
15691
    public void setItemId(long itemId) {
15692
      this.itemId = itemId;
15693
      setItemIdIsSet(true);
15694
    }
15695
 
15696
    public void unsetItemId() {
15697
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
15698
    }
15699
 
15700
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
15701
    public boolean isSetItemId() {
15702
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
15703
    }
15704
 
15705
    public void setItemIdIsSet(boolean value) {
15706
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
15707
    }
15708
 
15709
    public void setFieldValue(_Fields field, Object value) {
15710
      switch (field) {
15711
      case ITEM_ID:
15712
        if (value == null) {
15713
          unsetItemId();
15714
        } else {
15715
          setItemId((Long)value);
15716
        }
15717
        break;
15718
 
15719
      }
15720
    }
15721
 
15722
    public Object getFieldValue(_Fields field) {
15723
      switch (field) {
15724
      case ITEM_ID:
15725
        return Long.valueOf(getItemId());
15726
 
15727
      }
15728
      throw new IllegalStateException();
15729
    }
15730
 
15731
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15732
    public boolean isSet(_Fields field) {
15733
      if (field == null) {
15734
        throw new IllegalArgumentException();
15735
      }
15736
 
15737
      switch (field) {
15738
      case ITEM_ID:
15739
        return isSetItemId();
15740
      }
15741
      throw new IllegalStateException();
15742
    }
15743
 
15744
    @Override
15745
    public boolean equals(Object that) {
15746
      if (that == null)
15747
        return false;
15748
      if (that instanceof getAllItemPricing_args)
15749
        return this.equals((getAllItemPricing_args)that);
15750
      return false;
15751
    }
15752
 
15753
    public boolean equals(getAllItemPricing_args that) {
15754
      if (that == null)
15755
        return false;
15756
 
15757
      boolean this_present_itemId = true;
15758
      boolean that_present_itemId = true;
15759
      if (this_present_itemId || that_present_itemId) {
15760
        if (!(this_present_itemId && that_present_itemId))
15761
          return false;
15762
        if (this.itemId != that.itemId)
15763
          return false;
15764
      }
15765
 
15766
      return true;
15767
    }
15768
 
15769
    @Override
15770
    public int hashCode() {
15771
      return 0;
15772
    }
15773
 
15774
    public int compareTo(getAllItemPricing_args other) {
15775
      if (!getClass().equals(other.getClass())) {
15776
        return getClass().getName().compareTo(other.getClass().getName());
15777
      }
15778
 
15779
      int lastComparison = 0;
15780
      getAllItemPricing_args typedOther = (getAllItemPricing_args)other;
15781
 
15782
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
15783
      if (lastComparison != 0) {
15784
        return lastComparison;
15785
      }
15786
      if (isSetItemId()) {
15787
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
15788
        if (lastComparison != 0) {
15789
          return lastComparison;
15790
        }
15791
      }
15792
      return 0;
15793
    }
15794
 
15795
    public _Fields fieldForId(int fieldId) {
15796
      return _Fields.findByThriftId(fieldId);
15797
    }
15798
 
15799
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15800
      org.apache.thrift.protocol.TField field;
15801
      iprot.readStructBegin();
15802
      while (true)
15803
      {
15804
        field = iprot.readFieldBegin();
15805
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15806
          break;
15807
        }
15808
        switch (field.id) {
15809
          case 1: // ITEM_ID
15810
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15811
              this.itemId = iprot.readI64();
15812
              setItemIdIsSet(true);
15813
            } else { 
15814
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15815
            }
15816
            break;
15817
          default:
15818
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15819
        }
15820
        iprot.readFieldEnd();
15821
      }
15822
      iprot.readStructEnd();
15823
      validate();
15824
    }
15825
 
15826
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15827
      validate();
15828
 
15829
      oprot.writeStructBegin(STRUCT_DESC);
15830
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
15831
      oprot.writeI64(this.itemId);
15832
      oprot.writeFieldEnd();
15833
      oprot.writeFieldStop();
15834
      oprot.writeStructEnd();
15835
    }
15836
 
15837
    @Override
15838
    public String toString() {
15839
      StringBuilder sb = new StringBuilder("getAllItemPricing_args(");
15840
      boolean first = true;
15841
 
15842
      sb.append("itemId:");
15843
      sb.append(this.itemId);
15844
      first = false;
15845
      sb.append(")");
15846
      return sb.toString();
15847
    }
15848
 
15849
    public void validate() throws org.apache.thrift.TException {
15850
      // check for required fields
15851
    }
15852
 
15853
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15854
      try {
15855
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15856
      } catch (org.apache.thrift.TException te) {
15857
        throw new java.io.IOException(te);
15858
      }
15859
    }
15860
 
15861
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15862
      try {
15863
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15864
      } catch (org.apache.thrift.TException te) {
15865
        throw new java.io.IOException(te);
15866
      }
15867
    }
15868
 
15869
  }
15870
 
15871
  public static class getAllItemPricing_result implements org.apache.thrift.TBase<getAllItemPricing_result, getAllItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
15872
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemPricing_result");
15873
 
15874
    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);
15875
    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);
15876
 
15877
    private List<VendorItemPricing> success; // required
15878
    private InventoryServiceException cex; // required
15879
 
15880
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15881
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15882
      SUCCESS((short)0, "success"),
15883
      CEX((short)1, "cex");
15884
 
15885
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15886
 
15887
      static {
15888
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15889
          byName.put(field.getFieldName(), field);
15890
        }
15891
      }
15892
 
15893
      /**
15894
       * Find the _Fields constant that matches fieldId, or null if its not found.
15895
       */
15896
      public static _Fields findByThriftId(int fieldId) {
15897
        switch(fieldId) {
15898
          case 0: // SUCCESS
15899
            return SUCCESS;
15900
          case 1: // CEX
15901
            return CEX;
15902
          default:
15903
            return null;
15904
        }
15905
      }
15906
 
15907
      /**
15908
       * Find the _Fields constant that matches fieldId, throwing an exception
15909
       * if it is not found.
15910
       */
15911
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15912
        _Fields fields = findByThriftId(fieldId);
15913
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15914
        return fields;
15915
      }
15916
 
15917
      /**
15918
       * Find the _Fields constant that matches name, or null if its not found.
15919
       */
15920
      public static _Fields findByName(String name) {
15921
        return byName.get(name);
15922
      }
15923
 
15924
      private final short _thriftId;
15925
      private final String _fieldName;
15926
 
15927
      _Fields(short thriftId, String fieldName) {
15928
        _thriftId = thriftId;
15929
        _fieldName = fieldName;
15930
      }
15931
 
15932
      public short getThriftFieldId() {
15933
        return _thriftId;
15934
      }
15935
 
15936
      public String getFieldName() {
15937
        return _fieldName;
15938
      }
15939
    }
15940
 
15941
    // isset id assignments
15942
 
15943
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15944
    static {
15945
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15946
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15947
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
15948
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class))));
15949
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15950
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
15951
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15952
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemPricing_result.class, metaDataMap);
15953
    }
15954
 
15955
    public getAllItemPricing_result() {
15956
    }
15957
 
15958
    public getAllItemPricing_result(
15959
      List<VendorItemPricing> success,
15960
      InventoryServiceException cex)
15961
    {
15962
      this();
15963
      this.success = success;
15964
      this.cex = cex;
15965
    }
15966
 
15967
    /**
15968
     * Performs a deep copy on <i>other</i>.
15969
     */
15970
    public getAllItemPricing_result(getAllItemPricing_result other) {
15971
      if (other.isSetSuccess()) {
15972
        List<VendorItemPricing> __this__success = new ArrayList<VendorItemPricing>();
15973
        for (VendorItemPricing other_element : other.success) {
15974
          __this__success.add(new VendorItemPricing(other_element));
15975
        }
15976
        this.success = __this__success;
15977
      }
15978
      if (other.isSetCex()) {
15979
        this.cex = new InventoryServiceException(other.cex);
15980
      }
15981
    }
15982
 
15983
    public getAllItemPricing_result deepCopy() {
15984
      return new getAllItemPricing_result(this);
15985
    }
15986
 
15987
    @Override
15988
    public void clear() {
15989
      this.success = null;
15990
      this.cex = null;
15991
    }
15992
 
15993
    public int getSuccessSize() {
15994
      return (this.success == null) ? 0 : this.success.size();
15995
    }
15996
 
15997
    public java.util.Iterator<VendorItemPricing> getSuccessIterator() {
15998
      return (this.success == null) ? null : this.success.iterator();
15999
    }
16000
 
16001
    public void addToSuccess(VendorItemPricing elem) {
16002
      if (this.success == null) {
16003
        this.success = new ArrayList<VendorItemPricing>();
16004
      }
16005
      this.success.add(elem);
16006
    }
16007
 
16008
    public List<VendorItemPricing> getSuccess() {
16009
      return this.success;
16010
    }
16011
 
16012
    public void setSuccess(List<VendorItemPricing> success) {
16013
      this.success = success;
16014
    }
16015
 
16016
    public void unsetSuccess() {
16017
      this.success = null;
16018
    }
16019
 
16020
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
16021
    public boolean isSetSuccess() {
16022
      return this.success != null;
16023
    }
16024
 
16025
    public void setSuccessIsSet(boolean value) {
16026
      if (!value) {
16027
        this.success = null;
16028
      }
16029
    }
16030
 
16031
    public InventoryServiceException getCex() {
16032
      return this.cex;
16033
    }
16034
 
16035
    public void setCex(InventoryServiceException cex) {
16036
      this.cex = cex;
16037
    }
16038
 
16039
    public void unsetCex() {
16040
      this.cex = null;
16041
    }
16042
 
16043
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
16044
    public boolean isSetCex() {
16045
      return this.cex != null;
16046
    }
16047
 
16048
    public void setCexIsSet(boolean value) {
16049
      if (!value) {
16050
        this.cex = null;
16051
      }
16052
    }
16053
 
16054
    public void setFieldValue(_Fields field, Object value) {
16055
      switch (field) {
16056
      case SUCCESS:
16057
        if (value == null) {
16058
          unsetSuccess();
16059
        } else {
16060
          setSuccess((List<VendorItemPricing>)value);
16061
        }
16062
        break;
16063
 
16064
      case CEX:
16065
        if (value == null) {
16066
          unsetCex();
16067
        } else {
16068
          setCex((InventoryServiceException)value);
16069
        }
16070
        break;
16071
 
16072
      }
16073
    }
16074
 
16075
    public Object getFieldValue(_Fields field) {
16076
      switch (field) {
16077
      case SUCCESS:
16078
        return getSuccess();
16079
 
16080
      case CEX:
16081
        return getCex();
16082
 
16083
      }
16084
      throw new IllegalStateException();
16085
    }
16086
 
16087
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16088
    public boolean isSet(_Fields field) {
16089
      if (field == null) {
16090
        throw new IllegalArgumentException();
16091
      }
16092
 
16093
      switch (field) {
16094
      case SUCCESS:
16095
        return isSetSuccess();
16096
      case CEX:
16097
        return isSetCex();
16098
      }
16099
      throw new IllegalStateException();
16100
    }
16101
 
16102
    @Override
16103
    public boolean equals(Object that) {
16104
      if (that == null)
16105
        return false;
16106
      if (that instanceof getAllItemPricing_result)
16107
        return this.equals((getAllItemPricing_result)that);
16108
      return false;
16109
    }
16110
 
16111
    public boolean equals(getAllItemPricing_result that) {
16112
      if (that == null)
16113
        return false;
16114
 
16115
      boolean this_present_success = true && this.isSetSuccess();
16116
      boolean that_present_success = true && that.isSetSuccess();
16117
      if (this_present_success || that_present_success) {
16118
        if (!(this_present_success && that_present_success))
16119
          return false;
16120
        if (!this.success.equals(that.success))
16121
          return false;
16122
      }
16123
 
16124
      boolean this_present_cex = true && this.isSetCex();
16125
      boolean that_present_cex = true && that.isSetCex();
16126
      if (this_present_cex || that_present_cex) {
16127
        if (!(this_present_cex && that_present_cex))
16128
          return false;
16129
        if (!this.cex.equals(that.cex))
16130
          return false;
16131
      }
16132
 
16133
      return true;
16134
    }
16135
 
16136
    @Override
16137
    public int hashCode() {
16138
      return 0;
16139
    }
16140
 
16141
    public int compareTo(getAllItemPricing_result other) {
16142
      if (!getClass().equals(other.getClass())) {
16143
        return getClass().getName().compareTo(other.getClass().getName());
16144
      }
16145
 
16146
      int lastComparison = 0;
16147
      getAllItemPricing_result typedOther = (getAllItemPricing_result)other;
16148
 
16149
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
16150
      if (lastComparison != 0) {
16151
        return lastComparison;
16152
      }
16153
      if (isSetSuccess()) {
16154
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
16155
        if (lastComparison != 0) {
16156
          return lastComparison;
16157
        }
16158
      }
16159
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
16160
      if (lastComparison != 0) {
16161
        return lastComparison;
16162
      }
16163
      if (isSetCex()) {
16164
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
16165
        if (lastComparison != 0) {
16166
          return lastComparison;
16167
        }
16168
      }
16169
      return 0;
16170
    }
16171
 
16172
    public _Fields fieldForId(int fieldId) {
16173
      return _Fields.findByThriftId(fieldId);
16174
    }
16175
 
16176
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16177
      org.apache.thrift.protocol.TField field;
16178
      iprot.readStructBegin();
16179
      while (true)
16180
      {
16181
        field = iprot.readFieldBegin();
16182
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16183
          break;
16184
        }
16185
        switch (field.id) {
16186
          case 0: // SUCCESS
16187
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
16188
              {
16189
                org.apache.thrift.protocol.TList _list32 = iprot.readListBegin();
16190
                this.success = new ArrayList<VendorItemPricing>(_list32.size);
16191
                for (int _i33 = 0; _i33 < _list32.size; ++_i33)
16192
                {
16193
                  VendorItemPricing _elem34; // required
16194
                  _elem34 = new VendorItemPricing();
16195
                  _elem34.read(iprot);
16196
                  this.success.add(_elem34);
16197
                }
16198
                iprot.readListEnd();
16199
              }
16200
            } else { 
16201
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16202
            }
16203
            break;
16204
          case 1: // CEX
16205
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16206
              this.cex = new InventoryServiceException();
16207
              this.cex.read(iprot);
16208
            } else { 
16209
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16210
            }
16211
            break;
16212
          default:
16213
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16214
        }
16215
        iprot.readFieldEnd();
16216
      }
16217
      iprot.readStructEnd();
16218
      validate();
16219
    }
16220
 
16221
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16222
      oprot.writeStructBegin(STRUCT_DESC);
16223
 
16224
      if (this.isSetSuccess()) {
16225
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
16226
        {
16227
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
16228
          for (VendorItemPricing _iter35 : this.success)
16229
          {
16230
            _iter35.write(oprot);
16231
          }
16232
          oprot.writeListEnd();
16233
        }
16234
        oprot.writeFieldEnd();
16235
      } else if (this.isSetCex()) {
16236
        oprot.writeFieldBegin(CEX_FIELD_DESC);
16237
        this.cex.write(oprot);
16238
        oprot.writeFieldEnd();
16239
      }
16240
      oprot.writeFieldStop();
16241
      oprot.writeStructEnd();
16242
    }
16243
 
16244
    @Override
16245
    public String toString() {
16246
      StringBuilder sb = new StringBuilder("getAllItemPricing_result(");
16247
      boolean first = true;
16248
 
16249
      sb.append("success:");
16250
      if (this.success == null) {
16251
        sb.append("null");
16252
      } else {
16253
        sb.append(this.success);
16254
      }
16255
      first = false;
16256
      if (!first) sb.append(", ");
16257
      sb.append("cex:");
16258
      if (this.cex == null) {
16259
        sb.append("null");
16260
      } else {
16261
        sb.append(this.cex);
16262
      }
16263
      first = false;
16264
      sb.append(")");
16265
      return sb.toString();
16266
    }
16267
 
16268
    public void validate() throws org.apache.thrift.TException {
16269
      // check for required fields
16270
    }
16271
 
16272
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16273
      try {
16274
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16275
      } catch (org.apache.thrift.TException te) {
16276
        throw new java.io.IOException(te);
16277
      }
16278
    }
16279
 
16280
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16281
      try {
16282
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16283
      } catch (org.apache.thrift.TException te) {
16284
        throw new java.io.IOException(te);
16285
      }
16286
    }
16287
 
16288
  }
16289
 
16290
  public static class addVendorItemPricing_args implements org.apache.thrift.TBase<addVendorItemPricing_args, addVendorItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
16291
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemPricing_args");
16292
 
16293
    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);
16294
 
16295
    private VendorItemPricing vendorItemPricing; // required
16296
 
16297
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16298
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16299
      VENDOR_ITEM_PRICING((short)1, "vendorItemPricing");
16300
 
16301
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16302
 
16303
      static {
16304
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16305
          byName.put(field.getFieldName(), field);
16306
        }
16307
      }
16308
 
16309
      /**
16310
       * Find the _Fields constant that matches fieldId, or null if its not found.
16311
       */
16312
      public static _Fields findByThriftId(int fieldId) {
16313
        switch(fieldId) {
16314
          case 1: // VENDOR_ITEM_PRICING
16315
            return VENDOR_ITEM_PRICING;
16316
          default:
16317
            return null;
16318
        }
16319
      }
16320
 
16321
      /**
16322
       * Find the _Fields constant that matches fieldId, throwing an exception
16323
       * if it is not found.
16324
       */
16325
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16326
        _Fields fields = findByThriftId(fieldId);
16327
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16328
        return fields;
16329
      }
16330
 
16331
      /**
16332
       * Find the _Fields constant that matches name, or null if its not found.
16333
       */
16334
      public static _Fields findByName(String name) {
16335
        return byName.get(name);
16336
      }
16337
 
16338
      private final short _thriftId;
16339
      private final String _fieldName;
16340
 
16341
      _Fields(short thriftId, String fieldName) {
16342
        _thriftId = thriftId;
16343
        _fieldName = fieldName;
16344
      }
16345
 
16346
      public short getThriftFieldId() {
16347
        return _thriftId;
16348
      }
16349
 
16350
      public String getFieldName() {
16351
        return _fieldName;
16352
      }
16353
    }
16354
 
16355
    // isset id assignments
16356
 
16357
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16358
    static {
16359
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16360
      tmpMap.put(_Fields.VENDOR_ITEM_PRICING, new org.apache.thrift.meta_data.FieldMetaData("vendorItemPricing", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16361
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class)));
16362
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16363
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemPricing_args.class, metaDataMap);
16364
    }
16365
 
16366
    public addVendorItemPricing_args() {
16367
    }
16368
 
16369
    public addVendorItemPricing_args(
16370
      VendorItemPricing vendorItemPricing)
16371
    {
16372
      this();
16373
      this.vendorItemPricing = vendorItemPricing;
16374
    }
16375
 
16376
    /**
16377
     * Performs a deep copy on <i>other</i>.
16378
     */
16379
    public addVendorItemPricing_args(addVendorItemPricing_args other) {
16380
      if (other.isSetVendorItemPricing()) {
16381
        this.vendorItemPricing = new VendorItemPricing(other.vendorItemPricing);
16382
      }
16383
    }
16384
 
16385
    public addVendorItemPricing_args deepCopy() {
16386
      return new addVendorItemPricing_args(this);
16387
    }
16388
 
16389
    @Override
16390
    public void clear() {
16391
      this.vendorItemPricing = null;
16392
    }
16393
 
16394
    public VendorItemPricing getVendorItemPricing() {
16395
      return this.vendorItemPricing;
16396
    }
16397
 
16398
    public void setVendorItemPricing(VendorItemPricing vendorItemPricing) {
16399
      this.vendorItemPricing = vendorItemPricing;
16400
    }
16401
 
16402
    public void unsetVendorItemPricing() {
16403
      this.vendorItemPricing = null;
16404
    }
16405
 
16406
    /** Returns true if field vendorItemPricing is set (has been assigned a value) and false otherwise */
16407
    public boolean isSetVendorItemPricing() {
16408
      return this.vendorItemPricing != null;
16409
    }
16410
 
16411
    public void setVendorItemPricingIsSet(boolean value) {
16412
      if (!value) {
16413
        this.vendorItemPricing = null;
16414
      }
16415
    }
16416
 
16417
    public void setFieldValue(_Fields field, Object value) {
16418
      switch (field) {
16419
      case VENDOR_ITEM_PRICING:
16420
        if (value == null) {
16421
          unsetVendorItemPricing();
16422
        } else {
16423
          setVendorItemPricing((VendorItemPricing)value);
16424
        }
16425
        break;
16426
 
16427
      }
16428
    }
16429
 
16430
    public Object getFieldValue(_Fields field) {
16431
      switch (field) {
16432
      case VENDOR_ITEM_PRICING:
16433
        return getVendorItemPricing();
16434
 
16435
      }
16436
      throw new IllegalStateException();
16437
    }
16438
 
16439
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16440
    public boolean isSet(_Fields field) {
16441
      if (field == null) {
16442
        throw new IllegalArgumentException();
16443
      }
16444
 
16445
      switch (field) {
16446
      case VENDOR_ITEM_PRICING:
16447
        return isSetVendorItemPricing();
16448
      }
16449
      throw new IllegalStateException();
16450
    }
16451
 
16452
    @Override
16453
    public boolean equals(Object that) {
16454
      if (that == null)
16455
        return false;
16456
      if (that instanceof addVendorItemPricing_args)
16457
        return this.equals((addVendorItemPricing_args)that);
16458
      return false;
16459
    }
16460
 
16461
    public boolean equals(addVendorItemPricing_args that) {
16462
      if (that == null)
16463
        return false;
16464
 
16465
      boolean this_present_vendorItemPricing = true && this.isSetVendorItemPricing();
16466
      boolean that_present_vendorItemPricing = true && that.isSetVendorItemPricing();
16467
      if (this_present_vendorItemPricing || that_present_vendorItemPricing) {
16468
        if (!(this_present_vendorItemPricing && that_present_vendorItemPricing))
16469
          return false;
16470
        if (!this.vendorItemPricing.equals(that.vendorItemPricing))
16471
          return false;
16472
      }
16473
 
16474
      return true;
16475
    }
16476
 
16477
    @Override
16478
    public int hashCode() {
16479
      return 0;
16480
    }
16481
 
16482
    public int compareTo(addVendorItemPricing_args other) {
16483
      if (!getClass().equals(other.getClass())) {
16484
        return getClass().getName().compareTo(other.getClass().getName());
16485
      }
16486
 
16487
      int lastComparison = 0;
16488
      addVendorItemPricing_args typedOther = (addVendorItemPricing_args)other;
16489
 
16490
      lastComparison = Boolean.valueOf(isSetVendorItemPricing()).compareTo(typedOther.isSetVendorItemPricing());
16491
      if (lastComparison != 0) {
16492
        return lastComparison;
16493
      }
16494
      if (isSetVendorItemPricing()) {
16495
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorItemPricing, typedOther.vendorItemPricing);
16496
        if (lastComparison != 0) {
16497
          return lastComparison;
16498
        }
16499
      }
16500
      return 0;
16501
    }
16502
 
16503
    public _Fields fieldForId(int fieldId) {
16504
      return _Fields.findByThriftId(fieldId);
16505
    }
16506
 
16507
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16508
      org.apache.thrift.protocol.TField field;
16509
      iprot.readStructBegin();
16510
      while (true)
16511
      {
16512
        field = iprot.readFieldBegin();
16513
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16514
          break;
16515
        }
16516
        switch (field.id) {
16517
          case 1: // VENDOR_ITEM_PRICING
16518
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16519
              this.vendorItemPricing = new VendorItemPricing();
16520
              this.vendorItemPricing.read(iprot);
16521
            } else { 
16522
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16523
            }
16524
            break;
16525
          default:
16526
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16527
        }
16528
        iprot.readFieldEnd();
16529
      }
16530
      iprot.readStructEnd();
16531
      validate();
16532
    }
16533
 
16534
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16535
      validate();
16536
 
16537
      oprot.writeStructBegin(STRUCT_DESC);
16538
      if (this.vendorItemPricing != null) {
16539
        oprot.writeFieldBegin(VENDOR_ITEM_PRICING_FIELD_DESC);
16540
        this.vendorItemPricing.write(oprot);
16541
        oprot.writeFieldEnd();
16542
      }
16543
      oprot.writeFieldStop();
16544
      oprot.writeStructEnd();
16545
    }
16546
 
16547
    @Override
16548
    public String toString() {
16549
      StringBuilder sb = new StringBuilder("addVendorItemPricing_args(");
16550
      boolean first = true;
16551
 
16552
      sb.append("vendorItemPricing:");
16553
      if (this.vendorItemPricing == null) {
16554
        sb.append("null");
16555
      } else {
16556
        sb.append(this.vendorItemPricing);
16557
      }
16558
      first = false;
16559
      sb.append(")");
16560
      return sb.toString();
16561
    }
16562
 
16563
    public void validate() throws org.apache.thrift.TException {
16564
      // check for required fields
16565
    }
16566
 
16567
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16568
      try {
16569
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16570
      } catch (org.apache.thrift.TException te) {
16571
        throw new java.io.IOException(te);
16572
      }
16573
    }
16574
 
16575
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16576
      try {
16577
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16578
      } catch (org.apache.thrift.TException te) {
16579
        throw new java.io.IOException(te);
16580
      }
16581
    }
16582
 
16583
  }
16584
 
16585
  public static class addVendorItemPricing_result implements org.apache.thrift.TBase<addVendorItemPricing_result, addVendorItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
16586
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemPricing_result");
16587
 
16588
    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);
16589
 
16590
    private InventoryServiceException cex; // required
16591
 
16592
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16593
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16594
      CEX((short)1, "cex");
16595
 
16596
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16597
 
16598
      static {
16599
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16600
          byName.put(field.getFieldName(), field);
16601
        }
16602
      }
16603
 
16604
      /**
16605
       * Find the _Fields constant that matches fieldId, or null if its not found.
16606
       */
16607
      public static _Fields findByThriftId(int fieldId) {
16608
        switch(fieldId) {
16609
          case 1: // CEX
16610
            return CEX;
16611
          default:
16612
            return null;
16613
        }
16614
      }
16615
 
16616
      /**
16617
       * Find the _Fields constant that matches fieldId, throwing an exception
16618
       * if it is not found.
16619
       */
16620
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16621
        _Fields fields = findByThriftId(fieldId);
16622
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16623
        return fields;
16624
      }
16625
 
16626
      /**
16627
       * Find the _Fields constant that matches name, or null if its not found.
16628
       */
16629
      public static _Fields findByName(String name) {
16630
        return byName.get(name);
16631
      }
16632
 
16633
      private final short _thriftId;
16634
      private final String _fieldName;
16635
 
16636
      _Fields(short thriftId, String fieldName) {
16637
        _thriftId = thriftId;
16638
        _fieldName = fieldName;
16639
      }
16640
 
16641
      public short getThriftFieldId() {
16642
        return _thriftId;
16643
      }
16644
 
16645
      public String getFieldName() {
16646
        return _fieldName;
16647
      }
16648
    }
16649
 
16650
    // isset id assignments
16651
 
16652
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16653
    static {
16654
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16655
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16656
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
16657
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16658
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemPricing_result.class, metaDataMap);
16659
    }
16660
 
16661
    public addVendorItemPricing_result() {
16662
    }
16663
 
16664
    public addVendorItemPricing_result(
16665
      InventoryServiceException cex)
16666
    {
16667
      this();
16668
      this.cex = cex;
16669
    }
16670
 
16671
    /**
16672
     * Performs a deep copy on <i>other</i>.
16673
     */
16674
    public addVendorItemPricing_result(addVendorItemPricing_result other) {
16675
      if (other.isSetCex()) {
16676
        this.cex = new InventoryServiceException(other.cex);
16677
      }
16678
    }
16679
 
16680
    public addVendorItemPricing_result deepCopy() {
16681
      return new addVendorItemPricing_result(this);
16682
    }
16683
 
16684
    @Override
16685
    public void clear() {
16686
      this.cex = null;
16687
    }
16688
 
16689
    public InventoryServiceException getCex() {
16690
      return this.cex;
16691
    }
16692
 
16693
    public void setCex(InventoryServiceException cex) {
16694
      this.cex = cex;
16695
    }
16696
 
16697
    public void unsetCex() {
16698
      this.cex = null;
16699
    }
16700
 
16701
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
16702
    public boolean isSetCex() {
16703
      return this.cex != null;
16704
    }
16705
 
16706
    public void setCexIsSet(boolean value) {
16707
      if (!value) {
16708
        this.cex = null;
16709
      }
16710
    }
16711
 
16712
    public void setFieldValue(_Fields field, Object value) {
16713
      switch (field) {
16714
      case CEX:
16715
        if (value == null) {
16716
          unsetCex();
16717
        } else {
16718
          setCex((InventoryServiceException)value);
16719
        }
16720
        break;
16721
 
16722
      }
16723
    }
16724
 
16725
    public Object getFieldValue(_Fields field) {
16726
      switch (field) {
16727
      case CEX:
16728
        return getCex();
16729
 
16730
      }
16731
      throw new IllegalStateException();
16732
    }
16733
 
16734
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16735
    public boolean isSet(_Fields field) {
16736
      if (field == null) {
16737
        throw new IllegalArgumentException();
16738
      }
16739
 
16740
      switch (field) {
16741
      case CEX:
16742
        return isSetCex();
16743
      }
16744
      throw new IllegalStateException();
16745
    }
16746
 
16747
    @Override
16748
    public boolean equals(Object that) {
16749
      if (that == null)
16750
        return false;
16751
      if (that instanceof addVendorItemPricing_result)
16752
        return this.equals((addVendorItemPricing_result)that);
16753
      return false;
16754
    }
16755
 
16756
    public boolean equals(addVendorItemPricing_result that) {
16757
      if (that == null)
16758
        return false;
16759
 
16760
      boolean this_present_cex = true && this.isSetCex();
16761
      boolean that_present_cex = true && that.isSetCex();
16762
      if (this_present_cex || that_present_cex) {
16763
        if (!(this_present_cex && that_present_cex))
16764
          return false;
16765
        if (!this.cex.equals(that.cex))
16766
          return false;
16767
      }
16768
 
16769
      return true;
16770
    }
16771
 
16772
    @Override
16773
    public int hashCode() {
16774
      return 0;
16775
    }
16776
 
16777
    public int compareTo(addVendorItemPricing_result other) {
16778
      if (!getClass().equals(other.getClass())) {
16779
        return getClass().getName().compareTo(other.getClass().getName());
16780
      }
16781
 
16782
      int lastComparison = 0;
16783
      addVendorItemPricing_result typedOther = (addVendorItemPricing_result)other;
16784
 
16785
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
16786
      if (lastComparison != 0) {
16787
        return lastComparison;
16788
      }
16789
      if (isSetCex()) {
16790
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
16791
        if (lastComparison != 0) {
16792
          return lastComparison;
16793
        }
16794
      }
16795
      return 0;
16796
    }
16797
 
16798
    public _Fields fieldForId(int fieldId) {
16799
      return _Fields.findByThriftId(fieldId);
16800
    }
16801
 
16802
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16803
      org.apache.thrift.protocol.TField field;
16804
      iprot.readStructBegin();
16805
      while (true)
16806
      {
16807
        field = iprot.readFieldBegin();
16808
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16809
          break;
16810
        }
16811
        switch (field.id) {
16812
          case 1: // CEX
16813
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16814
              this.cex = new InventoryServiceException();
16815
              this.cex.read(iprot);
16816
            } else { 
16817
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16818
            }
16819
            break;
16820
          default:
16821
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16822
        }
16823
        iprot.readFieldEnd();
16824
      }
16825
      iprot.readStructEnd();
16826
      validate();
16827
    }
16828
 
16829
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16830
      oprot.writeStructBegin(STRUCT_DESC);
16831
 
16832
      if (this.isSetCex()) {
16833
        oprot.writeFieldBegin(CEX_FIELD_DESC);
16834
        this.cex.write(oprot);
16835
        oprot.writeFieldEnd();
16836
      }
16837
      oprot.writeFieldStop();
16838
      oprot.writeStructEnd();
16839
    }
16840
 
16841
    @Override
16842
    public String toString() {
16843
      StringBuilder sb = new StringBuilder("addVendorItemPricing_result(");
16844
      boolean first = true;
16845
 
16846
      sb.append("cex:");
16847
      if (this.cex == null) {
16848
        sb.append("null");
16849
      } else {
16850
        sb.append(this.cex);
16851
      }
16852
      first = false;
16853
      sb.append(")");
16854
      return sb.toString();
16855
    }
16856
 
16857
    public void validate() throws org.apache.thrift.TException {
16858
      // check for required fields
16859
    }
16860
 
16861
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16862
      try {
16863
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16864
      } catch (org.apache.thrift.TException te) {
16865
        throw new java.io.IOException(te);
16866
      }
16867
    }
16868
 
16869
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16870
      try {
16871
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16872
      } catch (org.apache.thrift.TException te) {
16873
        throw new java.io.IOException(te);
16874
      }
16875
    }
16876
 
16877
  }
16878
 
16879
  public static class getVendor_args implements org.apache.thrift.TBase<getVendor_args, getVendor_args._Fields>, java.io.Serializable, Cloneable   {
16880
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendor_args");
16881
 
16882
    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);
16883
 
16884
    private long vendorId; // required
16885
 
16886
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16887
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16888
      VENDOR_ID((short)1, "vendorId");
16889
 
16890
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16891
 
16892
      static {
16893
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16894
          byName.put(field.getFieldName(), field);
16895
        }
16896
      }
16897
 
16898
      /**
16899
       * Find the _Fields constant that matches fieldId, or null if its not found.
16900
       */
16901
      public static _Fields findByThriftId(int fieldId) {
16902
        switch(fieldId) {
16903
          case 1: // VENDOR_ID
16904
            return VENDOR_ID;
16905
          default:
16906
            return null;
16907
        }
16908
      }
16909
 
16910
      /**
16911
       * Find the _Fields constant that matches fieldId, throwing an exception
16912
       * if it is not found.
16913
       */
16914
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16915
        _Fields fields = findByThriftId(fieldId);
16916
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16917
        return fields;
16918
      }
16919
 
16920
      /**
16921
       * Find the _Fields constant that matches name, or null if its not found.
16922
       */
16923
      public static _Fields findByName(String name) {
16924
        return byName.get(name);
16925
      }
16926
 
16927
      private final short _thriftId;
16928
      private final String _fieldName;
16929
 
16930
      _Fields(short thriftId, String fieldName) {
16931
        _thriftId = thriftId;
16932
        _fieldName = fieldName;
16933
      }
16934
 
16935
      public short getThriftFieldId() {
16936
        return _thriftId;
16937
      }
16938
 
16939
      public String getFieldName() {
16940
        return _fieldName;
16941
      }
16942
    }
16943
 
16944
    // isset id assignments
16945
    private static final int __VENDORID_ISSET_ID = 0;
16946
    private BitSet __isset_bit_vector = new BitSet(1);
16947
 
16948
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16949
    static {
16950
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16951
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16952
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
16953
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16954
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendor_args.class, metaDataMap);
16955
    }
16956
 
16957
    public getVendor_args() {
16958
    }
16959
 
16960
    public getVendor_args(
16961
      long vendorId)
16962
    {
16963
      this();
16964
      this.vendorId = vendorId;
16965
      setVendorIdIsSet(true);
16966
    }
16967
 
16968
    /**
16969
     * Performs a deep copy on <i>other</i>.
16970
     */
16971
    public getVendor_args(getVendor_args other) {
16972
      __isset_bit_vector.clear();
16973
      __isset_bit_vector.or(other.__isset_bit_vector);
16974
      this.vendorId = other.vendorId;
16975
    }
16976
 
16977
    public getVendor_args deepCopy() {
16978
      return new getVendor_args(this);
16979
    }
16980
 
16981
    @Override
16982
    public void clear() {
16983
      setVendorIdIsSet(false);
16984
      this.vendorId = 0;
16985
    }
16986
 
16987
    public long getVendorId() {
16988
      return this.vendorId;
16989
    }
16990
 
16991
    public void setVendorId(long vendorId) {
16992
      this.vendorId = vendorId;
16993
      setVendorIdIsSet(true);
16994
    }
16995
 
16996
    public void unsetVendorId() {
16997
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
16998
    }
16999
 
17000
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
17001
    public boolean isSetVendorId() {
17002
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
17003
    }
17004
 
17005
    public void setVendorIdIsSet(boolean value) {
17006
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
17007
    }
17008
 
17009
    public void setFieldValue(_Fields field, Object value) {
17010
      switch (field) {
17011
      case VENDOR_ID:
17012
        if (value == null) {
17013
          unsetVendorId();
17014
        } else {
17015
          setVendorId((Long)value);
17016
        }
17017
        break;
17018
 
17019
      }
17020
    }
17021
 
17022
    public Object getFieldValue(_Fields field) {
17023
      switch (field) {
17024
      case VENDOR_ID:
17025
        return Long.valueOf(getVendorId());
17026
 
17027
      }
17028
      throw new IllegalStateException();
17029
    }
17030
 
17031
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17032
    public boolean isSet(_Fields field) {
17033
      if (field == null) {
17034
        throw new IllegalArgumentException();
17035
      }
17036
 
17037
      switch (field) {
17038
      case VENDOR_ID:
17039
        return isSetVendorId();
17040
      }
17041
      throw new IllegalStateException();
17042
    }
17043
 
17044
    @Override
17045
    public boolean equals(Object that) {
17046
      if (that == null)
17047
        return false;
17048
      if (that instanceof getVendor_args)
17049
        return this.equals((getVendor_args)that);
17050
      return false;
17051
    }
17052
 
17053
    public boolean equals(getVendor_args that) {
17054
      if (that == null)
17055
        return false;
17056
 
17057
      boolean this_present_vendorId = true;
17058
      boolean that_present_vendorId = true;
17059
      if (this_present_vendorId || that_present_vendorId) {
17060
        if (!(this_present_vendorId && that_present_vendorId))
17061
          return false;
17062
        if (this.vendorId != that.vendorId)
17063
          return false;
17064
      }
17065
 
17066
      return true;
17067
    }
17068
 
17069
    @Override
17070
    public int hashCode() {
17071
      return 0;
17072
    }
17073
 
17074
    public int compareTo(getVendor_args other) {
17075
      if (!getClass().equals(other.getClass())) {
17076
        return getClass().getName().compareTo(other.getClass().getName());
17077
      }
17078
 
17079
      int lastComparison = 0;
17080
      getVendor_args typedOther = (getVendor_args)other;
17081
 
17082
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
17083
      if (lastComparison != 0) {
17084
        return lastComparison;
17085
      }
17086
      if (isSetVendorId()) {
17087
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
17088
        if (lastComparison != 0) {
17089
          return lastComparison;
17090
        }
17091
      }
17092
      return 0;
17093
    }
17094
 
17095
    public _Fields fieldForId(int fieldId) {
17096
      return _Fields.findByThriftId(fieldId);
17097
    }
17098
 
17099
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17100
      org.apache.thrift.protocol.TField field;
17101
      iprot.readStructBegin();
17102
      while (true)
17103
      {
17104
        field = iprot.readFieldBegin();
17105
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17106
          break;
17107
        }
17108
        switch (field.id) {
17109
          case 1: // VENDOR_ID
17110
            if (field.type == org.apache.thrift.protocol.TType.I64) {
17111
              this.vendorId = iprot.readI64();
17112
              setVendorIdIsSet(true);
17113
            } else { 
17114
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17115
            }
17116
            break;
17117
          default:
17118
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17119
        }
17120
        iprot.readFieldEnd();
17121
      }
17122
      iprot.readStructEnd();
17123
      validate();
17124
    }
17125
 
17126
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17127
      validate();
17128
 
17129
      oprot.writeStructBegin(STRUCT_DESC);
17130
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
17131
      oprot.writeI64(this.vendorId);
17132
      oprot.writeFieldEnd();
17133
      oprot.writeFieldStop();
17134
      oprot.writeStructEnd();
17135
    }
17136
 
17137
    @Override
17138
    public String toString() {
17139
      StringBuilder sb = new StringBuilder("getVendor_args(");
17140
      boolean first = true;
17141
 
17142
      sb.append("vendorId:");
17143
      sb.append(this.vendorId);
17144
      first = false;
17145
      sb.append(")");
17146
      return sb.toString();
17147
    }
17148
 
17149
    public void validate() throws org.apache.thrift.TException {
17150
      // check for required fields
17151
    }
17152
 
17153
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17154
      try {
17155
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17156
      } catch (org.apache.thrift.TException te) {
17157
        throw new java.io.IOException(te);
17158
      }
17159
    }
17160
 
17161
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17162
      try {
17163
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
17164
        __isset_bit_vector = new BitSet(1);
17165
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17166
      } catch (org.apache.thrift.TException te) {
17167
        throw new java.io.IOException(te);
17168
      }
17169
    }
17170
 
17171
  }
17172
 
17173
  public static class getVendor_result implements org.apache.thrift.TBase<getVendor_result, getVendor_result._Fields>, java.io.Serializable, Cloneable   {
17174
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendor_result");
17175
 
17176
    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);
17177
 
17178
    private Vendor success; // required
17179
 
17180
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17181
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17182
      SUCCESS((short)0, "success");
17183
 
17184
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17185
 
17186
      static {
17187
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17188
          byName.put(field.getFieldName(), field);
17189
        }
17190
      }
17191
 
17192
      /**
17193
       * Find the _Fields constant that matches fieldId, or null if its not found.
17194
       */
17195
      public static _Fields findByThriftId(int fieldId) {
17196
        switch(fieldId) {
17197
          case 0: // SUCCESS
17198
            return SUCCESS;
17199
          default:
17200
            return null;
17201
        }
17202
      }
17203
 
17204
      /**
17205
       * Find the _Fields constant that matches fieldId, throwing an exception
17206
       * if it is not found.
17207
       */
17208
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17209
        _Fields fields = findByThriftId(fieldId);
17210
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17211
        return fields;
17212
      }
17213
 
17214
      /**
17215
       * Find the _Fields constant that matches name, or null if its not found.
17216
       */
17217
      public static _Fields findByName(String name) {
17218
        return byName.get(name);
17219
      }
17220
 
17221
      private final short _thriftId;
17222
      private final String _fieldName;
17223
 
17224
      _Fields(short thriftId, String fieldName) {
17225
        _thriftId = thriftId;
17226
        _fieldName = fieldName;
17227
      }
17228
 
17229
      public short getThriftFieldId() {
17230
        return _thriftId;
17231
      }
17232
 
17233
      public String getFieldName() {
17234
        return _fieldName;
17235
      }
17236
    }
17237
 
17238
    // isset id assignments
17239
 
17240
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17241
    static {
17242
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17243
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17244
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class)));
17245
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17246
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendor_result.class, metaDataMap);
17247
    }
17248
 
17249
    public getVendor_result() {
17250
    }
17251
 
17252
    public getVendor_result(
17253
      Vendor success)
17254
    {
17255
      this();
17256
      this.success = success;
17257
    }
17258
 
17259
    /**
17260
     * Performs a deep copy on <i>other</i>.
17261
     */
17262
    public getVendor_result(getVendor_result other) {
17263
      if (other.isSetSuccess()) {
17264
        this.success = new Vendor(other.success);
17265
      }
17266
    }
17267
 
17268
    public getVendor_result deepCopy() {
17269
      return new getVendor_result(this);
17270
    }
17271
 
17272
    @Override
17273
    public void clear() {
17274
      this.success = null;
17275
    }
17276
 
17277
    public Vendor getSuccess() {
17278
      return this.success;
17279
    }
17280
 
17281
    public void setSuccess(Vendor success) {
17282
      this.success = success;
17283
    }
17284
 
17285
    public void unsetSuccess() {
17286
      this.success = null;
17287
    }
17288
 
17289
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17290
    public boolean isSetSuccess() {
17291
      return this.success != null;
17292
    }
17293
 
17294
    public void setSuccessIsSet(boolean value) {
17295
      if (!value) {
17296
        this.success = null;
17297
      }
17298
    }
17299
 
17300
    public void setFieldValue(_Fields field, Object value) {
17301
      switch (field) {
17302
      case SUCCESS:
17303
        if (value == null) {
17304
          unsetSuccess();
17305
        } else {
17306
          setSuccess((Vendor)value);
17307
        }
17308
        break;
17309
 
17310
      }
17311
    }
17312
 
17313
    public Object getFieldValue(_Fields field) {
17314
      switch (field) {
17315
      case SUCCESS:
17316
        return getSuccess();
17317
 
17318
      }
17319
      throw new IllegalStateException();
17320
    }
17321
 
17322
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17323
    public boolean isSet(_Fields field) {
17324
      if (field == null) {
17325
        throw new IllegalArgumentException();
17326
      }
17327
 
17328
      switch (field) {
17329
      case SUCCESS:
17330
        return isSetSuccess();
17331
      }
17332
      throw new IllegalStateException();
17333
    }
17334
 
17335
    @Override
17336
    public boolean equals(Object that) {
17337
      if (that == null)
17338
        return false;
17339
      if (that instanceof getVendor_result)
17340
        return this.equals((getVendor_result)that);
17341
      return false;
17342
    }
17343
 
17344
    public boolean equals(getVendor_result that) {
17345
      if (that == null)
17346
        return false;
17347
 
17348
      boolean this_present_success = true && this.isSetSuccess();
17349
      boolean that_present_success = true && that.isSetSuccess();
17350
      if (this_present_success || that_present_success) {
17351
        if (!(this_present_success && that_present_success))
17352
          return false;
17353
        if (!this.success.equals(that.success))
17354
          return false;
17355
      }
17356
 
17357
      return true;
17358
    }
17359
 
17360
    @Override
17361
    public int hashCode() {
17362
      return 0;
17363
    }
17364
 
17365
    public int compareTo(getVendor_result other) {
17366
      if (!getClass().equals(other.getClass())) {
17367
        return getClass().getName().compareTo(other.getClass().getName());
17368
      }
17369
 
17370
      int lastComparison = 0;
17371
      getVendor_result typedOther = (getVendor_result)other;
17372
 
17373
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17374
      if (lastComparison != 0) {
17375
        return lastComparison;
17376
      }
17377
      if (isSetSuccess()) {
17378
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17379
        if (lastComparison != 0) {
17380
          return lastComparison;
17381
        }
17382
      }
17383
      return 0;
17384
    }
17385
 
17386
    public _Fields fieldForId(int fieldId) {
17387
      return _Fields.findByThriftId(fieldId);
17388
    }
17389
 
17390
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17391
      org.apache.thrift.protocol.TField field;
17392
      iprot.readStructBegin();
17393
      while (true)
17394
      {
17395
        field = iprot.readFieldBegin();
17396
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17397
          break;
17398
        }
17399
        switch (field.id) {
17400
          case 0: // SUCCESS
17401
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
17402
              this.success = new Vendor();
17403
              this.success.read(iprot);
17404
            } else { 
17405
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17406
            }
17407
            break;
17408
          default:
17409
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17410
        }
17411
        iprot.readFieldEnd();
17412
      }
17413
      iprot.readStructEnd();
17414
      validate();
17415
    }
17416
 
17417
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17418
      oprot.writeStructBegin(STRUCT_DESC);
17419
 
17420
      if (this.isSetSuccess()) {
17421
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17422
        this.success.write(oprot);
17423
        oprot.writeFieldEnd();
17424
      }
17425
      oprot.writeFieldStop();
17426
      oprot.writeStructEnd();
17427
    }
17428
 
17429
    @Override
17430
    public String toString() {
17431
      StringBuilder sb = new StringBuilder("getVendor_result(");
17432
      boolean first = true;
17433
 
17434
      sb.append("success:");
17435
      if (this.success == null) {
17436
        sb.append("null");
17437
      } else {
17438
        sb.append(this.success);
17439
      }
17440
      first = false;
17441
      sb.append(")");
17442
      return sb.toString();
17443
    }
17444
 
17445
    public void validate() throws org.apache.thrift.TException {
17446
      // check for required fields
17447
    }
17448
 
17449
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17450
      try {
17451
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17452
      } catch (org.apache.thrift.TException te) {
17453
        throw new java.io.IOException(te);
17454
      }
17455
    }
17456
 
17457
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17458
      try {
17459
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17460
      } catch (org.apache.thrift.TException te) {
17461
        throw new java.io.IOException(te);
17462
      }
17463
    }
17464
 
17465
  }
17466
 
17467
  public static class getAllVendors_args implements org.apache.thrift.TBase<getAllVendors_args, getAllVendors_args._Fields>, java.io.Serializable, Cloneable   {
17468
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendors_args");
17469
 
17470
 
17471
 
17472
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17473
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17474
;
17475
 
17476
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17477
 
17478
      static {
17479
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17480
          byName.put(field.getFieldName(), field);
17481
        }
17482
      }
17483
 
17484
      /**
17485
       * Find the _Fields constant that matches fieldId, or null if its not found.
17486
       */
17487
      public static _Fields findByThriftId(int fieldId) {
17488
        switch(fieldId) {
17489
          default:
17490
            return null;
17491
        }
17492
      }
17493
 
17494
      /**
17495
       * Find the _Fields constant that matches fieldId, throwing an exception
17496
       * if it is not found.
17497
       */
17498
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17499
        _Fields fields = findByThriftId(fieldId);
17500
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17501
        return fields;
17502
      }
17503
 
17504
      /**
17505
       * Find the _Fields constant that matches name, or null if its not found.
17506
       */
17507
      public static _Fields findByName(String name) {
17508
        return byName.get(name);
17509
      }
17510
 
17511
      private final short _thriftId;
17512
      private final String _fieldName;
17513
 
17514
      _Fields(short thriftId, String fieldName) {
17515
        _thriftId = thriftId;
17516
        _fieldName = fieldName;
17517
      }
17518
 
17519
      public short getThriftFieldId() {
17520
        return _thriftId;
17521
      }
17522
 
17523
      public String getFieldName() {
17524
        return _fieldName;
17525
      }
17526
    }
17527
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17528
    static {
17529
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17530
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17531
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendors_args.class, metaDataMap);
17532
    }
17533
 
17534
    public getAllVendors_args() {
17535
    }
17536
 
17537
    /**
17538
     * Performs a deep copy on <i>other</i>.
17539
     */
17540
    public getAllVendors_args(getAllVendors_args other) {
17541
    }
17542
 
17543
    public getAllVendors_args deepCopy() {
17544
      return new getAllVendors_args(this);
17545
    }
17546
 
17547
    @Override
17548
    public void clear() {
17549
    }
17550
 
17551
    public void setFieldValue(_Fields field, Object value) {
17552
      switch (field) {
17553
      }
17554
    }
17555
 
17556
    public Object getFieldValue(_Fields field) {
17557
      switch (field) {
17558
      }
17559
      throw new IllegalStateException();
17560
    }
17561
 
17562
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17563
    public boolean isSet(_Fields field) {
17564
      if (field == null) {
17565
        throw new IllegalArgumentException();
17566
      }
17567
 
17568
      switch (field) {
17569
      }
17570
      throw new IllegalStateException();
17571
    }
17572
 
17573
    @Override
17574
    public boolean equals(Object that) {
17575
      if (that == null)
17576
        return false;
17577
      if (that instanceof getAllVendors_args)
17578
        return this.equals((getAllVendors_args)that);
17579
      return false;
17580
    }
17581
 
17582
    public boolean equals(getAllVendors_args that) {
17583
      if (that == null)
17584
        return false;
17585
 
17586
      return true;
17587
    }
17588
 
17589
    @Override
17590
    public int hashCode() {
17591
      return 0;
17592
    }
17593
 
17594
    public int compareTo(getAllVendors_args other) {
17595
      if (!getClass().equals(other.getClass())) {
17596
        return getClass().getName().compareTo(other.getClass().getName());
17597
      }
17598
 
17599
      int lastComparison = 0;
17600
      getAllVendors_args typedOther = (getAllVendors_args)other;
17601
 
17602
      return 0;
17603
    }
17604
 
17605
    public _Fields fieldForId(int fieldId) {
17606
      return _Fields.findByThriftId(fieldId);
17607
    }
17608
 
17609
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17610
      org.apache.thrift.protocol.TField field;
17611
      iprot.readStructBegin();
17612
      while (true)
17613
      {
17614
        field = iprot.readFieldBegin();
17615
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17616
          break;
17617
        }
17618
        switch (field.id) {
17619
          default:
17620
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17621
        }
17622
        iprot.readFieldEnd();
17623
      }
17624
      iprot.readStructEnd();
17625
      validate();
17626
    }
17627
 
17628
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17629
      validate();
17630
 
17631
      oprot.writeStructBegin(STRUCT_DESC);
17632
      oprot.writeFieldStop();
17633
      oprot.writeStructEnd();
17634
    }
17635
 
17636
    @Override
17637
    public String toString() {
17638
      StringBuilder sb = new StringBuilder("getAllVendors_args(");
17639
      boolean first = true;
17640
 
17641
      sb.append(")");
17642
      return sb.toString();
17643
    }
17644
 
17645
    public void validate() throws org.apache.thrift.TException {
17646
      // check for required fields
17647
    }
17648
 
17649
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17650
      try {
17651
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17652
      } catch (org.apache.thrift.TException te) {
17653
        throw new java.io.IOException(te);
17654
      }
17655
    }
17656
 
17657
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17658
      try {
17659
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17660
      } catch (org.apache.thrift.TException te) {
17661
        throw new java.io.IOException(te);
17662
      }
17663
    }
17664
 
17665
  }
17666
 
17667
  public static class getAllVendors_result implements org.apache.thrift.TBase<getAllVendors_result, getAllVendors_result._Fields>, java.io.Serializable, Cloneable   {
17668
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendors_result");
17669
 
17670
    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);
17671
 
17672
    private List<Vendor> success; // required
17673
 
17674
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17675
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17676
      SUCCESS((short)0, "success");
17677
 
17678
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17679
 
17680
      static {
17681
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17682
          byName.put(field.getFieldName(), field);
17683
        }
17684
      }
17685
 
17686
      /**
17687
       * Find the _Fields constant that matches fieldId, or null if its not found.
17688
       */
17689
      public static _Fields findByThriftId(int fieldId) {
17690
        switch(fieldId) {
17691
          case 0: // SUCCESS
17692
            return SUCCESS;
17693
          default:
17694
            return null;
17695
        }
17696
      }
17697
 
17698
      /**
17699
       * Find the _Fields constant that matches fieldId, throwing an exception
17700
       * if it is not found.
17701
       */
17702
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17703
        _Fields fields = findByThriftId(fieldId);
17704
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17705
        return fields;
17706
      }
17707
 
17708
      /**
17709
       * Find the _Fields constant that matches name, or null if its not found.
17710
       */
17711
      public static _Fields findByName(String name) {
17712
        return byName.get(name);
17713
      }
17714
 
17715
      private final short _thriftId;
17716
      private final String _fieldName;
17717
 
17718
      _Fields(short thriftId, String fieldName) {
17719
        _thriftId = thriftId;
17720
        _fieldName = fieldName;
17721
      }
17722
 
17723
      public short getThriftFieldId() {
17724
        return _thriftId;
17725
      }
17726
 
17727
      public String getFieldName() {
17728
        return _fieldName;
17729
      }
17730
    }
17731
 
17732
    // isset id assignments
17733
 
17734
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17735
    static {
17736
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17737
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17738
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
17739
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class))));
17740
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17741
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendors_result.class, metaDataMap);
17742
    }
17743
 
17744
    public getAllVendors_result() {
17745
    }
17746
 
17747
    public getAllVendors_result(
17748
      List<Vendor> success)
17749
    {
17750
      this();
17751
      this.success = success;
17752
    }
17753
 
17754
    /**
17755
     * Performs a deep copy on <i>other</i>.
17756
     */
17757
    public getAllVendors_result(getAllVendors_result other) {
17758
      if (other.isSetSuccess()) {
17759
        List<Vendor> __this__success = new ArrayList<Vendor>();
17760
        for (Vendor other_element : other.success) {
17761
          __this__success.add(new Vendor(other_element));
17762
        }
17763
        this.success = __this__success;
17764
      }
17765
    }
17766
 
17767
    public getAllVendors_result deepCopy() {
17768
      return new getAllVendors_result(this);
17769
    }
17770
 
17771
    @Override
17772
    public void clear() {
17773
      this.success = null;
17774
    }
17775
 
17776
    public int getSuccessSize() {
17777
      return (this.success == null) ? 0 : this.success.size();
17778
    }
17779
 
17780
    public java.util.Iterator<Vendor> getSuccessIterator() {
17781
      return (this.success == null) ? null : this.success.iterator();
17782
    }
17783
 
17784
    public void addToSuccess(Vendor elem) {
17785
      if (this.success == null) {
17786
        this.success = new ArrayList<Vendor>();
17787
      }
17788
      this.success.add(elem);
17789
    }
17790
 
17791
    public List<Vendor> getSuccess() {
17792
      return this.success;
17793
    }
17794
 
17795
    public void setSuccess(List<Vendor> success) {
17796
      this.success = success;
17797
    }
17798
 
17799
    public void unsetSuccess() {
17800
      this.success = null;
17801
    }
17802
 
17803
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17804
    public boolean isSetSuccess() {
17805
      return this.success != null;
17806
    }
17807
 
17808
    public void setSuccessIsSet(boolean value) {
17809
      if (!value) {
17810
        this.success = null;
17811
      }
17812
    }
17813
 
17814
    public void setFieldValue(_Fields field, Object value) {
17815
      switch (field) {
17816
      case SUCCESS:
17817
        if (value == null) {
17818
          unsetSuccess();
17819
        } else {
17820
          setSuccess((List<Vendor>)value);
17821
        }
17822
        break;
17823
 
17824
      }
17825
    }
17826
 
17827
    public Object getFieldValue(_Fields field) {
17828
      switch (field) {
17829
      case SUCCESS:
17830
        return getSuccess();
17831
 
17832
      }
17833
      throw new IllegalStateException();
17834
    }
17835
 
17836
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17837
    public boolean isSet(_Fields field) {
17838
      if (field == null) {
17839
        throw new IllegalArgumentException();
17840
      }
17841
 
17842
      switch (field) {
17843
      case SUCCESS:
17844
        return isSetSuccess();
17845
      }
17846
      throw new IllegalStateException();
17847
    }
17848
 
17849
    @Override
17850
    public boolean equals(Object that) {
17851
      if (that == null)
17852
        return false;
17853
      if (that instanceof getAllVendors_result)
17854
        return this.equals((getAllVendors_result)that);
17855
      return false;
17856
    }
17857
 
17858
    public boolean equals(getAllVendors_result that) {
17859
      if (that == null)
17860
        return false;
17861
 
17862
      boolean this_present_success = true && this.isSetSuccess();
17863
      boolean that_present_success = true && that.isSetSuccess();
17864
      if (this_present_success || that_present_success) {
17865
        if (!(this_present_success && that_present_success))
17866
          return false;
17867
        if (!this.success.equals(that.success))
17868
          return false;
17869
      }
17870
 
17871
      return true;
17872
    }
17873
 
17874
    @Override
17875
    public int hashCode() {
17876
      return 0;
17877
    }
17878
 
17879
    public int compareTo(getAllVendors_result other) {
17880
      if (!getClass().equals(other.getClass())) {
17881
        return getClass().getName().compareTo(other.getClass().getName());
17882
      }
17883
 
17884
      int lastComparison = 0;
17885
      getAllVendors_result typedOther = (getAllVendors_result)other;
17886
 
17887
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17888
      if (lastComparison != 0) {
17889
        return lastComparison;
17890
      }
17891
      if (isSetSuccess()) {
17892
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17893
        if (lastComparison != 0) {
17894
          return lastComparison;
17895
        }
17896
      }
17897
      return 0;
17898
    }
17899
 
17900
    public _Fields fieldForId(int fieldId) {
17901
      return _Fields.findByThriftId(fieldId);
17902
    }
17903
 
17904
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17905
      org.apache.thrift.protocol.TField field;
17906
      iprot.readStructBegin();
17907
      while (true)
17908
      {
17909
        field = iprot.readFieldBegin();
17910
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17911
          break;
17912
        }
17913
        switch (field.id) {
17914
          case 0: // SUCCESS
17915
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
17916
              {
17917
                org.apache.thrift.protocol.TList _list36 = iprot.readListBegin();
17918
                this.success = new ArrayList<Vendor>(_list36.size);
17919
                for (int _i37 = 0; _i37 < _list36.size; ++_i37)
17920
                {
17921
                  Vendor _elem38; // required
17922
                  _elem38 = new Vendor();
17923
                  _elem38.read(iprot);
17924
                  this.success.add(_elem38);
17925
                }
17926
                iprot.readListEnd();
17927
              }
17928
            } else { 
17929
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17930
            }
17931
            break;
17932
          default:
17933
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17934
        }
17935
        iprot.readFieldEnd();
17936
      }
17937
      iprot.readStructEnd();
17938
      validate();
17939
    }
17940
 
17941
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17942
      oprot.writeStructBegin(STRUCT_DESC);
17943
 
17944
      if (this.isSetSuccess()) {
17945
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17946
        {
17947
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
17948
          for (Vendor _iter39 : this.success)
17949
          {
17950
            _iter39.write(oprot);
17951
          }
17952
          oprot.writeListEnd();
17953
        }
17954
        oprot.writeFieldEnd();
17955
      }
17956
      oprot.writeFieldStop();
17957
      oprot.writeStructEnd();
17958
    }
17959
 
17960
    @Override
17961
    public String toString() {
17962
      StringBuilder sb = new StringBuilder("getAllVendors_result(");
17963
      boolean first = true;
17964
 
17965
      sb.append("success:");
17966
      if (this.success == null) {
17967
        sb.append("null");
17968
      } else {
17969
        sb.append(this.success);
17970
      }
17971
      first = false;
17972
      sb.append(")");
17973
      return sb.toString();
17974
    }
17975
 
17976
    public void validate() throws org.apache.thrift.TException {
17977
      // check for required fields
17978
    }
17979
 
17980
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17981
      try {
17982
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17983
      } catch (org.apache.thrift.TException te) {
17984
        throw new java.io.IOException(te);
17985
      }
17986
    }
17987
 
17988
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17989
      try {
17990
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17991
      } catch (org.apache.thrift.TException te) {
17992
        throw new java.io.IOException(te);
17993
      }
17994
    }
17995
 
17996
  }
17997
 
17998
  public static class addVendorItemMapping_args implements org.apache.thrift.TBase<addVendorItemMapping_args, addVendorItemMapping_args._Fields>, java.io.Serializable, Cloneable   {
17999
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemMapping_args");
18000
 
18001
    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);
18002
    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);
18003
 
18004
    private String key; // required
18005
    private VendorItemMapping vendorItemMapping; // required
18006
 
18007
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18008
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18009
      KEY((short)1, "key"),
18010
      VENDOR_ITEM_MAPPING((short)2, "vendorItemMapping");
18011
 
18012
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18013
 
18014
      static {
18015
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18016
          byName.put(field.getFieldName(), field);
18017
        }
18018
      }
18019
 
18020
      /**
18021
       * Find the _Fields constant that matches fieldId, or null if its not found.
18022
       */
18023
      public static _Fields findByThriftId(int fieldId) {
18024
        switch(fieldId) {
18025
          case 1: // KEY
18026
            return KEY;
18027
          case 2: // VENDOR_ITEM_MAPPING
18028
            return VENDOR_ITEM_MAPPING;
18029
          default:
18030
            return null;
18031
        }
18032
      }
18033
 
18034
      /**
18035
       * Find the _Fields constant that matches fieldId, throwing an exception
18036
       * if it is not found.
18037
       */
18038
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18039
        _Fields fields = findByThriftId(fieldId);
18040
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18041
        return fields;
18042
      }
18043
 
18044
      /**
18045
       * Find the _Fields constant that matches name, or null if its not found.
18046
       */
18047
      public static _Fields findByName(String name) {
18048
        return byName.get(name);
18049
      }
18050
 
18051
      private final short _thriftId;
18052
      private final String _fieldName;
18053
 
18054
      _Fields(short thriftId, String fieldName) {
18055
        _thriftId = thriftId;
18056
        _fieldName = fieldName;
18057
      }
18058
 
18059
      public short getThriftFieldId() {
18060
        return _thriftId;
18061
      }
18062
 
18063
      public String getFieldName() {
18064
        return _fieldName;
18065
      }
18066
    }
18067
 
18068
    // isset id assignments
18069
 
18070
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18071
    static {
18072
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18073
      tmpMap.put(_Fields.KEY, new org.apache.thrift.meta_data.FieldMetaData("key", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18074
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
18075
      tmpMap.put(_Fields.VENDOR_ITEM_MAPPING, new org.apache.thrift.meta_data.FieldMetaData("vendorItemMapping", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18076
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class)));
18077
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18078
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemMapping_args.class, metaDataMap);
18079
    }
18080
 
18081
    public addVendorItemMapping_args() {
18082
    }
18083
 
18084
    public addVendorItemMapping_args(
18085
      String key,
18086
      VendorItemMapping vendorItemMapping)
18087
    {
18088
      this();
18089
      this.key = key;
18090
      this.vendorItemMapping = vendorItemMapping;
18091
    }
18092
 
18093
    /**
18094
     * Performs a deep copy on <i>other</i>.
18095
     */
18096
    public addVendorItemMapping_args(addVendorItemMapping_args other) {
18097
      if (other.isSetKey()) {
18098
        this.key = other.key;
18099
      }
18100
      if (other.isSetVendorItemMapping()) {
18101
        this.vendorItemMapping = new VendorItemMapping(other.vendorItemMapping);
18102
      }
18103
    }
18104
 
18105
    public addVendorItemMapping_args deepCopy() {
18106
      return new addVendorItemMapping_args(this);
18107
    }
18108
 
18109
    @Override
18110
    public void clear() {
18111
      this.key = null;
18112
      this.vendorItemMapping = null;
18113
    }
18114
 
18115
    public String getKey() {
18116
      return this.key;
18117
    }
18118
 
18119
    public void setKey(String key) {
18120
      this.key = key;
18121
    }
18122
 
18123
    public void unsetKey() {
18124
      this.key = null;
18125
    }
18126
 
18127
    /** Returns true if field key is set (has been assigned a value) and false otherwise */
18128
    public boolean isSetKey() {
18129
      return this.key != null;
18130
    }
18131
 
18132
    public void setKeyIsSet(boolean value) {
18133
      if (!value) {
18134
        this.key = null;
18135
      }
18136
    }
18137
 
18138
    public VendorItemMapping getVendorItemMapping() {
18139
      return this.vendorItemMapping;
18140
    }
18141
 
18142
    public void setVendorItemMapping(VendorItemMapping vendorItemMapping) {
18143
      this.vendorItemMapping = vendorItemMapping;
18144
    }
18145
 
18146
    public void unsetVendorItemMapping() {
18147
      this.vendorItemMapping = null;
18148
    }
18149
 
18150
    /** Returns true if field vendorItemMapping is set (has been assigned a value) and false otherwise */
18151
    public boolean isSetVendorItemMapping() {
18152
      return this.vendorItemMapping != null;
18153
    }
18154
 
18155
    public void setVendorItemMappingIsSet(boolean value) {
18156
      if (!value) {
18157
        this.vendorItemMapping = null;
18158
      }
18159
    }
18160
 
18161
    public void setFieldValue(_Fields field, Object value) {
18162
      switch (field) {
18163
      case KEY:
18164
        if (value == null) {
18165
          unsetKey();
18166
        } else {
18167
          setKey((String)value);
18168
        }
18169
        break;
18170
 
18171
      case VENDOR_ITEM_MAPPING:
18172
        if (value == null) {
18173
          unsetVendorItemMapping();
18174
        } else {
18175
          setVendorItemMapping((VendorItemMapping)value);
18176
        }
18177
        break;
18178
 
18179
      }
18180
    }
18181
 
18182
    public Object getFieldValue(_Fields field) {
18183
      switch (field) {
18184
      case KEY:
18185
        return getKey();
18186
 
18187
      case VENDOR_ITEM_MAPPING:
18188
        return getVendorItemMapping();
18189
 
18190
      }
18191
      throw new IllegalStateException();
18192
    }
18193
 
18194
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18195
    public boolean isSet(_Fields field) {
18196
      if (field == null) {
18197
        throw new IllegalArgumentException();
18198
      }
18199
 
18200
      switch (field) {
18201
      case KEY:
18202
        return isSetKey();
18203
      case VENDOR_ITEM_MAPPING:
18204
        return isSetVendorItemMapping();
18205
      }
18206
      throw new IllegalStateException();
18207
    }
18208
 
18209
    @Override
18210
    public boolean equals(Object that) {
18211
      if (that == null)
18212
        return false;
18213
      if (that instanceof addVendorItemMapping_args)
18214
        return this.equals((addVendorItemMapping_args)that);
18215
      return false;
18216
    }
18217
 
18218
    public boolean equals(addVendorItemMapping_args that) {
18219
      if (that == null)
18220
        return false;
18221
 
18222
      boolean this_present_key = true && this.isSetKey();
18223
      boolean that_present_key = true && that.isSetKey();
18224
      if (this_present_key || that_present_key) {
18225
        if (!(this_present_key && that_present_key))
18226
          return false;
18227
        if (!this.key.equals(that.key))
18228
          return false;
18229
      }
18230
 
18231
      boolean this_present_vendorItemMapping = true && this.isSetVendorItemMapping();
18232
      boolean that_present_vendorItemMapping = true && that.isSetVendorItemMapping();
18233
      if (this_present_vendorItemMapping || that_present_vendorItemMapping) {
18234
        if (!(this_present_vendorItemMapping && that_present_vendorItemMapping))
18235
          return false;
18236
        if (!this.vendorItemMapping.equals(that.vendorItemMapping))
18237
          return false;
18238
      }
18239
 
18240
      return true;
18241
    }
18242
 
18243
    @Override
18244
    public int hashCode() {
18245
      return 0;
18246
    }
18247
 
18248
    public int compareTo(addVendorItemMapping_args other) {
18249
      if (!getClass().equals(other.getClass())) {
18250
        return getClass().getName().compareTo(other.getClass().getName());
18251
      }
18252
 
18253
      int lastComparison = 0;
18254
      addVendorItemMapping_args typedOther = (addVendorItemMapping_args)other;
18255
 
18256
      lastComparison = Boolean.valueOf(isSetKey()).compareTo(typedOther.isSetKey());
18257
      if (lastComparison != 0) {
18258
        return lastComparison;
18259
      }
18260
      if (isSetKey()) {
18261
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.key, typedOther.key);
18262
        if (lastComparison != 0) {
18263
          return lastComparison;
18264
        }
18265
      }
18266
      lastComparison = Boolean.valueOf(isSetVendorItemMapping()).compareTo(typedOther.isSetVendorItemMapping());
18267
      if (lastComparison != 0) {
18268
        return lastComparison;
18269
      }
18270
      if (isSetVendorItemMapping()) {
18271
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorItemMapping, typedOther.vendorItemMapping);
18272
        if (lastComparison != 0) {
18273
          return lastComparison;
18274
        }
18275
      }
18276
      return 0;
18277
    }
18278
 
18279
    public _Fields fieldForId(int fieldId) {
18280
      return _Fields.findByThriftId(fieldId);
18281
    }
18282
 
18283
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18284
      org.apache.thrift.protocol.TField field;
18285
      iprot.readStructBegin();
18286
      while (true)
18287
      {
18288
        field = iprot.readFieldBegin();
18289
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18290
          break;
18291
        }
18292
        switch (field.id) {
18293
          case 1: // KEY
18294
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
18295
              this.key = iprot.readString();
18296
            } else { 
18297
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18298
            }
18299
            break;
18300
          case 2: // VENDOR_ITEM_MAPPING
18301
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
18302
              this.vendorItemMapping = new VendorItemMapping();
18303
              this.vendorItemMapping.read(iprot);
18304
            } else { 
18305
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18306
            }
18307
            break;
18308
          default:
18309
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18310
        }
18311
        iprot.readFieldEnd();
18312
      }
18313
      iprot.readStructEnd();
18314
      validate();
18315
    }
18316
 
18317
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18318
      validate();
18319
 
18320
      oprot.writeStructBegin(STRUCT_DESC);
18321
      if (this.key != null) {
18322
        oprot.writeFieldBegin(KEY_FIELD_DESC);
18323
        oprot.writeString(this.key);
18324
        oprot.writeFieldEnd();
18325
      }
18326
      if (this.vendorItemMapping != null) {
18327
        oprot.writeFieldBegin(VENDOR_ITEM_MAPPING_FIELD_DESC);
18328
        this.vendorItemMapping.write(oprot);
18329
        oprot.writeFieldEnd();
18330
      }
18331
      oprot.writeFieldStop();
18332
      oprot.writeStructEnd();
18333
    }
18334
 
18335
    @Override
18336
    public String toString() {
18337
      StringBuilder sb = new StringBuilder("addVendorItemMapping_args(");
18338
      boolean first = true;
18339
 
18340
      sb.append("key:");
18341
      if (this.key == null) {
18342
        sb.append("null");
18343
      } else {
18344
        sb.append(this.key);
18345
      }
18346
      first = false;
18347
      if (!first) sb.append(", ");
18348
      sb.append("vendorItemMapping:");
18349
      if (this.vendorItemMapping == null) {
18350
        sb.append("null");
18351
      } else {
18352
        sb.append(this.vendorItemMapping);
18353
      }
18354
      first = false;
18355
      sb.append(")");
18356
      return sb.toString();
18357
    }
18358
 
18359
    public void validate() throws org.apache.thrift.TException {
18360
      // check for required fields
18361
    }
18362
 
18363
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18364
      try {
18365
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18366
      } catch (org.apache.thrift.TException te) {
18367
        throw new java.io.IOException(te);
18368
      }
18369
    }
18370
 
18371
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18372
      try {
18373
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18374
      } catch (org.apache.thrift.TException te) {
18375
        throw new java.io.IOException(te);
18376
      }
18377
    }
18378
 
18379
  }
18380
 
18381
  public static class addVendorItemMapping_result implements org.apache.thrift.TBase<addVendorItemMapping_result, addVendorItemMapping_result._Fields>, java.io.Serializable, Cloneable   {
18382
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemMapping_result");
18383
 
18384
    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);
18385
 
18386
    private InventoryServiceException cex; // required
18387
 
18388
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18389
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18390
      CEX((short)1, "cex");
18391
 
18392
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18393
 
18394
      static {
18395
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18396
          byName.put(field.getFieldName(), field);
18397
        }
18398
      }
18399
 
18400
      /**
18401
       * Find the _Fields constant that matches fieldId, or null if its not found.
18402
       */
18403
      public static _Fields findByThriftId(int fieldId) {
18404
        switch(fieldId) {
18405
          case 1: // CEX
18406
            return CEX;
18407
          default:
18408
            return null;
18409
        }
18410
      }
18411
 
18412
      /**
18413
       * Find the _Fields constant that matches fieldId, throwing an exception
18414
       * if it is not found.
18415
       */
18416
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18417
        _Fields fields = findByThriftId(fieldId);
18418
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18419
        return fields;
18420
      }
18421
 
18422
      /**
18423
       * Find the _Fields constant that matches name, or null if its not found.
18424
       */
18425
      public static _Fields findByName(String name) {
18426
        return byName.get(name);
18427
      }
18428
 
18429
      private final short _thriftId;
18430
      private final String _fieldName;
18431
 
18432
      _Fields(short thriftId, String fieldName) {
18433
        _thriftId = thriftId;
18434
        _fieldName = fieldName;
18435
      }
18436
 
18437
      public short getThriftFieldId() {
18438
        return _thriftId;
18439
      }
18440
 
18441
      public String getFieldName() {
18442
        return _fieldName;
18443
      }
18444
    }
18445
 
18446
    // isset id assignments
18447
 
18448
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18449
    static {
18450
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18451
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18452
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
18453
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18454
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemMapping_result.class, metaDataMap);
18455
    }
18456
 
18457
    public addVendorItemMapping_result() {
18458
    }
18459
 
18460
    public addVendorItemMapping_result(
18461
      InventoryServiceException cex)
18462
    {
18463
      this();
18464
      this.cex = cex;
18465
    }
18466
 
18467
    /**
18468
     * Performs a deep copy on <i>other</i>.
18469
     */
18470
    public addVendorItemMapping_result(addVendorItemMapping_result other) {
18471
      if (other.isSetCex()) {
18472
        this.cex = new InventoryServiceException(other.cex);
18473
      }
18474
    }
18475
 
18476
    public addVendorItemMapping_result deepCopy() {
18477
      return new addVendorItemMapping_result(this);
18478
    }
18479
 
18480
    @Override
18481
    public void clear() {
18482
      this.cex = null;
18483
    }
18484
 
18485
    public InventoryServiceException getCex() {
18486
      return this.cex;
18487
    }
18488
 
18489
    public void setCex(InventoryServiceException cex) {
18490
      this.cex = cex;
18491
    }
18492
 
18493
    public void unsetCex() {
18494
      this.cex = null;
18495
    }
18496
 
18497
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
18498
    public boolean isSetCex() {
18499
      return this.cex != null;
18500
    }
18501
 
18502
    public void setCexIsSet(boolean value) {
18503
      if (!value) {
18504
        this.cex = null;
18505
      }
18506
    }
18507
 
18508
    public void setFieldValue(_Fields field, Object value) {
18509
      switch (field) {
18510
      case CEX:
18511
        if (value == null) {
18512
          unsetCex();
18513
        } else {
18514
          setCex((InventoryServiceException)value);
18515
        }
18516
        break;
18517
 
18518
      }
18519
    }
18520
 
18521
    public Object getFieldValue(_Fields field) {
18522
      switch (field) {
18523
      case CEX:
18524
        return getCex();
18525
 
18526
      }
18527
      throw new IllegalStateException();
18528
    }
18529
 
18530
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18531
    public boolean isSet(_Fields field) {
18532
      if (field == null) {
18533
        throw new IllegalArgumentException();
18534
      }
18535
 
18536
      switch (field) {
18537
      case CEX:
18538
        return isSetCex();
18539
      }
18540
      throw new IllegalStateException();
18541
    }
18542
 
18543
    @Override
18544
    public boolean equals(Object that) {
18545
      if (that == null)
18546
        return false;
18547
      if (that instanceof addVendorItemMapping_result)
18548
        return this.equals((addVendorItemMapping_result)that);
18549
      return false;
18550
    }
18551
 
18552
    public boolean equals(addVendorItemMapping_result that) {
18553
      if (that == null)
18554
        return false;
18555
 
18556
      boolean this_present_cex = true && this.isSetCex();
18557
      boolean that_present_cex = true && that.isSetCex();
18558
      if (this_present_cex || that_present_cex) {
18559
        if (!(this_present_cex && that_present_cex))
18560
          return false;
18561
        if (!this.cex.equals(that.cex))
18562
          return false;
18563
      }
18564
 
18565
      return true;
18566
    }
18567
 
18568
    @Override
18569
    public int hashCode() {
18570
      return 0;
18571
    }
18572
 
18573
    public int compareTo(addVendorItemMapping_result other) {
18574
      if (!getClass().equals(other.getClass())) {
18575
        return getClass().getName().compareTo(other.getClass().getName());
18576
      }
18577
 
18578
      int lastComparison = 0;
18579
      addVendorItemMapping_result typedOther = (addVendorItemMapping_result)other;
18580
 
18581
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
18582
      if (lastComparison != 0) {
18583
        return lastComparison;
18584
      }
18585
      if (isSetCex()) {
18586
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
18587
        if (lastComparison != 0) {
18588
          return lastComparison;
18589
        }
18590
      }
18591
      return 0;
18592
    }
18593
 
18594
    public _Fields fieldForId(int fieldId) {
18595
      return _Fields.findByThriftId(fieldId);
18596
    }
18597
 
18598
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18599
      org.apache.thrift.protocol.TField field;
18600
      iprot.readStructBegin();
18601
      while (true)
18602
      {
18603
        field = iprot.readFieldBegin();
18604
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18605
          break;
18606
        }
18607
        switch (field.id) {
18608
          case 1: // CEX
18609
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
18610
              this.cex = new InventoryServiceException();
18611
              this.cex.read(iprot);
18612
            } else { 
18613
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18614
            }
18615
            break;
18616
          default:
18617
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18618
        }
18619
        iprot.readFieldEnd();
18620
      }
18621
      iprot.readStructEnd();
18622
      validate();
18623
    }
18624
 
18625
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18626
      oprot.writeStructBegin(STRUCT_DESC);
18627
 
18628
      if (this.isSetCex()) {
18629
        oprot.writeFieldBegin(CEX_FIELD_DESC);
18630
        this.cex.write(oprot);
18631
        oprot.writeFieldEnd();
18632
      }
18633
      oprot.writeFieldStop();
18634
      oprot.writeStructEnd();
18635
    }
18636
 
18637
    @Override
18638
    public String toString() {
18639
      StringBuilder sb = new StringBuilder("addVendorItemMapping_result(");
18640
      boolean first = true;
18641
 
18642
      sb.append("cex:");
18643
      if (this.cex == null) {
18644
        sb.append("null");
18645
      } else {
18646
        sb.append(this.cex);
18647
      }
18648
      first = false;
18649
      sb.append(")");
18650
      return sb.toString();
18651
    }
18652
 
18653
    public void validate() throws org.apache.thrift.TException {
18654
      // check for required fields
18655
    }
18656
 
18657
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18658
      try {
18659
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18660
      } catch (org.apache.thrift.TException te) {
18661
        throw new java.io.IOException(te);
18662
      }
18663
    }
18664
 
18665
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18666
      try {
18667
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18668
      } catch (org.apache.thrift.TException te) {
18669
        throw new java.io.IOException(te);
18670
      }
18671
    }
18672
 
18673
  }
18674
 
18675
  public static class getVendorItemMappings_args implements org.apache.thrift.TBase<getVendorItemMappings_args, getVendorItemMappings_args._Fields>, java.io.Serializable, Cloneable   {
18676
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendorItemMappings_args");
18677
 
18678
    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);
18679
 
18680
    private long itemId; // required
18681
 
18682
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18683
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18684
      ITEM_ID((short)1, "itemId");
18685
 
18686
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18687
 
18688
      static {
18689
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18690
          byName.put(field.getFieldName(), field);
18691
        }
18692
      }
18693
 
18694
      /**
18695
       * Find the _Fields constant that matches fieldId, or null if its not found.
18696
       */
18697
      public static _Fields findByThriftId(int fieldId) {
18698
        switch(fieldId) {
18699
          case 1: // ITEM_ID
18700
            return ITEM_ID;
18701
          default:
18702
            return null;
18703
        }
18704
      }
18705
 
18706
      /**
18707
       * Find the _Fields constant that matches fieldId, throwing an exception
18708
       * if it is not found.
18709
       */
18710
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18711
        _Fields fields = findByThriftId(fieldId);
18712
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18713
        return fields;
18714
      }
18715
 
18716
      /**
18717
       * Find the _Fields constant that matches name, or null if its not found.
18718
       */
18719
      public static _Fields findByName(String name) {
18720
        return byName.get(name);
18721
      }
18722
 
18723
      private final short _thriftId;
18724
      private final String _fieldName;
18725
 
18726
      _Fields(short thriftId, String fieldName) {
18727
        _thriftId = thriftId;
18728
        _fieldName = fieldName;
18729
      }
18730
 
18731
      public short getThriftFieldId() {
18732
        return _thriftId;
18733
      }
18734
 
18735
      public String getFieldName() {
18736
        return _fieldName;
18737
      }
18738
    }
18739
 
18740
    // isset id assignments
18741
    private static final int __ITEMID_ISSET_ID = 0;
18742
    private BitSet __isset_bit_vector = new BitSet(1);
18743
 
18744
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18745
    static {
18746
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18747
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18748
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
18749
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18750
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendorItemMappings_args.class, metaDataMap);
18751
    }
18752
 
18753
    public getVendorItemMappings_args() {
18754
    }
18755
 
18756
    public getVendorItemMappings_args(
18757
      long itemId)
18758
    {
18759
      this();
18760
      this.itemId = itemId;
18761
      setItemIdIsSet(true);
18762
    }
18763
 
18764
    /**
18765
     * Performs a deep copy on <i>other</i>.
18766
     */
18767
    public getVendorItemMappings_args(getVendorItemMappings_args other) {
18768
      __isset_bit_vector.clear();
18769
      __isset_bit_vector.or(other.__isset_bit_vector);
18770
      this.itemId = other.itemId;
18771
    }
18772
 
18773
    public getVendorItemMappings_args deepCopy() {
18774
      return new getVendorItemMappings_args(this);
18775
    }
18776
 
18777
    @Override
18778
    public void clear() {
18779
      setItemIdIsSet(false);
18780
      this.itemId = 0;
18781
    }
18782
 
18783
    public long getItemId() {
18784
      return this.itemId;
18785
    }
18786
 
18787
    public void setItemId(long itemId) {
18788
      this.itemId = itemId;
18789
      setItemIdIsSet(true);
18790
    }
18791
 
18792
    public void unsetItemId() {
18793
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
18794
    }
18795
 
18796
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
18797
    public boolean isSetItemId() {
18798
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
18799
    }
18800
 
18801
    public void setItemIdIsSet(boolean value) {
18802
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
18803
    }
18804
 
18805
    public void setFieldValue(_Fields field, Object value) {
18806
      switch (field) {
18807
      case ITEM_ID:
18808
        if (value == null) {
18809
          unsetItemId();
18810
        } else {
18811
          setItemId((Long)value);
18812
        }
18813
        break;
18814
 
18815
      }
18816
    }
18817
 
18818
    public Object getFieldValue(_Fields field) {
18819
      switch (field) {
18820
      case ITEM_ID:
18821
        return Long.valueOf(getItemId());
18822
 
18823
      }
18824
      throw new IllegalStateException();
18825
    }
18826
 
18827
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18828
    public boolean isSet(_Fields field) {
18829
      if (field == null) {
18830
        throw new IllegalArgumentException();
18831
      }
18832
 
18833
      switch (field) {
18834
      case ITEM_ID:
18835
        return isSetItemId();
18836
      }
18837
      throw new IllegalStateException();
18838
    }
18839
 
18840
    @Override
18841
    public boolean equals(Object that) {
18842
      if (that == null)
18843
        return false;
18844
      if (that instanceof getVendorItemMappings_args)
18845
        return this.equals((getVendorItemMappings_args)that);
18846
      return false;
18847
    }
18848
 
18849
    public boolean equals(getVendorItemMappings_args that) {
18850
      if (that == null)
18851
        return false;
18852
 
18853
      boolean this_present_itemId = true;
18854
      boolean that_present_itemId = true;
18855
      if (this_present_itemId || that_present_itemId) {
18856
        if (!(this_present_itemId && that_present_itemId))
18857
          return false;
18858
        if (this.itemId != that.itemId)
18859
          return false;
18860
      }
18861
 
18862
      return true;
18863
    }
18864
 
18865
    @Override
18866
    public int hashCode() {
18867
      return 0;
18868
    }
18869
 
18870
    public int compareTo(getVendorItemMappings_args other) {
18871
      if (!getClass().equals(other.getClass())) {
18872
        return getClass().getName().compareTo(other.getClass().getName());
18873
      }
18874
 
18875
      int lastComparison = 0;
18876
      getVendorItemMappings_args typedOther = (getVendorItemMappings_args)other;
18877
 
18878
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
18879
      if (lastComparison != 0) {
18880
        return lastComparison;
18881
      }
18882
      if (isSetItemId()) {
18883
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
18884
        if (lastComparison != 0) {
18885
          return lastComparison;
18886
        }
18887
      }
18888
      return 0;
18889
    }
18890
 
18891
    public _Fields fieldForId(int fieldId) {
18892
      return _Fields.findByThriftId(fieldId);
18893
    }
18894
 
18895
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18896
      org.apache.thrift.protocol.TField field;
18897
      iprot.readStructBegin();
18898
      while (true)
18899
      {
18900
        field = iprot.readFieldBegin();
18901
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18902
          break;
18903
        }
18904
        switch (field.id) {
18905
          case 1: // ITEM_ID
18906
            if (field.type == org.apache.thrift.protocol.TType.I64) {
18907
              this.itemId = iprot.readI64();
18908
              setItemIdIsSet(true);
18909
            } else { 
18910
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18911
            }
18912
            break;
18913
          default:
18914
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18915
        }
18916
        iprot.readFieldEnd();
18917
      }
18918
      iprot.readStructEnd();
18919
      validate();
18920
    }
18921
 
18922
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18923
      validate();
18924
 
18925
      oprot.writeStructBegin(STRUCT_DESC);
18926
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
18927
      oprot.writeI64(this.itemId);
18928
      oprot.writeFieldEnd();
18929
      oprot.writeFieldStop();
18930
      oprot.writeStructEnd();
18931
    }
18932
 
18933
    @Override
18934
    public String toString() {
18935
      StringBuilder sb = new StringBuilder("getVendorItemMappings_args(");
18936
      boolean first = true;
18937
 
18938
      sb.append("itemId:");
18939
      sb.append(this.itemId);
18940
      first = false;
18941
      sb.append(")");
18942
      return sb.toString();
18943
    }
18944
 
18945
    public void validate() throws org.apache.thrift.TException {
18946
      // check for required fields
18947
    }
18948
 
18949
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18950
      try {
18951
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18952
      } catch (org.apache.thrift.TException te) {
18953
        throw new java.io.IOException(te);
18954
      }
18955
    }
18956
 
18957
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18958
      try {
18959
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18960
      } catch (org.apache.thrift.TException te) {
18961
        throw new java.io.IOException(te);
18962
      }
18963
    }
18964
 
18965
  }
18966
 
18967
  public static class getVendorItemMappings_result implements org.apache.thrift.TBase<getVendorItemMappings_result, getVendorItemMappings_result._Fields>, java.io.Serializable, Cloneable   {
18968
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendorItemMappings_result");
18969
 
18970
    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);
18971
    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);
18972
 
18973
    private List<VendorItemMapping> success; // required
18974
    private InventoryServiceException cex; // required
18975
 
18976
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18977
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18978
      SUCCESS((short)0, "success"),
18979
      CEX((short)1, "cex");
18980
 
18981
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18982
 
18983
      static {
18984
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18985
          byName.put(field.getFieldName(), field);
18986
        }
18987
      }
18988
 
18989
      /**
18990
       * Find the _Fields constant that matches fieldId, or null if its not found.
18991
       */
18992
      public static _Fields findByThriftId(int fieldId) {
18993
        switch(fieldId) {
18994
          case 0: // SUCCESS
18995
            return SUCCESS;
18996
          case 1: // CEX
18997
            return CEX;
18998
          default:
18999
            return null;
19000
        }
19001
      }
19002
 
19003
      /**
19004
       * Find the _Fields constant that matches fieldId, throwing an exception
19005
       * if it is not found.
19006
       */
19007
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19008
        _Fields fields = findByThriftId(fieldId);
19009
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19010
        return fields;
19011
      }
19012
 
19013
      /**
19014
       * Find the _Fields constant that matches name, or null if its not found.
19015
       */
19016
      public static _Fields findByName(String name) {
19017
        return byName.get(name);
19018
      }
19019
 
19020
      private final short _thriftId;
19021
      private final String _fieldName;
19022
 
19023
      _Fields(short thriftId, String fieldName) {
19024
        _thriftId = thriftId;
19025
        _fieldName = fieldName;
19026
      }
19027
 
19028
      public short getThriftFieldId() {
19029
        return _thriftId;
19030
      }
19031
 
19032
      public String getFieldName() {
19033
        return _fieldName;
19034
      }
19035
    }
19036
 
19037
    // isset id assignments
19038
 
19039
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19040
    static {
19041
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19042
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19043
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
19044
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class))));
19045
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19046
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
19047
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19048
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendorItemMappings_result.class, metaDataMap);
19049
    }
19050
 
19051
    public getVendorItemMappings_result() {
19052
    }
19053
 
19054
    public getVendorItemMappings_result(
19055
      List<VendorItemMapping> success,
19056
      InventoryServiceException cex)
19057
    {
19058
      this();
19059
      this.success = success;
19060
      this.cex = cex;
19061
    }
19062
 
19063
    /**
19064
     * Performs a deep copy on <i>other</i>.
19065
     */
19066
    public getVendorItemMappings_result(getVendorItemMappings_result other) {
19067
      if (other.isSetSuccess()) {
19068
        List<VendorItemMapping> __this__success = new ArrayList<VendorItemMapping>();
19069
        for (VendorItemMapping other_element : other.success) {
19070
          __this__success.add(new VendorItemMapping(other_element));
19071
        }
19072
        this.success = __this__success;
19073
      }
19074
      if (other.isSetCex()) {
19075
        this.cex = new InventoryServiceException(other.cex);
19076
      }
19077
    }
19078
 
19079
    public getVendorItemMappings_result deepCopy() {
19080
      return new getVendorItemMappings_result(this);
19081
    }
19082
 
19083
    @Override
19084
    public void clear() {
19085
      this.success = null;
19086
      this.cex = null;
19087
    }
19088
 
19089
    public int getSuccessSize() {
19090
      return (this.success == null) ? 0 : this.success.size();
19091
    }
19092
 
19093
    public java.util.Iterator<VendorItemMapping> getSuccessIterator() {
19094
      return (this.success == null) ? null : this.success.iterator();
19095
    }
19096
 
19097
    public void addToSuccess(VendorItemMapping elem) {
19098
      if (this.success == null) {
19099
        this.success = new ArrayList<VendorItemMapping>();
19100
      }
19101
      this.success.add(elem);
19102
    }
19103
 
19104
    public List<VendorItemMapping> getSuccess() {
19105
      return this.success;
19106
    }
19107
 
19108
    public void setSuccess(List<VendorItemMapping> success) {
19109
      this.success = success;
19110
    }
19111
 
19112
    public void unsetSuccess() {
19113
      this.success = null;
19114
    }
19115
 
19116
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
19117
    public boolean isSetSuccess() {
19118
      return this.success != null;
19119
    }
19120
 
19121
    public void setSuccessIsSet(boolean value) {
19122
      if (!value) {
19123
        this.success = null;
19124
      }
19125
    }
19126
 
19127
    public InventoryServiceException getCex() {
19128
      return this.cex;
19129
    }
19130
 
19131
    public void setCex(InventoryServiceException cex) {
19132
      this.cex = cex;
19133
    }
19134
 
19135
    public void unsetCex() {
19136
      this.cex = null;
19137
    }
19138
 
19139
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
19140
    public boolean isSetCex() {
19141
      return this.cex != null;
19142
    }
19143
 
19144
    public void setCexIsSet(boolean value) {
19145
      if (!value) {
19146
        this.cex = null;
19147
      }
19148
    }
19149
 
19150
    public void setFieldValue(_Fields field, Object value) {
19151
      switch (field) {
19152
      case SUCCESS:
19153
        if (value == null) {
19154
          unsetSuccess();
19155
        } else {
19156
          setSuccess((List<VendorItemMapping>)value);
19157
        }
19158
        break;
19159
 
19160
      case CEX:
19161
        if (value == null) {
19162
          unsetCex();
19163
        } else {
19164
          setCex((InventoryServiceException)value);
19165
        }
19166
        break;
19167
 
19168
      }
19169
    }
19170
 
19171
    public Object getFieldValue(_Fields field) {
19172
      switch (field) {
19173
      case SUCCESS:
19174
        return getSuccess();
19175
 
19176
      case CEX:
19177
        return getCex();
19178
 
19179
      }
19180
      throw new IllegalStateException();
19181
    }
19182
 
19183
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19184
    public boolean isSet(_Fields field) {
19185
      if (field == null) {
19186
        throw new IllegalArgumentException();
19187
      }
19188
 
19189
      switch (field) {
19190
      case SUCCESS:
19191
        return isSetSuccess();
19192
      case CEX:
19193
        return isSetCex();
19194
      }
19195
      throw new IllegalStateException();
19196
    }
19197
 
19198
    @Override
19199
    public boolean equals(Object that) {
19200
      if (that == null)
19201
        return false;
19202
      if (that instanceof getVendorItemMappings_result)
19203
        return this.equals((getVendorItemMappings_result)that);
19204
      return false;
19205
    }
19206
 
19207
    public boolean equals(getVendorItemMappings_result that) {
19208
      if (that == null)
19209
        return false;
19210
 
19211
      boolean this_present_success = true && this.isSetSuccess();
19212
      boolean that_present_success = true && that.isSetSuccess();
19213
      if (this_present_success || that_present_success) {
19214
        if (!(this_present_success && that_present_success))
19215
          return false;
19216
        if (!this.success.equals(that.success))
19217
          return false;
19218
      }
19219
 
19220
      boolean this_present_cex = true && this.isSetCex();
19221
      boolean that_present_cex = true && that.isSetCex();
19222
      if (this_present_cex || that_present_cex) {
19223
        if (!(this_present_cex && that_present_cex))
19224
          return false;
19225
        if (!this.cex.equals(that.cex))
19226
          return false;
19227
      }
19228
 
19229
      return true;
19230
    }
19231
 
19232
    @Override
19233
    public int hashCode() {
19234
      return 0;
19235
    }
19236
 
19237
    public int compareTo(getVendorItemMappings_result other) {
19238
      if (!getClass().equals(other.getClass())) {
19239
        return getClass().getName().compareTo(other.getClass().getName());
19240
      }
19241
 
19242
      int lastComparison = 0;
19243
      getVendorItemMappings_result typedOther = (getVendorItemMappings_result)other;
19244
 
19245
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
19246
      if (lastComparison != 0) {
19247
        return lastComparison;
19248
      }
19249
      if (isSetSuccess()) {
19250
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
19251
        if (lastComparison != 0) {
19252
          return lastComparison;
19253
        }
19254
      }
19255
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
19256
      if (lastComparison != 0) {
19257
        return lastComparison;
19258
      }
19259
      if (isSetCex()) {
19260
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
19261
        if (lastComparison != 0) {
19262
          return lastComparison;
19263
        }
19264
      }
19265
      return 0;
19266
    }
19267
 
19268
    public _Fields fieldForId(int fieldId) {
19269
      return _Fields.findByThriftId(fieldId);
19270
    }
19271
 
19272
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19273
      org.apache.thrift.protocol.TField field;
19274
      iprot.readStructBegin();
19275
      while (true)
19276
      {
19277
        field = iprot.readFieldBegin();
19278
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19279
          break;
19280
        }
19281
        switch (field.id) {
19282
          case 0: // SUCCESS
19283
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
19284
              {
19285
                org.apache.thrift.protocol.TList _list40 = iprot.readListBegin();
19286
                this.success = new ArrayList<VendorItemMapping>(_list40.size);
19287
                for (int _i41 = 0; _i41 < _list40.size; ++_i41)
19288
                {
19289
                  VendorItemMapping _elem42; // required
19290
                  _elem42 = new VendorItemMapping();
19291
                  _elem42.read(iprot);
19292
                  this.success.add(_elem42);
19293
                }
19294
                iprot.readListEnd();
19295
              }
19296
            } else { 
19297
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19298
            }
19299
            break;
19300
          case 1: // CEX
19301
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
19302
              this.cex = new InventoryServiceException();
19303
              this.cex.read(iprot);
19304
            } else { 
19305
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19306
            }
19307
            break;
19308
          default:
19309
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19310
        }
19311
        iprot.readFieldEnd();
19312
      }
19313
      iprot.readStructEnd();
19314
      validate();
19315
    }
19316
 
19317
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19318
      oprot.writeStructBegin(STRUCT_DESC);
19319
 
19320
      if (this.isSetSuccess()) {
19321
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
19322
        {
19323
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
19324
          for (VendorItemMapping _iter43 : this.success)
19325
          {
19326
            _iter43.write(oprot);
19327
          }
19328
          oprot.writeListEnd();
19329
        }
19330
        oprot.writeFieldEnd();
19331
      } else if (this.isSetCex()) {
19332
        oprot.writeFieldBegin(CEX_FIELD_DESC);
19333
        this.cex.write(oprot);
19334
        oprot.writeFieldEnd();
19335
      }
19336
      oprot.writeFieldStop();
19337
      oprot.writeStructEnd();
19338
    }
19339
 
19340
    @Override
19341
    public String toString() {
19342
      StringBuilder sb = new StringBuilder("getVendorItemMappings_result(");
19343
      boolean first = true;
19344
 
19345
      sb.append("success:");
19346
      if (this.success == null) {
19347
        sb.append("null");
19348
      } else {
19349
        sb.append(this.success);
19350
      }
19351
      first = false;
19352
      if (!first) sb.append(", ");
19353
      sb.append("cex:");
19354
      if (this.cex == null) {
19355
        sb.append("null");
19356
      } else {
19357
        sb.append(this.cex);
19358
      }
19359
      first = false;
19360
      sb.append(")");
19361
      return sb.toString();
19362
    }
19363
 
19364
    public void validate() throws org.apache.thrift.TException {
19365
      // check for required fields
19366
    }
19367
 
19368
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19369
      try {
19370
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19371
      } catch (org.apache.thrift.TException te) {
19372
        throw new java.io.IOException(te);
19373
      }
19374
    }
19375
 
19376
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19377
      try {
19378
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19379
      } catch (org.apache.thrift.TException te) {
19380
        throw new java.io.IOException(te);
19381
      }
19382
    }
19383
 
19384
  }
19385
 
19386
  public static class getPendingOrdersInventory_args implements org.apache.thrift.TBase<getPendingOrdersInventory_args, getPendingOrdersInventory_args._Fields>, java.io.Serializable, Cloneable   {
19387
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPendingOrdersInventory_args");
19388
 
19389
    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);
19390
 
19391
    private long vendorid; // required
19392
 
19393
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19394
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19395
      VENDORID((short)1, "vendorid");
19396
 
19397
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19398
 
19399
      static {
19400
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19401
          byName.put(field.getFieldName(), field);
19402
        }
19403
      }
19404
 
19405
      /**
19406
       * Find the _Fields constant that matches fieldId, or null if its not found.
19407
       */
19408
      public static _Fields findByThriftId(int fieldId) {
19409
        switch(fieldId) {
19410
          case 1: // VENDORID
19411
            return VENDORID;
19412
          default:
19413
            return null;
19414
        }
19415
      }
19416
 
19417
      /**
19418
       * Find the _Fields constant that matches fieldId, throwing an exception
19419
       * if it is not found.
19420
       */
19421
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19422
        _Fields fields = findByThriftId(fieldId);
19423
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19424
        return fields;
19425
      }
19426
 
19427
      /**
19428
       * Find the _Fields constant that matches name, or null if its not found.
19429
       */
19430
      public static _Fields findByName(String name) {
19431
        return byName.get(name);
19432
      }
19433
 
19434
      private final short _thriftId;
19435
      private final String _fieldName;
19436
 
19437
      _Fields(short thriftId, String fieldName) {
19438
        _thriftId = thriftId;
19439
        _fieldName = fieldName;
19440
      }
19441
 
19442
      public short getThriftFieldId() {
19443
        return _thriftId;
19444
      }
19445
 
19446
      public String getFieldName() {
19447
        return _fieldName;
19448
      }
19449
    }
19450
 
19451
    // isset id assignments
19452
    private static final int __VENDORID_ISSET_ID = 0;
19453
    private BitSet __isset_bit_vector = new BitSet(1);
19454
 
19455
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19456
    static {
19457
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19458
      tmpMap.put(_Fields.VENDORID, new org.apache.thrift.meta_data.FieldMetaData("vendorid", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19459
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
19460
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19461
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPendingOrdersInventory_args.class, metaDataMap);
19462
    }
19463
 
19464
    public getPendingOrdersInventory_args() {
19465
    }
19466
 
19467
    public getPendingOrdersInventory_args(
19468
      long vendorid)
19469
    {
19470
      this();
19471
      this.vendorid = vendorid;
19472
      setVendoridIsSet(true);
19473
    }
19474
 
19475
    /**
19476
     * Performs a deep copy on <i>other</i>.
19477
     */
19478
    public getPendingOrdersInventory_args(getPendingOrdersInventory_args other) {
19479
      __isset_bit_vector.clear();
19480
      __isset_bit_vector.or(other.__isset_bit_vector);
19481
      this.vendorid = other.vendorid;
19482
    }
19483
 
19484
    public getPendingOrdersInventory_args deepCopy() {
19485
      return new getPendingOrdersInventory_args(this);
19486
    }
19487
 
19488
    @Override
19489
    public void clear() {
19490
      setVendoridIsSet(false);
19491
      this.vendorid = 0;
19492
    }
19493
 
19494
    public long getVendorid() {
19495
      return this.vendorid;
19496
    }
19497
 
19498
    public void setVendorid(long vendorid) {
19499
      this.vendorid = vendorid;
19500
      setVendoridIsSet(true);
19501
    }
19502
 
19503
    public void unsetVendorid() {
19504
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
19505
    }
19506
 
19507
    /** Returns true if field vendorid is set (has been assigned a value) and false otherwise */
19508
    public boolean isSetVendorid() {
19509
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
19510
    }
19511
 
19512
    public void setVendoridIsSet(boolean value) {
19513
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
19514
    }
19515
 
19516
    public void setFieldValue(_Fields field, Object value) {
19517
      switch (field) {
19518
      case VENDORID:
19519
        if (value == null) {
19520
          unsetVendorid();
19521
        } else {
19522
          setVendorid((Long)value);
19523
        }
19524
        break;
19525
 
19526
      }
19527
    }
19528
 
19529
    public Object getFieldValue(_Fields field) {
19530
      switch (field) {
19531
      case VENDORID:
19532
        return Long.valueOf(getVendorid());
19533
 
19534
      }
19535
      throw new IllegalStateException();
19536
    }
19537
 
19538
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19539
    public boolean isSet(_Fields field) {
19540
      if (field == null) {
19541
        throw new IllegalArgumentException();
19542
      }
19543
 
19544
      switch (field) {
19545
      case VENDORID:
19546
        return isSetVendorid();
19547
      }
19548
      throw new IllegalStateException();
19549
    }
19550
 
19551
    @Override
19552
    public boolean equals(Object that) {
19553
      if (that == null)
19554
        return false;
19555
      if (that instanceof getPendingOrdersInventory_args)
19556
        return this.equals((getPendingOrdersInventory_args)that);
19557
      return false;
19558
    }
19559
 
19560
    public boolean equals(getPendingOrdersInventory_args that) {
19561
      if (that == null)
19562
        return false;
19563
 
19564
      boolean this_present_vendorid = true;
19565
      boolean that_present_vendorid = true;
19566
      if (this_present_vendorid || that_present_vendorid) {
19567
        if (!(this_present_vendorid && that_present_vendorid))
19568
          return false;
19569
        if (this.vendorid != that.vendorid)
19570
          return false;
19571
      }
19572
 
19573
      return true;
19574
    }
19575
 
19576
    @Override
19577
    public int hashCode() {
19578
      return 0;
19579
    }
19580
 
19581
    public int compareTo(getPendingOrdersInventory_args other) {
19582
      if (!getClass().equals(other.getClass())) {
19583
        return getClass().getName().compareTo(other.getClass().getName());
19584
      }
19585
 
19586
      int lastComparison = 0;
19587
      getPendingOrdersInventory_args typedOther = (getPendingOrdersInventory_args)other;
19588
 
19589
      lastComparison = Boolean.valueOf(isSetVendorid()).compareTo(typedOther.isSetVendorid());
19590
      if (lastComparison != 0) {
19591
        return lastComparison;
19592
      }
19593
      if (isSetVendorid()) {
19594
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorid, typedOther.vendorid);
19595
        if (lastComparison != 0) {
19596
          return lastComparison;
19597
        }
19598
      }
19599
      return 0;
19600
    }
19601
 
19602
    public _Fields fieldForId(int fieldId) {
19603
      return _Fields.findByThriftId(fieldId);
19604
    }
19605
 
19606
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19607
      org.apache.thrift.protocol.TField field;
19608
      iprot.readStructBegin();
19609
      while (true)
19610
      {
19611
        field = iprot.readFieldBegin();
19612
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19613
          break;
19614
        }
19615
        switch (field.id) {
19616
          case 1: // VENDORID
19617
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19618
              this.vendorid = iprot.readI64();
19619
              setVendoridIsSet(true);
19620
            } else { 
19621
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19622
            }
19623
            break;
19624
          default:
19625
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19626
        }
19627
        iprot.readFieldEnd();
19628
      }
19629
      iprot.readStructEnd();
19630
      validate();
19631
    }
19632
 
19633
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19634
      validate();
19635
 
19636
      oprot.writeStructBegin(STRUCT_DESC);
19637
      oprot.writeFieldBegin(VENDORID_FIELD_DESC);
19638
      oprot.writeI64(this.vendorid);
19639
      oprot.writeFieldEnd();
19640
      oprot.writeFieldStop();
19641
      oprot.writeStructEnd();
19642
    }
19643
 
19644
    @Override
19645
    public String toString() {
19646
      StringBuilder sb = new StringBuilder("getPendingOrdersInventory_args(");
19647
      boolean first = true;
19648
 
19649
      sb.append("vendorid:");
19650
      sb.append(this.vendorid);
19651
      first = false;
19652
      sb.append(")");
19653
      return sb.toString();
19654
    }
19655
 
19656
    public void validate() throws org.apache.thrift.TException {
19657
      // check for required fields
19658
    }
19659
 
19660
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19661
      try {
19662
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19663
      } catch (org.apache.thrift.TException te) {
19664
        throw new java.io.IOException(te);
19665
      }
19666
    }
19667
 
19668
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19669
      try {
19670
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
19671
        __isset_bit_vector = new BitSet(1);
19672
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19673
      } catch (org.apache.thrift.TException te) {
19674
        throw new java.io.IOException(te);
19675
      }
19676
    }
19677
 
19678
  }
19679
 
19680
  public static class getPendingOrdersInventory_result implements org.apache.thrift.TBase<getPendingOrdersInventory_result, getPendingOrdersInventory_result._Fields>, java.io.Serializable, Cloneable   {
19681
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPendingOrdersInventory_result");
19682
 
19683
    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);
19684
 
19685
    private List<AvailableAndReservedStock> success; // required
19686
 
19687
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19688
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19689
      SUCCESS((short)0, "success");
19690
 
19691
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19692
 
19693
      static {
19694
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19695
          byName.put(field.getFieldName(), field);
19696
        }
19697
      }
19698
 
19699
      /**
19700
       * Find the _Fields constant that matches fieldId, or null if its not found.
19701
       */
19702
      public static _Fields findByThriftId(int fieldId) {
19703
        switch(fieldId) {
19704
          case 0: // SUCCESS
19705
            return SUCCESS;
19706
          default:
19707
            return null;
19708
        }
19709
      }
19710
 
19711
      /**
19712
       * Find the _Fields constant that matches fieldId, throwing an exception
19713
       * if it is not found.
19714
       */
19715
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19716
        _Fields fields = findByThriftId(fieldId);
19717
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19718
        return fields;
19719
      }
19720
 
19721
      /**
19722
       * Find the _Fields constant that matches name, or null if its not found.
19723
       */
19724
      public static _Fields findByName(String name) {
19725
        return byName.get(name);
19726
      }
19727
 
19728
      private final short _thriftId;
19729
      private final String _fieldName;
19730
 
19731
      _Fields(short thriftId, String fieldName) {
19732
        _thriftId = thriftId;
19733
        _fieldName = fieldName;
19734
      }
19735
 
19736
      public short getThriftFieldId() {
19737
        return _thriftId;
19738
      }
19739
 
19740
      public String getFieldName() {
19741
        return _fieldName;
19742
      }
19743
    }
19744
 
19745
    // isset id assignments
19746
 
19747
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19748
    static {
19749
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19750
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19751
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
19752
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, AvailableAndReservedStock.class))));
19753
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19754
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPendingOrdersInventory_result.class, metaDataMap);
19755
    }
19756
 
19757
    public getPendingOrdersInventory_result() {
19758
    }
19759
 
19760
    public getPendingOrdersInventory_result(
19761
      List<AvailableAndReservedStock> success)
19762
    {
19763
      this();
19764
      this.success = success;
19765
    }
19766
 
19767
    /**
19768
     * Performs a deep copy on <i>other</i>.
19769
     */
19770
    public getPendingOrdersInventory_result(getPendingOrdersInventory_result other) {
19771
      if (other.isSetSuccess()) {
19772
        List<AvailableAndReservedStock> __this__success = new ArrayList<AvailableAndReservedStock>();
19773
        for (AvailableAndReservedStock other_element : other.success) {
19774
          __this__success.add(new AvailableAndReservedStock(other_element));
19775
        }
19776
        this.success = __this__success;
19777
      }
19778
    }
19779
 
19780
    public getPendingOrdersInventory_result deepCopy() {
19781
      return new getPendingOrdersInventory_result(this);
19782
    }
19783
 
19784
    @Override
19785
    public void clear() {
19786
      this.success = null;
19787
    }
19788
 
19789
    public int getSuccessSize() {
19790
      return (this.success == null) ? 0 : this.success.size();
19791
    }
19792
 
19793
    public java.util.Iterator<AvailableAndReservedStock> getSuccessIterator() {
19794
      return (this.success == null) ? null : this.success.iterator();
19795
    }
19796
 
19797
    public void addToSuccess(AvailableAndReservedStock elem) {
19798
      if (this.success == null) {
19799
        this.success = new ArrayList<AvailableAndReservedStock>();
19800
      }
19801
      this.success.add(elem);
19802
    }
19803
 
19804
    public List<AvailableAndReservedStock> getSuccess() {
19805
      return this.success;
19806
    }
19807
 
19808
    public void setSuccess(List<AvailableAndReservedStock> success) {
19809
      this.success = success;
19810
    }
19811
 
19812
    public void unsetSuccess() {
19813
      this.success = null;
19814
    }
19815
 
19816
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
19817
    public boolean isSetSuccess() {
19818
      return this.success != null;
19819
    }
19820
 
19821
    public void setSuccessIsSet(boolean value) {
19822
      if (!value) {
19823
        this.success = null;
19824
      }
19825
    }
19826
 
19827
    public void setFieldValue(_Fields field, Object value) {
19828
      switch (field) {
19829
      case SUCCESS:
19830
        if (value == null) {
19831
          unsetSuccess();
19832
        } else {
19833
          setSuccess((List<AvailableAndReservedStock>)value);
19834
        }
19835
        break;
19836
 
19837
      }
19838
    }
19839
 
19840
    public Object getFieldValue(_Fields field) {
19841
      switch (field) {
19842
      case SUCCESS:
19843
        return getSuccess();
19844
 
19845
      }
19846
      throw new IllegalStateException();
19847
    }
19848
 
19849
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19850
    public boolean isSet(_Fields field) {
19851
      if (field == null) {
19852
        throw new IllegalArgumentException();
19853
      }
19854
 
19855
      switch (field) {
19856
      case SUCCESS:
19857
        return isSetSuccess();
19858
      }
19859
      throw new IllegalStateException();
19860
    }
19861
 
19862
    @Override
19863
    public boolean equals(Object that) {
19864
      if (that == null)
19865
        return false;
19866
      if (that instanceof getPendingOrdersInventory_result)
19867
        return this.equals((getPendingOrdersInventory_result)that);
19868
      return false;
19869
    }
19870
 
19871
    public boolean equals(getPendingOrdersInventory_result that) {
19872
      if (that == null)
19873
        return false;
19874
 
19875
      boolean this_present_success = true && this.isSetSuccess();
19876
      boolean that_present_success = true && that.isSetSuccess();
19877
      if (this_present_success || that_present_success) {
19878
        if (!(this_present_success && that_present_success))
19879
          return false;
19880
        if (!this.success.equals(that.success))
19881
          return false;
19882
      }
19883
 
19884
      return true;
19885
    }
19886
 
19887
    @Override
19888
    public int hashCode() {
19889
      return 0;
19890
    }
19891
 
19892
    public int compareTo(getPendingOrdersInventory_result other) {
19893
      if (!getClass().equals(other.getClass())) {
19894
        return getClass().getName().compareTo(other.getClass().getName());
19895
      }
19896
 
19897
      int lastComparison = 0;
19898
      getPendingOrdersInventory_result typedOther = (getPendingOrdersInventory_result)other;
19899
 
19900
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
19901
      if (lastComparison != 0) {
19902
        return lastComparison;
19903
      }
19904
      if (isSetSuccess()) {
19905
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
19906
        if (lastComparison != 0) {
19907
          return lastComparison;
19908
        }
19909
      }
19910
      return 0;
19911
    }
19912
 
19913
    public _Fields fieldForId(int fieldId) {
19914
      return _Fields.findByThriftId(fieldId);
19915
    }
19916
 
19917
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19918
      org.apache.thrift.protocol.TField field;
19919
      iprot.readStructBegin();
19920
      while (true)
19921
      {
19922
        field = iprot.readFieldBegin();
19923
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19924
          break;
19925
        }
19926
        switch (field.id) {
19927
          case 0: // SUCCESS
19928
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
19929
              {
19930
                org.apache.thrift.protocol.TList _list44 = iprot.readListBegin();
19931
                this.success = new ArrayList<AvailableAndReservedStock>(_list44.size);
19932
                for (int _i45 = 0; _i45 < _list44.size; ++_i45)
19933
                {
19934
                  AvailableAndReservedStock _elem46; // required
19935
                  _elem46 = new AvailableAndReservedStock();
19936
                  _elem46.read(iprot);
19937
                  this.success.add(_elem46);
19938
                }
19939
                iprot.readListEnd();
19940
              }
19941
            } else { 
19942
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19943
            }
19944
            break;
19945
          default:
19946
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19947
        }
19948
        iprot.readFieldEnd();
19949
      }
19950
      iprot.readStructEnd();
19951
      validate();
19952
    }
19953
 
19954
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19955
      oprot.writeStructBegin(STRUCT_DESC);
19956
 
19957
      if (this.isSetSuccess()) {
19958
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
19959
        {
19960
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
19961
          for (AvailableAndReservedStock _iter47 : this.success)
19962
          {
19963
            _iter47.write(oprot);
19964
          }
19965
          oprot.writeListEnd();
19966
        }
19967
        oprot.writeFieldEnd();
19968
      }
19969
      oprot.writeFieldStop();
19970
      oprot.writeStructEnd();
19971
    }
19972
 
19973
    @Override
19974
    public String toString() {
19975
      StringBuilder sb = new StringBuilder("getPendingOrdersInventory_result(");
19976
      boolean first = true;
19977
 
19978
      sb.append("success:");
19979
      if (this.success == null) {
19980
        sb.append("null");
19981
      } else {
19982
        sb.append(this.success);
19983
      }
19984
      first = false;
19985
      sb.append(")");
19986
      return sb.toString();
19987
    }
19988
 
19989
    public void validate() throws org.apache.thrift.TException {
19990
      // check for required fields
19991
    }
19992
 
19993
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19994
      try {
19995
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19996
      } catch (org.apache.thrift.TException te) {
19997
        throw new java.io.IOException(te);
19998
      }
19999
    }
20000
 
20001
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20002
      try {
20003
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20004
      } catch (org.apache.thrift.TException te) {
20005
        throw new java.io.IOException(te);
20006
      }
20007
    }
20008
 
20009
  }
20010
 
20011
  public static class getWarehouses_args implements org.apache.thrift.TBase<getWarehouses_args, getWarehouses_args._Fields>, java.io.Serializable, Cloneable   {
20012
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouses_args");
20013
 
20014
    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);
20015
    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);
20016
    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);
20017
    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);
20018
    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);
20019
 
20020
    private WarehouseType warehouseType; // required
20021
    private InventoryType inventoryType; // required
20022
    private long vendorId; // required
20023
    private long billingWarehouseId; // required
20024
    private long shippingWarehouseId; // required
20025
 
20026
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20027
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20028
      /**
20029
       * 
20030
       * @see WarehouseType
20031
       */
20032
      WAREHOUSE_TYPE((short)1, "warehouseType"),
20033
      /**
20034
       * 
20035
       * @see InventoryType
20036
       */
20037
      INVENTORY_TYPE((short)2, "inventoryType"),
20038
      VENDOR_ID((short)3, "vendorId"),
20039
      BILLING_WAREHOUSE_ID((short)4, "billingWarehouseId"),
20040
      SHIPPING_WAREHOUSE_ID((short)5, "shippingWarehouseId");
20041
 
20042
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20043
 
20044
      static {
20045
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20046
          byName.put(field.getFieldName(), field);
20047
        }
20048
      }
20049
 
20050
      /**
20051
       * Find the _Fields constant that matches fieldId, or null if its not found.
20052
       */
20053
      public static _Fields findByThriftId(int fieldId) {
20054
        switch(fieldId) {
20055
          case 1: // WAREHOUSE_TYPE
20056
            return WAREHOUSE_TYPE;
20057
          case 2: // INVENTORY_TYPE
20058
            return INVENTORY_TYPE;
20059
          case 3: // VENDOR_ID
20060
            return VENDOR_ID;
20061
          case 4: // BILLING_WAREHOUSE_ID
20062
            return BILLING_WAREHOUSE_ID;
20063
          case 5: // SHIPPING_WAREHOUSE_ID
20064
            return SHIPPING_WAREHOUSE_ID;
20065
          default:
20066
            return null;
20067
        }
20068
      }
20069
 
20070
      /**
20071
       * Find the _Fields constant that matches fieldId, throwing an exception
20072
       * if it is not found.
20073
       */
20074
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20075
        _Fields fields = findByThriftId(fieldId);
20076
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20077
        return fields;
20078
      }
20079
 
20080
      /**
20081
       * Find the _Fields constant that matches name, or null if its not found.
20082
       */
20083
      public static _Fields findByName(String name) {
20084
        return byName.get(name);
20085
      }
20086
 
20087
      private final short _thriftId;
20088
      private final String _fieldName;
20089
 
20090
      _Fields(short thriftId, String fieldName) {
20091
        _thriftId = thriftId;
20092
        _fieldName = fieldName;
20093
      }
20094
 
20095
      public short getThriftFieldId() {
20096
        return _thriftId;
20097
      }
20098
 
20099
      public String getFieldName() {
20100
        return _fieldName;
20101
      }
20102
    }
20103
 
20104
    // isset id assignments
20105
    private static final int __VENDORID_ISSET_ID = 0;
20106
    private static final int __BILLINGWAREHOUSEID_ISSET_ID = 1;
20107
    private static final int __SHIPPINGWAREHOUSEID_ISSET_ID = 2;
20108
    private BitSet __isset_bit_vector = new BitSet(3);
20109
 
20110
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20111
    static {
20112
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20113
      tmpMap.put(_Fields.WAREHOUSE_TYPE, new org.apache.thrift.meta_data.FieldMetaData("warehouseType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20114
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, WarehouseType.class)));
20115
      tmpMap.put(_Fields.INVENTORY_TYPE, new org.apache.thrift.meta_data.FieldMetaData("inventoryType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20116
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, InventoryType.class)));
20117
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20118
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20119
      tmpMap.put(_Fields.BILLING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("billingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20120
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20121
      tmpMap.put(_Fields.SHIPPING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("shippingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20122
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20123
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20124
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouses_args.class, metaDataMap);
20125
    }
20126
 
20127
    public getWarehouses_args() {
20128
    }
20129
 
20130
    public getWarehouses_args(
20131
      WarehouseType warehouseType,
20132
      InventoryType inventoryType,
20133
      long vendorId,
20134
      long billingWarehouseId,
20135
      long shippingWarehouseId)
20136
    {
20137
      this();
20138
      this.warehouseType = warehouseType;
20139
      this.inventoryType = inventoryType;
20140
      this.vendorId = vendorId;
20141
      setVendorIdIsSet(true);
20142
      this.billingWarehouseId = billingWarehouseId;
20143
      setBillingWarehouseIdIsSet(true);
20144
      this.shippingWarehouseId = shippingWarehouseId;
20145
      setShippingWarehouseIdIsSet(true);
20146
    }
20147
 
20148
    /**
20149
     * Performs a deep copy on <i>other</i>.
20150
     */
20151
    public getWarehouses_args(getWarehouses_args other) {
20152
      __isset_bit_vector.clear();
20153
      __isset_bit_vector.or(other.__isset_bit_vector);
20154
      if (other.isSetWarehouseType()) {
20155
        this.warehouseType = other.warehouseType;
20156
      }
20157
      if (other.isSetInventoryType()) {
20158
        this.inventoryType = other.inventoryType;
20159
      }
20160
      this.vendorId = other.vendorId;
20161
      this.billingWarehouseId = other.billingWarehouseId;
20162
      this.shippingWarehouseId = other.shippingWarehouseId;
20163
    }
20164
 
20165
    public getWarehouses_args deepCopy() {
20166
      return new getWarehouses_args(this);
20167
    }
20168
 
20169
    @Override
20170
    public void clear() {
20171
      this.warehouseType = null;
20172
      this.inventoryType = null;
20173
      setVendorIdIsSet(false);
20174
      this.vendorId = 0;
20175
      setBillingWarehouseIdIsSet(false);
20176
      this.billingWarehouseId = 0;
20177
      setShippingWarehouseIdIsSet(false);
20178
      this.shippingWarehouseId = 0;
20179
    }
20180
 
20181
    /**
20182
     * 
20183
     * @see WarehouseType
20184
     */
20185
    public WarehouseType getWarehouseType() {
20186
      return this.warehouseType;
20187
    }
20188
 
20189
    /**
20190
     * 
20191
     * @see WarehouseType
20192
     */
20193
    public void setWarehouseType(WarehouseType warehouseType) {
20194
      this.warehouseType = warehouseType;
20195
    }
20196
 
20197
    public void unsetWarehouseType() {
20198
      this.warehouseType = null;
20199
    }
20200
 
20201
    /** Returns true if field warehouseType is set (has been assigned a value) and false otherwise */
20202
    public boolean isSetWarehouseType() {
20203
      return this.warehouseType != null;
20204
    }
20205
 
20206
    public void setWarehouseTypeIsSet(boolean value) {
20207
      if (!value) {
20208
        this.warehouseType = null;
20209
      }
20210
    }
20211
 
20212
    /**
20213
     * 
20214
     * @see InventoryType
20215
     */
20216
    public InventoryType getInventoryType() {
20217
      return this.inventoryType;
20218
    }
20219
 
20220
    /**
20221
     * 
20222
     * @see InventoryType
20223
     */
20224
    public void setInventoryType(InventoryType inventoryType) {
20225
      this.inventoryType = inventoryType;
20226
    }
20227
 
20228
    public void unsetInventoryType() {
20229
      this.inventoryType = null;
20230
    }
20231
 
20232
    /** Returns true if field inventoryType is set (has been assigned a value) and false otherwise */
20233
    public boolean isSetInventoryType() {
20234
      return this.inventoryType != null;
20235
    }
20236
 
20237
    public void setInventoryTypeIsSet(boolean value) {
20238
      if (!value) {
20239
        this.inventoryType = null;
20240
      }
20241
    }
20242
 
20243
    public long getVendorId() {
20244
      return this.vendorId;
20245
    }
20246
 
20247
    public void setVendorId(long vendorId) {
20248
      this.vendorId = vendorId;
20249
      setVendorIdIsSet(true);
20250
    }
20251
 
20252
    public void unsetVendorId() {
20253
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
20254
    }
20255
 
20256
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
20257
    public boolean isSetVendorId() {
20258
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
20259
    }
20260
 
20261
    public void setVendorIdIsSet(boolean value) {
20262
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
20263
    }
20264
 
20265
    public long getBillingWarehouseId() {
20266
      return this.billingWarehouseId;
20267
    }
20268
 
20269
    public void setBillingWarehouseId(long billingWarehouseId) {
20270
      this.billingWarehouseId = billingWarehouseId;
20271
      setBillingWarehouseIdIsSet(true);
20272
    }
20273
 
20274
    public void unsetBillingWarehouseId() {
20275
      __isset_bit_vector.clear(__BILLINGWAREHOUSEID_ISSET_ID);
20276
    }
20277
 
20278
    /** Returns true if field billingWarehouseId is set (has been assigned a value) and false otherwise */
20279
    public boolean isSetBillingWarehouseId() {
20280
      return __isset_bit_vector.get(__BILLINGWAREHOUSEID_ISSET_ID);
20281
    }
20282
 
20283
    public void setBillingWarehouseIdIsSet(boolean value) {
20284
      __isset_bit_vector.set(__BILLINGWAREHOUSEID_ISSET_ID, value);
20285
    }
20286
 
20287
    public long getShippingWarehouseId() {
20288
      return this.shippingWarehouseId;
20289
    }
20290
 
20291
    public void setShippingWarehouseId(long shippingWarehouseId) {
20292
      this.shippingWarehouseId = shippingWarehouseId;
20293
      setShippingWarehouseIdIsSet(true);
20294
    }
20295
 
20296
    public void unsetShippingWarehouseId() {
20297
      __isset_bit_vector.clear(__SHIPPINGWAREHOUSEID_ISSET_ID);
20298
    }
20299
 
20300
    /** Returns true if field shippingWarehouseId is set (has been assigned a value) and false otherwise */
20301
    public boolean isSetShippingWarehouseId() {
20302
      return __isset_bit_vector.get(__SHIPPINGWAREHOUSEID_ISSET_ID);
20303
    }
20304
 
20305
    public void setShippingWarehouseIdIsSet(boolean value) {
20306
      __isset_bit_vector.set(__SHIPPINGWAREHOUSEID_ISSET_ID, value);
20307
    }
20308
 
20309
    public void setFieldValue(_Fields field, Object value) {
20310
      switch (field) {
20311
      case WAREHOUSE_TYPE:
20312
        if (value == null) {
20313
          unsetWarehouseType();
20314
        } else {
20315
          setWarehouseType((WarehouseType)value);
20316
        }
20317
        break;
20318
 
20319
      case INVENTORY_TYPE:
20320
        if (value == null) {
20321
          unsetInventoryType();
20322
        } else {
20323
          setInventoryType((InventoryType)value);
20324
        }
20325
        break;
20326
 
20327
      case VENDOR_ID:
20328
        if (value == null) {
20329
          unsetVendorId();
20330
        } else {
20331
          setVendorId((Long)value);
20332
        }
20333
        break;
20334
 
20335
      case BILLING_WAREHOUSE_ID:
20336
        if (value == null) {
20337
          unsetBillingWarehouseId();
20338
        } else {
20339
          setBillingWarehouseId((Long)value);
20340
        }
20341
        break;
20342
 
20343
      case SHIPPING_WAREHOUSE_ID:
20344
        if (value == null) {
20345
          unsetShippingWarehouseId();
20346
        } else {
20347
          setShippingWarehouseId((Long)value);
20348
        }
20349
        break;
20350
 
20351
      }
20352
    }
20353
 
20354
    public Object getFieldValue(_Fields field) {
20355
      switch (field) {
20356
      case WAREHOUSE_TYPE:
20357
        return getWarehouseType();
20358
 
20359
      case INVENTORY_TYPE:
20360
        return getInventoryType();
20361
 
20362
      case VENDOR_ID:
20363
        return Long.valueOf(getVendorId());
20364
 
20365
      case BILLING_WAREHOUSE_ID:
20366
        return Long.valueOf(getBillingWarehouseId());
20367
 
20368
      case SHIPPING_WAREHOUSE_ID:
20369
        return Long.valueOf(getShippingWarehouseId());
20370
 
20371
      }
20372
      throw new IllegalStateException();
20373
    }
20374
 
20375
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20376
    public boolean isSet(_Fields field) {
20377
      if (field == null) {
20378
        throw new IllegalArgumentException();
20379
      }
20380
 
20381
      switch (field) {
20382
      case WAREHOUSE_TYPE:
20383
        return isSetWarehouseType();
20384
      case INVENTORY_TYPE:
20385
        return isSetInventoryType();
20386
      case VENDOR_ID:
20387
        return isSetVendorId();
20388
      case BILLING_WAREHOUSE_ID:
20389
        return isSetBillingWarehouseId();
20390
      case SHIPPING_WAREHOUSE_ID:
20391
        return isSetShippingWarehouseId();
20392
      }
20393
      throw new IllegalStateException();
20394
    }
20395
 
20396
    @Override
20397
    public boolean equals(Object that) {
20398
      if (that == null)
20399
        return false;
20400
      if (that instanceof getWarehouses_args)
20401
        return this.equals((getWarehouses_args)that);
20402
      return false;
20403
    }
20404
 
20405
    public boolean equals(getWarehouses_args that) {
20406
      if (that == null)
20407
        return false;
20408
 
20409
      boolean this_present_warehouseType = true && this.isSetWarehouseType();
20410
      boolean that_present_warehouseType = true && that.isSetWarehouseType();
20411
      if (this_present_warehouseType || that_present_warehouseType) {
20412
        if (!(this_present_warehouseType && that_present_warehouseType))
20413
          return false;
20414
        if (!this.warehouseType.equals(that.warehouseType))
20415
          return false;
20416
      }
20417
 
20418
      boolean this_present_inventoryType = true && this.isSetInventoryType();
20419
      boolean that_present_inventoryType = true && that.isSetInventoryType();
20420
      if (this_present_inventoryType || that_present_inventoryType) {
20421
        if (!(this_present_inventoryType && that_present_inventoryType))
20422
          return false;
20423
        if (!this.inventoryType.equals(that.inventoryType))
20424
          return false;
20425
      }
20426
 
20427
      boolean this_present_vendorId = true;
20428
      boolean that_present_vendorId = true;
20429
      if (this_present_vendorId || that_present_vendorId) {
20430
        if (!(this_present_vendorId && that_present_vendorId))
20431
          return false;
20432
        if (this.vendorId != that.vendorId)
20433
          return false;
20434
      }
20435
 
20436
      boolean this_present_billingWarehouseId = true;
20437
      boolean that_present_billingWarehouseId = true;
20438
      if (this_present_billingWarehouseId || that_present_billingWarehouseId) {
20439
        if (!(this_present_billingWarehouseId && that_present_billingWarehouseId))
20440
          return false;
20441
        if (this.billingWarehouseId != that.billingWarehouseId)
20442
          return false;
20443
      }
20444
 
20445
      boolean this_present_shippingWarehouseId = true;
20446
      boolean that_present_shippingWarehouseId = true;
20447
      if (this_present_shippingWarehouseId || that_present_shippingWarehouseId) {
20448
        if (!(this_present_shippingWarehouseId && that_present_shippingWarehouseId))
20449
          return false;
20450
        if (this.shippingWarehouseId != that.shippingWarehouseId)
20451
          return false;
20452
      }
20453
 
20454
      return true;
20455
    }
20456
 
20457
    @Override
20458
    public int hashCode() {
20459
      return 0;
20460
    }
20461
 
20462
    public int compareTo(getWarehouses_args other) {
20463
      if (!getClass().equals(other.getClass())) {
20464
        return getClass().getName().compareTo(other.getClass().getName());
20465
      }
20466
 
20467
      int lastComparison = 0;
20468
      getWarehouses_args typedOther = (getWarehouses_args)other;
20469
 
20470
      lastComparison = Boolean.valueOf(isSetWarehouseType()).compareTo(typedOther.isSetWarehouseType());
20471
      if (lastComparison != 0) {
20472
        return lastComparison;
20473
      }
20474
      if (isSetWarehouseType()) {
20475
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseType, typedOther.warehouseType);
20476
        if (lastComparison != 0) {
20477
          return lastComparison;
20478
        }
20479
      }
20480
      lastComparison = Boolean.valueOf(isSetInventoryType()).compareTo(typedOther.isSetInventoryType());
20481
      if (lastComparison != 0) {
20482
        return lastComparison;
20483
      }
20484
      if (isSetInventoryType()) {
20485
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.inventoryType, typedOther.inventoryType);
20486
        if (lastComparison != 0) {
20487
          return lastComparison;
20488
        }
20489
      }
20490
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
20491
      if (lastComparison != 0) {
20492
        return lastComparison;
20493
      }
20494
      if (isSetVendorId()) {
20495
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
20496
        if (lastComparison != 0) {
20497
          return lastComparison;
20498
        }
20499
      }
20500
      lastComparison = Boolean.valueOf(isSetBillingWarehouseId()).compareTo(typedOther.isSetBillingWarehouseId());
20501
      if (lastComparison != 0) {
20502
        return lastComparison;
20503
      }
20504
      if (isSetBillingWarehouseId()) {
20505
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.billingWarehouseId, typedOther.billingWarehouseId);
20506
        if (lastComparison != 0) {
20507
          return lastComparison;
20508
        }
20509
      }
20510
      lastComparison = Boolean.valueOf(isSetShippingWarehouseId()).compareTo(typedOther.isSetShippingWarehouseId());
20511
      if (lastComparison != 0) {
20512
        return lastComparison;
20513
      }
20514
      if (isSetShippingWarehouseId()) {
20515
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.shippingWarehouseId, typedOther.shippingWarehouseId);
20516
        if (lastComparison != 0) {
20517
          return lastComparison;
20518
        }
20519
      }
20520
      return 0;
20521
    }
20522
 
20523
    public _Fields fieldForId(int fieldId) {
20524
      return _Fields.findByThriftId(fieldId);
20525
    }
20526
 
20527
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20528
      org.apache.thrift.protocol.TField field;
20529
      iprot.readStructBegin();
20530
      while (true)
20531
      {
20532
        field = iprot.readFieldBegin();
20533
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20534
          break;
20535
        }
20536
        switch (field.id) {
20537
          case 1: // WAREHOUSE_TYPE
20538
            if (field.type == org.apache.thrift.protocol.TType.I32) {
20539
              this.warehouseType = WarehouseType.findByValue(iprot.readI32());
20540
            } else { 
20541
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20542
            }
20543
            break;
20544
          case 2: // INVENTORY_TYPE
20545
            if (field.type == org.apache.thrift.protocol.TType.I32) {
20546
              this.inventoryType = InventoryType.findByValue(iprot.readI32());
20547
            } else { 
20548
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20549
            }
20550
            break;
20551
          case 3: // VENDOR_ID
20552
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20553
              this.vendorId = iprot.readI64();
20554
              setVendorIdIsSet(true);
20555
            } else { 
20556
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20557
            }
20558
            break;
20559
          case 4: // BILLING_WAREHOUSE_ID
20560
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20561
              this.billingWarehouseId = iprot.readI64();
20562
              setBillingWarehouseIdIsSet(true);
20563
            } else { 
20564
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20565
            }
20566
            break;
20567
          case 5: // SHIPPING_WAREHOUSE_ID
20568
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20569
              this.shippingWarehouseId = iprot.readI64();
20570
              setShippingWarehouseIdIsSet(true);
20571
            } else { 
20572
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20573
            }
20574
            break;
20575
          default:
20576
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20577
        }
20578
        iprot.readFieldEnd();
20579
      }
20580
      iprot.readStructEnd();
20581
      validate();
20582
    }
20583
 
20584
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20585
      validate();
20586
 
20587
      oprot.writeStructBegin(STRUCT_DESC);
20588
      if (this.warehouseType != null) {
20589
        oprot.writeFieldBegin(WAREHOUSE_TYPE_FIELD_DESC);
20590
        oprot.writeI32(this.warehouseType.getValue());
20591
        oprot.writeFieldEnd();
20592
      }
20593
      if (this.inventoryType != null) {
20594
        oprot.writeFieldBegin(INVENTORY_TYPE_FIELD_DESC);
20595
        oprot.writeI32(this.inventoryType.getValue());
20596
        oprot.writeFieldEnd();
20597
      }
20598
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
20599
      oprot.writeI64(this.vendorId);
20600
      oprot.writeFieldEnd();
20601
      oprot.writeFieldBegin(BILLING_WAREHOUSE_ID_FIELD_DESC);
20602
      oprot.writeI64(this.billingWarehouseId);
20603
      oprot.writeFieldEnd();
20604
      oprot.writeFieldBegin(SHIPPING_WAREHOUSE_ID_FIELD_DESC);
20605
      oprot.writeI64(this.shippingWarehouseId);
20606
      oprot.writeFieldEnd();
20607
      oprot.writeFieldStop();
20608
      oprot.writeStructEnd();
20609
    }
20610
 
20611
    @Override
20612
    public String toString() {
20613
      StringBuilder sb = new StringBuilder("getWarehouses_args(");
20614
      boolean first = true;
20615
 
20616
      sb.append("warehouseType:");
20617
      if (this.warehouseType == null) {
20618
        sb.append("null");
20619
      } else {
20620
        sb.append(this.warehouseType);
20621
      }
20622
      first = false;
20623
      if (!first) sb.append(", ");
20624
      sb.append("inventoryType:");
20625
      if (this.inventoryType == null) {
20626
        sb.append("null");
20627
      } else {
20628
        sb.append(this.inventoryType);
20629
      }
20630
      first = false;
20631
      if (!first) sb.append(", ");
20632
      sb.append("vendorId:");
20633
      sb.append(this.vendorId);
20634
      first = false;
20635
      if (!first) sb.append(", ");
20636
      sb.append("billingWarehouseId:");
20637
      sb.append(this.billingWarehouseId);
20638
      first = false;
20639
      if (!first) sb.append(", ");
20640
      sb.append("shippingWarehouseId:");
20641
      sb.append(this.shippingWarehouseId);
20642
      first = false;
20643
      sb.append(")");
20644
      return sb.toString();
20645
    }
20646
 
20647
    public void validate() throws org.apache.thrift.TException {
20648
      // check for required fields
20649
    }
20650
 
20651
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20652
      try {
20653
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20654
      } catch (org.apache.thrift.TException te) {
20655
        throw new java.io.IOException(te);
20656
      }
20657
    }
20658
 
20659
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20660
      try {
20661
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20662
      } catch (org.apache.thrift.TException te) {
20663
        throw new java.io.IOException(te);
20664
      }
20665
    }
20666
 
20667
  }
20668
 
20669
  public static class getWarehouses_result implements org.apache.thrift.TBase<getWarehouses_result, getWarehouses_result._Fields>, java.io.Serializable, Cloneable   {
20670
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouses_result");
20671
 
20672
    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);
20673
 
20674
    private List<Warehouse> success; // required
20675
 
20676
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20677
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20678
      SUCCESS((short)0, "success");
20679
 
20680
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20681
 
20682
      static {
20683
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20684
          byName.put(field.getFieldName(), field);
20685
        }
20686
      }
20687
 
20688
      /**
20689
       * Find the _Fields constant that matches fieldId, or null if its not found.
20690
       */
20691
      public static _Fields findByThriftId(int fieldId) {
20692
        switch(fieldId) {
20693
          case 0: // SUCCESS
20694
            return SUCCESS;
20695
          default:
20696
            return null;
20697
        }
20698
      }
20699
 
20700
      /**
20701
       * Find the _Fields constant that matches fieldId, throwing an exception
20702
       * if it is not found.
20703
       */
20704
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20705
        _Fields fields = findByThriftId(fieldId);
20706
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20707
        return fields;
20708
      }
20709
 
20710
      /**
20711
       * Find the _Fields constant that matches name, or null if its not found.
20712
       */
20713
      public static _Fields findByName(String name) {
20714
        return byName.get(name);
20715
      }
20716
 
20717
      private final short _thriftId;
20718
      private final String _fieldName;
20719
 
20720
      _Fields(short thriftId, String fieldName) {
20721
        _thriftId = thriftId;
20722
        _fieldName = fieldName;
20723
      }
20724
 
20725
      public short getThriftFieldId() {
20726
        return _thriftId;
20727
      }
20728
 
20729
      public String getFieldName() {
20730
        return _fieldName;
20731
      }
20732
    }
20733
 
20734
    // isset id assignments
20735
 
20736
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20737
    static {
20738
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20739
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20740
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
20741
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
20742
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20743
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouses_result.class, metaDataMap);
20744
    }
20745
 
20746
    public getWarehouses_result() {
20747
    }
20748
 
20749
    public getWarehouses_result(
20750
      List<Warehouse> success)
20751
    {
20752
      this();
20753
      this.success = success;
20754
    }
20755
 
20756
    /**
20757
     * Performs a deep copy on <i>other</i>.
20758
     */
20759
    public getWarehouses_result(getWarehouses_result other) {
20760
      if (other.isSetSuccess()) {
20761
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
20762
        for (Warehouse other_element : other.success) {
20763
          __this__success.add(new Warehouse(other_element));
20764
        }
20765
        this.success = __this__success;
20766
      }
20767
    }
20768
 
20769
    public getWarehouses_result deepCopy() {
20770
      return new getWarehouses_result(this);
20771
    }
20772
 
20773
    @Override
20774
    public void clear() {
20775
      this.success = null;
20776
    }
20777
 
20778
    public int getSuccessSize() {
20779
      return (this.success == null) ? 0 : this.success.size();
20780
    }
20781
 
20782
    public java.util.Iterator<Warehouse> getSuccessIterator() {
20783
      return (this.success == null) ? null : this.success.iterator();
20784
    }
20785
 
20786
    public void addToSuccess(Warehouse elem) {
20787
      if (this.success == null) {
20788
        this.success = new ArrayList<Warehouse>();
20789
      }
20790
      this.success.add(elem);
20791
    }
20792
 
20793
    public List<Warehouse> getSuccess() {
20794
      return this.success;
20795
    }
20796
 
20797
    public void setSuccess(List<Warehouse> success) {
20798
      this.success = success;
20799
    }
20800
 
20801
    public void unsetSuccess() {
20802
      this.success = null;
20803
    }
20804
 
20805
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
20806
    public boolean isSetSuccess() {
20807
      return this.success != null;
20808
    }
20809
 
20810
    public void setSuccessIsSet(boolean value) {
20811
      if (!value) {
20812
        this.success = null;
20813
      }
20814
    }
20815
 
20816
    public void setFieldValue(_Fields field, Object value) {
20817
      switch (field) {
20818
      case SUCCESS:
20819
        if (value == null) {
20820
          unsetSuccess();
20821
        } else {
20822
          setSuccess((List<Warehouse>)value);
20823
        }
20824
        break;
20825
 
20826
      }
20827
    }
20828
 
20829
    public Object getFieldValue(_Fields field) {
20830
      switch (field) {
20831
      case SUCCESS:
20832
        return getSuccess();
20833
 
20834
      }
20835
      throw new IllegalStateException();
20836
    }
20837
 
20838
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20839
    public boolean isSet(_Fields field) {
20840
      if (field == null) {
20841
        throw new IllegalArgumentException();
20842
      }
20843
 
20844
      switch (field) {
20845
      case SUCCESS:
20846
        return isSetSuccess();
20847
      }
20848
      throw new IllegalStateException();
20849
    }
20850
 
20851
    @Override
20852
    public boolean equals(Object that) {
20853
      if (that == null)
20854
        return false;
20855
      if (that instanceof getWarehouses_result)
20856
        return this.equals((getWarehouses_result)that);
20857
      return false;
20858
    }
20859
 
20860
    public boolean equals(getWarehouses_result that) {
20861
      if (that == null)
20862
        return false;
20863
 
20864
      boolean this_present_success = true && this.isSetSuccess();
20865
      boolean that_present_success = true && that.isSetSuccess();
20866
      if (this_present_success || that_present_success) {
20867
        if (!(this_present_success && that_present_success))
20868
          return false;
20869
        if (!this.success.equals(that.success))
20870
          return false;
20871
      }
20872
 
20873
      return true;
20874
    }
20875
 
20876
    @Override
20877
    public int hashCode() {
20878
      return 0;
20879
    }
20880
 
20881
    public int compareTo(getWarehouses_result other) {
20882
      if (!getClass().equals(other.getClass())) {
20883
        return getClass().getName().compareTo(other.getClass().getName());
20884
      }
20885
 
20886
      int lastComparison = 0;
20887
      getWarehouses_result typedOther = (getWarehouses_result)other;
20888
 
20889
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
20890
      if (lastComparison != 0) {
20891
        return lastComparison;
20892
      }
20893
      if (isSetSuccess()) {
20894
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
20895
        if (lastComparison != 0) {
20896
          return lastComparison;
20897
        }
20898
      }
20899
      return 0;
20900
    }
20901
 
20902
    public _Fields fieldForId(int fieldId) {
20903
      return _Fields.findByThriftId(fieldId);
20904
    }
20905
 
20906
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20907
      org.apache.thrift.protocol.TField field;
20908
      iprot.readStructBegin();
20909
      while (true)
20910
      {
20911
        field = iprot.readFieldBegin();
20912
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20913
          break;
20914
        }
20915
        switch (field.id) {
20916
          case 0: // SUCCESS
20917
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
20918
              {
20919
                org.apache.thrift.protocol.TList _list48 = iprot.readListBegin();
20920
                this.success = new ArrayList<Warehouse>(_list48.size);
20921
                for (int _i49 = 0; _i49 < _list48.size; ++_i49)
20922
                {
20923
                  Warehouse _elem50; // required
20924
                  _elem50 = new Warehouse();
20925
                  _elem50.read(iprot);
20926
                  this.success.add(_elem50);
20927
                }
20928
                iprot.readListEnd();
20929
              }
20930
            } else { 
20931
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20932
            }
20933
            break;
20934
          default:
20935
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20936
        }
20937
        iprot.readFieldEnd();
20938
      }
20939
      iprot.readStructEnd();
20940
      validate();
20941
    }
20942
 
20943
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20944
      oprot.writeStructBegin(STRUCT_DESC);
20945
 
20946
      if (this.isSetSuccess()) {
20947
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
20948
        {
20949
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
20950
          for (Warehouse _iter51 : this.success)
20951
          {
20952
            _iter51.write(oprot);
20953
          }
20954
          oprot.writeListEnd();
20955
        }
20956
        oprot.writeFieldEnd();
20957
      }
20958
      oprot.writeFieldStop();
20959
      oprot.writeStructEnd();
20960
    }
20961
 
20962
    @Override
20963
    public String toString() {
20964
      StringBuilder sb = new StringBuilder("getWarehouses_result(");
20965
      boolean first = true;
20966
 
20967
      sb.append("success:");
20968
      if (this.success == null) {
20969
        sb.append("null");
20970
      } else {
20971
        sb.append(this.success);
20972
      }
20973
      first = false;
20974
      sb.append(")");
20975
      return sb.toString();
20976
    }
20977
 
20978
    public void validate() throws org.apache.thrift.TException {
20979
      // check for required fields
20980
    }
20981
 
20982
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20983
      try {
20984
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20985
      } catch (org.apache.thrift.TException te) {
20986
        throw new java.io.IOException(te);
20987
      }
20988
    }
20989
 
20990
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20991
      try {
20992
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20993
      } catch (org.apache.thrift.TException te) {
20994
        throw new java.io.IOException(te);
20995
      }
20996
    }
20997
 
20998
  }
20999
 
21000
  public static class resetAvailability_args implements org.apache.thrift.TBase<resetAvailability_args, resetAvailability_args._Fields>, java.io.Serializable, Cloneable   {
21001
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailability_args");
21002
 
21003
    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);
21004
    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);
21005
    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);
21006
    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);
21007
 
21008
    private String itemKey; // required
21009
    private long vendorId; // required
21010
    private long quantity; // required
21011
    private long warehouseId; // required
21012
 
21013
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21014
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21015
      ITEM_KEY((short)1, "itemKey"),
21016
      VENDOR_ID((short)2, "vendorId"),
21017
      QUANTITY((short)3, "quantity"),
21018
      WAREHOUSE_ID((short)4, "warehouseId");
21019
 
21020
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21021
 
21022
      static {
21023
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21024
          byName.put(field.getFieldName(), field);
21025
        }
21026
      }
21027
 
21028
      /**
21029
       * Find the _Fields constant that matches fieldId, or null if its not found.
21030
       */
21031
      public static _Fields findByThriftId(int fieldId) {
21032
        switch(fieldId) {
21033
          case 1: // ITEM_KEY
21034
            return ITEM_KEY;
21035
          case 2: // VENDOR_ID
21036
            return VENDOR_ID;
21037
          case 3: // QUANTITY
21038
            return QUANTITY;
21039
          case 4: // WAREHOUSE_ID
21040
            return WAREHOUSE_ID;
21041
          default:
21042
            return null;
21043
        }
21044
      }
21045
 
21046
      /**
21047
       * Find the _Fields constant that matches fieldId, throwing an exception
21048
       * if it is not found.
21049
       */
21050
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21051
        _Fields fields = findByThriftId(fieldId);
21052
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21053
        return fields;
21054
      }
21055
 
21056
      /**
21057
       * Find the _Fields constant that matches name, or null if its not found.
21058
       */
21059
      public static _Fields findByName(String name) {
21060
        return byName.get(name);
21061
      }
21062
 
21063
      private final short _thriftId;
21064
      private final String _fieldName;
21065
 
21066
      _Fields(short thriftId, String fieldName) {
21067
        _thriftId = thriftId;
21068
        _fieldName = fieldName;
21069
      }
21070
 
21071
      public short getThriftFieldId() {
21072
        return _thriftId;
21073
      }
21074
 
21075
      public String getFieldName() {
21076
        return _fieldName;
21077
      }
21078
    }
21079
 
21080
    // isset id assignments
21081
    private static final int __VENDORID_ISSET_ID = 0;
21082
    private static final int __QUANTITY_ISSET_ID = 1;
21083
    private static final int __WAREHOUSEID_ISSET_ID = 2;
21084
    private BitSet __isset_bit_vector = new BitSet(3);
21085
 
21086
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21087
    static {
21088
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21089
      tmpMap.put(_Fields.ITEM_KEY, new org.apache.thrift.meta_data.FieldMetaData("itemKey", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21090
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
21091
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21092
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21093
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21094
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21095
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21096
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21097
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21098
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailability_args.class, metaDataMap);
21099
    }
21100
 
21101
    public resetAvailability_args() {
21102
    }
21103
 
21104
    public resetAvailability_args(
21105
      String itemKey,
21106
      long vendorId,
21107
      long quantity,
21108
      long warehouseId)
21109
    {
21110
      this();
21111
      this.itemKey = itemKey;
21112
      this.vendorId = vendorId;
21113
      setVendorIdIsSet(true);
21114
      this.quantity = quantity;
21115
      setQuantityIsSet(true);
21116
      this.warehouseId = warehouseId;
21117
      setWarehouseIdIsSet(true);
21118
    }
21119
 
21120
    /**
21121
     * Performs a deep copy on <i>other</i>.
21122
     */
21123
    public resetAvailability_args(resetAvailability_args other) {
21124
      __isset_bit_vector.clear();
21125
      __isset_bit_vector.or(other.__isset_bit_vector);
21126
      if (other.isSetItemKey()) {
21127
        this.itemKey = other.itemKey;
21128
      }
21129
      this.vendorId = other.vendorId;
21130
      this.quantity = other.quantity;
21131
      this.warehouseId = other.warehouseId;
21132
    }
21133
 
21134
    public resetAvailability_args deepCopy() {
21135
      return new resetAvailability_args(this);
21136
    }
21137
 
21138
    @Override
21139
    public void clear() {
21140
      this.itemKey = null;
21141
      setVendorIdIsSet(false);
21142
      this.vendorId = 0;
21143
      setQuantityIsSet(false);
21144
      this.quantity = 0;
21145
      setWarehouseIdIsSet(false);
21146
      this.warehouseId = 0;
21147
    }
21148
 
21149
    public String getItemKey() {
21150
      return this.itemKey;
21151
    }
21152
 
21153
    public void setItemKey(String itemKey) {
21154
      this.itemKey = itemKey;
21155
    }
21156
 
21157
    public void unsetItemKey() {
21158
      this.itemKey = null;
21159
    }
21160
 
21161
    /** Returns true if field itemKey is set (has been assigned a value) and false otherwise */
21162
    public boolean isSetItemKey() {
21163
      return this.itemKey != null;
21164
    }
21165
 
21166
    public void setItemKeyIsSet(boolean value) {
21167
      if (!value) {
21168
        this.itemKey = null;
21169
      }
21170
    }
21171
 
21172
    public long getVendorId() {
21173
      return this.vendorId;
21174
    }
21175
 
21176
    public void setVendorId(long vendorId) {
21177
      this.vendorId = vendorId;
21178
      setVendorIdIsSet(true);
21179
    }
21180
 
21181
    public void unsetVendorId() {
21182
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
21183
    }
21184
 
21185
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
21186
    public boolean isSetVendorId() {
21187
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
21188
    }
21189
 
21190
    public void setVendorIdIsSet(boolean value) {
21191
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
21192
    }
21193
 
21194
    public long getQuantity() {
21195
      return this.quantity;
21196
    }
21197
 
21198
    public void setQuantity(long quantity) {
21199
      this.quantity = quantity;
21200
      setQuantityIsSet(true);
21201
    }
21202
 
21203
    public void unsetQuantity() {
21204
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
21205
    }
21206
 
21207
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
21208
    public boolean isSetQuantity() {
21209
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
21210
    }
21211
 
21212
    public void setQuantityIsSet(boolean value) {
21213
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
21214
    }
21215
 
21216
    public long getWarehouseId() {
21217
      return this.warehouseId;
21218
    }
21219
 
21220
    public void setWarehouseId(long warehouseId) {
21221
      this.warehouseId = warehouseId;
21222
      setWarehouseIdIsSet(true);
21223
    }
21224
 
21225
    public void unsetWarehouseId() {
21226
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
21227
    }
21228
 
21229
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
21230
    public boolean isSetWarehouseId() {
21231
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
21232
    }
21233
 
21234
    public void setWarehouseIdIsSet(boolean value) {
21235
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
21236
    }
21237
 
21238
    public void setFieldValue(_Fields field, Object value) {
21239
      switch (field) {
21240
      case ITEM_KEY:
21241
        if (value == null) {
21242
          unsetItemKey();
21243
        } else {
21244
          setItemKey((String)value);
21245
        }
21246
        break;
21247
 
21248
      case VENDOR_ID:
21249
        if (value == null) {
21250
          unsetVendorId();
21251
        } else {
21252
          setVendorId((Long)value);
21253
        }
21254
        break;
21255
 
21256
      case QUANTITY:
21257
        if (value == null) {
21258
          unsetQuantity();
21259
        } else {
21260
          setQuantity((Long)value);
21261
        }
21262
        break;
21263
 
21264
      case WAREHOUSE_ID:
21265
        if (value == null) {
21266
          unsetWarehouseId();
21267
        } else {
21268
          setWarehouseId((Long)value);
21269
        }
21270
        break;
21271
 
21272
      }
21273
    }
21274
 
21275
    public Object getFieldValue(_Fields field) {
21276
      switch (field) {
21277
      case ITEM_KEY:
21278
        return getItemKey();
21279
 
21280
      case VENDOR_ID:
21281
        return Long.valueOf(getVendorId());
21282
 
21283
      case QUANTITY:
21284
        return Long.valueOf(getQuantity());
21285
 
21286
      case WAREHOUSE_ID:
21287
        return Long.valueOf(getWarehouseId());
21288
 
21289
      }
21290
      throw new IllegalStateException();
21291
    }
21292
 
21293
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21294
    public boolean isSet(_Fields field) {
21295
      if (field == null) {
21296
        throw new IllegalArgumentException();
21297
      }
21298
 
21299
      switch (field) {
21300
      case ITEM_KEY:
21301
        return isSetItemKey();
21302
      case VENDOR_ID:
21303
        return isSetVendorId();
21304
      case QUANTITY:
21305
        return isSetQuantity();
21306
      case WAREHOUSE_ID:
21307
        return isSetWarehouseId();
21308
      }
21309
      throw new IllegalStateException();
21310
    }
21311
 
21312
    @Override
21313
    public boolean equals(Object that) {
21314
      if (that == null)
21315
        return false;
21316
      if (that instanceof resetAvailability_args)
21317
        return this.equals((resetAvailability_args)that);
21318
      return false;
21319
    }
21320
 
21321
    public boolean equals(resetAvailability_args that) {
21322
      if (that == null)
21323
        return false;
21324
 
21325
      boolean this_present_itemKey = true && this.isSetItemKey();
21326
      boolean that_present_itemKey = true && that.isSetItemKey();
21327
      if (this_present_itemKey || that_present_itemKey) {
21328
        if (!(this_present_itemKey && that_present_itemKey))
21329
          return false;
21330
        if (!this.itemKey.equals(that.itemKey))
21331
          return false;
21332
      }
21333
 
21334
      boolean this_present_vendorId = true;
21335
      boolean that_present_vendorId = true;
21336
      if (this_present_vendorId || that_present_vendorId) {
21337
        if (!(this_present_vendorId && that_present_vendorId))
21338
          return false;
21339
        if (this.vendorId != that.vendorId)
21340
          return false;
21341
      }
21342
 
21343
      boolean this_present_quantity = true;
21344
      boolean that_present_quantity = true;
21345
      if (this_present_quantity || that_present_quantity) {
21346
        if (!(this_present_quantity && that_present_quantity))
21347
          return false;
21348
        if (this.quantity != that.quantity)
21349
          return false;
21350
      }
21351
 
21352
      boolean this_present_warehouseId = true;
21353
      boolean that_present_warehouseId = true;
21354
      if (this_present_warehouseId || that_present_warehouseId) {
21355
        if (!(this_present_warehouseId && that_present_warehouseId))
21356
          return false;
21357
        if (this.warehouseId != that.warehouseId)
21358
          return false;
21359
      }
21360
 
21361
      return true;
21362
    }
21363
 
21364
    @Override
21365
    public int hashCode() {
21366
      return 0;
21367
    }
21368
 
21369
    public int compareTo(resetAvailability_args other) {
21370
      if (!getClass().equals(other.getClass())) {
21371
        return getClass().getName().compareTo(other.getClass().getName());
21372
      }
21373
 
21374
      int lastComparison = 0;
21375
      resetAvailability_args typedOther = (resetAvailability_args)other;
21376
 
21377
      lastComparison = Boolean.valueOf(isSetItemKey()).compareTo(typedOther.isSetItemKey());
21378
      if (lastComparison != 0) {
21379
        return lastComparison;
21380
      }
21381
      if (isSetItemKey()) {
21382
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemKey, typedOther.itemKey);
21383
        if (lastComparison != 0) {
21384
          return lastComparison;
21385
        }
21386
      }
21387
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
21388
      if (lastComparison != 0) {
21389
        return lastComparison;
21390
      }
21391
      if (isSetVendorId()) {
21392
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
21393
        if (lastComparison != 0) {
21394
          return lastComparison;
21395
        }
21396
      }
21397
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
21398
      if (lastComparison != 0) {
21399
        return lastComparison;
21400
      }
21401
      if (isSetQuantity()) {
21402
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
21403
        if (lastComparison != 0) {
21404
          return lastComparison;
21405
        }
21406
      }
21407
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
21408
      if (lastComparison != 0) {
21409
        return lastComparison;
21410
      }
21411
      if (isSetWarehouseId()) {
21412
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
21413
        if (lastComparison != 0) {
21414
          return lastComparison;
21415
        }
21416
      }
21417
      return 0;
21418
    }
21419
 
21420
    public _Fields fieldForId(int fieldId) {
21421
      return _Fields.findByThriftId(fieldId);
21422
    }
21423
 
21424
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21425
      org.apache.thrift.protocol.TField field;
21426
      iprot.readStructBegin();
21427
      while (true)
21428
      {
21429
        field = iprot.readFieldBegin();
21430
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21431
          break;
21432
        }
21433
        switch (field.id) {
21434
          case 1: // ITEM_KEY
21435
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
21436
              this.itemKey = iprot.readString();
21437
            } else { 
21438
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21439
            }
21440
            break;
21441
          case 2: // VENDOR_ID
21442
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21443
              this.vendorId = iprot.readI64();
21444
              setVendorIdIsSet(true);
21445
            } else { 
21446
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21447
            }
21448
            break;
21449
          case 3: // QUANTITY
21450
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21451
              this.quantity = iprot.readI64();
21452
              setQuantityIsSet(true);
21453
            } else { 
21454
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21455
            }
21456
            break;
21457
          case 4: // WAREHOUSE_ID
21458
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21459
              this.warehouseId = iprot.readI64();
21460
              setWarehouseIdIsSet(true);
21461
            } else { 
21462
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21463
            }
21464
            break;
21465
          default:
21466
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21467
        }
21468
        iprot.readFieldEnd();
21469
      }
21470
      iprot.readStructEnd();
21471
      validate();
21472
    }
21473
 
21474
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21475
      validate();
21476
 
21477
      oprot.writeStructBegin(STRUCT_DESC);
21478
      if (this.itemKey != null) {
21479
        oprot.writeFieldBegin(ITEM_KEY_FIELD_DESC);
21480
        oprot.writeString(this.itemKey);
21481
        oprot.writeFieldEnd();
21482
      }
21483
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
21484
      oprot.writeI64(this.vendorId);
21485
      oprot.writeFieldEnd();
21486
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
21487
      oprot.writeI64(this.quantity);
21488
      oprot.writeFieldEnd();
21489
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
21490
      oprot.writeI64(this.warehouseId);
21491
      oprot.writeFieldEnd();
21492
      oprot.writeFieldStop();
21493
      oprot.writeStructEnd();
21494
    }
21495
 
21496
    @Override
21497
    public String toString() {
21498
      StringBuilder sb = new StringBuilder("resetAvailability_args(");
21499
      boolean first = true;
21500
 
21501
      sb.append("itemKey:");
21502
      if (this.itemKey == null) {
21503
        sb.append("null");
21504
      } else {
21505
        sb.append(this.itemKey);
21506
      }
21507
      first = false;
21508
      if (!first) sb.append(", ");
21509
      sb.append("vendorId:");
21510
      sb.append(this.vendorId);
21511
      first = false;
21512
      if (!first) sb.append(", ");
21513
      sb.append("quantity:");
21514
      sb.append(this.quantity);
21515
      first = false;
21516
      if (!first) sb.append(", ");
21517
      sb.append("warehouseId:");
21518
      sb.append(this.warehouseId);
21519
      first = false;
21520
      sb.append(")");
21521
      return sb.toString();
21522
    }
21523
 
21524
    public void validate() throws org.apache.thrift.TException {
21525
      // check for required fields
21526
    }
21527
 
21528
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21529
      try {
21530
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21531
      } catch (org.apache.thrift.TException te) {
21532
        throw new java.io.IOException(te);
21533
      }
21534
    }
21535
 
21536
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21537
      try {
21538
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
21539
        __isset_bit_vector = new BitSet(1);
21540
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21541
      } catch (org.apache.thrift.TException te) {
21542
        throw new java.io.IOException(te);
21543
      }
21544
    }
21545
 
21546
  }
21547
 
21548
  public static class resetAvailability_result implements org.apache.thrift.TBase<resetAvailability_result, resetAvailability_result._Fields>, java.io.Serializable, Cloneable   {
21549
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailability_result");
21550
 
21551
    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);
21552
 
21553
    private InventoryServiceException cex; // required
21554
 
21555
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21556
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21557
      CEX((short)1, "cex");
21558
 
21559
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21560
 
21561
      static {
21562
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21563
          byName.put(field.getFieldName(), field);
21564
        }
21565
      }
21566
 
21567
      /**
21568
       * Find the _Fields constant that matches fieldId, or null if its not found.
21569
       */
21570
      public static _Fields findByThriftId(int fieldId) {
21571
        switch(fieldId) {
21572
          case 1: // CEX
21573
            return CEX;
21574
          default:
21575
            return null;
21576
        }
21577
      }
21578
 
21579
      /**
21580
       * Find the _Fields constant that matches fieldId, throwing an exception
21581
       * if it is not found.
21582
       */
21583
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21584
        _Fields fields = findByThriftId(fieldId);
21585
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21586
        return fields;
21587
      }
21588
 
21589
      /**
21590
       * Find the _Fields constant that matches name, or null if its not found.
21591
       */
21592
      public static _Fields findByName(String name) {
21593
        return byName.get(name);
21594
      }
21595
 
21596
      private final short _thriftId;
21597
      private final String _fieldName;
21598
 
21599
      _Fields(short thriftId, String fieldName) {
21600
        _thriftId = thriftId;
21601
        _fieldName = fieldName;
21602
      }
21603
 
21604
      public short getThriftFieldId() {
21605
        return _thriftId;
21606
      }
21607
 
21608
      public String getFieldName() {
21609
        return _fieldName;
21610
      }
21611
    }
21612
 
21613
    // isset id assignments
21614
 
21615
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21616
    static {
21617
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21618
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21619
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
21620
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21621
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailability_result.class, metaDataMap);
21622
    }
21623
 
21624
    public resetAvailability_result() {
21625
    }
21626
 
21627
    public resetAvailability_result(
21628
      InventoryServiceException cex)
21629
    {
21630
      this();
21631
      this.cex = cex;
21632
    }
21633
 
21634
    /**
21635
     * Performs a deep copy on <i>other</i>.
21636
     */
21637
    public resetAvailability_result(resetAvailability_result other) {
21638
      if (other.isSetCex()) {
21639
        this.cex = new InventoryServiceException(other.cex);
21640
      }
21641
    }
21642
 
21643
    public resetAvailability_result deepCopy() {
21644
      return new resetAvailability_result(this);
21645
    }
21646
 
21647
    @Override
21648
    public void clear() {
21649
      this.cex = null;
21650
    }
21651
 
21652
    public InventoryServiceException getCex() {
21653
      return this.cex;
21654
    }
21655
 
21656
    public void setCex(InventoryServiceException cex) {
21657
      this.cex = cex;
21658
    }
21659
 
21660
    public void unsetCex() {
21661
      this.cex = null;
21662
    }
21663
 
21664
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
21665
    public boolean isSetCex() {
21666
      return this.cex != null;
21667
    }
21668
 
21669
    public void setCexIsSet(boolean value) {
21670
      if (!value) {
21671
        this.cex = null;
21672
      }
21673
    }
21674
 
21675
    public void setFieldValue(_Fields field, Object value) {
21676
      switch (field) {
21677
      case CEX:
21678
        if (value == null) {
21679
          unsetCex();
21680
        } else {
21681
          setCex((InventoryServiceException)value);
21682
        }
21683
        break;
21684
 
21685
      }
21686
    }
21687
 
21688
    public Object getFieldValue(_Fields field) {
21689
      switch (field) {
21690
      case CEX:
21691
        return getCex();
21692
 
21693
      }
21694
      throw new IllegalStateException();
21695
    }
21696
 
21697
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21698
    public boolean isSet(_Fields field) {
21699
      if (field == null) {
21700
        throw new IllegalArgumentException();
21701
      }
21702
 
21703
      switch (field) {
21704
      case CEX:
21705
        return isSetCex();
21706
      }
21707
      throw new IllegalStateException();
21708
    }
21709
 
21710
    @Override
21711
    public boolean equals(Object that) {
21712
      if (that == null)
21713
        return false;
21714
      if (that instanceof resetAvailability_result)
21715
        return this.equals((resetAvailability_result)that);
21716
      return false;
21717
    }
21718
 
21719
    public boolean equals(resetAvailability_result that) {
21720
      if (that == null)
21721
        return false;
21722
 
21723
      boolean this_present_cex = true && this.isSetCex();
21724
      boolean that_present_cex = true && that.isSetCex();
21725
      if (this_present_cex || that_present_cex) {
21726
        if (!(this_present_cex && that_present_cex))
21727
          return false;
21728
        if (!this.cex.equals(that.cex))
21729
          return false;
21730
      }
21731
 
21732
      return true;
21733
    }
21734
 
21735
    @Override
21736
    public int hashCode() {
21737
      return 0;
21738
    }
21739
 
21740
    public int compareTo(resetAvailability_result other) {
21741
      if (!getClass().equals(other.getClass())) {
21742
        return getClass().getName().compareTo(other.getClass().getName());
21743
      }
21744
 
21745
      int lastComparison = 0;
21746
      resetAvailability_result typedOther = (resetAvailability_result)other;
21747
 
21748
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
21749
      if (lastComparison != 0) {
21750
        return lastComparison;
21751
      }
21752
      if (isSetCex()) {
21753
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
21754
        if (lastComparison != 0) {
21755
          return lastComparison;
21756
        }
21757
      }
21758
      return 0;
21759
    }
21760
 
21761
    public _Fields fieldForId(int fieldId) {
21762
      return _Fields.findByThriftId(fieldId);
21763
    }
21764
 
21765
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21766
      org.apache.thrift.protocol.TField field;
21767
      iprot.readStructBegin();
21768
      while (true)
21769
      {
21770
        field = iprot.readFieldBegin();
21771
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21772
          break;
21773
        }
21774
        switch (field.id) {
21775
          case 1: // CEX
21776
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
21777
              this.cex = new InventoryServiceException();
21778
              this.cex.read(iprot);
21779
            } else { 
21780
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21781
            }
21782
            break;
21783
          default:
21784
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21785
        }
21786
        iprot.readFieldEnd();
21787
      }
21788
      iprot.readStructEnd();
21789
      validate();
21790
    }
21791
 
21792
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21793
      oprot.writeStructBegin(STRUCT_DESC);
21794
 
21795
      if (this.isSetCex()) {
21796
        oprot.writeFieldBegin(CEX_FIELD_DESC);
21797
        this.cex.write(oprot);
21798
        oprot.writeFieldEnd();
21799
      }
21800
      oprot.writeFieldStop();
21801
      oprot.writeStructEnd();
21802
    }
21803
 
21804
    @Override
21805
    public String toString() {
21806
      StringBuilder sb = new StringBuilder("resetAvailability_result(");
21807
      boolean first = true;
21808
 
21809
      sb.append("cex:");
21810
      if (this.cex == null) {
21811
        sb.append("null");
21812
      } else {
21813
        sb.append(this.cex);
21814
      }
21815
      first = false;
21816
      sb.append(")");
21817
      return sb.toString();
21818
    }
21819
 
21820
    public void validate() throws org.apache.thrift.TException {
21821
      // check for required fields
21822
    }
21823
 
21824
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21825
      try {
21826
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21827
      } catch (org.apache.thrift.TException te) {
21828
        throw new java.io.IOException(te);
21829
      }
21830
    }
21831
 
21832
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21833
      try {
21834
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21835
      } catch (org.apache.thrift.TException te) {
21836
        throw new java.io.IOException(te);
21837
      }
21838
    }
21839
 
21840
  }
21841
 
21842
  public static class resetAvailabilityForWarehouse_args implements org.apache.thrift.TBase<resetAvailabilityForWarehouse_args, resetAvailabilityForWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
21843
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailabilityForWarehouse_args");
21844
 
21845
    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);
21846
 
21847
    private long warehouseId; // required
21848
 
21849
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21850
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21851
      WAREHOUSE_ID((short)1, "warehouseId");
21852
 
21853
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21854
 
21855
      static {
21856
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21857
          byName.put(field.getFieldName(), field);
21858
        }
21859
      }
21860
 
21861
      /**
21862
       * Find the _Fields constant that matches fieldId, or null if its not found.
21863
       */
21864
      public static _Fields findByThriftId(int fieldId) {
21865
        switch(fieldId) {
21866
          case 1: // WAREHOUSE_ID
21867
            return WAREHOUSE_ID;
21868
          default:
21869
            return null;
21870
        }
21871
      }
21872
 
21873
      /**
21874
       * Find the _Fields constant that matches fieldId, throwing an exception
21875
       * if it is not found.
21876
       */
21877
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21878
        _Fields fields = findByThriftId(fieldId);
21879
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21880
        return fields;
21881
      }
21882
 
21883
      /**
21884
       * Find the _Fields constant that matches name, or null if its not found.
21885
       */
21886
      public static _Fields findByName(String name) {
21887
        return byName.get(name);
21888
      }
21889
 
21890
      private final short _thriftId;
21891
      private final String _fieldName;
21892
 
21893
      _Fields(short thriftId, String fieldName) {
21894
        _thriftId = thriftId;
21895
        _fieldName = fieldName;
21896
      }
21897
 
21898
      public short getThriftFieldId() {
21899
        return _thriftId;
21900
      }
21901
 
21902
      public String getFieldName() {
21903
        return _fieldName;
21904
      }
21905
    }
21906
 
21907
    // isset id assignments
21908
    private static final int __WAREHOUSEID_ISSET_ID = 0;
21909
    private BitSet __isset_bit_vector = new BitSet(1);
21910
 
21911
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21912
    static {
21913
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21914
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21915
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21916
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21917
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailabilityForWarehouse_args.class, metaDataMap);
21918
    }
21919
 
21920
    public resetAvailabilityForWarehouse_args() {
21921
    }
21922
 
21923
    public resetAvailabilityForWarehouse_args(
21924
      long warehouseId)
21925
    {
21926
      this();
21927
      this.warehouseId = warehouseId;
21928
      setWarehouseIdIsSet(true);
21929
    }
21930
 
21931
    /**
21932
     * Performs a deep copy on <i>other</i>.
21933
     */
21934
    public resetAvailabilityForWarehouse_args(resetAvailabilityForWarehouse_args other) {
21935
      __isset_bit_vector.clear();
21936
      __isset_bit_vector.or(other.__isset_bit_vector);
21937
      this.warehouseId = other.warehouseId;
21938
    }
21939
 
21940
    public resetAvailabilityForWarehouse_args deepCopy() {
21941
      return new resetAvailabilityForWarehouse_args(this);
21942
    }
21943
 
21944
    @Override
21945
    public void clear() {
21946
      setWarehouseIdIsSet(false);
21947
      this.warehouseId = 0;
21948
    }
21949
 
21950
    public long getWarehouseId() {
21951
      return this.warehouseId;
21952
    }
21953
 
21954
    public void setWarehouseId(long warehouseId) {
21955
      this.warehouseId = warehouseId;
21956
      setWarehouseIdIsSet(true);
21957
    }
21958
 
21959
    public void unsetWarehouseId() {
21960
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
21961
    }
21962
 
21963
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
21964
    public boolean isSetWarehouseId() {
21965
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
21966
    }
21967
 
21968
    public void setWarehouseIdIsSet(boolean value) {
21969
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
21970
    }
21971
 
21972
    public void setFieldValue(_Fields field, Object value) {
21973
      switch (field) {
21974
      case WAREHOUSE_ID:
21975
        if (value == null) {
21976
          unsetWarehouseId();
21977
        } else {
21978
          setWarehouseId((Long)value);
21979
        }
21980
        break;
21981
 
21982
      }
21983
    }
21984
 
21985
    public Object getFieldValue(_Fields field) {
21986
      switch (field) {
21987
      case WAREHOUSE_ID:
21988
        return Long.valueOf(getWarehouseId());
21989
 
21990
      }
21991
      throw new IllegalStateException();
21992
    }
21993
 
21994
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21995
    public boolean isSet(_Fields field) {
21996
      if (field == null) {
21997
        throw new IllegalArgumentException();
21998
      }
21999
 
22000
      switch (field) {
22001
      case WAREHOUSE_ID:
22002
        return isSetWarehouseId();
22003
      }
22004
      throw new IllegalStateException();
22005
    }
22006
 
22007
    @Override
22008
    public boolean equals(Object that) {
22009
      if (that == null)
22010
        return false;
22011
      if (that instanceof resetAvailabilityForWarehouse_args)
22012
        return this.equals((resetAvailabilityForWarehouse_args)that);
22013
      return false;
22014
    }
22015
 
22016
    public boolean equals(resetAvailabilityForWarehouse_args that) {
22017
      if (that == null)
22018
        return false;
22019
 
22020
      boolean this_present_warehouseId = true;
22021
      boolean that_present_warehouseId = true;
22022
      if (this_present_warehouseId || that_present_warehouseId) {
22023
        if (!(this_present_warehouseId && that_present_warehouseId))
22024
          return false;
22025
        if (this.warehouseId != that.warehouseId)
22026
          return false;
22027
      }
22028
 
22029
      return true;
22030
    }
22031
 
22032
    @Override
22033
    public int hashCode() {
22034
      return 0;
22035
    }
22036
 
22037
    public int compareTo(resetAvailabilityForWarehouse_args other) {
22038
      if (!getClass().equals(other.getClass())) {
22039
        return getClass().getName().compareTo(other.getClass().getName());
22040
      }
22041
 
22042
      int lastComparison = 0;
22043
      resetAvailabilityForWarehouse_args typedOther = (resetAvailabilityForWarehouse_args)other;
22044
 
22045
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
22046
      if (lastComparison != 0) {
22047
        return lastComparison;
22048
      }
22049
      if (isSetWarehouseId()) {
22050
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
22051
        if (lastComparison != 0) {
22052
          return lastComparison;
22053
        }
22054
      }
22055
      return 0;
22056
    }
22057
 
22058
    public _Fields fieldForId(int fieldId) {
22059
      return _Fields.findByThriftId(fieldId);
22060
    }
22061
 
22062
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22063
      org.apache.thrift.protocol.TField field;
22064
      iprot.readStructBegin();
22065
      while (true)
22066
      {
22067
        field = iprot.readFieldBegin();
22068
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22069
          break;
22070
        }
22071
        switch (field.id) {
22072
          case 1: // WAREHOUSE_ID
22073
            if (field.type == org.apache.thrift.protocol.TType.I64) {
22074
              this.warehouseId = iprot.readI64();
22075
              setWarehouseIdIsSet(true);
22076
            } else { 
22077
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22078
            }
22079
            break;
22080
          default:
22081
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22082
        }
22083
        iprot.readFieldEnd();
22084
      }
22085
      iprot.readStructEnd();
22086
      validate();
22087
    }
22088
 
22089
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22090
      validate();
22091
 
22092
      oprot.writeStructBegin(STRUCT_DESC);
22093
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
22094
      oprot.writeI64(this.warehouseId);
22095
      oprot.writeFieldEnd();
22096
      oprot.writeFieldStop();
22097
      oprot.writeStructEnd();
22098
    }
22099
 
22100
    @Override
22101
    public String toString() {
22102
      StringBuilder sb = new StringBuilder("resetAvailabilityForWarehouse_args(");
22103
      boolean first = true;
22104
 
22105
      sb.append("warehouseId:");
22106
      sb.append(this.warehouseId);
22107
      first = false;
22108
      sb.append(")");
22109
      return sb.toString();
22110
    }
22111
 
22112
    public void validate() throws org.apache.thrift.TException {
22113
      // check for required fields
22114
    }
22115
 
22116
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22117
      try {
22118
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22119
      } catch (org.apache.thrift.TException te) {
22120
        throw new java.io.IOException(te);
22121
      }
22122
    }
22123
 
22124
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22125
      try {
22126
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
22127
        __isset_bit_vector = new BitSet(1);
22128
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22129
      } catch (org.apache.thrift.TException te) {
22130
        throw new java.io.IOException(te);
22131
      }
22132
    }
22133
 
22134
  }
22135
 
22136
  public static class resetAvailabilityForWarehouse_result implements org.apache.thrift.TBase<resetAvailabilityForWarehouse_result, resetAvailabilityForWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
22137
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailabilityForWarehouse_result");
22138
 
22139
    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);
22140
 
22141
    private InventoryServiceException cex; // required
22142
 
22143
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22144
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22145
      CEX((short)1, "cex");
22146
 
22147
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22148
 
22149
      static {
22150
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22151
          byName.put(field.getFieldName(), field);
22152
        }
22153
      }
22154
 
22155
      /**
22156
       * Find the _Fields constant that matches fieldId, or null if its not found.
22157
       */
22158
      public static _Fields findByThriftId(int fieldId) {
22159
        switch(fieldId) {
22160
          case 1: // CEX
22161
            return CEX;
22162
          default:
22163
            return null;
22164
        }
22165
      }
22166
 
22167
      /**
22168
       * Find the _Fields constant that matches fieldId, throwing an exception
22169
       * if it is not found.
22170
       */
22171
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22172
        _Fields fields = findByThriftId(fieldId);
22173
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22174
        return fields;
22175
      }
22176
 
22177
      /**
22178
       * Find the _Fields constant that matches name, or null if its not found.
22179
       */
22180
      public static _Fields findByName(String name) {
22181
        return byName.get(name);
22182
      }
22183
 
22184
      private final short _thriftId;
22185
      private final String _fieldName;
22186
 
22187
      _Fields(short thriftId, String fieldName) {
22188
        _thriftId = thriftId;
22189
        _fieldName = fieldName;
22190
      }
22191
 
22192
      public short getThriftFieldId() {
22193
        return _thriftId;
22194
      }
22195
 
22196
      public String getFieldName() {
22197
        return _fieldName;
22198
      }
22199
    }
22200
 
22201
    // isset id assignments
22202
 
22203
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22204
    static {
22205
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22206
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22207
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
22208
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22209
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailabilityForWarehouse_result.class, metaDataMap);
22210
    }
22211
 
22212
    public resetAvailabilityForWarehouse_result() {
22213
    }
22214
 
22215
    public resetAvailabilityForWarehouse_result(
22216
      InventoryServiceException cex)
22217
    {
22218
      this();
22219
      this.cex = cex;
22220
    }
22221
 
22222
    /**
22223
     * Performs a deep copy on <i>other</i>.
22224
     */
22225
    public resetAvailabilityForWarehouse_result(resetAvailabilityForWarehouse_result other) {
22226
      if (other.isSetCex()) {
22227
        this.cex = new InventoryServiceException(other.cex);
22228
      }
22229
    }
22230
 
22231
    public resetAvailabilityForWarehouse_result deepCopy() {
22232
      return new resetAvailabilityForWarehouse_result(this);
22233
    }
22234
 
22235
    @Override
22236
    public void clear() {
22237
      this.cex = null;
22238
    }
22239
 
22240
    public InventoryServiceException getCex() {
22241
      return this.cex;
22242
    }
22243
 
22244
    public void setCex(InventoryServiceException cex) {
22245
      this.cex = cex;
22246
    }
22247
 
22248
    public void unsetCex() {
22249
      this.cex = null;
22250
    }
22251
 
22252
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
22253
    public boolean isSetCex() {
22254
      return this.cex != null;
22255
    }
22256
 
22257
    public void setCexIsSet(boolean value) {
22258
      if (!value) {
22259
        this.cex = null;
22260
      }
22261
    }
22262
 
22263
    public void setFieldValue(_Fields field, Object value) {
22264
      switch (field) {
22265
      case CEX:
22266
        if (value == null) {
22267
          unsetCex();
22268
        } else {
22269
          setCex((InventoryServiceException)value);
22270
        }
22271
        break;
22272
 
22273
      }
22274
    }
22275
 
22276
    public Object getFieldValue(_Fields field) {
22277
      switch (field) {
22278
      case CEX:
22279
        return getCex();
22280
 
22281
      }
22282
      throw new IllegalStateException();
22283
    }
22284
 
22285
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22286
    public boolean isSet(_Fields field) {
22287
      if (field == null) {
22288
        throw new IllegalArgumentException();
22289
      }
22290
 
22291
      switch (field) {
22292
      case CEX:
22293
        return isSetCex();
22294
      }
22295
      throw new IllegalStateException();
22296
    }
22297
 
22298
    @Override
22299
    public boolean equals(Object that) {
22300
      if (that == null)
22301
        return false;
22302
      if (that instanceof resetAvailabilityForWarehouse_result)
22303
        return this.equals((resetAvailabilityForWarehouse_result)that);
22304
      return false;
22305
    }
22306
 
22307
    public boolean equals(resetAvailabilityForWarehouse_result that) {
22308
      if (that == null)
22309
        return false;
22310
 
22311
      boolean this_present_cex = true && this.isSetCex();
22312
      boolean that_present_cex = true && that.isSetCex();
22313
      if (this_present_cex || that_present_cex) {
22314
        if (!(this_present_cex && that_present_cex))
22315
          return false;
22316
        if (!this.cex.equals(that.cex))
22317
          return false;
22318
      }
22319
 
22320
      return true;
22321
    }
22322
 
22323
    @Override
22324
    public int hashCode() {
22325
      return 0;
22326
    }
22327
 
22328
    public int compareTo(resetAvailabilityForWarehouse_result other) {
22329
      if (!getClass().equals(other.getClass())) {
22330
        return getClass().getName().compareTo(other.getClass().getName());
22331
      }
22332
 
22333
      int lastComparison = 0;
22334
      resetAvailabilityForWarehouse_result typedOther = (resetAvailabilityForWarehouse_result)other;
22335
 
22336
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
22337
      if (lastComparison != 0) {
22338
        return lastComparison;
22339
      }
22340
      if (isSetCex()) {
22341
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
22342
        if (lastComparison != 0) {
22343
          return lastComparison;
22344
        }
22345
      }
22346
      return 0;
22347
    }
22348
 
22349
    public _Fields fieldForId(int fieldId) {
22350
      return _Fields.findByThriftId(fieldId);
22351
    }
22352
 
22353
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22354
      org.apache.thrift.protocol.TField field;
22355
      iprot.readStructBegin();
22356
      while (true)
22357
      {
22358
        field = iprot.readFieldBegin();
22359
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22360
          break;
22361
        }
22362
        switch (field.id) {
22363
          case 1: // CEX
22364
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
22365
              this.cex = new InventoryServiceException();
22366
              this.cex.read(iprot);
22367
            } else { 
22368
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22369
            }
22370
            break;
22371
          default:
22372
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22373
        }
22374
        iprot.readFieldEnd();
22375
      }
22376
      iprot.readStructEnd();
22377
      validate();
22378
    }
22379
 
22380
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22381
      oprot.writeStructBegin(STRUCT_DESC);
22382
 
22383
      if (this.isSetCex()) {
22384
        oprot.writeFieldBegin(CEX_FIELD_DESC);
22385
        this.cex.write(oprot);
22386
        oprot.writeFieldEnd();
22387
      }
22388
      oprot.writeFieldStop();
22389
      oprot.writeStructEnd();
22390
    }
22391
 
22392
    @Override
22393
    public String toString() {
22394
      StringBuilder sb = new StringBuilder("resetAvailabilityForWarehouse_result(");
22395
      boolean first = true;
22396
 
22397
      sb.append("cex:");
22398
      if (this.cex == null) {
22399
        sb.append("null");
22400
      } else {
22401
        sb.append(this.cex);
22402
      }
22403
      first = false;
22404
      sb.append(")");
22405
      return sb.toString();
22406
    }
22407
 
22408
    public void validate() throws org.apache.thrift.TException {
22409
      // check for required fields
22410
    }
22411
 
22412
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22413
      try {
22414
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22415
      } catch (org.apache.thrift.TException te) {
22416
        throw new java.io.IOException(te);
22417
      }
22418
    }
22419
 
22420
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22421
      try {
22422
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22423
      } catch (org.apache.thrift.TException te) {
22424
        throw new java.io.IOException(te);
22425
      }
22426
    }
22427
 
22428
  }
22429
 
22430
  public static class getItemKeysToBeProcessed_args implements org.apache.thrift.TBase<getItemKeysToBeProcessed_args, getItemKeysToBeProcessed_args._Fields>, java.io.Serializable, Cloneable   {
22431
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemKeysToBeProcessed_args");
22432
 
22433
    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);
22434
 
22435
    private long warehouseId; // required
22436
 
22437
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22438
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22439
      WAREHOUSE_ID((short)1, "warehouseId");
22440
 
22441
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22442
 
22443
      static {
22444
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22445
          byName.put(field.getFieldName(), field);
22446
        }
22447
      }
22448
 
22449
      /**
22450
       * Find the _Fields constant that matches fieldId, or null if its not found.
22451
       */
22452
      public static _Fields findByThriftId(int fieldId) {
22453
        switch(fieldId) {
22454
          case 1: // WAREHOUSE_ID
22455
            return WAREHOUSE_ID;
22456
          default:
22457
            return null;
22458
        }
22459
      }
22460
 
22461
      /**
22462
       * Find the _Fields constant that matches fieldId, throwing an exception
22463
       * if it is not found.
22464
       */
22465
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22466
        _Fields fields = findByThriftId(fieldId);
22467
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22468
        return fields;
22469
      }
22470
 
22471
      /**
22472
       * Find the _Fields constant that matches name, or null if its not found.
22473
       */
22474
      public static _Fields findByName(String name) {
22475
        return byName.get(name);
22476
      }
22477
 
22478
      private final short _thriftId;
22479
      private final String _fieldName;
22480
 
22481
      _Fields(short thriftId, String fieldName) {
22482
        _thriftId = thriftId;
22483
        _fieldName = fieldName;
22484
      }
22485
 
22486
      public short getThriftFieldId() {
22487
        return _thriftId;
22488
      }
22489
 
22490
      public String getFieldName() {
22491
        return _fieldName;
22492
      }
22493
    }
22494
 
22495
    // isset id assignments
22496
    private static final int __WAREHOUSEID_ISSET_ID = 0;
22497
    private BitSet __isset_bit_vector = new BitSet(1);
22498
 
22499
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22500
    static {
22501
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22502
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22503
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
22504
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22505
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemKeysToBeProcessed_args.class, metaDataMap);
22506
    }
22507
 
22508
    public getItemKeysToBeProcessed_args() {
22509
    }
22510
 
22511
    public getItemKeysToBeProcessed_args(
22512
      long warehouseId)
22513
    {
22514
      this();
22515
      this.warehouseId = warehouseId;
22516
      setWarehouseIdIsSet(true);
22517
    }
22518
 
22519
    /**
22520
     * Performs a deep copy on <i>other</i>.
22521
     */
22522
    public getItemKeysToBeProcessed_args(getItemKeysToBeProcessed_args other) {
22523
      __isset_bit_vector.clear();
22524
      __isset_bit_vector.or(other.__isset_bit_vector);
22525
      this.warehouseId = other.warehouseId;
22526
    }
22527
 
22528
    public getItemKeysToBeProcessed_args deepCopy() {
22529
      return new getItemKeysToBeProcessed_args(this);
22530
    }
22531
 
22532
    @Override
22533
    public void clear() {
22534
      setWarehouseIdIsSet(false);
22535
      this.warehouseId = 0;
22536
    }
22537
 
22538
    public long getWarehouseId() {
22539
      return this.warehouseId;
22540
    }
22541
 
22542
    public void setWarehouseId(long warehouseId) {
22543
      this.warehouseId = warehouseId;
22544
      setWarehouseIdIsSet(true);
22545
    }
22546
 
22547
    public void unsetWarehouseId() {
22548
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
22549
    }
22550
 
22551
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
22552
    public boolean isSetWarehouseId() {
22553
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
22554
    }
22555
 
22556
    public void setWarehouseIdIsSet(boolean value) {
22557
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
22558
    }
22559
 
22560
    public void setFieldValue(_Fields field, Object value) {
22561
      switch (field) {
22562
      case WAREHOUSE_ID:
22563
        if (value == null) {
22564
          unsetWarehouseId();
22565
        } else {
22566
          setWarehouseId((Long)value);
22567
        }
22568
        break;
22569
 
22570
      }
22571
    }
22572
 
22573
    public Object getFieldValue(_Fields field) {
22574
      switch (field) {
22575
      case WAREHOUSE_ID:
22576
        return Long.valueOf(getWarehouseId());
22577
 
22578
      }
22579
      throw new IllegalStateException();
22580
    }
22581
 
22582
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22583
    public boolean isSet(_Fields field) {
22584
      if (field == null) {
22585
        throw new IllegalArgumentException();
22586
      }
22587
 
22588
      switch (field) {
22589
      case WAREHOUSE_ID:
22590
        return isSetWarehouseId();
22591
      }
22592
      throw new IllegalStateException();
22593
    }
22594
 
22595
    @Override
22596
    public boolean equals(Object that) {
22597
      if (that == null)
22598
        return false;
22599
      if (that instanceof getItemKeysToBeProcessed_args)
22600
        return this.equals((getItemKeysToBeProcessed_args)that);
22601
      return false;
22602
    }
22603
 
22604
    public boolean equals(getItemKeysToBeProcessed_args that) {
22605
      if (that == null)
22606
        return false;
22607
 
22608
      boolean this_present_warehouseId = true;
22609
      boolean that_present_warehouseId = true;
22610
      if (this_present_warehouseId || that_present_warehouseId) {
22611
        if (!(this_present_warehouseId && that_present_warehouseId))
22612
          return false;
22613
        if (this.warehouseId != that.warehouseId)
22614
          return false;
22615
      }
22616
 
22617
      return true;
22618
    }
22619
 
22620
    @Override
22621
    public int hashCode() {
22622
      return 0;
22623
    }
22624
 
22625
    public int compareTo(getItemKeysToBeProcessed_args other) {
22626
      if (!getClass().equals(other.getClass())) {
22627
        return getClass().getName().compareTo(other.getClass().getName());
22628
      }
22629
 
22630
      int lastComparison = 0;
22631
      getItemKeysToBeProcessed_args typedOther = (getItemKeysToBeProcessed_args)other;
22632
 
22633
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
22634
      if (lastComparison != 0) {
22635
        return lastComparison;
22636
      }
22637
      if (isSetWarehouseId()) {
22638
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
22639
        if (lastComparison != 0) {
22640
          return lastComparison;
22641
        }
22642
      }
22643
      return 0;
22644
    }
22645
 
22646
    public _Fields fieldForId(int fieldId) {
22647
      return _Fields.findByThriftId(fieldId);
22648
    }
22649
 
22650
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22651
      org.apache.thrift.protocol.TField field;
22652
      iprot.readStructBegin();
22653
      while (true)
22654
      {
22655
        field = iprot.readFieldBegin();
22656
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22657
          break;
22658
        }
22659
        switch (field.id) {
22660
          case 1: // WAREHOUSE_ID
22661
            if (field.type == org.apache.thrift.protocol.TType.I64) {
22662
              this.warehouseId = iprot.readI64();
22663
              setWarehouseIdIsSet(true);
22664
            } else { 
22665
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22666
            }
22667
            break;
22668
          default:
22669
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22670
        }
22671
        iprot.readFieldEnd();
22672
      }
22673
      iprot.readStructEnd();
22674
      validate();
22675
    }
22676
 
22677
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22678
      validate();
22679
 
22680
      oprot.writeStructBegin(STRUCT_DESC);
22681
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
22682
      oprot.writeI64(this.warehouseId);
22683
      oprot.writeFieldEnd();
22684
      oprot.writeFieldStop();
22685
      oprot.writeStructEnd();
22686
    }
22687
 
22688
    @Override
22689
    public String toString() {
22690
      StringBuilder sb = new StringBuilder("getItemKeysToBeProcessed_args(");
22691
      boolean first = true;
22692
 
22693
      sb.append("warehouseId:");
22694
      sb.append(this.warehouseId);
22695
      first = false;
22696
      sb.append(")");
22697
      return sb.toString();
22698
    }
22699
 
22700
    public void validate() throws org.apache.thrift.TException {
22701
      // check for required fields
22702
    }
22703
 
22704
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22705
      try {
22706
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22707
      } catch (org.apache.thrift.TException te) {
22708
        throw new java.io.IOException(te);
22709
      }
22710
    }
22711
 
22712
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22713
      try {
22714
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22715
      } catch (org.apache.thrift.TException te) {
22716
        throw new java.io.IOException(te);
22717
      }
22718
    }
22719
 
22720
  }
22721
 
22722
  public static class getItemKeysToBeProcessed_result implements org.apache.thrift.TBase<getItemKeysToBeProcessed_result, getItemKeysToBeProcessed_result._Fields>, java.io.Serializable, Cloneable   {
22723
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemKeysToBeProcessed_result");
22724
 
22725
    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);
22726
 
22727
    private List<String> success; // required
22728
 
22729
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22730
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22731
      SUCCESS((short)0, "success");
22732
 
22733
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22734
 
22735
      static {
22736
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22737
          byName.put(field.getFieldName(), field);
22738
        }
22739
      }
22740
 
22741
      /**
22742
       * Find the _Fields constant that matches fieldId, or null if its not found.
22743
       */
22744
      public static _Fields findByThriftId(int fieldId) {
22745
        switch(fieldId) {
22746
          case 0: // SUCCESS
22747
            return SUCCESS;
22748
          default:
22749
            return null;
22750
        }
22751
      }
22752
 
22753
      /**
22754
       * Find the _Fields constant that matches fieldId, throwing an exception
22755
       * if it is not found.
22756
       */
22757
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22758
        _Fields fields = findByThriftId(fieldId);
22759
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22760
        return fields;
22761
      }
22762
 
22763
      /**
22764
       * Find the _Fields constant that matches name, or null if its not found.
22765
       */
22766
      public static _Fields findByName(String name) {
22767
        return byName.get(name);
22768
      }
22769
 
22770
      private final short _thriftId;
22771
      private final String _fieldName;
22772
 
22773
      _Fields(short thriftId, String fieldName) {
22774
        _thriftId = thriftId;
22775
        _fieldName = fieldName;
22776
      }
22777
 
22778
      public short getThriftFieldId() {
22779
        return _thriftId;
22780
      }
22781
 
22782
      public String getFieldName() {
22783
        return _fieldName;
22784
      }
22785
    }
22786
 
22787
    // isset id assignments
22788
 
22789
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22790
    static {
22791
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22792
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22793
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
22794
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
22795
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22796
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemKeysToBeProcessed_result.class, metaDataMap);
22797
    }
22798
 
22799
    public getItemKeysToBeProcessed_result() {
22800
    }
22801
 
22802
    public getItemKeysToBeProcessed_result(
22803
      List<String> success)
22804
    {
22805
      this();
22806
      this.success = success;
22807
    }
22808
 
22809
    /**
22810
     * Performs a deep copy on <i>other</i>.
22811
     */
22812
    public getItemKeysToBeProcessed_result(getItemKeysToBeProcessed_result other) {
22813
      if (other.isSetSuccess()) {
22814
        List<String> __this__success = new ArrayList<String>();
22815
        for (String other_element : other.success) {
22816
          __this__success.add(other_element);
22817
        }
22818
        this.success = __this__success;
22819
      }
22820
    }
22821
 
22822
    public getItemKeysToBeProcessed_result deepCopy() {
22823
      return new getItemKeysToBeProcessed_result(this);
22824
    }
22825
 
22826
    @Override
22827
    public void clear() {
22828
      this.success = null;
22829
    }
22830
 
22831
    public int getSuccessSize() {
22832
      return (this.success == null) ? 0 : this.success.size();
22833
    }
22834
 
22835
    public java.util.Iterator<String> getSuccessIterator() {
22836
      return (this.success == null) ? null : this.success.iterator();
22837
    }
22838
 
22839
    public void addToSuccess(String elem) {
22840
      if (this.success == null) {
22841
        this.success = new ArrayList<String>();
22842
      }
22843
      this.success.add(elem);
22844
    }
22845
 
22846
    public List<String> getSuccess() {
22847
      return this.success;
22848
    }
22849
 
22850
    public void setSuccess(List<String> success) {
22851
      this.success = success;
22852
    }
22853
 
22854
    public void unsetSuccess() {
22855
      this.success = null;
22856
    }
22857
 
22858
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
22859
    public boolean isSetSuccess() {
22860
      return this.success != null;
22861
    }
22862
 
22863
    public void setSuccessIsSet(boolean value) {
22864
      if (!value) {
22865
        this.success = null;
22866
      }
22867
    }
22868
 
22869
    public void setFieldValue(_Fields field, Object value) {
22870
      switch (field) {
22871
      case SUCCESS:
22872
        if (value == null) {
22873
          unsetSuccess();
22874
        } else {
22875
          setSuccess((List<String>)value);
22876
        }
22877
        break;
22878
 
22879
      }
22880
    }
22881
 
22882
    public Object getFieldValue(_Fields field) {
22883
      switch (field) {
22884
      case SUCCESS:
22885
        return getSuccess();
22886
 
22887
      }
22888
      throw new IllegalStateException();
22889
    }
22890
 
22891
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22892
    public boolean isSet(_Fields field) {
22893
      if (field == null) {
22894
        throw new IllegalArgumentException();
22895
      }
22896
 
22897
      switch (field) {
22898
      case SUCCESS:
22899
        return isSetSuccess();
22900
      }
22901
      throw new IllegalStateException();
22902
    }
22903
 
22904
    @Override
22905
    public boolean equals(Object that) {
22906
      if (that == null)
22907
        return false;
22908
      if (that instanceof getItemKeysToBeProcessed_result)
22909
        return this.equals((getItemKeysToBeProcessed_result)that);
22910
      return false;
22911
    }
22912
 
22913
    public boolean equals(getItemKeysToBeProcessed_result that) {
22914
      if (that == null)
22915
        return false;
22916
 
22917
      boolean this_present_success = true && this.isSetSuccess();
22918
      boolean that_present_success = true && that.isSetSuccess();
22919
      if (this_present_success || that_present_success) {
22920
        if (!(this_present_success && that_present_success))
22921
          return false;
22922
        if (!this.success.equals(that.success))
22923
          return false;
22924
      }
22925
 
22926
      return true;
22927
    }
22928
 
22929
    @Override
22930
    public int hashCode() {
22931
      return 0;
22932
    }
22933
 
22934
    public int compareTo(getItemKeysToBeProcessed_result other) {
22935
      if (!getClass().equals(other.getClass())) {
22936
        return getClass().getName().compareTo(other.getClass().getName());
22937
      }
22938
 
22939
      int lastComparison = 0;
22940
      getItemKeysToBeProcessed_result typedOther = (getItemKeysToBeProcessed_result)other;
22941
 
22942
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
22943
      if (lastComparison != 0) {
22944
        return lastComparison;
22945
      }
22946
      if (isSetSuccess()) {
22947
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
22948
        if (lastComparison != 0) {
22949
          return lastComparison;
22950
        }
22951
      }
22952
      return 0;
22953
    }
22954
 
22955
    public _Fields fieldForId(int fieldId) {
22956
      return _Fields.findByThriftId(fieldId);
22957
    }
22958
 
22959
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22960
      org.apache.thrift.protocol.TField field;
22961
      iprot.readStructBegin();
22962
      while (true)
22963
      {
22964
        field = iprot.readFieldBegin();
22965
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22966
          break;
22967
        }
22968
        switch (field.id) {
22969
          case 0: // SUCCESS
22970
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
22971
              {
22972
                org.apache.thrift.protocol.TList _list52 = iprot.readListBegin();
22973
                this.success = new ArrayList<String>(_list52.size);
22974
                for (int _i53 = 0; _i53 < _list52.size; ++_i53)
22975
                {
22976
                  String _elem54; // required
22977
                  _elem54 = iprot.readString();
22978
                  this.success.add(_elem54);
22979
                }
22980
                iprot.readListEnd();
22981
              }
22982
            } else { 
22983
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22984
            }
22985
            break;
22986
          default:
22987
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22988
        }
22989
        iprot.readFieldEnd();
22990
      }
22991
      iprot.readStructEnd();
22992
      validate();
22993
    }
22994
 
22995
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22996
      oprot.writeStructBegin(STRUCT_DESC);
22997
 
22998
      if (this.isSetSuccess()) {
22999
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
23000
        {
23001
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, this.success.size()));
23002
          for (String _iter55 : this.success)
23003
          {
23004
            oprot.writeString(_iter55);
23005
          }
23006
          oprot.writeListEnd();
23007
        }
23008
        oprot.writeFieldEnd();
23009
      }
23010
      oprot.writeFieldStop();
23011
      oprot.writeStructEnd();
23012
    }
23013
 
23014
    @Override
23015
    public String toString() {
23016
      StringBuilder sb = new StringBuilder("getItemKeysToBeProcessed_result(");
23017
      boolean first = true;
23018
 
23019
      sb.append("success:");
23020
      if (this.success == null) {
23021
        sb.append("null");
23022
      } else {
23023
        sb.append(this.success);
23024
      }
23025
      first = false;
23026
      sb.append(")");
23027
      return sb.toString();
23028
    }
23029
 
23030
    public void validate() throws org.apache.thrift.TException {
23031
      // check for required fields
23032
    }
23033
 
23034
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23035
      try {
23036
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23037
      } catch (org.apache.thrift.TException te) {
23038
        throw new java.io.IOException(te);
23039
      }
23040
    }
23041
 
23042
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23043
      try {
23044
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23045
      } catch (org.apache.thrift.TException te) {
23046
        throw new java.io.IOException(te);
23047
      }
23048
    }
23049
 
23050
  }
23051
 
23052
  public static class markMissedInventoryUpdatesAsProcessed_args implements org.apache.thrift.TBase<markMissedInventoryUpdatesAsProcessed_args, markMissedInventoryUpdatesAsProcessed_args._Fields>, java.io.Serializable, Cloneable   {
23053
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markMissedInventoryUpdatesAsProcessed_args");
23054
 
23055
    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);
23056
    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);
23057
 
23058
    private String itemKey; // required
23059
    private long warehouseId; // required
23060
 
23061
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23062
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23063
      ITEM_KEY((short)1, "itemKey"),
23064
      WAREHOUSE_ID((short)2, "warehouseId");
23065
 
23066
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23067
 
23068
      static {
23069
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23070
          byName.put(field.getFieldName(), field);
23071
        }
23072
      }
23073
 
23074
      /**
23075
       * Find the _Fields constant that matches fieldId, or null if its not found.
23076
       */
23077
      public static _Fields findByThriftId(int fieldId) {
23078
        switch(fieldId) {
23079
          case 1: // ITEM_KEY
23080
            return ITEM_KEY;
23081
          case 2: // WAREHOUSE_ID
23082
            return WAREHOUSE_ID;
23083
          default:
23084
            return null;
23085
        }
23086
      }
23087
 
23088
      /**
23089
       * Find the _Fields constant that matches fieldId, throwing an exception
23090
       * if it is not found.
23091
       */
23092
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23093
        _Fields fields = findByThriftId(fieldId);
23094
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23095
        return fields;
23096
      }
23097
 
23098
      /**
23099
       * Find the _Fields constant that matches name, or null if its not found.
23100
       */
23101
      public static _Fields findByName(String name) {
23102
        return byName.get(name);
23103
      }
23104
 
23105
      private final short _thriftId;
23106
      private final String _fieldName;
23107
 
23108
      _Fields(short thriftId, String fieldName) {
23109
        _thriftId = thriftId;
23110
        _fieldName = fieldName;
23111
      }
23112
 
23113
      public short getThriftFieldId() {
23114
        return _thriftId;
23115
      }
23116
 
23117
      public String getFieldName() {
23118
        return _fieldName;
23119
      }
23120
    }
23121
 
23122
    // isset id assignments
23123
    private static final int __WAREHOUSEID_ISSET_ID = 0;
23124
    private BitSet __isset_bit_vector = new BitSet(1);
23125
 
23126
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23127
    static {
23128
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23129
      tmpMap.put(_Fields.ITEM_KEY, new org.apache.thrift.meta_data.FieldMetaData("itemKey", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23130
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
23131
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23132
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
23133
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23134
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markMissedInventoryUpdatesAsProcessed_args.class, metaDataMap);
23135
    }
23136
 
23137
    public markMissedInventoryUpdatesAsProcessed_args() {
23138
    }
23139
 
23140
    public markMissedInventoryUpdatesAsProcessed_args(
23141
      String itemKey,
23142
      long warehouseId)
23143
    {
23144
      this();
23145
      this.itemKey = itemKey;
23146
      this.warehouseId = warehouseId;
23147
      setWarehouseIdIsSet(true);
23148
    }
23149
 
23150
    /**
23151
     * Performs a deep copy on <i>other</i>.
23152
     */
23153
    public markMissedInventoryUpdatesAsProcessed_args(markMissedInventoryUpdatesAsProcessed_args other) {
23154
      __isset_bit_vector.clear();
23155
      __isset_bit_vector.or(other.__isset_bit_vector);
23156
      if (other.isSetItemKey()) {
23157
        this.itemKey = other.itemKey;
23158
      }
23159
      this.warehouseId = other.warehouseId;
23160
    }
23161
 
23162
    public markMissedInventoryUpdatesAsProcessed_args deepCopy() {
23163
      return new markMissedInventoryUpdatesAsProcessed_args(this);
23164
    }
23165
 
23166
    @Override
23167
    public void clear() {
23168
      this.itemKey = null;
23169
      setWarehouseIdIsSet(false);
23170
      this.warehouseId = 0;
23171
    }
23172
 
23173
    public String getItemKey() {
23174
      return this.itemKey;
23175
    }
23176
 
23177
    public void setItemKey(String itemKey) {
23178
      this.itemKey = itemKey;
23179
    }
23180
 
23181
    public void unsetItemKey() {
23182
      this.itemKey = null;
23183
    }
23184
 
23185
    /** Returns true if field itemKey is set (has been assigned a value) and false otherwise */
23186
    public boolean isSetItemKey() {
23187
      return this.itemKey != null;
23188
    }
23189
 
23190
    public void setItemKeyIsSet(boolean value) {
23191
      if (!value) {
23192
        this.itemKey = null;
23193
      }
23194
    }
23195
 
23196
    public long getWarehouseId() {
23197
      return this.warehouseId;
23198
    }
23199
 
23200
    public void setWarehouseId(long warehouseId) {
23201
      this.warehouseId = warehouseId;
23202
      setWarehouseIdIsSet(true);
23203
    }
23204
 
23205
    public void unsetWarehouseId() {
23206
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
23207
    }
23208
 
23209
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
23210
    public boolean isSetWarehouseId() {
23211
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
23212
    }
23213
 
23214
    public void setWarehouseIdIsSet(boolean value) {
23215
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
23216
    }
23217
 
23218
    public void setFieldValue(_Fields field, Object value) {
23219
      switch (field) {
23220
      case ITEM_KEY:
23221
        if (value == null) {
23222
          unsetItemKey();
23223
        } else {
23224
          setItemKey((String)value);
23225
        }
23226
        break;
23227
 
23228
      case WAREHOUSE_ID:
23229
        if (value == null) {
23230
          unsetWarehouseId();
23231
        } else {
23232
          setWarehouseId((Long)value);
23233
        }
23234
        break;
23235
 
23236
      }
23237
    }
23238
 
23239
    public Object getFieldValue(_Fields field) {
23240
      switch (field) {
23241
      case ITEM_KEY:
23242
        return getItemKey();
23243
 
23244
      case WAREHOUSE_ID:
23245
        return Long.valueOf(getWarehouseId());
23246
 
23247
      }
23248
      throw new IllegalStateException();
23249
    }
23250
 
23251
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23252
    public boolean isSet(_Fields field) {
23253
      if (field == null) {
23254
        throw new IllegalArgumentException();
23255
      }
23256
 
23257
      switch (field) {
23258
      case ITEM_KEY:
23259
        return isSetItemKey();
23260
      case WAREHOUSE_ID:
23261
        return isSetWarehouseId();
23262
      }
23263
      throw new IllegalStateException();
23264
    }
23265
 
23266
    @Override
23267
    public boolean equals(Object that) {
23268
      if (that == null)
23269
        return false;
23270
      if (that instanceof markMissedInventoryUpdatesAsProcessed_args)
23271
        return this.equals((markMissedInventoryUpdatesAsProcessed_args)that);
23272
      return false;
23273
    }
23274
 
23275
    public boolean equals(markMissedInventoryUpdatesAsProcessed_args that) {
23276
      if (that == null)
23277
        return false;
23278
 
23279
      boolean this_present_itemKey = true && this.isSetItemKey();
23280
      boolean that_present_itemKey = true && that.isSetItemKey();
23281
      if (this_present_itemKey || that_present_itemKey) {
23282
        if (!(this_present_itemKey && that_present_itemKey))
23283
          return false;
23284
        if (!this.itemKey.equals(that.itemKey))
23285
          return false;
23286
      }
23287
 
23288
      boolean this_present_warehouseId = true;
23289
      boolean that_present_warehouseId = true;
23290
      if (this_present_warehouseId || that_present_warehouseId) {
23291
        if (!(this_present_warehouseId && that_present_warehouseId))
23292
          return false;
23293
        if (this.warehouseId != that.warehouseId)
23294
          return false;
23295
      }
23296
 
23297
      return true;
23298
    }
23299
 
23300
    @Override
23301
    public int hashCode() {
23302
      return 0;
23303
    }
23304
 
23305
    public int compareTo(markMissedInventoryUpdatesAsProcessed_args other) {
23306
      if (!getClass().equals(other.getClass())) {
23307
        return getClass().getName().compareTo(other.getClass().getName());
23308
      }
23309
 
23310
      int lastComparison = 0;
23311
      markMissedInventoryUpdatesAsProcessed_args typedOther = (markMissedInventoryUpdatesAsProcessed_args)other;
23312
 
23313
      lastComparison = Boolean.valueOf(isSetItemKey()).compareTo(typedOther.isSetItemKey());
23314
      if (lastComparison != 0) {
23315
        return lastComparison;
23316
      }
23317
      if (isSetItemKey()) {
23318
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemKey, typedOther.itemKey);
23319
        if (lastComparison != 0) {
23320
          return lastComparison;
23321
        }
23322
      }
23323
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
23324
      if (lastComparison != 0) {
23325
        return lastComparison;
23326
      }
23327
      if (isSetWarehouseId()) {
23328
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
23329
        if (lastComparison != 0) {
23330
          return lastComparison;
23331
        }
23332
      }
23333
      return 0;
23334
    }
23335
 
23336
    public _Fields fieldForId(int fieldId) {
23337
      return _Fields.findByThriftId(fieldId);
23338
    }
23339
 
23340
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23341
      org.apache.thrift.protocol.TField field;
23342
      iprot.readStructBegin();
23343
      while (true)
23344
      {
23345
        field = iprot.readFieldBegin();
23346
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23347
          break;
23348
        }
23349
        switch (field.id) {
23350
          case 1: // ITEM_KEY
23351
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
23352
              this.itemKey = iprot.readString();
23353
            } else { 
23354
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23355
            }
23356
            break;
23357
          case 2: // WAREHOUSE_ID
23358
            if (field.type == org.apache.thrift.protocol.TType.I64) {
23359
              this.warehouseId = iprot.readI64();
23360
              setWarehouseIdIsSet(true);
23361
            } else { 
23362
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23363
            }
23364
            break;
23365
          default:
23366
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23367
        }
23368
        iprot.readFieldEnd();
23369
      }
23370
      iprot.readStructEnd();
23371
      validate();
23372
    }
23373
 
23374
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23375
      validate();
23376
 
23377
      oprot.writeStructBegin(STRUCT_DESC);
23378
      if (this.itemKey != null) {
23379
        oprot.writeFieldBegin(ITEM_KEY_FIELD_DESC);
23380
        oprot.writeString(this.itemKey);
23381
        oprot.writeFieldEnd();
23382
      }
23383
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
23384
      oprot.writeI64(this.warehouseId);
23385
      oprot.writeFieldEnd();
23386
      oprot.writeFieldStop();
23387
      oprot.writeStructEnd();
23388
    }
23389
 
23390
    @Override
23391
    public String toString() {
23392
      StringBuilder sb = new StringBuilder("markMissedInventoryUpdatesAsProcessed_args(");
23393
      boolean first = true;
23394
 
23395
      sb.append("itemKey:");
23396
      if (this.itemKey == null) {
23397
        sb.append("null");
23398
      } else {
23399
        sb.append(this.itemKey);
23400
      }
23401
      first = false;
23402
      if (!first) sb.append(", ");
23403
      sb.append("warehouseId:");
23404
      sb.append(this.warehouseId);
23405
      first = false;
23406
      sb.append(")");
23407
      return sb.toString();
23408
    }
23409
 
23410
    public void validate() throws org.apache.thrift.TException {
23411
      // check for required fields
23412
    }
23413
 
23414
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23415
      try {
23416
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23417
      } catch (org.apache.thrift.TException te) {
23418
        throw new java.io.IOException(te);
23419
      }
23420
    }
23421
 
23422
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23423
      try {
23424
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23425
      } catch (org.apache.thrift.TException te) {
23426
        throw new java.io.IOException(te);
23427
      }
23428
    }
23429
 
23430
  }
23431
 
23432
  public static class markMissedInventoryUpdatesAsProcessed_result implements org.apache.thrift.TBase<markMissedInventoryUpdatesAsProcessed_result, markMissedInventoryUpdatesAsProcessed_result._Fields>, java.io.Serializable, Cloneable   {
23433
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markMissedInventoryUpdatesAsProcessed_result");
23434
 
23435
 
23436
 
23437
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23438
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23439
;
23440
 
23441
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23442
 
23443
      static {
23444
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23445
          byName.put(field.getFieldName(), field);
23446
        }
23447
      }
23448
 
23449
      /**
23450
       * Find the _Fields constant that matches fieldId, or null if its not found.
23451
       */
23452
      public static _Fields findByThriftId(int fieldId) {
23453
        switch(fieldId) {
23454
          default:
23455
            return null;
23456
        }
23457
      }
23458
 
23459
      /**
23460
       * Find the _Fields constant that matches fieldId, throwing an exception
23461
       * if it is not found.
23462
       */
23463
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23464
        _Fields fields = findByThriftId(fieldId);
23465
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23466
        return fields;
23467
      }
23468
 
23469
      /**
23470
       * Find the _Fields constant that matches name, or null if its not found.
23471
       */
23472
      public static _Fields findByName(String name) {
23473
        return byName.get(name);
23474
      }
23475
 
23476
      private final short _thriftId;
23477
      private final String _fieldName;
23478
 
23479
      _Fields(short thriftId, String fieldName) {
23480
        _thriftId = thriftId;
23481
        _fieldName = fieldName;
23482
      }
23483
 
23484
      public short getThriftFieldId() {
23485
        return _thriftId;
23486
      }
23487
 
23488
      public String getFieldName() {
23489
        return _fieldName;
23490
      }
23491
    }
23492
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23493
    static {
23494
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23495
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23496
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markMissedInventoryUpdatesAsProcessed_result.class, metaDataMap);
23497
    }
23498
 
23499
    public markMissedInventoryUpdatesAsProcessed_result() {
23500
    }
23501
 
23502
    /**
23503
     * Performs a deep copy on <i>other</i>.
23504
     */
23505
    public markMissedInventoryUpdatesAsProcessed_result(markMissedInventoryUpdatesAsProcessed_result other) {
23506
    }
23507
 
23508
    public markMissedInventoryUpdatesAsProcessed_result deepCopy() {
23509
      return new markMissedInventoryUpdatesAsProcessed_result(this);
23510
    }
23511
 
23512
    @Override
23513
    public void clear() {
23514
    }
23515
 
23516
    public void setFieldValue(_Fields field, Object value) {
23517
      switch (field) {
23518
      }
23519
    }
23520
 
23521
    public Object getFieldValue(_Fields field) {
23522
      switch (field) {
23523
      }
23524
      throw new IllegalStateException();
23525
    }
23526
 
23527
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23528
    public boolean isSet(_Fields field) {
23529
      if (field == null) {
23530
        throw new IllegalArgumentException();
23531
      }
23532
 
23533
      switch (field) {
23534
      }
23535
      throw new IllegalStateException();
23536
    }
23537
 
23538
    @Override
23539
    public boolean equals(Object that) {
23540
      if (that == null)
23541
        return false;
23542
      if (that instanceof markMissedInventoryUpdatesAsProcessed_result)
23543
        return this.equals((markMissedInventoryUpdatesAsProcessed_result)that);
23544
      return false;
23545
    }
23546
 
23547
    public boolean equals(markMissedInventoryUpdatesAsProcessed_result that) {
23548
      if (that == null)
23549
        return false;
23550
 
23551
      return true;
23552
    }
23553
 
23554
    @Override
23555
    public int hashCode() {
23556
      return 0;
23557
    }
23558
 
23559
    public int compareTo(markMissedInventoryUpdatesAsProcessed_result other) {
23560
      if (!getClass().equals(other.getClass())) {
23561
        return getClass().getName().compareTo(other.getClass().getName());
23562
      }
23563
 
23564
      int lastComparison = 0;
23565
      markMissedInventoryUpdatesAsProcessed_result typedOther = (markMissedInventoryUpdatesAsProcessed_result)other;
23566
 
23567
      return 0;
23568
    }
23569
 
23570
    public _Fields fieldForId(int fieldId) {
23571
      return _Fields.findByThriftId(fieldId);
23572
    }
23573
 
23574
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23575
      org.apache.thrift.protocol.TField field;
23576
      iprot.readStructBegin();
23577
      while (true)
23578
      {
23579
        field = iprot.readFieldBegin();
23580
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23581
          break;
23582
        }
23583
        switch (field.id) {
23584
          default:
23585
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23586
        }
23587
        iprot.readFieldEnd();
23588
      }
23589
      iprot.readStructEnd();
23590
      validate();
23591
    }
23592
 
23593
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23594
      oprot.writeStructBegin(STRUCT_DESC);
23595
 
23596
      oprot.writeFieldStop();
23597
      oprot.writeStructEnd();
23598
    }
23599
 
23600
    @Override
23601
    public String toString() {
23602
      StringBuilder sb = new StringBuilder("markMissedInventoryUpdatesAsProcessed_result(");
23603
      boolean first = true;
23604
 
23605
      sb.append(")");
23606
      return sb.toString();
23607
    }
23608
 
23609
    public void validate() throws org.apache.thrift.TException {
23610
      // check for required fields
23611
    }
23612
 
23613
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23614
      try {
23615
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23616
      } catch (org.apache.thrift.TException te) {
23617
        throw new java.io.IOException(te);
23618
      }
23619
    }
23620
 
23621
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23622
      try {
23623
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23624
      } catch (org.apache.thrift.TException te) {
23625
        throw new java.io.IOException(te);
23626
      }
23627
    }
23628
 
23629
  }
23630
 
23631
  public static class getIgnoredItemKeys_args implements org.apache.thrift.TBase<getIgnoredItemKeys_args, getIgnoredItemKeys_args._Fields>, java.io.Serializable, Cloneable   {
23632
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getIgnoredItemKeys_args");
23633
 
23634
 
23635
 
23636
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23637
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23638
;
23639
 
23640
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23641
 
23642
      static {
23643
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23644
          byName.put(field.getFieldName(), field);
23645
        }
23646
      }
23647
 
23648
      /**
23649
       * Find the _Fields constant that matches fieldId, or null if its not found.
23650
       */
23651
      public static _Fields findByThriftId(int fieldId) {
23652
        switch(fieldId) {
23653
          default:
23654
            return null;
23655
        }
23656
      }
23657
 
23658
      /**
23659
       * Find the _Fields constant that matches fieldId, throwing an exception
23660
       * if it is not found.
23661
       */
23662
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23663
        _Fields fields = findByThriftId(fieldId);
23664
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23665
        return fields;
23666
      }
23667
 
23668
      /**
23669
       * Find the _Fields constant that matches name, or null if its not found.
23670
       */
23671
      public static _Fields findByName(String name) {
23672
        return byName.get(name);
23673
      }
23674
 
23675
      private final short _thriftId;
23676
      private final String _fieldName;
23677
 
23678
      _Fields(short thriftId, String fieldName) {
23679
        _thriftId = thriftId;
23680
        _fieldName = fieldName;
23681
      }
23682
 
23683
      public short getThriftFieldId() {
23684
        return _thriftId;
23685
      }
23686
 
23687
      public String getFieldName() {
23688
        return _fieldName;
23689
      }
23690
    }
23691
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23692
    static {
23693
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23694
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23695
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getIgnoredItemKeys_args.class, metaDataMap);
23696
    }
23697
 
23698
    public getIgnoredItemKeys_args() {
23699
    }
23700
 
23701
    /**
23702
     * Performs a deep copy on <i>other</i>.
23703
     */
23704
    public getIgnoredItemKeys_args(getIgnoredItemKeys_args other) {
23705
    }
23706
 
23707
    public getIgnoredItemKeys_args deepCopy() {
23708
      return new getIgnoredItemKeys_args(this);
23709
    }
23710
 
23711
    @Override
23712
    public void clear() {
23713
    }
23714
 
23715
    public void setFieldValue(_Fields field, Object value) {
23716
      switch (field) {
23717
      }
23718
    }
23719
 
23720
    public Object getFieldValue(_Fields field) {
23721
      switch (field) {
23722
      }
23723
      throw new IllegalStateException();
23724
    }
23725
 
23726
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23727
    public boolean isSet(_Fields field) {
23728
      if (field == null) {
23729
        throw new IllegalArgumentException();
23730
      }
23731
 
23732
      switch (field) {
23733
      }
23734
      throw new IllegalStateException();
23735
    }
23736
 
23737
    @Override
23738
    public boolean equals(Object that) {
23739
      if (that == null)
23740
        return false;
23741
      if (that instanceof getIgnoredItemKeys_args)
23742
        return this.equals((getIgnoredItemKeys_args)that);
23743
      return false;
23744
    }
23745
 
23746
    public boolean equals(getIgnoredItemKeys_args that) {
23747
      if (that == null)
23748
        return false;
23749
 
23750
      return true;
23751
    }
23752
 
23753
    @Override
23754
    public int hashCode() {
23755
      return 0;
23756
    }
23757
 
23758
    public int compareTo(getIgnoredItemKeys_args other) {
23759
      if (!getClass().equals(other.getClass())) {
23760
        return getClass().getName().compareTo(other.getClass().getName());
23761
      }
23762
 
23763
      int lastComparison = 0;
23764
      getIgnoredItemKeys_args typedOther = (getIgnoredItemKeys_args)other;
23765
 
23766
      return 0;
23767
    }
23768
 
23769
    public _Fields fieldForId(int fieldId) {
23770
      return _Fields.findByThriftId(fieldId);
23771
    }
23772
 
23773
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23774
      org.apache.thrift.protocol.TField field;
23775
      iprot.readStructBegin();
23776
      while (true)
23777
      {
23778
        field = iprot.readFieldBegin();
23779
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23780
          break;
23781
        }
23782
        switch (field.id) {
23783
          default:
23784
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23785
        }
23786
        iprot.readFieldEnd();
23787
      }
23788
      iprot.readStructEnd();
23789
      validate();
23790
    }
23791
 
23792
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23793
      validate();
23794
 
23795
      oprot.writeStructBegin(STRUCT_DESC);
23796
      oprot.writeFieldStop();
23797
      oprot.writeStructEnd();
23798
    }
23799
 
23800
    @Override
23801
    public String toString() {
23802
      StringBuilder sb = new StringBuilder("getIgnoredItemKeys_args(");
23803
      boolean first = true;
23804
 
23805
      sb.append(")");
23806
      return sb.toString();
23807
    }
23808
 
23809
    public void validate() throws org.apache.thrift.TException {
23810
      // check for required fields
23811
    }
23812
 
23813
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23814
      try {
23815
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23816
      } catch (org.apache.thrift.TException te) {
23817
        throw new java.io.IOException(te);
23818
      }
23819
    }
23820
 
23821
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23822
      try {
23823
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23824
      } catch (org.apache.thrift.TException te) {
23825
        throw new java.io.IOException(te);
23826
      }
23827
    }
23828
 
23829
  }
23830
 
23831
  public static class getIgnoredItemKeys_result implements org.apache.thrift.TBase<getIgnoredItemKeys_result, getIgnoredItemKeys_result._Fields>, java.io.Serializable, Cloneable   {
23832
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getIgnoredItemKeys_result");
23833
 
23834
    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);
23835
 
23836
    private Map<String,Map<Long,Long>> success; // required
23837
 
23838
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23839
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23840
      SUCCESS((short)0, "success");
23841
 
23842
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23843
 
23844
      static {
23845
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23846
          byName.put(field.getFieldName(), field);
23847
        }
23848
      }
23849
 
23850
      /**
23851
       * Find the _Fields constant that matches fieldId, or null if its not found.
23852
       */
23853
      public static _Fields findByThriftId(int fieldId) {
23854
        switch(fieldId) {
23855
          case 0: // SUCCESS
23856
            return SUCCESS;
23857
          default:
23858
            return null;
23859
        }
23860
      }
23861
 
23862
      /**
23863
       * Find the _Fields constant that matches fieldId, throwing an exception
23864
       * if it is not found.
23865
       */
23866
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23867
        _Fields fields = findByThriftId(fieldId);
23868
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23869
        return fields;
23870
      }
23871
 
23872
      /**
23873
       * Find the _Fields constant that matches name, or null if its not found.
23874
       */
23875
      public static _Fields findByName(String name) {
23876
        return byName.get(name);
23877
      }
23878
 
23879
      private final short _thriftId;
23880
      private final String _fieldName;
23881
 
23882
      _Fields(short thriftId, String fieldName) {
23883
        _thriftId = thriftId;
23884
        _fieldName = fieldName;
23885
      }
23886
 
23887
      public short getThriftFieldId() {
23888
        return _thriftId;
23889
      }
23890
 
23891
      public String getFieldName() {
23892
        return _fieldName;
23893
      }
23894
    }
23895
 
23896
    // isset id assignments
23897
 
23898
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23899
    static {
23900
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23901
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23902
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
23903
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
23904
              new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
23905
                  new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
23906
                  new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)))));
23907
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23908
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getIgnoredItemKeys_result.class, metaDataMap);
23909
    }
23910
 
23911
    public getIgnoredItemKeys_result() {
23912
    }
23913
 
23914
    public getIgnoredItemKeys_result(
23915
      Map<String,Map<Long,Long>> success)
23916
    {
23917
      this();
23918
      this.success = success;
23919
    }
23920
 
23921
    /**
23922
     * Performs a deep copy on <i>other</i>.
23923
     */
23924
    public getIgnoredItemKeys_result(getIgnoredItemKeys_result other) {
23925
      if (other.isSetSuccess()) {
23926
        Map<String,Map<Long,Long>> __this__success = new HashMap<String,Map<Long,Long>>();
23927
        for (Map.Entry<String, Map<Long,Long>> other_element : other.success.entrySet()) {
23928
 
23929
          String other_element_key = other_element.getKey();
23930
          Map<Long,Long> other_element_value = other_element.getValue();
23931
 
23932
          String __this__success_copy_key = other_element_key;
23933
 
23934
          Map<Long,Long> __this__success_copy_value = new HashMap<Long,Long>();
23935
          for (Map.Entry<Long, Long> other_element_value_element : other_element_value.entrySet()) {
23936
 
23937
            Long other_element_value_element_key = other_element_value_element.getKey();
23938
            Long other_element_value_element_value = other_element_value_element.getValue();
23939
 
23940
            Long __this__success_copy_value_copy_key = other_element_value_element_key;
23941
 
23942
            Long __this__success_copy_value_copy_value = other_element_value_element_value;
23943
 
23944
            __this__success_copy_value.put(__this__success_copy_value_copy_key, __this__success_copy_value_copy_value);
23945
          }
23946
 
23947
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
23948
        }
23949
        this.success = __this__success;
23950
      }
23951
    }
23952
 
23953
    public getIgnoredItemKeys_result deepCopy() {
23954
      return new getIgnoredItemKeys_result(this);
23955
    }
23956
 
23957
    @Override
23958
    public void clear() {
23959
      this.success = null;
23960
    }
23961
 
23962
    public int getSuccessSize() {
23963
      return (this.success == null) ? 0 : this.success.size();
23964
    }
23965
 
23966
    public void putToSuccess(String key, Map<Long,Long> val) {
23967
      if (this.success == null) {
23968
        this.success = new HashMap<String,Map<Long,Long>>();
23969
      }
23970
      this.success.put(key, val);
23971
    }
23972
 
23973
    public Map<String,Map<Long,Long>> getSuccess() {
23974
      return this.success;
23975
    }
23976
 
23977
    public void setSuccess(Map<String,Map<Long,Long>> success) {
23978
      this.success = success;
23979
    }
23980
 
23981
    public void unsetSuccess() {
23982
      this.success = null;
23983
    }
23984
 
23985
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
23986
    public boolean isSetSuccess() {
23987
      return this.success != null;
23988
    }
23989
 
23990
    public void setSuccessIsSet(boolean value) {
23991
      if (!value) {
23992
        this.success = null;
23993
      }
23994
    }
23995
 
23996
    public void setFieldValue(_Fields field, Object value) {
23997
      switch (field) {
23998
      case SUCCESS:
23999
        if (value == null) {
24000
          unsetSuccess();
24001
        } else {
24002
          setSuccess((Map<String,Map<Long,Long>>)value);
24003
        }
24004
        break;
24005
 
24006
      }
24007
    }
24008
 
24009
    public Object getFieldValue(_Fields field) {
24010
      switch (field) {
24011
      case SUCCESS:
24012
        return getSuccess();
24013
 
24014
      }
24015
      throw new IllegalStateException();
24016
    }
24017
 
24018
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24019
    public boolean isSet(_Fields field) {
24020
      if (field == null) {
24021
        throw new IllegalArgumentException();
24022
      }
24023
 
24024
      switch (field) {
24025
      case SUCCESS:
24026
        return isSetSuccess();
24027
      }
24028
      throw new IllegalStateException();
24029
    }
24030
 
24031
    @Override
24032
    public boolean equals(Object that) {
24033
      if (that == null)
24034
        return false;
24035
      if (that instanceof getIgnoredItemKeys_result)
24036
        return this.equals((getIgnoredItemKeys_result)that);
24037
      return false;
24038
    }
24039
 
24040
    public boolean equals(getIgnoredItemKeys_result that) {
24041
      if (that == null)
24042
        return false;
24043
 
24044
      boolean this_present_success = true && this.isSetSuccess();
24045
      boolean that_present_success = true && that.isSetSuccess();
24046
      if (this_present_success || that_present_success) {
24047
        if (!(this_present_success && that_present_success))
24048
          return false;
24049
        if (!this.success.equals(that.success))
24050
          return false;
24051
      }
24052
 
24053
      return true;
24054
    }
24055
 
24056
    @Override
24057
    public int hashCode() {
24058
      return 0;
24059
    }
24060
 
24061
    public int compareTo(getIgnoredItemKeys_result other) {
24062
      if (!getClass().equals(other.getClass())) {
24063
        return getClass().getName().compareTo(other.getClass().getName());
24064
      }
24065
 
24066
      int lastComparison = 0;
24067
      getIgnoredItemKeys_result typedOther = (getIgnoredItemKeys_result)other;
24068
 
24069
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
24070
      if (lastComparison != 0) {
24071
        return lastComparison;
24072
      }
24073
      if (isSetSuccess()) {
24074
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
24075
        if (lastComparison != 0) {
24076
          return lastComparison;
24077
        }
24078
      }
24079
      return 0;
24080
    }
24081
 
24082
    public _Fields fieldForId(int fieldId) {
24083
      return _Fields.findByThriftId(fieldId);
24084
    }
24085
 
24086
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24087
      org.apache.thrift.protocol.TField field;
24088
      iprot.readStructBegin();
24089
      while (true)
24090
      {
24091
        field = iprot.readFieldBegin();
24092
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24093
          break;
24094
        }
24095
        switch (field.id) {
24096
          case 0: // SUCCESS
24097
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
24098
              {
24099
                org.apache.thrift.protocol.TMap _map56 = iprot.readMapBegin();
24100
                this.success = new HashMap<String,Map<Long,Long>>(2*_map56.size);
24101
                for (int _i57 = 0; _i57 < _map56.size; ++_i57)
24102
                {
24103
                  String _key58; // required
24104
                  Map<Long,Long> _val59; // required
24105
                  _key58 = iprot.readString();
24106
                  {
24107
                    org.apache.thrift.protocol.TMap _map60 = iprot.readMapBegin();
24108
                    _val59 = new HashMap<Long,Long>(2*_map60.size);
24109
                    for (int _i61 = 0; _i61 < _map60.size; ++_i61)
24110
                    {
24111
                      long _key62; // required
24112
                      long _val63; // required
24113
                      _key62 = iprot.readI64();
24114
                      _val63 = iprot.readI64();
24115
                      _val59.put(_key62, _val63);
24116
                    }
24117
                    iprot.readMapEnd();
24118
                  }
24119
                  this.success.put(_key58, _val59);
24120
                }
24121
                iprot.readMapEnd();
24122
              }
24123
            } else { 
24124
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24125
            }
24126
            break;
24127
          default:
24128
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24129
        }
24130
        iprot.readFieldEnd();
24131
      }
24132
      iprot.readStructEnd();
24133
      validate();
24134
    }
24135
 
24136
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24137
      oprot.writeStructBegin(STRUCT_DESC);
24138
 
24139
      if (this.isSetSuccess()) {
24140
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
24141
        {
24142
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.MAP, this.success.size()));
24143
          for (Map.Entry<String, Map<Long,Long>> _iter64 : this.success.entrySet())
24144
          {
24145
            oprot.writeString(_iter64.getKey());
24146
            {
24147
              oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.I64, _iter64.getValue().size()));
24148
              for (Map.Entry<Long, Long> _iter65 : _iter64.getValue().entrySet())
24149
              {
24150
                oprot.writeI64(_iter65.getKey());
24151
                oprot.writeI64(_iter65.getValue());
24152
              }
24153
              oprot.writeMapEnd();
24154
            }
24155
          }
24156
          oprot.writeMapEnd();
24157
        }
24158
        oprot.writeFieldEnd();
24159
      }
24160
      oprot.writeFieldStop();
24161
      oprot.writeStructEnd();
24162
    }
24163
 
24164
    @Override
24165
    public String toString() {
24166
      StringBuilder sb = new StringBuilder("getIgnoredItemKeys_result(");
24167
      boolean first = true;
24168
 
24169
      sb.append("success:");
24170
      if (this.success == null) {
24171
        sb.append("null");
24172
      } else {
24173
        sb.append(this.success);
24174
      }
24175
      first = false;
24176
      sb.append(")");
24177
      return sb.toString();
24178
    }
24179
 
24180
    public void validate() throws org.apache.thrift.TException {
24181
      // check for required fields
24182
    }
24183
 
24184
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24185
      try {
24186
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24187
      } catch (org.apache.thrift.TException te) {
24188
        throw new java.io.IOException(te);
24189
      }
24190
    }
24191
 
24192
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24193
      try {
24194
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24195
      } catch (org.apache.thrift.TException te) {
24196
        throw new java.io.IOException(te);
24197
      }
24198
    }
24199
 
24200
  }
24201
 
24202
  public static class addBadInventory_args implements org.apache.thrift.TBase<addBadInventory_args, addBadInventory_args._Fields>, java.io.Serializable, Cloneable   {
24203
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addBadInventory_args");
24204
 
24205
    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);
24206
    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);
24207
    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);
24208
 
24209
    private long itemId; // required
24210
    private long warehouseId; // required
24211
    private long quantity; // required
24212
 
24213
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24214
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24215
      ITEM_ID((short)1, "itemId"),
24216
      WAREHOUSE_ID((short)2, "warehouseId"),
24217
      QUANTITY((short)3, "quantity");
24218
 
24219
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24220
 
24221
      static {
24222
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24223
          byName.put(field.getFieldName(), field);
24224
        }
24225
      }
24226
 
24227
      /**
24228
       * Find the _Fields constant that matches fieldId, or null if its not found.
24229
       */
24230
      public static _Fields findByThriftId(int fieldId) {
24231
        switch(fieldId) {
24232
          case 1: // ITEM_ID
24233
            return ITEM_ID;
24234
          case 2: // WAREHOUSE_ID
24235
            return WAREHOUSE_ID;
24236
          case 3: // QUANTITY
24237
            return QUANTITY;
24238
          default:
24239
            return null;
24240
        }
24241
      }
24242
 
24243
      /**
24244
       * Find the _Fields constant that matches fieldId, throwing an exception
24245
       * if it is not found.
24246
       */
24247
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24248
        _Fields fields = findByThriftId(fieldId);
24249
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24250
        return fields;
24251
      }
24252
 
24253
      /**
24254
       * Find the _Fields constant that matches name, or null if its not found.
24255
       */
24256
      public static _Fields findByName(String name) {
24257
        return byName.get(name);
24258
      }
24259
 
24260
      private final short _thriftId;
24261
      private final String _fieldName;
24262
 
24263
      _Fields(short thriftId, String fieldName) {
24264
        _thriftId = thriftId;
24265
        _fieldName = fieldName;
24266
      }
24267
 
24268
      public short getThriftFieldId() {
24269
        return _thriftId;
24270
      }
24271
 
24272
      public String getFieldName() {
24273
        return _fieldName;
24274
      }
24275
    }
24276
 
24277
    // isset id assignments
24278
    private static final int __ITEMID_ISSET_ID = 0;
24279
    private static final int __WAREHOUSEID_ISSET_ID = 1;
24280
    private static final int __QUANTITY_ISSET_ID = 2;
24281
    private BitSet __isset_bit_vector = new BitSet(3);
24282
 
24283
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24284
    static {
24285
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24286
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24287
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24288
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24289
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24290
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24291
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24292
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24293
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addBadInventory_args.class, metaDataMap);
24294
    }
24295
 
24296
    public addBadInventory_args() {
24297
    }
24298
 
24299
    public addBadInventory_args(
24300
      long itemId,
24301
      long warehouseId,
24302
      long quantity)
24303
    {
24304
      this();
24305
      this.itemId = itemId;
24306
      setItemIdIsSet(true);
24307
      this.warehouseId = warehouseId;
24308
      setWarehouseIdIsSet(true);
24309
      this.quantity = quantity;
24310
      setQuantityIsSet(true);
24311
    }
24312
 
24313
    /**
24314
     * Performs a deep copy on <i>other</i>.
24315
     */
24316
    public addBadInventory_args(addBadInventory_args other) {
24317
      __isset_bit_vector.clear();
24318
      __isset_bit_vector.or(other.__isset_bit_vector);
24319
      this.itemId = other.itemId;
24320
      this.warehouseId = other.warehouseId;
24321
      this.quantity = other.quantity;
24322
    }
24323
 
24324
    public addBadInventory_args deepCopy() {
24325
      return new addBadInventory_args(this);
24326
    }
24327
 
24328
    @Override
24329
    public void clear() {
24330
      setItemIdIsSet(false);
24331
      this.itemId = 0;
24332
      setWarehouseIdIsSet(false);
24333
      this.warehouseId = 0;
24334
      setQuantityIsSet(false);
24335
      this.quantity = 0;
24336
    }
24337
 
24338
    public long getItemId() {
24339
      return this.itemId;
24340
    }
24341
 
24342
    public void setItemId(long itemId) {
24343
      this.itemId = itemId;
24344
      setItemIdIsSet(true);
24345
    }
24346
 
24347
    public void unsetItemId() {
24348
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
24349
    }
24350
 
24351
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
24352
    public boolean isSetItemId() {
24353
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
24354
    }
24355
 
24356
    public void setItemIdIsSet(boolean value) {
24357
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
24358
    }
24359
 
24360
    public long getWarehouseId() {
24361
      return this.warehouseId;
24362
    }
24363
 
24364
    public void setWarehouseId(long warehouseId) {
24365
      this.warehouseId = warehouseId;
24366
      setWarehouseIdIsSet(true);
24367
    }
24368
 
24369
    public void unsetWarehouseId() {
24370
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
24371
    }
24372
 
24373
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
24374
    public boolean isSetWarehouseId() {
24375
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
24376
    }
24377
 
24378
    public void setWarehouseIdIsSet(boolean value) {
24379
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
24380
    }
24381
 
24382
    public long getQuantity() {
24383
      return this.quantity;
24384
    }
24385
 
24386
    public void setQuantity(long quantity) {
24387
      this.quantity = quantity;
24388
      setQuantityIsSet(true);
24389
    }
24390
 
24391
    public void unsetQuantity() {
24392
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
24393
    }
24394
 
24395
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
24396
    public boolean isSetQuantity() {
24397
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
24398
    }
24399
 
24400
    public void setQuantityIsSet(boolean value) {
24401
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
24402
    }
24403
 
24404
    public void setFieldValue(_Fields field, Object value) {
24405
      switch (field) {
24406
      case ITEM_ID:
24407
        if (value == null) {
24408
          unsetItemId();
24409
        } else {
24410
          setItemId((Long)value);
24411
        }
24412
        break;
24413
 
24414
      case WAREHOUSE_ID:
24415
        if (value == null) {
24416
          unsetWarehouseId();
24417
        } else {
24418
          setWarehouseId((Long)value);
24419
        }
24420
        break;
24421
 
24422
      case QUANTITY:
24423
        if (value == null) {
24424
          unsetQuantity();
24425
        } else {
24426
          setQuantity((Long)value);
24427
        }
24428
        break;
24429
 
24430
      }
24431
    }
24432
 
24433
    public Object getFieldValue(_Fields field) {
24434
      switch (field) {
24435
      case ITEM_ID:
24436
        return Long.valueOf(getItemId());
24437
 
24438
      case WAREHOUSE_ID:
24439
        return Long.valueOf(getWarehouseId());
24440
 
24441
      case QUANTITY:
24442
        return Long.valueOf(getQuantity());
24443
 
24444
      }
24445
      throw new IllegalStateException();
24446
    }
24447
 
24448
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24449
    public boolean isSet(_Fields field) {
24450
      if (field == null) {
24451
        throw new IllegalArgumentException();
24452
      }
24453
 
24454
      switch (field) {
24455
      case ITEM_ID:
24456
        return isSetItemId();
24457
      case WAREHOUSE_ID:
24458
        return isSetWarehouseId();
24459
      case QUANTITY:
24460
        return isSetQuantity();
24461
      }
24462
      throw new IllegalStateException();
24463
    }
24464
 
24465
    @Override
24466
    public boolean equals(Object that) {
24467
      if (that == null)
24468
        return false;
24469
      if (that instanceof addBadInventory_args)
24470
        return this.equals((addBadInventory_args)that);
24471
      return false;
24472
    }
24473
 
24474
    public boolean equals(addBadInventory_args that) {
24475
      if (that == null)
24476
        return false;
24477
 
24478
      boolean this_present_itemId = true;
24479
      boolean that_present_itemId = true;
24480
      if (this_present_itemId || that_present_itemId) {
24481
        if (!(this_present_itemId && that_present_itemId))
24482
          return false;
24483
        if (this.itemId != that.itemId)
24484
          return false;
24485
      }
24486
 
24487
      boolean this_present_warehouseId = true;
24488
      boolean that_present_warehouseId = true;
24489
      if (this_present_warehouseId || that_present_warehouseId) {
24490
        if (!(this_present_warehouseId && that_present_warehouseId))
24491
          return false;
24492
        if (this.warehouseId != that.warehouseId)
24493
          return false;
24494
      }
24495
 
24496
      boolean this_present_quantity = true;
24497
      boolean that_present_quantity = true;
24498
      if (this_present_quantity || that_present_quantity) {
24499
        if (!(this_present_quantity && that_present_quantity))
24500
          return false;
24501
        if (this.quantity != that.quantity)
24502
          return false;
24503
      }
24504
 
24505
      return true;
24506
    }
24507
 
24508
    @Override
24509
    public int hashCode() {
24510
      return 0;
24511
    }
24512
 
24513
    public int compareTo(addBadInventory_args other) {
24514
      if (!getClass().equals(other.getClass())) {
24515
        return getClass().getName().compareTo(other.getClass().getName());
24516
      }
24517
 
24518
      int lastComparison = 0;
24519
      addBadInventory_args typedOther = (addBadInventory_args)other;
24520
 
24521
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
24522
      if (lastComparison != 0) {
24523
        return lastComparison;
24524
      }
24525
      if (isSetItemId()) {
24526
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
24527
        if (lastComparison != 0) {
24528
          return lastComparison;
24529
        }
24530
      }
24531
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
24532
      if (lastComparison != 0) {
24533
        return lastComparison;
24534
      }
24535
      if (isSetWarehouseId()) {
24536
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
24537
        if (lastComparison != 0) {
24538
          return lastComparison;
24539
        }
24540
      }
24541
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
24542
      if (lastComparison != 0) {
24543
        return lastComparison;
24544
      }
24545
      if (isSetQuantity()) {
24546
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
24547
        if (lastComparison != 0) {
24548
          return lastComparison;
24549
        }
24550
      }
24551
      return 0;
24552
    }
24553
 
24554
    public _Fields fieldForId(int fieldId) {
24555
      return _Fields.findByThriftId(fieldId);
24556
    }
24557
 
24558
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24559
      org.apache.thrift.protocol.TField field;
24560
      iprot.readStructBegin();
24561
      while (true)
24562
      {
24563
        field = iprot.readFieldBegin();
24564
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24565
          break;
24566
        }
24567
        switch (field.id) {
24568
          case 1: // ITEM_ID
24569
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24570
              this.itemId = iprot.readI64();
24571
              setItemIdIsSet(true);
24572
            } else { 
24573
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24574
            }
24575
            break;
24576
          case 2: // WAREHOUSE_ID
24577
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24578
              this.warehouseId = iprot.readI64();
24579
              setWarehouseIdIsSet(true);
24580
            } else { 
24581
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24582
            }
24583
            break;
24584
          case 3: // QUANTITY
24585
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24586
              this.quantity = iprot.readI64();
24587
              setQuantityIsSet(true);
24588
            } else { 
24589
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24590
            }
24591
            break;
24592
          default:
24593
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24594
        }
24595
        iprot.readFieldEnd();
24596
      }
24597
      iprot.readStructEnd();
24598
      validate();
24599
    }
24600
 
24601
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24602
      validate();
24603
 
24604
      oprot.writeStructBegin(STRUCT_DESC);
24605
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
24606
      oprot.writeI64(this.itemId);
24607
      oprot.writeFieldEnd();
24608
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
24609
      oprot.writeI64(this.warehouseId);
24610
      oprot.writeFieldEnd();
24611
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
24612
      oprot.writeI64(this.quantity);
24613
      oprot.writeFieldEnd();
24614
      oprot.writeFieldStop();
24615
      oprot.writeStructEnd();
24616
    }
24617
 
24618
    @Override
24619
    public String toString() {
24620
      StringBuilder sb = new StringBuilder("addBadInventory_args(");
24621
      boolean first = true;
24622
 
24623
      sb.append("itemId:");
24624
      sb.append(this.itemId);
24625
      first = false;
24626
      if (!first) sb.append(", ");
24627
      sb.append("warehouseId:");
24628
      sb.append(this.warehouseId);
24629
      first = false;
24630
      if (!first) sb.append(", ");
24631
      sb.append("quantity:");
24632
      sb.append(this.quantity);
24633
      first = false;
24634
      sb.append(")");
24635
      return sb.toString();
24636
    }
24637
 
24638
    public void validate() throws org.apache.thrift.TException {
24639
      // check for required fields
24640
    }
24641
 
24642
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24643
      try {
24644
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24645
      } catch (org.apache.thrift.TException te) {
24646
        throw new java.io.IOException(te);
24647
      }
24648
    }
24649
 
24650
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24651
      try {
24652
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
24653
        __isset_bit_vector = new BitSet(1);
24654
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24655
      } catch (org.apache.thrift.TException te) {
24656
        throw new java.io.IOException(te);
24657
      }
24658
    }
24659
 
24660
  }
24661
 
24662
  public static class addBadInventory_result implements org.apache.thrift.TBase<addBadInventory_result, addBadInventory_result._Fields>, java.io.Serializable, Cloneable   {
24663
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addBadInventory_result");
24664
 
24665
    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);
24666
 
24667
    private InventoryServiceException cex; // required
24668
 
24669
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24670
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24671
      CEX((short)1, "cex");
24672
 
24673
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24674
 
24675
      static {
24676
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24677
          byName.put(field.getFieldName(), field);
24678
        }
24679
      }
24680
 
24681
      /**
24682
       * Find the _Fields constant that matches fieldId, or null if its not found.
24683
       */
24684
      public static _Fields findByThriftId(int fieldId) {
24685
        switch(fieldId) {
24686
          case 1: // CEX
24687
            return CEX;
24688
          default:
24689
            return null;
24690
        }
24691
      }
24692
 
24693
      /**
24694
       * Find the _Fields constant that matches fieldId, throwing an exception
24695
       * if it is not found.
24696
       */
24697
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24698
        _Fields fields = findByThriftId(fieldId);
24699
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24700
        return fields;
24701
      }
24702
 
24703
      /**
24704
       * Find the _Fields constant that matches name, or null if its not found.
24705
       */
24706
      public static _Fields findByName(String name) {
24707
        return byName.get(name);
24708
      }
24709
 
24710
      private final short _thriftId;
24711
      private final String _fieldName;
24712
 
24713
      _Fields(short thriftId, String fieldName) {
24714
        _thriftId = thriftId;
24715
        _fieldName = fieldName;
24716
      }
24717
 
24718
      public short getThriftFieldId() {
24719
        return _thriftId;
24720
      }
24721
 
24722
      public String getFieldName() {
24723
        return _fieldName;
24724
      }
24725
    }
24726
 
24727
    // isset id assignments
24728
 
24729
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24730
    static {
24731
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24732
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24733
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
24734
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24735
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addBadInventory_result.class, metaDataMap);
24736
    }
24737
 
24738
    public addBadInventory_result() {
24739
    }
24740
 
24741
    public addBadInventory_result(
24742
      InventoryServiceException cex)
24743
    {
24744
      this();
24745
      this.cex = cex;
24746
    }
24747
 
24748
    /**
24749
     * Performs a deep copy on <i>other</i>.
24750
     */
24751
    public addBadInventory_result(addBadInventory_result other) {
24752
      if (other.isSetCex()) {
24753
        this.cex = new InventoryServiceException(other.cex);
24754
      }
24755
    }
24756
 
24757
    public addBadInventory_result deepCopy() {
24758
      return new addBadInventory_result(this);
24759
    }
24760
 
24761
    @Override
24762
    public void clear() {
24763
      this.cex = null;
24764
    }
24765
 
24766
    public InventoryServiceException getCex() {
24767
      return this.cex;
24768
    }
24769
 
24770
    public void setCex(InventoryServiceException cex) {
24771
      this.cex = cex;
24772
    }
24773
 
24774
    public void unsetCex() {
24775
      this.cex = null;
24776
    }
24777
 
24778
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
24779
    public boolean isSetCex() {
24780
      return this.cex != null;
24781
    }
24782
 
24783
    public void setCexIsSet(boolean value) {
24784
      if (!value) {
24785
        this.cex = null;
24786
      }
24787
    }
24788
 
24789
    public void setFieldValue(_Fields field, Object value) {
24790
      switch (field) {
24791
      case CEX:
24792
        if (value == null) {
24793
          unsetCex();
24794
        } else {
24795
          setCex((InventoryServiceException)value);
24796
        }
24797
        break;
24798
 
24799
      }
24800
    }
24801
 
24802
    public Object getFieldValue(_Fields field) {
24803
      switch (field) {
24804
      case CEX:
24805
        return getCex();
24806
 
24807
      }
24808
      throw new IllegalStateException();
24809
    }
24810
 
24811
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24812
    public boolean isSet(_Fields field) {
24813
      if (field == null) {
24814
        throw new IllegalArgumentException();
24815
      }
24816
 
24817
      switch (field) {
24818
      case CEX:
24819
        return isSetCex();
24820
      }
24821
      throw new IllegalStateException();
24822
    }
24823
 
24824
    @Override
24825
    public boolean equals(Object that) {
24826
      if (that == null)
24827
        return false;
24828
      if (that instanceof addBadInventory_result)
24829
        return this.equals((addBadInventory_result)that);
24830
      return false;
24831
    }
24832
 
24833
    public boolean equals(addBadInventory_result that) {
24834
      if (that == null)
24835
        return false;
24836
 
24837
      boolean this_present_cex = true && this.isSetCex();
24838
      boolean that_present_cex = true && that.isSetCex();
24839
      if (this_present_cex || that_present_cex) {
24840
        if (!(this_present_cex && that_present_cex))
24841
          return false;
24842
        if (!this.cex.equals(that.cex))
24843
          return false;
24844
      }
24845
 
24846
      return true;
24847
    }
24848
 
24849
    @Override
24850
    public int hashCode() {
24851
      return 0;
24852
    }
24853
 
24854
    public int compareTo(addBadInventory_result other) {
24855
      if (!getClass().equals(other.getClass())) {
24856
        return getClass().getName().compareTo(other.getClass().getName());
24857
      }
24858
 
24859
      int lastComparison = 0;
24860
      addBadInventory_result typedOther = (addBadInventory_result)other;
24861
 
24862
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
24863
      if (lastComparison != 0) {
24864
        return lastComparison;
24865
      }
24866
      if (isSetCex()) {
24867
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
24868
        if (lastComparison != 0) {
24869
          return lastComparison;
24870
        }
24871
      }
24872
      return 0;
24873
    }
24874
 
24875
    public _Fields fieldForId(int fieldId) {
24876
      return _Fields.findByThriftId(fieldId);
24877
    }
24878
 
24879
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24880
      org.apache.thrift.protocol.TField field;
24881
      iprot.readStructBegin();
24882
      while (true)
24883
      {
24884
        field = iprot.readFieldBegin();
24885
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24886
          break;
24887
        }
24888
        switch (field.id) {
24889
          case 1: // CEX
24890
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
24891
              this.cex = new InventoryServiceException();
24892
              this.cex.read(iprot);
24893
            } else { 
24894
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24895
            }
24896
            break;
24897
          default:
24898
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24899
        }
24900
        iprot.readFieldEnd();
24901
      }
24902
      iprot.readStructEnd();
24903
      validate();
24904
    }
24905
 
24906
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24907
      oprot.writeStructBegin(STRUCT_DESC);
24908
 
24909
      if (this.isSetCex()) {
24910
        oprot.writeFieldBegin(CEX_FIELD_DESC);
24911
        this.cex.write(oprot);
24912
        oprot.writeFieldEnd();
24913
      }
24914
      oprot.writeFieldStop();
24915
      oprot.writeStructEnd();
24916
    }
24917
 
24918
    @Override
24919
    public String toString() {
24920
      StringBuilder sb = new StringBuilder("addBadInventory_result(");
24921
      boolean first = true;
24922
 
24923
      sb.append("cex:");
24924
      if (this.cex == null) {
24925
        sb.append("null");
24926
      } else {
24927
        sb.append(this.cex);
24928
      }
24929
      first = false;
24930
      sb.append(")");
24931
      return sb.toString();
24932
    }
24933
 
24934
    public void validate() throws org.apache.thrift.TException {
24935
      // check for required fields
24936
    }
24937
 
24938
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24939
      try {
24940
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24941
      } catch (org.apache.thrift.TException te) {
24942
        throw new java.io.IOException(te);
24943
      }
24944
    }
24945
 
24946
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24947
      try {
24948
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24949
      } catch (org.apache.thrift.TException te) {
24950
        throw new java.io.IOException(te);
24951
      }
24952
    }
24953
 
24954
  }
24955
 
24956
  public static class getShippingLocations_args implements org.apache.thrift.TBase<getShippingLocations_args, getShippingLocations_args._Fields>, java.io.Serializable, Cloneable   {
24957
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShippingLocations_args");
24958
 
24959
 
24960
 
24961
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24962
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24963
;
24964
 
24965
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24966
 
24967
      static {
24968
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24969
          byName.put(field.getFieldName(), field);
24970
        }
24971
      }
24972
 
24973
      /**
24974
       * Find the _Fields constant that matches fieldId, or null if its not found.
24975
       */
24976
      public static _Fields findByThriftId(int fieldId) {
24977
        switch(fieldId) {
24978
          default:
24979
            return null;
24980
        }
24981
      }
24982
 
24983
      /**
24984
       * Find the _Fields constant that matches fieldId, throwing an exception
24985
       * if it is not found.
24986
       */
24987
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24988
        _Fields fields = findByThriftId(fieldId);
24989
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24990
        return fields;
24991
      }
24992
 
24993
      /**
24994
       * Find the _Fields constant that matches name, or null if its not found.
24995
       */
24996
      public static _Fields findByName(String name) {
24997
        return byName.get(name);
24998
      }
24999
 
25000
      private final short _thriftId;
25001
      private final String _fieldName;
25002
 
25003
      _Fields(short thriftId, String fieldName) {
25004
        _thriftId = thriftId;
25005
        _fieldName = fieldName;
25006
      }
25007
 
25008
      public short getThriftFieldId() {
25009
        return _thriftId;
25010
      }
25011
 
25012
      public String getFieldName() {
25013
        return _fieldName;
25014
      }
25015
    }
25016
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25017
    static {
25018
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25019
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25020
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShippingLocations_args.class, metaDataMap);
25021
    }
25022
 
25023
    public getShippingLocations_args() {
25024
    }
25025
 
25026
    /**
25027
     * Performs a deep copy on <i>other</i>.
25028
     */
25029
    public getShippingLocations_args(getShippingLocations_args other) {
25030
    }
25031
 
25032
    public getShippingLocations_args deepCopy() {
25033
      return new getShippingLocations_args(this);
25034
    }
25035
 
25036
    @Override
25037
    public void clear() {
25038
    }
25039
 
25040
    public void setFieldValue(_Fields field, Object value) {
25041
      switch (field) {
25042
      }
25043
    }
25044
 
25045
    public Object getFieldValue(_Fields field) {
25046
      switch (field) {
25047
      }
25048
      throw new IllegalStateException();
25049
    }
25050
 
25051
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25052
    public boolean isSet(_Fields field) {
25053
      if (field == null) {
25054
        throw new IllegalArgumentException();
25055
      }
25056
 
25057
      switch (field) {
25058
      }
25059
      throw new IllegalStateException();
25060
    }
25061
 
25062
    @Override
25063
    public boolean equals(Object that) {
25064
      if (that == null)
25065
        return false;
25066
      if (that instanceof getShippingLocations_args)
25067
        return this.equals((getShippingLocations_args)that);
25068
      return false;
25069
    }
25070
 
25071
    public boolean equals(getShippingLocations_args that) {
25072
      if (that == null)
25073
        return false;
25074
 
25075
      return true;
25076
    }
25077
 
25078
    @Override
25079
    public int hashCode() {
25080
      return 0;
25081
    }
25082
 
25083
    public int compareTo(getShippingLocations_args other) {
25084
      if (!getClass().equals(other.getClass())) {
25085
        return getClass().getName().compareTo(other.getClass().getName());
25086
      }
25087
 
25088
      int lastComparison = 0;
25089
      getShippingLocations_args typedOther = (getShippingLocations_args)other;
25090
 
25091
      return 0;
25092
    }
25093
 
25094
    public _Fields fieldForId(int fieldId) {
25095
      return _Fields.findByThriftId(fieldId);
25096
    }
25097
 
25098
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25099
      org.apache.thrift.protocol.TField field;
25100
      iprot.readStructBegin();
25101
      while (true)
25102
      {
25103
        field = iprot.readFieldBegin();
25104
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25105
          break;
25106
        }
25107
        switch (field.id) {
25108
          default:
25109
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25110
        }
25111
        iprot.readFieldEnd();
25112
      }
25113
      iprot.readStructEnd();
25114
      validate();
25115
    }
25116
 
25117
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25118
      validate();
25119
 
25120
      oprot.writeStructBegin(STRUCT_DESC);
25121
      oprot.writeFieldStop();
25122
      oprot.writeStructEnd();
25123
    }
25124
 
25125
    @Override
25126
    public String toString() {
25127
      StringBuilder sb = new StringBuilder("getShippingLocations_args(");
25128
      boolean first = true;
25129
 
25130
      sb.append(")");
25131
      return sb.toString();
25132
    }
25133
 
25134
    public void validate() throws org.apache.thrift.TException {
25135
      // check for required fields
25136
    }
25137
 
25138
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25139
      try {
25140
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25141
      } catch (org.apache.thrift.TException te) {
25142
        throw new java.io.IOException(te);
25143
      }
25144
    }
25145
 
25146
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25147
      try {
25148
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25149
      } catch (org.apache.thrift.TException te) {
25150
        throw new java.io.IOException(te);
25151
      }
25152
    }
25153
 
25154
  }
25155
 
25156
  public static class getShippingLocations_result implements org.apache.thrift.TBase<getShippingLocations_result, getShippingLocations_result._Fields>, java.io.Serializable, Cloneable   {
25157
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShippingLocations_result");
25158
 
25159
    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);
25160
 
25161
    private List<Warehouse> success; // required
25162
 
25163
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25164
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25165
      SUCCESS((short)0, "success");
25166
 
25167
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25168
 
25169
      static {
25170
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25171
          byName.put(field.getFieldName(), field);
25172
        }
25173
      }
25174
 
25175
      /**
25176
       * Find the _Fields constant that matches fieldId, or null if its not found.
25177
       */
25178
      public static _Fields findByThriftId(int fieldId) {
25179
        switch(fieldId) {
25180
          case 0: // SUCCESS
25181
            return SUCCESS;
25182
          default:
25183
            return null;
25184
        }
25185
      }
25186
 
25187
      /**
25188
       * Find the _Fields constant that matches fieldId, throwing an exception
25189
       * if it is not found.
25190
       */
25191
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25192
        _Fields fields = findByThriftId(fieldId);
25193
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25194
        return fields;
25195
      }
25196
 
25197
      /**
25198
       * Find the _Fields constant that matches name, or null if its not found.
25199
       */
25200
      public static _Fields findByName(String name) {
25201
        return byName.get(name);
25202
      }
25203
 
25204
      private final short _thriftId;
25205
      private final String _fieldName;
25206
 
25207
      _Fields(short thriftId, String fieldName) {
25208
        _thriftId = thriftId;
25209
        _fieldName = fieldName;
25210
      }
25211
 
25212
      public short getThriftFieldId() {
25213
        return _thriftId;
25214
      }
25215
 
25216
      public String getFieldName() {
25217
        return _fieldName;
25218
      }
25219
    }
25220
 
25221
    // isset id assignments
25222
 
25223
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25224
    static {
25225
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25226
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
25227
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
25228
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
25229
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25230
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShippingLocations_result.class, metaDataMap);
25231
    }
25232
 
25233
    public getShippingLocations_result() {
25234
    }
25235
 
25236
    public getShippingLocations_result(
25237
      List<Warehouse> success)
25238
    {
25239
      this();
25240
      this.success = success;
25241
    }
25242
 
25243
    /**
25244
     * Performs a deep copy on <i>other</i>.
25245
     */
25246
    public getShippingLocations_result(getShippingLocations_result other) {
25247
      if (other.isSetSuccess()) {
25248
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
25249
        for (Warehouse other_element : other.success) {
25250
          __this__success.add(new Warehouse(other_element));
25251
        }
25252
        this.success = __this__success;
25253
      }
25254
    }
25255
 
25256
    public getShippingLocations_result deepCopy() {
25257
      return new getShippingLocations_result(this);
25258
    }
25259
 
25260
    @Override
25261
    public void clear() {
25262
      this.success = null;
25263
    }
25264
 
25265
    public int getSuccessSize() {
25266
      return (this.success == null) ? 0 : this.success.size();
25267
    }
25268
 
25269
    public java.util.Iterator<Warehouse> getSuccessIterator() {
25270
      return (this.success == null) ? null : this.success.iterator();
25271
    }
25272
 
25273
    public void addToSuccess(Warehouse elem) {
25274
      if (this.success == null) {
25275
        this.success = new ArrayList<Warehouse>();
25276
      }
25277
      this.success.add(elem);
25278
    }
25279
 
25280
    public List<Warehouse> getSuccess() {
25281
      return this.success;
25282
    }
25283
 
25284
    public void setSuccess(List<Warehouse> success) {
25285
      this.success = success;
25286
    }
25287
 
25288
    public void unsetSuccess() {
25289
      this.success = null;
25290
    }
25291
 
25292
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
25293
    public boolean isSetSuccess() {
25294
      return this.success != null;
25295
    }
25296
 
25297
    public void setSuccessIsSet(boolean value) {
25298
      if (!value) {
25299
        this.success = null;
25300
      }
25301
    }
25302
 
25303
    public void setFieldValue(_Fields field, Object value) {
25304
      switch (field) {
25305
      case SUCCESS:
25306
        if (value == null) {
25307
          unsetSuccess();
25308
        } else {
25309
          setSuccess((List<Warehouse>)value);
25310
        }
25311
        break;
25312
 
25313
      }
25314
    }
25315
 
25316
    public Object getFieldValue(_Fields field) {
25317
      switch (field) {
25318
      case SUCCESS:
25319
        return getSuccess();
25320
 
25321
      }
25322
      throw new IllegalStateException();
25323
    }
25324
 
25325
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25326
    public boolean isSet(_Fields field) {
25327
      if (field == null) {
25328
        throw new IllegalArgumentException();
25329
      }
25330
 
25331
      switch (field) {
25332
      case SUCCESS:
25333
        return isSetSuccess();
25334
      }
25335
      throw new IllegalStateException();
25336
    }
25337
 
25338
    @Override
25339
    public boolean equals(Object that) {
25340
      if (that == null)
25341
        return false;
25342
      if (that instanceof getShippingLocations_result)
25343
        return this.equals((getShippingLocations_result)that);
25344
      return false;
25345
    }
25346
 
25347
    public boolean equals(getShippingLocations_result that) {
25348
      if (that == null)
25349
        return false;
25350
 
25351
      boolean this_present_success = true && this.isSetSuccess();
25352
      boolean that_present_success = true && that.isSetSuccess();
25353
      if (this_present_success || that_present_success) {
25354
        if (!(this_present_success && that_present_success))
25355
          return false;
25356
        if (!this.success.equals(that.success))
25357
          return false;
25358
      }
25359
 
25360
      return true;
25361
    }
25362
 
25363
    @Override
25364
    public int hashCode() {
25365
      return 0;
25366
    }
25367
 
25368
    public int compareTo(getShippingLocations_result other) {
25369
      if (!getClass().equals(other.getClass())) {
25370
        return getClass().getName().compareTo(other.getClass().getName());
25371
      }
25372
 
25373
      int lastComparison = 0;
25374
      getShippingLocations_result typedOther = (getShippingLocations_result)other;
25375
 
25376
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
25377
      if (lastComparison != 0) {
25378
        return lastComparison;
25379
      }
25380
      if (isSetSuccess()) {
25381
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
25382
        if (lastComparison != 0) {
25383
          return lastComparison;
25384
        }
25385
      }
25386
      return 0;
25387
    }
25388
 
25389
    public _Fields fieldForId(int fieldId) {
25390
      return _Fields.findByThriftId(fieldId);
25391
    }
25392
 
25393
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25394
      org.apache.thrift.protocol.TField field;
25395
      iprot.readStructBegin();
25396
      while (true)
25397
      {
25398
        field = iprot.readFieldBegin();
25399
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25400
          break;
25401
        }
25402
        switch (field.id) {
25403
          case 0: // SUCCESS
25404
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
25405
              {
25406
                org.apache.thrift.protocol.TList _list66 = iprot.readListBegin();
25407
                this.success = new ArrayList<Warehouse>(_list66.size);
25408
                for (int _i67 = 0; _i67 < _list66.size; ++_i67)
25409
                {
25410
                  Warehouse _elem68; // required
25411
                  _elem68 = new Warehouse();
25412
                  _elem68.read(iprot);
25413
                  this.success.add(_elem68);
25414
                }
25415
                iprot.readListEnd();
25416
              }
25417
            } else { 
25418
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25419
            }
25420
            break;
25421
          default:
25422
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25423
        }
25424
        iprot.readFieldEnd();
25425
      }
25426
      iprot.readStructEnd();
25427
      validate();
25428
    }
25429
 
25430
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25431
      oprot.writeStructBegin(STRUCT_DESC);
25432
 
25433
      if (this.isSetSuccess()) {
25434
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
25435
        {
25436
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
25437
          for (Warehouse _iter69 : this.success)
25438
          {
25439
            _iter69.write(oprot);
25440
          }
25441
          oprot.writeListEnd();
25442
        }
25443
        oprot.writeFieldEnd();
25444
      }
25445
      oprot.writeFieldStop();
25446
      oprot.writeStructEnd();
25447
    }
25448
 
25449
    @Override
25450
    public String toString() {
25451
      StringBuilder sb = new StringBuilder("getShippingLocations_result(");
25452
      boolean first = true;
25453
 
25454
      sb.append("success:");
25455
      if (this.success == null) {
25456
        sb.append("null");
25457
      } else {
25458
        sb.append(this.success);
25459
      }
25460
      first = false;
25461
      sb.append(")");
25462
      return sb.toString();
25463
    }
25464
 
25465
    public void validate() throws org.apache.thrift.TException {
25466
      // check for required fields
25467
    }
25468
 
25469
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25470
      try {
25471
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25472
      } catch (org.apache.thrift.TException te) {
25473
        throw new java.io.IOException(te);
25474
      }
25475
    }
25476
 
25477
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25478
      try {
25479
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25480
      } catch (org.apache.thrift.TException te) {
25481
        throw new java.io.IOException(te);
25482
      }
25483
    }
25484
 
25485
  }
25486
 
25487
  public static class getAllVendorItemMappings_args implements org.apache.thrift.TBase<getAllVendorItemMappings_args, getAllVendorItemMappings_args._Fields>, java.io.Serializable, Cloneable   {
25488
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendorItemMappings_args");
25489
 
25490
 
25491
 
25492
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25493
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25494
;
25495
 
25496
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25497
 
25498
      static {
25499
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25500
          byName.put(field.getFieldName(), field);
25501
        }
25502
      }
25503
 
25504
      /**
25505
       * Find the _Fields constant that matches fieldId, or null if its not found.
25506
       */
25507
      public static _Fields findByThriftId(int fieldId) {
25508
        switch(fieldId) {
25509
          default:
25510
            return null;
25511
        }
25512
      }
25513
 
25514
      /**
25515
       * Find the _Fields constant that matches fieldId, throwing an exception
25516
       * if it is not found.
25517
       */
25518
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25519
        _Fields fields = findByThriftId(fieldId);
25520
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25521
        return fields;
25522
      }
25523
 
25524
      /**
25525
       * Find the _Fields constant that matches name, or null if its not found.
25526
       */
25527
      public static _Fields findByName(String name) {
25528
        return byName.get(name);
25529
      }
25530
 
25531
      private final short _thriftId;
25532
      private final String _fieldName;
25533
 
25534
      _Fields(short thriftId, String fieldName) {
25535
        _thriftId = thriftId;
25536
        _fieldName = fieldName;
25537
      }
25538
 
25539
      public short getThriftFieldId() {
25540
        return _thriftId;
25541
      }
25542
 
25543
      public String getFieldName() {
25544
        return _fieldName;
25545
      }
25546
    }
25547
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25548
    static {
25549
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25550
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25551
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendorItemMappings_args.class, metaDataMap);
25552
    }
25553
 
25554
    public getAllVendorItemMappings_args() {
25555
    }
25556
 
25557
    /**
25558
     * Performs a deep copy on <i>other</i>.
25559
     */
25560
    public getAllVendorItemMappings_args(getAllVendorItemMappings_args other) {
25561
    }
25562
 
25563
    public getAllVendorItemMappings_args deepCopy() {
25564
      return new getAllVendorItemMappings_args(this);
25565
    }
25566
 
25567
    @Override
25568
    public void clear() {
25569
    }
25570
 
25571
    public void setFieldValue(_Fields field, Object value) {
25572
      switch (field) {
25573
      }
25574
    }
25575
 
25576
    public Object getFieldValue(_Fields field) {
25577
      switch (field) {
25578
      }
25579
      throw new IllegalStateException();
25580
    }
25581
 
25582
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25583
    public boolean isSet(_Fields field) {
25584
      if (field == null) {
25585
        throw new IllegalArgumentException();
25586
      }
25587
 
25588
      switch (field) {
25589
      }
25590
      throw new IllegalStateException();
25591
    }
25592
 
25593
    @Override
25594
    public boolean equals(Object that) {
25595
      if (that == null)
25596
        return false;
25597
      if (that instanceof getAllVendorItemMappings_args)
25598
        return this.equals((getAllVendorItemMappings_args)that);
25599
      return false;
25600
    }
25601
 
25602
    public boolean equals(getAllVendorItemMappings_args that) {
25603
      if (that == null)
25604
        return false;
25605
 
25606
      return true;
25607
    }
25608
 
25609
    @Override
25610
    public int hashCode() {
25611
      return 0;
25612
    }
25613
 
25614
    public int compareTo(getAllVendorItemMappings_args other) {
25615
      if (!getClass().equals(other.getClass())) {
25616
        return getClass().getName().compareTo(other.getClass().getName());
25617
      }
25618
 
25619
      int lastComparison = 0;
25620
      getAllVendorItemMappings_args typedOther = (getAllVendorItemMappings_args)other;
25621
 
25622
      return 0;
25623
    }
25624
 
25625
    public _Fields fieldForId(int fieldId) {
25626
      return _Fields.findByThriftId(fieldId);
25627
    }
25628
 
25629
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25630
      org.apache.thrift.protocol.TField field;
25631
      iprot.readStructBegin();
25632
      while (true)
25633
      {
25634
        field = iprot.readFieldBegin();
25635
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25636
          break;
25637
        }
25638
        switch (field.id) {
25639
          default:
25640
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25641
        }
25642
        iprot.readFieldEnd();
25643
      }
25644
      iprot.readStructEnd();
25645
      validate();
25646
    }
25647
 
25648
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25649
      validate();
25650
 
25651
      oprot.writeStructBegin(STRUCT_DESC);
25652
      oprot.writeFieldStop();
25653
      oprot.writeStructEnd();
25654
    }
25655
 
25656
    @Override
25657
    public String toString() {
25658
      StringBuilder sb = new StringBuilder("getAllVendorItemMappings_args(");
25659
      boolean first = true;
25660
 
25661
      sb.append(")");
25662
      return sb.toString();
25663
    }
25664
 
25665
    public void validate() throws org.apache.thrift.TException {
25666
      // check for required fields
25667
    }
25668
 
25669
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25670
      try {
25671
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25672
      } catch (org.apache.thrift.TException te) {
25673
        throw new java.io.IOException(te);
25674
      }
25675
    }
25676
 
25677
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25678
      try {
25679
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25680
      } catch (org.apache.thrift.TException te) {
25681
        throw new java.io.IOException(te);
25682
      }
25683
    }
25684
 
25685
  }
25686
 
25687
  public static class getAllVendorItemMappings_result implements org.apache.thrift.TBase<getAllVendorItemMappings_result, getAllVendorItemMappings_result._Fields>, java.io.Serializable, Cloneable   {
25688
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendorItemMappings_result");
25689
 
25690
    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);
25691
 
25692
    private List<VendorItemMapping> success; // required
25693
 
25694
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25695
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25696
      SUCCESS((short)0, "success");
25697
 
25698
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25699
 
25700
      static {
25701
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25702
          byName.put(field.getFieldName(), field);
25703
        }
25704
      }
25705
 
25706
      /**
25707
       * Find the _Fields constant that matches fieldId, or null if its not found.
25708
       */
25709
      public static _Fields findByThriftId(int fieldId) {
25710
        switch(fieldId) {
25711
          case 0: // SUCCESS
25712
            return SUCCESS;
25713
          default:
25714
            return null;
25715
        }
25716
      }
25717
 
25718
      /**
25719
       * Find the _Fields constant that matches fieldId, throwing an exception
25720
       * if it is not found.
25721
       */
25722
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25723
        _Fields fields = findByThriftId(fieldId);
25724
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25725
        return fields;
25726
      }
25727
 
25728
      /**
25729
       * Find the _Fields constant that matches name, or null if its not found.
25730
       */
25731
      public static _Fields findByName(String name) {
25732
        return byName.get(name);
25733
      }
25734
 
25735
      private final short _thriftId;
25736
      private final String _fieldName;
25737
 
25738
      _Fields(short thriftId, String fieldName) {
25739
        _thriftId = thriftId;
25740
        _fieldName = fieldName;
25741
      }
25742
 
25743
      public short getThriftFieldId() {
25744
        return _thriftId;
25745
      }
25746
 
25747
      public String getFieldName() {
25748
        return _fieldName;
25749
      }
25750
    }
25751
 
25752
    // isset id assignments
25753
 
25754
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25755
    static {
25756
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25757
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
25758
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
25759
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class))));
25760
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25761
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendorItemMappings_result.class, metaDataMap);
25762
    }
25763
 
25764
    public getAllVendorItemMappings_result() {
25765
    }
25766
 
25767
    public getAllVendorItemMappings_result(
25768
      List<VendorItemMapping> success)
25769
    {
25770
      this();
25771
      this.success = success;
25772
    }
25773
 
25774
    /**
25775
     * Performs a deep copy on <i>other</i>.
25776
     */
25777
    public getAllVendorItemMappings_result(getAllVendorItemMappings_result other) {
25778
      if (other.isSetSuccess()) {
25779
        List<VendorItemMapping> __this__success = new ArrayList<VendorItemMapping>();
25780
        for (VendorItemMapping other_element : other.success) {
25781
          __this__success.add(new VendorItemMapping(other_element));
25782
        }
25783
        this.success = __this__success;
25784
      }
25785
    }
25786
 
25787
    public getAllVendorItemMappings_result deepCopy() {
25788
      return new getAllVendorItemMappings_result(this);
25789
    }
25790
 
25791
    @Override
25792
    public void clear() {
25793
      this.success = null;
25794
    }
25795
 
25796
    public int getSuccessSize() {
25797
      return (this.success == null) ? 0 : this.success.size();
25798
    }
25799
 
25800
    public java.util.Iterator<VendorItemMapping> getSuccessIterator() {
25801
      return (this.success == null) ? null : this.success.iterator();
25802
    }
25803
 
25804
    public void addToSuccess(VendorItemMapping elem) {
25805
      if (this.success == null) {
25806
        this.success = new ArrayList<VendorItemMapping>();
25807
      }
25808
      this.success.add(elem);
25809
    }
25810
 
25811
    public List<VendorItemMapping> getSuccess() {
25812
      return this.success;
25813
    }
25814
 
25815
    public void setSuccess(List<VendorItemMapping> success) {
25816
      this.success = success;
25817
    }
25818
 
25819
    public void unsetSuccess() {
25820
      this.success = null;
25821
    }
25822
 
25823
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
25824
    public boolean isSetSuccess() {
25825
      return this.success != null;
25826
    }
25827
 
25828
    public void setSuccessIsSet(boolean value) {
25829
      if (!value) {
25830
        this.success = null;
25831
      }
25832
    }
25833
 
25834
    public void setFieldValue(_Fields field, Object value) {
25835
      switch (field) {
25836
      case SUCCESS:
25837
        if (value == null) {
25838
          unsetSuccess();
25839
        } else {
25840
          setSuccess((List<VendorItemMapping>)value);
25841
        }
25842
        break;
25843
 
25844
      }
25845
    }
25846
 
25847
    public Object getFieldValue(_Fields field) {
25848
      switch (field) {
25849
      case SUCCESS:
25850
        return getSuccess();
25851
 
25852
      }
25853
      throw new IllegalStateException();
25854
    }
25855
 
25856
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25857
    public boolean isSet(_Fields field) {
25858
      if (field == null) {
25859
        throw new IllegalArgumentException();
25860
      }
25861
 
25862
      switch (field) {
25863
      case SUCCESS:
25864
        return isSetSuccess();
25865
      }
25866
      throw new IllegalStateException();
25867
    }
25868
 
25869
    @Override
25870
    public boolean equals(Object that) {
25871
      if (that == null)
25872
        return false;
25873
      if (that instanceof getAllVendorItemMappings_result)
25874
        return this.equals((getAllVendorItemMappings_result)that);
25875
      return false;
25876
    }
25877
 
25878
    public boolean equals(getAllVendorItemMappings_result that) {
25879
      if (that == null)
25880
        return false;
25881
 
25882
      boolean this_present_success = true && this.isSetSuccess();
25883
      boolean that_present_success = true && that.isSetSuccess();
25884
      if (this_present_success || that_present_success) {
25885
        if (!(this_present_success && that_present_success))
25886
          return false;
25887
        if (!this.success.equals(that.success))
25888
          return false;
25889
      }
25890
 
25891
      return true;
25892
    }
25893
 
25894
    @Override
25895
    public int hashCode() {
25896
      return 0;
25897
    }
25898
 
25899
    public int compareTo(getAllVendorItemMappings_result other) {
25900
      if (!getClass().equals(other.getClass())) {
25901
        return getClass().getName().compareTo(other.getClass().getName());
25902
      }
25903
 
25904
      int lastComparison = 0;
25905
      getAllVendorItemMappings_result typedOther = (getAllVendorItemMappings_result)other;
25906
 
25907
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
25908
      if (lastComparison != 0) {
25909
        return lastComparison;
25910
      }
25911
      if (isSetSuccess()) {
25912
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
25913
        if (lastComparison != 0) {
25914
          return lastComparison;
25915
        }
25916
      }
25917
      return 0;
25918
    }
25919
 
25920
    public _Fields fieldForId(int fieldId) {
25921
      return _Fields.findByThriftId(fieldId);
25922
    }
25923
 
25924
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25925
      org.apache.thrift.protocol.TField field;
25926
      iprot.readStructBegin();
25927
      while (true)
25928
      {
25929
        field = iprot.readFieldBegin();
25930
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25931
          break;
25932
        }
25933
        switch (field.id) {
25934
          case 0: // SUCCESS
25935
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
25936
              {
25937
                org.apache.thrift.protocol.TList _list70 = iprot.readListBegin();
25938
                this.success = new ArrayList<VendorItemMapping>(_list70.size);
25939
                for (int _i71 = 0; _i71 < _list70.size; ++_i71)
25940
                {
25941
                  VendorItemMapping _elem72; // required
25942
                  _elem72 = new VendorItemMapping();
25943
                  _elem72.read(iprot);
25944
                  this.success.add(_elem72);
25945
                }
25946
                iprot.readListEnd();
25947
              }
25948
            } else { 
25949
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25950
            }
25951
            break;
25952
          default:
25953
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25954
        }
25955
        iprot.readFieldEnd();
25956
      }
25957
      iprot.readStructEnd();
25958
      validate();
25959
    }
25960
 
25961
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25962
      oprot.writeStructBegin(STRUCT_DESC);
25963
 
25964
      if (this.isSetSuccess()) {
25965
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
25966
        {
25967
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
25968
          for (VendorItemMapping _iter73 : this.success)
25969
          {
25970
            _iter73.write(oprot);
25971
          }
25972
          oprot.writeListEnd();
25973
        }
25974
        oprot.writeFieldEnd();
25975
      }
25976
      oprot.writeFieldStop();
25977
      oprot.writeStructEnd();
25978
    }
25979
 
25980
    @Override
25981
    public String toString() {
25982
      StringBuilder sb = new StringBuilder("getAllVendorItemMappings_result(");
25983
      boolean first = true;
25984
 
25985
      sb.append("success:");
25986
      if (this.success == null) {
25987
        sb.append("null");
25988
      } else {
25989
        sb.append(this.success);
25990
      }
25991
      first = false;
25992
      sb.append(")");
25993
      return sb.toString();
25994
    }
25995
 
25996
    public void validate() throws org.apache.thrift.TException {
25997
      // check for required fields
25998
    }
25999
 
26000
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26001
      try {
26002
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26003
      } catch (org.apache.thrift.TException te) {
26004
        throw new java.io.IOException(te);
26005
      }
26006
    }
26007
 
26008
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26009
      try {
26010
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26011
      } catch (org.apache.thrift.TException te) {
26012
        throw new java.io.IOException(te);
26013
      }
26014
    }
26015
 
26016
  }
26017
 
26018
  public static class getInventorySnapshot_args implements org.apache.thrift.TBase<getInventorySnapshot_args, getInventorySnapshot_args._Fields>, java.io.Serializable, Cloneable   {
26019
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventorySnapshot_args");
26020
 
26021
    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);
26022
 
26023
    private long warehouseId; // required
26024
 
26025
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26026
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26027
      WAREHOUSE_ID((short)1, "warehouseId");
26028
 
26029
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26030
 
26031
      static {
26032
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26033
          byName.put(field.getFieldName(), field);
26034
        }
26035
      }
26036
 
26037
      /**
26038
       * Find the _Fields constant that matches fieldId, or null if its not found.
26039
       */
26040
      public static _Fields findByThriftId(int fieldId) {
26041
        switch(fieldId) {
26042
          case 1: // WAREHOUSE_ID
26043
            return WAREHOUSE_ID;
26044
          default:
26045
            return null;
26046
        }
26047
      }
26048
 
26049
      /**
26050
       * Find the _Fields constant that matches fieldId, throwing an exception
26051
       * if it is not found.
26052
       */
26053
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26054
        _Fields fields = findByThriftId(fieldId);
26055
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26056
        return fields;
26057
      }
26058
 
26059
      /**
26060
       * Find the _Fields constant that matches name, or null if its not found.
26061
       */
26062
      public static _Fields findByName(String name) {
26063
        return byName.get(name);
26064
      }
26065
 
26066
      private final short _thriftId;
26067
      private final String _fieldName;
26068
 
26069
      _Fields(short thriftId, String fieldName) {
26070
        _thriftId = thriftId;
26071
        _fieldName = fieldName;
26072
      }
26073
 
26074
      public short getThriftFieldId() {
26075
        return _thriftId;
26076
      }
26077
 
26078
      public String getFieldName() {
26079
        return _fieldName;
26080
      }
26081
    }
26082
 
26083
    // isset id assignments
26084
    private static final int __WAREHOUSEID_ISSET_ID = 0;
26085
    private BitSet __isset_bit_vector = new BitSet(1);
26086
 
26087
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26088
    static {
26089
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26090
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
26091
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
26092
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26093
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventorySnapshot_args.class, metaDataMap);
26094
    }
26095
 
26096
    public getInventorySnapshot_args() {
26097
    }
26098
 
26099
    public getInventorySnapshot_args(
26100
      long warehouseId)
26101
    {
26102
      this();
26103
      this.warehouseId = warehouseId;
26104
      setWarehouseIdIsSet(true);
26105
    }
26106
 
26107
    /**
26108
     * Performs a deep copy on <i>other</i>.
26109
     */
26110
    public getInventorySnapshot_args(getInventorySnapshot_args other) {
26111
      __isset_bit_vector.clear();
26112
      __isset_bit_vector.or(other.__isset_bit_vector);
26113
      this.warehouseId = other.warehouseId;
26114
    }
26115
 
26116
    public getInventorySnapshot_args deepCopy() {
26117
      return new getInventorySnapshot_args(this);
26118
    }
26119
 
26120
    @Override
26121
    public void clear() {
26122
      setWarehouseIdIsSet(false);
26123
      this.warehouseId = 0;
26124
    }
26125
 
26126
    public long getWarehouseId() {
26127
      return this.warehouseId;
26128
    }
26129
 
26130
    public void setWarehouseId(long warehouseId) {
26131
      this.warehouseId = warehouseId;
26132
      setWarehouseIdIsSet(true);
26133
    }
26134
 
26135
    public void unsetWarehouseId() {
26136
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
26137
    }
26138
 
26139
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
26140
    public boolean isSetWarehouseId() {
26141
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
26142
    }
26143
 
26144
    public void setWarehouseIdIsSet(boolean value) {
26145
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
26146
    }
26147
 
26148
    public void setFieldValue(_Fields field, Object value) {
26149
      switch (field) {
26150
      case WAREHOUSE_ID:
26151
        if (value == null) {
26152
          unsetWarehouseId();
26153
        } else {
26154
          setWarehouseId((Long)value);
26155
        }
26156
        break;
26157
 
26158
      }
26159
    }
26160
 
26161
    public Object getFieldValue(_Fields field) {
26162
      switch (field) {
26163
      case WAREHOUSE_ID:
26164
        return Long.valueOf(getWarehouseId());
26165
 
26166
      }
26167
      throw new IllegalStateException();
26168
    }
26169
 
26170
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26171
    public boolean isSet(_Fields field) {
26172
      if (field == null) {
26173
        throw new IllegalArgumentException();
26174
      }
26175
 
26176
      switch (field) {
26177
      case WAREHOUSE_ID:
26178
        return isSetWarehouseId();
26179
      }
26180
      throw new IllegalStateException();
26181
    }
26182
 
26183
    @Override
26184
    public boolean equals(Object that) {
26185
      if (that == null)
26186
        return false;
26187
      if (that instanceof getInventorySnapshot_args)
26188
        return this.equals((getInventorySnapshot_args)that);
26189
      return false;
26190
    }
26191
 
26192
    public boolean equals(getInventorySnapshot_args that) {
26193
      if (that == null)
26194
        return false;
26195
 
26196
      boolean this_present_warehouseId = true;
26197
      boolean that_present_warehouseId = true;
26198
      if (this_present_warehouseId || that_present_warehouseId) {
26199
        if (!(this_present_warehouseId && that_present_warehouseId))
26200
          return false;
26201
        if (this.warehouseId != that.warehouseId)
26202
          return false;
26203
      }
26204
 
26205
      return true;
26206
    }
26207
 
26208
    @Override
26209
    public int hashCode() {
26210
      return 0;
26211
    }
26212
 
26213
    public int compareTo(getInventorySnapshot_args other) {
26214
      if (!getClass().equals(other.getClass())) {
26215
        return getClass().getName().compareTo(other.getClass().getName());
26216
      }
26217
 
26218
      int lastComparison = 0;
26219
      getInventorySnapshot_args typedOther = (getInventorySnapshot_args)other;
26220
 
26221
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
26222
      if (lastComparison != 0) {
26223
        return lastComparison;
26224
      }
26225
      if (isSetWarehouseId()) {
26226
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
26227
        if (lastComparison != 0) {
26228
          return lastComparison;
26229
        }
26230
      }
26231
      return 0;
26232
    }
26233
 
26234
    public _Fields fieldForId(int fieldId) {
26235
      return _Fields.findByThriftId(fieldId);
26236
    }
26237
 
26238
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26239
      org.apache.thrift.protocol.TField field;
26240
      iprot.readStructBegin();
26241
      while (true)
26242
      {
26243
        field = iprot.readFieldBegin();
26244
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26245
          break;
26246
        }
26247
        switch (field.id) {
26248
          case 1: // WAREHOUSE_ID
26249
            if (field.type == org.apache.thrift.protocol.TType.I64) {
26250
              this.warehouseId = iprot.readI64();
26251
              setWarehouseIdIsSet(true);
26252
            } else { 
26253
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26254
            }
26255
            break;
26256
          default:
26257
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26258
        }
26259
        iprot.readFieldEnd();
26260
      }
26261
      iprot.readStructEnd();
26262
      validate();
26263
    }
26264
 
26265
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26266
      validate();
26267
 
26268
      oprot.writeStructBegin(STRUCT_DESC);
26269
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
26270
      oprot.writeI64(this.warehouseId);
26271
      oprot.writeFieldEnd();
26272
      oprot.writeFieldStop();
26273
      oprot.writeStructEnd();
26274
    }
26275
 
26276
    @Override
26277
    public String toString() {
26278
      StringBuilder sb = new StringBuilder("getInventorySnapshot_args(");
26279
      boolean first = true;
26280
 
26281
      sb.append("warehouseId:");
26282
      sb.append(this.warehouseId);
26283
      first = false;
26284
      sb.append(")");
26285
      return sb.toString();
26286
    }
26287
 
26288
    public void validate() throws org.apache.thrift.TException {
26289
      // check for required fields
26290
    }
26291
 
26292
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26293
      try {
26294
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26295
      } catch (org.apache.thrift.TException te) {
26296
        throw new java.io.IOException(te);
26297
      }
26298
    }
26299
 
26300
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26301
      try {
26302
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
26303
        __isset_bit_vector = new BitSet(1);
26304
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26305
      } catch (org.apache.thrift.TException te) {
26306
        throw new java.io.IOException(te);
26307
      }
26308
    }
26309
 
26310
  }
26311
 
26312
  public static class getInventorySnapshot_result implements org.apache.thrift.TBase<getInventorySnapshot_result, getInventorySnapshot_result._Fields>, java.io.Serializable, Cloneable   {
26313
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventorySnapshot_result");
26314
 
26315
    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);
26316
 
26317
    private Map<Long,ItemInventory> success; // required
26318
 
26319
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26320
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26321
      SUCCESS((short)0, "success");
26322
 
26323
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26324
 
26325
      static {
26326
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26327
          byName.put(field.getFieldName(), field);
26328
        }
26329
      }
26330
 
26331
      /**
26332
       * Find the _Fields constant that matches fieldId, or null if its not found.
26333
       */
26334
      public static _Fields findByThriftId(int fieldId) {
26335
        switch(fieldId) {
26336
          case 0: // SUCCESS
26337
            return SUCCESS;
26338
          default:
26339
            return null;
26340
        }
26341
      }
26342
 
26343
      /**
26344
       * Find the _Fields constant that matches fieldId, throwing an exception
26345
       * if it is not found.
26346
       */
26347
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26348
        _Fields fields = findByThriftId(fieldId);
26349
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26350
        return fields;
26351
      }
26352
 
26353
      /**
26354
       * Find the _Fields constant that matches name, or null if its not found.
26355
       */
26356
      public static _Fields findByName(String name) {
26357
        return byName.get(name);
26358
      }
26359
 
26360
      private final short _thriftId;
26361
      private final String _fieldName;
26362
 
26363
      _Fields(short thriftId, String fieldName) {
26364
        _thriftId = thriftId;
26365
        _fieldName = fieldName;
26366
      }
26367
 
26368
      public short getThriftFieldId() {
26369
        return _thriftId;
26370
      }
26371
 
26372
      public String getFieldName() {
26373
        return _fieldName;
26374
      }
26375
    }
26376
 
26377
    // isset id assignments
26378
 
26379
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26380
    static {
26381
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26382
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
26383
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
26384
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
26385
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ItemInventory.class))));
26386
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26387
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventorySnapshot_result.class, metaDataMap);
26388
    }
26389
 
26390
    public getInventorySnapshot_result() {
26391
    }
26392
 
26393
    public getInventorySnapshot_result(
26394
      Map<Long,ItemInventory> success)
26395
    {
26396
      this();
26397
      this.success = success;
26398
    }
26399
 
26400
    /**
26401
     * Performs a deep copy on <i>other</i>.
26402
     */
26403
    public getInventorySnapshot_result(getInventorySnapshot_result other) {
26404
      if (other.isSetSuccess()) {
26405
        Map<Long,ItemInventory> __this__success = new HashMap<Long,ItemInventory>();
26406
        for (Map.Entry<Long, ItemInventory> other_element : other.success.entrySet()) {
26407
 
26408
          Long other_element_key = other_element.getKey();
26409
          ItemInventory other_element_value = other_element.getValue();
26410
 
26411
          Long __this__success_copy_key = other_element_key;
26412
 
26413
          ItemInventory __this__success_copy_value = new ItemInventory(other_element_value);
26414
 
26415
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
26416
        }
26417
        this.success = __this__success;
26418
      }
26419
    }
26420
 
26421
    public getInventorySnapshot_result deepCopy() {
26422
      return new getInventorySnapshot_result(this);
26423
    }
26424
 
26425
    @Override
26426
    public void clear() {
26427
      this.success = null;
26428
    }
26429
 
26430
    public int getSuccessSize() {
26431
      return (this.success == null) ? 0 : this.success.size();
26432
    }
26433
 
26434
    public void putToSuccess(long key, ItemInventory val) {
26435
      if (this.success == null) {
26436
        this.success = new HashMap<Long,ItemInventory>();
26437
      }
26438
      this.success.put(key, val);
26439
    }
26440
 
26441
    public Map<Long,ItemInventory> getSuccess() {
26442
      return this.success;
26443
    }
26444
 
26445
    public void setSuccess(Map<Long,ItemInventory> success) {
26446
      this.success = success;
26447
    }
26448
 
26449
    public void unsetSuccess() {
26450
      this.success = null;
26451
    }
26452
 
26453
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
26454
    public boolean isSetSuccess() {
26455
      return this.success != null;
26456
    }
26457
 
26458
    public void setSuccessIsSet(boolean value) {
26459
      if (!value) {
26460
        this.success = null;
26461
      }
26462
    }
26463
 
26464
    public void setFieldValue(_Fields field, Object value) {
26465
      switch (field) {
26466
      case SUCCESS:
26467
        if (value == null) {
26468
          unsetSuccess();
26469
        } else {
26470
          setSuccess((Map<Long,ItemInventory>)value);
26471
        }
26472
        break;
26473
 
26474
      }
26475
    }
26476
 
26477
    public Object getFieldValue(_Fields field) {
26478
      switch (field) {
26479
      case SUCCESS:
26480
        return getSuccess();
26481
 
26482
      }
26483
      throw new IllegalStateException();
26484
    }
26485
 
26486
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26487
    public boolean isSet(_Fields field) {
26488
      if (field == null) {
26489
        throw new IllegalArgumentException();
26490
      }
26491
 
26492
      switch (field) {
26493
      case SUCCESS:
26494
        return isSetSuccess();
26495
      }
26496
      throw new IllegalStateException();
26497
    }
26498
 
26499
    @Override
26500
    public boolean equals(Object that) {
26501
      if (that == null)
26502
        return false;
26503
      if (that instanceof getInventorySnapshot_result)
26504
        return this.equals((getInventorySnapshot_result)that);
26505
      return false;
26506
    }
26507
 
26508
    public boolean equals(getInventorySnapshot_result that) {
26509
      if (that == null)
26510
        return false;
26511
 
26512
      boolean this_present_success = true && this.isSetSuccess();
26513
      boolean that_present_success = true && that.isSetSuccess();
26514
      if (this_present_success || that_present_success) {
26515
        if (!(this_present_success && that_present_success))
26516
          return false;
26517
        if (!this.success.equals(that.success))
26518
          return false;
26519
      }
26520
 
26521
      return true;
26522
    }
26523
 
26524
    @Override
26525
    public int hashCode() {
26526
      return 0;
26527
    }
26528
 
26529
    public int compareTo(getInventorySnapshot_result other) {
26530
      if (!getClass().equals(other.getClass())) {
26531
        return getClass().getName().compareTo(other.getClass().getName());
26532
      }
26533
 
26534
      int lastComparison = 0;
26535
      getInventorySnapshot_result typedOther = (getInventorySnapshot_result)other;
26536
 
26537
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
26538
      if (lastComparison != 0) {
26539
        return lastComparison;
26540
      }
26541
      if (isSetSuccess()) {
26542
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
26543
        if (lastComparison != 0) {
26544
          return lastComparison;
26545
        }
26546
      }
26547
      return 0;
26548
    }
26549
 
26550
    public _Fields fieldForId(int fieldId) {
26551
      return _Fields.findByThriftId(fieldId);
26552
    }
26553
 
26554
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26555
      org.apache.thrift.protocol.TField field;
26556
      iprot.readStructBegin();
26557
      while (true)
26558
      {
26559
        field = iprot.readFieldBegin();
26560
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26561
          break;
26562
        }
26563
        switch (field.id) {
26564
          case 0: // SUCCESS
26565
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
26566
              {
26567
                org.apache.thrift.protocol.TMap _map74 = iprot.readMapBegin();
26568
                this.success = new HashMap<Long,ItemInventory>(2*_map74.size);
26569
                for (int _i75 = 0; _i75 < _map74.size; ++_i75)
26570
                {
26571
                  long _key76; // required
26572
                  ItemInventory _val77; // required
26573
                  _key76 = iprot.readI64();
26574
                  _val77 = new ItemInventory();
26575
                  _val77.read(iprot);
26576
                  this.success.put(_key76, _val77);
26577
                }
26578
                iprot.readMapEnd();
26579
              }
26580
            } else { 
26581
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26582
            }
26583
            break;
26584
          default:
26585
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26586
        }
26587
        iprot.readFieldEnd();
26588
      }
26589
      iprot.readStructEnd();
26590
      validate();
26591
    }
26592
 
26593
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26594
      oprot.writeStructBegin(STRUCT_DESC);
26595
 
26596
      if (this.isSetSuccess()) {
26597
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
26598
        {
26599
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
26600
          for (Map.Entry<Long, ItemInventory> _iter78 : this.success.entrySet())
26601
          {
26602
            oprot.writeI64(_iter78.getKey());
26603
            _iter78.getValue().write(oprot);
26604
          }
26605
          oprot.writeMapEnd();
26606
        }
26607
        oprot.writeFieldEnd();
26608
      }
26609
      oprot.writeFieldStop();
26610
      oprot.writeStructEnd();
26611
    }
26612
 
26613
    @Override
26614
    public String toString() {
26615
      StringBuilder sb = new StringBuilder("getInventorySnapshot_result(");
26616
      boolean first = true;
26617
 
26618
      sb.append("success:");
26619
      if (this.success == null) {
26620
        sb.append("null");
26621
      } else {
26622
        sb.append(this.success);
26623
      }
26624
      first = false;
26625
      sb.append(")");
26626
      return sb.toString();
26627
    }
26628
 
26629
    public void validate() throws org.apache.thrift.TException {
26630
      // check for required fields
26631
    }
26632
 
26633
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26634
      try {
26635
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26636
      } catch (org.apache.thrift.TException te) {
26637
        throw new java.io.IOException(te);
26638
      }
26639
    }
26640
 
26641
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26642
      try {
26643
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26644
      } catch (org.apache.thrift.TException te) {
26645
        throw new java.io.IOException(te);
26646
      }
26647
    }
26648
 
26649
  }
26650
 
26651
  public static class clearItemAvailabilityCache_args implements org.apache.thrift.TBase<clearItemAvailabilityCache_args, clearItemAvailabilityCache_args._Fields>, java.io.Serializable, Cloneable   {
26652
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCache_args");
26653
 
26654
 
26655
 
26656
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26657
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26658
;
26659
 
26660
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26661
 
26662
      static {
26663
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26664
          byName.put(field.getFieldName(), field);
26665
        }
26666
      }
26667
 
26668
      /**
26669
       * Find the _Fields constant that matches fieldId, or null if its not found.
26670
       */
26671
      public static _Fields findByThriftId(int fieldId) {
26672
        switch(fieldId) {
26673
          default:
26674
            return null;
26675
        }
26676
      }
26677
 
26678
      /**
26679
       * Find the _Fields constant that matches fieldId, throwing an exception
26680
       * if it is not found.
26681
       */
26682
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26683
        _Fields fields = findByThriftId(fieldId);
26684
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26685
        return fields;
26686
      }
26687
 
26688
      /**
26689
       * Find the _Fields constant that matches name, or null if its not found.
26690
       */
26691
      public static _Fields findByName(String name) {
26692
        return byName.get(name);
26693
      }
26694
 
26695
      private final short _thriftId;
26696
      private final String _fieldName;
26697
 
26698
      _Fields(short thriftId, String fieldName) {
26699
        _thriftId = thriftId;
26700
        _fieldName = fieldName;
26701
      }
26702
 
26703
      public short getThriftFieldId() {
26704
        return _thriftId;
26705
      }
26706
 
26707
      public String getFieldName() {
26708
        return _fieldName;
26709
      }
26710
    }
26711
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26712
    static {
26713
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26714
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26715
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCache_args.class, metaDataMap);
26716
    }
26717
 
26718
    public clearItemAvailabilityCache_args() {
26719
    }
26720
 
26721
    /**
26722
     * Performs a deep copy on <i>other</i>.
26723
     */
26724
    public clearItemAvailabilityCache_args(clearItemAvailabilityCache_args other) {
26725
    }
26726
 
26727
    public clearItemAvailabilityCache_args deepCopy() {
26728
      return new clearItemAvailabilityCache_args(this);
26729
    }
26730
 
26731
    @Override
26732
    public void clear() {
26733
    }
26734
 
26735
    public void setFieldValue(_Fields field, Object value) {
26736
      switch (field) {
26737
      }
26738
    }
26739
 
26740
    public Object getFieldValue(_Fields field) {
26741
      switch (field) {
26742
      }
26743
      throw new IllegalStateException();
26744
    }
26745
 
26746
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26747
    public boolean isSet(_Fields field) {
26748
      if (field == null) {
26749
        throw new IllegalArgumentException();
26750
      }
26751
 
26752
      switch (field) {
26753
      }
26754
      throw new IllegalStateException();
26755
    }
26756
 
26757
    @Override
26758
    public boolean equals(Object that) {
26759
      if (that == null)
26760
        return false;
26761
      if (that instanceof clearItemAvailabilityCache_args)
26762
        return this.equals((clearItemAvailabilityCache_args)that);
26763
      return false;
26764
    }
26765
 
26766
    public boolean equals(clearItemAvailabilityCache_args that) {
26767
      if (that == null)
26768
        return false;
26769
 
26770
      return true;
26771
    }
26772
 
26773
    @Override
26774
    public int hashCode() {
26775
      return 0;
26776
    }
26777
 
26778
    public int compareTo(clearItemAvailabilityCache_args other) {
26779
      if (!getClass().equals(other.getClass())) {
26780
        return getClass().getName().compareTo(other.getClass().getName());
26781
      }
26782
 
26783
      int lastComparison = 0;
26784
      clearItemAvailabilityCache_args typedOther = (clearItemAvailabilityCache_args)other;
26785
 
26786
      return 0;
26787
    }
26788
 
26789
    public _Fields fieldForId(int fieldId) {
26790
      return _Fields.findByThriftId(fieldId);
26791
    }
26792
 
26793
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26794
      org.apache.thrift.protocol.TField field;
26795
      iprot.readStructBegin();
26796
      while (true)
26797
      {
26798
        field = iprot.readFieldBegin();
26799
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26800
          break;
26801
        }
26802
        switch (field.id) {
26803
          default:
26804
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26805
        }
26806
        iprot.readFieldEnd();
26807
      }
26808
      iprot.readStructEnd();
26809
      validate();
26810
    }
26811
 
26812
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26813
      validate();
26814
 
26815
      oprot.writeStructBegin(STRUCT_DESC);
26816
      oprot.writeFieldStop();
26817
      oprot.writeStructEnd();
26818
    }
26819
 
26820
    @Override
26821
    public String toString() {
26822
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCache_args(");
26823
      boolean first = true;
26824
 
26825
      sb.append(")");
26826
      return sb.toString();
26827
    }
26828
 
26829
    public void validate() throws org.apache.thrift.TException {
26830
      // check for required fields
26831
    }
26832
 
26833
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26834
      try {
26835
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26836
      } catch (org.apache.thrift.TException te) {
26837
        throw new java.io.IOException(te);
26838
      }
26839
    }
26840
 
26841
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26842
      try {
26843
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26844
      } catch (org.apache.thrift.TException te) {
26845
        throw new java.io.IOException(te);
26846
      }
26847
    }
26848
 
26849
  }
26850
 
26851
  public static class clearItemAvailabilityCache_result implements org.apache.thrift.TBase<clearItemAvailabilityCache_result, clearItemAvailabilityCache_result._Fields>, java.io.Serializable, Cloneable   {
26852
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCache_result");
26853
 
26854
 
26855
 
26856
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26857
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26858
;
26859
 
26860
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26861
 
26862
      static {
26863
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26864
          byName.put(field.getFieldName(), field);
26865
        }
26866
      }
26867
 
26868
      /**
26869
       * Find the _Fields constant that matches fieldId, or null if its not found.
26870
       */
26871
      public static _Fields findByThriftId(int fieldId) {
26872
        switch(fieldId) {
26873
          default:
26874
            return null;
26875
        }
26876
      }
26877
 
26878
      /**
26879
       * Find the _Fields constant that matches fieldId, throwing an exception
26880
       * if it is not found.
26881
       */
26882
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26883
        _Fields fields = findByThriftId(fieldId);
26884
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26885
        return fields;
26886
      }
26887
 
26888
      /**
26889
       * Find the _Fields constant that matches name, or null if its not found.
26890
       */
26891
      public static _Fields findByName(String name) {
26892
        return byName.get(name);
26893
      }
26894
 
26895
      private final short _thriftId;
26896
      private final String _fieldName;
26897
 
26898
      _Fields(short thriftId, String fieldName) {
26899
        _thriftId = thriftId;
26900
        _fieldName = fieldName;
26901
      }
26902
 
26903
      public short getThriftFieldId() {
26904
        return _thriftId;
26905
      }
26906
 
26907
      public String getFieldName() {
26908
        return _fieldName;
26909
      }
26910
    }
26911
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26912
    static {
26913
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26914
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26915
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCache_result.class, metaDataMap);
26916
    }
26917
 
26918
    public clearItemAvailabilityCache_result() {
26919
    }
26920
 
26921
    /**
26922
     * Performs a deep copy on <i>other</i>.
26923
     */
26924
    public clearItemAvailabilityCache_result(clearItemAvailabilityCache_result other) {
26925
    }
26926
 
26927
    public clearItemAvailabilityCache_result deepCopy() {
26928
      return new clearItemAvailabilityCache_result(this);
26929
    }
26930
 
26931
    @Override
26932
    public void clear() {
26933
    }
26934
 
26935
    public void setFieldValue(_Fields field, Object value) {
26936
      switch (field) {
26937
      }
26938
    }
26939
 
26940
    public Object getFieldValue(_Fields field) {
26941
      switch (field) {
26942
      }
26943
      throw new IllegalStateException();
26944
    }
26945
 
26946
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26947
    public boolean isSet(_Fields field) {
26948
      if (field == null) {
26949
        throw new IllegalArgumentException();
26950
      }
26951
 
26952
      switch (field) {
26953
      }
26954
      throw new IllegalStateException();
26955
    }
26956
 
26957
    @Override
26958
    public boolean equals(Object that) {
26959
      if (that == null)
26960
        return false;
26961
      if (that instanceof clearItemAvailabilityCache_result)
26962
        return this.equals((clearItemAvailabilityCache_result)that);
26963
      return false;
26964
    }
26965
 
26966
    public boolean equals(clearItemAvailabilityCache_result that) {
26967
      if (that == null)
26968
        return false;
26969
 
26970
      return true;
26971
    }
26972
 
26973
    @Override
26974
    public int hashCode() {
26975
      return 0;
26976
    }
26977
 
26978
    public int compareTo(clearItemAvailabilityCache_result other) {
26979
      if (!getClass().equals(other.getClass())) {
26980
        return getClass().getName().compareTo(other.getClass().getName());
26981
      }
26982
 
26983
      int lastComparison = 0;
26984
      clearItemAvailabilityCache_result typedOther = (clearItemAvailabilityCache_result)other;
26985
 
26986
      return 0;
26987
    }
26988
 
26989
    public _Fields fieldForId(int fieldId) {
26990
      return _Fields.findByThriftId(fieldId);
26991
    }
26992
 
26993
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26994
      org.apache.thrift.protocol.TField field;
26995
      iprot.readStructBegin();
26996
      while (true)
26997
      {
26998
        field = iprot.readFieldBegin();
26999
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
27000
          break;
27001
        }
27002
        switch (field.id) {
27003
          default:
27004
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27005
        }
27006
        iprot.readFieldEnd();
27007
      }
27008
      iprot.readStructEnd();
27009
      validate();
27010
    }
27011
 
27012
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
27013
      oprot.writeStructBegin(STRUCT_DESC);
27014
 
27015
      oprot.writeFieldStop();
27016
      oprot.writeStructEnd();
27017
    }
27018
 
27019
    @Override
27020
    public String toString() {
27021
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCache_result(");
27022
      boolean first = true;
27023
 
27024
      sb.append(")");
27025
      return sb.toString();
27026
    }
27027
 
27028
    public void validate() throws org.apache.thrift.TException {
27029
      // check for required fields
27030
    }
27031
 
27032
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
27033
      try {
27034
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
27035
      } catch (org.apache.thrift.TException te) {
27036
        throw new java.io.IOException(te);
27037
      }
27038
    }
27039
 
27040
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
27041
      try {
27042
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
27043
      } catch (org.apache.thrift.TException te) {
27044
        throw new java.io.IOException(te);
27045
      }
27046
    }
27047
 
27048
  }
27049
 
27050
  public static class updateVendorString_args implements org.apache.thrift.TBase<updateVendorString_args, updateVendorString_args._Fields>, java.io.Serializable, Cloneable   {
27051
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateVendorString_args");
27052
 
27053
    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);
27054
    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);
27055
 
27056
    private long warehouseId; // required
27057
    private String vendorString; // required
27058
 
27059
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
27060
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
27061
      WAREHOUSE_ID((short)1, "warehouseId"),
27062
      VENDOR_STRING((short)2, "vendorString");
27063
 
27064
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
27065
 
27066
      static {
27067
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
27068
          byName.put(field.getFieldName(), field);
27069
        }
27070
      }
27071
 
27072
      /**
27073
       * Find the _Fields constant that matches fieldId, or null if its not found.
27074
       */
27075
      public static _Fields findByThriftId(int fieldId) {
27076
        switch(fieldId) {
27077
          case 1: // WAREHOUSE_ID
27078
            return WAREHOUSE_ID;
27079
          case 2: // VENDOR_STRING
27080
            return VENDOR_STRING;
27081
          default:
27082
            return null;
27083
        }
27084
      }
27085
 
27086
      /**
27087
       * Find the _Fields constant that matches fieldId, throwing an exception
27088
       * if it is not found.
27089
       */
27090
      public static _Fields findByThriftIdOrThrow(int fieldId) {
27091
        _Fields fields = findByThriftId(fieldId);
27092
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
27093
        return fields;
27094
      }
27095
 
27096
      /**
27097
       * Find the _Fields constant that matches name, or null if its not found.
27098
       */
27099
      public static _Fields findByName(String name) {
27100
        return byName.get(name);
27101
      }
27102
 
27103
      private final short _thriftId;
27104
      private final String _fieldName;
27105
 
27106
      _Fields(short thriftId, String fieldName) {
27107
        _thriftId = thriftId;
27108
        _fieldName = fieldName;
27109
      }
27110
 
27111
      public short getThriftFieldId() {
27112
        return _thriftId;
27113
      }
27114
 
27115
      public String getFieldName() {
27116
        return _fieldName;
27117
      }
27118
    }
27119
 
27120
    // isset id assignments
27121
    private static final int __WAREHOUSEID_ISSET_ID = 0;
27122
    private BitSet __isset_bit_vector = new BitSet(1);
27123
 
27124
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
27125
    static {
27126
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
27127
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
27128
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
27129
      tmpMap.put(_Fields.VENDOR_STRING, new org.apache.thrift.meta_data.FieldMetaData("vendorString", org.apache.thrift.TFieldRequirementType.DEFAULT, 
27130
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
27131
      metaDataMap = Collections.unmodifiableMap(tmpMap);
27132
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateVendorString_args.class, metaDataMap);
27133
    }
27134
 
27135
    public updateVendorString_args() {
27136
    }
27137
 
27138
    public updateVendorString_args(
27139
      long warehouseId,
27140
      String vendorString)
27141
    {
27142
      this();
27143
      this.warehouseId = warehouseId;
27144
      setWarehouseIdIsSet(true);
27145
      this.vendorString = vendorString;
27146
    }
27147
 
27148
    /**
27149
     * Performs a deep copy on <i>other</i>.
27150
     */
27151
    public updateVendorString_args(updateVendorString_args other) {
27152
      __isset_bit_vector.clear();
27153
      __isset_bit_vector.or(other.__isset_bit_vector);
27154
      this.warehouseId = other.warehouseId;
27155
      if (other.isSetVendorString()) {
27156
        this.vendorString = other.vendorString;
27157
      }
27158
    }
27159
 
27160
    public updateVendorString_args deepCopy() {
27161
      return new updateVendorString_args(this);
27162
    }
27163
 
27164
    @Override
27165
    public void clear() {
27166
      setWarehouseIdIsSet(false);
27167
      this.warehouseId = 0;
27168
      this.vendorString = null;
27169
    }
27170
 
27171
    public long getWarehouseId() {
27172
      return this.warehouseId;
27173
    }
27174
 
27175
    public void setWarehouseId(long warehouseId) {
27176
      this.warehouseId = warehouseId;
27177
      setWarehouseIdIsSet(true);
27178
    }
27179
 
27180
    public void unsetWarehouseId() {
27181
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
27182
    }
27183
 
27184
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
27185
    public boolean isSetWarehouseId() {
27186
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
27187
    }
27188
 
27189
    public void setWarehouseIdIsSet(boolean value) {
27190
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
27191
    }
27192
 
27193
    public String getVendorString() {
27194
      return this.vendorString;
27195
    }
27196
 
27197
    public void setVendorString(String vendorString) {
27198
      this.vendorString = vendorString;
27199
    }
27200
 
27201
    public void unsetVendorString() {
27202
      this.vendorString = null;
27203
    }
27204
 
27205
    /** Returns true if field vendorString is set (has been assigned a value) and false otherwise */
27206
    public boolean isSetVendorString() {
27207
      return this.vendorString != null;
27208
    }
27209
 
27210
    public void setVendorStringIsSet(boolean value) {
27211
      if (!value) {
27212
        this.vendorString = null;
27213
      }
27214
    }
27215
 
27216
    public void setFieldValue(_Fields field, Object value) {
27217
      switch (field) {
27218
      case WAREHOUSE_ID:
27219
        if (value == null) {
27220
          unsetWarehouseId();
27221
        } else {
27222
          setWarehouseId((Long)value);
27223
        }
27224
        break;
27225
 
27226
      case VENDOR_STRING:
27227
        if (value == null) {
27228
          unsetVendorString();
27229
        } else {
27230
          setVendorString((String)value);
27231
        }
27232
        break;
27233
 
27234
      }
27235
    }
27236
 
27237
    public Object getFieldValue(_Fields field) {
27238
      switch (field) {
27239
      case WAREHOUSE_ID:
27240
        return Long.valueOf(getWarehouseId());
27241
 
27242
      case VENDOR_STRING:
27243
        return getVendorString();
27244
 
27245
      }
27246
      throw new IllegalStateException();
27247
    }
27248
 
27249
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
27250
    public boolean isSet(_Fields field) {
27251
      if (field == null) {
27252
        throw new IllegalArgumentException();
27253
      }
27254
 
27255
      switch (field) {
27256
      case WAREHOUSE_ID:
27257
        return isSetWarehouseId();
27258
      case VENDOR_STRING:
27259
        return isSetVendorString();
27260
      }
27261
      throw new IllegalStateException();
27262
    }
27263
 
27264
    @Override
27265
    public boolean equals(Object that) {
27266
      if (that == null)
27267
        return false;
27268
      if (that instanceof updateVendorString_args)
27269
        return this.equals((updateVendorString_args)that);
27270
      return false;
27271
    }
27272
 
27273
    public boolean equals(updateVendorString_args that) {
27274
      if (that == null)
27275
        return false;
27276
 
27277
      boolean this_present_warehouseId = true;
27278
      boolean that_present_warehouseId = true;
27279
      if (this_present_warehouseId || that_present_warehouseId) {
27280
        if (!(this_present_warehouseId && that_present_warehouseId))
27281
          return false;
27282
        if (this.warehouseId != that.warehouseId)
27283
          return false;
27284
      }
27285
 
27286
      boolean this_present_vendorString = true && this.isSetVendorString();
27287
      boolean that_present_vendorString = true && that.isSetVendorString();
27288
      if (this_present_vendorString || that_present_vendorString) {
27289
        if (!(this_present_vendorString && that_present_vendorString))
27290
          return false;
27291
        if (!this.vendorString.equals(that.vendorString))
27292
          return false;
27293
      }
27294
 
27295
      return true;
27296
    }
27297
 
27298
    @Override
27299
    public int hashCode() {
27300
      return 0;
27301
    }
27302
 
27303
    public int compareTo(updateVendorString_args other) {
27304
      if (!getClass().equals(other.getClass())) {
27305
        return getClass().getName().compareTo(other.getClass().getName());
27306
      }
27307
 
27308
      int lastComparison = 0;
27309
      updateVendorString_args typedOther = (updateVendorString_args)other;
27310
 
27311
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
27312
      if (lastComparison != 0) {
27313
        return lastComparison;
27314
      }
27315
      if (isSetWarehouseId()) {
27316
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
27317
        if (lastComparison != 0) {
27318
          return lastComparison;
27319
        }
27320
      }
27321
      lastComparison = Boolean.valueOf(isSetVendorString()).compareTo(typedOther.isSetVendorString());
27322
      if (lastComparison != 0) {
27323
        return lastComparison;
27324
      }
27325
      if (isSetVendorString()) {
27326
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorString, typedOther.vendorString);
27327
        if (lastComparison != 0) {
27328
          return lastComparison;
27329
        }
27330
      }
27331
      return 0;
27332
    }
27333
 
27334
    public _Fields fieldForId(int fieldId) {
27335
      return _Fields.findByThriftId(fieldId);
27336
    }
27337
 
27338
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
27339
      org.apache.thrift.protocol.TField field;
27340
      iprot.readStructBegin();
27341
      while (true)
27342
      {
27343
        field = iprot.readFieldBegin();
27344
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
27345
          break;
27346
        }
27347
        switch (field.id) {
27348
          case 1: // WAREHOUSE_ID
27349
            if (field.type == org.apache.thrift.protocol.TType.I64) {
27350
              this.warehouseId = iprot.readI64();
27351
              setWarehouseIdIsSet(true);
27352
            } else { 
27353
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27354
            }
27355
            break;
27356
          case 2: // VENDOR_STRING
27357
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
27358
              this.vendorString = iprot.readString();
27359
            } else { 
27360
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27361
            }
27362
            break;
27363
          default:
27364
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27365
        }
27366
        iprot.readFieldEnd();
27367
      }
27368
      iprot.readStructEnd();
27369
      validate();
27370
    }
27371
 
27372
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
27373
      validate();
27374
 
27375
      oprot.writeStructBegin(STRUCT_DESC);
27376
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
27377
      oprot.writeI64(this.warehouseId);
27378
      oprot.writeFieldEnd();
27379
      if (this.vendorString != null) {
27380
        oprot.writeFieldBegin(VENDOR_STRING_FIELD_DESC);
27381
        oprot.writeString(this.vendorString);
27382
        oprot.writeFieldEnd();
27383
      }
27384
      oprot.writeFieldStop();
27385
      oprot.writeStructEnd();
27386
    }
27387
 
27388
    @Override
27389
    public String toString() {
27390
      StringBuilder sb = new StringBuilder("updateVendorString_args(");
27391
      boolean first = true;
27392
 
27393
      sb.append("warehouseId:");
27394
      sb.append(this.warehouseId);
27395
      first = false;
27396
      if (!first) sb.append(", ");
27397
      sb.append("vendorString:");
27398
      if (this.vendorString == null) {
27399
        sb.append("null");
27400
      } else {
27401
        sb.append(this.vendorString);
27402
      }
27403
      first = false;
27404
      sb.append(")");
27405
      return sb.toString();
27406
    }
27407
 
27408
    public void validate() throws org.apache.thrift.TException {
27409
      // check for required fields
27410
    }
27411
 
27412
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
27413
      try {
27414
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
27415
      } catch (org.apache.thrift.TException te) {
27416
        throw new java.io.IOException(te);
27417
      }
27418
    }
27419
 
27420
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
27421
      try {
5967 rajveer 27422
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
27423
        __isset_bit_vector = new BitSet(1);
5945 mandeep.dh 27424
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
27425
      } catch (org.apache.thrift.TException te) {
27426
        throw new java.io.IOException(te);
27427
      }
27428
    }
27429
 
27430
  }
27431
 
27432
  public static class updateVendorString_result implements org.apache.thrift.TBase<updateVendorString_result, updateVendorString_result._Fields>, java.io.Serializable, Cloneable   {
27433
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateVendorString_result");
27434
 
27435
 
27436
 
27437
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
27438
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
27439
;
27440
 
27441
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
27442
 
27443
      static {
27444
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
27445
          byName.put(field.getFieldName(), field);
27446
        }
27447
      }
27448
 
27449
      /**
27450
       * Find the _Fields constant that matches fieldId, or null if its not found.
27451
       */
27452
      public static _Fields findByThriftId(int fieldId) {
27453
        switch(fieldId) {
27454
          default:
27455
            return null;
27456
        }
27457
      }
27458
 
27459
      /**
27460
       * Find the _Fields constant that matches fieldId, throwing an exception
27461
       * if it is not found.
27462
       */
27463
      public static _Fields findByThriftIdOrThrow(int fieldId) {
27464
        _Fields fields = findByThriftId(fieldId);
27465
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
27466
        return fields;
27467
      }
27468
 
27469
      /**
27470
       * Find the _Fields constant that matches name, or null if its not found.
27471
       */
27472
      public static _Fields findByName(String name) {
27473
        return byName.get(name);
27474
      }
27475
 
27476
      private final short _thriftId;
27477
      private final String _fieldName;
27478
 
27479
      _Fields(short thriftId, String fieldName) {
27480
        _thriftId = thriftId;
27481
        _fieldName = fieldName;
27482
      }
27483
 
27484
      public short getThriftFieldId() {
27485
        return _thriftId;
27486
      }
27487
 
27488
      public String getFieldName() {
27489
        return _fieldName;
27490
      }
27491
    }
27492
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
27493
    static {
27494
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
27495
      metaDataMap = Collections.unmodifiableMap(tmpMap);
27496
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateVendorString_result.class, metaDataMap);
27497
    }
27498
 
27499
    public updateVendorString_result() {
27500
    }
27501
 
27502
    /**
27503
     * Performs a deep copy on <i>other</i>.
27504
     */
27505
    public updateVendorString_result(updateVendorString_result other) {
27506
    }
27507
 
27508
    public updateVendorString_result deepCopy() {
27509
      return new updateVendorString_result(this);
27510
    }
27511
 
27512
    @Override
27513
    public void clear() {
27514
    }
27515
 
27516
    public void setFieldValue(_Fields field, Object value) {
27517
      switch (field) {
27518
      }
27519
    }
27520
 
27521
    public Object getFieldValue(_Fields field) {
27522
      switch (field) {
27523
      }
27524
      throw new IllegalStateException();
27525
    }
27526
 
27527
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
27528
    public boolean isSet(_Fields field) {
27529
      if (field == null) {
27530
        throw new IllegalArgumentException();
27531
      }
27532
 
27533
      switch (field) {
27534
      }
27535
      throw new IllegalStateException();
27536
    }
27537
 
27538
    @Override
27539
    public boolean equals(Object that) {
27540
      if (that == null)
27541
        return false;
27542
      if (that instanceof updateVendorString_result)
27543
        return this.equals((updateVendorString_result)that);
27544
      return false;
27545
    }
27546
 
27547
    public boolean equals(updateVendorString_result that) {
27548
      if (that == null)
27549
        return false;
27550
 
27551
      return true;
27552
    }
27553
 
27554
    @Override
27555
    public int hashCode() {
27556
      return 0;
27557
    }
27558
 
27559
    public int compareTo(updateVendorString_result other) {
27560
      if (!getClass().equals(other.getClass())) {
27561
        return getClass().getName().compareTo(other.getClass().getName());
27562
      }
27563
 
27564
      int lastComparison = 0;
27565
      updateVendorString_result typedOther = (updateVendorString_result)other;
27566
 
27567
      return 0;
27568
    }
27569
 
27570
    public _Fields fieldForId(int fieldId) {
27571
      return _Fields.findByThriftId(fieldId);
27572
    }
27573
 
27574
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
27575
      org.apache.thrift.protocol.TField field;
27576
      iprot.readStructBegin();
27577
      while (true)
27578
      {
27579
        field = iprot.readFieldBegin();
27580
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
27581
          break;
27582
        }
27583
        switch (field.id) {
27584
          default:
27585
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27586
        }
27587
        iprot.readFieldEnd();
27588
      }
27589
      iprot.readStructEnd();
27590
      validate();
27591
    }
27592
 
27593
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
27594
      oprot.writeStructBegin(STRUCT_DESC);
27595
 
27596
      oprot.writeFieldStop();
27597
      oprot.writeStructEnd();
27598
    }
27599
 
27600
    @Override
27601
    public String toString() {
27602
      StringBuilder sb = new StringBuilder("updateVendorString_result(");
27603
      boolean first = true;
27604
 
27605
      sb.append(")");
27606
      return sb.toString();
27607
    }
27608
 
27609
    public void validate() throws org.apache.thrift.TException {
27610
      // check for required fields
27611
    }
27612
 
27613
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
27614
      try {
27615
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
27616
      } catch (org.apache.thrift.TException te) {
27617
        throw new java.io.IOException(te);
27618
      }
27619
    }
27620
 
27621
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
27622
      try {
27623
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
27624
      } catch (org.apache.thrift.TException te) {
27625
        throw new java.io.IOException(te);
27626
      }
27627
    }
27628
 
27629
  }
27630
 
27631
}