Subversion Repositories SmartDukaan

Rev

Rev 5967 | Go to most recent revision | Details | 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
81
     */
82
    public List<Long> getItemAvailabilityAtLocation(long itemId) throws InventoryServiceException, org.apache.thrift.TException;
83
 
84
    public List<Warehouse> getAllWarehouses(boolean isActive) throws InventoryServiceException, org.apache.thrift.TException;
85
 
86
    /**
87
     * Returns the warehouse with the given id.
88
     * 
89
     * @param warehouse_id
90
     */
91
    public Warehouse getWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException;
92
 
93
    public List<Long> getAllItemsForWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException;
94
 
95
    /**
96
     * Increases the reservation count for an item in a warehouse. Should always succeed normally.
97
     * 
98
     * @param itemId
99
     * @param warehouseId
100
     * @param quantity
101
     */
102
    public boolean reserveItemInWarehouse(long itemId, long warehouseId, double quantity) throws InventoryServiceException, org.apache.thrift.TException;
103
 
104
    /**
105
     * Decreases the reservation count for an item in a warehouse. Should always succeed normally.
106
     * 
107
     * @param itemId
108
     * @param warehouseId
109
     * @param quantity
110
     */
111
    public boolean reduceReservationCount(long itemId, long warehouseId, double quantity) throws InventoryServiceException, org.apache.thrift.TException;
112
 
113
    /**
114
     * Returns the pricing information of an item associated with the vendor of the given warehouse.
115
     * Raises an exception if either the item, vendor or the associated pricing information can't be found.
116
     * 
117
     * @param itemId
118
     * @param vendorId
119
     */
120
    public VendorItemPricing getItemPricing(long itemId, long vendorId) throws InventoryServiceException, org.apache.thrift.TException;
121
 
122
    /**
123
     * Returns the list of vendor pricing information of an item.
124
     * Raises an exception if item not found corresponding to itemId
125
     * 
126
     * @param itemId
127
     */
128
    public List<VendorItemPricing> getAllItemPricing(long itemId) throws InventoryServiceException, org.apache.thrift.TException;
129
 
130
    /**
131
     * Adds vendor prices corresponding to the item. If pricing already exists then updates the prices.
132
     * Raises an exception if either the item or vendor can't be found corresponding to their ids.
133
     * 
134
     * @param vendorItemPricing
135
     */
136
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing) throws InventoryServiceException, org.apache.thrift.TException;
137
 
138
    /**
139
     * Returns a vendor given its id
140
     * 
141
     * @param vendorId
142
     */
143
    public Vendor getVendor(long vendorId) throws org.apache.thrift.TException;
144
 
145
    /**
146
     * Return list of all vendors
147
     */
148
    public List<Vendor> getAllVendors() throws org.apache.thrift.TException;
149
 
150
    /**
151
     * Adds VendorItemMapping. Updates VendorItemMapping if exists corresponding to the item key.
152
     * 
153
     * @param key
154
     * @param vendorItemMapping
155
     */
156
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws InventoryServiceException, org.apache.thrift.TException;
157
 
158
    /**
159
     * Returns the list of vendor item mapping corresponding to itemId passed as parameter.
160
     * Raises an exception if item not found corresponding to itemId
161
     * 
162
     * @param itemId
163
     */
164
    public List<VendorItemMapping> getVendorItemMappings(long itemId) throws InventoryServiceException, org.apache.thrift.TException;
165
 
166
    /**
167
     * Returns a list of inventory stock for items for which there are pending orders for the given vendor.
168
     * 
169
     * @param vendorid
170
     */
171
    public List<AvailableAndReservedStock> getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException;
172
 
173
    /**
174
     * This method returns all warehouses for a given warehosueType, inventoryType, vendor, billingWarehouse and shippingWarehouse.
175
     * 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
176
     * 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
177
     *    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
178
     *    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
179
     * 
180
     * @param warehouseType
181
     * @param inventoryType
182
     * @param vendorId
183
     * @param billingWarehouseId
184
     * @param shippingWarehouseId
185
     */
186
    public List<Warehouse> getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException;
187
 
188
    /**
189
     * Resets availability of an item to the quantity mentioned in a warehouse.
190
     * 
191
     * @param itemKey
192
     * @param vendorId
193
     * @param quantity
194
     * @param warehouseId
195
     */
196
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws InventoryServiceException, org.apache.thrift.TException;
197
 
198
    /**
199
     * Resets availability of a warehouse to zero.
200
     * 
201
     * @param warehouseId
202
     */
203
    public void resetAvailabilityForWarehouse(long warehouseId) throws InventoryServiceException, org.apache.thrift.TException;
204
 
205
    /**
206
     * Returns the list of item keys which need to be processed for a given warehouse.
207
     * This is currently used by Support application to send item keys whose inventory needs
208
     * to be updated from PLB
209
     * 
210
     * @param warehouseId
211
     */
212
    public List<String> getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException;
213
 
214
    /**
215
     * Marks/Deletes missed inventory updates for a given key and warehouse.
216
     * This generally happens when updates from PLB are applied on the currentinventorysnapshot for an item
217
     * 
218
     * @param itemKey
219
     * @param warehouseId
220
     */
221
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException;
222
 
223
    /**
224
     * Returns all the item key mappings that have been ignored until date. Value of map has the warehouse id
225
     * and the timestamp from where alert was raised.
226
     */
227
    public Map<String,Map<Long,Long>> getIgnoredItemKeys() throws org.apache.thrift.TException;
228
 
229
    /**
230
     * Add the BAD type inventory to existing stock.
231
     * 
232
     * @param itemId
233
     * @param warehouseId
234
     * @param quantity
235
     */
236
    public void addBadInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException;
237
 
238
    /**
239
     * Returns all shipping locations
240
     */
241
    public List<Warehouse> getShippingLocations() throws org.apache.thrift.TException;
242
 
243
    /**
244
     * Fetches all the vendor item mappings present.
245
     */
246
    public List<VendorItemMapping> getAllVendorItemMappings() throws org.apache.thrift.TException;
247
 
248
    /**
249
     * Gets items' inventory for a warehouse
250
     * If warehouse is passed as zero, items' inventory across all warehouses is sent
251
     * 
252
     * @param warehouseId
253
     */
254
    public Map<Long,ItemInventory> getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException;
255
 
256
    /**
257
     * Clear item availability cache.
258
     */
259
    public void clearItemAvailabilityCache() throws org.apache.thrift.TException;
260
 
261
    public void updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException;
262
 
263
  }
264
 
265
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
266
 
267
    public void addWarehouse(Warehouse warehouse, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addWarehouse_call> resultHandler) throws org.apache.thrift.TException;
268
 
269
    public void addVendor(Vendor vendor, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendor_call> resultHandler) throws org.apache.thrift.TException;
270
 
271
    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;
272
 
273
    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;
274
 
275
    public void addInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addInventory_call> resultHandler) throws org.apache.thrift.TException;
276
 
277
    public void retireWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.retireWarehouse_call> resultHandler) throws org.apache.thrift.TException;
278
 
279
    public void getItemInventoryByItemId(long item_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemInventoryByItemId_call> resultHandler) throws org.apache.thrift.TException;
280
 
281
    public void getItemAvailibilityAtWarehouse(long warehouse_id, long item_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemAvailibilityAtWarehouse_call> resultHandler) throws org.apache.thrift.TException;
282
 
283
    public void getItemAvailabilityAtLocation(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemAvailabilityAtLocation_call> resultHandler) throws org.apache.thrift.TException;
284
 
285
    public void getAllWarehouses(boolean isActive, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllWarehouses_call> resultHandler) throws org.apache.thrift.TException;
286
 
287
    public void getWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getWarehouse_call> resultHandler) throws org.apache.thrift.TException;
288
 
289
    public void getAllItemsForWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllItemsForWarehouse_call> resultHandler) throws org.apache.thrift.TException;
290
 
291
    public void reserveItemInWarehouse(long itemId, long warehouseId, double quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.reserveItemInWarehouse_call> resultHandler) throws org.apache.thrift.TException;
292
 
293
    public void reduceReservationCount(long itemId, long warehouseId, double quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.reduceReservationCount_call> resultHandler) throws org.apache.thrift.TException;
294
 
295
    public void getItemPricing(long itemId, long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemPricing_call> resultHandler) throws org.apache.thrift.TException;
296
 
297
    public void getAllItemPricing(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllItemPricing_call> resultHandler) throws org.apache.thrift.TException;
298
 
299
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendorItemPricing_call> resultHandler) throws org.apache.thrift.TException;
300
 
301
    public void getVendor(long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getVendor_call> resultHandler) throws org.apache.thrift.TException;
302
 
303
    public void getAllVendors(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllVendors_call> resultHandler) throws org.apache.thrift.TException;
304
 
305
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendorItemMapping_call> resultHandler) throws org.apache.thrift.TException;
306
 
307
    public void getVendorItemMappings(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException;
308
 
309
    public void getPendingOrdersInventory(long vendorid, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPendingOrdersInventory_call> resultHandler) throws org.apache.thrift.TException;
310
 
311
    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;
312
 
313
    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;
314
 
315
    public void resetAvailabilityForWarehouse(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.resetAvailabilityForWarehouse_call> resultHandler) throws org.apache.thrift.TException;
316
 
317
    public void getItemKeysToBeProcessed(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemKeysToBeProcessed_call> resultHandler) throws org.apache.thrift.TException;
318
 
319
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.markMissedInventoryUpdatesAsProcessed_call> resultHandler) throws org.apache.thrift.TException;
320
 
321
    public void getIgnoredItemKeys(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getIgnoredItemKeys_call> resultHandler) throws org.apache.thrift.TException;
322
 
323
    public void addBadInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addBadInventory_call> resultHandler) throws org.apache.thrift.TException;
324
 
325
    public void getShippingLocations(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getShippingLocations_call> resultHandler) throws org.apache.thrift.TException;
326
 
327
    public void getAllVendorItemMappings(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException;
328
 
329
    public void getInventorySnapshot(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventorySnapshot_call> resultHandler) throws org.apache.thrift.TException;
330
 
331
    public void clearItemAvailabilityCache(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.clearItemAvailabilityCache_call> resultHandler) throws org.apache.thrift.TException;
332
 
333
    public void updateVendorString(long warehouseId, String vendorString, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updateVendorString_call> resultHandler) throws org.apache.thrift.TException;
334
 
335
  }
336
 
337
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
338
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
339
      public Factory() {}
340
      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
341
        return new Client(prot);
342
      }
343
      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
344
        return new Client(iprot, oprot);
345
      }
346
    }
347
 
348
    public Client(org.apache.thrift.protocol.TProtocol prot)
349
    {
350
      super(prot, prot);
351
    }
352
 
353
    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
354
      super(iprot, oprot);
355
    }
356
 
357
    public long addWarehouse(Warehouse warehouse) throws InventoryServiceException, org.apache.thrift.TException
358
    {
359
      send_addWarehouse(warehouse);
360
      return recv_addWarehouse();
361
    }
362
 
363
    public void send_addWarehouse(Warehouse warehouse) throws org.apache.thrift.TException
364
    {
365
      addWarehouse_args args = new addWarehouse_args();
366
      args.setWarehouse(warehouse);
367
      sendBase("addWarehouse", args);
368
    }
369
 
370
    public long recv_addWarehouse() throws InventoryServiceException, org.apache.thrift.TException
371
    {
372
      addWarehouse_result result = new addWarehouse_result();
373
      receiveBase(result, "addWarehouse");
374
      if (result.isSetSuccess()) {
375
        return result.success;
376
      }
377
      if (result.cex != null) {
378
        throw result.cex;
379
      }
380
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addWarehouse failed: unknown result");
381
    }
382
 
383
    public long addVendor(Vendor vendor) throws InventoryServiceException, org.apache.thrift.TException
384
    {
385
      send_addVendor(vendor);
386
      return recv_addVendor();
387
    }
388
 
389
    public void send_addVendor(Vendor vendor) throws org.apache.thrift.TException
390
    {
391
      addVendor_args args = new addVendor_args();
392
      args.setVendor(vendor);
393
      sendBase("addVendor", args);
394
    }
395
 
396
    public long recv_addVendor() throws InventoryServiceException, org.apache.thrift.TException
397
    {
398
      addVendor_result result = new addVendor_result();
399
      receiveBase(result, "addVendor");
400
      if (result.isSetSuccess()) {
401
        return result.success;
402
      }
403
      if (result.cex != null) {
404
        throw result.cex;
405
      }
406
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addVendor failed: unknown result");
407
    }
408
 
409
    public void updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException
410
    {
411
      send_updateInventoryHistory(warehouse_id, timestamp, availability);
412
      recv_updateInventoryHistory();
413
    }
414
 
415
    public void send_updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws org.apache.thrift.TException
416
    {
417
      updateInventoryHistory_args args = new updateInventoryHistory_args();
418
      args.setWarehouse_id(warehouse_id);
419
      args.setTimestamp(timestamp);
420
      args.setAvailability(availability);
421
      sendBase("updateInventoryHistory", args);
422
    }
423
 
424
    public void recv_updateInventoryHistory() throws InventoryServiceException, org.apache.thrift.TException
425
    {
426
      updateInventoryHistory_result result = new updateInventoryHistory_result();
427
      receiveBase(result, "updateInventoryHistory");
428
      if (result.cex != null) {
429
        throw result.cex;
430
      }
431
      return;
432
    }
433
 
434
    public void updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException
435
    {
436
      send_updateInventory(warehouse_id, timestamp, availability);
437
      recv_updateInventory();
438
    }
439
 
440
    public void send_updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws org.apache.thrift.TException
441
    {
442
      updateInventory_args args = new updateInventory_args();
443
      args.setWarehouse_id(warehouse_id);
444
      args.setTimestamp(timestamp);
445
      args.setAvailability(availability);
446
      sendBase("updateInventory", args);
447
    }
448
 
449
    public void recv_updateInventory() throws InventoryServiceException, org.apache.thrift.TException
450
    {
451
      updateInventory_result result = new updateInventory_result();
452
      receiveBase(result, "updateInventory");
453
      if (result.cex != null) {
454
        throw result.cex;
455
      }
456
      return;
457
    }
458
 
459
    public void addInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException
460
    {
461
      send_addInventory(itemId, warehouseId, quantity);
462
      recv_addInventory();
463
    }
464
 
465
    public void send_addInventory(long itemId, long warehouseId, long quantity) throws org.apache.thrift.TException
466
    {
467
      addInventory_args args = new addInventory_args();
468
      args.setItemId(itemId);
469
      args.setWarehouseId(warehouseId);
470
      args.setQuantity(quantity);
471
      sendBase("addInventory", args);
472
    }
473
 
474
    public void recv_addInventory() throws InventoryServiceException, org.apache.thrift.TException
475
    {
476
      addInventory_result result = new addInventory_result();
477
      receiveBase(result, "addInventory");
478
      if (result.cex != null) {
479
        throw result.cex;
480
      }
481
      return;
482
    }
483
 
484
    public void retireWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
485
    {
486
      send_retireWarehouse(warehouse_id);
487
      recv_retireWarehouse();
488
    }
489
 
490
    public void send_retireWarehouse(long warehouse_id) throws org.apache.thrift.TException
491
    {
492
      retireWarehouse_args args = new retireWarehouse_args();
493
      args.setWarehouse_id(warehouse_id);
494
      sendBase("retireWarehouse", args);
495
    }
496
 
497
    public void recv_retireWarehouse() throws InventoryServiceException, org.apache.thrift.TException
498
    {
499
      retireWarehouse_result result = new retireWarehouse_result();
500
      receiveBase(result, "retireWarehouse");
501
      if (result.cex != null) {
502
        throw result.cex;
503
      }
504
      return;
505
    }
506
 
507
    public ItemInventory getItemInventoryByItemId(long item_id) throws InventoryServiceException, org.apache.thrift.TException
508
    {
509
      send_getItemInventoryByItemId(item_id);
510
      return recv_getItemInventoryByItemId();
511
    }
512
 
513
    public void send_getItemInventoryByItemId(long item_id) throws org.apache.thrift.TException
514
    {
515
      getItemInventoryByItemId_args args = new getItemInventoryByItemId_args();
516
      args.setItem_id(item_id);
517
      sendBase("getItemInventoryByItemId", args);
518
    }
519
 
520
    public ItemInventory recv_getItemInventoryByItemId() throws InventoryServiceException, org.apache.thrift.TException
521
    {
522
      getItemInventoryByItemId_result result = new getItemInventoryByItemId_result();
523
      receiveBase(result, "getItemInventoryByItemId");
524
      if (result.isSetSuccess()) {
525
        return result.success;
526
      }
527
      if (result.cex != null) {
528
        throw result.cex;
529
      }
530
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemInventoryByItemId failed: unknown result");
531
    }
532
 
533
    public long getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws InventoryServiceException, org.apache.thrift.TException
534
    {
535
      send_getItemAvailibilityAtWarehouse(warehouse_id, item_id);
536
      return recv_getItemAvailibilityAtWarehouse();
537
    }
538
 
539
    public void send_getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws org.apache.thrift.TException
540
    {
541
      getItemAvailibilityAtWarehouse_args args = new getItemAvailibilityAtWarehouse_args();
542
      args.setWarehouse_id(warehouse_id);
543
      args.setItem_id(item_id);
544
      sendBase("getItemAvailibilityAtWarehouse", args);
545
    }
546
 
547
    public long recv_getItemAvailibilityAtWarehouse() throws InventoryServiceException, org.apache.thrift.TException
548
    {
549
      getItemAvailibilityAtWarehouse_result result = new getItemAvailibilityAtWarehouse_result();
550
      receiveBase(result, "getItemAvailibilityAtWarehouse");
551
      if (result.isSetSuccess()) {
552
        return result.success;
553
      }
554
      if (result.cex != null) {
555
        throw result.cex;
556
      }
557
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemAvailibilityAtWarehouse failed: unknown result");
558
    }
559
 
560
    public List<Long> getItemAvailabilityAtLocation(long itemId) throws InventoryServiceException, org.apache.thrift.TException
561
    {
562
      send_getItemAvailabilityAtLocation(itemId);
563
      return recv_getItemAvailabilityAtLocation();
564
    }
565
 
566
    public void send_getItemAvailabilityAtLocation(long itemId) throws org.apache.thrift.TException
567
    {
568
      getItemAvailabilityAtLocation_args args = new getItemAvailabilityAtLocation_args();
569
      args.setItemId(itemId);
570
      sendBase("getItemAvailabilityAtLocation", args);
571
    }
572
 
573
    public List<Long> recv_getItemAvailabilityAtLocation() throws InventoryServiceException, org.apache.thrift.TException
574
    {
575
      getItemAvailabilityAtLocation_result result = new getItemAvailabilityAtLocation_result();
576
      receiveBase(result, "getItemAvailabilityAtLocation");
577
      if (result.isSetSuccess()) {
578
        return result.success;
579
      }
580
      if (result.isex != null) {
581
        throw result.isex;
582
      }
583
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemAvailabilityAtLocation failed: unknown result");
584
    }
585
 
586
    public List<Warehouse> getAllWarehouses(boolean isActive) throws InventoryServiceException, org.apache.thrift.TException
587
    {
588
      send_getAllWarehouses(isActive);
589
      return recv_getAllWarehouses();
590
    }
591
 
592
    public void send_getAllWarehouses(boolean isActive) throws org.apache.thrift.TException
593
    {
594
      getAllWarehouses_args args = new getAllWarehouses_args();
595
      args.setIsActive(isActive);
596
      sendBase("getAllWarehouses", args);
597
    }
598
 
599
    public List<Warehouse> recv_getAllWarehouses() throws InventoryServiceException, org.apache.thrift.TException
600
    {
601
      getAllWarehouses_result result = new getAllWarehouses_result();
602
      receiveBase(result, "getAllWarehouses");
603
      if (result.isSetSuccess()) {
604
        return result.success;
605
      }
606
      if (result.cex != null) {
607
        throw result.cex;
608
      }
609
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllWarehouses failed: unknown result");
610
    }
611
 
612
    public Warehouse getWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
613
    {
614
      send_getWarehouse(warehouse_id);
615
      return recv_getWarehouse();
616
    }
617
 
618
    public void send_getWarehouse(long warehouse_id) throws org.apache.thrift.TException
619
    {
620
      getWarehouse_args args = new getWarehouse_args();
621
      args.setWarehouse_id(warehouse_id);
622
      sendBase("getWarehouse", args);
623
    }
624
 
625
    public Warehouse recv_getWarehouse() throws InventoryServiceException, org.apache.thrift.TException
626
    {
627
      getWarehouse_result result = new getWarehouse_result();
628
      receiveBase(result, "getWarehouse");
629
      if (result.isSetSuccess()) {
630
        return result.success;
631
      }
632
      if (result.cex != null) {
633
        throw result.cex;
634
      }
635
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getWarehouse failed: unknown result");
636
    }
637
 
638
    public List<Long> getAllItemsForWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
639
    {
640
      send_getAllItemsForWarehouse(warehouse_id);
641
      return recv_getAllItemsForWarehouse();
642
    }
643
 
644
    public void send_getAllItemsForWarehouse(long warehouse_id) throws org.apache.thrift.TException
645
    {
646
      getAllItemsForWarehouse_args args = new getAllItemsForWarehouse_args();
647
      args.setWarehouse_id(warehouse_id);
648
      sendBase("getAllItemsForWarehouse", args);
649
    }
650
 
651
    public List<Long> recv_getAllItemsForWarehouse() throws InventoryServiceException, org.apache.thrift.TException
652
    {
653
      getAllItemsForWarehouse_result result = new getAllItemsForWarehouse_result();
654
      receiveBase(result, "getAllItemsForWarehouse");
655
      if (result.isSetSuccess()) {
656
        return result.success;
657
      }
658
      if (result.cex != null) {
659
        throw result.cex;
660
      }
661
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllItemsForWarehouse failed: unknown result");
662
    }
663
 
664
    public boolean reserveItemInWarehouse(long itemId, long warehouseId, double quantity) throws InventoryServiceException, org.apache.thrift.TException
665
    {
666
      send_reserveItemInWarehouse(itemId, warehouseId, quantity);
667
      return recv_reserveItemInWarehouse();
668
    }
669
 
670
    public void send_reserveItemInWarehouse(long itemId, long warehouseId, double quantity) throws org.apache.thrift.TException
671
    {
672
      reserveItemInWarehouse_args args = new reserveItemInWarehouse_args();
673
      args.setItemId(itemId);
674
      args.setWarehouseId(warehouseId);
675
      args.setQuantity(quantity);
676
      sendBase("reserveItemInWarehouse", args);
677
    }
678
 
679
    public boolean recv_reserveItemInWarehouse() throws InventoryServiceException, org.apache.thrift.TException
680
    {
681
      reserveItemInWarehouse_result result = new reserveItemInWarehouse_result();
682
      receiveBase(result, "reserveItemInWarehouse");
683
      if (result.isSetSuccess()) {
684
        return result.success;
685
      }
686
      if (result.cex != null) {
687
        throw result.cex;
688
      }
689
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "reserveItemInWarehouse failed: unknown result");
690
    }
691
 
692
    public boolean reduceReservationCount(long itemId, long warehouseId, double quantity) throws InventoryServiceException, org.apache.thrift.TException
693
    {
694
      send_reduceReservationCount(itemId, warehouseId, quantity);
695
      return recv_reduceReservationCount();
696
    }
697
 
698
    public void send_reduceReservationCount(long itemId, long warehouseId, double quantity) throws org.apache.thrift.TException
699
    {
700
      reduceReservationCount_args args = new reduceReservationCount_args();
701
      args.setItemId(itemId);
702
      args.setWarehouseId(warehouseId);
703
      args.setQuantity(quantity);
704
      sendBase("reduceReservationCount", args);
705
    }
706
 
707
    public boolean recv_reduceReservationCount() throws InventoryServiceException, org.apache.thrift.TException
708
    {
709
      reduceReservationCount_result result = new reduceReservationCount_result();
710
      receiveBase(result, "reduceReservationCount");
711
      if (result.isSetSuccess()) {
712
        return result.success;
713
      }
714
      if (result.cex != null) {
715
        throw result.cex;
716
      }
717
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "reduceReservationCount failed: unknown result");
718
    }
719
 
720
    public VendorItemPricing getItemPricing(long itemId, long vendorId) throws InventoryServiceException, org.apache.thrift.TException
721
    {
722
      send_getItemPricing(itemId, vendorId);
723
      return recv_getItemPricing();
724
    }
725
 
726
    public void send_getItemPricing(long itemId, long vendorId) throws org.apache.thrift.TException
727
    {
728
      getItemPricing_args args = new getItemPricing_args();
729
      args.setItemId(itemId);
730
      args.setVendorId(vendorId);
731
      sendBase("getItemPricing", args);
732
    }
733
 
734
    public VendorItemPricing recv_getItemPricing() throws InventoryServiceException, org.apache.thrift.TException
735
    {
736
      getItemPricing_result result = new getItemPricing_result();
737
      receiveBase(result, "getItemPricing");
738
      if (result.isSetSuccess()) {
739
        return result.success;
740
      }
741
      if (result.cex != null) {
742
        throw result.cex;
743
      }
744
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemPricing failed: unknown result");
745
    }
746
 
747
    public List<VendorItemPricing> getAllItemPricing(long itemId) throws InventoryServiceException, org.apache.thrift.TException
748
    {
749
      send_getAllItemPricing(itemId);
750
      return recv_getAllItemPricing();
751
    }
752
 
753
    public void send_getAllItemPricing(long itemId) throws org.apache.thrift.TException
754
    {
755
      getAllItemPricing_args args = new getAllItemPricing_args();
756
      args.setItemId(itemId);
757
      sendBase("getAllItemPricing", args);
758
    }
759
 
760
    public List<VendorItemPricing> recv_getAllItemPricing() throws InventoryServiceException, org.apache.thrift.TException
761
    {
762
      getAllItemPricing_result result = new getAllItemPricing_result();
763
      receiveBase(result, "getAllItemPricing");
764
      if (result.isSetSuccess()) {
765
        return result.success;
766
      }
767
      if (result.cex != null) {
768
        throw result.cex;
769
      }
770
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllItemPricing failed: unknown result");
771
    }
772
 
773
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing) throws InventoryServiceException, org.apache.thrift.TException
774
    {
775
      send_addVendorItemPricing(vendorItemPricing);
776
      recv_addVendorItemPricing();
777
    }
778
 
779
    public void send_addVendorItemPricing(VendorItemPricing vendorItemPricing) throws org.apache.thrift.TException
780
    {
781
      addVendorItemPricing_args args = new addVendorItemPricing_args();
782
      args.setVendorItemPricing(vendorItemPricing);
783
      sendBase("addVendorItemPricing", args);
784
    }
785
 
786
    public void recv_addVendorItemPricing() throws InventoryServiceException, org.apache.thrift.TException
787
    {
788
      addVendorItemPricing_result result = new addVendorItemPricing_result();
789
      receiveBase(result, "addVendorItemPricing");
790
      if (result.cex != null) {
791
        throw result.cex;
792
      }
793
      return;
794
    }
795
 
796
    public Vendor getVendor(long vendorId) throws org.apache.thrift.TException
797
    {
798
      send_getVendor(vendorId);
799
      return recv_getVendor();
800
    }
801
 
802
    public void send_getVendor(long vendorId) throws org.apache.thrift.TException
803
    {
804
      getVendor_args args = new getVendor_args();
805
      args.setVendorId(vendorId);
806
      sendBase("getVendor", args);
807
    }
808
 
809
    public Vendor recv_getVendor() throws org.apache.thrift.TException
810
    {
811
      getVendor_result result = new getVendor_result();
812
      receiveBase(result, "getVendor");
813
      if (result.isSetSuccess()) {
814
        return result.success;
815
      }
816
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getVendor failed: unknown result");
817
    }
818
 
819
    public List<Vendor> getAllVendors() throws org.apache.thrift.TException
820
    {
821
      send_getAllVendors();
822
      return recv_getAllVendors();
823
    }
824
 
825
    public void send_getAllVendors() throws org.apache.thrift.TException
826
    {
827
      getAllVendors_args args = new getAllVendors_args();
828
      sendBase("getAllVendors", args);
829
    }
830
 
831
    public List<Vendor> recv_getAllVendors() throws org.apache.thrift.TException
832
    {
833
      getAllVendors_result result = new getAllVendors_result();
834
      receiveBase(result, "getAllVendors");
835
      if (result.isSetSuccess()) {
836
        return result.success;
837
      }
838
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllVendors failed: unknown result");
839
    }
840
 
841
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws InventoryServiceException, org.apache.thrift.TException
842
    {
843
      send_addVendorItemMapping(key, vendorItemMapping);
844
      recv_addVendorItemMapping();
845
    }
846
 
847
    public void send_addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws org.apache.thrift.TException
848
    {
849
      addVendorItemMapping_args args = new addVendorItemMapping_args();
850
      args.setKey(key);
851
      args.setVendorItemMapping(vendorItemMapping);
852
      sendBase("addVendorItemMapping", args);
853
    }
854
 
855
    public void recv_addVendorItemMapping() throws InventoryServiceException, org.apache.thrift.TException
856
    {
857
      addVendorItemMapping_result result = new addVendorItemMapping_result();
858
      receiveBase(result, "addVendorItemMapping");
859
      if (result.cex != null) {
860
        throw result.cex;
861
      }
862
      return;
863
    }
864
 
865
    public List<VendorItemMapping> getVendorItemMappings(long itemId) throws InventoryServiceException, org.apache.thrift.TException
866
    {
867
      send_getVendorItemMappings(itemId);
868
      return recv_getVendorItemMappings();
869
    }
870
 
871
    public void send_getVendorItemMappings(long itemId) throws org.apache.thrift.TException
872
    {
873
      getVendorItemMappings_args args = new getVendorItemMappings_args();
874
      args.setItemId(itemId);
875
      sendBase("getVendorItemMappings", args);
876
    }
877
 
878
    public List<VendorItemMapping> recv_getVendorItemMappings() throws InventoryServiceException, org.apache.thrift.TException
879
    {
880
      getVendorItemMappings_result result = new getVendorItemMappings_result();
881
      receiveBase(result, "getVendorItemMappings");
882
      if (result.isSetSuccess()) {
883
        return result.success;
884
      }
885
      if (result.cex != null) {
886
        throw result.cex;
887
      }
888
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getVendorItemMappings failed: unknown result");
889
    }
890
 
891
    public List<AvailableAndReservedStock> getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException
892
    {
893
      send_getPendingOrdersInventory(vendorid);
894
      return recv_getPendingOrdersInventory();
895
    }
896
 
897
    public void send_getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException
898
    {
899
      getPendingOrdersInventory_args args = new getPendingOrdersInventory_args();
900
      args.setVendorid(vendorid);
901
      sendBase("getPendingOrdersInventory", args);
902
    }
903
 
904
    public List<AvailableAndReservedStock> recv_getPendingOrdersInventory() throws org.apache.thrift.TException
905
    {
906
      getPendingOrdersInventory_result result = new getPendingOrdersInventory_result();
907
      receiveBase(result, "getPendingOrdersInventory");
908
      if (result.isSetSuccess()) {
909
        return result.success;
910
      }
911
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPendingOrdersInventory failed: unknown result");
912
    }
913
 
914
    public List<Warehouse> getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException
915
    {
916
      send_getWarehouses(warehouseType, inventoryType, vendorId, billingWarehouseId, shippingWarehouseId);
917
      return recv_getWarehouses();
918
    }
919
 
920
    public void send_getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException
921
    {
922
      getWarehouses_args args = new getWarehouses_args();
923
      args.setWarehouseType(warehouseType);
924
      args.setInventoryType(inventoryType);
925
      args.setVendorId(vendorId);
926
      args.setBillingWarehouseId(billingWarehouseId);
927
      args.setShippingWarehouseId(shippingWarehouseId);
928
      sendBase("getWarehouses", args);
929
    }
930
 
931
    public List<Warehouse> recv_getWarehouses() throws org.apache.thrift.TException
932
    {
933
      getWarehouses_result result = new getWarehouses_result();
934
      receiveBase(result, "getWarehouses");
935
      if (result.isSetSuccess()) {
936
        return result.success;
937
      }
938
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getWarehouses failed: unknown result");
939
    }
940
 
941
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws InventoryServiceException, org.apache.thrift.TException
942
    {
943
      send_resetAvailability(itemKey, vendorId, quantity, warehouseId);
944
      recv_resetAvailability();
945
    }
946
 
947
    public void send_resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws org.apache.thrift.TException
948
    {
949
      resetAvailability_args args = new resetAvailability_args();
950
      args.setItemKey(itemKey);
951
      args.setVendorId(vendorId);
952
      args.setQuantity(quantity);
953
      args.setWarehouseId(warehouseId);
954
      sendBase("resetAvailability", args);
955
    }
956
 
957
    public void recv_resetAvailability() throws InventoryServiceException, org.apache.thrift.TException
958
    {
959
      resetAvailability_result result = new resetAvailability_result();
960
      receiveBase(result, "resetAvailability");
961
      if (result.cex != null) {
962
        throw result.cex;
963
      }
964
      return;
965
    }
966
 
967
    public void resetAvailabilityForWarehouse(long warehouseId) throws InventoryServiceException, org.apache.thrift.TException
968
    {
969
      send_resetAvailabilityForWarehouse(warehouseId);
970
      recv_resetAvailabilityForWarehouse();
971
    }
972
 
973
    public void send_resetAvailabilityForWarehouse(long warehouseId) throws org.apache.thrift.TException
974
    {
975
      resetAvailabilityForWarehouse_args args = new resetAvailabilityForWarehouse_args();
976
      args.setWarehouseId(warehouseId);
977
      sendBase("resetAvailabilityForWarehouse", args);
978
    }
979
 
980
    public void recv_resetAvailabilityForWarehouse() throws InventoryServiceException, org.apache.thrift.TException
981
    {
982
      resetAvailabilityForWarehouse_result result = new resetAvailabilityForWarehouse_result();
983
      receiveBase(result, "resetAvailabilityForWarehouse");
984
      if (result.cex != null) {
985
        throw result.cex;
986
      }
987
      return;
988
    }
989
 
990
    public List<String> getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException
991
    {
992
      send_getItemKeysToBeProcessed(warehouseId);
993
      return recv_getItemKeysToBeProcessed();
994
    }
995
 
996
    public void send_getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException
997
    {
998
      getItemKeysToBeProcessed_args args = new getItemKeysToBeProcessed_args();
999
      args.setWarehouseId(warehouseId);
1000
      sendBase("getItemKeysToBeProcessed", args);
1001
    }
1002
 
1003
    public List<String> recv_getItemKeysToBeProcessed() throws org.apache.thrift.TException
1004
    {
1005
      getItemKeysToBeProcessed_result result = new getItemKeysToBeProcessed_result();
1006
      receiveBase(result, "getItemKeysToBeProcessed");
1007
      if (result.isSetSuccess()) {
1008
        return result.success;
1009
      }
1010
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemKeysToBeProcessed failed: unknown result");
1011
    }
1012
 
1013
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException
1014
    {
1015
      send_markMissedInventoryUpdatesAsProcessed(itemKey, warehouseId);
1016
      recv_markMissedInventoryUpdatesAsProcessed();
1017
    }
1018
 
1019
    public void send_markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException
1020
    {
1021
      markMissedInventoryUpdatesAsProcessed_args args = new markMissedInventoryUpdatesAsProcessed_args();
1022
      args.setItemKey(itemKey);
1023
      args.setWarehouseId(warehouseId);
1024
      sendBase("markMissedInventoryUpdatesAsProcessed", args);
1025
    }
1026
 
1027
    public void recv_markMissedInventoryUpdatesAsProcessed() throws org.apache.thrift.TException
1028
    {
1029
      markMissedInventoryUpdatesAsProcessed_result result = new markMissedInventoryUpdatesAsProcessed_result();
1030
      receiveBase(result, "markMissedInventoryUpdatesAsProcessed");
1031
      return;
1032
    }
1033
 
1034
    public Map<String,Map<Long,Long>> getIgnoredItemKeys() throws org.apache.thrift.TException
1035
    {
1036
      send_getIgnoredItemKeys();
1037
      return recv_getIgnoredItemKeys();
1038
    }
1039
 
1040
    public void send_getIgnoredItemKeys() throws org.apache.thrift.TException
1041
    {
1042
      getIgnoredItemKeys_args args = new getIgnoredItemKeys_args();
1043
      sendBase("getIgnoredItemKeys", args);
1044
    }
1045
 
1046
    public Map<String,Map<Long,Long>> recv_getIgnoredItemKeys() throws org.apache.thrift.TException
1047
    {
1048
      getIgnoredItemKeys_result result = new getIgnoredItemKeys_result();
1049
      receiveBase(result, "getIgnoredItemKeys");
1050
      if (result.isSetSuccess()) {
1051
        return result.success;
1052
      }
1053
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getIgnoredItemKeys failed: unknown result");
1054
    }
1055
 
1056
    public void addBadInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException
1057
    {
1058
      send_addBadInventory(itemId, warehouseId, quantity);
1059
      recv_addBadInventory();
1060
    }
1061
 
1062
    public void send_addBadInventory(long itemId, long warehouseId, long quantity) throws org.apache.thrift.TException
1063
    {
1064
      addBadInventory_args args = new addBadInventory_args();
1065
      args.setItemId(itemId);
1066
      args.setWarehouseId(warehouseId);
1067
      args.setQuantity(quantity);
1068
      sendBase("addBadInventory", args);
1069
    }
1070
 
1071
    public void recv_addBadInventory() throws InventoryServiceException, org.apache.thrift.TException
1072
    {
1073
      addBadInventory_result result = new addBadInventory_result();
1074
      receiveBase(result, "addBadInventory");
1075
      if (result.cex != null) {
1076
        throw result.cex;
1077
      }
1078
      return;
1079
    }
1080
 
1081
    public List<Warehouse> getShippingLocations() throws org.apache.thrift.TException
1082
    {
1083
      send_getShippingLocations();
1084
      return recv_getShippingLocations();
1085
    }
1086
 
1087
    public void send_getShippingLocations() throws org.apache.thrift.TException
1088
    {
1089
      getShippingLocations_args args = new getShippingLocations_args();
1090
      sendBase("getShippingLocations", args);
1091
    }
1092
 
1093
    public List<Warehouse> recv_getShippingLocations() throws org.apache.thrift.TException
1094
    {
1095
      getShippingLocations_result result = new getShippingLocations_result();
1096
      receiveBase(result, "getShippingLocations");
1097
      if (result.isSetSuccess()) {
1098
        return result.success;
1099
      }
1100
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getShippingLocations failed: unknown result");
1101
    }
1102
 
1103
    public List<VendorItemMapping> getAllVendorItemMappings() throws org.apache.thrift.TException
1104
    {
1105
      send_getAllVendorItemMappings();
1106
      return recv_getAllVendorItemMappings();
1107
    }
1108
 
1109
    public void send_getAllVendorItemMappings() throws org.apache.thrift.TException
1110
    {
1111
      getAllVendorItemMappings_args args = new getAllVendorItemMappings_args();
1112
      sendBase("getAllVendorItemMappings", args);
1113
    }
1114
 
1115
    public List<VendorItemMapping> recv_getAllVendorItemMappings() throws org.apache.thrift.TException
1116
    {
1117
      getAllVendorItemMappings_result result = new getAllVendorItemMappings_result();
1118
      receiveBase(result, "getAllVendorItemMappings");
1119
      if (result.isSetSuccess()) {
1120
        return result.success;
1121
      }
1122
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllVendorItemMappings failed: unknown result");
1123
    }
1124
 
1125
    public Map<Long,ItemInventory> getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException
1126
    {
1127
      send_getInventorySnapshot(warehouseId);
1128
      return recv_getInventorySnapshot();
1129
    }
1130
 
1131
    public void send_getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException
1132
    {
1133
      getInventorySnapshot_args args = new getInventorySnapshot_args();
1134
      args.setWarehouseId(warehouseId);
1135
      sendBase("getInventorySnapshot", args);
1136
    }
1137
 
1138
    public Map<Long,ItemInventory> recv_getInventorySnapshot() throws org.apache.thrift.TException
1139
    {
1140
      getInventorySnapshot_result result = new getInventorySnapshot_result();
1141
      receiveBase(result, "getInventorySnapshot");
1142
      if (result.isSetSuccess()) {
1143
        return result.success;
1144
      }
1145
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventorySnapshot failed: unknown result");
1146
    }
1147
 
1148
    public void clearItemAvailabilityCache() throws org.apache.thrift.TException
1149
    {
1150
      send_clearItemAvailabilityCache();
1151
      recv_clearItemAvailabilityCache();
1152
    }
1153
 
1154
    public void send_clearItemAvailabilityCache() throws org.apache.thrift.TException
1155
    {
1156
      clearItemAvailabilityCache_args args = new clearItemAvailabilityCache_args();
1157
      sendBase("clearItemAvailabilityCache", args);
1158
    }
1159
 
1160
    public void recv_clearItemAvailabilityCache() throws org.apache.thrift.TException
1161
    {
1162
      clearItemAvailabilityCache_result result = new clearItemAvailabilityCache_result();
1163
      receiveBase(result, "clearItemAvailabilityCache");
1164
      return;
1165
    }
1166
 
1167
    public void updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException
1168
    {
1169
      send_updateVendorString(warehouseId, vendorString);
1170
      recv_updateVendorString();
1171
    }
1172
 
1173
    public void send_updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException
1174
    {
1175
      updateVendorString_args args = new updateVendorString_args();
1176
      args.setWarehouseId(warehouseId);
1177
      args.setVendorString(vendorString);
1178
      sendBase("updateVendorString", args);
1179
    }
1180
 
1181
    public void recv_updateVendorString() throws org.apache.thrift.TException
1182
    {
1183
      updateVendorString_result result = new updateVendorString_result();
1184
      receiveBase(result, "updateVendorString");
1185
      return;
1186
    }
1187
 
1188
  }
1189
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
1190
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
1191
      private org.apache.thrift.async.TAsyncClientManager clientManager;
1192
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
1193
      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
1194
        this.clientManager = clientManager;
1195
        this.protocolFactory = protocolFactory;
1196
      }
1197
      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
1198
        return new AsyncClient(protocolFactory, clientManager, transport);
1199
      }
1200
    }
1201
 
1202
    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
1203
      super(protocolFactory, clientManager, transport);
1204
    }
1205
 
1206
    public void addWarehouse(Warehouse warehouse, org.apache.thrift.async.AsyncMethodCallback<addWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1207
      checkReady();
1208
      addWarehouse_call method_call = new addWarehouse_call(warehouse, resultHandler, this, ___protocolFactory, ___transport);
1209
      this.___currentMethod = method_call;
1210
      ___manager.call(method_call);
1211
    }
1212
 
1213
    public static class addWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1214
      private Warehouse warehouse;
1215
      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 {
1216
        super(client, protocolFactory, transport, resultHandler, false);
1217
        this.warehouse = warehouse;
1218
      }
1219
 
1220
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1221
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1222
        addWarehouse_args args = new addWarehouse_args();
1223
        args.setWarehouse(warehouse);
1224
        args.write(prot);
1225
        prot.writeMessageEnd();
1226
      }
1227
 
1228
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1229
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1230
          throw new IllegalStateException("Method call not finished!");
1231
        }
1232
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1233
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1234
        return (new Client(prot)).recv_addWarehouse();
1235
      }
1236
    }
1237
 
1238
    public void addVendor(Vendor vendor, org.apache.thrift.async.AsyncMethodCallback<addVendor_call> resultHandler) throws org.apache.thrift.TException {
1239
      checkReady();
1240
      addVendor_call method_call = new addVendor_call(vendor, resultHandler, this, ___protocolFactory, ___transport);
1241
      this.___currentMethod = method_call;
1242
      ___manager.call(method_call);
1243
    }
1244
 
1245
    public static class addVendor_call extends org.apache.thrift.async.TAsyncMethodCall {
1246
      private Vendor vendor;
1247
      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 {
1248
        super(client, protocolFactory, transport, resultHandler, false);
1249
        this.vendor = vendor;
1250
      }
1251
 
1252
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1253
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendor", org.apache.thrift.protocol.TMessageType.CALL, 0));
1254
        addVendor_args args = new addVendor_args();
1255
        args.setVendor(vendor);
1256
        args.write(prot);
1257
        prot.writeMessageEnd();
1258
      }
1259
 
1260
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1261
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1262
          throw new IllegalStateException("Method call not finished!");
1263
        }
1264
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1265
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1266
        return (new Client(prot)).recv_addVendor();
1267
      }
1268
    }
1269
 
1270
    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 {
1271
      checkReady();
1272
      updateInventoryHistory_call method_call = new updateInventoryHistory_call(warehouse_id, timestamp, availability, resultHandler, this, ___protocolFactory, ___transport);
1273
      this.___currentMethod = method_call;
1274
      ___manager.call(method_call);
1275
    }
1276
 
1277
    public static class updateInventoryHistory_call extends org.apache.thrift.async.TAsyncMethodCall {
1278
      private long warehouse_id;
1279
      private String timestamp;
1280
      private Map<String,Long> availability;
1281
      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 {
1282
        super(client, protocolFactory, transport, resultHandler, false);
1283
        this.warehouse_id = warehouse_id;
1284
        this.timestamp = timestamp;
1285
        this.availability = availability;
1286
      }
1287
 
1288
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1289
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateInventoryHistory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1290
        updateInventoryHistory_args args = new updateInventoryHistory_args();
1291
        args.setWarehouse_id(warehouse_id);
1292
        args.setTimestamp(timestamp);
1293
        args.setAvailability(availability);
1294
        args.write(prot);
1295
        prot.writeMessageEnd();
1296
      }
1297
 
1298
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1299
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1300
          throw new IllegalStateException("Method call not finished!");
1301
        }
1302
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1303
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1304
        (new Client(prot)).recv_updateInventoryHistory();
1305
      }
1306
    }
1307
 
1308
    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 {
1309
      checkReady();
1310
      updateInventory_call method_call = new updateInventory_call(warehouse_id, timestamp, availability, resultHandler, this, ___protocolFactory, ___transport);
1311
      this.___currentMethod = method_call;
1312
      ___manager.call(method_call);
1313
    }
1314
 
1315
    public static class updateInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
1316
      private long warehouse_id;
1317
      private String timestamp;
1318
      private Map<String,Long> availability;
1319
      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 {
1320
        super(client, protocolFactory, transport, resultHandler, false);
1321
        this.warehouse_id = warehouse_id;
1322
        this.timestamp = timestamp;
1323
        this.availability = availability;
1324
      }
1325
 
1326
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1327
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1328
        updateInventory_args args = new updateInventory_args();
1329
        args.setWarehouse_id(warehouse_id);
1330
        args.setTimestamp(timestamp);
1331
        args.setAvailability(availability);
1332
        args.write(prot);
1333
        prot.writeMessageEnd();
1334
      }
1335
 
1336
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1337
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1338
          throw new IllegalStateException("Method call not finished!");
1339
        }
1340
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1341
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1342
        (new Client(prot)).recv_updateInventory();
1343
      }
1344
    }
1345
 
1346
    public void addInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addInventory_call> resultHandler) throws org.apache.thrift.TException {
1347
      checkReady();
1348
      addInventory_call method_call = new addInventory_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
1349
      this.___currentMethod = method_call;
1350
      ___manager.call(method_call);
1351
    }
1352
 
1353
    public static class addInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
1354
      private long itemId;
1355
      private long warehouseId;
1356
      private long quantity;
1357
      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 {
1358
        super(client, protocolFactory, transport, resultHandler, false);
1359
        this.itemId = itemId;
1360
        this.warehouseId = warehouseId;
1361
        this.quantity = quantity;
1362
      }
1363
 
1364
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1365
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1366
        addInventory_args args = new addInventory_args();
1367
        args.setItemId(itemId);
1368
        args.setWarehouseId(warehouseId);
1369
        args.setQuantity(quantity);
1370
        args.write(prot);
1371
        prot.writeMessageEnd();
1372
      }
1373
 
1374
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1375
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1376
          throw new IllegalStateException("Method call not finished!");
1377
        }
1378
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1379
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1380
        (new Client(prot)).recv_addInventory();
1381
      }
1382
    }
1383
 
1384
    public void retireWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<retireWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1385
      checkReady();
1386
      retireWarehouse_call method_call = new retireWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1387
      this.___currentMethod = method_call;
1388
      ___manager.call(method_call);
1389
    }
1390
 
1391
    public static class retireWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1392
      private long warehouse_id;
1393
      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 {
1394
        super(client, protocolFactory, transport, resultHandler, false);
1395
        this.warehouse_id = warehouse_id;
1396
      }
1397
 
1398
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1399
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("retireWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1400
        retireWarehouse_args args = new retireWarehouse_args();
1401
        args.setWarehouse_id(warehouse_id);
1402
        args.write(prot);
1403
        prot.writeMessageEnd();
1404
      }
1405
 
1406
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1407
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1408
          throw new IllegalStateException("Method call not finished!");
1409
        }
1410
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1411
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1412
        (new Client(prot)).recv_retireWarehouse();
1413
      }
1414
    }
1415
 
1416
    public void getItemInventoryByItemId(long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemInventoryByItemId_call> resultHandler) throws org.apache.thrift.TException {
1417
      checkReady();
1418
      getItemInventoryByItemId_call method_call = new getItemInventoryByItemId_call(item_id, resultHandler, this, ___protocolFactory, ___transport);
1419
      this.___currentMethod = method_call;
1420
      ___manager.call(method_call);
1421
    }
1422
 
1423
    public static class getItemInventoryByItemId_call extends org.apache.thrift.async.TAsyncMethodCall {
1424
      private long item_id;
1425
      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 {
1426
        super(client, protocolFactory, transport, resultHandler, false);
1427
        this.item_id = item_id;
1428
      }
1429
 
1430
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1431
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemInventoryByItemId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1432
        getItemInventoryByItemId_args args = new getItemInventoryByItemId_args();
1433
        args.setItem_id(item_id);
1434
        args.write(prot);
1435
        prot.writeMessageEnd();
1436
      }
1437
 
1438
      public ItemInventory getResult() throws InventoryServiceException, org.apache.thrift.TException {
1439
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1440
          throw new IllegalStateException("Method call not finished!");
1441
        }
1442
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1443
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1444
        return (new Client(prot)).recv_getItemInventoryByItemId();
1445
      }
1446
    }
1447
 
1448
    public void getItemAvailibilityAtWarehouse(long warehouse_id, long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemAvailibilityAtWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1449
      checkReady();
1450
      getItemAvailibilityAtWarehouse_call method_call = new getItemAvailibilityAtWarehouse_call(warehouse_id, item_id, resultHandler, this, ___protocolFactory, ___transport);
1451
      this.___currentMethod = method_call;
1452
      ___manager.call(method_call);
1453
    }
1454
 
1455
    public static class getItemAvailibilityAtWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1456
      private long warehouse_id;
1457
      private long item_id;
1458
      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 {
1459
        super(client, protocolFactory, transport, resultHandler, false);
1460
        this.warehouse_id = warehouse_id;
1461
        this.item_id = item_id;
1462
      }
1463
 
1464
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1465
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemAvailibilityAtWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1466
        getItemAvailibilityAtWarehouse_args args = new getItemAvailibilityAtWarehouse_args();
1467
        args.setWarehouse_id(warehouse_id);
1468
        args.setItem_id(item_id);
1469
        args.write(prot);
1470
        prot.writeMessageEnd();
1471
      }
1472
 
1473
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1474
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1475
          throw new IllegalStateException("Method call not finished!");
1476
        }
1477
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1478
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1479
        return (new Client(prot)).recv_getItemAvailibilityAtWarehouse();
1480
      }
1481
    }
1482
 
1483
    public void getItemAvailabilityAtLocation(long itemId, org.apache.thrift.async.AsyncMethodCallback<getItemAvailabilityAtLocation_call> resultHandler) throws org.apache.thrift.TException {
1484
      checkReady();
1485
      getItemAvailabilityAtLocation_call method_call = new getItemAvailabilityAtLocation_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1486
      this.___currentMethod = method_call;
1487
      ___manager.call(method_call);
1488
    }
1489
 
1490
    public static class getItemAvailabilityAtLocation_call extends org.apache.thrift.async.TAsyncMethodCall {
1491
      private long itemId;
1492
      public getItemAvailabilityAtLocation_call(long itemId, 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 {
1493
        super(client, protocolFactory, transport, resultHandler, false);
1494
        this.itemId = itemId;
1495
      }
1496
 
1497
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1498
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemAvailabilityAtLocation", org.apache.thrift.protocol.TMessageType.CALL, 0));
1499
        getItemAvailabilityAtLocation_args args = new getItemAvailabilityAtLocation_args();
1500
        args.setItemId(itemId);
1501
        args.write(prot);
1502
        prot.writeMessageEnd();
1503
      }
1504
 
1505
      public List<Long> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1506
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1507
          throw new IllegalStateException("Method call not finished!");
1508
        }
1509
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1510
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1511
        return (new Client(prot)).recv_getItemAvailabilityAtLocation();
1512
      }
1513
    }
1514
 
1515
    public void getAllWarehouses(boolean isActive, org.apache.thrift.async.AsyncMethodCallback<getAllWarehouses_call> resultHandler) throws org.apache.thrift.TException {
1516
      checkReady();
1517
      getAllWarehouses_call method_call = new getAllWarehouses_call(isActive, resultHandler, this, ___protocolFactory, ___transport);
1518
      this.___currentMethod = method_call;
1519
      ___manager.call(method_call);
1520
    }
1521
 
1522
    public static class getAllWarehouses_call extends org.apache.thrift.async.TAsyncMethodCall {
1523
      private boolean isActive;
1524
      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 {
1525
        super(client, protocolFactory, transport, resultHandler, false);
1526
        this.isActive = isActive;
1527
      }
1528
 
1529
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1530
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllWarehouses", org.apache.thrift.protocol.TMessageType.CALL, 0));
1531
        getAllWarehouses_args args = new getAllWarehouses_args();
1532
        args.setIsActive(isActive);
1533
        args.write(prot);
1534
        prot.writeMessageEnd();
1535
      }
1536
 
1537
      public List<Warehouse> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1538
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1539
          throw new IllegalStateException("Method call not finished!");
1540
        }
1541
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1542
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1543
        return (new Client(prot)).recv_getAllWarehouses();
1544
      }
1545
    }
1546
 
1547
    public void getWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1548
      checkReady();
1549
      getWarehouse_call method_call = new getWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1550
      this.___currentMethod = method_call;
1551
      ___manager.call(method_call);
1552
    }
1553
 
1554
    public static class getWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1555
      private long warehouse_id;
1556
      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 {
1557
        super(client, protocolFactory, transport, resultHandler, false);
1558
        this.warehouse_id = warehouse_id;
1559
      }
1560
 
1561
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1562
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1563
        getWarehouse_args args = new getWarehouse_args();
1564
        args.setWarehouse_id(warehouse_id);
1565
        args.write(prot);
1566
        prot.writeMessageEnd();
1567
      }
1568
 
1569
      public Warehouse getResult() throws InventoryServiceException, org.apache.thrift.TException {
1570
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1571
          throw new IllegalStateException("Method call not finished!");
1572
        }
1573
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1574
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1575
        return (new Client(prot)).recv_getWarehouse();
1576
      }
1577
    }
1578
 
1579
    public void getAllItemsForWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getAllItemsForWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1580
      checkReady();
1581
      getAllItemsForWarehouse_call method_call = new getAllItemsForWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1582
      this.___currentMethod = method_call;
1583
      ___manager.call(method_call);
1584
    }
1585
 
1586
    public static class getAllItemsForWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1587
      private long warehouse_id;
1588
      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 {
1589
        super(client, protocolFactory, transport, resultHandler, false);
1590
        this.warehouse_id = warehouse_id;
1591
      }
1592
 
1593
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1594
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllItemsForWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1595
        getAllItemsForWarehouse_args args = new getAllItemsForWarehouse_args();
1596
        args.setWarehouse_id(warehouse_id);
1597
        args.write(prot);
1598
        prot.writeMessageEnd();
1599
      }
1600
 
1601
      public List<Long> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1602
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1603
          throw new IllegalStateException("Method call not finished!");
1604
        }
1605
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1606
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1607
        return (new Client(prot)).recv_getAllItemsForWarehouse();
1608
      }
1609
    }
1610
 
1611
    public void reserveItemInWarehouse(long itemId, long warehouseId, double quantity, org.apache.thrift.async.AsyncMethodCallback<reserveItemInWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1612
      checkReady();
1613
      reserveItemInWarehouse_call method_call = new reserveItemInWarehouse_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
1614
      this.___currentMethod = method_call;
1615
      ___manager.call(method_call);
1616
    }
1617
 
1618
    public static class reserveItemInWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1619
      private long itemId;
1620
      private long warehouseId;
1621
      private double quantity;
1622
      public reserveItemInWarehouse_call(long itemId, long warehouseId, 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 {
1623
        super(client, protocolFactory, transport, resultHandler, false);
1624
        this.itemId = itemId;
1625
        this.warehouseId = warehouseId;
1626
        this.quantity = quantity;
1627
      }
1628
 
1629
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1630
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("reserveItemInWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1631
        reserveItemInWarehouse_args args = new reserveItemInWarehouse_args();
1632
        args.setItemId(itemId);
1633
        args.setWarehouseId(warehouseId);
1634
        args.setQuantity(quantity);
1635
        args.write(prot);
1636
        prot.writeMessageEnd();
1637
      }
1638
 
1639
      public boolean getResult() throws InventoryServiceException, org.apache.thrift.TException {
1640
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1641
          throw new IllegalStateException("Method call not finished!");
1642
        }
1643
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1644
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1645
        return (new Client(prot)).recv_reserveItemInWarehouse();
1646
      }
1647
    }
1648
 
1649
    public void reduceReservationCount(long itemId, long warehouseId, double quantity, org.apache.thrift.async.AsyncMethodCallback<reduceReservationCount_call> resultHandler) throws org.apache.thrift.TException {
1650
      checkReady();
1651
      reduceReservationCount_call method_call = new reduceReservationCount_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
1652
      this.___currentMethod = method_call;
1653
      ___manager.call(method_call);
1654
    }
1655
 
1656
    public static class reduceReservationCount_call extends org.apache.thrift.async.TAsyncMethodCall {
1657
      private long itemId;
1658
      private long warehouseId;
1659
      private double quantity;
1660
      public reduceReservationCount_call(long itemId, long warehouseId, 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 {
1661
        super(client, protocolFactory, transport, resultHandler, false);
1662
        this.itemId = itemId;
1663
        this.warehouseId = warehouseId;
1664
        this.quantity = quantity;
1665
      }
1666
 
1667
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1668
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("reduceReservationCount", org.apache.thrift.protocol.TMessageType.CALL, 0));
1669
        reduceReservationCount_args args = new reduceReservationCount_args();
1670
        args.setItemId(itemId);
1671
        args.setWarehouseId(warehouseId);
1672
        args.setQuantity(quantity);
1673
        args.write(prot);
1674
        prot.writeMessageEnd();
1675
      }
1676
 
1677
      public boolean getResult() throws InventoryServiceException, org.apache.thrift.TException {
1678
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1679
          throw new IllegalStateException("Method call not finished!");
1680
        }
1681
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1682
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1683
        return (new Client(prot)).recv_reduceReservationCount();
1684
      }
1685
    }
1686
 
1687
    public void getItemPricing(long itemId, long vendorId, org.apache.thrift.async.AsyncMethodCallback<getItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1688
      checkReady();
1689
      getItemPricing_call method_call = new getItemPricing_call(itemId, vendorId, resultHandler, this, ___protocolFactory, ___transport);
1690
      this.___currentMethod = method_call;
1691
      ___manager.call(method_call);
1692
    }
1693
 
1694
    public static class getItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1695
      private long itemId;
1696
      private long vendorId;
1697
      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 {
1698
        super(client, protocolFactory, transport, resultHandler, false);
1699
        this.itemId = itemId;
1700
        this.vendorId = vendorId;
1701
      }
1702
 
1703
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1704
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1705
        getItemPricing_args args = new getItemPricing_args();
1706
        args.setItemId(itemId);
1707
        args.setVendorId(vendorId);
1708
        args.write(prot);
1709
        prot.writeMessageEnd();
1710
      }
1711
 
1712
      public VendorItemPricing getResult() throws InventoryServiceException, org.apache.thrift.TException {
1713
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1714
          throw new IllegalStateException("Method call not finished!");
1715
        }
1716
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1717
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1718
        return (new Client(prot)).recv_getItemPricing();
1719
      }
1720
    }
1721
 
1722
    public void getAllItemPricing(long itemId, org.apache.thrift.async.AsyncMethodCallback<getAllItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1723
      checkReady();
1724
      getAllItemPricing_call method_call = new getAllItemPricing_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1725
      this.___currentMethod = method_call;
1726
      ___manager.call(method_call);
1727
    }
1728
 
1729
    public static class getAllItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1730
      private long itemId;
1731
      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 {
1732
        super(client, protocolFactory, transport, resultHandler, false);
1733
        this.itemId = itemId;
1734
      }
1735
 
1736
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1737
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1738
        getAllItemPricing_args args = new getAllItemPricing_args();
1739
        args.setItemId(itemId);
1740
        args.write(prot);
1741
        prot.writeMessageEnd();
1742
      }
1743
 
1744
      public List<VendorItemPricing> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1745
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1746
          throw new IllegalStateException("Method call not finished!");
1747
        }
1748
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1749
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1750
        return (new Client(prot)).recv_getAllItemPricing();
1751
      }
1752
    }
1753
 
1754
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing, org.apache.thrift.async.AsyncMethodCallback<addVendorItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1755
      checkReady();
1756
      addVendorItemPricing_call method_call = new addVendorItemPricing_call(vendorItemPricing, resultHandler, this, ___protocolFactory, ___transport);
1757
      this.___currentMethod = method_call;
1758
      ___manager.call(method_call);
1759
    }
1760
 
1761
    public static class addVendorItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1762
      private VendorItemPricing vendorItemPricing;
1763
      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 {
1764
        super(client, protocolFactory, transport, resultHandler, false);
1765
        this.vendorItemPricing = vendorItemPricing;
1766
      }
1767
 
1768
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1769
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendorItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1770
        addVendorItemPricing_args args = new addVendorItemPricing_args();
1771
        args.setVendorItemPricing(vendorItemPricing);
1772
        args.write(prot);
1773
        prot.writeMessageEnd();
1774
      }
1775
 
1776
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1777
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1778
          throw new IllegalStateException("Method call not finished!");
1779
        }
1780
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1781
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1782
        (new Client(prot)).recv_addVendorItemPricing();
1783
      }
1784
    }
1785
 
1786
    public void getVendor(long vendorId, org.apache.thrift.async.AsyncMethodCallback<getVendor_call> resultHandler) throws org.apache.thrift.TException {
1787
      checkReady();
1788
      getVendor_call method_call = new getVendor_call(vendorId, resultHandler, this, ___protocolFactory, ___transport);
1789
      this.___currentMethod = method_call;
1790
      ___manager.call(method_call);
1791
    }
1792
 
1793
    public static class getVendor_call extends org.apache.thrift.async.TAsyncMethodCall {
1794
      private long vendorId;
1795
      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 {
1796
        super(client, protocolFactory, transport, resultHandler, false);
1797
        this.vendorId = vendorId;
1798
      }
1799
 
1800
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1801
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getVendor", org.apache.thrift.protocol.TMessageType.CALL, 0));
1802
        getVendor_args args = new getVendor_args();
1803
        args.setVendorId(vendorId);
1804
        args.write(prot);
1805
        prot.writeMessageEnd();
1806
      }
1807
 
1808
      public Vendor getResult() throws org.apache.thrift.TException {
1809
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1810
          throw new IllegalStateException("Method call not finished!");
1811
        }
1812
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1813
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1814
        return (new Client(prot)).recv_getVendor();
1815
      }
1816
    }
1817
 
1818
    public void getAllVendors(org.apache.thrift.async.AsyncMethodCallback<getAllVendors_call> resultHandler) throws org.apache.thrift.TException {
1819
      checkReady();
1820
      getAllVendors_call method_call = new getAllVendors_call(resultHandler, this, ___protocolFactory, ___transport);
1821
      this.___currentMethod = method_call;
1822
      ___manager.call(method_call);
1823
    }
1824
 
1825
    public static class getAllVendors_call extends org.apache.thrift.async.TAsyncMethodCall {
1826
      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 {
1827
        super(client, protocolFactory, transport, resultHandler, false);
1828
      }
1829
 
1830
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1831
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllVendors", org.apache.thrift.protocol.TMessageType.CALL, 0));
1832
        getAllVendors_args args = new getAllVendors_args();
1833
        args.write(prot);
1834
        prot.writeMessageEnd();
1835
      }
1836
 
1837
      public List<Vendor> getResult() throws org.apache.thrift.TException {
1838
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1839
          throw new IllegalStateException("Method call not finished!");
1840
        }
1841
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1842
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1843
        return (new Client(prot)).recv_getAllVendors();
1844
      }
1845
    }
1846
 
1847
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping, org.apache.thrift.async.AsyncMethodCallback<addVendorItemMapping_call> resultHandler) throws org.apache.thrift.TException {
1848
      checkReady();
1849
      addVendorItemMapping_call method_call = new addVendorItemMapping_call(key, vendorItemMapping, resultHandler, this, ___protocolFactory, ___transport);
1850
      this.___currentMethod = method_call;
1851
      ___manager.call(method_call);
1852
    }
1853
 
1854
    public static class addVendorItemMapping_call extends org.apache.thrift.async.TAsyncMethodCall {
1855
      private String key;
1856
      private VendorItemMapping vendorItemMapping;
1857
      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 {
1858
        super(client, protocolFactory, transport, resultHandler, false);
1859
        this.key = key;
1860
        this.vendorItemMapping = vendorItemMapping;
1861
      }
1862
 
1863
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1864
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendorItemMapping", org.apache.thrift.protocol.TMessageType.CALL, 0));
1865
        addVendorItemMapping_args args = new addVendorItemMapping_args();
1866
        args.setKey(key);
1867
        args.setVendorItemMapping(vendorItemMapping);
1868
        args.write(prot);
1869
        prot.writeMessageEnd();
1870
      }
1871
 
1872
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1873
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1874
          throw new IllegalStateException("Method call not finished!");
1875
        }
1876
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1877
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1878
        (new Client(prot)).recv_addVendorItemMapping();
1879
      }
1880
    }
1881
 
1882
    public void getVendorItemMappings(long itemId, org.apache.thrift.async.AsyncMethodCallback<getVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException {
1883
      checkReady();
1884
      getVendorItemMappings_call method_call = new getVendorItemMappings_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1885
      this.___currentMethod = method_call;
1886
      ___manager.call(method_call);
1887
    }
1888
 
1889
    public static class getVendorItemMappings_call extends org.apache.thrift.async.TAsyncMethodCall {
1890
      private long itemId;
1891
      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 {
1892
        super(client, protocolFactory, transport, resultHandler, false);
1893
        this.itemId = itemId;
1894
      }
1895
 
1896
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1897
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getVendorItemMappings", org.apache.thrift.protocol.TMessageType.CALL, 0));
1898
        getVendorItemMappings_args args = new getVendorItemMappings_args();
1899
        args.setItemId(itemId);
1900
        args.write(prot);
1901
        prot.writeMessageEnd();
1902
      }
1903
 
1904
      public List<VendorItemMapping> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1905
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1906
          throw new IllegalStateException("Method call not finished!");
1907
        }
1908
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1909
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1910
        return (new Client(prot)).recv_getVendorItemMappings();
1911
      }
1912
    }
1913
 
1914
    public void getPendingOrdersInventory(long vendorid, org.apache.thrift.async.AsyncMethodCallback<getPendingOrdersInventory_call> resultHandler) throws org.apache.thrift.TException {
1915
      checkReady();
1916
      getPendingOrdersInventory_call method_call = new getPendingOrdersInventory_call(vendorid, resultHandler, this, ___protocolFactory, ___transport);
1917
      this.___currentMethod = method_call;
1918
      ___manager.call(method_call);
1919
    }
1920
 
1921
    public static class getPendingOrdersInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
1922
      private long vendorid;
1923
      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 {
1924
        super(client, protocolFactory, transport, resultHandler, false);
1925
        this.vendorid = vendorid;
1926
      }
1927
 
1928
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1929
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPendingOrdersInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1930
        getPendingOrdersInventory_args args = new getPendingOrdersInventory_args();
1931
        args.setVendorid(vendorid);
1932
        args.write(prot);
1933
        prot.writeMessageEnd();
1934
      }
1935
 
1936
      public List<AvailableAndReservedStock> getResult() throws org.apache.thrift.TException {
1937
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1938
          throw new IllegalStateException("Method call not finished!");
1939
        }
1940
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1941
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1942
        return (new Client(prot)).recv_getPendingOrdersInventory();
1943
      }
1944
    }
1945
 
1946
    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 {
1947
      checkReady();
1948
      getWarehouses_call method_call = new getWarehouses_call(warehouseType, inventoryType, vendorId, billingWarehouseId, shippingWarehouseId, resultHandler, this, ___protocolFactory, ___transport);
1949
      this.___currentMethod = method_call;
1950
      ___manager.call(method_call);
1951
    }
1952
 
1953
    public static class getWarehouses_call extends org.apache.thrift.async.TAsyncMethodCall {
1954
      private WarehouseType warehouseType;
1955
      private InventoryType inventoryType;
1956
      private long vendorId;
1957
      private long billingWarehouseId;
1958
      private long shippingWarehouseId;
1959
      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 {
1960
        super(client, protocolFactory, transport, resultHandler, false);
1961
        this.warehouseType = warehouseType;
1962
        this.inventoryType = inventoryType;
1963
        this.vendorId = vendorId;
1964
        this.billingWarehouseId = billingWarehouseId;
1965
        this.shippingWarehouseId = shippingWarehouseId;
1966
      }
1967
 
1968
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1969
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getWarehouses", org.apache.thrift.protocol.TMessageType.CALL, 0));
1970
        getWarehouses_args args = new getWarehouses_args();
1971
        args.setWarehouseType(warehouseType);
1972
        args.setInventoryType(inventoryType);
1973
        args.setVendorId(vendorId);
1974
        args.setBillingWarehouseId(billingWarehouseId);
1975
        args.setShippingWarehouseId(shippingWarehouseId);
1976
        args.write(prot);
1977
        prot.writeMessageEnd();
1978
      }
1979
 
1980
      public List<Warehouse> getResult() throws org.apache.thrift.TException {
1981
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1982
          throw new IllegalStateException("Method call not finished!");
1983
        }
1984
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1985
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1986
        return (new Client(prot)).recv_getWarehouses();
1987
      }
1988
    }
1989
 
1990
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailability_call> resultHandler) throws org.apache.thrift.TException {
1991
      checkReady();
1992
      resetAvailability_call method_call = new resetAvailability_call(itemKey, vendorId, quantity, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
1993
      this.___currentMethod = method_call;
1994
      ___manager.call(method_call);
1995
    }
1996
 
1997
    public static class resetAvailability_call extends org.apache.thrift.async.TAsyncMethodCall {
1998
      private String itemKey;
1999
      private long vendorId;
2000
      private long quantity;
2001
      private long warehouseId;
2002
      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 {
2003
        super(client, protocolFactory, transport, resultHandler, false);
2004
        this.itemKey = itemKey;
2005
        this.vendorId = vendorId;
2006
        this.quantity = quantity;
2007
        this.warehouseId = warehouseId;
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("resetAvailability", org.apache.thrift.protocol.TMessageType.CALL, 0));
2012
        resetAvailability_args args = new resetAvailability_args();
2013
        args.setItemKey(itemKey);
2014
        args.setVendorId(vendorId);
2015
        args.setQuantity(quantity);
2016
        args.setWarehouseId(warehouseId);
2017
        args.write(prot);
2018
        prot.writeMessageEnd();
2019
      }
2020
 
2021
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2022
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2023
          throw new IllegalStateException("Method call not finished!");
2024
        }
2025
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2026
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2027
        (new Client(prot)).recv_resetAvailability();
2028
      }
2029
    }
2030
 
2031
    public void resetAvailabilityForWarehouse(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailabilityForWarehouse_call> resultHandler) throws org.apache.thrift.TException {
2032
      checkReady();
2033
      resetAvailabilityForWarehouse_call method_call = new resetAvailabilityForWarehouse_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2034
      this.___currentMethod = method_call;
2035
      ___manager.call(method_call);
2036
    }
2037
 
2038
    public static class resetAvailabilityForWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
2039
      private long warehouseId;
2040
      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 {
2041
        super(client, protocolFactory, transport, resultHandler, false);
2042
        this.warehouseId = warehouseId;
2043
      }
2044
 
2045
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2046
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("resetAvailabilityForWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
2047
        resetAvailabilityForWarehouse_args args = new resetAvailabilityForWarehouse_args();
2048
        args.setWarehouseId(warehouseId);
2049
        args.write(prot);
2050
        prot.writeMessageEnd();
2051
      }
2052
 
2053
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2054
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2055
          throw new IllegalStateException("Method call not finished!");
2056
        }
2057
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2058
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2059
        (new Client(prot)).recv_resetAvailabilityForWarehouse();
2060
      }
2061
    }
2062
 
2063
    public void getItemKeysToBeProcessed(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getItemKeysToBeProcessed_call> resultHandler) throws org.apache.thrift.TException {
2064
      checkReady();
2065
      getItemKeysToBeProcessed_call method_call = new getItemKeysToBeProcessed_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2066
      this.___currentMethod = method_call;
2067
      ___manager.call(method_call);
2068
    }
2069
 
2070
    public static class getItemKeysToBeProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
2071
      private long warehouseId;
2072
      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 {
2073
        super(client, protocolFactory, transport, resultHandler, false);
2074
        this.warehouseId = warehouseId;
2075
      }
2076
 
2077
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2078
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemKeysToBeProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
2079
        getItemKeysToBeProcessed_args args = new getItemKeysToBeProcessed_args();
2080
        args.setWarehouseId(warehouseId);
2081
        args.write(prot);
2082
        prot.writeMessageEnd();
2083
      }
2084
 
2085
      public List<String> getResult() throws org.apache.thrift.TException {
2086
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2087
          throw new IllegalStateException("Method call not finished!");
2088
        }
2089
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2090
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2091
        return (new Client(prot)).recv_getItemKeysToBeProcessed();
2092
      }
2093
    }
2094
 
2095
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<markMissedInventoryUpdatesAsProcessed_call> resultHandler) throws org.apache.thrift.TException {
2096
      checkReady();
2097
      markMissedInventoryUpdatesAsProcessed_call method_call = new markMissedInventoryUpdatesAsProcessed_call(itemKey, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2098
      this.___currentMethod = method_call;
2099
      ___manager.call(method_call);
2100
    }
2101
 
2102
    public static class markMissedInventoryUpdatesAsProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
2103
      private String itemKey;
2104
      private long warehouseId;
2105
      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 {
2106
        super(client, protocolFactory, transport, resultHandler, false);
2107
        this.itemKey = itemKey;
2108
        this.warehouseId = warehouseId;
2109
      }
2110
 
2111
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2112
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("markMissedInventoryUpdatesAsProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
2113
        markMissedInventoryUpdatesAsProcessed_args args = new markMissedInventoryUpdatesAsProcessed_args();
2114
        args.setItemKey(itemKey);
2115
        args.setWarehouseId(warehouseId);
2116
        args.write(prot);
2117
        prot.writeMessageEnd();
2118
      }
2119
 
2120
      public void getResult() throws org.apache.thrift.TException {
2121
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2122
          throw new IllegalStateException("Method call not finished!");
2123
        }
2124
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2125
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2126
        (new Client(prot)).recv_markMissedInventoryUpdatesAsProcessed();
2127
      }
2128
    }
2129
 
2130
    public void getIgnoredItemKeys(org.apache.thrift.async.AsyncMethodCallback<getIgnoredItemKeys_call> resultHandler) throws org.apache.thrift.TException {
2131
      checkReady();
2132
      getIgnoredItemKeys_call method_call = new getIgnoredItemKeys_call(resultHandler, this, ___protocolFactory, ___transport);
2133
      this.___currentMethod = method_call;
2134
      ___manager.call(method_call);
2135
    }
2136
 
2137
    public static class getIgnoredItemKeys_call extends org.apache.thrift.async.TAsyncMethodCall {
2138
      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 {
2139
        super(client, protocolFactory, transport, resultHandler, false);
2140
      }
2141
 
2142
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2143
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getIgnoredItemKeys", org.apache.thrift.protocol.TMessageType.CALL, 0));
2144
        getIgnoredItemKeys_args args = new getIgnoredItemKeys_args();
2145
        args.write(prot);
2146
        prot.writeMessageEnd();
2147
      }
2148
 
2149
      public Map<String,Map<Long,Long>> getResult() throws org.apache.thrift.TException {
2150
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2151
          throw new IllegalStateException("Method call not finished!");
2152
        }
2153
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2154
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2155
        return (new Client(prot)).recv_getIgnoredItemKeys();
2156
      }
2157
    }
2158
 
2159
    public void addBadInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addBadInventory_call> resultHandler) throws org.apache.thrift.TException {
2160
      checkReady();
2161
      addBadInventory_call method_call = new addBadInventory_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
2162
      this.___currentMethod = method_call;
2163
      ___manager.call(method_call);
2164
    }
2165
 
2166
    public static class addBadInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
2167
      private long itemId;
2168
      private long warehouseId;
2169
      private long quantity;
2170
      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 {
2171
        super(client, protocolFactory, transport, resultHandler, false);
2172
        this.itemId = itemId;
2173
        this.warehouseId = warehouseId;
2174
        this.quantity = quantity;
2175
      }
2176
 
2177
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2178
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addBadInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
2179
        addBadInventory_args args = new addBadInventory_args();
2180
        args.setItemId(itemId);
2181
        args.setWarehouseId(warehouseId);
2182
        args.setQuantity(quantity);
2183
        args.write(prot);
2184
        prot.writeMessageEnd();
2185
      }
2186
 
2187
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2188
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2189
          throw new IllegalStateException("Method call not finished!");
2190
        }
2191
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2192
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2193
        (new Client(prot)).recv_addBadInventory();
2194
      }
2195
    }
2196
 
2197
    public void getShippingLocations(org.apache.thrift.async.AsyncMethodCallback<getShippingLocations_call> resultHandler) throws org.apache.thrift.TException {
2198
      checkReady();
2199
      getShippingLocations_call method_call = new getShippingLocations_call(resultHandler, this, ___protocolFactory, ___transport);
2200
      this.___currentMethod = method_call;
2201
      ___manager.call(method_call);
2202
    }
2203
 
2204
    public static class getShippingLocations_call extends org.apache.thrift.async.TAsyncMethodCall {
2205
      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 {
2206
        super(client, protocolFactory, transport, resultHandler, false);
2207
      }
2208
 
2209
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2210
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getShippingLocations", org.apache.thrift.protocol.TMessageType.CALL, 0));
2211
        getShippingLocations_args args = new getShippingLocations_args();
2212
        args.write(prot);
2213
        prot.writeMessageEnd();
2214
      }
2215
 
2216
      public List<Warehouse> getResult() throws org.apache.thrift.TException {
2217
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2218
          throw new IllegalStateException("Method call not finished!");
2219
        }
2220
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2221
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2222
        return (new Client(prot)).recv_getShippingLocations();
2223
      }
2224
    }
2225
 
2226
    public void getAllVendorItemMappings(org.apache.thrift.async.AsyncMethodCallback<getAllVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException {
2227
      checkReady();
2228
      getAllVendorItemMappings_call method_call = new getAllVendorItemMappings_call(resultHandler, this, ___protocolFactory, ___transport);
2229
      this.___currentMethod = method_call;
2230
      ___manager.call(method_call);
2231
    }
2232
 
2233
    public static class getAllVendorItemMappings_call extends org.apache.thrift.async.TAsyncMethodCall {
2234
      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 {
2235
        super(client, protocolFactory, transport, resultHandler, false);
2236
      }
2237
 
2238
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2239
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllVendorItemMappings", org.apache.thrift.protocol.TMessageType.CALL, 0));
2240
        getAllVendorItemMappings_args args = new getAllVendorItemMappings_args();
2241
        args.write(prot);
2242
        prot.writeMessageEnd();
2243
      }
2244
 
2245
      public List<VendorItemMapping> getResult() throws org.apache.thrift.TException {
2246
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2247
          throw new IllegalStateException("Method call not finished!");
2248
        }
2249
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2250
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2251
        return (new Client(prot)).recv_getAllVendorItemMappings();
2252
      }
2253
    }
2254
 
2255
    public void getInventorySnapshot(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getInventorySnapshot_call> resultHandler) throws org.apache.thrift.TException {
2256
      checkReady();
2257
      getInventorySnapshot_call method_call = new getInventorySnapshot_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2258
      this.___currentMethod = method_call;
2259
      ___manager.call(method_call);
2260
    }
2261
 
2262
    public static class getInventorySnapshot_call extends org.apache.thrift.async.TAsyncMethodCall {
2263
      private long warehouseId;
2264
      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 {
2265
        super(client, protocolFactory, transport, resultHandler, false);
2266
        this.warehouseId = warehouseId;
2267
      }
2268
 
2269
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2270
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventorySnapshot", org.apache.thrift.protocol.TMessageType.CALL, 0));
2271
        getInventorySnapshot_args args = new getInventorySnapshot_args();
2272
        args.setWarehouseId(warehouseId);
2273
        args.write(prot);
2274
        prot.writeMessageEnd();
2275
      }
2276
 
2277
      public Map<Long,ItemInventory> getResult() throws org.apache.thrift.TException {
2278
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2279
          throw new IllegalStateException("Method call not finished!");
2280
        }
2281
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2282
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2283
        return (new Client(prot)).recv_getInventorySnapshot();
2284
      }
2285
    }
2286
 
2287
    public void clearItemAvailabilityCache(org.apache.thrift.async.AsyncMethodCallback<clearItemAvailabilityCache_call> resultHandler) throws org.apache.thrift.TException {
2288
      checkReady();
2289
      clearItemAvailabilityCache_call method_call = new clearItemAvailabilityCache_call(resultHandler, this, ___protocolFactory, ___transport);
2290
      this.___currentMethod = method_call;
2291
      ___manager.call(method_call);
2292
    }
2293
 
2294
    public static class clearItemAvailabilityCache_call extends org.apache.thrift.async.TAsyncMethodCall {
2295
      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 {
2296
        super(client, protocolFactory, transport, resultHandler, false);
2297
      }
2298
 
2299
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2300
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("clearItemAvailabilityCache", org.apache.thrift.protocol.TMessageType.CALL, 0));
2301
        clearItemAvailabilityCache_args args = new clearItemAvailabilityCache_args();
2302
        args.write(prot);
2303
        prot.writeMessageEnd();
2304
      }
2305
 
2306
      public void getResult() throws org.apache.thrift.TException {
2307
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2308
          throw new IllegalStateException("Method call not finished!");
2309
        }
2310
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2311
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2312
        (new Client(prot)).recv_clearItemAvailabilityCache();
2313
      }
2314
    }
2315
 
2316
    public void updateVendorString(long warehouseId, String vendorString, org.apache.thrift.async.AsyncMethodCallback<updateVendorString_call> resultHandler) throws org.apache.thrift.TException {
2317
      checkReady();
2318
      updateVendorString_call method_call = new updateVendorString_call(warehouseId, vendorString, resultHandler, this, ___protocolFactory, ___transport);
2319
      this.___currentMethod = method_call;
2320
      ___manager.call(method_call);
2321
    }
2322
 
2323
    public static class updateVendorString_call extends org.apache.thrift.async.TAsyncMethodCall {
2324
      private long warehouseId;
2325
      private String vendorString;
2326
      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 {
2327
        super(client, protocolFactory, transport, resultHandler, false);
2328
        this.warehouseId = warehouseId;
2329
        this.vendorString = vendorString;
2330
      }
2331
 
2332
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2333
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateVendorString", org.apache.thrift.protocol.TMessageType.CALL, 0));
2334
        updateVendorString_args args = new updateVendorString_args();
2335
        args.setWarehouseId(warehouseId);
2336
        args.setVendorString(vendorString);
2337
        args.write(prot);
2338
        prot.writeMessageEnd();
2339
      }
2340
 
2341
      public void getResult() throws org.apache.thrift.TException {
2342
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2343
          throw new IllegalStateException("Method call not finished!");
2344
        }
2345
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2346
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2347
        (new Client(prot)).recv_updateVendorString();
2348
      }
2349
    }
2350
 
2351
  }
2352
 
2353
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
2354
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
2355
    public Processor(I iface) {
2356
      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
2357
    }
2358
 
2359
    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
2360
      super(iface, getProcessMap(processMap));
2361
    }
2362
 
2363
    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) {
2364
      processMap.put("addWarehouse", new addWarehouse());
2365
      processMap.put("addVendor", new addVendor());
2366
      processMap.put("updateInventoryHistory", new updateInventoryHistory());
2367
      processMap.put("updateInventory", new updateInventory());
2368
      processMap.put("addInventory", new addInventory());
2369
      processMap.put("retireWarehouse", new retireWarehouse());
2370
      processMap.put("getItemInventoryByItemId", new getItemInventoryByItemId());
2371
      processMap.put("getItemAvailibilityAtWarehouse", new getItemAvailibilityAtWarehouse());
2372
      processMap.put("getItemAvailabilityAtLocation", new getItemAvailabilityAtLocation());
2373
      processMap.put("getAllWarehouses", new getAllWarehouses());
2374
      processMap.put("getWarehouse", new getWarehouse());
2375
      processMap.put("getAllItemsForWarehouse", new getAllItemsForWarehouse());
2376
      processMap.put("reserveItemInWarehouse", new reserveItemInWarehouse());
2377
      processMap.put("reduceReservationCount", new reduceReservationCount());
2378
      processMap.put("getItemPricing", new getItemPricing());
2379
      processMap.put("getAllItemPricing", new getAllItemPricing());
2380
      processMap.put("addVendorItemPricing", new addVendorItemPricing());
2381
      processMap.put("getVendor", new getVendor());
2382
      processMap.put("getAllVendors", new getAllVendors());
2383
      processMap.put("addVendorItemMapping", new addVendorItemMapping());
2384
      processMap.put("getVendorItemMappings", new getVendorItemMappings());
2385
      processMap.put("getPendingOrdersInventory", new getPendingOrdersInventory());
2386
      processMap.put("getWarehouses", new getWarehouses());
2387
      processMap.put("resetAvailability", new resetAvailability());
2388
      processMap.put("resetAvailabilityForWarehouse", new resetAvailabilityForWarehouse());
2389
      processMap.put("getItemKeysToBeProcessed", new getItemKeysToBeProcessed());
2390
      processMap.put("markMissedInventoryUpdatesAsProcessed", new markMissedInventoryUpdatesAsProcessed());
2391
      processMap.put("getIgnoredItemKeys", new getIgnoredItemKeys());
2392
      processMap.put("addBadInventory", new addBadInventory());
2393
      processMap.put("getShippingLocations", new getShippingLocations());
2394
      processMap.put("getAllVendorItemMappings", new getAllVendorItemMappings());
2395
      processMap.put("getInventorySnapshot", new getInventorySnapshot());
2396
      processMap.put("clearItemAvailabilityCache", new clearItemAvailabilityCache());
2397
      processMap.put("updateVendorString", new updateVendorString());
2398
      return processMap;
2399
    }
2400
 
2401
    private static class addWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addWarehouse_args> {
2402
      public addWarehouse() {
2403
        super("addWarehouse");
2404
      }
2405
 
2406
      protected addWarehouse_args getEmptyArgsInstance() {
2407
        return new addWarehouse_args();
2408
      }
2409
 
2410
      protected addWarehouse_result getResult(I iface, addWarehouse_args args) throws org.apache.thrift.TException {
2411
        addWarehouse_result result = new addWarehouse_result();
2412
        try {
2413
          result.success = iface.addWarehouse(args.warehouse);
2414
          result.setSuccessIsSet(true);
2415
        } catch (InventoryServiceException cex) {
2416
          result.cex = cex;
2417
        }
2418
        return result;
2419
      }
2420
    }
2421
 
2422
    private static class addVendor<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendor_args> {
2423
      public addVendor() {
2424
        super("addVendor");
2425
      }
2426
 
2427
      protected addVendor_args getEmptyArgsInstance() {
2428
        return new addVendor_args();
2429
      }
2430
 
2431
      protected addVendor_result getResult(I iface, addVendor_args args) throws org.apache.thrift.TException {
2432
        addVendor_result result = new addVendor_result();
2433
        try {
2434
          result.success = iface.addVendor(args.vendor);
2435
          result.setSuccessIsSet(true);
2436
        } catch (InventoryServiceException cex) {
2437
          result.cex = cex;
2438
        }
2439
        return result;
2440
      }
2441
    }
2442
 
2443
    private static class updateInventoryHistory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateInventoryHistory_args> {
2444
      public updateInventoryHistory() {
2445
        super("updateInventoryHistory");
2446
      }
2447
 
2448
      protected updateInventoryHistory_args getEmptyArgsInstance() {
2449
        return new updateInventoryHistory_args();
2450
      }
2451
 
2452
      protected updateInventoryHistory_result getResult(I iface, updateInventoryHistory_args args) throws org.apache.thrift.TException {
2453
        updateInventoryHistory_result result = new updateInventoryHistory_result();
2454
        try {
2455
          iface.updateInventoryHistory(args.warehouse_id, args.timestamp, args.availability);
2456
        } catch (InventoryServiceException cex) {
2457
          result.cex = cex;
2458
        }
2459
        return result;
2460
      }
2461
    }
2462
 
2463
    private static class updateInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateInventory_args> {
2464
      public updateInventory() {
2465
        super("updateInventory");
2466
      }
2467
 
2468
      protected updateInventory_args getEmptyArgsInstance() {
2469
        return new updateInventory_args();
2470
      }
2471
 
2472
      protected updateInventory_result getResult(I iface, updateInventory_args args) throws org.apache.thrift.TException {
2473
        updateInventory_result result = new updateInventory_result();
2474
        try {
2475
          iface.updateInventory(args.warehouse_id, args.timestamp, args.availability);
2476
        } catch (InventoryServiceException cex) {
2477
          result.cex = cex;
2478
        }
2479
        return result;
2480
      }
2481
    }
2482
 
2483
    private static class addInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addInventory_args> {
2484
      public addInventory() {
2485
        super("addInventory");
2486
      }
2487
 
2488
      protected addInventory_args getEmptyArgsInstance() {
2489
        return new addInventory_args();
2490
      }
2491
 
2492
      protected addInventory_result getResult(I iface, addInventory_args args) throws org.apache.thrift.TException {
2493
        addInventory_result result = new addInventory_result();
2494
        try {
2495
          iface.addInventory(args.itemId, args.warehouseId, args.quantity);
2496
        } catch (InventoryServiceException cex) {
2497
          result.cex = cex;
2498
        }
2499
        return result;
2500
      }
2501
    }
2502
 
2503
    private static class retireWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, retireWarehouse_args> {
2504
      public retireWarehouse() {
2505
        super("retireWarehouse");
2506
      }
2507
 
2508
      protected retireWarehouse_args getEmptyArgsInstance() {
2509
        return new retireWarehouse_args();
2510
      }
2511
 
2512
      protected retireWarehouse_result getResult(I iface, retireWarehouse_args args) throws org.apache.thrift.TException {
2513
        retireWarehouse_result result = new retireWarehouse_result();
2514
        try {
2515
          iface.retireWarehouse(args.warehouse_id);
2516
        } catch (InventoryServiceException cex) {
2517
          result.cex = cex;
2518
        }
2519
        return result;
2520
      }
2521
    }
2522
 
2523
    private static class getItemInventoryByItemId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemInventoryByItemId_args> {
2524
      public getItemInventoryByItemId() {
2525
        super("getItemInventoryByItemId");
2526
      }
2527
 
2528
      protected getItemInventoryByItemId_args getEmptyArgsInstance() {
2529
        return new getItemInventoryByItemId_args();
2530
      }
2531
 
2532
      protected getItemInventoryByItemId_result getResult(I iface, getItemInventoryByItemId_args args) throws org.apache.thrift.TException {
2533
        getItemInventoryByItemId_result result = new getItemInventoryByItemId_result();
2534
        try {
2535
          result.success = iface.getItemInventoryByItemId(args.item_id);
2536
        } catch (InventoryServiceException cex) {
2537
          result.cex = cex;
2538
        }
2539
        return result;
2540
      }
2541
    }
2542
 
2543
    private static class getItemAvailibilityAtWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemAvailibilityAtWarehouse_args> {
2544
      public getItemAvailibilityAtWarehouse() {
2545
        super("getItemAvailibilityAtWarehouse");
2546
      }
2547
 
2548
      protected getItemAvailibilityAtWarehouse_args getEmptyArgsInstance() {
2549
        return new getItemAvailibilityAtWarehouse_args();
2550
      }
2551
 
2552
      protected getItemAvailibilityAtWarehouse_result getResult(I iface, getItemAvailibilityAtWarehouse_args args) throws org.apache.thrift.TException {
2553
        getItemAvailibilityAtWarehouse_result result = new getItemAvailibilityAtWarehouse_result();
2554
        try {
2555
          result.success = iface.getItemAvailibilityAtWarehouse(args.warehouse_id, args.item_id);
2556
          result.setSuccessIsSet(true);
2557
        } catch (InventoryServiceException cex) {
2558
          result.cex = cex;
2559
        }
2560
        return result;
2561
      }
2562
    }
2563
 
2564
    private static class getItemAvailabilityAtLocation<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemAvailabilityAtLocation_args> {
2565
      public getItemAvailabilityAtLocation() {
2566
        super("getItemAvailabilityAtLocation");
2567
      }
2568
 
2569
      protected getItemAvailabilityAtLocation_args getEmptyArgsInstance() {
2570
        return new getItemAvailabilityAtLocation_args();
2571
      }
2572
 
2573
      protected getItemAvailabilityAtLocation_result getResult(I iface, getItemAvailabilityAtLocation_args args) throws org.apache.thrift.TException {
2574
        getItemAvailabilityAtLocation_result result = new getItemAvailabilityAtLocation_result();
2575
        try {
2576
          result.success = iface.getItemAvailabilityAtLocation(args.itemId);
2577
        } catch (InventoryServiceException isex) {
2578
          result.isex = isex;
2579
        }
2580
        return result;
2581
      }
2582
    }
2583
 
2584
    private static class getAllWarehouses<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllWarehouses_args> {
2585
      public getAllWarehouses() {
2586
        super("getAllWarehouses");
2587
      }
2588
 
2589
      protected getAllWarehouses_args getEmptyArgsInstance() {
2590
        return new getAllWarehouses_args();
2591
      }
2592
 
2593
      protected getAllWarehouses_result getResult(I iface, getAllWarehouses_args args) throws org.apache.thrift.TException {
2594
        getAllWarehouses_result result = new getAllWarehouses_result();
2595
        try {
2596
          result.success = iface.getAllWarehouses(args.isActive);
2597
        } catch (InventoryServiceException cex) {
2598
          result.cex = cex;
2599
        }
2600
        return result;
2601
      }
2602
    }
2603
 
2604
    private static class getWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getWarehouse_args> {
2605
      public getWarehouse() {
2606
        super("getWarehouse");
2607
      }
2608
 
2609
      protected getWarehouse_args getEmptyArgsInstance() {
2610
        return new getWarehouse_args();
2611
      }
2612
 
2613
      protected getWarehouse_result getResult(I iface, getWarehouse_args args) throws org.apache.thrift.TException {
2614
        getWarehouse_result result = new getWarehouse_result();
2615
        try {
2616
          result.success = iface.getWarehouse(args.warehouse_id);
2617
        } catch (InventoryServiceException cex) {
2618
          result.cex = cex;
2619
        }
2620
        return result;
2621
      }
2622
    }
2623
 
2624
    private static class getAllItemsForWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllItemsForWarehouse_args> {
2625
      public getAllItemsForWarehouse() {
2626
        super("getAllItemsForWarehouse");
2627
      }
2628
 
2629
      protected getAllItemsForWarehouse_args getEmptyArgsInstance() {
2630
        return new getAllItemsForWarehouse_args();
2631
      }
2632
 
2633
      protected getAllItemsForWarehouse_result getResult(I iface, getAllItemsForWarehouse_args args) throws org.apache.thrift.TException {
2634
        getAllItemsForWarehouse_result result = new getAllItemsForWarehouse_result();
2635
        try {
2636
          result.success = iface.getAllItemsForWarehouse(args.warehouse_id);
2637
        } catch (InventoryServiceException cex) {
2638
          result.cex = cex;
2639
        }
2640
        return result;
2641
      }
2642
    }
2643
 
2644
    private static class reserveItemInWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, reserveItemInWarehouse_args> {
2645
      public reserveItemInWarehouse() {
2646
        super("reserveItemInWarehouse");
2647
      }
2648
 
2649
      protected reserveItemInWarehouse_args getEmptyArgsInstance() {
2650
        return new reserveItemInWarehouse_args();
2651
      }
2652
 
2653
      protected reserveItemInWarehouse_result getResult(I iface, reserveItemInWarehouse_args args) throws org.apache.thrift.TException {
2654
        reserveItemInWarehouse_result result = new reserveItemInWarehouse_result();
2655
        try {
2656
          result.success = iface.reserveItemInWarehouse(args.itemId, args.warehouseId, args.quantity);
2657
          result.setSuccessIsSet(true);
2658
        } catch (InventoryServiceException cex) {
2659
          result.cex = cex;
2660
        }
2661
        return result;
2662
      }
2663
    }
2664
 
2665
    private static class reduceReservationCount<I extends Iface> extends org.apache.thrift.ProcessFunction<I, reduceReservationCount_args> {
2666
      public reduceReservationCount() {
2667
        super("reduceReservationCount");
2668
      }
2669
 
2670
      protected reduceReservationCount_args getEmptyArgsInstance() {
2671
        return new reduceReservationCount_args();
2672
      }
2673
 
2674
      protected reduceReservationCount_result getResult(I iface, reduceReservationCount_args args) throws org.apache.thrift.TException {
2675
        reduceReservationCount_result result = new reduceReservationCount_result();
2676
        try {
2677
          result.success = iface.reduceReservationCount(args.itemId, args.warehouseId, args.quantity);
2678
          result.setSuccessIsSet(true);
2679
        } catch (InventoryServiceException cex) {
2680
          result.cex = cex;
2681
        }
2682
        return result;
2683
      }
2684
    }
2685
 
2686
    private static class getItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemPricing_args> {
2687
      public getItemPricing() {
2688
        super("getItemPricing");
2689
      }
2690
 
2691
      protected getItemPricing_args getEmptyArgsInstance() {
2692
        return new getItemPricing_args();
2693
      }
2694
 
2695
      protected getItemPricing_result getResult(I iface, getItemPricing_args args) throws org.apache.thrift.TException {
2696
        getItemPricing_result result = new getItemPricing_result();
2697
        try {
2698
          result.success = iface.getItemPricing(args.itemId, args.vendorId);
2699
        } catch (InventoryServiceException cex) {
2700
          result.cex = cex;
2701
        }
2702
        return result;
2703
      }
2704
    }
2705
 
2706
    private static class getAllItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllItemPricing_args> {
2707
      public getAllItemPricing() {
2708
        super("getAllItemPricing");
2709
      }
2710
 
2711
      protected getAllItemPricing_args getEmptyArgsInstance() {
2712
        return new getAllItemPricing_args();
2713
      }
2714
 
2715
      protected getAllItemPricing_result getResult(I iface, getAllItemPricing_args args) throws org.apache.thrift.TException {
2716
        getAllItemPricing_result result = new getAllItemPricing_result();
2717
        try {
2718
          result.success = iface.getAllItemPricing(args.itemId);
2719
        } catch (InventoryServiceException cex) {
2720
          result.cex = cex;
2721
        }
2722
        return result;
2723
      }
2724
    }
2725
 
2726
    private static class addVendorItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendorItemPricing_args> {
2727
      public addVendorItemPricing() {
2728
        super("addVendorItemPricing");
2729
      }
2730
 
2731
      protected addVendorItemPricing_args getEmptyArgsInstance() {
2732
        return new addVendorItemPricing_args();
2733
      }
2734
 
2735
      protected addVendorItemPricing_result getResult(I iface, addVendorItemPricing_args args) throws org.apache.thrift.TException {
2736
        addVendorItemPricing_result result = new addVendorItemPricing_result();
2737
        try {
2738
          iface.addVendorItemPricing(args.vendorItemPricing);
2739
        } catch (InventoryServiceException cex) {
2740
          result.cex = cex;
2741
        }
2742
        return result;
2743
      }
2744
    }
2745
 
2746
    private static class getVendor<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getVendor_args> {
2747
      public getVendor() {
2748
        super("getVendor");
2749
      }
2750
 
2751
      protected getVendor_args getEmptyArgsInstance() {
2752
        return new getVendor_args();
2753
      }
2754
 
2755
      protected getVendor_result getResult(I iface, getVendor_args args) throws org.apache.thrift.TException {
2756
        getVendor_result result = new getVendor_result();
2757
        result.success = iface.getVendor(args.vendorId);
2758
        return result;
2759
      }
2760
    }
2761
 
2762
    private static class getAllVendors<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllVendors_args> {
2763
      public getAllVendors() {
2764
        super("getAllVendors");
2765
      }
2766
 
2767
      protected getAllVendors_args getEmptyArgsInstance() {
2768
        return new getAllVendors_args();
2769
      }
2770
 
2771
      protected getAllVendors_result getResult(I iface, getAllVendors_args args) throws org.apache.thrift.TException {
2772
        getAllVendors_result result = new getAllVendors_result();
2773
        result.success = iface.getAllVendors();
2774
        return result;
2775
      }
2776
    }
2777
 
2778
    private static class addVendorItemMapping<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendorItemMapping_args> {
2779
      public addVendorItemMapping() {
2780
        super("addVendorItemMapping");
2781
      }
2782
 
2783
      protected addVendorItemMapping_args getEmptyArgsInstance() {
2784
        return new addVendorItemMapping_args();
2785
      }
2786
 
2787
      protected addVendorItemMapping_result getResult(I iface, addVendorItemMapping_args args) throws org.apache.thrift.TException {
2788
        addVendorItemMapping_result result = new addVendorItemMapping_result();
2789
        try {
2790
          iface.addVendorItemMapping(args.key, args.vendorItemMapping);
2791
        } catch (InventoryServiceException cex) {
2792
          result.cex = cex;
2793
        }
2794
        return result;
2795
      }
2796
    }
2797
 
2798
    private static class getVendorItemMappings<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getVendorItemMappings_args> {
2799
      public getVendorItemMappings() {
2800
        super("getVendorItemMappings");
2801
      }
2802
 
2803
      protected getVendorItemMappings_args getEmptyArgsInstance() {
2804
        return new getVendorItemMappings_args();
2805
      }
2806
 
2807
      protected getVendorItemMappings_result getResult(I iface, getVendorItemMappings_args args) throws org.apache.thrift.TException {
2808
        getVendorItemMappings_result result = new getVendorItemMappings_result();
2809
        try {
2810
          result.success = iface.getVendorItemMappings(args.itemId);
2811
        } catch (InventoryServiceException cex) {
2812
          result.cex = cex;
2813
        }
2814
        return result;
2815
      }
2816
    }
2817
 
2818
    private static class getPendingOrdersInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPendingOrdersInventory_args> {
2819
      public getPendingOrdersInventory() {
2820
        super("getPendingOrdersInventory");
2821
      }
2822
 
2823
      protected getPendingOrdersInventory_args getEmptyArgsInstance() {
2824
        return new getPendingOrdersInventory_args();
2825
      }
2826
 
2827
      protected getPendingOrdersInventory_result getResult(I iface, getPendingOrdersInventory_args args) throws org.apache.thrift.TException {
2828
        getPendingOrdersInventory_result result = new getPendingOrdersInventory_result();
2829
        result.success = iface.getPendingOrdersInventory(args.vendorid);
2830
        return result;
2831
      }
2832
    }
2833
 
2834
    private static class getWarehouses<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getWarehouses_args> {
2835
      public getWarehouses() {
2836
        super("getWarehouses");
2837
      }
2838
 
2839
      protected getWarehouses_args getEmptyArgsInstance() {
2840
        return new getWarehouses_args();
2841
      }
2842
 
2843
      protected getWarehouses_result getResult(I iface, getWarehouses_args args) throws org.apache.thrift.TException {
2844
        getWarehouses_result result = new getWarehouses_result();
2845
        result.success = iface.getWarehouses(args.warehouseType, args.inventoryType, args.vendorId, args.billingWarehouseId, args.shippingWarehouseId);
2846
        return result;
2847
      }
2848
    }
2849
 
2850
    private static class resetAvailability<I extends Iface> extends org.apache.thrift.ProcessFunction<I, resetAvailability_args> {
2851
      public resetAvailability() {
2852
        super("resetAvailability");
2853
      }
2854
 
2855
      protected resetAvailability_args getEmptyArgsInstance() {
2856
        return new resetAvailability_args();
2857
      }
2858
 
2859
      protected resetAvailability_result getResult(I iface, resetAvailability_args args) throws org.apache.thrift.TException {
2860
        resetAvailability_result result = new resetAvailability_result();
2861
        try {
2862
          iface.resetAvailability(args.itemKey, args.vendorId, args.quantity, args.warehouseId);
2863
        } catch (InventoryServiceException cex) {
2864
          result.cex = cex;
2865
        }
2866
        return result;
2867
      }
2868
    }
2869
 
2870
    private static class resetAvailabilityForWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, resetAvailabilityForWarehouse_args> {
2871
      public resetAvailabilityForWarehouse() {
2872
        super("resetAvailabilityForWarehouse");
2873
      }
2874
 
2875
      protected resetAvailabilityForWarehouse_args getEmptyArgsInstance() {
2876
        return new resetAvailabilityForWarehouse_args();
2877
      }
2878
 
2879
      protected resetAvailabilityForWarehouse_result getResult(I iface, resetAvailabilityForWarehouse_args args) throws org.apache.thrift.TException {
2880
        resetAvailabilityForWarehouse_result result = new resetAvailabilityForWarehouse_result();
2881
        try {
2882
          iface.resetAvailabilityForWarehouse(args.warehouseId);
2883
        } catch (InventoryServiceException cex) {
2884
          result.cex = cex;
2885
        }
2886
        return result;
2887
      }
2888
    }
2889
 
2890
    private static class getItemKeysToBeProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemKeysToBeProcessed_args> {
2891
      public getItemKeysToBeProcessed() {
2892
        super("getItemKeysToBeProcessed");
2893
      }
2894
 
2895
      protected getItemKeysToBeProcessed_args getEmptyArgsInstance() {
2896
        return new getItemKeysToBeProcessed_args();
2897
      }
2898
 
2899
      protected getItemKeysToBeProcessed_result getResult(I iface, getItemKeysToBeProcessed_args args) throws org.apache.thrift.TException {
2900
        getItemKeysToBeProcessed_result result = new getItemKeysToBeProcessed_result();
2901
        result.success = iface.getItemKeysToBeProcessed(args.warehouseId);
2902
        return result;
2903
      }
2904
    }
2905
 
2906
    private static class markMissedInventoryUpdatesAsProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, markMissedInventoryUpdatesAsProcessed_args> {
2907
      public markMissedInventoryUpdatesAsProcessed() {
2908
        super("markMissedInventoryUpdatesAsProcessed");
2909
      }
2910
 
2911
      protected markMissedInventoryUpdatesAsProcessed_args getEmptyArgsInstance() {
2912
        return new markMissedInventoryUpdatesAsProcessed_args();
2913
      }
2914
 
2915
      protected markMissedInventoryUpdatesAsProcessed_result getResult(I iface, markMissedInventoryUpdatesAsProcessed_args args) throws org.apache.thrift.TException {
2916
        markMissedInventoryUpdatesAsProcessed_result result = new markMissedInventoryUpdatesAsProcessed_result();
2917
        iface.markMissedInventoryUpdatesAsProcessed(args.itemKey, args.warehouseId);
2918
        return result;
2919
      }
2920
    }
2921
 
2922
    private static class getIgnoredItemKeys<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getIgnoredItemKeys_args> {
2923
      public getIgnoredItemKeys() {
2924
        super("getIgnoredItemKeys");
2925
      }
2926
 
2927
      protected getIgnoredItemKeys_args getEmptyArgsInstance() {
2928
        return new getIgnoredItemKeys_args();
2929
      }
2930
 
2931
      protected getIgnoredItemKeys_result getResult(I iface, getIgnoredItemKeys_args args) throws org.apache.thrift.TException {
2932
        getIgnoredItemKeys_result result = new getIgnoredItemKeys_result();
2933
        result.success = iface.getIgnoredItemKeys();
2934
        return result;
2935
      }
2936
    }
2937
 
2938
    private static class addBadInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addBadInventory_args> {
2939
      public addBadInventory() {
2940
        super("addBadInventory");
2941
      }
2942
 
2943
      protected addBadInventory_args getEmptyArgsInstance() {
2944
        return new addBadInventory_args();
2945
      }
2946
 
2947
      protected addBadInventory_result getResult(I iface, addBadInventory_args args) throws org.apache.thrift.TException {
2948
        addBadInventory_result result = new addBadInventory_result();
2949
        try {
2950
          iface.addBadInventory(args.itemId, args.warehouseId, args.quantity);
2951
        } catch (InventoryServiceException cex) {
2952
          result.cex = cex;
2953
        }
2954
        return result;
2955
      }
2956
    }
2957
 
2958
    private static class getShippingLocations<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getShippingLocations_args> {
2959
      public getShippingLocations() {
2960
        super("getShippingLocations");
2961
      }
2962
 
2963
      protected getShippingLocations_args getEmptyArgsInstance() {
2964
        return new getShippingLocations_args();
2965
      }
2966
 
2967
      protected getShippingLocations_result getResult(I iface, getShippingLocations_args args) throws org.apache.thrift.TException {
2968
        getShippingLocations_result result = new getShippingLocations_result();
2969
        result.success = iface.getShippingLocations();
2970
        return result;
2971
      }
2972
    }
2973
 
2974
    private static class getAllVendorItemMappings<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllVendorItemMappings_args> {
2975
      public getAllVendorItemMappings() {
2976
        super("getAllVendorItemMappings");
2977
      }
2978
 
2979
      protected getAllVendorItemMappings_args getEmptyArgsInstance() {
2980
        return new getAllVendorItemMappings_args();
2981
      }
2982
 
2983
      protected getAllVendorItemMappings_result getResult(I iface, getAllVendorItemMappings_args args) throws org.apache.thrift.TException {
2984
        getAllVendorItemMappings_result result = new getAllVendorItemMappings_result();
2985
        result.success = iface.getAllVendorItemMappings();
2986
        return result;
2987
      }
2988
    }
2989
 
2990
    private static class getInventorySnapshot<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventorySnapshot_args> {
2991
      public getInventorySnapshot() {
2992
        super("getInventorySnapshot");
2993
      }
2994
 
2995
      protected getInventorySnapshot_args getEmptyArgsInstance() {
2996
        return new getInventorySnapshot_args();
2997
      }
2998
 
2999
      protected getInventorySnapshot_result getResult(I iface, getInventorySnapshot_args args) throws org.apache.thrift.TException {
3000
        getInventorySnapshot_result result = new getInventorySnapshot_result();
3001
        result.success = iface.getInventorySnapshot(args.warehouseId);
3002
        return result;
3003
      }
3004
    }
3005
 
3006
    private static class clearItemAvailabilityCache<I extends Iface> extends org.apache.thrift.ProcessFunction<I, clearItemAvailabilityCache_args> {
3007
      public clearItemAvailabilityCache() {
3008
        super("clearItemAvailabilityCache");
3009
      }
3010
 
3011
      protected clearItemAvailabilityCache_args getEmptyArgsInstance() {
3012
        return new clearItemAvailabilityCache_args();
3013
      }
3014
 
3015
      protected clearItemAvailabilityCache_result getResult(I iface, clearItemAvailabilityCache_args args) throws org.apache.thrift.TException {
3016
        clearItemAvailabilityCache_result result = new clearItemAvailabilityCache_result();
3017
        iface.clearItemAvailabilityCache();
3018
        return result;
3019
      }
3020
    }
3021
 
3022
    private static class updateVendorString<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateVendorString_args> {
3023
      public updateVendorString() {
3024
        super("updateVendorString");
3025
      }
3026
 
3027
      protected updateVendorString_args getEmptyArgsInstance() {
3028
        return new updateVendorString_args();
3029
      }
3030
 
3031
      protected updateVendorString_result getResult(I iface, updateVendorString_args args) throws org.apache.thrift.TException {
3032
        updateVendorString_result result = new updateVendorString_result();
3033
        iface.updateVendorString(args.warehouseId, args.vendorString);
3034
        return result;
3035
      }
3036
    }
3037
 
3038
  }
3039
 
3040
  public static class addWarehouse_args implements org.apache.thrift.TBase<addWarehouse_args, addWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
3041
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addWarehouse_args");
3042
 
3043
    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);
3044
 
3045
    private Warehouse warehouse; // required
3046
 
3047
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3048
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3049
      WAREHOUSE((short)1, "warehouse");
3050
 
3051
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3052
 
3053
      static {
3054
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3055
          byName.put(field.getFieldName(), field);
3056
        }
3057
      }
3058
 
3059
      /**
3060
       * Find the _Fields constant that matches fieldId, or null if its not found.
3061
       */
3062
      public static _Fields findByThriftId(int fieldId) {
3063
        switch(fieldId) {
3064
          case 1: // WAREHOUSE
3065
            return WAREHOUSE;
3066
          default:
3067
            return null;
3068
        }
3069
      }
3070
 
3071
      /**
3072
       * Find the _Fields constant that matches fieldId, throwing an exception
3073
       * if it is not found.
3074
       */
3075
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3076
        _Fields fields = findByThriftId(fieldId);
3077
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3078
        return fields;
3079
      }
3080
 
3081
      /**
3082
       * Find the _Fields constant that matches name, or null if its not found.
3083
       */
3084
      public static _Fields findByName(String name) {
3085
        return byName.get(name);
3086
      }
3087
 
3088
      private final short _thriftId;
3089
      private final String _fieldName;
3090
 
3091
      _Fields(short thriftId, String fieldName) {
3092
        _thriftId = thriftId;
3093
        _fieldName = fieldName;
3094
      }
3095
 
3096
      public short getThriftFieldId() {
3097
        return _thriftId;
3098
      }
3099
 
3100
      public String getFieldName() {
3101
        return _fieldName;
3102
      }
3103
    }
3104
 
3105
    // isset id assignments
3106
 
3107
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3108
    static {
3109
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3110
      tmpMap.put(_Fields.WAREHOUSE, new org.apache.thrift.meta_data.FieldMetaData("warehouse", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3111
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class)));
3112
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3113
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addWarehouse_args.class, metaDataMap);
3114
    }
3115
 
3116
    public addWarehouse_args() {
3117
    }
3118
 
3119
    public addWarehouse_args(
3120
      Warehouse warehouse)
3121
    {
3122
      this();
3123
      this.warehouse = warehouse;
3124
    }
3125
 
3126
    /**
3127
     * Performs a deep copy on <i>other</i>.
3128
     */
3129
    public addWarehouse_args(addWarehouse_args other) {
3130
      if (other.isSetWarehouse()) {
3131
        this.warehouse = new Warehouse(other.warehouse);
3132
      }
3133
    }
3134
 
3135
    public addWarehouse_args deepCopy() {
3136
      return new addWarehouse_args(this);
3137
    }
3138
 
3139
    @Override
3140
    public void clear() {
3141
      this.warehouse = null;
3142
    }
3143
 
3144
    public Warehouse getWarehouse() {
3145
      return this.warehouse;
3146
    }
3147
 
3148
    public void setWarehouse(Warehouse warehouse) {
3149
      this.warehouse = warehouse;
3150
    }
3151
 
3152
    public void unsetWarehouse() {
3153
      this.warehouse = null;
3154
    }
3155
 
3156
    /** Returns true if field warehouse is set (has been assigned a value) and false otherwise */
3157
    public boolean isSetWarehouse() {
3158
      return this.warehouse != null;
3159
    }
3160
 
3161
    public void setWarehouseIsSet(boolean value) {
3162
      if (!value) {
3163
        this.warehouse = null;
3164
      }
3165
    }
3166
 
3167
    public void setFieldValue(_Fields field, Object value) {
3168
      switch (field) {
3169
      case WAREHOUSE:
3170
        if (value == null) {
3171
          unsetWarehouse();
3172
        } else {
3173
          setWarehouse((Warehouse)value);
3174
        }
3175
        break;
3176
 
3177
      }
3178
    }
3179
 
3180
    public Object getFieldValue(_Fields field) {
3181
      switch (field) {
3182
      case WAREHOUSE:
3183
        return getWarehouse();
3184
 
3185
      }
3186
      throw new IllegalStateException();
3187
    }
3188
 
3189
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3190
    public boolean isSet(_Fields field) {
3191
      if (field == null) {
3192
        throw new IllegalArgumentException();
3193
      }
3194
 
3195
      switch (field) {
3196
      case WAREHOUSE:
3197
        return isSetWarehouse();
3198
      }
3199
      throw new IllegalStateException();
3200
    }
3201
 
3202
    @Override
3203
    public boolean equals(Object that) {
3204
      if (that == null)
3205
        return false;
3206
      if (that instanceof addWarehouse_args)
3207
        return this.equals((addWarehouse_args)that);
3208
      return false;
3209
    }
3210
 
3211
    public boolean equals(addWarehouse_args that) {
3212
      if (that == null)
3213
        return false;
3214
 
3215
      boolean this_present_warehouse = true && this.isSetWarehouse();
3216
      boolean that_present_warehouse = true && that.isSetWarehouse();
3217
      if (this_present_warehouse || that_present_warehouse) {
3218
        if (!(this_present_warehouse && that_present_warehouse))
3219
          return false;
3220
        if (!this.warehouse.equals(that.warehouse))
3221
          return false;
3222
      }
3223
 
3224
      return true;
3225
    }
3226
 
3227
    @Override
3228
    public int hashCode() {
3229
      return 0;
3230
    }
3231
 
3232
    public int compareTo(addWarehouse_args other) {
3233
      if (!getClass().equals(other.getClass())) {
3234
        return getClass().getName().compareTo(other.getClass().getName());
3235
      }
3236
 
3237
      int lastComparison = 0;
3238
      addWarehouse_args typedOther = (addWarehouse_args)other;
3239
 
3240
      lastComparison = Boolean.valueOf(isSetWarehouse()).compareTo(typedOther.isSetWarehouse());
3241
      if (lastComparison != 0) {
3242
        return lastComparison;
3243
      }
3244
      if (isSetWarehouse()) {
3245
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse, typedOther.warehouse);
3246
        if (lastComparison != 0) {
3247
          return lastComparison;
3248
        }
3249
      }
3250
      return 0;
3251
    }
3252
 
3253
    public _Fields fieldForId(int fieldId) {
3254
      return _Fields.findByThriftId(fieldId);
3255
    }
3256
 
3257
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3258
      org.apache.thrift.protocol.TField field;
3259
      iprot.readStructBegin();
3260
      while (true)
3261
      {
3262
        field = iprot.readFieldBegin();
3263
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3264
          break;
3265
        }
3266
        switch (field.id) {
3267
          case 1: // WAREHOUSE
3268
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3269
              this.warehouse = new Warehouse();
3270
              this.warehouse.read(iprot);
3271
            } else { 
3272
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3273
            }
3274
            break;
3275
          default:
3276
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3277
        }
3278
        iprot.readFieldEnd();
3279
      }
3280
      iprot.readStructEnd();
3281
      validate();
3282
    }
3283
 
3284
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3285
      validate();
3286
 
3287
      oprot.writeStructBegin(STRUCT_DESC);
3288
      if (this.warehouse != null) {
3289
        oprot.writeFieldBegin(WAREHOUSE_FIELD_DESC);
3290
        this.warehouse.write(oprot);
3291
        oprot.writeFieldEnd();
3292
      }
3293
      oprot.writeFieldStop();
3294
      oprot.writeStructEnd();
3295
    }
3296
 
3297
    @Override
3298
    public String toString() {
3299
      StringBuilder sb = new StringBuilder("addWarehouse_args(");
3300
      boolean first = true;
3301
 
3302
      sb.append("warehouse:");
3303
      if (this.warehouse == null) {
3304
        sb.append("null");
3305
      } else {
3306
        sb.append(this.warehouse);
3307
      }
3308
      first = false;
3309
      sb.append(")");
3310
      return sb.toString();
3311
    }
3312
 
3313
    public void validate() throws org.apache.thrift.TException {
3314
      // check for required fields
3315
    }
3316
 
3317
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3318
      try {
3319
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3320
      } catch (org.apache.thrift.TException te) {
3321
        throw new java.io.IOException(te);
3322
      }
3323
    }
3324
 
3325
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3326
      try {
3327
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3328
      } catch (org.apache.thrift.TException te) {
3329
        throw new java.io.IOException(te);
3330
      }
3331
    }
3332
 
3333
  }
3334
 
3335
  public static class addWarehouse_result implements org.apache.thrift.TBase<addWarehouse_result, addWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
3336
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addWarehouse_result");
3337
 
3338
    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);
3339
    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);
3340
 
3341
    private long success; // required
3342
    private InventoryServiceException cex; // required
3343
 
3344
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3345
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3346
      SUCCESS((short)0, "success"),
3347
      CEX((short)1, "cex");
3348
 
3349
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3350
 
3351
      static {
3352
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3353
          byName.put(field.getFieldName(), field);
3354
        }
3355
      }
3356
 
3357
      /**
3358
       * Find the _Fields constant that matches fieldId, or null if its not found.
3359
       */
3360
      public static _Fields findByThriftId(int fieldId) {
3361
        switch(fieldId) {
3362
          case 0: // SUCCESS
3363
            return SUCCESS;
3364
          case 1: // CEX
3365
            return CEX;
3366
          default:
3367
            return null;
3368
        }
3369
      }
3370
 
3371
      /**
3372
       * Find the _Fields constant that matches fieldId, throwing an exception
3373
       * if it is not found.
3374
       */
3375
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3376
        _Fields fields = findByThriftId(fieldId);
3377
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3378
        return fields;
3379
      }
3380
 
3381
      /**
3382
       * Find the _Fields constant that matches name, or null if its not found.
3383
       */
3384
      public static _Fields findByName(String name) {
3385
        return byName.get(name);
3386
      }
3387
 
3388
      private final short _thriftId;
3389
      private final String _fieldName;
3390
 
3391
      _Fields(short thriftId, String fieldName) {
3392
        _thriftId = thriftId;
3393
        _fieldName = fieldName;
3394
      }
3395
 
3396
      public short getThriftFieldId() {
3397
        return _thriftId;
3398
      }
3399
 
3400
      public String getFieldName() {
3401
        return _fieldName;
3402
      }
3403
    }
3404
 
3405
    // isset id assignments
3406
    private static final int __SUCCESS_ISSET_ID = 0;
3407
    private BitSet __isset_bit_vector = new BitSet(1);
3408
 
3409
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3410
    static {
3411
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3412
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3413
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3414
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3415
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3416
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3417
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addWarehouse_result.class, metaDataMap);
3418
    }
3419
 
3420
    public addWarehouse_result() {
3421
    }
3422
 
3423
    public addWarehouse_result(
3424
      long success,
3425
      InventoryServiceException cex)
3426
    {
3427
      this();
3428
      this.success = success;
3429
      setSuccessIsSet(true);
3430
      this.cex = cex;
3431
    }
3432
 
3433
    /**
3434
     * Performs a deep copy on <i>other</i>.
3435
     */
3436
    public addWarehouse_result(addWarehouse_result other) {
3437
      __isset_bit_vector.clear();
3438
      __isset_bit_vector.or(other.__isset_bit_vector);
3439
      this.success = other.success;
3440
      if (other.isSetCex()) {
3441
        this.cex = new InventoryServiceException(other.cex);
3442
      }
3443
    }
3444
 
3445
    public addWarehouse_result deepCopy() {
3446
      return new addWarehouse_result(this);
3447
    }
3448
 
3449
    @Override
3450
    public void clear() {
3451
      setSuccessIsSet(false);
3452
      this.success = 0;
3453
      this.cex = null;
3454
    }
3455
 
3456
    public long getSuccess() {
3457
      return this.success;
3458
    }
3459
 
3460
    public void setSuccess(long success) {
3461
      this.success = success;
3462
      setSuccessIsSet(true);
3463
    }
3464
 
3465
    public void unsetSuccess() {
3466
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
3467
    }
3468
 
3469
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
3470
    public boolean isSetSuccess() {
3471
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
3472
    }
3473
 
3474
    public void setSuccessIsSet(boolean value) {
3475
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
3476
    }
3477
 
3478
    public InventoryServiceException getCex() {
3479
      return this.cex;
3480
    }
3481
 
3482
    public void setCex(InventoryServiceException cex) {
3483
      this.cex = cex;
3484
    }
3485
 
3486
    public void unsetCex() {
3487
      this.cex = null;
3488
    }
3489
 
3490
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
3491
    public boolean isSetCex() {
3492
      return this.cex != null;
3493
    }
3494
 
3495
    public void setCexIsSet(boolean value) {
3496
      if (!value) {
3497
        this.cex = null;
3498
      }
3499
    }
3500
 
3501
    public void setFieldValue(_Fields field, Object value) {
3502
      switch (field) {
3503
      case SUCCESS:
3504
        if (value == null) {
3505
          unsetSuccess();
3506
        } else {
3507
          setSuccess((Long)value);
3508
        }
3509
        break;
3510
 
3511
      case CEX:
3512
        if (value == null) {
3513
          unsetCex();
3514
        } else {
3515
          setCex((InventoryServiceException)value);
3516
        }
3517
        break;
3518
 
3519
      }
3520
    }
3521
 
3522
    public Object getFieldValue(_Fields field) {
3523
      switch (field) {
3524
      case SUCCESS:
3525
        return Long.valueOf(getSuccess());
3526
 
3527
      case CEX:
3528
        return getCex();
3529
 
3530
      }
3531
      throw new IllegalStateException();
3532
    }
3533
 
3534
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3535
    public boolean isSet(_Fields field) {
3536
      if (field == null) {
3537
        throw new IllegalArgumentException();
3538
      }
3539
 
3540
      switch (field) {
3541
      case SUCCESS:
3542
        return isSetSuccess();
3543
      case CEX:
3544
        return isSetCex();
3545
      }
3546
      throw new IllegalStateException();
3547
    }
3548
 
3549
    @Override
3550
    public boolean equals(Object that) {
3551
      if (that == null)
3552
        return false;
3553
      if (that instanceof addWarehouse_result)
3554
        return this.equals((addWarehouse_result)that);
3555
      return false;
3556
    }
3557
 
3558
    public boolean equals(addWarehouse_result that) {
3559
      if (that == null)
3560
        return false;
3561
 
3562
      boolean this_present_success = true;
3563
      boolean that_present_success = true;
3564
      if (this_present_success || that_present_success) {
3565
        if (!(this_present_success && that_present_success))
3566
          return false;
3567
        if (this.success != that.success)
3568
          return false;
3569
      }
3570
 
3571
      boolean this_present_cex = true && this.isSetCex();
3572
      boolean that_present_cex = true && that.isSetCex();
3573
      if (this_present_cex || that_present_cex) {
3574
        if (!(this_present_cex && that_present_cex))
3575
          return false;
3576
        if (!this.cex.equals(that.cex))
3577
          return false;
3578
      }
3579
 
3580
      return true;
3581
    }
3582
 
3583
    @Override
3584
    public int hashCode() {
3585
      return 0;
3586
    }
3587
 
3588
    public int compareTo(addWarehouse_result other) {
3589
      if (!getClass().equals(other.getClass())) {
3590
        return getClass().getName().compareTo(other.getClass().getName());
3591
      }
3592
 
3593
      int lastComparison = 0;
3594
      addWarehouse_result typedOther = (addWarehouse_result)other;
3595
 
3596
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
3597
      if (lastComparison != 0) {
3598
        return lastComparison;
3599
      }
3600
      if (isSetSuccess()) {
3601
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3602
        if (lastComparison != 0) {
3603
          return lastComparison;
3604
        }
3605
      }
3606
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
3607
      if (lastComparison != 0) {
3608
        return lastComparison;
3609
      }
3610
      if (isSetCex()) {
3611
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
3612
        if (lastComparison != 0) {
3613
          return lastComparison;
3614
        }
3615
      }
3616
      return 0;
3617
    }
3618
 
3619
    public _Fields fieldForId(int fieldId) {
3620
      return _Fields.findByThriftId(fieldId);
3621
    }
3622
 
3623
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3624
      org.apache.thrift.protocol.TField field;
3625
      iprot.readStructBegin();
3626
      while (true)
3627
      {
3628
        field = iprot.readFieldBegin();
3629
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3630
          break;
3631
        }
3632
        switch (field.id) {
3633
          case 0: // SUCCESS
3634
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3635
              this.success = iprot.readI64();
3636
              setSuccessIsSet(true);
3637
            } else { 
3638
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3639
            }
3640
            break;
3641
          case 1: // CEX
3642
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3643
              this.cex = new InventoryServiceException();
3644
              this.cex.read(iprot);
3645
            } else { 
3646
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3647
            }
3648
            break;
3649
          default:
3650
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3651
        }
3652
        iprot.readFieldEnd();
3653
      }
3654
      iprot.readStructEnd();
3655
      validate();
3656
    }
3657
 
3658
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3659
      oprot.writeStructBegin(STRUCT_DESC);
3660
 
3661
      if (this.isSetSuccess()) {
3662
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3663
        oprot.writeI64(this.success);
3664
        oprot.writeFieldEnd();
3665
      } else if (this.isSetCex()) {
3666
        oprot.writeFieldBegin(CEX_FIELD_DESC);
3667
        this.cex.write(oprot);
3668
        oprot.writeFieldEnd();
3669
      }
3670
      oprot.writeFieldStop();
3671
      oprot.writeStructEnd();
3672
    }
3673
 
3674
    @Override
3675
    public String toString() {
3676
      StringBuilder sb = new StringBuilder("addWarehouse_result(");
3677
      boolean first = true;
3678
 
3679
      sb.append("success:");
3680
      sb.append(this.success);
3681
      first = false;
3682
      if (!first) sb.append(", ");
3683
      sb.append("cex:");
3684
      if (this.cex == null) {
3685
        sb.append("null");
3686
      } else {
3687
        sb.append(this.cex);
3688
      }
3689
      first = false;
3690
      sb.append(")");
3691
      return sb.toString();
3692
    }
3693
 
3694
    public void validate() throws org.apache.thrift.TException {
3695
      // check for required fields
3696
    }
3697
 
3698
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3699
      try {
3700
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3701
      } catch (org.apache.thrift.TException te) {
3702
        throw new java.io.IOException(te);
3703
      }
3704
    }
3705
 
3706
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3707
      try {
3708
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3709
      } catch (org.apache.thrift.TException te) {
3710
        throw new java.io.IOException(te);
3711
      }
3712
    }
3713
 
3714
  }
3715
 
3716
  public static class addVendor_args implements org.apache.thrift.TBase<addVendor_args, addVendor_args._Fields>, java.io.Serializable, Cloneable   {
3717
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendor_args");
3718
 
3719
    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);
3720
 
3721
    private Vendor vendor; // required
3722
 
3723
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3724
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3725
      VENDOR((short)1, "vendor");
3726
 
3727
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3728
 
3729
      static {
3730
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3731
          byName.put(field.getFieldName(), field);
3732
        }
3733
      }
3734
 
3735
      /**
3736
       * Find the _Fields constant that matches fieldId, or null if its not found.
3737
       */
3738
      public static _Fields findByThriftId(int fieldId) {
3739
        switch(fieldId) {
3740
          case 1: // VENDOR
3741
            return VENDOR;
3742
          default:
3743
            return null;
3744
        }
3745
      }
3746
 
3747
      /**
3748
       * Find the _Fields constant that matches fieldId, throwing an exception
3749
       * if it is not found.
3750
       */
3751
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3752
        _Fields fields = findByThriftId(fieldId);
3753
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3754
        return fields;
3755
      }
3756
 
3757
      /**
3758
       * Find the _Fields constant that matches name, or null if its not found.
3759
       */
3760
      public static _Fields findByName(String name) {
3761
        return byName.get(name);
3762
      }
3763
 
3764
      private final short _thriftId;
3765
      private final String _fieldName;
3766
 
3767
      _Fields(short thriftId, String fieldName) {
3768
        _thriftId = thriftId;
3769
        _fieldName = fieldName;
3770
      }
3771
 
3772
      public short getThriftFieldId() {
3773
        return _thriftId;
3774
      }
3775
 
3776
      public String getFieldName() {
3777
        return _fieldName;
3778
      }
3779
    }
3780
 
3781
    // isset id assignments
3782
 
3783
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3784
    static {
3785
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3786
      tmpMap.put(_Fields.VENDOR, new org.apache.thrift.meta_data.FieldMetaData("vendor", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3787
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class)));
3788
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3789
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendor_args.class, metaDataMap);
3790
    }
3791
 
3792
    public addVendor_args() {
3793
    }
3794
 
3795
    public addVendor_args(
3796
      Vendor vendor)
3797
    {
3798
      this();
3799
      this.vendor = vendor;
3800
    }
3801
 
3802
    /**
3803
     * Performs a deep copy on <i>other</i>.
3804
     */
3805
    public addVendor_args(addVendor_args other) {
3806
      if (other.isSetVendor()) {
3807
        this.vendor = new Vendor(other.vendor);
3808
      }
3809
    }
3810
 
3811
    public addVendor_args deepCopy() {
3812
      return new addVendor_args(this);
3813
    }
3814
 
3815
    @Override
3816
    public void clear() {
3817
      this.vendor = null;
3818
    }
3819
 
3820
    public Vendor getVendor() {
3821
      return this.vendor;
3822
    }
3823
 
3824
    public void setVendor(Vendor vendor) {
3825
      this.vendor = vendor;
3826
    }
3827
 
3828
    public void unsetVendor() {
3829
      this.vendor = null;
3830
    }
3831
 
3832
    /** Returns true if field vendor is set (has been assigned a value) and false otherwise */
3833
    public boolean isSetVendor() {
3834
      return this.vendor != null;
3835
    }
3836
 
3837
    public void setVendorIsSet(boolean value) {
3838
      if (!value) {
3839
        this.vendor = null;
3840
      }
3841
    }
3842
 
3843
    public void setFieldValue(_Fields field, Object value) {
3844
      switch (field) {
3845
      case VENDOR:
3846
        if (value == null) {
3847
          unsetVendor();
3848
        } else {
3849
          setVendor((Vendor)value);
3850
        }
3851
        break;
3852
 
3853
      }
3854
    }
3855
 
3856
    public Object getFieldValue(_Fields field) {
3857
      switch (field) {
3858
      case VENDOR:
3859
        return getVendor();
3860
 
3861
      }
3862
      throw new IllegalStateException();
3863
    }
3864
 
3865
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3866
    public boolean isSet(_Fields field) {
3867
      if (field == null) {
3868
        throw new IllegalArgumentException();
3869
      }
3870
 
3871
      switch (field) {
3872
      case VENDOR:
3873
        return isSetVendor();
3874
      }
3875
      throw new IllegalStateException();
3876
    }
3877
 
3878
    @Override
3879
    public boolean equals(Object that) {
3880
      if (that == null)
3881
        return false;
3882
      if (that instanceof addVendor_args)
3883
        return this.equals((addVendor_args)that);
3884
      return false;
3885
    }
3886
 
3887
    public boolean equals(addVendor_args that) {
3888
      if (that == null)
3889
        return false;
3890
 
3891
      boolean this_present_vendor = true && this.isSetVendor();
3892
      boolean that_present_vendor = true && that.isSetVendor();
3893
      if (this_present_vendor || that_present_vendor) {
3894
        if (!(this_present_vendor && that_present_vendor))
3895
          return false;
3896
        if (!this.vendor.equals(that.vendor))
3897
          return false;
3898
      }
3899
 
3900
      return true;
3901
    }
3902
 
3903
    @Override
3904
    public int hashCode() {
3905
      return 0;
3906
    }
3907
 
3908
    public int compareTo(addVendor_args other) {
3909
      if (!getClass().equals(other.getClass())) {
3910
        return getClass().getName().compareTo(other.getClass().getName());
3911
      }
3912
 
3913
      int lastComparison = 0;
3914
      addVendor_args typedOther = (addVendor_args)other;
3915
 
3916
      lastComparison = Boolean.valueOf(isSetVendor()).compareTo(typedOther.isSetVendor());
3917
      if (lastComparison != 0) {
3918
        return lastComparison;
3919
      }
3920
      if (isSetVendor()) {
3921
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendor, typedOther.vendor);
3922
        if (lastComparison != 0) {
3923
          return lastComparison;
3924
        }
3925
      }
3926
      return 0;
3927
    }
3928
 
3929
    public _Fields fieldForId(int fieldId) {
3930
      return _Fields.findByThriftId(fieldId);
3931
    }
3932
 
3933
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3934
      org.apache.thrift.protocol.TField field;
3935
      iprot.readStructBegin();
3936
      while (true)
3937
      {
3938
        field = iprot.readFieldBegin();
3939
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3940
          break;
3941
        }
3942
        switch (field.id) {
3943
          case 1: // VENDOR
3944
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3945
              this.vendor = new Vendor();
3946
              this.vendor.read(iprot);
3947
            } else { 
3948
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3949
            }
3950
            break;
3951
          default:
3952
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3953
        }
3954
        iprot.readFieldEnd();
3955
      }
3956
      iprot.readStructEnd();
3957
      validate();
3958
    }
3959
 
3960
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3961
      validate();
3962
 
3963
      oprot.writeStructBegin(STRUCT_DESC);
3964
      if (this.vendor != null) {
3965
        oprot.writeFieldBegin(VENDOR_FIELD_DESC);
3966
        this.vendor.write(oprot);
3967
        oprot.writeFieldEnd();
3968
      }
3969
      oprot.writeFieldStop();
3970
      oprot.writeStructEnd();
3971
    }
3972
 
3973
    @Override
3974
    public String toString() {
3975
      StringBuilder sb = new StringBuilder("addVendor_args(");
3976
      boolean first = true;
3977
 
3978
      sb.append("vendor:");
3979
      if (this.vendor == null) {
3980
        sb.append("null");
3981
      } else {
3982
        sb.append(this.vendor);
3983
      }
3984
      first = false;
3985
      sb.append(")");
3986
      return sb.toString();
3987
    }
3988
 
3989
    public void validate() throws org.apache.thrift.TException {
3990
      // check for required fields
3991
    }
3992
 
3993
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3994
      try {
3995
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3996
      } catch (org.apache.thrift.TException te) {
3997
        throw new java.io.IOException(te);
3998
      }
3999
    }
4000
 
4001
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4002
      try {
4003
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4004
      } catch (org.apache.thrift.TException te) {
4005
        throw new java.io.IOException(te);
4006
      }
4007
    }
4008
 
4009
  }
4010
 
4011
  public static class addVendor_result implements org.apache.thrift.TBase<addVendor_result, addVendor_result._Fields>, java.io.Serializable, Cloneable   {
4012
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendor_result");
4013
 
4014
    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);
4015
    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);
4016
 
4017
    private long success; // required
4018
    private InventoryServiceException cex; // required
4019
 
4020
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4021
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4022
      SUCCESS((short)0, "success"),
4023
      CEX((short)1, "cex");
4024
 
4025
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4026
 
4027
      static {
4028
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4029
          byName.put(field.getFieldName(), field);
4030
        }
4031
      }
4032
 
4033
      /**
4034
       * Find the _Fields constant that matches fieldId, or null if its not found.
4035
       */
4036
      public static _Fields findByThriftId(int fieldId) {
4037
        switch(fieldId) {
4038
          case 0: // SUCCESS
4039
            return SUCCESS;
4040
          case 1: // CEX
4041
            return CEX;
4042
          default:
4043
            return null;
4044
        }
4045
      }
4046
 
4047
      /**
4048
       * Find the _Fields constant that matches fieldId, throwing an exception
4049
       * if it is not found.
4050
       */
4051
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4052
        _Fields fields = findByThriftId(fieldId);
4053
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4054
        return fields;
4055
      }
4056
 
4057
      /**
4058
       * Find the _Fields constant that matches name, or null if its not found.
4059
       */
4060
      public static _Fields findByName(String name) {
4061
        return byName.get(name);
4062
      }
4063
 
4064
      private final short _thriftId;
4065
      private final String _fieldName;
4066
 
4067
      _Fields(short thriftId, String fieldName) {
4068
        _thriftId = thriftId;
4069
        _fieldName = fieldName;
4070
      }
4071
 
4072
      public short getThriftFieldId() {
4073
        return _thriftId;
4074
      }
4075
 
4076
      public String getFieldName() {
4077
        return _fieldName;
4078
      }
4079
    }
4080
 
4081
    // isset id assignments
4082
    private static final int __SUCCESS_ISSET_ID = 0;
4083
    private BitSet __isset_bit_vector = new BitSet(1);
4084
 
4085
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4086
    static {
4087
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4088
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4089
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4090
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4091
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4092
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4093
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendor_result.class, metaDataMap);
4094
    }
4095
 
4096
    public addVendor_result() {
4097
    }
4098
 
4099
    public addVendor_result(
4100
      long success,
4101
      InventoryServiceException cex)
4102
    {
4103
      this();
4104
      this.success = success;
4105
      setSuccessIsSet(true);
4106
      this.cex = cex;
4107
    }
4108
 
4109
    /**
4110
     * Performs a deep copy on <i>other</i>.
4111
     */
4112
    public addVendor_result(addVendor_result other) {
4113
      __isset_bit_vector.clear();
4114
      __isset_bit_vector.or(other.__isset_bit_vector);
4115
      this.success = other.success;
4116
      if (other.isSetCex()) {
4117
        this.cex = new InventoryServiceException(other.cex);
4118
      }
4119
    }
4120
 
4121
    public addVendor_result deepCopy() {
4122
      return new addVendor_result(this);
4123
    }
4124
 
4125
    @Override
4126
    public void clear() {
4127
      setSuccessIsSet(false);
4128
      this.success = 0;
4129
      this.cex = null;
4130
    }
4131
 
4132
    public long getSuccess() {
4133
      return this.success;
4134
    }
4135
 
4136
    public void setSuccess(long success) {
4137
      this.success = success;
4138
      setSuccessIsSet(true);
4139
    }
4140
 
4141
    public void unsetSuccess() {
4142
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
4143
    }
4144
 
4145
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
4146
    public boolean isSetSuccess() {
4147
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
4148
    }
4149
 
4150
    public void setSuccessIsSet(boolean value) {
4151
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
4152
    }
4153
 
4154
    public InventoryServiceException getCex() {
4155
      return this.cex;
4156
    }
4157
 
4158
    public void setCex(InventoryServiceException cex) {
4159
      this.cex = cex;
4160
    }
4161
 
4162
    public void unsetCex() {
4163
      this.cex = null;
4164
    }
4165
 
4166
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
4167
    public boolean isSetCex() {
4168
      return this.cex != null;
4169
    }
4170
 
4171
    public void setCexIsSet(boolean value) {
4172
      if (!value) {
4173
        this.cex = null;
4174
      }
4175
    }
4176
 
4177
    public void setFieldValue(_Fields field, Object value) {
4178
      switch (field) {
4179
      case SUCCESS:
4180
        if (value == null) {
4181
          unsetSuccess();
4182
        } else {
4183
          setSuccess((Long)value);
4184
        }
4185
        break;
4186
 
4187
      case CEX:
4188
        if (value == null) {
4189
          unsetCex();
4190
        } else {
4191
          setCex((InventoryServiceException)value);
4192
        }
4193
        break;
4194
 
4195
      }
4196
    }
4197
 
4198
    public Object getFieldValue(_Fields field) {
4199
      switch (field) {
4200
      case SUCCESS:
4201
        return Long.valueOf(getSuccess());
4202
 
4203
      case CEX:
4204
        return getCex();
4205
 
4206
      }
4207
      throw new IllegalStateException();
4208
    }
4209
 
4210
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4211
    public boolean isSet(_Fields field) {
4212
      if (field == null) {
4213
        throw new IllegalArgumentException();
4214
      }
4215
 
4216
      switch (field) {
4217
      case SUCCESS:
4218
        return isSetSuccess();
4219
      case CEX:
4220
        return isSetCex();
4221
      }
4222
      throw new IllegalStateException();
4223
    }
4224
 
4225
    @Override
4226
    public boolean equals(Object that) {
4227
      if (that == null)
4228
        return false;
4229
      if (that instanceof addVendor_result)
4230
        return this.equals((addVendor_result)that);
4231
      return false;
4232
    }
4233
 
4234
    public boolean equals(addVendor_result that) {
4235
      if (that == null)
4236
        return false;
4237
 
4238
      boolean this_present_success = true;
4239
      boolean that_present_success = true;
4240
      if (this_present_success || that_present_success) {
4241
        if (!(this_present_success && that_present_success))
4242
          return false;
4243
        if (this.success != that.success)
4244
          return false;
4245
      }
4246
 
4247
      boolean this_present_cex = true && this.isSetCex();
4248
      boolean that_present_cex = true && that.isSetCex();
4249
      if (this_present_cex || that_present_cex) {
4250
        if (!(this_present_cex && that_present_cex))
4251
          return false;
4252
        if (!this.cex.equals(that.cex))
4253
          return false;
4254
      }
4255
 
4256
      return true;
4257
    }
4258
 
4259
    @Override
4260
    public int hashCode() {
4261
      return 0;
4262
    }
4263
 
4264
    public int compareTo(addVendor_result other) {
4265
      if (!getClass().equals(other.getClass())) {
4266
        return getClass().getName().compareTo(other.getClass().getName());
4267
      }
4268
 
4269
      int lastComparison = 0;
4270
      addVendor_result typedOther = (addVendor_result)other;
4271
 
4272
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
4273
      if (lastComparison != 0) {
4274
        return lastComparison;
4275
      }
4276
      if (isSetSuccess()) {
4277
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
4278
        if (lastComparison != 0) {
4279
          return lastComparison;
4280
        }
4281
      }
4282
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
4283
      if (lastComparison != 0) {
4284
        return lastComparison;
4285
      }
4286
      if (isSetCex()) {
4287
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
4288
        if (lastComparison != 0) {
4289
          return lastComparison;
4290
        }
4291
      }
4292
      return 0;
4293
    }
4294
 
4295
    public _Fields fieldForId(int fieldId) {
4296
      return _Fields.findByThriftId(fieldId);
4297
    }
4298
 
4299
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4300
      org.apache.thrift.protocol.TField field;
4301
      iprot.readStructBegin();
4302
      while (true)
4303
      {
4304
        field = iprot.readFieldBegin();
4305
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4306
          break;
4307
        }
4308
        switch (field.id) {
4309
          case 0: // SUCCESS
4310
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4311
              this.success = iprot.readI64();
4312
              setSuccessIsSet(true);
4313
            } else { 
4314
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4315
            }
4316
            break;
4317
          case 1: // CEX
4318
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4319
              this.cex = new InventoryServiceException();
4320
              this.cex.read(iprot);
4321
            } else { 
4322
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4323
            }
4324
            break;
4325
          default:
4326
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4327
        }
4328
        iprot.readFieldEnd();
4329
      }
4330
      iprot.readStructEnd();
4331
      validate();
4332
    }
4333
 
4334
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4335
      oprot.writeStructBegin(STRUCT_DESC);
4336
 
4337
      if (this.isSetSuccess()) {
4338
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
4339
        oprot.writeI64(this.success);
4340
        oprot.writeFieldEnd();
4341
      } else if (this.isSetCex()) {
4342
        oprot.writeFieldBegin(CEX_FIELD_DESC);
4343
        this.cex.write(oprot);
4344
        oprot.writeFieldEnd();
4345
      }
4346
      oprot.writeFieldStop();
4347
      oprot.writeStructEnd();
4348
    }
4349
 
4350
    @Override
4351
    public String toString() {
4352
      StringBuilder sb = new StringBuilder("addVendor_result(");
4353
      boolean first = true;
4354
 
4355
      sb.append("success:");
4356
      sb.append(this.success);
4357
      first = false;
4358
      if (!first) sb.append(", ");
4359
      sb.append("cex:");
4360
      if (this.cex == null) {
4361
        sb.append("null");
4362
      } else {
4363
        sb.append(this.cex);
4364
      }
4365
      first = false;
4366
      sb.append(")");
4367
      return sb.toString();
4368
    }
4369
 
4370
    public void validate() throws org.apache.thrift.TException {
4371
      // check for required fields
4372
    }
4373
 
4374
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4375
      try {
4376
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4377
      } catch (org.apache.thrift.TException te) {
4378
        throw new java.io.IOException(te);
4379
      }
4380
    }
4381
 
4382
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4383
      try {
4384
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4385
      } catch (org.apache.thrift.TException te) {
4386
        throw new java.io.IOException(te);
4387
      }
4388
    }
4389
 
4390
  }
4391
 
4392
  public static class updateInventoryHistory_args implements org.apache.thrift.TBase<updateInventoryHistory_args, updateInventoryHistory_args._Fields>, java.io.Serializable, Cloneable   {
4393
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventoryHistory_args");
4394
 
4395
    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);
4396
    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);
4397
    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);
4398
 
4399
    private long warehouse_id; // required
4400
    private String timestamp; // required
4401
    private Map<String,Long> availability; // required
4402
 
4403
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4404
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4405
      WAREHOUSE_ID((short)1, "warehouse_id"),
4406
      TIMESTAMP((short)2, "timestamp"),
4407
      AVAILABILITY((short)3, "availability");
4408
 
4409
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4410
 
4411
      static {
4412
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4413
          byName.put(field.getFieldName(), field);
4414
        }
4415
      }
4416
 
4417
      /**
4418
       * Find the _Fields constant that matches fieldId, or null if its not found.
4419
       */
4420
      public static _Fields findByThriftId(int fieldId) {
4421
        switch(fieldId) {
4422
          case 1: // WAREHOUSE_ID
4423
            return WAREHOUSE_ID;
4424
          case 2: // TIMESTAMP
4425
            return TIMESTAMP;
4426
          case 3: // AVAILABILITY
4427
            return AVAILABILITY;
4428
          default:
4429
            return null;
4430
        }
4431
      }
4432
 
4433
      /**
4434
       * Find the _Fields constant that matches fieldId, throwing an exception
4435
       * if it is not found.
4436
       */
4437
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4438
        _Fields fields = findByThriftId(fieldId);
4439
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4440
        return fields;
4441
      }
4442
 
4443
      /**
4444
       * Find the _Fields constant that matches name, or null if its not found.
4445
       */
4446
      public static _Fields findByName(String name) {
4447
        return byName.get(name);
4448
      }
4449
 
4450
      private final short _thriftId;
4451
      private final String _fieldName;
4452
 
4453
      _Fields(short thriftId, String fieldName) {
4454
        _thriftId = thriftId;
4455
        _fieldName = fieldName;
4456
      }
4457
 
4458
      public short getThriftFieldId() {
4459
        return _thriftId;
4460
      }
4461
 
4462
      public String getFieldName() {
4463
        return _fieldName;
4464
      }
4465
    }
4466
 
4467
    // isset id assignments
4468
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
4469
    private BitSet __isset_bit_vector = new BitSet(1);
4470
 
4471
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4472
    static {
4473
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4474
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4475
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4476
      tmpMap.put(_Fields.TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("timestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4477
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
4478
      tmpMap.put(_Fields.AVAILABILITY, new org.apache.thrift.meta_data.FieldMetaData("availability", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4479
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
4480
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
4481
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
4482
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4483
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventoryHistory_args.class, metaDataMap);
4484
    }
4485
 
4486
    public updateInventoryHistory_args() {
4487
    }
4488
 
4489
    public updateInventoryHistory_args(
4490
      long warehouse_id,
4491
      String timestamp,
4492
      Map<String,Long> availability)
4493
    {
4494
      this();
4495
      this.warehouse_id = warehouse_id;
4496
      setWarehouse_idIsSet(true);
4497
      this.timestamp = timestamp;
4498
      this.availability = availability;
4499
    }
4500
 
4501
    /**
4502
     * Performs a deep copy on <i>other</i>.
4503
     */
4504
    public updateInventoryHistory_args(updateInventoryHistory_args other) {
4505
      __isset_bit_vector.clear();
4506
      __isset_bit_vector.or(other.__isset_bit_vector);
4507
      this.warehouse_id = other.warehouse_id;
4508
      if (other.isSetTimestamp()) {
4509
        this.timestamp = other.timestamp;
4510
      }
4511
      if (other.isSetAvailability()) {
4512
        Map<String,Long> __this__availability = new HashMap<String,Long>();
4513
        for (Map.Entry<String, Long> other_element : other.availability.entrySet()) {
4514
 
4515
          String other_element_key = other_element.getKey();
4516
          Long other_element_value = other_element.getValue();
4517
 
4518
          String __this__availability_copy_key = other_element_key;
4519
 
4520
          Long __this__availability_copy_value = other_element_value;
4521
 
4522
          __this__availability.put(__this__availability_copy_key, __this__availability_copy_value);
4523
        }
4524
        this.availability = __this__availability;
4525
      }
4526
    }
4527
 
4528
    public updateInventoryHistory_args deepCopy() {
4529
      return new updateInventoryHistory_args(this);
4530
    }
4531
 
4532
    @Override
4533
    public void clear() {
4534
      setWarehouse_idIsSet(false);
4535
      this.warehouse_id = 0;
4536
      this.timestamp = null;
4537
      this.availability = null;
4538
    }
4539
 
4540
    public long getWarehouse_id() {
4541
      return this.warehouse_id;
4542
    }
4543
 
4544
    public void setWarehouse_id(long warehouse_id) {
4545
      this.warehouse_id = warehouse_id;
4546
      setWarehouse_idIsSet(true);
4547
    }
4548
 
4549
    public void unsetWarehouse_id() {
4550
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
4551
    }
4552
 
4553
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
4554
    public boolean isSetWarehouse_id() {
4555
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
4556
    }
4557
 
4558
    public void setWarehouse_idIsSet(boolean value) {
4559
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
4560
    }
4561
 
4562
    public String getTimestamp() {
4563
      return this.timestamp;
4564
    }
4565
 
4566
    public void setTimestamp(String timestamp) {
4567
      this.timestamp = timestamp;
4568
    }
4569
 
4570
    public void unsetTimestamp() {
4571
      this.timestamp = null;
4572
    }
4573
 
4574
    /** Returns true if field timestamp is set (has been assigned a value) and false otherwise */
4575
    public boolean isSetTimestamp() {
4576
      return this.timestamp != null;
4577
    }
4578
 
4579
    public void setTimestampIsSet(boolean value) {
4580
      if (!value) {
4581
        this.timestamp = null;
4582
      }
4583
    }
4584
 
4585
    public int getAvailabilitySize() {
4586
      return (this.availability == null) ? 0 : this.availability.size();
4587
    }
4588
 
4589
    public void putToAvailability(String key, long val) {
4590
      if (this.availability == null) {
4591
        this.availability = new HashMap<String,Long>();
4592
      }
4593
      this.availability.put(key, val);
4594
    }
4595
 
4596
    public Map<String,Long> getAvailability() {
4597
      return this.availability;
4598
    }
4599
 
4600
    public void setAvailability(Map<String,Long> availability) {
4601
      this.availability = availability;
4602
    }
4603
 
4604
    public void unsetAvailability() {
4605
      this.availability = null;
4606
    }
4607
 
4608
    /** Returns true if field availability is set (has been assigned a value) and false otherwise */
4609
    public boolean isSetAvailability() {
4610
      return this.availability != null;
4611
    }
4612
 
4613
    public void setAvailabilityIsSet(boolean value) {
4614
      if (!value) {
4615
        this.availability = null;
4616
      }
4617
    }
4618
 
4619
    public void setFieldValue(_Fields field, Object value) {
4620
      switch (field) {
4621
      case WAREHOUSE_ID:
4622
        if (value == null) {
4623
          unsetWarehouse_id();
4624
        } else {
4625
          setWarehouse_id((Long)value);
4626
        }
4627
        break;
4628
 
4629
      case TIMESTAMP:
4630
        if (value == null) {
4631
          unsetTimestamp();
4632
        } else {
4633
          setTimestamp((String)value);
4634
        }
4635
        break;
4636
 
4637
      case AVAILABILITY:
4638
        if (value == null) {
4639
          unsetAvailability();
4640
        } else {
4641
          setAvailability((Map<String,Long>)value);
4642
        }
4643
        break;
4644
 
4645
      }
4646
    }
4647
 
4648
    public Object getFieldValue(_Fields field) {
4649
      switch (field) {
4650
      case WAREHOUSE_ID:
4651
        return Long.valueOf(getWarehouse_id());
4652
 
4653
      case TIMESTAMP:
4654
        return getTimestamp();
4655
 
4656
      case AVAILABILITY:
4657
        return getAvailability();
4658
 
4659
      }
4660
      throw new IllegalStateException();
4661
    }
4662
 
4663
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4664
    public boolean isSet(_Fields field) {
4665
      if (field == null) {
4666
        throw new IllegalArgumentException();
4667
      }
4668
 
4669
      switch (field) {
4670
      case WAREHOUSE_ID:
4671
        return isSetWarehouse_id();
4672
      case TIMESTAMP:
4673
        return isSetTimestamp();
4674
      case AVAILABILITY:
4675
        return isSetAvailability();
4676
      }
4677
      throw new IllegalStateException();
4678
    }
4679
 
4680
    @Override
4681
    public boolean equals(Object that) {
4682
      if (that == null)
4683
        return false;
4684
      if (that instanceof updateInventoryHistory_args)
4685
        return this.equals((updateInventoryHistory_args)that);
4686
      return false;
4687
    }
4688
 
4689
    public boolean equals(updateInventoryHistory_args that) {
4690
      if (that == null)
4691
        return false;
4692
 
4693
      boolean this_present_warehouse_id = true;
4694
      boolean that_present_warehouse_id = true;
4695
      if (this_present_warehouse_id || that_present_warehouse_id) {
4696
        if (!(this_present_warehouse_id && that_present_warehouse_id))
4697
          return false;
4698
        if (this.warehouse_id != that.warehouse_id)
4699
          return false;
4700
      }
4701
 
4702
      boolean this_present_timestamp = true && this.isSetTimestamp();
4703
      boolean that_present_timestamp = true && that.isSetTimestamp();
4704
      if (this_present_timestamp || that_present_timestamp) {
4705
        if (!(this_present_timestamp && that_present_timestamp))
4706
          return false;
4707
        if (!this.timestamp.equals(that.timestamp))
4708
          return false;
4709
      }
4710
 
4711
      boolean this_present_availability = true && this.isSetAvailability();
4712
      boolean that_present_availability = true && that.isSetAvailability();
4713
      if (this_present_availability || that_present_availability) {
4714
        if (!(this_present_availability && that_present_availability))
4715
          return false;
4716
        if (!this.availability.equals(that.availability))
4717
          return false;
4718
      }
4719
 
4720
      return true;
4721
    }
4722
 
4723
    @Override
4724
    public int hashCode() {
4725
      return 0;
4726
    }
4727
 
4728
    public int compareTo(updateInventoryHistory_args other) {
4729
      if (!getClass().equals(other.getClass())) {
4730
        return getClass().getName().compareTo(other.getClass().getName());
4731
      }
4732
 
4733
      int lastComparison = 0;
4734
      updateInventoryHistory_args typedOther = (updateInventoryHistory_args)other;
4735
 
4736
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
4737
      if (lastComparison != 0) {
4738
        return lastComparison;
4739
      }
4740
      if (isSetWarehouse_id()) {
4741
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
4742
        if (lastComparison != 0) {
4743
          return lastComparison;
4744
        }
4745
      }
4746
      lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(typedOther.isSetTimestamp());
4747
      if (lastComparison != 0) {
4748
        return lastComparison;
4749
      }
4750
      if (isSetTimestamp()) {
4751
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.timestamp, typedOther.timestamp);
4752
        if (lastComparison != 0) {
4753
          return lastComparison;
4754
        }
4755
      }
4756
      lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(typedOther.isSetAvailability());
4757
      if (lastComparison != 0) {
4758
        return lastComparison;
4759
      }
4760
      if (isSetAvailability()) {
4761
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.availability, typedOther.availability);
4762
        if (lastComparison != 0) {
4763
          return lastComparison;
4764
        }
4765
      }
4766
      return 0;
4767
    }
4768
 
4769
    public _Fields fieldForId(int fieldId) {
4770
      return _Fields.findByThriftId(fieldId);
4771
    }
4772
 
4773
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4774
      org.apache.thrift.protocol.TField field;
4775
      iprot.readStructBegin();
4776
      while (true)
4777
      {
4778
        field = iprot.readFieldBegin();
4779
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4780
          break;
4781
        }
4782
        switch (field.id) {
4783
          case 1: // WAREHOUSE_ID
4784
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4785
              this.warehouse_id = iprot.readI64();
4786
              setWarehouse_idIsSet(true);
4787
            } else { 
4788
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4789
            }
4790
            break;
4791
          case 2: // TIMESTAMP
4792
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
4793
              this.timestamp = iprot.readString();
4794
            } else { 
4795
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4796
            }
4797
            break;
4798
          case 3: // AVAILABILITY
4799
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
4800
              {
4801
                org.apache.thrift.protocol.TMap _map10 = iprot.readMapBegin();
4802
                this.availability = new HashMap<String,Long>(2*_map10.size);
4803
                for (int _i11 = 0; _i11 < _map10.size; ++_i11)
4804
                {
4805
                  String _key12; // required
4806
                  long _val13; // required
4807
                  _key12 = iprot.readString();
4808
                  _val13 = iprot.readI64();
4809
                  this.availability.put(_key12, _val13);
4810
                }
4811
                iprot.readMapEnd();
4812
              }
4813
            } else { 
4814
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4815
            }
4816
            break;
4817
          default:
4818
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4819
        }
4820
        iprot.readFieldEnd();
4821
      }
4822
      iprot.readStructEnd();
4823
      validate();
4824
    }
4825
 
4826
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4827
      validate();
4828
 
4829
      oprot.writeStructBegin(STRUCT_DESC);
4830
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
4831
      oprot.writeI64(this.warehouse_id);
4832
      oprot.writeFieldEnd();
4833
      if (this.timestamp != null) {
4834
        oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
4835
        oprot.writeString(this.timestamp);
4836
        oprot.writeFieldEnd();
4837
      }
4838
      if (this.availability != null) {
4839
        oprot.writeFieldBegin(AVAILABILITY_FIELD_DESC);
4840
        {
4841
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.I64, this.availability.size()));
4842
          for (Map.Entry<String, Long> _iter14 : this.availability.entrySet())
4843
          {
4844
            oprot.writeString(_iter14.getKey());
4845
            oprot.writeI64(_iter14.getValue());
4846
          }
4847
          oprot.writeMapEnd();
4848
        }
4849
        oprot.writeFieldEnd();
4850
      }
4851
      oprot.writeFieldStop();
4852
      oprot.writeStructEnd();
4853
    }
4854
 
4855
    @Override
4856
    public String toString() {
4857
      StringBuilder sb = new StringBuilder("updateInventoryHistory_args(");
4858
      boolean first = true;
4859
 
4860
      sb.append("warehouse_id:");
4861
      sb.append(this.warehouse_id);
4862
      first = false;
4863
      if (!first) sb.append(", ");
4864
      sb.append("timestamp:");
4865
      if (this.timestamp == null) {
4866
        sb.append("null");
4867
      } else {
4868
        sb.append(this.timestamp);
4869
      }
4870
      first = false;
4871
      if (!first) sb.append(", ");
4872
      sb.append("availability:");
4873
      if (this.availability == null) {
4874
        sb.append("null");
4875
      } else {
4876
        sb.append(this.availability);
4877
      }
4878
      first = false;
4879
      sb.append(")");
4880
      return sb.toString();
4881
    }
4882
 
4883
    public void validate() throws org.apache.thrift.TException {
4884
      // check for required fields
4885
    }
4886
 
4887
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4888
      try {
4889
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4890
      } catch (org.apache.thrift.TException te) {
4891
        throw new java.io.IOException(te);
4892
      }
4893
    }
4894
 
4895
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4896
      try {
4897
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
4898
        __isset_bit_vector = new BitSet(1);
4899
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4900
      } catch (org.apache.thrift.TException te) {
4901
        throw new java.io.IOException(te);
4902
      }
4903
    }
4904
 
4905
  }
4906
 
4907
  public static class updateInventoryHistory_result implements org.apache.thrift.TBase<updateInventoryHistory_result, updateInventoryHistory_result._Fields>, java.io.Serializable, Cloneable   {
4908
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventoryHistory_result");
4909
 
4910
    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);
4911
 
4912
    private InventoryServiceException cex; // required
4913
 
4914
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4915
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4916
      CEX((short)1, "cex");
4917
 
4918
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4919
 
4920
      static {
4921
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4922
          byName.put(field.getFieldName(), field);
4923
        }
4924
      }
4925
 
4926
      /**
4927
       * Find the _Fields constant that matches fieldId, or null if its not found.
4928
       */
4929
      public static _Fields findByThriftId(int fieldId) {
4930
        switch(fieldId) {
4931
          case 1: // CEX
4932
            return CEX;
4933
          default:
4934
            return null;
4935
        }
4936
      }
4937
 
4938
      /**
4939
       * Find the _Fields constant that matches fieldId, throwing an exception
4940
       * if it is not found.
4941
       */
4942
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4943
        _Fields fields = findByThriftId(fieldId);
4944
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4945
        return fields;
4946
      }
4947
 
4948
      /**
4949
       * Find the _Fields constant that matches name, or null if its not found.
4950
       */
4951
      public static _Fields findByName(String name) {
4952
        return byName.get(name);
4953
      }
4954
 
4955
      private final short _thriftId;
4956
      private final String _fieldName;
4957
 
4958
      _Fields(short thriftId, String fieldName) {
4959
        _thriftId = thriftId;
4960
        _fieldName = fieldName;
4961
      }
4962
 
4963
      public short getThriftFieldId() {
4964
        return _thriftId;
4965
      }
4966
 
4967
      public String getFieldName() {
4968
        return _fieldName;
4969
      }
4970
    }
4971
 
4972
    // isset id assignments
4973
 
4974
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4975
    static {
4976
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4977
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4978
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4979
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4980
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventoryHistory_result.class, metaDataMap);
4981
    }
4982
 
4983
    public updateInventoryHistory_result() {
4984
    }
4985
 
4986
    public updateInventoryHistory_result(
4987
      InventoryServiceException cex)
4988
    {
4989
      this();
4990
      this.cex = cex;
4991
    }
4992
 
4993
    /**
4994
     * Performs a deep copy on <i>other</i>.
4995
     */
4996
    public updateInventoryHistory_result(updateInventoryHistory_result other) {
4997
      if (other.isSetCex()) {
4998
        this.cex = new InventoryServiceException(other.cex);
4999
      }
5000
    }
5001
 
5002
    public updateInventoryHistory_result deepCopy() {
5003
      return new updateInventoryHistory_result(this);
5004
    }
5005
 
5006
    @Override
5007
    public void clear() {
5008
      this.cex = null;
5009
    }
5010
 
5011
    public InventoryServiceException getCex() {
5012
      return this.cex;
5013
    }
5014
 
5015
    public void setCex(InventoryServiceException cex) {
5016
      this.cex = cex;
5017
    }
5018
 
5019
    public void unsetCex() {
5020
      this.cex = null;
5021
    }
5022
 
5023
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
5024
    public boolean isSetCex() {
5025
      return this.cex != null;
5026
    }
5027
 
5028
    public void setCexIsSet(boolean value) {
5029
      if (!value) {
5030
        this.cex = null;
5031
      }
5032
    }
5033
 
5034
    public void setFieldValue(_Fields field, Object value) {
5035
      switch (field) {
5036
      case CEX:
5037
        if (value == null) {
5038
          unsetCex();
5039
        } else {
5040
          setCex((InventoryServiceException)value);
5041
        }
5042
        break;
5043
 
5044
      }
5045
    }
5046
 
5047
    public Object getFieldValue(_Fields field) {
5048
      switch (field) {
5049
      case CEX:
5050
        return getCex();
5051
 
5052
      }
5053
      throw new IllegalStateException();
5054
    }
5055
 
5056
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5057
    public boolean isSet(_Fields field) {
5058
      if (field == null) {
5059
        throw new IllegalArgumentException();
5060
      }
5061
 
5062
      switch (field) {
5063
      case CEX:
5064
        return isSetCex();
5065
      }
5066
      throw new IllegalStateException();
5067
    }
5068
 
5069
    @Override
5070
    public boolean equals(Object that) {
5071
      if (that == null)
5072
        return false;
5073
      if (that instanceof updateInventoryHistory_result)
5074
        return this.equals((updateInventoryHistory_result)that);
5075
      return false;
5076
    }
5077
 
5078
    public boolean equals(updateInventoryHistory_result that) {
5079
      if (that == null)
5080
        return false;
5081
 
5082
      boolean this_present_cex = true && this.isSetCex();
5083
      boolean that_present_cex = true && that.isSetCex();
5084
      if (this_present_cex || that_present_cex) {
5085
        if (!(this_present_cex && that_present_cex))
5086
          return false;
5087
        if (!this.cex.equals(that.cex))
5088
          return false;
5089
      }
5090
 
5091
      return true;
5092
    }
5093
 
5094
    @Override
5095
    public int hashCode() {
5096
      return 0;
5097
    }
5098
 
5099
    public int compareTo(updateInventoryHistory_result other) {
5100
      if (!getClass().equals(other.getClass())) {
5101
        return getClass().getName().compareTo(other.getClass().getName());
5102
      }
5103
 
5104
      int lastComparison = 0;
5105
      updateInventoryHistory_result typedOther = (updateInventoryHistory_result)other;
5106
 
5107
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
5108
      if (lastComparison != 0) {
5109
        return lastComparison;
5110
      }
5111
      if (isSetCex()) {
5112
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
5113
        if (lastComparison != 0) {
5114
          return lastComparison;
5115
        }
5116
      }
5117
      return 0;
5118
    }
5119
 
5120
    public _Fields fieldForId(int fieldId) {
5121
      return _Fields.findByThriftId(fieldId);
5122
    }
5123
 
5124
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5125
      org.apache.thrift.protocol.TField field;
5126
      iprot.readStructBegin();
5127
      while (true)
5128
      {
5129
        field = iprot.readFieldBegin();
5130
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5131
          break;
5132
        }
5133
        switch (field.id) {
5134
          case 1: // CEX
5135
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5136
              this.cex = new InventoryServiceException();
5137
              this.cex.read(iprot);
5138
            } else { 
5139
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5140
            }
5141
            break;
5142
          default:
5143
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5144
        }
5145
        iprot.readFieldEnd();
5146
      }
5147
      iprot.readStructEnd();
5148
      validate();
5149
    }
5150
 
5151
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5152
      oprot.writeStructBegin(STRUCT_DESC);
5153
 
5154
      if (this.isSetCex()) {
5155
        oprot.writeFieldBegin(CEX_FIELD_DESC);
5156
        this.cex.write(oprot);
5157
        oprot.writeFieldEnd();
5158
      }
5159
      oprot.writeFieldStop();
5160
      oprot.writeStructEnd();
5161
    }
5162
 
5163
    @Override
5164
    public String toString() {
5165
      StringBuilder sb = new StringBuilder("updateInventoryHistory_result(");
5166
      boolean first = true;
5167
 
5168
      sb.append("cex:");
5169
      if (this.cex == null) {
5170
        sb.append("null");
5171
      } else {
5172
        sb.append(this.cex);
5173
      }
5174
      first = false;
5175
      sb.append(")");
5176
      return sb.toString();
5177
    }
5178
 
5179
    public void validate() throws org.apache.thrift.TException {
5180
      // check for required fields
5181
    }
5182
 
5183
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5184
      try {
5185
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5186
      } catch (org.apache.thrift.TException te) {
5187
        throw new java.io.IOException(te);
5188
      }
5189
    }
5190
 
5191
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5192
      try {
5193
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5194
      } catch (org.apache.thrift.TException te) {
5195
        throw new java.io.IOException(te);
5196
      }
5197
    }
5198
 
5199
  }
5200
 
5201
  public static class updateInventory_args implements org.apache.thrift.TBase<updateInventory_args, updateInventory_args._Fields>, java.io.Serializable, Cloneable   {
5202
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventory_args");
5203
 
5204
    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);
5205
    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);
5206
    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);
5207
 
5208
    private long warehouse_id; // required
5209
    private String timestamp; // required
5210
    private Map<String,Long> availability; // required
5211
 
5212
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5213
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5214
      WAREHOUSE_ID((short)1, "warehouse_id"),
5215
      TIMESTAMP((short)2, "timestamp"),
5216
      AVAILABILITY((short)3, "availability");
5217
 
5218
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5219
 
5220
      static {
5221
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5222
          byName.put(field.getFieldName(), field);
5223
        }
5224
      }
5225
 
5226
      /**
5227
       * Find the _Fields constant that matches fieldId, or null if its not found.
5228
       */
5229
      public static _Fields findByThriftId(int fieldId) {
5230
        switch(fieldId) {
5231
          case 1: // WAREHOUSE_ID
5232
            return WAREHOUSE_ID;
5233
          case 2: // TIMESTAMP
5234
            return TIMESTAMP;
5235
          case 3: // AVAILABILITY
5236
            return AVAILABILITY;
5237
          default:
5238
            return null;
5239
        }
5240
      }
5241
 
5242
      /**
5243
       * Find the _Fields constant that matches fieldId, throwing an exception
5244
       * if it is not found.
5245
       */
5246
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5247
        _Fields fields = findByThriftId(fieldId);
5248
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5249
        return fields;
5250
      }
5251
 
5252
      /**
5253
       * Find the _Fields constant that matches name, or null if its not found.
5254
       */
5255
      public static _Fields findByName(String name) {
5256
        return byName.get(name);
5257
      }
5258
 
5259
      private final short _thriftId;
5260
      private final String _fieldName;
5261
 
5262
      _Fields(short thriftId, String fieldName) {
5263
        _thriftId = thriftId;
5264
        _fieldName = fieldName;
5265
      }
5266
 
5267
      public short getThriftFieldId() {
5268
        return _thriftId;
5269
      }
5270
 
5271
      public String getFieldName() {
5272
        return _fieldName;
5273
      }
5274
    }
5275
 
5276
    // isset id assignments
5277
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
5278
    private BitSet __isset_bit_vector = new BitSet(1);
5279
 
5280
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5281
    static {
5282
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5283
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5284
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5285
      tmpMap.put(_Fields.TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("timestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5286
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
5287
      tmpMap.put(_Fields.AVAILABILITY, new org.apache.thrift.meta_data.FieldMetaData("availability", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5288
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
5289
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
5290
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
5291
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5292
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventory_args.class, metaDataMap);
5293
    }
5294
 
5295
    public updateInventory_args() {
5296
    }
5297
 
5298
    public updateInventory_args(
5299
      long warehouse_id,
5300
      String timestamp,
5301
      Map<String,Long> availability)
5302
    {
5303
      this();
5304
      this.warehouse_id = warehouse_id;
5305
      setWarehouse_idIsSet(true);
5306
      this.timestamp = timestamp;
5307
      this.availability = availability;
5308
    }
5309
 
5310
    /**
5311
     * Performs a deep copy on <i>other</i>.
5312
     */
5313
    public updateInventory_args(updateInventory_args other) {
5314
      __isset_bit_vector.clear();
5315
      __isset_bit_vector.or(other.__isset_bit_vector);
5316
      this.warehouse_id = other.warehouse_id;
5317
      if (other.isSetTimestamp()) {
5318
        this.timestamp = other.timestamp;
5319
      }
5320
      if (other.isSetAvailability()) {
5321
        Map<String,Long> __this__availability = new HashMap<String,Long>();
5322
        for (Map.Entry<String, Long> other_element : other.availability.entrySet()) {
5323
 
5324
          String other_element_key = other_element.getKey();
5325
          Long other_element_value = other_element.getValue();
5326
 
5327
          String __this__availability_copy_key = other_element_key;
5328
 
5329
          Long __this__availability_copy_value = other_element_value;
5330
 
5331
          __this__availability.put(__this__availability_copy_key, __this__availability_copy_value);
5332
        }
5333
        this.availability = __this__availability;
5334
      }
5335
    }
5336
 
5337
    public updateInventory_args deepCopy() {
5338
      return new updateInventory_args(this);
5339
    }
5340
 
5341
    @Override
5342
    public void clear() {
5343
      setWarehouse_idIsSet(false);
5344
      this.warehouse_id = 0;
5345
      this.timestamp = null;
5346
      this.availability = null;
5347
    }
5348
 
5349
    public long getWarehouse_id() {
5350
      return this.warehouse_id;
5351
    }
5352
 
5353
    public void setWarehouse_id(long warehouse_id) {
5354
      this.warehouse_id = warehouse_id;
5355
      setWarehouse_idIsSet(true);
5356
    }
5357
 
5358
    public void unsetWarehouse_id() {
5359
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
5360
    }
5361
 
5362
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
5363
    public boolean isSetWarehouse_id() {
5364
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
5365
    }
5366
 
5367
    public void setWarehouse_idIsSet(boolean value) {
5368
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
5369
    }
5370
 
5371
    public String getTimestamp() {
5372
      return this.timestamp;
5373
    }
5374
 
5375
    public void setTimestamp(String timestamp) {
5376
      this.timestamp = timestamp;
5377
    }
5378
 
5379
    public void unsetTimestamp() {
5380
      this.timestamp = null;
5381
    }
5382
 
5383
    /** Returns true if field timestamp is set (has been assigned a value) and false otherwise */
5384
    public boolean isSetTimestamp() {
5385
      return this.timestamp != null;
5386
    }
5387
 
5388
    public void setTimestampIsSet(boolean value) {
5389
      if (!value) {
5390
        this.timestamp = null;
5391
      }
5392
    }
5393
 
5394
    public int getAvailabilitySize() {
5395
      return (this.availability == null) ? 0 : this.availability.size();
5396
    }
5397
 
5398
    public void putToAvailability(String key, long val) {
5399
      if (this.availability == null) {
5400
        this.availability = new HashMap<String,Long>();
5401
      }
5402
      this.availability.put(key, val);
5403
    }
5404
 
5405
    public Map<String,Long> getAvailability() {
5406
      return this.availability;
5407
    }
5408
 
5409
    public void setAvailability(Map<String,Long> availability) {
5410
      this.availability = availability;
5411
    }
5412
 
5413
    public void unsetAvailability() {
5414
      this.availability = null;
5415
    }
5416
 
5417
    /** Returns true if field availability is set (has been assigned a value) and false otherwise */
5418
    public boolean isSetAvailability() {
5419
      return this.availability != null;
5420
    }
5421
 
5422
    public void setAvailabilityIsSet(boolean value) {
5423
      if (!value) {
5424
        this.availability = null;
5425
      }
5426
    }
5427
 
5428
    public void setFieldValue(_Fields field, Object value) {
5429
      switch (field) {
5430
      case WAREHOUSE_ID:
5431
        if (value == null) {
5432
          unsetWarehouse_id();
5433
        } else {
5434
          setWarehouse_id((Long)value);
5435
        }
5436
        break;
5437
 
5438
      case TIMESTAMP:
5439
        if (value == null) {
5440
          unsetTimestamp();
5441
        } else {
5442
          setTimestamp((String)value);
5443
        }
5444
        break;
5445
 
5446
      case AVAILABILITY:
5447
        if (value == null) {
5448
          unsetAvailability();
5449
        } else {
5450
          setAvailability((Map<String,Long>)value);
5451
        }
5452
        break;
5453
 
5454
      }
5455
    }
5456
 
5457
    public Object getFieldValue(_Fields field) {
5458
      switch (field) {
5459
      case WAREHOUSE_ID:
5460
        return Long.valueOf(getWarehouse_id());
5461
 
5462
      case TIMESTAMP:
5463
        return getTimestamp();
5464
 
5465
      case AVAILABILITY:
5466
        return getAvailability();
5467
 
5468
      }
5469
      throw new IllegalStateException();
5470
    }
5471
 
5472
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5473
    public boolean isSet(_Fields field) {
5474
      if (field == null) {
5475
        throw new IllegalArgumentException();
5476
      }
5477
 
5478
      switch (field) {
5479
      case WAREHOUSE_ID:
5480
        return isSetWarehouse_id();
5481
      case TIMESTAMP:
5482
        return isSetTimestamp();
5483
      case AVAILABILITY:
5484
        return isSetAvailability();
5485
      }
5486
      throw new IllegalStateException();
5487
    }
5488
 
5489
    @Override
5490
    public boolean equals(Object that) {
5491
      if (that == null)
5492
        return false;
5493
      if (that instanceof updateInventory_args)
5494
        return this.equals((updateInventory_args)that);
5495
      return false;
5496
    }
5497
 
5498
    public boolean equals(updateInventory_args that) {
5499
      if (that == null)
5500
        return false;
5501
 
5502
      boolean this_present_warehouse_id = true;
5503
      boolean that_present_warehouse_id = true;
5504
      if (this_present_warehouse_id || that_present_warehouse_id) {
5505
        if (!(this_present_warehouse_id && that_present_warehouse_id))
5506
          return false;
5507
        if (this.warehouse_id != that.warehouse_id)
5508
          return false;
5509
      }
5510
 
5511
      boolean this_present_timestamp = true && this.isSetTimestamp();
5512
      boolean that_present_timestamp = true && that.isSetTimestamp();
5513
      if (this_present_timestamp || that_present_timestamp) {
5514
        if (!(this_present_timestamp && that_present_timestamp))
5515
          return false;
5516
        if (!this.timestamp.equals(that.timestamp))
5517
          return false;
5518
      }
5519
 
5520
      boolean this_present_availability = true && this.isSetAvailability();
5521
      boolean that_present_availability = true && that.isSetAvailability();
5522
      if (this_present_availability || that_present_availability) {
5523
        if (!(this_present_availability && that_present_availability))
5524
          return false;
5525
        if (!this.availability.equals(that.availability))
5526
          return false;
5527
      }
5528
 
5529
      return true;
5530
    }
5531
 
5532
    @Override
5533
    public int hashCode() {
5534
      return 0;
5535
    }
5536
 
5537
    public int compareTo(updateInventory_args other) {
5538
      if (!getClass().equals(other.getClass())) {
5539
        return getClass().getName().compareTo(other.getClass().getName());
5540
      }
5541
 
5542
      int lastComparison = 0;
5543
      updateInventory_args typedOther = (updateInventory_args)other;
5544
 
5545
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
5546
      if (lastComparison != 0) {
5547
        return lastComparison;
5548
      }
5549
      if (isSetWarehouse_id()) {
5550
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
5551
        if (lastComparison != 0) {
5552
          return lastComparison;
5553
        }
5554
      }
5555
      lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(typedOther.isSetTimestamp());
5556
      if (lastComparison != 0) {
5557
        return lastComparison;
5558
      }
5559
      if (isSetTimestamp()) {
5560
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.timestamp, typedOther.timestamp);
5561
        if (lastComparison != 0) {
5562
          return lastComparison;
5563
        }
5564
      }
5565
      lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(typedOther.isSetAvailability());
5566
      if (lastComparison != 0) {
5567
        return lastComparison;
5568
      }
5569
      if (isSetAvailability()) {
5570
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.availability, typedOther.availability);
5571
        if (lastComparison != 0) {
5572
          return lastComparison;
5573
        }
5574
      }
5575
      return 0;
5576
    }
5577
 
5578
    public _Fields fieldForId(int fieldId) {
5579
      return _Fields.findByThriftId(fieldId);
5580
    }
5581
 
5582
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5583
      org.apache.thrift.protocol.TField field;
5584
      iprot.readStructBegin();
5585
      while (true)
5586
      {
5587
        field = iprot.readFieldBegin();
5588
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5589
          break;
5590
        }
5591
        switch (field.id) {
5592
          case 1: // WAREHOUSE_ID
5593
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5594
              this.warehouse_id = iprot.readI64();
5595
              setWarehouse_idIsSet(true);
5596
            } else { 
5597
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5598
            }
5599
            break;
5600
          case 2: // TIMESTAMP
5601
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
5602
              this.timestamp = iprot.readString();
5603
            } else { 
5604
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5605
            }
5606
            break;
5607
          case 3: // AVAILABILITY
5608
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
5609
              {
5610
                org.apache.thrift.protocol.TMap _map15 = iprot.readMapBegin();
5611
                this.availability = new HashMap<String,Long>(2*_map15.size);
5612
                for (int _i16 = 0; _i16 < _map15.size; ++_i16)
5613
                {
5614
                  String _key17; // required
5615
                  long _val18; // required
5616
                  _key17 = iprot.readString();
5617
                  _val18 = iprot.readI64();
5618
                  this.availability.put(_key17, _val18);
5619
                }
5620
                iprot.readMapEnd();
5621
              }
5622
            } else { 
5623
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5624
            }
5625
            break;
5626
          default:
5627
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5628
        }
5629
        iprot.readFieldEnd();
5630
      }
5631
      iprot.readStructEnd();
5632
      validate();
5633
    }
5634
 
5635
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5636
      validate();
5637
 
5638
      oprot.writeStructBegin(STRUCT_DESC);
5639
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
5640
      oprot.writeI64(this.warehouse_id);
5641
      oprot.writeFieldEnd();
5642
      if (this.timestamp != null) {
5643
        oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
5644
        oprot.writeString(this.timestamp);
5645
        oprot.writeFieldEnd();
5646
      }
5647
      if (this.availability != null) {
5648
        oprot.writeFieldBegin(AVAILABILITY_FIELD_DESC);
5649
        {
5650
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.I64, this.availability.size()));
5651
          for (Map.Entry<String, Long> _iter19 : this.availability.entrySet())
5652
          {
5653
            oprot.writeString(_iter19.getKey());
5654
            oprot.writeI64(_iter19.getValue());
5655
          }
5656
          oprot.writeMapEnd();
5657
        }
5658
        oprot.writeFieldEnd();
5659
      }
5660
      oprot.writeFieldStop();
5661
      oprot.writeStructEnd();
5662
    }
5663
 
5664
    @Override
5665
    public String toString() {
5666
      StringBuilder sb = new StringBuilder("updateInventory_args(");
5667
      boolean first = true;
5668
 
5669
      sb.append("warehouse_id:");
5670
      sb.append(this.warehouse_id);
5671
      first = false;
5672
      if (!first) sb.append(", ");
5673
      sb.append("timestamp:");
5674
      if (this.timestamp == null) {
5675
        sb.append("null");
5676
      } else {
5677
        sb.append(this.timestamp);
5678
      }
5679
      first = false;
5680
      if (!first) sb.append(", ");
5681
      sb.append("availability:");
5682
      if (this.availability == null) {
5683
        sb.append("null");
5684
      } else {
5685
        sb.append(this.availability);
5686
      }
5687
      first = false;
5688
      sb.append(")");
5689
      return sb.toString();
5690
    }
5691
 
5692
    public void validate() throws org.apache.thrift.TException {
5693
      // check for required fields
5694
    }
5695
 
5696
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5697
      try {
5698
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5699
      } catch (org.apache.thrift.TException te) {
5700
        throw new java.io.IOException(te);
5701
      }
5702
    }
5703
 
5704
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5705
      try {
5706
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
5707
        __isset_bit_vector = new BitSet(1);
5708
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5709
      } catch (org.apache.thrift.TException te) {
5710
        throw new java.io.IOException(te);
5711
      }
5712
    }
5713
 
5714
  }
5715
 
5716
  public static class updateInventory_result implements org.apache.thrift.TBase<updateInventory_result, updateInventory_result._Fields>, java.io.Serializable, Cloneable   {
5717
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventory_result");
5718
 
5719
    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);
5720
 
5721
    private InventoryServiceException cex; // required
5722
 
5723
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5724
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5725
      CEX((short)1, "cex");
5726
 
5727
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5728
 
5729
      static {
5730
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5731
          byName.put(field.getFieldName(), field);
5732
        }
5733
      }
5734
 
5735
      /**
5736
       * Find the _Fields constant that matches fieldId, or null if its not found.
5737
       */
5738
      public static _Fields findByThriftId(int fieldId) {
5739
        switch(fieldId) {
5740
          case 1: // CEX
5741
            return CEX;
5742
          default:
5743
            return null;
5744
        }
5745
      }
5746
 
5747
      /**
5748
       * Find the _Fields constant that matches fieldId, throwing an exception
5749
       * if it is not found.
5750
       */
5751
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5752
        _Fields fields = findByThriftId(fieldId);
5753
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5754
        return fields;
5755
      }
5756
 
5757
      /**
5758
       * Find the _Fields constant that matches name, or null if its not found.
5759
       */
5760
      public static _Fields findByName(String name) {
5761
        return byName.get(name);
5762
      }
5763
 
5764
      private final short _thriftId;
5765
      private final String _fieldName;
5766
 
5767
      _Fields(short thriftId, String fieldName) {
5768
        _thriftId = thriftId;
5769
        _fieldName = fieldName;
5770
      }
5771
 
5772
      public short getThriftFieldId() {
5773
        return _thriftId;
5774
      }
5775
 
5776
      public String getFieldName() {
5777
        return _fieldName;
5778
      }
5779
    }
5780
 
5781
    // isset id assignments
5782
 
5783
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5784
    static {
5785
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5786
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5787
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5788
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5789
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventory_result.class, metaDataMap);
5790
    }
5791
 
5792
    public updateInventory_result() {
5793
    }
5794
 
5795
    public updateInventory_result(
5796
      InventoryServiceException cex)
5797
    {
5798
      this();
5799
      this.cex = cex;
5800
    }
5801
 
5802
    /**
5803
     * Performs a deep copy on <i>other</i>.
5804
     */
5805
    public updateInventory_result(updateInventory_result other) {
5806
      if (other.isSetCex()) {
5807
        this.cex = new InventoryServiceException(other.cex);
5808
      }
5809
    }
5810
 
5811
    public updateInventory_result deepCopy() {
5812
      return new updateInventory_result(this);
5813
    }
5814
 
5815
    @Override
5816
    public void clear() {
5817
      this.cex = null;
5818
    }
5819
 
5820
    public InventoryServiceException getCex() {
5821
      return this.cex;
5822
    }
5823
 
5824
    public void setCex(InventoryServiceException cex) {
5825
      this.cex = cex;
5826
    }
5827
 
5828
    public void unsetCex() {
5829
      this.cex = null;
5830
    }
5831
 
5832
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
5833
    public boolean isSetCex() {
5834
      return this.cex != null;
5835
    }
5836
 
5837
    public void setCexIsSet(boolean value) {
5838
      if (!value) {
5839
        this.cex = null;
5840
      }
5841
    }
5842
 
5843
    public void setFieldValue(_Fields field, Object value) {
5844
      switch (field) {
5845
      case CEX:
5846
        if (value == null) {
5847
          unsetCex();
5848
        } else {
5849
          setCex((InventoryServiceException)value);
5850
        }
5851
        break;
5852
 
5853
      }
5854
    }
5855
 
5856
    public Object getFieldValue(_Fields field) {
5857
      switch (field) {
5858
      case CEX:
5859
        return getCex();
5860
 
5861
      }
5862
      throw new IllegalStateException();
5863
    }
5864
 
5865
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5866
    public boolean isSet(_Fields field) {
5867
      if (field == null) {
5868
        throw new IllegalArgumentException();
5869
      }
5870
 
5871
      switch (field) {
5872
      case CEX:
5873
        return isSetCex();
5874
      }
5875
      throw new IllegalStateException();
5876
    }
5877
 
5878
    @Override
5879
    public boolean equals(Object that) {
5880
      if (that == null)
5881
        return false;
5882
      if (that instanceof updateInventory_result)
5883
        return this.equals((updateInventory_result)that);
5884
      return false;
5885
    }
5886
 
5887
    public boolean equals(updateInventory_result that) {
5888
      if (that == null)
5889
        return false;
5890
 
5891
      boolean this_present_cex = true && this.isSetCex();
5892
      boolean that_present_cex = true && that.isSetCex();
5893
      if (this_present_cex || that_present_cex) {
5894
        if (!(this_present_cex && that_present_cex))
5895
          return false;
5896
        if (!this.cex.equals(that.cex))
5897
          return false;
5898
      }
5899
 
5900
      return true;
5901
    }
5902
 
5903
    @Override
5904
    public int hashCode() {
5905
      return 0;
5906
    }
5907
 
5908
    public int compareTo(updateInventory_result other) {
5909
      if (!getClass().equals(other.getClass())) {
5910
        return getClass().getName().compareTo(other.getClass().getName());
5911
      }
5912
 
5913
      int lastComparison = 0;
5914
      updateInventory_result typedOther = (updateInventory_result)other;
5915
 
5916
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
5917
      if (lastComparison != 0) {
5918
        return lastComparison;
5919
      }
5920
      if (isSetCex()) {
5921
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
5922
        if (lastComparison != 0) {
5923
          return lastComparison;
5924
        }
5925
      }
5926
      return 0;
5927
    }
5928
 
5929
    public _Fields fieldForId(int fieldId) {
5930
      return _Fields.findByThriftId(fieldId);
5931
    }
5932
 
5933
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5934
      org.apache.thrift.protocol.TField field;
5935
      iprot.readStructBegin();
5936
      while (true)
5937
      {
5938
        field = iprot.readFieldBegin();
5939
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5940
          break;
5941
        }
5942
        switch (field.id) {
5943
          case 1: // CEX
5944
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5945
              this.cex = new InventoryServiceException();
5946
              this.cex.read(iprot);
5947
            } else { 
5948
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5949
            }
5950
            break;
5951
          default:
5952
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5953
        }
5954
        iprot.readFieldEnd();
5955
      }
5956
      iprot.readStructEnd();
5957
      validate();
5958
    }
5959
 
5960
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5961
      oprot.writeStructBegin(STRUCT_DESC);
5962
 
5963
      if (this.isSetCex()) {
5964
        oprot.writeFieldBegin(CEX_FIELD_DESC);
5965
        this.cex.write(oprot);
5966
        oprot.writeFieldEnd();
5967
      }
5968
      oprot.writeFieldStop();
5969
      oprot.writeStructEnd();
5970
    }
5971
 
5972
    @Override
5973
    public String toString() {
5974
      StringBuilder sb = new StringBuilder("updateInventory_result(");
5975
      boolean first = true;
5976
 
5977
      sb.append("cex:");
5978
      if (this.cex == null) {
5979
        sb.append("null");
5980
      } else {
5981
        sb.append(this.cex);
5982
      }
5983
      first = false;
5984
      sb.append(")");
5985
      return sb.toString();
5986
    }
5987
 
5988
    public void validate() throws org.apache.thrift.TException {
5989
      // check for required fields
5990
    }
5991
 
5992
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5993
      try {
5994
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5995
      } catch (org.apache.thrift.TException te) {
5996
        throw new java.io.IOException(te);
5997
      }
5998
    }
5999
 
6000
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6001
      try {
6002
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6003
      } catch (org.apache.thrift.TException te) {
6004
        throw new java.io.IOException(te);
6005
      }
6006
    }
6007
 
6008
  }
6009
 
6010
  public static class addInventory_args implements org.apache.thrift.TBase<addInventory_args, addInventory_args._Fields>, java.io.Serializable, Cloneable   {
6011
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addInventory_args");
6012
 
6013
    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);
6014
    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);
6015
    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);
6016
 
6017
    private long itemId; // required
6018
    private long warehouseId; // required
6019
    private long quantity; // required
6020
 
6021
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6022
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6023
      ITEM_ID((short)1, "itemId"),
6024
      WAREHOUSE_ID((short)2, "warehouseId"),
6025
      QUANTITY((short)3, "quantity");
6026
 
6027
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6028
 
6029
      static {
6030
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6031
          byName.put(field.getFieldName(), field);
6032
        }
6033
      }
6034
 
6035
      /**
6036
       * Find the _Fields constant that matches fieldId, or null if its not found.
6037
       */
6038
      public static _Fields findByThriftId(int fieldId) {
6039
        switch(fieldId) {
6040
          case 1: // ITEM_ID
6041
            return ITEM_ID;
6042
          case 2: // WAREHOUSE_ID
6043
            return WAREHOUSE_ID;
6044
          case 3: // QUANTITY
6045
            return QUANTITY;
6046
          default:
6047
            return null;
6048
        }
6049
      }
6050
 
6051
      /**
6052
       * Find the _Fields constant that matches fieldId, throwing an exception
6053
       * if it is not found.
6054
       */
6055
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6056
        _Fields fields = findByThriftId(fieldId);
6057
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6058
        return fields;
6059
      }
6060
 
6061
      /**
6062
       * Find the _Fields constant that matches name, or null if its not found.
6063
       */
6064
      public static _Fields findByName(String name) {
6065
        return byName.get(name);
6066
      }
6067
 
6068
      private final short _thriftId;
6069
      private final String _fieldName;
6070
 
6071
      _Fields(short thriftId, String fieldName) {
6072
        _thriftId = thriftId;
6073
        _fieldName = fieldName;
6074
      }
6075
 
6076
      public short getThriftFieldId() {
6077
        return _thriftId;
6078
      }
6079
 
6080
      public String getFieldName() {
6081
        return _fieldName;
6082
      }
6083
    }
6084
 
6085
    // isset id assignments
6086
    private static final int __ITEMID_ISSET_ID = 0;
6087
    private static final int __WAREHOUSEID_ISSET_ID = 1;
6088
    private static final int __QUANTITY_ISSET_ID = 2;
6089
    private BitSet __isset_bit_vector = new BitSet(3);
6090
 
6091
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6092
    static {
6093
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6094
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6095
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6096
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6097
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6098
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6099
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6100
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6101
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addInventory_args.class, metaDataMap);
6102
    }
6103
 
6104
    public addInventory_args() {
6105
    }
6106
 
6107
    public addInventory_args(
6108
      long itemId,
6109
      long warehouseId,
6110
      long quantity)
6111
    {
6112
      this();
6113
      this.itemId = itemId;
6114
      setItemIdIsSet(true);
6115
      this.warehouseId = warehouseId;
6116
      setWarehouseIdIsSet(true);
6117
      this.quantity = quantity;
6118
      setQuantityIsSet(true);
6119
    }
6120
 
6121
    /**
6122
     * Performs a deep copy on <i>other</i>.
6123
     */
6124
    public addInventory_args(addInventory_args other) {
6125
      __isset_bit_vector.clear();
6126
      __isset_bit_vector.or(other.__isset_bit_vector);
6127
      this.itemId = other.itemId;
6128
      this.warehouseId = other.warehouseId;
6129
      this.quantity = other.quantity;
6130
    }
6131
 
6132
    public addInventory_args deepCopy() {
6133
      return new addInventory_args(this);
6134
    }
6135
 
6136
    @Override
6137
    public void clear() {
6138
      setItemIdIsSet(false);
6139
      this.itemId = 0;
6140
      setWarehouseIdIsSet(false);
6141
      this.warehouseId = 0;
6142
      setQuantityIsSet(false);
6143
      this.quantity = 0;
6144
    }
6145
 
6146
    public long getItemId() {
6147
      return this.itemId;
6148
    }
6149
 
6150
    public void setItemId(long itemId) {
6151
      this.itemId = itemId;
6152
      setItemIdIsSet(true);
6153
    }
6154
 
6155
    public void unsetItemId() {
6156
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
6157
    }
6158
 
6159
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
6160
    public boolean isSetItemId() {
6161
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
6162
    }
6163
 
6164
    public void setItemIdIsSet(boolean value) {
6165
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
6166
    }
6167
 
6168
    public long getWarehouseId() {
6169
      return this.warehouseId;
6170
    }
6171
 
6172
    public void setWarehouseId(long warehouseId) {
6173
      this.warehouseId = warehouseId;
6174
      setWarehouseIdIsSet(true);
6175
    }
6176
 
6177
    public void unsetWarehouseId() {
6178
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
6179
    }
6180
 
6181
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
6182
    public boolean isSetWarehouseId() {
6183
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
6184
    }
6185
 
6186
    public void setWarehouseIdIsSet(boolean value) {
6187
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
6188
    }
6189
 
6190
    public long getQuantity() {
6191
      return this.quantity;
6192
    }
6193
 
6194
    public void setQuantity(long quantity) {
6195
      this.quantity = quantity;
6196
      setQuantityIsSet(true);
6197
    }
6198
 
6199
    public void unsetQuantity() {
6200
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
6201
    }
6202
 
6203
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
6204
    public boolean isSetQuantity() {
6205
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
6206
    }
6207
 
6208
    public void setQuantityIsSet(boolean value) {
6209
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
6210
    }
6211
 
6212
    public void setFieldValue(_Fields field, Object value) {
6213
      switch (field) {
6214
      case ITEM_ID:
6215
        if (value == null) {
6216
          unsetItemId();
6217
        } else {
6218
          setItemId((Long)value);
6219
        }
6220
        break;
6221
 
6222
      case WAREHOUSE_ID:
6223
        if (value == null) {
6224
          unsetWarehouseId();
6225
        } else {
6226
          setWarehouseId((Long)value);
6227
        }
6228
        break;
6229
 
6230
      case QUANTITY:
6231
        if (value == null) {
6232
          unsetQuantity();
6233
        } else {
6234
          setQuantity((Long)value);
6235
        }
6236
        break;
6237
 
6238
      }
6239
    }
6240
 
6241
    public Object getFieldValue(_Fields field) {
6242
      switch (field) {
6243
      case ITEM_ID:
6244
        return Long.valueOf(getItemId());
6245
 
6246
      case WAREHOUSE_ID:
6247
        return Long.valueOf(getWarehouseId());
6248
 
6249
      case QUANTITY:
6250
        return Long.valueOf(getQuantity());
6251
 
6252
      }
6253
      throw new IllegalStateException();
6254
    }
6255
 
6256
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6257
    public boolean isSet(_Fields field) {
6258
      if (field == null) {
6259
        throw new IllegalArgumentException();
6260
      }
6261
 
6262
      switch (field) {
6263
      case ITEM_ID:
6264
        return isSetItemId();
6265
      case WAREHOUSE_ID:
6266
        return isSetWarehouseId();
6267
      case QUANTITY:
6268
        return isSetQuantity();
6269
      }
6270
      throw new IllegalStateException();
6271
    }
6272
 
6273
    @Override
6274
    public boolean equals(Object that) {
6275
      if (that == null)
6276
        return false;
6277
      if (that instanceof addInventory_args)
6278
        return this.equals((addInventory_args)that);
6279
      return false;
6280
    }
6281
 
6282
    public boolean equals(addInventory_args that) {
6283
      if (that == null)
6284
        return false;
6285
 
6286
      boolean this_present_itemId = true;
6287
      boolean that_present_itemId = true;
6288
      if (this_present_itemId || that_present_itemId) {
6289
        if (!(this_present_itemId && that_present_itemId))
6290
          return false;
6291
        if (this.itemId != that.itemId)
6292
          return false;
6293
      }
6294
 
6295
      boolean this_present_warehouseId = true;
6296
      boolean that_present_warehouseId = true;
6297
      if (this_present_warehouseId || that_present_warehouseId) {
6298
        if (!(this_present_warehouseId && that_present_warehouseId))
6299
          return false;
6300
        if (this.warehouseId != that.warehouseId)
6301
          return false;
6302
      }
6303
 
6304
      boolean this_present_quantity = true;
6305
      boolean that_present_quantity = true;
6306
      if (this_present_quantity || that_present_quantity) {
6307
        if (!(this_present_quantity && that_present_quantity))
6308
          return false;
6309
        if (this.quantity != that.quantity)
6310
          return false;
6311
      }
6312
 
6313
      return true;
6314
    }
6315
 
6316
    @Override
6317
    public int hashCode() {
6318
      return 0;
6319
    }
6320
 
6321
    public int compareTo(addInventory_args other) {
6322
      if (!getClass().equals(other.getClass())) {
6323
        return getClass().getName().compareTo(other.getClass().getName());
6324
      }
6325
 
6326
      int lastComparison = 0;
6327
      addInventory_args typedOther = (addInventory_args)other;
6328
 
6329
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
6330
      if (lastComparison != 0) {
6331
        return lastComparison;
6332
      }
6333
      if (isSetItemId()) {
6334
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
6335
        if (lastComparison != 0) {
6336
          return lastComparison;
6337
        }
6338
      }
6339
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
6340
      if (lastComparison != 0) {
6341
        return lastComparison;
6342
      }
6343
      if (isSetWarehouseId()) {
6344
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
6345
        if (lastComparison != 0) {
6346
          return lastComparison;
6347
        }
6348
      }
6349
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
6350
      if (lastComparison != 0) {
6351
        return lastComparison;
6352
      }
6353
      if (isSetQuantity()) {
6354
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
6355
        if (lastComparison != 0) {
6356
          return lastComparison;
6357
        }
6358
      }
6359
      return 0;
6360
    }
6361
 
6362
    public _Fields fieldForId(int fieldId) {
6363
      return _Fields.findByThriftId(fieldId);
6364
    }
6365
 
6366
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6367
      org.apache.thrift.protocol.TField field;
6368
      iprot.readStructBegin();
6369
      while (true)
6370
      {
6371
        field = iprot.readFieldBegin();
6372
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6373
          break;
6374
        }
6375
        switch (field.id) {
6376
          case 1: // ITEM_ID
6377
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6378
              this.itemId = iprot.readI64();
6379
              setItemIdIsSet(true);
6380
            } else { 
6381
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6382
            }
6383
            break;
6384
          case 2: // WAREHOUSE_ID
6385
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6386
              this.warehouseId = iprot.readI64();
6387
              setWarehouseIdIsSet(true);
6388
            } else { 
6389
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6390
            }
6391
            break;
6392
          case 3: // QUANTITY
6393
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6394
              this.quantity = iprot.readI64();
6395
              setQuantityIsSet(true);
6396
            } else { 
6397
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6398
            }
6399
            break;
6400
          default:
6401
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6402
        }
6403
        iprot.readFieldEnd();
6404
      }
6405
      iprot.readStructEnd();
6406
      validate();
6407
    }
6408
 
6409
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6410
      validate();
6411
 
6412
      oprot.writeStructBegin(STRUCT_DESC);
6413
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
6414
      oprot.writeI64(this.itemId);
6415
      oprot.writeFieldEnd();
6416
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
6417
      oprot.writeI64(this.warehouseId);
6418
      oprot.writeFieldEnd();
6419
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
6420
      oprot.writeI64(this.quantity);
6421
      oprot.writeFieldEnd();
6422
      oprot.writeFieldStop();
6423
      oprot.writeStructEnd();
6424
    }
6425
 
6426
    @Override
6427
    public String toString() {
6428
      StringBuilder sb = new StringBuilder("addInventory_args(");
6429
      boolean first = true;
6430
 
6431
      sb.append("itemId:");
6432
      sb.append(this.itemId);
6433
      first = false;
6434
      if (!first) sb.append(", ");
6435
      sb.append("warehouseId:");
6436
      sb.append(this.warehouseId);
6437
      first = false;
6438
      if (!first) sb.append(", ");
6439
      sb.append("quantity:");
6440
      sb.append(this.quantity);
6441
      first = false;
6442
      sb.append(")");
6443
      return sb.toString();
6444
    }
6445
 
6446
    public void validate() throws org.apache.thrift.TException {
6447
      // check for required fields
6448
    }
6449
 
6450
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6451
      try {
6452
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6453
      } catch (org.apache.thrift.TException te) {
6454
        throw new java.io.IOException(te);
6455
      }
6456
    }
6457
 
6458
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6459
      try {
6460
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
6461
        __isset_bit_vector = new BitSet(1);
6462
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6463
      } catch (org.apache.thrift.TException te) {
6464
        throw new java.io.IOException(te);
6465
      }
6466
    }
6467
 
6468
  }
6469
 
6470
  public static class addInventory_result implements org.apache.thrift.TBase<addInventory_result, addInventory_result._Fields>, java.io.Serializable, Cloneable   {
6471
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addInventory_result");
6472
 
6473
    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);
6474
 
6475
    private InventoryServiceException cex; // required
6476
 
6477
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6478
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6479
      CEX((short)1, "cex");
6480
 
6481
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6482
 
6483
      static {
6484
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6485
          byName.put(field.getFieldName(), field);
6486
        }
6487
      }
6488
 
6489
      /**
6490
       * Find the _Fields constant that matches fieldId, or null if its not found.
6491
       */
6492
      public static _Fields findByThriftId(int fieldId) {
6493
        switch(fieldId) {
6494
          case 1: // CEX
6495
            return CEX;
6496
          default:
6497
            return null;
6498
        }
6499
      }
6500
 
6501
      /**
6502
       * Find the _Fields constant that matches fieldId, throwing an exception
6503
       * if it is not found.
6504
       */
6505
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6506
        _Fields fields = findByThriftId(fieldId);
6507
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6508
        return fields;
6509
      }
6510
 
6511
      /**
6512
       * Find the _Fields constant that matches name, or null if its not found.
6513
       */
6514
      public static _Fields findByName(String name) {
6515
        return byName.get(name);
6516
      }
6517
 
6518
      private final short _thriftId;
6519
      private final String _fieldName;
6520
 
6521
      _Fields(short thriftId, String fieldName) {
6522
        _thriftId = thriftId;
6523
        _fieldName = fieldName;
6524
      }
6525
 
6526
      public short getThriftFieldId() {
6527
        return _thriftId;
6528
      }
6529
 
6530
      public String getFieldName() {
6531
        return _fieldName;
6532
      }
6533
    }
6534
 
6535
    // isset id assignments
6536
 
6537
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6538
    static {
6539
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6540
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6541
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6542
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6543
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addInventory_result.class, metaDataMap);
6544
    }
6545
 
6546
    public addInventory_result() {
6547
    }
6548
 
6549
    public addInventory_result(
6550
      InventoryServiceException cex)
6551
    {
6552
      this();
6553
      this.cex = cex;
6554
    }
6555
 
6556
    /**
6557
     * Performs a deep copy on <i>other</i>.
6558
     */
6559
    public addInventory_result(addInventory_result other) {
6560
      if (other.isSetCex()) {
6561
        this.cex = new InventoryServiceException(other.cex);
6562
      }
6563
    }
6564
 
6565
    public addInventory_result deepCopy() {
6566
      return new addInventory_result(this);
6567
    }
6568
 
6569
    @Override
6570
    public void clear() {
6571
      this.cex = null;
6572
    }
6573
 
6574
    public InventoryServiceException getCex() {
6575
      return this.cex;
6576
    }
6577
 
6578
    public void setCex(InventoryServiceException cex) {
6579
      this.cex = cex;
6580
    }
6581
 
6582
    public void unsetCex() {
6583
      this.cex = null;
6584
    }
6585
 
6586
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
6587
    public boolean isSetCex() {
6588
      return this.cex != null;
6589
    }
6590
 
6591
    public void setCexIsSet(boolean value) {
6592
      if (!value) {
6593
        this.cex = null;
6594
      }
6595
    }
6596
 
6597
    public void setFieldValue(_Fields field, Object value) {
6598
      switch (field) {
6599
      case CEX:
6600
        if (value == null) {
6601
          unsetCex();
6602
        } else {
6603
          setCex((InventoryServiceException)value);
6604
        }
6605
        break;
6606
 
6607
      }
6608
    }
6609
 
6610
    public Object getFieldValue(_Fields field) {
6611
      switch (field) {
6612
      case CEX:
6613
        return getCex();
6614
 
6615
      }
6616
      throw new IllegalStateException();
6617
    }
6618
 
6619
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6620
    public boolean isSet(_Fields field) {
6621
      if (field == null) {
6622
        throw new IllegalArgumentException();
6623
      }
6624
 
6625
      switch (field) {
6626
      case CEX:
6627
        return isSetCex();
6628
      }
6629
      throw new IllegalStateException();
6630
    }
6631
 
6632
    @Override
6633
    public boolean equals(Object that) {
6634
      if (that == null)
6635
        return false;
6636
      if (that instanceof addInventory_result)
6637
        return this.equals((addInventory_result)that);
6638
      return false;
6639
    }
6640
 
6641
    public boolean equals(addInventory_result that) {
6642
      if (that == null)
6643
        return false;
6644
 
6645
      boolean this_present_cex = true && this.isSetCex();
6646
      boolean that_present_cex = true && that.isSetCex();
6647
      if (this_present_cex || that_present_cex) {
6648
        if (!(this_present_cex && that_present_cex))
6649
          return false;
6650
        if (!this.cex.equals(that.cex))
6651
          return false;
6652
      }
6653
 
6654
      return true;
6655
    }
6656
 
6657
    @Override
6658
    public int hashCode() {
6659
      return 0;
6660
    }
6661
 
6662
    public int compareTo(addInventory_result other) {
6663
      if (!getClass().equals(other.getClass())) {
6664
        return getClass().getName().compareTo(other.getClass().getName());
6665
      }
6666
 
6667
      int lastComparison = 0;
6668
      addInventory_result typedOther = (addInventory_result)other;
6669
 
6670
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
6671
      if (lastComparison != 0) {
6672
        return lastComparison;
6673
      }
6674
      if (isSetCex()) {
6675
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
6676
        if (lastComparison != 0) {
6677
          return lastComparison;
6678
        }
6679
      }
6680
      return 0;
6681
    }
6682
 
6683
    public _Fields fieldForId(int fieldId) {
6684
      return _Fields.findByThriftId(fieldId);
6685
    }
6686
 
6687
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6688
      org.apache.thrift.protocol.TField field;
6689
      iprot.readStructBegin();
6690
      while (true)
6691
      {
6692
        field = iprot.readFieldBegin();
6693
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6694
          break;
6695
        }
6696
        switch (field.id) {
6697
          case 1: // CEX
6698
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6699
              this.cex = new InventoryServiceException();
6700
              this.cex.read(iprot);
6701
            } else { 
6702
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6703
            }
6704
            break;
6705
          default:
6706
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6707
        }
6708
        iprot.readFieldEnd();
6709
      }
6710
      iprot.readStructEnd();
6711
      validate();
6712
    }
6713
 
6714
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6715
      oprot.writeStructBegin(STRUCT_DESC);
6716
 
6717
      if (this.isSetCex()) {
6718
        oprot.writeFieldBegin(CEX_FIELD_DESC);
6719
        this.cex.write(oprot);
6720
        oprot.writeFieldEnd();
6721
      }
6722
      oprot.writeFieldStop();
6723
      oprot.writeStructEnd();
6724
    }
6725
 
6726
    @Override
6727
    public String toString() {
6728
      StringBuilder sb = new StringBuilder("addInventory_result(");
6729
      boolean first = true;
6730
 
6731
      sb.append("cex:");
6732
      if (this.cex == null) {
6733
        sb.append("null");
6734
      } else {
6735
        sb.append(this.cex);
6736
      }
6737
      first = false;
6738
      sb.append(")");
6739
      return sb.toString();
6740
    }
6741
 
6742
    public void validate() throws org.apache.thrift.TException {
6743
      // check for required fields
6744
    }
6745
 
6746
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6747
      try {
6748
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6749
      } catch (org.apache.thrift.TException te) {
6750
        throw new java.io.IOException(te);
6751
      }
6752
    }
6753
 
6754
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6755
      try {
6756
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6757
      } catch (org.apache.thrift.TException te) {
6758
        throw new java.io.IOException(te);
6759
      }
6760
    }
6761
 
6762
  }
6763
 
6764
  public static class retireWarehouse_args implements org.apache.thrift.TBase<retireWarehouse_args, retireWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
6765
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("retireWarehouse_args");
6766
 
6767
    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);
6768
 
6769
    private long warehouse_id; // required
6770
 
6771
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6772
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6773
      WAREHOUSE_ID((short)1, "warehouse_id");
6774
 
6775
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6776
 
6777
      static {
6778
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6779
          byName.put(field.getFieldName(), field);
6780
        }
6781
      }
6782
 
6783
      /**
6784
       * Find the _Fields constant that matches fieldId, or null if its not found.
6785
       */
6786
      public static _Fields findByThriftId(int fieldId) {
6787
        switch(fieldId) {
6788
          case 1: // WAREHOUSE_ID
6789
            return WAREHOUSE_ID;
6790
          default:
6791
            return null;
6792
        }
6793
      }
6794
 
6795
      /**
6796
       * Find the _Fields constant that matches fieldId, throwing an exception
6797
       * if it is not found.
6798
       */
6799
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6800
        _Fields fields = findByThriftId(fieldId);
6801
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6802
        return fields;
6803
      }
6804
 
6805
      /**
6806
       * Find the _Fields constant that matches name, or null if its not found.
6807
       */
6808
      public static _Fields findByName(String name) {
6809
        return byName.get(name);
6810
      }
6811
 
6812
      private final short _thriftId;
6813
      private final String _fieldName;
6814
 
6815
      _Fields(short thriftId, String fieldName) {
6816
        _thriftId = thriftId;
6817
        _fieldName = fieldName;
6818
      }
6819
 
6820
      public short getThriftFieldId() {
6821
        return _thriftId;
6822
      }
6823
 
6824
      public String getFieldName() {
6825
        return _fieldName;
6826
      }
6827
    }
6828
 
6829
    // isset id assignments
6830
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
6831
    private BitSet __isset_bit_vector = new BitSet(1);
6832
 
6833
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6834
    static {
6835
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6836
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6837
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6838
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6839
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(retireWarehouse_args.class, metaDataMap);
6840
    }
6841
 
6842
    public retireWarehouse_args() {
6843
    }
6844
 
6845
    public retireWarehouse_args(
6846
      long warehouse_id)
6847
    {
6848
      this();
6849
      this.warehouse_id = warehouse_id;
6850
      setWarehouse_idIsSet(true);
6851
    }
6852
 
6853
    /**
6854
     * Performs a deep copy on <i>other</i>.
6855
     */
6856
    public retireWarehouse_args(retireWarehouse_args other) {
6857
      __isset_bit_vector.clear();
6858
      __isset_bit_vector.or(other.__isset_bit_vector);
6859
      this.warehouse_id = other.warehouse_id;
6860
    }
6861
 
6862
    public retireWarehouse_args deepCopy() {
6863
      return new retireWarehouse_args(this);
6864
    }
6865
 
6866
    @Override
6867
    public void clear() {
6868
      setWarehouse_idIsSet(false);
6869
      this.warehouse_id = 0;
6870
    }
6871
 
6872
    public long getWarehouse_id() {
6873
      return this.warehouse_id;
6874
    }
6875
 
6876
    public void setWarehouse_id(long warehouse_id) {
6877
      this.warehouse_id = warehouse_id;
6878
      setWarehouse_idIsSet(true);
6879
    }
6880
 
6881
    public void unsetWarehouse_id() {
6882
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
6883
    }
6884
 
6885
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
6886
    public boolean isSetWarehouse_id() {
6887
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
6888
    }
6889
 
6890
    public void setWarehouse_idIsSet(boolean value) {
6891
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
6892
    }
6893
 
6894
    public void setFieldValue(_Fields field, Object value) {
6895
      switch (field) {
6896
      case WAREHOUSE_ID:
6897
        if (value == null) {
6898
          unsetWarehouse_id();
6899
        } else {
6900
          setWarehouse_id((Long)value);
6901
        }
6902
        break;
6903
 
6904
      }
6905
    }
6906
 
6907
    public Object getFieldValue(_Fields field) {
6908
      switch (field) {
6909
      case WAREHOUSE_ID:
6910
        return Long.valueOf(getWarehouse_id());
6911
 
6912
      }
6913
      throw new IllegalStateException();
6914
    }
6915
 
6916
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6917
    public boolean isSet(_Fields field) {
6918
      if (field == null) {
6919
        throw new IllegalArgumentException();
6920
      }
6921
 
6922
      switch (field) {
6923
      case WAREHOUSE_ID:
6924
        return isSetWarehouse_id();
6925
      }
6926
      throw new IllegalStateException();
6927
    }
6928
 
6929
    @Override
6930
    public boolean equals(Object that) {
6931
      if (that == null)
6932
        return false;
6933
      if (that instanceof retireWarehouse_args)
6934
        return this.equals((retireWarehouse_args)that);
6935
      return false;
6936
    }
6937
 
6938
    public boolean equals(retireWarehouse_args that) {
6939
      if (that == null)
6940
        return false;
6941
 
6942
      boolean this_present_warehouse_id = true;
6943
      boolean that_present_warehouse_id = true;
6944
      if (this_present_warehouse_id || that_present_warehouse_id) {
6945
        if (!(this_present_warehouse_id && that_present_warehouse_id))
6946
          return false;
6947
        if (this.warehouse_id != that.warehouse_id)
6948
          return false;
6949
      }
6950
 
6951
      return true;
6952
    }
6953
 
6954
    @Override
6955
    public int hashCode() {
6956
      return 0;
6957
    }
6958
 
6959
    public int compareTo(retireWarehouse_args other) {
6960
      if (!getClass().equals(other.getClass())) {
6961
        return getClass().getName().compareTo(other.getClass().getName());
6962
      }
6963
 
6964
      int lastComparison = 0;
6965
      retireWarehouse_args typedOther = (retireWarehouse_args)other;
6966
 
6967
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
6968
      if (lastComparison != 0) {
6969
        return lastComparison;
6970
      }
6971
      if (isSetWarehouse_id()) {
6972
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
6973
        if (lastComparison != 0) {
6974
          return lastComparison;
6975
        }
6976
      }
6977
      return 0;
6978
    }
6979
 
6980
    public _Fields fieldForId(int fieldId) {
6981
      return _Fields.findByThriftId(fieldId);
6982
    }
6983
 
6984
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6985
      org.apache.thrift.protocol.TField field;
6986
      iprot.readStructBegin();
6987
      while (true)
6988
      {
6989
        field = iprot.readFieldBegin();
6990
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6991
          break;
6992
        }
6993
        switch (field.id) {
6994
          case 1: // WAREHOUSE_ID
6995
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6996
              this.warehouse_id = iprot.readI64();
6997
              setWarehouse_idIsSet(true);
6998
            } else { 
6999
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7000
            }
7001
            break;
7002
          default:
7003
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7004
        }
7005
        iprot.readFieldEnd();
7006
      }
7007
      iprot.readStructEnd();
7008
      validate();
7009
    }
7010
 
7011
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7012
      validate();
7013
 
7014
      oprot.writeStructBegin(STRUCT_DESC);
7015
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
7016
      oprot.writeI64(this.warehouse_id);
7017
      oprot.writeFieldEnd();
7018
      oprot.writeFieldStop();
7019
      oprot.writeStructEnd();
7020
    }
7021
 
7022
    @Override
7023
    public String toString() {
7024
      StringBuilder sb = new StringBuilder("retireWarehouse_args(");
7025
      boolean first = true;
7026
 
7027
      sb.append("warehouse_id:");
7028
      sb.append(this.warehouse_id);
7029
      first = false;
7030
      sb.append(")");
7031
      return sb.toString();
7032
    }
7033
 
7034
    public void validate() throws org.apache.thrift.TException {
7035
      // check for required fields
7036
    }
7037
 
7038
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7039
      try {
7040
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7041
      } catch (org.apache.thrift.TException te) {
7042
        throw new java.io.IOException(te);
7043
      }
7044
    }
7045
 
7046
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7047
      try {
7048
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7049
        __isset_bit_vector = new BitSet(1);
7050
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7051
      } catch (org.apache.thrift.TException te) {
7052
        throw new java.io.IOException(te);
7053
      }
7054
    }
7055
 
7056
  }
7057
 
7058
  public static class retireWarehouse_result implements org.apache.thrift.TBase<retireWarehouse_result, retireWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
7059
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("retireWarehouse_result");
7060
 
7061
    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);
7062
 
7063
    private InventoryServiceException cex; // required
7064
 
7065
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7066
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7067
      CEX((short)1, "cex");
7068
 
7069
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7070
 
7071
      static {
7072
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7073
          byName.put(field.getFieldName(), field);
7074
        }
7075
      }
7076
 
7077
      /**
7078
       * Find the _Fields constant that matches fieldId, or null if its not found.
7079
       */
7080
      public static _Fields findByThriftId(int fieldId) {
7081
        switch(fieldId) {
7082
          case 1: // CEX
7083
            return CEX;
7084
          default:
7085
            return null;
7086
        }
7087
      }
7088
 
7089
      /**
7090
       * Find the _Fields constant that matches fieldId, throwing an exception
7091
       * if it is not found.
7092
       */
7093
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7094
        _Fields fields = findByThriftId(fieldId);
7095
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7096
        return fields;
7097
      }
7098
 
7099
      /**
7100
       * Find the _Fields constant that matches name, or null if its not found.
7101
       */
7102
      public static _Fields findByName(String name) {
7103
        return byName.get(name);
7104
      }
7105
 
7106
      private final short _thriftId;
7107
      private final String _fieldName;
7108
 
7109
      _Fields(short thriftId, String fieldName) {
7110
        _thriftId = thriftId;
7111
        _fieldName = fieldName;
7112
      }
7113
 
7114
      public short getThriftFieldId() {
7115
        return _thriftId;
7116
      }
7117
 
7118
      public String getFieldName() {
7119
        return _fieldName;
7120
      }
7121
    }
7122
 
7123
    // isset id assignments
7124
 
7125
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7126
    static {
7127
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7128
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7129
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7130
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7131
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(retireWarehouse_result.class, metaDataMap);
7132
    }
7133
 
7134
    public retireWarehouse_result() {
7135
    }
7136
 
7137
    public retireWarehouse_result(
7138
      InventoryServiceException cex)
7139
    {
7140
      this();
7141
      this.cex = cex;
7142
    }
7143
 
7144
    /**
7145
     * Performs a deep copy on <i>other</i>.
7146
     */
7147
    public retireWarehouse_result(retireWarehouse_result other) {
7148
      if (other.isSetCex()) {
7149
        this.cex = new InventoryServiceException(other.cex);
7150
      }
7151
    }
7152
 
7153
    public retireWarehouse_result deepCopy() {
7154
      return new retireWarehouse_result(this);
7155
    }
7156
 
7157
    @Override
7158
    public void clear() {
7159
      this.cex = null;
7160
    }
7161
 
7162
    public InventoryServiceException getCex() {
7163
      return this.cex;
7164
    }
7165
 
7166
    public void setCex(InventoryServiceException cex) {
7167
      this.cex = cex;
7168
    }
7169
 
7170
    public void unsetCex() {
7171
      this.cex = null;
7172
    }
7173
 
7174
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
7175
    public boolean isSetCex() {
7176
      return this.cex != null;
7177
    }
7178
 
7179
    public void setCexIsSet(boolean value) {
7180
      if (!value) {
7181
        this.cex = null;
7182
      }
7183
    }
7184
 
7185
    public void setFieldValue(_Fields field, Object value) {
7186
      switch (field) {
7187
      case CEX:
7188
        if (value == null) {
7189
          unsetCex();
7190
        } else {
7191
          setCex((InventoryServiceException)value);
7192
        }
7193
        break;
7194
 
7195
      }
7196
    }
7197
 
7198
    public Object getFieldValue(_Fields field) {
7199
      switch (field) {
7200
      case CEX:
7201
        return getCex();
7202
 
7203
      }
7204
      throw new IllegalStateException();
7205
    }
7206
 
7207
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7208
    public boolean isSet(_Fields field) {
7209
      if (field == null) {
7210
        throw new IllegalArgumentException();
7211
      }
7212
 
7213
      switch (field) {
7214
      case CEX:
7215
        return isSetCex();
7216
      }
7217
      throw new IllegalStateException();
7218
    }
7219
 
7220
    @Override
7221
    public boolean equals(Object that) {
7222
      if (that == null)
7223
        return false;
7224
      if (that instanceof retireWarehouse_result)
7225
        return this.equals((retireWarehouse_result)that);
7226
      return false;
7227
    }
7228
 
7229
    public boolean equals(retireWarehouse_result that) {
7230
      if (that == null)
7231
        return false;
7232
 
7233
      boolean this_present_cex = true && this.isSetCex();
7234
      boolean that_present_cex = true && that.isSetCex();
7235
      if (this_present_cex || that_present_cex) {
7236
        if (!(this_present_cex && that_present_cex))
7237
          return false;
7238
        if (!this.cex.equals(that.cex))
7239
          return false;
7240
      }
7241
 
7242
      return true;
7243
    }
7244
 
7245
    @Override
7246
    public int hashCode() {
7247
      return 0;
7248
    }
7249
 
7250
    public int compareTo(retireWarehouse_result other) {
7251
      if (!getClass().equals(other.getClass())) {
7252
        return getClass().getName().compareTo(other.getClass().getName());
7253
      }
7254
 
7255
      int lastComparison = 0;
7256
      retireWarehouse_result typedOther = (retireWarehouse_result)other;
7257
 
7258
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
7259
      if (lastComparison != 0) {
7260
        return lastComparison;
7261
      }
7262
      if (isSetCex()) {
7263
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
7264
        if (lastComparison != 0) {
7265
          return lastComparison;
7266
        }
7267
      }
7268
      return 0;
7269
    }
7270
 
7271
    public _Fields fieldForId(int fieldId) {
7272
      return _Fields.findByThriftId(fieldId);
7273
    }
7274
 
7275
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7276
      org.apache.thrift.protocol.TField field;
7277
      iprot.readStructBegin();
7278
      while (true)
7279
      {
7280
        field = iprot.readFieldBegin();
7281
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7282
          break;
7283
        }
7284
        switch (field.id) {
7285
          case 1: // CEX
7286
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7287
              this.cex = new InventoryServiceException();
7288
              this.cex.read(iprot);
7289
            } else { 
7290
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7291
            }
7292
            break;
7293
          default:
7294
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7295
        }
7296
        iprot.readFieldEnd();
7297
      }
7298
      iprot.readStructEnd();
7299
      validate();
7300
    }
7301
 
7302
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7303
      oprot.writeStructBegin(STRUCT_DESC);
7304
 
7305
      if (this.isSetCex()) {
7306
        oprot.writeFieldBegin(CEX_FIELD_DESC);
7307
        this.cex.write(oprot);
7308
        oprot.writeFieldEnd();
7309
      }
7310
      oprot.writeFieldStop();
7311
      oprot.writeStructEnd();
7312
    }
7313
 
7314
    @Override
7315
    public String toString() {
7316
      StringBuilder sb = new StringBuilder("retireWarehouse_result(");
7317
      boolean first = true;
7318
 
7319
      sb.append("cex:");
7320
      if (this.cex == null) {
7321
        sb.append("null");
7322
      } else {
7323
        sb.append(this.cex);
7324
      }
7325
      first = false;
7326
      sb.append(")");
7327
      return sb.toString();
7328
    }
7329
 
7330
    public void validate() throws org.apache.thrift.TException {
7331
      // check for required fields
7332
    }
7333
 
7334
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7335
      try {
7336
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7337
      } catch (org.apache.thrift.TException te) {
7338
        throw new java.io.IOException(te);
7339
      }
7340
    }
7341
 
7342
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7343
      try {
7344
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7345
      } catch (org.apache.thrift.TException te) {
7346
        throw new java.io.IOException(te);
7347
      }
7348
    }
7349
 
7350
  }
7351
 
7352
  public static class getItemInventoryByItemId_args implements org.apache.thrift.TBase<getItemInventoryByItemId_args, getItemInventoryByItemId_args._Fields>, java.io.Serializable, Cloneable   {
7353
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemInventoryByItemId_args");
7354
 
7355
    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);
7356
 
7357
    private long item_id; // required
7358
 
7359
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7360
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7361
      ITEM_ID((short)1, "item_id");
7362
 
7363
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7364
 
7365
      static {
7366
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7367
          byName.put(field.getFieldName(), field);
7368
        }
7369
      }
7370
 
7371
      /**
7372
       * Find the _Fields constant that matches fieldId, or null if its not found.
7373
       */
7374
      public static _Fields findByThriftId(int fieldId) {
7375
        switch(fieldId) {
7376
          case 1: // ITEM_ID
7377
            return ITEM_ID;
7378
          default:
7379
            return null;
7380
        }
7381
      }
7382
 
7383
      /**
7384
       * Find the _Fields constant that matches fieldId, throwing an exception
7385
       * if it is not found.
7386
       */
7387
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7388
        _Fields fields = findByThriftId(fieldId);
7389
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7390
        return fields;
7391
      }
7392
 
7393
      /**
7394
       * Find the _Fields constant that matches name, or null if its not found.
7395
       */
7396
      public static _Fields findByName(String name) {
7397
        return byName.get(name);
7398
      }
7399
 
7400
      private final short _thriftId;
7401
      private final String _fieldName;
7402
 
7403
      _Fields(short thriftId, String fieldName) {
7404
        _thriftId = thriftId;
7405
        _fieldName = fieldName;
7406
      }
7407
 
7408
      public short getThriftFieldId() {
7409
        return _thriftId;
7410
      }
7411
 
7412
      public String getFieldName() {
7413
        return _fieldName;
7414
      }
7415
    }
7416
 
7417
    // isset id assignments
7418
    private static final int __ITEM_ID_ISSET_ID = 0;
7419
    private BitSet __isset_bit_vector = new BitSet(1);
7420
 
7421
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7422
    static {
7423
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7424
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7425
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7426
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7427
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemInventoryByItemId_args.class, metaDataMap);
7428
    }
7429
 
7430
    public getItemInventoryByItemId_args() {
7431
    }
7432
 
7433
    public getItemInventoryByItemId_args(
7434
      long item_id)
7435
    {
7436
      this();
7437
      this.item_id = item_id;
7438
      setItem_idIsSet(true);
7439
    }
7440
 
7441
    /**
7442
     * Performs a deep copy on <i>other</i>.
7443
     */
7444
    public getItemInventoryByItemId_args(getItemInventoryByItemId_args other) {
7445
      __isset_bit_vector.clear();
7446
      __isset_bit_vector.or(other.__isset_bit_vector);
7447
      this.item_id = other.item_id;
7448
    }
7449
 
7450
    public getItemInventoryByItemId_args deepCopy() {
7451
      return new getItemInventoryByItemId_args(this);
7452
    }
7453
 
7454
    @Override
7455
    public void clear() {
7456
      setItem_idIsSet(false);
7457
      this.item_id = 0;
7458
    }
7459
 
7460
    public long getItem_id() {
7461
      return this.item_id;
7462
    }
7463
 
7464
    public void setItem_id(long item_id) {
7465
      this.item_id = item_id;
7466
      setItem_idIsSet(true);
7467
    }
7468
 
7469
    public void unsetItem_id() {
7470
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
7471
    }
7472
 
7473
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
7474
    public boolean isSetItem_id() {
7475
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
7476
    }
7477
 
7478
    public void setItem_idIsSet(boolean value) {
7479
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
7480
    }
7481
 
7482
    public void setFieldValue(_Fields field, Object value) {
7483
      switch (field) {
7484
      case ITEM_ID:
7485
        if (value == null) {
7486
          unsetItem_id();
7487
        } else {
7488
          setItem_id((Long)value);
7489
        }
7490
        break;
7491
 
7492
      }
7493
    }
7494
 
7495
    public Object getFieldValue(_Fields field) {
7496
      switch (field) {
7497
      case ITEM_ID:
7498
        return Long.valueOf(getItem_id());
7499
 
7500
      }
7501
      throw new IllegalStateException();
7502
    }
7503
 
7504
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7505
    public boolean isSet(_Fields field) {
7506
      if (field == null) {
7507
        throw new IllegalArgumentException();
7508
      }
7509
 
7510
      switch (field) {
7511
      case ITEM_ID:
7512
        return isSetItem_id();
7513
      }
7514
      throw new IllegalStateException();
7515
    }
7516
 
7517
    @Override
7518
    public boolean equals(Object that) {
7519
      if (that == null)
7520
        return false;
7521
      if (that instanceof getItemInventoryByItemId_args)
7522
        return this.equals((getItemInventoryByItemId_args)that);
7523
      return false;
7524
    }
7525
 
7526
    public boolean equals(getItemInventoryByItemId_args that) {
7527
      if (that == null)
7528
        return false;
7529
 
7530
      boolean this_present_item_id = true;
7531
      boolean that_present_item_id = true;
7532
      if (this_present_item_id || that_present_item_id) {
7533
        if (!(this_present_item_id && that_present_item_id))
7534
          return false;
7535
        if (this.item_id != that.item_id)
7536
          return false;
7537
      }
7538
 
7539
      return true;
7540
    }
7541
 
7542
    @Override
7543
    public int hashCode() {
7544
      return 0;
7545
    }
7546
 
7547
    public int compareTo(getItemInventoryByItemId_args other) {
7548
      if (!getClass().equals(other.getClass())) {
7549
        return getClass().getName().compareTo(other.getClass().getName());
7550
      }
7551
 
7552
      int lastComparison = 0;
7553
      getItemInventoryByItemId_args typedOther = (getItemInventoryByItemId_args)other;
7554
 
7555
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
7556
      if (lastComparison != 0) {
7557
        return lastComparison;
7558
      }
7559
      if (isSetItem_id()) {
7560
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
7561
        if (lastComparison != 0) {
7562
          return lastComparison;
7563
        }
7564
      }
7565
      return 0;
7566
    }
7567
 
7568
    public _Fields fieldForId(int fieldId) {
7569
      return _Fields.findByThriftId(fieldId);
7570
    }
7571
 
7572
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7573
      org.apache.thrift.protocol.TField field;
7574
      iprot.readStructBegin();
7575
      while (true)
7576
      {
7577
        field = iprot.readFieldBegin();
7578
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7579
          break;
7580
        }
7581
        switch (field.id) {
7582
          case 1: // ITEM_ID
7583
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7584
              this.item_id = iprot.readI64();
7585
              setItem_idIsSet(true);
7586
            } else { 
7587
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7588
            }
7589
            break;
7590
          default:
7591
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7592
        }
7593
        iprot.readFieldEnd();
7594
      }
7595
      iprot.readStructEnd();
7596
      validate();
7597
    }
7598
 
7599
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7600
      validate();
7601
 
7602
      oprot.writeStructBegin(STRUCT_DESC);
7603
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
7604
      oprot.writeI64(this.item_id);
7605
      oprot.writeFieldEnd();
7606
      oprot.writeFieldStop();
7607
      oprot.writeStructEnd();
7608
    }
7609
 
7610
    @Override
7611
    public String toString() {
7612
      StringBuilder sb = new StringBuilder("getItemInventoryByItemId_args(");
7613
      boolean first = true;
7614
 
7615
      sb.append("item_id:");
7616
      sb.append(this.item_id);
7617
      first = false;
7618
      sb.append(")");
7619
      return sb.toString();
7620
    }
7621
 
7622
    public void validate() throws org.apache.thrift.TException {
7623
      // check for required fields
7624
    }
7625
 
7626
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7627
      try {
7628
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7629
      } catch (org.apache.thrift.TException te) {
7630
        throw new java.io.IOException(te);
7631
      }
7632
    }
7633
 
7634
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7635
      try {
7636
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7637
        __isset_bit_vector = new BitSet(1);
7638
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7639
      } catch (org.apache.thrift.TException te) {
7640
        throw new java.io.IOException(te);
7641
      }
7642
    }
7643
 
7644
  }
7645
 
7646
  public static class getItemInventoryByItemId_result implements org.apache.thrift.TBase<getItemInventoryByItemId_result, getItemInventoryByItemId_result._Fields>, java.io.Serializable, Cloneable   {
7647
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemInventoryByItemId_result");
7648
 
7649
    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);
7650
    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);
7651
 
7652
    private ItemInventory success; // required
7653
    private InventoryServiceException cex; // required
7654
 
7655
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7656
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7657
      SUCCESS((short)0, "success"),
7658
      CEX((short)1, "cex");
7659
 
7660
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7661
 
7662
      static {
7663
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7664
          byName.put(field.getFieldName(), field);
7665
        }
7666
      }
7667
 
7668
      /**
7669
       * Find the _Fields constant that matches fieldId, or null if its not found.
7670
       */
7671
      public static _Fields findByThriftId(int fieldId) {
7672
        switch(fieldId) {
7673
          case 0: // SUCCESS
7674
            return SUCCESS;
7675
          case 1: // CEX
7676
            return CEX;
7677
          default:
7678
            return null;
7679
        }
7680
      }
7681
 
7682
      /**
7683
       * Find the _Fields constant that matches fieldId, throwing an exception
7684
       * if it is not found.
7685
       */
7686
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7687
        _Fields fields = findByThriftId(fieldId);
7688
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7689
        return fields;
7690
      }
7691
 
7692
      /**
7693
       * Find the _Fields constant that matches name, or null if its not found.
7694
       */
7695
      public static _Fields findByName(String name) {
7696
        return byName.get(name);
7697
      }
7698
 
7699
      private final short _thriftId;
7700
      private final String _fieldName;
7701
 
7702
      _Fields(short thriftId, String fieldName) {
7703
        _thriftId = thriftId;
7704
        _fieldName = fieldName;
7705
      }
7706
 
7707
      public short getThriftFieldId() {
7708
        return _thriftId;
7709
      }
7710
 
7711
      public String getFieldName() {
7712
        return _fieldName;
7713
      }
7714
    }
7715
 
7716
    // isset id assignments
7717
 
7718
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7719
    static {
7720
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7721
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7722
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ItemInventory.class)));
7723
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7724
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7725
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7726
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemInventoryByItemId_result.class, metaDataMap);
7727
    }
7728
 
7729
    public getItemInventoryByItemId_result() {
7730
    }
7731
 
7732
    public getItemInventoryByItemId_result(
7733
      ItemInventory success,
7734
      InventoryServiceException cex)
7735
    {
7736
      this();
7737
      this.success = success;
7738
      this.cex = cex;
7739
    }
7740
 
7741
    /**
7742
     * Performs a deep copy on <i>other</i>.
7743
     */
7744
    public getItemInventoryByItemId_result(getItemInventoryByItemId_result other) {
7745
      if (other.isSetSuccess()) {
7746
        this.success = new ItemInventory(other.success);
7747
      }
7748
      if (other.isSetCex()) {
7749
        this.cex = new InventoryServiceException(other.cex);
7750
      }
7751
    }
7752
 
7753
    public getItemInventoryByItemId_result deepCopy() {
7754
      return new getItemInventoryByItemId_result(this);
7755
    }
7756
 
7757
    @Override
7758
    public void clear() {
7759
      this.success = null;
7760
      this.cex = null;
7761
    }
7762
 
7763
    public ItemInventory getSuccess() {
7764
      return this.success;
7765
    }
7766
 
7767
    public void setSuccess(ItemInventory success) {
7768
      this.success = success;
7769
    }
7770
 
7771
    public void unsetSuccess() {
7772
      this.success = null;
7773
    }
7774
 
7775
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
7776
    public boolean isSetSuccess() {
7777
      return this.success != null;
7778
    }
7779
 
7780
    public void setSuccessIsSet(boolean value) {
7781
      if (!value) {
7782
        this.success = null;
7783
      }
7784
    }
7785
 
7786
    public InventoryServiceException getCex() {
7787
      return this.cex;
7788
    }
7789
 
7790
    public void setCex(InventoryServiceException cex) {
7791
      this.cex = cex;
7792
    }
7793
 
7794
    public void unsetCex() {
7795
      this.cex = null;
7796
    }
7797
 
7798
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
7799
    public boolean isSetCex() {
7800
      return this.cex != null;
7801
    }
7802
 
7803
    public void setCexIsSet(boolean value) {
7804
      if (!value) {
7805
        this.cex = null;
7806
      }
7807
    }
7808
 
7809
    public void setFieldValue(_Fields field, Object value) {
7810
      switch (field) {
7811
      case SUCCESS:
7812
        if (value == null) {
7813
          unsetSuccess();
7814
        } else {
7815
          setSuccess((ItemInventory)value);
7816
        }
7817
        break;
7818
 
7819
      case CEX:
7820
        if (value == null) {
7821
          unsetCex();
7822
        } else {
7823
          setCex((InventoryServiceException)value);
7824
        }
7825
        break;
7826
 
7827
      }
7828
    }
7829
 
7830
    public Object getFieldValue(_Fields field) {
7831
      switch (field) {
7832
      case SUCCESS:
7833
        return getSuccess();
7834
 
7835
      case CEX:
7836
        return getCex();
7837
 
7838
      }
7839
      throw new IllegalStateException();
7840
    }
7841
 
7842
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7843
    public boolean isSet(_Fields field) {
7844
      if (field == null) {
7845
        throw new IllegalArgumentException();
7846
      }
7847
 
7848
      switch (field) {
7849
      case SUCCESS:
7850
        return isSetSuccess();
7851
      case CEX:
7852
        return isSetCex();
7853
      }
7854
      throw new IllegalStateException();
7855
    }
7856
 
7857
    @Override
7858
    public boolean equals(Object that) {
7859
      if (that == null)
7860
        return false;
7861
      if (that instanceof getItemInventoryByItemId_result)
7862
        return this.equals((getItemInventoryByItemId_result)that);
7863
      return false;
7864
    }
7865
 
7866
    public boolean equals(getItemInventoryByItemId_result that) {
7867
      if (that == null)
7868
        return false;
7869
 
7870
      boolean this_present_success = true && this.isSetSuccess();
7871
      boolean that_present_success = true && that.isSetSuccess();
7872
      if (this_present_success || that_present_success) {
7873
        if (!(this_present_success && that_present_success))
7874
          return false;
7875
        if (!this.success.equals(that.success))
7876
          return false;
7877
      }
7878
 
7879
      boolean this_present_cex = true && this.isSetCex();
7880
      boolean that_present_cex = true && that.isSetCex();
7881
      if (this_present_cex || that_present_cex) {
7882
        if (!(this_present_cex && that_present_cex))
7883
          return false;
7884
        if (!this.cex.equals(that.cex))
7885
          return false;
7886
      }
7887
 
7888
      return true;
7889
    }
7890
 
7891
    @Override
7892
    public int hashCode() {
7893
      return 0;
7894
    }
7895
 
7896
    public int compareTo(getItemInventoryByItemId_result other) {
7897
      if (!getClass().equals(other.getClass())) {
7898
        return getClass().getName().compareTo(other.getClass().getName());
7899
      }
7900
 
7901
      int lastComparison = 0;
7902
      getItemInventoryByItemId_result typedOther = (getItemInventoryByItemId_result)other;
7903
 
7904
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
7905
      if (lastComparison != 0) {
7906
        return lastComparison;
7907
      }
7908
      if (isSetSuccess()) {
7909
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
7910
        if (lastComparison != 0) {
7911
          return lastComparison;
7912
        }
7913
      }
7914
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
7915
      if (lastComparison != 0) {
7916
        return lastComparison;
7917
      }
7918
      if (isSetCex()) {
7919
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
7920
        if (lastComparison != 0) {
7921
          return lastComparison;
7922
        }
7923
      }
7924
      return 0;
7925
    }
7926
 
7927
    public _Fields fieldForId(int fieldId) {
7928
      return _Fields.findByThriftId(fieldId);
7929
    }
7930
 
7931
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7932
      org.apache.thrift.protocol.TField field;
7933
      iprot.readStructBegin();
7934
      while (true)
7935
      {
7936
        field = iprot.readFieldBegin();
7937
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7938
          break;
7939
        }
7940
        switch (field.id) {
7941
          case 0: // SUCCESS
7942
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7943
              this.success = new ItemInventory();
7944
              this.success.read(iprot);
7945
            } else { 
7946
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7947
            }
7948
            break;
7949
          case 1: // CEX
7950
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7951
              this.cex = new InventoryServiceException();
7952
              this.cex.read(iprot);
7953
            } else { 
7954
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7955
            }
7956
            break;
7957
          default:
7958
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7959
        }
7960
        iprot.readFieldEnd();
7961
      }
7962
      iprot.readStructEnd();
7963
      validate();
7964
    }
7965
 
7966
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7967
      oprot.writeStructBegin(STRUCT_DESC);
7968
 
7969
      if (this.isSetSuccess()) {
7970
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
7971
        this.success.write(oprot);
7972
        oprot.writeFieldEnd();
7973
      } else if (this.isSetCex()) {
7974
        oprot.writeFieldBegin(CEX_FIELD_DESC);
7975
        this.cex.write(oprot);
7976
        oprot.writeFieldEnd();
7977
      }
7978
      oprot.writeFieldStop();
7979
      oprot.writeStructEnd();
7980
    }
7981
 
7982
    @Override
7983
    public String toString() {
7984
      StringBuilder sb = new StringBuilder("getItemInventoryByItemId_result(");
7985
      boolean first = true;
7986
 
7987
      sb.append("success:");
7988
      if (this.success == null) {
7989
        sb.append("null");
7990
      } else {
7991
        sb.append(this.success);
7992
      }
7993
      first = false;
7994
      if (!first) sb.append(", ");
7995
      sb.append("cex:");
7996
      if (this.cex == null) {
7997
        sb.append("null");
7998
      } else {
7999
        sb.append(this.cex);
8000
      }
8001
      first = false;
8002
      sb.append(")");
8003
      return sb.toString();
8004
    }
8005
 
8006
    public void validate() throws org.apache.thrift.TException {
8007
      // check for required fields
8008
    }
8009
 
8010
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8011
      try {
8012
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8013
      } catch (org.apache.thrift.TException te) {
8014
        throw new java.io.IOException(te);
8015
      }
8016
    }
8017
 
8018
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8019
      try {
8020
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8021
      } catch (org.apache.thrift.TException te) {
8022
        throw new java.io.IOException(te);
8023
      }
8024
    }
8025
 
8026
  }
8027
 
8028
  public static class getItemAvailibilityAtWarehouse_args implements org.apache.thrift.TBase<getItemAvailibilityAtWarehouse_args, getItemAvailibilityAtWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
8029
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailibilityAtWarehouse_args");
8030
 
8031
    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);
8032
    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);
8033
 
8034
    private long warehouse_id; // required
8035
    private long item_id; // required
8036
 
8037
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8038
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8039
      WAREHOUSE_ID((short)1, "warehouse_id"),
8040
      ITEM_ID((short)2, "item_id");
8041
 
8042
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8043
 
8044
      static {
8045
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8046
          byName.put(field.getFieldName(), field);
8047
        }
8048
      }
8049
 
8050
      /**
8051
       * Find the _Fields constant that matches fieldId, or null if its not found.
8052
       */
8053
      public static _Fields findByThriftId(int fieldId) {
8054
        switch(fieldId) {
8055
          case 1: // WAREHOUSE_ID
8056
            return WAREHOUSE_ID;
8057
          case 2: // ITEM_ID
8058
            return ITEM_ID;
8059
          default:
8060
            return null;
8061
        }
8062
      }
8063
 
8064
      /**
8065
       * Find the _Fields constant that matches fieldId, throwing an exception
8066
       * if it is not found.
8067
       */
8068
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8069
        _Fields fields = findByThriftId(fieldId);
8070
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8071
        return fields;
8072
      }
8073
 
8074
      /**
8075
       * Find the _Fields constant that matches name, or null if its not found.
8076
       */
8077
      public static _Fields findByName(String name) {
8078
        return byName.get(name);
8079
      }
8080
 
8081
      private final short _thriftId;
8082
      private final String _fieldName;
8083
 
8084
      _Fields(short thriftId, String fieldName) {
8085
        _thriftId = thriftId;
8086
        _fieldName = fieldName;
8087
      }
8088
 
8089
      public short getThriftFieldId() {
8090
        return _thriftId;
8091
      }
8092
 
8093
      public String getFieldName() {
8094
        return _fieldName;
8095
      }
8096
    }
8097
 
8098
    // isset id assignments
8099
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
8100
    private static final int __ITEM_ID_ISSET_ID = 1;
8101
    private BitSet __isset_bit_vector = new BitSet(2);
8102
 
8103
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8104
    static {
8105
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8106
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8107
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8108
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8109
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8110
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8111
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailibilityAtWarehouse_args.class, metaDataMap);
8112
    }
8113
 
8114
    public getItemAvailibilityAtWarehouse_args() {
8115
    }
8116
 
8117
    public getItemAvailibilityAtWarehouse_args(
8118
      long warehouse_id,
8119
      long item_id)
8120
    {
8121
      this();
8122
      this.warehouse_id = warehouse_id;
8123
      setWarehouse_idIsSet(true);
8124
      this.item_id = item_id;
8125
      setItem_idIsSet(true);
8126
    }
8127
 
8128
    /**
8129
     * Performs a deep copy on <i>other</i>.
8130
     */
8131
    public getItemAvailibilityAtWarehouse_args(getItemAvailibilityAtWarehouse_args other) {
8132
      __isset_bit_vector.clear();
8133
      __isset_bit_vector.or(other.__isset_bit_vector);
8134
      this.warehouse_id = other.warehouse_id;
8135
      this.item_id = other.item_id;
8136
    }
8137
 
8138
    public getItemAvailibilityAtWarehouse_args deepCopy() {
8139
      return new getItemAvailibilityAtWarehouse_args(this);
8140
    }
8141
 
8142
    @Override
8143
    public void clear() {
8144
      setWarehouse_idIsSet(false);
8145
      this.warehouse_id = 0;
8146
      setItem_idIsSet(false);
8147
      this.item_id = 0;
8148
    }
8149
 
8150
    public long getWarehouse_id() {
8151
      return this.warehouse_id;
8152
    }
8153
 
8154
    public void setWarehouse_id(long warehouse_id) {
8155
      this.warehouse_id = warehouse_id;
8156
      setWarehouse_idIsSet(true);
8157
    }
8158
 
8159
    public void unsetWarehouse_id() {
8160
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
8161
    }
8162
 
8163
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
8164
    public boolean isSetWarehouse_id() {
8165
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
8166
    }
8167
 
8168
    public void setWarehouse_idIsSet(boolean value) {
8169
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
8170
    }
8171
 
8172
    public long getItem_id() {
8173
      return this.item_id;
8174
    }
8175
 
8176
    public void setItem_id(long item_id) {
8177
      this.item_id = item_id;
8178
      setItem_idIsSet(true);
8179
    }
8180
 
8181
    public void unsetItem_id() {
8182
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
8183
    }
8184
 
8185
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
8186
    public boolean isSetItem_id() {
8187
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
8188
    }
8189
 
8190
    public void setItem_idIsSet(boolean value) {
8191
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
8192
    }
8193
 
8194
    public void setFieldValue(_Fields field, Object value) {
8195
      switch (field) {
8196
      case WAREHOUSE_ID:
8197
        if (value == null) {
8198
          unsetWarehouse_id();
8199
        } else {
8200
          setWarehouse_id((Long)value);
8201
        }
8202
        break;
8203
 
8204
      case ITEM_ID:
8205
        if (value == null) {
8206
          unsetItem_id();
8207
        } else {
8208
          setItem_id((Long)value);
8209
        }
8210
        break;
8211
 
8212
      }
8213
    }
8214
 
8215
    public Object getFieldValue(_Fields field) {
8216
      switch (field) {
8217
      case WAREHOUSE_ID:
8218
        return Long.valueOf(getWarehouse_id());
8219
 
8220
      case ITEM_ID:
8221
        return Long.valueOf(getItem_id());
8222
 
8223
      }
8224
      throw new IllegalStateException();
8225
    }
8226
 
8227
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8228
    public boolean isSet(_Fields field) {
8229
      if (field == null) {
8230
        throw new IllegalArgumentException();
8231
      }
8232
 
8233
      switch (field) {
8234
      case WAREHOUSE_ID:
8235
        return isSetWarehouse_id();
8236
      case ITEM_ID:
8237
        return isSetItem_id();
8238
      }
8239
      throw new IllegalStateException();
8240
    }
8241
 
8242
    @Override
8243
    public boolean equals(Object that) {
8244
      if (that == null)
8245
        return false;
8246
      if (that instanceof getItemAvailibilityAtWarehouse_args)
8247
        return this.equals((getItemAvailibilityAtWarehouse_args)that);
8248
      return false;
8249
    }
8250
 
8251
    public boolean equals(getItemAvailibilityAtWarehouse_args that) {
8252
      if (that == null)
8253
        return false;
8254
 
8255
      boolean this_present_warehouse_id = true;
8256
      boolean that_present_warehouse_id = true;
8257
      if (this_present_warehouse_id || that_present_warehouse_id) {
8258
        if (!(this_present_warehouse_id && that_present_warehouse_id))
8259
          return false;
8260
        if (this.warehouse_id != that.warehouse_id)
8261
          return false;
8262
      }
8263
 
8264
      boolean this_present_item_id = true;
8265
      boolean that_present_item_id = true;
8266
      if (this_present_item_id || that_present_item_id) {
8267
        if (!(this_present_item_id && that_present_item_id))
8268
          return false;
8269
        if (this.item_id != that.item_id)
8270
          return false;
8271
      }
8272
 
8273
      return true;
8274
    }
8275
 
8276
    @Override
8277
    public int hashCode() {
8278
      return 0;
8279
    }
8280
 
8281
    public int compareTo(getItemAvailibilityAtWarehouse_args other) {
8282
      if (!getClass().equals(other.getClass())) {
8283
        return getClass().getName().compareTo(other.getClass().getName());
8284
      }
8285
 
8286
      int lastComparison = 0;
8287
      getItemAvailibilityAtWarehouse_args typedOther = (getItemAvailibilityAtWarehouse_args)other;
8288
 
8289
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
8290
      if (lastComparison != 0) {
8291
        return lastComparison;
8292
      }
8293
      if (isSetWarehouse_id()) {
8294
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
8295
        if (lastComparison != 0) {
8296
          return lastComparison;
8297
        }
8298
      }
8299
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
8300
      if (lastComparison != 0) {
8301
        return lastComparison;
8302
      }
8303
      if (isSetItem_id()) {
8304
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
8305
        if (lastComparison != 0) {
8306
          return lastComparison;
8307
        }
8308
      }
8309
      return 0;
8310
    }
8311
 
8312
    public _Fields fieldForId(int fieldId) {
8313
      return _Fields.findByThriftId(fieldId);
8314
    }
8315
 
8316
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8317
      org.apache.thrift.protocol.TField field;
8318
      iprot.readStructBegin();
8319
      while (true)
8320
      {
8321
        field = iprot.readFieldBegin();
8322
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8323
          break;
8324
        }
8325
        switch (field.id) {
8326
          case 1: // WAREHOUSE_ID
8327
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8328
              this.warehouse_id = iprot.readI64();
8329
              setWarehouse_idIsSet(true);
8330
            } else { 
8331
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8332
            }
8333
            break;
8334
          case 2: // ITEM_ID
8335
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8336
              this.item_id = iprot.readI64();
8337
              setItem_idIsSet(true);
8338
            } else { 
8339
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8340
            }
8341
            break;
8342
          default:
8343
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8344
        }
8345
        iprot.readFieldEnd();
8346
      }
8347
      iprot.readStructEnd();
8348
      validate();
8349
    }
8350
 
8351
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8352
      validate();
8353
 
8354
      oprot.writeStructBegin(STRUCT_DESC);
8355
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
8356
      oprot.writeI64(this.warehouse_id);
8357
      oprot.writeFieldEnd();
8358
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
8359
      oprot.writeI64(this.item_id);
8360
      oprot.writeFieldEnd();
8361
      oprot.writeFieldStop();
8362
      oprot.writeStructEnd();
8363
    }
8364
 
8365
    @Override
8366
    public String toString() {
8367
      StringBuilder sb = new StringBuilder("getItemAvailibilityAtWarehouse_args(");
8368
      boolean first = true;
8369
 
8370
      sb.append("warehouse_id:");
8371
      sb.append(this.warehouse_id);
8372
      first = false;
8373
      if (!first) sb.append(", ");
8374
      sb.append("item_id:");
8375
      sb.append(this.item_id);
8376
      first = false;
8377
      sb.append(")");
8378
      return sb.toString();
8379
    }
8380
 
8381
    public void validate() throws org.apache.thrift.TException {
8382
      // check for required fields
8383
    }
8384
 
8385
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8386
      try {
8387
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8388
      } catch (org.apache.thrift.TException te) {
8389
        throw new java.io.IOException(te);
8390
      }
8391
    }
8392
 
8393
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8394
      try {
8395
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
8396
        __isset_bit_vector = new BitSet(1);
8397
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8398
      } catch (org.apache.thrift.TException te) {
8399
        throw new java.io.IOException(te);
8400
      }
8401
    }
8402
 
8403
  }
8404
 
8405
  public static class getItemAvailibilityAtWarehouse_result implements org.apache.thrift.TBase<getItemAvailibilityAtWarehouse_result, getItemAvailibilityAtWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
8406
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailibilityAtWarehouse_result");
8407
 
8408
    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);
8409
    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);
8410
 
8411
    private long success; // required
8412
    private InventoryServiceException cex; // required
8413
 
8414
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8415
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8416
      SUCCESS((short)0, "success"),
8417
      CEX((short)1, "cex");
8418
 
8419
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8420
 
8421
      static {
8422
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8423
          byName.put(field.getFieldName(), field);
8424
        }
8425
      }
8426
 
8427
      /**
8428
       * Find the _Fields constant that matches fieldId, or null if its not found.
8429
       */
8430
      public static _Fields findByThriftId(int fieldId) {
8431
        switch(fieldId) {
8432
          case 0: // SUCCESS
8433
            return SUCCESS;
8434
          case 1: // CEX
8435
            return CEX;
8436
          default:
8437
            return null;
8438
        }
8439
      }
8440
 
8441
      /**
8442
       * Find the _Fields constant that matches fieldId, throwing an exception
8443
       * if it is not found.
8444
       */
8445
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8446
        _Fields fields = findByThriftId(fieldId);
8447
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8448
        return fields;
8449
      }
8450
 
8451
      /**
8452
       * Find the _Fields constant that matches name, or null if its not found.
8453
       */
8454
      public static _Fields findByName(String name) {
8455
        return byName.get(name);
8456
      }
8457
 
8458
      private final short _thriftId;
8459
      private final String _fieldName;
8460
 
8461
      _Fields(short thriftId, String fieldName) {
8462
        _thriftId = thriftId;
8463
        _fieldName = fieldName;
8464
      }
8465
 
8466
      public short getThriftFieldId() {
8467
        return _thriftId;
8468
      }
8469
 
8470
      public String getFieldName() {
8471
        return _fieldName;
8472
      }
8473
    }
8474
 
8475
    // isset id assignments
8476
    private static final int __SUCCESS_ISSET_ID = 0;
8477
    private BitSet __isset_bit_vector = new BitSet(1);
8478
 
8479
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8480
    static {
8481
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8482
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8483
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8484
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8485
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
8486
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8487
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailibilityAtWarehouse_result.class, metaDataMap);
8488
    }
8489
 
8490
    public getItemAvailibilityAtWarehouse_result() {
8491
    }
8492
 
8493
    public getItemAvailibilityAtWarehouse_result(
8494
      long success,
8495
      InventoryServiceException cex)
8496
    {
8497
      this();
8498
      this.success = success;
8499
      setSuccessIsSet(true);
8500
      this.cex = cex;
8501
    }
8502
 
8503
    /**
8504
     * Performs a deep copy on <i>other</i>.
8505
     */
8506
    public getItemAvailibilityAtWarehouse_result(getItemAvailibilityAtWarehouse_result other) {
8507
      __isset_bit_vector.clear();
8508
      __isset_bit_vector.or(other.__isset_bit_vector);
8509
      this.success = other.success;
8510
      if (other.isSetCex()) {
8511
        this.cex = new InventoryServiceException(other.cex);
8512
      }
8513
    }
8514
 
8515
    public getItemAvailibilityAtWarehouse_result deepCopy() {
8516
      return new getItemAvailibilityAtWarehouse_result(this);
8517
    }
8518
 
8519
    @Override
8520
    public void clear() {
8521
      setSuccessIsSet(false);
8522
      this.success = 0;
8523
      this.cex = null;
8524
    }
8525
 
8526
    public long getSuccess() {
8527
      return this.success;
8528
    }
8529
 
8530
    public void setSuccess(long success) {
8531
      this.success = success;
8532
      setSuccessIsSet(true);
8533
    }
8534
 
8535
    public void unsetSuccess() {
8536
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
8537
    }
8538
 
8539
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
8540
    public boolean isSetSuccess() {
8541
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
8542
    }
8543
 
8544
    public void setSuccessIsSet(boolean value) {
8545
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
8546
    }
8547
 
8548
    public InventoryServiceException getCex() {
8549
      return this.cex;
8550
    }
8551
 
8552
    public void setCex(InventoryServiceException cex) {
8553
      this.cex = cex;
8554
    }
8555
 
8556
    public void unsetCex() {
8557
      this.cex = null;
8558
    }
8559
 
8560
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
8561
    public boolean isSetCex() {
8562
      return this.cex != null;
8563
    }
8564
 
8565
    public void setCexIsSet(boolean value) {
8566
      if (!value) {
8567
        this.cex = null;
8568
      }
8569
    }
8570
 
8571
    public void setFieldValue(_Fields field, Object value) {
8572
      switch (field) {
8573
      case SUCCESS:
8574
        if (value == null) {
8575
          unsetSuccess();
8576
        } else {
8577
          setSuccess((Long)value);
8578
        }
8579
        break;
8580
 
8581
      case CEX:
8582
        if (value == null) {
8583
          unsetCex();
8584
        } else {
8585
          setCex((InventoryServiceException)value);
8586
        }
8587
        break;
8588
 
8589
      }
8590
    }
8591
 
8592
    public Object getFieldValue(_Fields field) {
8593
      switch (field) {
8594
      case SUCCESS:
8595
        return Long.valueOf(getSuccess());
8596
 
8597
      case CEX:
8598
        return getCex();
8599
 
8600
      }
8601
      throw new IllegalStateException();
8602
    }
8603
 
8604
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8605
    public boolean isSet(_Fields field) {
8606
      if (field == null) {
8607
        throw new IllegalArgumentException();
8608
      }
8609
 
8610
      switch (field) {
8611
      case SUCCESS:
8612
        return isSetSuccess();
8613
      case CEX:
8614
        return isSetCex();
8615
      }
8616
      throw new IllegalStateException();
8617
    }
8618
 
8619
    @Override
8620
    public boolean equals(Object that) {
8621
      if (that == null)
8622
        return false;
8623
      if (that instanceof getItemAvailibilityAtWarehouse_result)
8624
        return this.equals((getItemAvailibilityAtWarehouse_result)that);
8625
      return false;
8626
    }
8627
 
8628
    public boolean equals(getItemAvailibilityAtWarehouse_result that) {
8629
      if (that == null)
8630
        return false;
8631
 
8632
      boolean this_present_success = true;
8633
      boolean that_present_success = true;
8634
      if (this_present_success || that_present_success) {
8635
        if (!(this_present_success && that_present_success))
8636
          return false;
8637
        if (this.success != that.success)
8638
          return false;
8639
      }
8640
 
8641
      boolean this_present_cex = true && this.isSetCex();
8642
      boolean that_present_cex = true && that.isSetCex();
8643
      if (this_present_cex || that_present_cex) {
8644
        if (!(this_present_cex && that_present_cex))
8645
          return false;
8646
        if (!this.cex.equals(that.cex))
8647
          return false;
8648
      }
8649
 
8650
      return true;
8651
    }
8652
 
8653
    @Override
8654
    public int hashCode() {
8655
      return 0;
8656
    }
8657
 
8658
    public int compareTo(getItemAvailibilityAtWarehouse_result other) {
8659
      if (!getClass().equals(other.getClass())) {
8660
        return getClass().getName().compareTo(other.getClass().getName());
8661
      }
8662
 
8663
      int lastComparison = 0;
8664
      getItemAvailibilityAtWarehouse_result typedOther = (getItemAvailibilityAtWarehouse_result)other;
8665
 
8666
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
8667
      if (lastComparison != 0) {
8668
        return lastComparison;
8669
      }
8670
      if (isSetSuccess()) {
8671
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8672
        if (lastComparison != 0) {
8673
          return lastComparison;
8674
        }
8675
      }
8676
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
8677
      if (lastComparison != 0) {
8678
        return lastComparison;
8679
      }
8680
      if (isSetCex()) {
8681
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
8682
        if (lastComparison != 0) {
8683
          return lastComparison;
8684
        }
8685
      }
8686
      return 0;
8687
    }
8688
 
8689
    public _Fields fieldForId(int fieldId) {
8690
      return _Fields.findByThriftId(fieldId);
8691
    }
8692
 
8693
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8694
      org.apache.thrift.protocol.TField field;
8695
      iprot.readStructBegin();
8696
      while (true)
8697
      {
8698
        field = iprot.readFieldBegin();
8699
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8700
          break;
8701
        }
8702
        switch (field.id) {
8703
          case 0: // SUCCESS
8704
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8705
              this.success = iprot.readI64();
8706
              setSuccessIsSet(true);
8707
            } else { 
8708
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8709
            }
8710
            break;
8711
          case 1: // CEX
8712
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8713
              this.cex = new InventoryServiceException();
8714
              this.cex.read(iprot);
8715
            } else { 
8716
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8717
            }
8718
            break;
8719
          default:
8720
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8721
        }
8722
        iprot.readFieldEnd();
8723
      }
8724
      iprot.readStructEnd();
8725
      validate();
8726
    }
8727
 
8728
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8729
      oprot.writeStructBegin(STRUCT_DESC);
8730
 
8731
      if (this.isSetSuccess()) {
8732
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8733
        oprot.writeI64(this.success);
8734
        oprot.writeFieldEnd();
8735
      } else if (this.isSetCex()) {
8736
        oprot.writeFieldBegin(CEX_FIELD_DESC);
8737
        this.cex.write(oprot);
8738
        oprot.writeFieldEnd();
8739
      }
8740
      oprot.writeFieldStop();
8741
      oprot.writeStructEnd();
8742
    }
8743
 
8744
    @Override
8745
    public String toString() {
8746
      StringBuilder sb = new StringBuilder("getItemAvailibilityAtWarehouse_result(");
8747
      boolean first = true;
8748
 
8749
      sb.append("success:");
8750
      sb.append(this.success);
8751
      first = false;
8752
      if (!first) sb.append(", ");
8753
      sb.append("cex:");
8754
      if (this.cex == null) {
8755
        sb.append("null");
8756
      } else {
8757
        sb.append(this.cex);
8758
      }
8759
      first = false;
8760
      sb.append(")");
8761
      return sb.toString();
8762
    }
8763
 
8764
    public void validate() throws org.apache.thrift.TException {
8765
      // check for required fields
8766
    }
8767
 
8768
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8769
      try {
8770
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8771
      } catch (org.apache.thrift.TException te) {
8772
        throw new java.io.IOException(te);
8773
      }
8774
    }
8775
 
8776
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8777
      try {
8778
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8779
      } catch (org.apache.thrift.TException te) {
8780
        throw new java.io.IOException(te);
8781
      }
8782
    }
8783
 
8784
  }
8785
 
8786
  public static class getItemAvailabilityAtLocation_args implements org.apache.thrift.TBase<getItemAvailabilityAtLocation_args, getItemAvailabilityAtLocation_args._Fields>, java.io.Serializable, Cloneable   {
8787
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailabilityAtLocation_args");
8788
 
8789
    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);
8790
 
8791
    private long itemId; // required
8792
 
8793
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8794
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8795
      ITEM_ID((short)1, "itemId");
8796
 
8797
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8798
 
8799
      static {
8800
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8801
          byName.put(field.getFieldName(), field);
8802
        }
8803
      }
8804
 
8805
      /**
8806
       * Find the _Fields constant that matches fieldId, or null if its not found.
8807
       */
8808
      public static _Fields findByThriftId(int fieldId) {
8809
        switch(fieldId) {
8810
          case 1: // ITEM_ID
8811
            return ITEM_ID;
8812
          default:
8813
            return null;
8814
        }
8815
      }
8816
 
8817
      /**
8818
       * Find the _Fields constant that matches fieldId, throwing an exception
8819
       * if it is not found.
8820
       */
8821
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8822
        _Fields fields = findByThriftId(fieldId);
8823
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8824
        return fields;
8825
      }
8826
 
8827
      /**
8828
       * Find the _Fields constant that matches name, or null if its not found.
8829
       */
8830
      public static _Fields findByName(String name) {
8831
        return byName.get(name);
8832
      }
8833
 
8834
      private final short _thriftId;
8835
      private final String _fieldName;
8836
 
8837
      _Fields(short thriftId, String fieldName) {
8838
        _thriftId = thriftId;
8839
        _fieldName = fieldName;
8840
      }
8841
 
8842
      public short getThriftFieldId() {
8843
        return _thriftId;
8844
      }
8845
 
8846
      public String getFieldName() {
8847
        return _fieldName;
8848
      }
8849
    }
8850
 
8851
    // isset id assignments
8852
    private static final int __ITEMID_ISSET_ID = 0;
8853
    private BitSet __isset_bit_vector = new BitSet(1);
8854
 
8855
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8856
    static {
8857
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8858
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8859
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8860
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8861
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailabilityAtLocation_args.class, metaDataMap);
8862
    }
8863
 
8864
    public getItemAvailabilityAtLocation_args() {
8865
    }
8866
 
8867
    public getItemAvailabilityAtLocation_args(
8868
      long itemId)
8869
    {
8870
      this();
8871
      this.itemId = itemId;
8872
      setItemIdIsSet(true);
8873
    }
8874
 
8875
    /**
8876
     * Performs a deep copy on <i>other</i>.
8877
     */
8878
    public getItemAvailabilityAtLocation_args(getItemAvailabilityAtLocation_args other) {
8879
      __isset_bit_vector.clear();
8880
      __isset_bit_vector.or(other.__isset_bit_vector);
8881
      this.itemId = other.itemId;
8882
    }
8883
 
8884
    public getItemAvailabilityAtLocation_args deepCopy() {
8885
      return new getItemAvailabilityAtLocation_args(this);
8886
    }
8887
 
8888
    @Override
8889
    public void clear() {
8890
      setItemIdIsSet(false);
8891
      this.itemId = 0;
8892
    }
8893
 
8894
    public long getItemId() {
8895
      return this.itemId;
8896
    }
8897
 
8898
    public void setItemId(long itemId) {
8899
      this.itemId = itemId;
8900
      setItemIdIsSet(true);
8901
    }
8902
 
8903
    public void unsetItemId() {
8904
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
8905
    }
8906
 
8907
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
8908
    public boolean isSetItemId() {
8909
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
8910
    }
8911
 
8912
    public void setItemIdIsSet(boolean value) {
8913
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
8914
    }
8915
 
8916
    public void setFieldValue(_Fields field, Object value) {
8917
      switch (field) {
8918
      case ITEM_ID:
8919
        if (value == null) {
8920
          unsetItemId();
8921
        } else {
8922
          setItemId((Long)value);
8923
        }
8924
        break;
8925
 
8926
      }
8927
    }
8928
 
8929
    public Object getFieldValue(_Fields field) {
8930
      switch (field) {
8931
      case ITEM_ID:
8932
        return Long.valueOf(getItemId());
8933
 
8934
      }
8935
      throw new IllegalStateException();
8936
    }
8937
 
8938
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8939
    public boolean isSet(_Fields field) {
8940
      if (field == null) {
8941
        throw new IllegalArgumentException();
8942
      }
8943
 
8944
      switch (field) {
8945
      case ITEM_ID:
8946
        return isSetItemId();
8947
      }
8948
      throw new IllegalStateException();
8949
    }
8950
 
8951
    @Override
8952
    public boolean equals(Object that) {
8953
      if (that == null)
8954
        return false;
8955
      if (that instanceof getItemAvailabilityAtLocation_args)
8956
        return this.equals((getItemAvailabilityAtLocation_args)that);
8957
      return false;
8958
    }
8959
 
8960
    public boolean equals(getItemAvailabilityAtLocation_args that) {
8961
      if (that == null)
8962
        return false;
8963
 
8964
      boolean this_present_itemId = true;
8965
      boolean that_present_itemId = true;
8966
      if (this_present_itemId || that_present_itemId) {
8967
        if (!(this_present_itemId && that_present_itemId))
8968
          return false;
8969
        if (this.itemId != that.itemId)
8970
          return false;
8971
      }
8972
 
8973
      return true;
8974
    }
8975
 
8976
    @Override
8977
    public int hashCode() {
8978
      return 0;
8979
    }
8980
 
8981
    public int compareTo(getItemAvailabilityAtLocation_args other) {
8982
      if (!getClass().equals(other.getClass())) {
8983
        return getClass().getName().compareTo(other.getClass().getName());
8984
      }
8985
 
8986
      int lastComparison = 0;
8987
      getItemAvailabilityAtLocation_args typedOther = (getItemAvailabilityAtLocation_args)other;
8988
 
8989
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
8990
      if (lastComparison != 0) {
8991
        return lastComparison;
8992
      }
8993
      if (isSetItemId()) {
8994
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
8995
        if (lastComparison != 0) {
8996
          return lastComparison;
8997
        }
8998
      }
8999
      return 0;
9000
    }
9001
 
9002
    public _Fields fieldForId(int fieldId) {
9003
      return _Fields.findByThriftId(fieldId);
9004
    }
9005
 
9006
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9007
      org.apache.thrift.protocol.TField field;
9008
      iprot.readStructBegin();
9009
      while (true)
9010
      {
9011
        field = iprot.readFieldBegin();
9012
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9013
          break;
9014
        }
9015
        switch (field.id) {
9016
          case 1: // ITEM_ID
9017
            if (field.type == org.apache.thrift.protocol.TType.I64) {
9018
              this.itemId = iprot.readI64();
9019
              setItemIdIsSet(true);
9020
            } else { 
9021
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9022
            }
9023
            break;
9024
          default:
9025
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9026
        }
9027
        iprot.readFieldEnd();
9028
      }
9029
      iprot.readStructEnd();
9030
      validate();
9031
    }
9032
 
9033
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9034
      validate();
9035
 
9036
      oprot.writeStructBegin(STRUCT_DESC);
9037
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
9038
      oprot.writeI64(this.itemId);
9039
      oprot.writeFieldEnd();
9040
      oprot.writeFieldStop();
9041
      oprot.writeStructEnd();
9042
    }
9043
 
9044
    @Override
9045
    public String toString() {
9046
      StringBuilder sb = new StringBuilder("getItemAvailabilityAtLocation_args(");
9047
      boolean first = true;
9048
 
9049
      sb.append("itemId:");
9050
      sb.append(this.itemId);
9051
      first = false;
9052
      sb.append(")");
9053
      return sb.toString();
9054
    }
9055
 
9056
    public void validate() throws org.apache.thrift.TException {
9057
      // check for required fields
9058
    }
9059
 
9060
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9061
      try {
9062
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9063
      } catch (org.apache.thrift.TException te) {
9064
        throw new java.io.IOException(te);
9065
      }
9066
    }
9067
 
9068
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9069
      try {
9070
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9071
      } catch (org.apache.thrift.TException te) {
9072
        throw new java.io.IOException(te);
9073
      }
9074
    }
9075
 
9076
  }
9077
 
9078
  public static class getItemAvailabilityAtLocation_result implements org.apache.thrift.TBase<getItemAvailabilityAtLocation_result, getItemAvailabilityAtLocation_result._Fields>, java.io.Serializable, Cloneable   {
9079
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailabilityAtLocation_result");
9080
 
9081
    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);
9082
    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);
9083
 
9084
    private List<Long> success; // required
9085
    private InventoryServiceException isex; // required
9086
 
9087
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9088
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9089
      SUCCESS((short)0, "success"),
9090
      ISEX((short)1, "isex");
9091
 
9092
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9093
 
9094
      static {
9095
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9096
          byName.put(field.getFieldName(), field);
9097
        }
9098
      }
9099
 
9100
      /**
9101
       * Find the _Fields constant that matches fieldId, or null if its not found.
9102
       */
9103
      public static _Fields findByThriftId(int fieldId) {
9104
        switch(fieldId) {
9105
          case 0: // SUCCESS
9106
            return SUCCESS;
9107
          case 1: // ISEX
9108
            return ISEX;
9109
          default:
9110
            return null;
9111
        }
9112
      }
9113
 
9114
      /**
9115
       * Find the _Fields constant that matches fieldId, throwing an exception
9116
       * if it is not found.
9117
       */
9118
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9119
        _Fields fields = findByThriftId(fieldId);
9120
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9121
        return fields;
9122
      }
9123
 
9124
      /**
9125
       * Find the _Fields constant that matches name, or null if its not found.
9126
       */
9127
      public static _Fields findByName(String name) {
9128
        return byName.get(name);
9129
      }
9130
 
9131
      private final short _thriftId;
9132
      private final String _fieldName;
9133
 
9134
      _Fields(short thriftId, String fieldName) {
9135
        _thriftId = thriftId;
9136
        _fieldName = fieldName;
9137
      }
9138
 
9139
      public short getThriftFieldId() {
9140
        return _thriftId;
9141
      }
9142
 
9143
      public String getFieldName() {
9144
        return _fieldName;
9145
      }
9146
    }
9147
 
9148
    // isset id assignments
9149
 
9150
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9151
    static {
9152
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9153
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9154
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9155
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
9156
      tmpMap.put(_Fields.ISEX, new org.apache.thrift.meta_data.FieldMetaData("isex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9157
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9158
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9159
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailabilityAtLocation_result.class, metaDataMap);
9160
    }
9161
 
9162
    public getItemAvailabilityAtLocation_result() {
9163
    }
9164
 
9165
    public getItemAvailabilityAtLocation_result(
9166
      List<Long> success,
9167
      InventoryServiceException isex)
9168
    {
9169
      this();
9170
      this.success = success;
9171
      this.isex = isex;
9172
    }
9173
 
9174
    /**
9175
     * Performs a deep copy on <i>other</i>.
9176
     */
9177
    public getItemAvailabilityAtLocation_result(getItemAvailabilityAtLocation_result other) {
9178
      if (other.isSetSuccess()) {
9179
        List<Long> __this__success = new ArrayList<Long>();
9180
        for (Long other_element : other.success) {
9181
          __this__success.add(other_element);
9182
        }
9183
        this.success = __this__success;
9184
      }
9185
      if (other.isSetIsex()) {
9186
        this.isex = new InventoryServiceException(other.isex);
9187
      }
9188
    }
9189
 
9190
    public getItemAvailabilityAtLocation_result deepCopy() {
9191
      return new getItemAvailabilityAtLocation_result(this);
9192
    }
9193
 
9194
    @Override
9195
    public void clear() {
9196
      this.success = null;
9197
      this.isex = null;
9198
    }
9199
 
9200
    public int getSuccessSize() {
9201
      return (this.success == null) ? 0 : this.success.size();
9202
    }
9203
 
9204
    public java.util.Iterator<Long> getSuccessIterator() {
9205
      return (this.success == null) ? null : this.success.iterator();
9206
    }
9207
 
9208
    public void addToSuccess(long elem) {
9209
      if (this.success == null) {
9210
        this.success = new ArrayList<Long>();
9211
      }
9212
      this.success.add(elem);
9213
    }
9214
 
9215
    public List<Long> getSuccess() {
9216
      return this.success;
9217
    }
9218
 
9219
    public void setSuccess(List<Long> success) {
9220
      this.success = success;
9221
    }
9222
 
9223
    public void unsetSuccess() {
9224
      this.success = null;
9225
    }
9226
 
9227
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9228
    public boolean isSetSuccess() {
9229
      return this.success != null;
9230
    }
9231
 
9232
    public void setSuccessIsSet(boolean value) {
9233
      if (!value) {
9234
        this.success = null;
9235
      }
9236
    }
9237
 
9238
    public InventoryServiceException getIsex() {
9239
      return this.isex;
9240
    }
9241
 
9242
    public void setIsex(InventoryServiceException isex) {
9243
      this.isex = isex;
9244
    }
9245
 
9246
    public void unsetIsex() {
9247
      this.isex = null;
9248
    }
9249
 
9250
    /** Returns true if field isex is set (has been assigned a value) and false otherwise */
9251
    public boolean isSetIsex() {
9252
      return this.isex != null;
9253
    }
9254
 
9255
    public void setIsexIsSet(boolean value) {
9256
      if (!value) {
9257
        this.isex = null;
9258
      }
9259
    }
9260
 
9261
    public void setFieldValue(_Fields field, Object value) {
9262
      switch (field) {
9263
      case SUCCESS:
9264
        if (value == null) {
9265
          unsetSuccess();
9266
        } else {
9267
          setSuccess((List<Long>)value);
9268
        }
9269
        break;
9270
 
9271
      case ISEX:
9272
        if (value == null) {
9273
          unsetIsex();
9274
        } else {
9275
          setIsex((InventoryServiceException)value);
9276
        }
9277
        break;
9278
 
9279
      }
9280
    }
9281
 
9282
    public Object getFieldValue(_Fields field) {
9283
      switch (field) {
9284
      case SUCCESS:
9285
        return getSuccess();
9286
 
9287
      case ISEX:
9288
        return getIsex();
9289
 
9290
      }
9291
      throw new IllegalStateException();
9292
    }
9293
 
9294
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9295
    public boolean isSet(_Fields field) {
9296
      if (field == null) {
9297
        throw new IllegalArgumentException();
9298
      }
9299
 
9300
      switch (field) {
9301
      case SUCCESS:
9302
        return isSetSuccess();
9303
      case ISEX:
9304
        return isSetIsex();
9305
      }
9306
      throw new IllegalStateException();
9307
    }
9308
 
9309
    @Override
9310
    public boolean equals(Object that) {
9311
      if (that == null)
9312
        return false;
9313
      if (that instanceof getItemAvailabilityAtLocation_result)
9314
        return this.equals((getItemAvailabilityAtLocation_result)that);
9315
      return false;
9316
    }
9317
 
9318
    public boolean equals(getItemAvailabilityAtLocation_result that) {
9319
      if (that == null)
9320
        return false;
9321
 
9322
      boolean this_present_success = true && this.isSetSuccess();
9323
      boolean that_present_success = true && that.isSetSuccess();
9324
      if (this_present_success || that_present_success) {
9325
        if (!(this_present_success && that_present_success))
9326
          return false;
9327
        if (!this.success.equals(that.success))
9328
          return false;
9329
      }
9330
 
9331
      boolean this_present_isex = true && this.isSetIsex();
9332
      boolean that_present_isex = true && that.isSetIsex();
9333
      if (this_present_isex || that_present_isex) {
9334
        if (!(this_present_isex && that_present_isex))
9335
          return false;
9336
        if (!this.isex.equals(that.isex))
9337
          return false;
9338
      }
9339
 
9340
      return true;
9341
    }
9342
 
9343
    @Override
9344
    public int hashCode() {
9345
      return 0;
9346
    }
9347
 
9348
    public int compareTo(getItemAvailabilityAtLocation_result other) {
9349
      if (!getClass().equals(other.getClass())) {
9350
        return getClass().getName().compareTo(other.getClass().getName());
9351
      }
9352
 
9353
      int lastComparison = 0;
9354
      getItemAvailabilityAtLocation_result typedOther = (getItemAvailabilityAtLocation_result)other;
9355
 
9356
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
9357
      if (lastComparison != 0) {
9358
        return lastComparison;
9359
      }
9360
      if (isSetSuccess()) {
9361
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9362
        if (lastComparison != 0) {
9363
          return lastComparison;
9364
        }
9365
      }
9366
      lastComparison = Boolean.valueOf(isSetIsex()).compareTo(typedOther.isSetIsex());
9367
      if (lastComparison != 0) {
9368
        return lastComparison;
9369
      }
9370
      if (isSetIsex()) {
9371
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isex, typedOther.isex);
9372
        if (lastComparison != 0) {
9373
          return lastComparison;
9374
        }
9375
      }
9376
      return 0;
9377
    }
9378
 
9379
    public _Fields fieldForId(int fieldId) {
9380
      return _Fields.findByThriftId(fieldId);
9381
    }
9382
 
9383
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9384
      org.apache.thrift.protocol.TField field;
9385
      iprot.readStructBegin();
9386
      while (true)
9387
      {
9388
        field = iprot.readFieldBegin();
9389
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9390
          break;
9391
        }
9392
        switch (field.id) {
9393
          case 0: // SUCCESS
9394
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
9395
              {
9396
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
9397
                this.success = new ArrayList<Long>(_list20.size);
9398
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
9399
                {
9400
                  long _elem22; // required
9401
                  _elem22 = iprot.readI64();
9402
                  this.success.add(_elem22);
9403
                }
9404
                iprot.readListEnd();
9405
              }
9406
            } else { 
9407
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9408
            }
9409
            break;
9410
          case 1: // ISEX
9411
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9412
              this.isex = new InventoryServiceException();
9413
              this.isex.read(iprot);
9414
            } else { 
9415
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9416
            }
9417
            break;
9418
          default:
9419
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9420
        }
9421
        iprot.readFieldEnd();
9422
      }
9423
      iprot.readStructEnd();
9424
      validate();
9425
    }
9426
 
9427
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9428
      oprot.writeStructBegin(STRUCT_DESC);
9429
 
9430
      if (this.isSetSuccess()) {
9431
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9432
        {
9433
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
9434
          for (long _iter23 : this.success)
9435
          {
9436
            oprot.writeI64(_iter23);
9437
          }
9438
          oprot.writeListEnd();
9439
        }
9440
        oprot.writeFieldEnd();
9441
      } else if (this.isSetIsex()) {
9442
        oprot.writeFieldBegin(ISEX_FIELD_DESC);
9443
        this.isex.write(oprot);
9444
        oprot.writeFieldEnd();
9445
      }
9446
      oprot.writeFieldStop();
9447
      oprot.writeStructEnd();
9448
    }
9449
 
9450
    @Override
9451
    public String toString() {
9452
      StringBuilder sb = new StringBuilder("getItemAvailabilityAtLocation_result(");
9453
      boolean first = true;
9454
 
9455
      sb.append("success:");
9456
      if (this.success == null) {
9457
        sb.append("null");
9458
      } else {
9459
        sb.append(this.success);
9460
      }
9461
      first = false;
9462
      if (!first) sb.append(", ");
9463
      sb.append("isex:");
9464
      if (this.isex == null) {
9465
        sb.append("null");
9466
      } else {
9467
        sb.append(this.isex);
9468
      }
9469
      first = false;
9470
      sb.append(")");
9471
      return sb.toString();
9472
    }
9473
 
9474
    public void validate() throws org.apache.thrift.TException {
9475
      // check for required fields
9476
    }
9477
 
9478
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9479
      try {
9480
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9481
      } catch (org.apache.thrift.TException te) {
9482
        throw new java.io.IOException(te);
9483
      }
9484
    }
9485
 
9486
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9487
      try {
9488
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9489
      } catch (org.apache.thrift.TException te) {
9490
        throw new java.io.IOException(te);
9491
      }
9492
    }
9493
 
9494
  }
9495
 
9496
  public static class getAllWarehouses_args implements org.apache.thrift.TBase<getAllWarehouses_args, getAllWarehouses_args._Fields>, java.io.Serializable, Cloneable   {
9497
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllWarehouses_args");
9498
 
9499
    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);
9500
 
9501
    private boolean isActive; // required
9502
 
9503
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9504
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9505
      IS_ACTIVE((short)1, "isActive");
9506
 
9507
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9508
 
9509
      static {
9510
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9511
          byName.put(field.getFieldName(), field);
9512
        }
9513
      }
9514
 
9515
      /**
9516
       * Find the _Fields constant that matches fieldId, or null if its not found.
9517
       */
9518
      public static _Fields findByThriftId(int fieldId) {
9519
        switch(fieldId) {
9520
          case 1: // IS_ACTIVE
9521
            return IS_ACTIVE;
9522
          default:
9523
            return null;
9524
        }
9525
      }
9526
 
9527
      /**
9528
       * Find the _Fields constant that matches fieldId, throwing an exception
9529
       * if it is not found.
9530
       */
9531
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9532
        _Fields fields = findByThriftId(fieldId);
9533
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9534
        return fields;
9535
      }
9536
 
9537
      /**
9538
       * Find the _Fields constant that matches name, or null if its not found.
9539
       */
9540
      public static _Fields findByName(String name) {
9541
        return byName.get(name);
9542
      }
9543
 
9544
      private final short _thriftId;
9545
      private final String _fieldName;
9546
 
9547
      _Fields(short thriftId, String fieldName) {
9548
        _thriftId = thriftId;
9549
        _fieldName = fieldName;
9550
      }
9551
 
9552
      public short getThriftFieldId() {
9553
        return _thriftId;
9554
      }
9555
 
9556
      public String getFieldName() {
9557
        return _fieldName;
9558
      }
9559
    }
9560
 
9561
    // isset id assignments
9562
    private static final int __ISACTIVE_ISSET_ID = 0;
9563
    private BitSet __isset_bit_vector = new BitSet(1);
9564
 
9565
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9566
    static {
9567
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9568
      tmpMap.put(_Fields.IS_ACTIVE, new org.apache.thrift.meta_data.FieldMetaData("isActive", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9569
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
9570
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9571
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllWarehouses_args.class, metaDataMap);
9572
    }
9573
 
9574
    public getAllWarehouses_args() {
9575
    }
9576
 
9577
    public getAllWarehouses_args(
9578
      boolean isActive)
9579
    {
9580
      this();
9581
      this.isActive = isActive;
9582
      setIsActiveIsSet(true);
9583
    }
9584
 
9585
    /**
9586
     * Performs a deep copy on <i>other</i>.
9587
     */
9588
    public getAllWarehouses_args(getAllWarehouses_args other) {
9589
      __isset_bit_vector.clear();
9590
      __isset_bit_vector.or(other.__isset_bit_vector);
9591
      this.isActive = other.isActive;
9592
    }
9593
 
9594
    public getAllWarehouses_args deepCopy() {
9595
      return new getAllWarehouses_args(this);
9596
    }
9597
 
9598
    @Override
9599
    public void clear() {
9600
      setIsActiveIsSet(false);
9601
      this.isActive = false;
9602
    }
9603
 
9604
    public boolean isIsActive() {
9605
      return this.isActive;
9606
    }
9607
 
9608
    public void setIsActive(boolean isActive) {
9609
      this.isActive = isActive;
9610
      setIsActiveIsSet(true);
9611
    }
9612
 
9613
    public void unsetIsActive() {
9614
      __isset_bit_vector.clear(__ISACTIVE_ISSET_ID);
9615
    }
9616
 
9617
    /** Returns true if field isActive is set (has been assigned a value) and false otherwise */
9618
    public boolean isSetIsActive() {
9619
      return __isset_bit_vector.get(__ISACTIVE_ISSET_ID);
9620
    }
9621
 
9622
    public void setIsActiveIsSet(boolean value) {
9623
      __isset_bit_vector.set(__ISACTIVE_ISSET_ID, value);
9624
    }
9625
 
9626
    public void setFieldValue(_Fields field, Object value) {
9627
      switch (field) {
9628
      case IS_ACTIVE:
9629
        if (value == null) {
9630
          unsetIsActive();
9631
        } else {
9632
          setIsActive((Boolean)value);
9633
        }
9634
        break;
9635
 
9636
      }
9637
    }
9638
 
9639
    public Object getFieldValue(_Fields field) {
9640
      switch (field) {
9641
      case IS_ACTIVE:
9642
        return Boolean.valueOf(isIsActive());
9643
 
9644
      }
9645
      throw new IllegalStateException();
9646
    }
9647
 
9648
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9649
    public boolean isSet(_Fields field) {
9650
      if (field == null) {
9651
        throw new IllegalArgumentException();
9652
      }
9653
 
9654
      switch (field) {
9655
      case IS_ACTIVE:
9656
        return isSetIsActive();
9657
      }
9658
      throw new IllegalStateException();
9659
    }
9660
 
9661
    @Override
9662
    public boolean equals(Object that) {
9663
      if (that == null)
9664
        return false;
9665
      if (that instanceof getAllWarehouses_args)
9666
        return this.equals((getAllWarehouses_args)that);
9667
      return false;
9668
    }
9669
 
9670
    public boolean equals(getAllWarehouses_args that) {
9671
      if (that == null)
9672
        return false;
9673
 
9674
      boolean this_present_isActive = true;
9675
      boolean that_present_isActive = true;
9676
      if (this_present_isActive || that_present_isActive) {
9677
        if (!(this_present_isActive && that_present_isActive))
9678
          return false;
9679
        if (this.isActive != that.isActive)
9680
          return false;
9681
      }
9682
 
9683
      return true;
9684
    }
9685
 
9686
    @Override
9687
    public int hashCode() {
9688
      return 0;
9689
    }
9690
 
9691
    public int compareTo(getAllWarehouses_args other) {
9692
      if (!getClass().equals(other.getClass())) {
9693
        return getClass().getName().compareTo(other.getClass().getName());
9694
      }
9695
 
9696
      int lastComparison = 0;
9697
      getAllWarehouses_args typedOther = (getAllWarehouses_args)other;
9698
 
9699
      lastComparison = Boolean.valueOf(isSetIsActive()).compareTo(typedOther.isSetIsActive());
9700
      if (lastComparison != 0) {
9701
        return lastComparison;
9702
      }
9703
      if (isSetIsActive()) {
9704
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isActive, typedOther.isActive);
9705
        if (lastComparison != 0) {
9706
          return lastComparison;
9707
        }
9708
      }
9709
      return 0;
9710
    }
9711
 
9712
    public _Fields fieldForId(int fieldId) {
9713
      return _Fields.findByThriftId(fieldId);
9714
    }
9715
 
9716
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9717
      org.apache.thrift.protocol.TField field;
9718
      iprot.readStructBegin();
9719
      while (true)
9720
      {
9721
        field = iprot.readFieldBegin();
9722
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9723
          break;
9724
        }
9725
        switch (field.id) {
9726
          case 1: // IS_ACTIVE
9727
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
9728
              this.isActive = iprot.readBool();
9729
              setIsActiveIsSet(true);
9730
            } else { 
9731
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9732
            }
9733
            break;
9734
          default:
9735
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9736
        }
9737
        iprot.readFieldEnd();
9738
      }
9739
      iprot.readStructEnd();
9740
      validate();
9741
    }
9742
 
9743
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9744
      validate();
9745
 
9746
      oprot.writeStructBegin(STRUCT_DESC);
9747
      oprot.writeFieldBegin(IS_ACTIVE_FIELD_DESC);
9748
      oprot.writeBool(this.isActive);
9749
      oprot.writeFieldEnd();
9750
      oprot.writeFieldStop();
9751
      oprot.writeStructEnd();
9752
    }
9753
 
9754
    @Override
9755
    public String toString() {
9756
      StringBuilder sb = new StringBuilder("getAllWarehouses_args(");
9757
      boolean first = true;
9758
 
9759
      sb.append("isActive:");
9760
      sb.append(this.isActive);
9761
      first = false;
9762
      sb.append(")");
9763
      return sb.toString();
9764
    }
9765
 
9766
    public void validate() throws org.apache.thrift.TException {
9767
      // check for required fields
9768
    }
9769
 
9770
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9771
      try {
9772
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9773
      } catch (org.apache.thrift.TException te) {
9774
        throw new java.io.IOException(te);
9775
      }
9776
    }
9777
 
9778
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9779
      try {
9780
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
9781
        __isset_bit_vector = new BitSet(1);
9782
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9783
      } catch (org.apache.thrift.TException te) {
9784
        throw new java.io.IOException(te);
9785
      }
9786
    }
9787
 
9788
  }
9789
 
9790
  public static class getAllWarehouses_result implements org.apache.thrift.TBase<getAllWarehouses_result, getAllWarehouses_result._Fields>, java.io.Serializable, Cloneable   {
9791
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllWarehouses_result");
9792
 
9793
    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);
9794
    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);
9795
 
9796
    private List<Warehouse> success; // required
9797
    private InventoryServiceException cex; // required
9798
 
9799
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9800
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9801
      SUCCESS((short)0, "success"),
9802
      CEX((short)1, "cex");
9803
 
9804
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9805
 
9806
      static {
9807
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9808
          byName.put(field.getFieldName(), field);
9809
        }
9810
      }
9811
 
9812
      /**
9813
       * Find the _Fields constant that matches fieldId, or null if its not found.
9814
       */
9815
      public static _Fields findByThriftId(int fieldId) {
9816
        switch(fieldId) {
9817
          case 0: // SUCCESS
9818
            return SUCCESS;
9819
          case 1: // CEX
9820
            return CEX;
9821
          default:
9822
            return null;
9823
        }
9824
      }
9825
 
9826
      /**
9827
       * Find the _Fields constant that matches fieldId, throwing an exception
9828
       * if it is not found.
9829
       */
9830
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9831
        _Fields fields = findByThriftId(fieldId);
9832
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9833
        return fields;
9834
      }
9835
 
9836
      /**
9837
       * Find the _Fields constant that matches name, or null if its not found.
9838
       */
9839
      public static _Fields findByName(String name) {
9840
        return byName.get(name);
9841
      }
9842
 
9843
      private final short _thriftId;
9844
      private final String _fieldName;
9845
 
9846
      _Fields(short thriftId, String fieldName) {
9847
        _thriftId = thriftId;
9848
        _fieldName = fieldName;
9849
      }
9850
 
9851
      public short getThriftFieldId() {
9852
        return _thriftId;
9853
      }
9854
 
9855
      public String getFieldName() {
9856
        return _fieldName;
9857
      }
9858
    }
9859
 
9860
    // isset id assignments
9861
 
9862
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9863
    static {
9864
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9865
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9866
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9867
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
9868
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9869
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9870
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9871
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllWarehouses_result.class, metaDataMap);
9872
    }
9873
 
9874
    public getAllWarehouses_result() {
9875
    }
9876
 
9877
    public getAllWarehouses_result(
9878
      List<Warehouse> success,
9879
      InventoryServiceException cex)
9880
    {
9881
      this();
9882
      this.success = success;
9883
      this.cex = cex;
9884
    }
9885
 
9886
    /**
9887
     * Performs a deep copy on <i>other</i>.
9888
     */
9889
    public getAllWarehouses_result(getAllWarehouses_result other) {
9890
      if (other.isSetSuccess()) {
9891
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
9892
        for (Warehouse other_element : other.success) {
9893
          __this__success.add(new Warehouse(other_element));
9894
        }
9895
        this.success = __this__success;
9896
      }
9897
      if (other.isSetCex()) {
9898
        this.cex = new InventoryServiceException(other.cex);
9899
      }
9900
    }
9901
 
9902
    public getAllWarehouses_result deepCopy() {
9903
      return new getAllWarehouses_result(this);
9904
    }
9905
 
9906
    @Override
9907
    public void clear() {
9908
      this.success = null;
9909
      this.cex = null;
9910
    }
9911
 
9912
    public int getSuccessSize() {
9913
      return (this.success == null) ? 0 : this.success.size();
9914
    }
9915
 
9916
    public java.util.Iterator<Warehouse> getSuccessIterator() {
9917
      return (this.success == null) ? null : this.success.iterator();
9918
    }
9919
 
9920
    public void addToSuccess(Warehouse elem) {
9921
      if (this.success == null) {
9922
        this.success = new ArrayList<Warehouse>();
9923
      }
9924
      this.success.add(elem);
9925
    }
9926
 
9927
    public List<Warehouse> getSuccess() {
9928
      return this.success;
9929
    }
9930
 
9931
    public void setSuccess(List<Warehouse> success) {
9932
      this.success = success;
9933
    }
9934
 
9935
    public void unsetSuccess() {
9936
      this.success = null;
9937
    }
9938
 
9939
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9940
    public boolean isSetSuccess() {
9941
      return this.success != null;
9942
    }
9943
 
9944
    public void setSuccessIsSet(boolean value) {
9945
      if (!value) {
9946
        this.success = null;
9947
      }
9948
    }
9949
 
9950
    public InventoryServiceException getCex() {
9951
      return this.cex;
9952
    }
9953
 
9954
    public void setCex(InventoryServiceException cex) {
9955
      this.cex = cex;
9956
    }
9957
 
9958
    public void unsetCex() {
9959
      this.cex = null;
9960
    }
9961
 
9962
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
9963
    public boolean isSetCex() {
9964
      return this.cex != null;
9965
    }
9966
 
9967
    public void setCexIsSet(boolean value) {
9968
      if (!value) {
9969
        this.cex = null;
9970
      }
9971
    }
9972
 
9973
    public void setFieldValue(_Fields field, Object value) {
9974
      switch (field) {
9975
      case SUCCESS:
9976
        if (value == null) {
9977
          unsetSuccess();
9978
        } else {
9979
          setSuccess((List<Warehouse>)value);
9980
        }
9981
        break;
9982
 
9983
      case CEX:
9984
        if (value == null) {
9985
          unsetCex();
9986
        } else {
9987
          setCex((InventoryServiceException)value);
9988
        }
9989
        break;
9990
 
9991
      }
9992
    }
9993
 
9994
    public Object getFieldValue(_Fields field) {
9995
      switch (field) {
9996
      case SUCCESS:
9997
        return getSuccess();
9998
 
9999
      case CEX:
10000
        return getCex();
10001
 
10002
      }
10003
      throw new IllegalStateException();
10004
    }
10005
 
10006
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10007
    public boolean isSet(_Fields field) {
10008
      if (field == null) {
10009
        throw new IllegalArgumentException();
10010
      }
10011
 
10012
      switch (field) {
10013
      case SUCCESS:
10014
        return isSetSuccess();
10015
      case CEX:
10016
        return isSetCex();
10017
      }
10018
      throw new IllegalStateException();
10019
    }
10020
 
10021
    @Override
10022
    public boolean equals(Object that) {
10023
      if (that == null)
10024
        return false;
10025
      if (that instanceof getAllWarehouses_result)
10026
        return this.equals((getAllWarehouses_result)that);
10027
      return false;
10028
    }
10029
 
10030
    public boolean equals(getAllWarehouses_result that) {
10031
      if (that == null)
10032
        return false;
10033
 
10034
      boolean this_present_success = true && this.isSetSuccess();
10035
      boolean that_present_success = true && that.isSetSuccess();
10036
      if (this_present_success || that_present_success) {
10037
        if (!(this_present_success && that_present_success))
10038
          return false;
10039
        if (!this.success.equals(that.success))
10040
          return false;
10041
      }
10042
 
10043
      boolean this_present_cex = true && this.isSetCex();
10044
      boolean that_present_cex = true && that.isSetCex();
10045
      if (this_present_cex || that_present_cex) {
10046
        if (!(this_present_cex && that_present_cex))
10047
          return false;
10048
        if (!this.cex.equals(that.cex))
10049
          return false;
10050
      }
10051
 
10052
      return true;
10053
    }
10054
 
10055
    @Override
10056
    public int hashCode() {
10057
      return 0;
10058
    }
10059
 
10060
    public int compareTo(getAllWarehouses_result other) {
10061
      if (!getClass().equals(other.getClass())) {
10062
        return getClass().getName().compareTo(other.getClass().getName());
10063
      }
10064
 
10065
      int lastComparison = 0;
10066
      getAllWarehouses_result typedOther = (getAllWarehouses_result)other;
10067
 
10068
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10069
      if (lastComparison != 0) {
10070
        return lastComparison;
10071
      }
10072
      if (isSetSuccess()) {
10073
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10074
        if (lastComparison != 0) {
10075
          return lastComparison;
10076
        }
10077
      }
10078
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
10079
      if (lastComparison != 0) {
10080
        return lastComparison;
10081
      }
10082
      if (isSetCex()) {
10083
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
10084
        if (lastComparison != 0) {
10085
          return lastComparison;
10086
        }
10087
      }
10088
      return 0;
10089
    }
10090
 
10091
    public _Fields fieldForId(int fieldId) {
10092
      return _Fields.findByThriftId(fieldId);
10093
    }
10094
 
10095
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10096
      org.apache.thrift.protocol.TField field;
10097
      iprot.readStructBegin();
10098
      while (true)
10099
      {
10100
        field = iprot.readFieldBegin();
10101
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10102
          break;
10103
        }
10104
        switch (field.id) {
10105
          case 0: // SUCCESS
10106
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
10107
              {
10108
                org.apache.thrift.protocol.TList _list24 = iprot.readListBegin();
10109
                this.success = new ArrayList<Warehouse>(_list24.size);
10110
                for (int _i25 = 0; _i25 < _list24.size; ++_i25)
10111
                {
10112
                  Warehouse _elem26; // required
10113
                  _elem26 = new Warehouse();
10114
                  _elem26.read(iprot);
10115
                  this.success.add(_elem26);
10116
                }
10117
                iprot.readListEnd();
10118
              }
10119
            } else { 
10120
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10121
            }
10122
            break;
10123
          case 1: // CEX
10124
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10125
              this.cex = new InventoryServiceException();
10126
              this.cex.read(iprot);
10127
            } else { 
10128
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10129
            }
10130
            break;
10131
          default:
10132
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10133
        }
10134
        iprot.readFieldEnd();
10135
      }
10136
      iprot.readStructEnd();
10137
      validate();
10138
    }
10139
 
10140
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10141
      oprot.writeStructBegin(STRUCT_DESC);
10142
 
10143
      if (this.isSetSuccess()) {
10144
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10145
        {
10146
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
10147
          for (Warehouse _iter27 : this.success)
10148
          {
10149
            _iter27.write(oprot);
10150
          }
10151
          oprot.writeListEnd();
10152
        }
10153
        oprot.writeFieldEnd();
10154
      } else if (this.isSetCex()) {
10155
        oprot.writeFieldBegin(CEX_FIELD_DESC);
10156
        this.cex.write(oprot);
10157
        oprot.writeFieldEnd();
10158
      }
10159
      oprot.writeFieldStop();
10160
      oprot.writeStructEnd();
10161
    }
10162
 
10163
    @Override
10164
    public String toString() {
10165
      StringBuilder sb = new StringBuilder("getAllWarehouses_result(");
10166
      boolean first = true;
10167
 
10168
      sb.append("success:");
10169
      if (this.success == null) {
10170
        sb.append("null");
10171
      } else {
10172
        sb.append(this.success);
10173
      }
10174
      first = false;
10175
      if (!first) sb.append(", ");
10176
      sb.append("cex:");
10177
      if (this.cex == null) {
10178
        sb.append("null");
10179
      } else {
10180
        sb.append(this.cex);
10181
      }
10182
      first = false;
10183
      sb.append(")");
10184
      return sb.toString();
10185
    }
10186
 
10187
    public void validate() throws org.apache.thrift.TException {
10188
      // check for required fields
10189
    }
10190
 
10191
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10192
      try {
10193
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10194
      } catch (org.apache.thrift.TException te) {
10195
        throw new java.io.IOException(te);
10196
      }
10197
    }
10198
 
10199
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10200
      try {
10201
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10202
      } catch (org.apache.thrift.TException te) {
10203
        throw new java.io.IOException(te);
10204
      }
10205
    }
10206
 
10207
  }
10208
 
10209
  public static class getWarehouse_args implements org.apache.thrift.TBase<getWarehouse_args, getWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
10210
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouse_args");
10211
 
10212
    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);
10213
 
10214
    private long warehouse_id; // required
10215
 
10216
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10217
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10218
      WAREHOUSE_ID((short)1, "warehouse_id");
10219
 
10220
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10221
 
10222
      static {
10223
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10224
          byName.put(field.getFieldName(), field);
10225
        }
10226
      }
10227
 
10228
      /**
10229
       * Find the _Fields constant that matches fieldId, or null if its not found.
10230
       */
10231
      public static _Fields findByThriftId(int fieldId) {
10232
        switch(fieldId) {
10233
          case 1: // WAREHOUSE_ID
10234
            return WAREHOUSE_ID;
10235
          default:
10236
            return null;
10237
        }
10238
      }
10239
 
10240
      /**
10241
       * Find the _Fields constant that matches fieldId, throwing an exception
10242
       * if it is not found.
10243
       */
10244
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10245
        _Fields fields = findByThriftId(fieldId);
10246
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10247
        return fields;
10248
      }
10249
 
10250
      /**
10251
       * Find the _Fields constant that matches name, or null if its not found.
10252
       */
10253
      public static _Fields findByName(String name) {
10254
        return byName.get(name);
10255
      }
10256
 
10257
      private final short _thriftId;
10258
      private final String _fieldName;
10259
 
10260
      _Fields(short thriftId, String fieldName) {
10261
        _thriftId = thriftId;
10262
        _fieldName = fieldName;
10263
      }
10264
 
10265
      public short getThriftFieldId() {
10266
        return _thriftId;
10267
      }
10268
 
10269
      public String getFieldName() {
10270
        return _fieldName;
10271
      }
10272
    }
10273
 
10274
    // isset id assignments
10275
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
10276
    private BitSet __isset_bit_vector = new BitSet(1);
10277
 
10278
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10279
    static {
10280
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10281
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10282
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10283
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10284
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouse_args.class, metaDataMap);
10285
    }
10286
 
10287
    public getWarehouse_args() {
10288
    }
10289
 
10290
    public getWarehouse_args(
10291
      long warehouse_id)
10292
    {
10293
      this();
10294
      this.warehouse_id = warehouse_id;
10295
      setWarehouse_idIsSet(true);
10296
    }
10297
 
10298
    /**
10299
     * Performs a deep copy on <i>other</i>.
10300
     */
10301
    public getWarehouse_args(getWarehouse_args other) {
10302
      __isset_bit_vector.clear();
10303
      __isset_bit_vector.or(other.__isset_bit_vector);
10304
      this.warehouse_id = other.warehouse_id;
10305
    }
10306
 
10307
    public getWarehouse_args deepCopy() {
10308
      return new getWarehouse_args(this);
10309
    }
10310
 
10311
    @Override
10312
    public void clear() {
10313
      setWarehouse_idIsSet(false);
10314
      this.warehouse_id = 0;
10315
    }
10316
 
10317
    public long getWarehouse_id() {
10318
      return this.warehouse_id;
10319
    }
10320
 
10321
    public void setWarehouse_id(long warehouse_id) {
10322
      this.warehouse_id = warehouse_id;
10323
      setWarehouse_idIsSet(true);
10324
    }
10325
 
10326
    public void unsetWarehouse_id() {
10327
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
10328
    }
10329
 
10330
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
10331
    public boolean isSetWarehouse_id() {
10332
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
10333
    }
10334
 
10335
    public void setWarehouse_idIsSet(boolean value) {
10336
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
10337
    }
10338
 
10339
    public void setFieldValue(_Fields field, Object value) {
10340
      switch (field) {
10341
      case WAREHOUSE_ID:
10342
        if (value == null) {
10343
          unsetWarehouse_id();
10344
        } else {
10345
          setWarehouse_id((Long)value);
10346
        }
10347
        break;
10348
 
10349
      }
10350
    }
10351
 
10352
    public Object getFieldValue(_Fields field) {
10353
      switch (field) {
10354
      case WAREHOUSE_ID:
10355
        return Long.valueOf(getWarehouse_id());
10356
 
10357
      }
10358
      throw new IllegalStateException();
10359
    }
10360
 
10361
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10362
    public boolean isSet(_Fields field) {
10363
      if (field == null) {
10364
        throw new IllegalArgumentException();
10365
      }
10366
 
10367
      switch (field) {
10368
      case WAREHOUSE_ID:
10369
        return isSetWarehouse_id();
10370
      }
10371
      throw new IllegalStateException();
10372
    }
10373
 
10374
    @Override
10375
    public boolean equals(Object that) {
10376
      if (that == null)
10377
        return false;
10378
      if (that instanceof getWarehouse_args)
10379
        return this.equals((getWarehouse_args)that);
10380
      return false;
10381
    }
10382
 
10383
    public boolean equals(getWarehouse_args that) {
10384
      if (that == null)
10385
        return false;
10386
 
10387
      boolean this_present_warehouse_id = true;
10388
      boolean that_present_warehouse_id = true;
10389
      if (this_present_warehouse_id || that_present_warehouse_id) {
10390
        if (!(this_present_warehouse_id && that_present_warehouse_id))
10391
          return false;
10392
        if (this.warehouse_id != that.warehouse_id)
10393
          return false;
10394
      }
10395
 
10396
      return true;
10397
    }
10398
 
10399
    @Override
10400
    public int hashCode() {
10401
      return 0;
10402
    }
10403
 
10404
    public int compareTo(getWarehouse_args other) {
10405
      if (!getClass().equals(other.getClass())) {
10406
        return getClass().getName().compareTo(other.getClass().getName());
10407
      }
10408
 
10409
      int lastComparison = 0;
10410
      getWarehouse_args typedOther = (getWarehouse_args)other;
10411
 
10412
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
10413
      if (lastComparison != 0) {
10414
        return lastComparison;
10415
      }
10416
      if (isSetWarehouse_id()) {
10417
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
10418
        if (lastComparison != 0) {
10419
          return lastComparison;
10420
        }
10421
      }
10422
      return 0;
10423
    }
10424
 
10425
    public _Fields fieldForId(int fieldId) {
10426
      return _Fields.findByThriftId(fieldId);
10427
    }
10428
 
10429
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10430
      org.apache.thrift.protocol.TField field;
10431
      iprot.readStructBegin();
10432
      while (true)
10433
      {
10434
        field = iprot.readFieldBegin();
10435
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10436
          break;
10437
        }
10438
        switch (field.id) {
10439
          case 1: // WAREHOUSE_ID
10440
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10441
              this.warehouse_id = iprot.readI64();
10442
              setWarehouse_idIsSet(true);
10443
            } else { 
10444
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10445
            }
10446
            break;
10447
          default:
10448
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10449
        }
10450
        iprot.readFieldEnd();
10451
      }
10452
      iprot.readStructEnd();
10453
      validate();
10454
    }
10455
 
10456
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10457
      validate();
10458
 
10459
      oprot.writeStructBegin(STRUCT_DESC);
10460
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
10461
      oprot.writeI64(this.warehouse_id);
10462
      oprot.writeFieldEnd();
10463
      oprot.writeFieldStop();
10464
      oprot.writeStructEnd();
10465
    }
10466
 
10467
    @Override
10468
    public String toString() {
10469
      StringBuilder sb = new StringBuilder("getWarehouse_args(");
10470
      boolean first = true;
10471
 
10472
      sb.append("warehouse_id:");
10473
      sb.append(this.warehouse_id);
10474
      first = false;
10475
      sb.append(")");
10476
      return sb.toString();
10477
    }
10478
 
10479
    public void validate() throws org.apache.thrift.TException {
10480
      // check for required fields
10481
    }
10482
 
10483
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10484
      try {
10485
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10486
      } catch (org.apache.thrift.TException te) {
10487
        throw new java.io.IOException(te);
10488
      }
10489
    }
10490
 
10491
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10492
      try {
10493
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
10494
        __isset_bit_vector = new BitSet(1);
10495
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10496
      } catch (org.apache.thrift.TException te) {
10497
        throw new java.io.IOException(te);
10498
      }
10499
    }
10500
 
10501
  }
10502
 
10503
  public static class getWarehouse_result implements org.apache.thrift.TBase<getWarehouse_result, getWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
10504
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouse_result");
10505
 
10506
    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);
10507
    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);
10508
 
10509
    private Warehouse success; // required
10510
    private InventoryServiceException cex; // required
10511
 
10512
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10513
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10514
      SUCCESS((short)0, "success"),
10515
      CEX((short)1, "cex");
10516
 
10517
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10518
 
10519
      static {
10520
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10521
          byName.put(field.getFieldName(), field);
10522
        }
10523
      }
10524
 
10525
      /**
10526
       * Find the _Fields constant that matches fieldId, or null if its not found.
10527
       */
10528
      public static _Fields findByThriftId(int fieldId) {
10529
        switch(fieldId) {
10530
          case 0: // SUCCESS
10531
            return SUCCESS;
10532
          case 1: // CEX
10533
            return CEX;
10534
          default:
10535
            return null;
10536
        }
10537
      }
10538
 
10539
      /**
10540
       * Find the _Fields constant that matches fieldId, throwing an exception
10541
       * if it is not found.
10542
       */
10543
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10544
        _Fields fields = findByThriftId(fieldId);
10545
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10546
        return fields;
10547
      }
10548
 
10549
      /**
10550
       * Find the _Fields constant that matches name, or null if its not found.
10551
       */
10552
      public static _Fields findByName(String name) {
10553
        return byName.get(name);
10554
      }
10555
 
10556
      private final short _thriftId;
10557
      private final String _fieldName;
10558
 
10559
      _Fields(short thriftId, String fieldName) {
10560
        _thriftId = thriftId;
10561
        _fieldName = fieldName;
10562
      }
10563
 
10564
      public short getThriftFieldId() {
10565
        return _thriftId;
10566
      }
10567
 
10568
      public String getFieldName() {
10569
        return _fieldName;
10570
      }
10571
    }
10572
 
10573
    // isset id assignments
10574
 
10575
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10576
    static {
10577
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10578
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10579
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class)));
10580
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10581
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
10582
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10583
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouse_result.class, metaDataMap);
10584
    }
10585
 
10586
    public getWarehouse_result() {
10587
    }
10588
 
10589
    public getWarehouse_result(
10590
      Warehouse success,
10591
      InventoryServiceException cex)
10592
    {
10593
      this();
10594
      this.success = success;
10595
      this.cex = cex;
10596
    }
10597
 
10598
    /**
10599
     * Performs a deep copy on <i>other</i>.
10600
     */
10601
    public getWarehouse_result(getWarehouse_result other) {
10602
      if (other.isSetSuccess()) {
10603
        this.success = new Warehouse(other.success);
10604
      }
10605
      if (other.isSetCex()) {
10606
        this.cex = new InventoryServiceException(other.cex);
10607
      }
10608
    }
10609
 
10610
    public getWarehouse_result deepCopy() {
10611
      return new getWarehouse_result(this);
10612
    }
10613
 
10614
    @Override
10615
    public void clear() {
10616
      this.success = null;
10617
      this.cex = null;
10618
    }
10619
 
10620
    public Warehouse getSuccess() {
10621
      return this.success;
10622
    }
10623
 
10624
    public void setSuccess(Warehouse success) {
10625
      this.success = success;
10626
    }
10627
 
10628
    public void unsetSuccess() {
10629
      this.success = null;
10630
    }
10631
 
10632
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
10633
    public boolean isSetSuccess() {
10634
      return this.success != null;
10635
    }
10636
 
10637
    public void setSuccessIsSet(boolean value) {
10638
      if (!value) {
10639
        this.success = null;
10640
      }
10641
    }
10642
 
10643
    public InventoryServiceException getCex() {
10644
      return this.cex;
10645
    }
10646
 
10647
    public void setCex(InventoryServiceException cex) {
10648
      this.cex = cex;
10649
    }
10650
 
10651
    public void unsetCex() {
10652
      this.cex = null;
10653
    }
10654
 
10655
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
10656
    public boolean isSetCex() {
10657
      return this.cex != null;
10658
    }
10659
 
10660
    public void setCexIsSet(boolean value) {
10661
      if (!value) {
10662
        this.cex = null;
10663
      }
10664
    }
10665
 
10666
    public void setFieldValue(_Fields field, Object value) {
10667
      switch (field) {
10668
      case SUCCESS:
10669
        if (value == null) {
10670
          unsetSuccess();
10671
        } else {
10672
          setSuccess((Warehouse)value);
10673
        }
10674
        break;
10675
 
10676
      case CEX:
10677
        if (value == null) {
10678
          unsetCex();
10679
        } else {
10680
          setCex((InventoryServiceException)value);
10681
        }
10682
        break;
10683
 
10684
      }
10685
    }
10686
 
10687
    public Object getFieldValue(_Fields field) {
10688
      switch (field) {
10689
      case SUCCESS:
10690
        return getSuccess();
10691
 
10692
      case CEX:
10693
        return getCex();
10694
 
10695
      }
10696
      throw new IllegalStateException();
10697
    }
10698
 
10699
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10700
    public boolean isSet(_Fields field) {
10701
      if (field == null) {
10702
        throw new IllegalArgumentException();
10703
      }
10704
 
10705
      switch (field) {
10706
      case SUCCESS:
10707
        return isSetSuccess();
10708
      case CEX:
10709
        return isSetCex();
10710
      }
10711
      throw new IllegalStateException();
10712
    }
10713
 
10714
    @Override
10715
    public boolean equals(Object that) {
10716
      if (that == null)
10717
        return false;
10718
      if (that instanceof getWarehouse_result)
10719
        return this.equals((getWarehouse_result)that);
10720
      return false;
10721
    }
10722
 
10723
    public boolean equals(getWarehouse_result that) {
10724
      if (that == null)
10725
        return false;
10726
 
10727
      boolean this_present_success = true && this.isSetSuccess();
10728
      boolean that_present_success = true && that.isSetSuccess();
10729
      if (this_present_success || that_present_success) {
10730
        if (!(this_present_success && that_present_success))
10731
          return false;
10732
        if (!this.success.equals(that.success))
10733
          return false;
10734
      }
10735
 
10736
      boolean this_present_cex = true && this.isSetCex();
10737
      boolean that_present_cex = true && that.isSetCex();
10738
      if (this_present_cex || that_present_cex) {
10739
        if (!(this_present_cex && that_present_cex))
10740
          return false;
10741
        if (!this.cex.equals(that.cex))
10742
          return false;
10743
      }
10744
 
10745
      return true;
10746
    }
10747
 
10748
    @Override
10749
    public int hashCode() {
10750
      return 0;
10751
    }
10752
 
10753
    public int compareTo(getWarehouse_result other) {
10754
      if (!getClass().equals(other.getClass())) {
10755
        return getClass().getName().compareTo(other.getClass().getName());
10756
      }
10757
 
10758
      int lastComparison = 0;
10759
      getWarehouse_result typedOther = (getWarehouse_result)other;
10760
 
10761
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10762
      if (lastComparison != 0) {
10763
        return lastComparison;
10764
      }
10765
      if (isSetSuccess()) {
10766
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10767
        if (lastComparison != 0) {
10768
          return lastComparison;
10769
        }
10770
      }
10771
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
10772
      if (lastComparison != 0) {
10773
        return lastComparison;
10774
      }
10775
      if (isSetCex()) {
10776
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
10777
        if (lastComparison != 0) {
10778
          return lastComparison;
10779
        }
10780
      }
10781
      return 0;
10782
    }
10783
 
10784
    public _Fields fieldForId(int fieldId) {
10785
      return _Fields.findByThriftId(fieldId);
10786
    }
10787
 
10788
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10789
      org.apache.thrift.protocol.TField field;
10790
      iprot.readStructBegin();
10791
      while (true)
10792
      {
10793
        field = iprot.readFieldBegin();
10794
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10795
          break;
10796
        }
10797
        switch (field.id) {
10798
          case 0: // SUCCESS
10799
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10800
              this.success = new Warehouse();
10801
              this.success.read(iprot);
10802
            } else { 
10803
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10804
            }
10805
            break;
10806
          case 1: // CEX
10807
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10808
              this.cex = new InventoryServiceException();
10809
              this.cex.read(iprot);
10810
            } else { 
10811
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10812
            }
10813
            break;
10814
          default:
10815
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10816
        }
10817
        iprot.readFieldEnd();
10818
      }
10819
      iprot.readStructEnd();
10820
      validate();
10821
    }
10822
 
10823
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10824
      oprot.writeStructBegin(STRUCT_DESC);
10825
 
10826
      if (this.isSetSuccess()) {
10827
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10828
        this.success.write(oprot);
10829
        oprot.writeFieldEnd();
10830
      } else if (this.isSetCex()) {
10831
        oprot.writeFieldBegin(CEX_FIELD_DESC);
10832
        this.cex.write(oprot);
10833
        oprot.writeFieldEnd();
10834
      }
10835
      oprot.writeFieldStop();
10836
      oprot.writeStructEnd();
10837
    }
10838
 
10839
    @Override
10840
    public String toString() {
10841
      StringBuilder sb = new StringBuilder("getWarehouse_result(");
10842
      boolean first = true;
10843
 
10844
      sb.append("success:");
10845
      if (this.success == null) {
10846
        sb.append("null");
10847
      } else {
10848
        sb.append(this.success);
10849
      }
10850
      first = false;
10851
      if (!first) sb.append(", ");
10852
      sb.append("cex:");
10853
      if (this.cex == null) {
10854
        sb.append("null");
10855
      } else {
10856
        sb.append(this.cex);
10857
      }
10858
      first = false;
10859
      sb.append(")");
10860
      return sb.toString();
10861
    }
10862
 
10863
    public void validate() throws org.apache.thrift.TException {
10864
      // check for required fields
10865
    }
10866
 
10867
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10868
      try {
10869
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10870
      } catch (org.apache.thrift.TException te) {
10871
        throw new java.io.IOException(te);
10872
      }
10873
    }
10874
 
10875
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10876
      try {
10877
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10878
      } catch (org.apache.thrift.TException te) {
10879
        throw new java.io.IOException(te);
10880
      }
10881
    }
10882
 
10883
  }
10884
 
10885
  public static class getAllItemsForWarehouse_args implements org.apache.thrift.TBase<getAllItemsForWarehouse_args, getAllItemsForWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
10886
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemsForWarehouse_args");
10887
 
10888
    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);
10889
 
10890
    private long warehouse_id; // required
10891
 
10892
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10893
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10894
      WAREHOUSE_ID((short)1, "warehouse_id");
10895
 
10896
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10897
 
10898
      static {
10899
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10900
          byName.put(field.getFieldName(), field);
10901
        }
10902
      }
10903
 
10904
      /**
10905
       * Find the _Fields constant that matches fieldId, or null if its not found.
10906
       */
10907
      public static _Fields findByThriftId(int fieldId) {
10908
        switch(fieldId) {
10909
          case 1: // WAREHOUSE_ID
10910
            return WAREHOUSE_ID;
10911
          default:
10912
            return null;
10913
        }
10914
      }
10915
 
10916
      /**
10917
       * Find the _Fields constant that matches fieldId, throwing an exception
10918
       * if it is not found.
10919
       */
10920
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10921
        _Fields fields = findByThriftId(fieldId);
10922
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10923
        return fields;
10924
      }
10925
 
10926
      /**
10927
       * Find the _Fields constant that matches name, or null if its not found.
10928
       */
10929
      public static _Fields findByName(String name) {
10930
        return byName.get(name);
10931
      }
10932
 
10933
      private final short _thriftId;
10934
      private final String _fieldName;
10935
 
10936
      _Fields(short thriftId, String fieldName) {
10937
        _thriftId = thriftId;
10938
        _fieldName = fieldName;
10939
      }
10940
 
10941
      public short getThriftFieldId() {
10942
        return _thriftId;
10943
      }
10944
 
10945
      public String getFieldName() {
10946
        return _fieldName;
10947
      }
10948
    }
10949
 
10950
    // isset id assignments
10951
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
10952
    private BitSet __isset_bit_vector = new BitSet(1);
10953
 
10954
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10955
    static {
10956
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10957
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10958
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10959
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10960
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemsForWarehouse_args.class, metaDataMap);
10961
    }
10962
 
10963
    public getAllItemsForWarehouse_args() {
10964
    }
10965
 
10966
    public getAllItemsForWarehouse_args(
10967
      long warehouse_id)
10968
    {
10969
      this();
10970
      this.warehouse_id = warehouse_id;
10971
      setWarehouse_idIsSet(true);
10972
    }
10973
 
10974
    /**
10975
     * Performs a deep copy on <i>other</i>.
10976
     */
10977
    public getAllItemsForWarehouse_args(getAllItemsForWarehouse_args other) {
10978
      __isset_bit_vector.clear();
10979
      __isset_bit_vector.or(other.__isset_bit_vector);
10980
      this.warehouse_id = other.warehouse_id;
10981
    }
10982
 
10983
    public getAllItemsForWarehouse_args deepCopy() {
10984
      return new getAllItemsForWarehouse_args(this);
10985
    }
10986
 
10987
    @Override
10988
    public void clear() {
10989
      setWarehouse_idIsSet(false);
10990
      this.warehouse_id = 0;
10991
    }
10992
 
10993
    public long getWarehouse_id() {
10994
      return this.warehouse_id;
10995
    }
10996
 
10997
    public void setWarehouse_id(long warehouse_id) {
10998
      this.warehouse_id = warehouse_id;
10999
      setWarehouse_idIsSet(true);
11000
    }
11001
 
11002
    public void unsetWarehouse_id() {
11003
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
11004
    }
11005
 
11006
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
11007
    public boolean isSetWarehouse_id() {
11008
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
11009
    }
11010
 
11011
    public void setWarehouse_idIsSet(boolean value) {
11012
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
11013
    }
11014
 
11015
    public void setFieldValue(_Fields field, Object value) {
11016
      switch (field) {
11017
      case WAREHOUSE_ID:
11018
        if (value == null) {
11019
          unsetWarehouse_id();
11020
        } else {
11021
          setWarehouse_id((Long)value);
11022
        }
11023
        break;
11024
 
11025
      }
11026
    }
11027
 
11028
    public Object getFieldValue(_Fields field) {
11029
      switch (field) {
11030
      case WAREHOUSE_ID:
11031
        return Long.valueOf(getWarehouse_id());
11032
 
11033
      }
11034
      throw new IllegalStateException();
11035
    }
11036
 
11037
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11038
    public boolean isSet(_Fields field) {
11039
      if (field == null) {
11040
        throw new IllegalArgumentException();
11041
      }
11042
 
11043
      switch (field) {
11044
      case WAREHOUSE_ID:
11045
        return isSetWarehouse_id();
11046
      }
11047
      throw new IllegalStateException();
11048
    }
11049
 
11050
    @Override
11051
    public boolean equals(Object that) {
11052
      if (that == null)
11053
        return false;
11054
      if (that instanceof getAllItemsForWarehouse_args)
11055
        return this.equals((getAllItemsForWarehouse_args)that);
11056
      return false;
11057
    }
11058
 
11059
    public boolean equals(getAllItemsForWarehouse_args that) {
11060
      if (that == null)
11061
        return false;
11062
 
11063
      boolean this_present_warehouse_id = true;
11064
      boolean that_present_warehouse_id = true;
11065
      if (this_present_warehouse_id || that_present_warehouse_id) {
11066
        if (!(this_present_warehouse_id && that_present_warehouse_id))
11067
          return false;
11068
        if (this.warehouse_id != that.warehouse_id)
11069
          return false;
11070
      }
11071
 
11072
      return true;
11073
    }
11074
 
11075
    @Override
11076
    public int hashCode() {
11077
      return 0;
11078
    }
11079
 
11080
    public int compareTo(getAllItemsForWarehouse_args other) {
11081
      if (!getClass().equals(other.getClass())) {
11082
        return getClass().getName().compareTo(other.getClass().getName());
11083
      }
11084
 
11085
      int lastComparison = 0;
11086
      getAllItemsForWarehouse_args typedOther = (getAllItemsForWarehouse_args)other;
11087
 
11088
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
11089
      if (lastComparison != 0) {
11090
        return lastComparison;
11091
      }
11092
      if (isSetWarehouse_id()) {
11093
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
11094
        if (lastComparison != 0) {
11095
          return lastComparison;
11096
        }
11097
      }
11098
      return 0;
11099
    }
11100
 
11101
    public _Fields fieldForId(int fieldId) {
11102
      return _Fields.findByThriftId(fieldId);
11103
    }
11104
 
11105
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11106
      org.apache.thrift.protocol.TField field;
11107
      iprot.readStructBegin();
11108
      while (true)
11109
      {
11110
        field = iprot.readFieldBegin();
11111
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11112
          break;
11113
        }
11114
        switch (field.id) {
11115
          case 1: // WAREHOUSE_ID
11116
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11117
              this.warehouse_id = iprot.readI64();
11118
              setWarehouse_idIsSet(true);
11119
            } else { 
11120
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11121
            }
11122
            break;
11123
          default:
11124
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11125
        }
11126
        iprot.readFieldEnd();
11127
      }
11128
      iprot.readStructEnd();
11129
      validate();
11130
    }
11131
 
11132
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11133
      validate();
11134
 
11135
      oprot.writeStructBegin(STRUCT_DESC);
11136
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
11137
      oprot.writeI64(this.warehouse_id);
11138
      oprot.writeFieldEnd();
11139
      oprot.writeFieldStop();
11140
      oprot.writeStructEnd();
11141
    }
11142
 
11143
    @Override
11144
    public String toString() {
11145
      StringBuilder sb = new StringBuilder("getAllItemsForWarehouse_args(");
11146
      boolean first = true;
11147
 
11148
      sb.append("warehouse_id:");
11149
      sb.append(this.warehouse_id);
11150
      first = false;
11151
      sb.append(")");
11152
      return sb.toString();
11153
    }
11154
 
11155
    public void validate() throws org.apache.thrift.TException {
11156
      // check for required fields
11157
    }
11158
 
11159
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11160
      try {
11161
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11162
      } catch (org.apache.thrift.TException te) {
11163
        throw new java.io.IOException(te);
11164
      }
11165
    }
11166
 
11167
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11168
      try {
11169
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
11170
        __isset_bit_vector = new BitSet(1);
11171
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11172
      } catch (org.apache.thrift.TException te) {
11173
        throw new java.io.IOException(te);
11174
      }
11175
    }
11176
 
11177
  }
11178
 
11179
  public static class getAllItemsForWarehouse_result implements org.apache.thrift.TBase<getAllItemsForWarehouse_result, getAllItemsForWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
11180
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemsForWarehouse_result");
11181
 
11182
    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);
11183
    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);
11184
 
11185
    private List<Long> success; // required
11186
    private InventoryServiceException cex; // required
11187
 
11188
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11189
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11190
      SUCCESS((short)0, "success"),
11191
      CEX((short)1, "cex");
11192
 
11193
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11194
 
11195
      static {
11196
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11197
          byName.put(field.getFieldName(), field);
11198
        }
11199
      }
11200
 
11201
      /**
11202
       * Find the _Fields constant that matches fieldId, or null if its not found.
11203
       */
11204
      public static _Fields findByThriftId(int fieldId) {
11205
        switch(fieldId) {
11206
          case 0: // SUCCESS
11207
            return SUCCESS;
11208
          case 1: // CEX
11209
            return CEX;
11210
          default:
11211
            return null;
11212
        }
11213
      }
11214
 
11215
      /**
11216
       * Find the _Fields constant that matches fieldId, throwing an exception
11217
       * if it is not found.
11218
       */
11219
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11220
        _Fields fields = findByThriftId(fieldId);
11221
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11222
        return fields;
11223
      }
11224
 
11225
      /**
11226
       * Find the _Fields constant that matches name, or null if its not found.
11227
       */
11228
      public static _Fields findByName(String name) {
11229
        return byName.get(name);
11230
      }
11231
 
11232
      private final short _thriftId;
11233
      private final String _fieldName;
11234
 
11235
      _Fields(short thriftId, String fieldName) {
11236
        _thriftId = thriftId;
11237
        _fieldName = fieldName;
11238
      }
11239
 
11240
      public short getThriftFieldId() {
11241
        return _thriftId;
11242
      }
11243
 
11244
      public String getFieldName() {
11245
        return _fieldName;
11246
      }
11247
    }
11248
 
11249
    // isset id assignments
11250
 
11251
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11252
    static {
11253
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11254
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11255
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
11256
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
11257
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11258
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
11259
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11260
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemsForWarehouse_result.class, metaDataMap);
11261
    }
11262
 
11263
    public getAllItemsForWarehouse_result() {
11264
    }
11265
 
11266
    public getAllItemsForWarehouse_result(
11267
      List<Long> success,
11268
      InventoryServiceException cex)
11269
    {
11270
      this();
11271
      this.success = success;
11272
      this.cex = cex;
11273
    }
11274
 
11275
    /**
11276
     * Performs a deep copy on <i>other</i>.
11277
     */
11278
    public getAllItemsForWarehouse_result(getAllItemsForWarehouse_result other) {
11279
      if (other.isSetSuccess()) {
11280
        List<Long> __this__success = new ArrayList<Long>();
11281
        for (Long other_element : other.success) {
11282
          __this__success.add(other_element);
11283
        }
11284
        this.success = __this__success;
11285
      }
11286
      if (other.isSetCex()) {
11287
        this.cex = new InventoryServiceException(other.cex);
11288
      }
11289
    }
11290
 
11291
    public getAllItemsForWarehouse_result deepCopy() {
11292
      return new getAllItemsForWarehouse_result(this);
11293
    }
11294
 
11295
    @Override
11296
    public void clear() {
11297
      this.success = null;
11298
      this.cex = null;
11299
    }
11300
 
11301
    public int getSuccessSize() {
11302
      return (this.success == null) ? 0 : this.success.size();
11303
    }
11304
 
11305
    public java.util.Iterator<Long> getSuccessIterator() {
11306
      return (this.success == null) ? null : this.success.iterator();
11307
    }
11308
 
11309
    public void addToSuccess(long elem) {
11310
      if (this.success == null) {
11311
        this.success = new ArrayList<Long>();
11312
      }
11313
      this.success.add(elem);
11314
    }
11315
 
11316
    public List<Long> getSuccess() {
11317
      return this.success;
11318
    }
11319
 
11320
    public void setSuccess(List<Long> success) {
11321
      this.success = success;
11322
    }
11323
 
11324
    public void unsetSuccess() {
11325
      this.success = null;
11326
    }
11327
 
11328
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
11329
    public boolean isSetSuccess() {
11330
      return this.success != null;
11331
    }
11332
 
11333
    public void setSuccessIsSet(boolean value) {
11334
      if (!value) {
11335
        this.success = null;
11336
      }
11337
    }
11338
 
11339
    public InventoryServiceException getCex() {
11340
      return this.cex;
11341
    }
11342
 
11343
    public void setCex(InventoryServiceException cex) {
11344
      this.cex = cex;
11345
    }
11346
 
11347
    public void unsetCex() {
11348
      this.cex = null;
11349
    }
11350
 
11351
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
11352
    public boolean isSetCex() {
11353
      return this.cex != null;
11354
    }
11355
 
11356
    public void setCexIsSet(boolean value) {
11357
      if (!value) {
11358
        this.cex = null;
11359
      }
11360
    }
11361
 
11362
    public void setFieldValue(_Fields field, Object value) {
11363
      switch (field) {
11364
      case SUCCESS:
11365
        if (value == null) {
11366
          unsetSuccess();
11367
        } else {
11368
          setSuccess((List<Long>)value);
11369
        }
11370
        break;
11371
 
11372
      case CEX:
11373
        if (value == null) {
11374
          unsetCex();
11375
        } else {
11376
          setCex((InventoryServiceException)value);
11377
        }
11378
        break;
11379
 
11380
      }
11381
    }
11382
 
11383
    public Object getFieldValue(_Fields field) {
11384
      switch (field) {
11385
      case SUCCESS:
11386
        return getSuccess();
11387
 
11388
      case CEX:
11389
        return getCex();
11390
 
11391
      }
11392
      throw new IllegalStateException();
11393
    }
11394
 
11395
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11396
    public boolean isSet(_Fields field) {
11397
      if (field == null) {
11398
        throw new IllegalArgumentException();
11399
      }
11400
 
11401
      switch (field) {
11402
      case SUCCESS:
11403
        return isSetSuccess();
11404
      case CEX:
11405
        return isSetCex();
11406
      }
11407
      throw new IllegalStateException();
11408
    }
11409
 
11410
    @Override
11411
    public boolean equals(Object that) {
11412
      if (that == null)
11413
        return false;
11414
      if (that instanceof getAllItemsForWarehouse_result)
11415
        return this.equals((getAllItemsForWarehouse_result)that);
11416
      return false;
11417
    }
11418
 
11419
    public boolean equals(getAllItemsForWarehouse_result that) {
11420
      if (that == null)
11421
        return false;
11422
 
11423
      boolean this_present_success = true && this.isSetSuccess();
11424
      boolean that_present_success = true && that.isSetSuccess();
11425
      if (this_present_success || that_present_success) {
11426
        if (!(this_present_success && that_present_success))
11427
          return false;
11428
        if (!this.success.equals(that.success))
11429
          return false;
11430
      }
11431
 
11432
      boolean this_present_cex = true && this.isSetCex();
11433
      boolean that_present_cex = true && that.isSetCex();
11434
      if (this_present_cex || that_present_cex) {
11435
        if (!(this_present_cex && that_present_cex))
11436
          return false;
11437
        if (!this.cex.equals(that.cex))
11438
          return false;
11439
      }
11440
 
11441
      return true;
11442
    }
11443
 
11444
    @Override
11445
    public int hashCode() {
11446
      return 0;
11447
    }
11448
 
11449
    public int compareTo(getAllItemsForWarehouse_result other) {
11450
      if (!getClass().equals(other.getClass())) {
11451
        return getClass().getName().compareTo(other.getClass().getName());
11452
      }
11453
 
11454
      int lastComparison = 0;
11455
      getAllItemsForWarehouse_result typedOther = (getAllItemsForWarehouse_result)other;
11456
 
11457
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
11458
      if (lastComparison != 0) {
11459
        return lastComparison;
11460
      }
11461
      if (isSetSuccess()) {
11462
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11463
        if (lastComparison != 0) {
11464
          return lastComparison;
11465
        }
11466
      }
11467
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
11468
      if (lastComparison != 0) {
11469
        return lastComparison;
11470
      }
11471
      if (isSetCex()) {
11472
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
11473
        if (lastComparison != 0) {
11474
          return lastComparison;
11475
        }
11476
      }
11477
      return 0;
11478
    }
11479
 
11480
    public _Fields fieldForId(int fieldId) {
11481
      return _Fields.findByThriftId(fieldId);
11482
    }
11483
 
11484
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11485
      org.apache.thrift.protocol.TField field;
11486
      iprot.readStructBegin();
11487
      while (true)
11488
      {
11489
        field = iprot.readFieldBegin();
11490
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11491
          break;
11492
        }
11493
        switch (field.id) {
11494
          case 0: // SUCCESS
11495
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
11496
              {
11497
                org.apache.thrift.protocol.TList _list28 = iprot.readListBegin();
11498
                this.success = new ArrayList<Long>(_list28.size);
11499
                for (int _i29 = 0; _i29 < _list28.size; ++_i29)
11500
                {
11501
                  long _elem30; // required
11502
                  _elem30 = iprot.readI64();
11503
                  this.success.add(_elem30);
11504
                }
11505
                iprot.readListEnd();
11506
              }
11507
            } else { 
11508
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11509
            }
11510
            break;
11511
          case 1: // CEX
11512
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11513
              this.cex = new InventoryServiceException();
11514
              this.cex.read(iprot);
11515
            } else { 
11516
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11517
            }
11518
            break;
11519
          default:
11520
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11521
        }
11522
        iprot.readFieldEnd();
11523
      }
11524
      iprot.readStructEnd();
11525
      validate();
11526
    }
11527
 
11528
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11529
      oprot.writeStructBegin(STRUCT_DESC);
11530
 
11531
      if (this.isSetSuccess()) {
11532
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11533
        {
11534
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
11535
          for (long _iter31 : this.success)
11536
          {
11537
            oprot.writeI64(_iter31);
11538
          }
11539
          oprot.writeListEnd();
11540
        }
11541
        oprot.writeFieldEnd();
11542
      } else if (this.isSetCex()) {
11543
        oprot.writeFieldBegin(CEX_FIELD_DESC);
11544
        this.cex.write(oprot);
11545
        oprot.writeFieldEnd();
11546
      }
11547
      oprot.writeFieldStop();
11548
      oprot.writeStructEnd();
11549
    }
11550
 
11551
    @Override
11552
    public String toString() {
11553
      StringBuilder sb = new StringBuilder("getAllItemsForWarehouse_result(");
11554
      boolean first = true;
11555
 
11556
      sb.append("success:");
11557
      if (this.success == null) {
11558
        sb.append("null");
11559
      } else {
11560
        sb.append(this.success);
11561
      }
11562
      first = false;
11563
      if (!first) sb.append(", ");
11564
      sb.append("cex:");
11565
      if (this.cex == null) {
11566
        sb.append("null");
11567
      } else {
11568
        sb.append(this.cex);
11569
      }
11570
      first = false;
11571
      sb.append(")");
11572
      return sb.toString();
11573
    }
11574
 
11575
    public void validate() throws org.apache.thrift.TException {
11576
      // check for required fields
11577
    }
11578
 
11579
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11580
      try {
11581
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11582
      } catch (org.apache.thrift.TException te) {
11583
        throw new java.io.IOException(te);
11584
      }
11585
    }
11586
 
11587
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11588
      try {
11589
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11590
      } catch (org.apache.thrift.TException te) {
11591
        throw new java.io.IOException(te);
11592
      }
11593
    }
11594
 
11595
  }
11596
 
11597
  public static class reserveItemInWarehouse_args implements org.apache.thrift.TBase<reserveItemInWarehouse_args, reserveItemInWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
11598
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reserveItemInWarehouse_args");
11599
 
11600
    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);
11601
    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);
11602
    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)3);
11603
 
11604
    private long itemId; // required
11605
    private long warehouseId; // required
11606
    private double quantity; // required
11607
 
11608
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11609
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11610
      ITEM_ID((short)1, "itemId"),
11611
      WAREHOUSE_ID((short)2, "warehouseId"),
11612
      QUANTITY((short)3, "quantity");
11613
 
11614
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11615
 
11616
      static {
11617
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11618
          byName.put(field.getFieldName(), field);
11619
        }
11620
      }
11621
 
11622
      /**
11623
       * Find the _Fields constant that matches fieldId, or null if its not found.
11624
       */
11625
      public static _Fields findByThriftId(int fieldId) {
11626
        switch(fieldId) {
11627
          case 1: // ITEM_ID
11628
            return ITEM_ID;
11629
          case 2: // WAREHOUSE_ID
11630
            return WAREHOUSE_ID;
11631
          case 3: // QUANTITY
11632
            return QUANTITY;
11633
          default:
11634
            return null;
11635
        }
11636
      }
11637
 
11638
      /**
11639
       * Find the _Fields constant that matches fieldId, throwing an exception
11640
       * if it is not found.
11641
       */
11642
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11643
        _Fields fields = findByThriftId(fieldId);
11644
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11645
        return fields;
11646
      }
11647
 
11648
      /**
11649
       * Find the _Fields constant that matches name, or null if its not found.
11650
       */
11651
      public static _Fields findByName(String name) {
11652
        return byName.get(name);
11653
      }
11654
 
11655
      private final short _thriftId;
11656
      private final String _fieldName;
11657
 
11658
      _Fields(short thriftId, String fieldName) {
11659
        _thriftId = thriftId;
11660
        _fieldName = fieldName;
11661
      }
11662
 
11663
      public short getThriftFieldId() {
11664
        return _thriftId;
11665
      }
11666
 
11667
      public String getFieldName() {
11668
        return _fieldName;
11669
      }
11670
    }
11671
 
11672
    // isset id assignments
11673
    private static final int __ITEMID_ISSET_ID = 0;
11674
    private static final int __WAREHOUSEID_ISSET_ID = 1;
11675
    private static final int __QUANTITY_ISSET_ID = 2;
11676
    private BitSet __isset_bit_vector = new BitSet(3);
11677
 
11678
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11679
    static {
11680
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11681
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11682
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11683
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11684
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11685
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11686
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
11687
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11688
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reserveItemInWarehouse_args.class, metaDataMap);
11689
    }
11690
 
11691
    public reserveItemInWarehouse_args() {
11692
    }
11693
 
11694
    public reserveItemInWarehouse_args(
11695
      long itemId,
11696
      long warehouseId,
11697
      double quantity)
11698
    {
11699
      this();
11700
      this.itemId = itemId;
11701
      setItemIdIsSet(true);
11702
      this.warehouseId = warehouseId;
11703
      setWarehouseIdIsSet(true);
11704
      this.quantity = quantity;
11705
      setQuantityIsSet(true);
11706
    }
11707
 
11708
    /**
11709
     * Performs a deep copy on <i>other</i>.
11710
     */
11711
    public reserveItemInWarehouse_args(reserveItemInWarehouse_args other) {
11712
      __isset_bit_vector.clear();
11713
      __isset_bit_vector.or(other.__isset_bit_vector);
11714
      this.itemId = other.itemId;
11715
      this.warehouseId = other.warehouseId;
11716
      this.quantity = other.quantity;
11717
    }
11718
 
11719
    public reserveItemInWarehouse_args deepCopy() {
11720
      return new reserveItemInWarehouse_args(this);
11721
    }
11722
 
11723
    @Override
11724
    public void clear() {
11725
      setItemIdIsSet(false);
11726
      this.itemId = 0;
11727
      setWarehouseIdIsSet(false);
11728
      this.warehouseId = 0;
11729
      setQuantityIsSet(false);
11730
      this.quantity = 0.0;
11731
    }
11732
 
11733
    public long getItemId() {
11734
      return this.itemId;
11735
    }
11736
 
11737
    public void setItemId(long itemId) {
11738
      this.itemId = itemId;
11739
      setItemIdIsSet(true);
11740
    }
11741
 
11742
    public void unsetItemId() {
11743
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
11744
    }
11745
 
11746
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
11747
    public boolean isSetItemId() {
11748
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
11749
    }
11750
 
11751
    public void setItemIdIsSet(boolean value) {
11752
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
11753
    }
11754
 
11755
    public long getWarehouseId() {
11756
      return this.warehouseId;
11757
    }
11758
 
11759
    public void setWarehouseId(long warehouseId) {
11760
      this.warehouseId = warehouseId;
11761
      setWarehouseIdIsSet(true);
11762
    }
11763
 
11764
    public void unsetWarehouseId() {
11765
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
11766
    }
11767
 
11768
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
11769
    public boolean isSetWarehouseId() {
11770
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
11771
    }
11772
 
11773
    public void setWarehouseIdIsSet(boolean value) {
11774
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
11775
    }
11776
 
11777
    public double getQuantity() {
11778
      return this.quantity;
11779
    }
11780
 
11781
    public void setQuantity(double quantity) {
11782
      this.quantity = quantity;
11783
      setQuantityIsSet(true);
11784
    }
11785
 
11786
    public void unsetQuantity() {
11787
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
11788
    }
11789
 
11790
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
11791
    public boolean isSetQuantity() {
11792
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
11793
    }
11794
 
11795
    public void setQuantityIsSet(boolean value) {
11796
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
11797
    }
11798
 
11799
    public void setFieldValue(_Fields field, Object value) {
11800
      switch (field) {
11801
      case ITEM_ID:
11802
        if (value == null) {
11803
          unsetItemId();
11804
        } else {
11805
          setItemId((Long)value);
11806
        }
11807
        break;
11808
 
11809
      case WAREHOUSE_ID:
11810
        if (value == null) {
11811
          unsetWarehouseId();
11812
        } else {
11813
          setWarehouseId((Long)value);
11814
        }
11815
        break;
11816
 
11817
      case QUANTITY:
11818
        if (value == null) {
11819
          unsetQuantity();
11820
        } else {
11821
          setQuantity((Double)value);
11822
        }
11823
        break;
11824
 
11825
      }
11826
    }
11827
 
11828
    public Object getFieldValue(_Fields field) {
11829
      switch (field) {
11830
      case ITEM_ID:
11831
        return Long.valueOf(getItemId());
11832
 
11833
      case WAREHOUSE_ID:
11834
        return Long.valueOf(getWarehouseId());
11835
 
11836
      case QUANTITY:
11837
        return Double.valueOf(getQuantity());
11838
 
11839
      }
11840
      throw new IllegalStateException();
11841
    }
11842
 
11843
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11844
    public boolean isSet(_Fields field) {
11845
      if (field == null) {
11846
        throw new IllegalArgumentException();
11847
      }
11848
 
11849
      switch (field) {
11850
      case ITEM_ID:
11851
        return isSetItemId();
11852
      case WAREHOUSE_ID:
11853
        return isSetWarehouseId();
11854
      case QUANTITY:
11855
        return isSetQuantity();
11856
      }
11857
      throw new IllegalStateException();
11858
    }
11859
 
11860
    @Override
11861
    public boolean equals(Object that) {
11862
      if (that == null)
11863
        return false;
11864
      if (that instanceof reserveItemInWarehouse_args)
11865
        return this.equals((reserveItemInWarehouse_args)that);
11866
      return false;
11867
    }
11868
 
11869
    public boolean equals(reserveItemInWarehouse_args that) {
11870
      if (that == null)
11871
        return false;
11872
 
11873
      boolean this_present_itemId = true;
11874
      boolean that_present_itemId = true;
11875
      if (this_present_itemId || that_present_itemId) {
11876
        if (!(this_present_itemId && that_present_itemId))
11877
          return false;
11878
        if (this.itemId != that.itemId)
11879
          return false;
11880
      }
11881
 
11882
      boolean this_present_warehouseId = true;
11883
      boolean that_present_warehouseId = true;
11884
      if (this_present_warehouseId || that_present_warehouseId) {
11885
        if (!(this_present_warehouseId && that_present_warehouseId))
11886
          return false;
11887
        if (this.warehouseId != that.warehouseId)
11888
          return false;
11889
      }
11890
 
11891
      boolean this_present_quantity = true;
11892
      boolean that_present_quantity = true;
11893
      if (this_present_quantity || that_present_quantity) {
11894
        if (!(this_present_quantity && that_present_quantity))
11895
          return false;
11896
        if (this.quantity != that.quantity)
11897
          return false;
11898
      }
11899
 
11900
      return true;
11901
    }
11902
 
11903
    @Override
11904
    public int hashCode() {
11905
      return 0;
11906
    }
11907
 
11908
    public int compareTo(reserveItemInWarehouse_args other) {
11909
      if (!getClass().equals(other.getClass())) {
11910
        return getClass().getName().compareTo(other.getClass().getName());
11911
      }
11912
 
11913
      int lastComparison = 0;
11914
      reserveItemInWarehouse_args typedOther = (reserveItemInWarehouse_args)other;
11915
 
11916
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
11917
      if (lastComparison != 0) {
11918
        return lastComparison;
11919
      }
11920
      if (isSetItemId()) {
11921
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
11922
        if (lastComparison != 0) {
11923
          return lastComparison;
11924
        }
11925
      }
11926
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
11927
      if (lastComparison != 0) {
11928
        return lastComparison;
11929
      }
11930
      if (isSetWarehouseId()) {
11931
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
11932
        if (lastComparison != 0) {
11933
          return lastComparison;
11934
        }
11935
      }
11936
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
11937
      if (lastComparison != 0) {
11938
        return lastComparison;
11939
      }
11940
      if (isSetQuantity()) {
11941
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
11942
        if (lastComparison != 0) {
11943
          return lastComparison;
11944
        }
11945
      }
11946
      return 0;
11947
    }
11948
 
11949
    public _Fields fieldForId(int fieldId) {
11950
      return _Fields.findByThriftId(fieldId);
11951
    }
11952
 
11953
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11954
      org.apache.thrift.protocol.TField field;
11955
      iprot.readStructBegin();
11956
      while (true)
11957
      {
11958
        field = iprot.readFieldBegin();
11959
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11960
          break;
11961
        }
11962
        switch (field.id) {
11963
          case 1: // ITEM_ID
11964
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11965
              this.itemId = iprot.readI64();
11966
              setItemIdIsSet(true);
11967
            } else { 
11968
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11969
            }
11970
            break;
11971
          case 2: // WAREHOUSE_ID
11972
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11973
              this.warehouseId = iprot.readI64();
11974
              setWarehouseIdIsSet(true);
11975
            } else { 
11976
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11977
            }
11978
            break;
11979
          case 3: // QUANTITY
11980
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
11981
              this.quantity = iprot.readDouble();
11982
              setQuantityIsSet(true);
11983
            } else { 
11984
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11985
            }
11986
            break;
11987
          default:
11988
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11989
        }
11990
        iprot.readFieldEnd();
11991
      }
11992
      iprot.readStructEnd();
11993
      validate();
11994
    }
11995
 
11996
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11997
      validate();
11998
 
11999
      oprot.writeStructBegin(STRUCT_DESC);
12000
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
12001
      oprot.writeI64(this.itemId);
12002
      oprot.writeFieldEnd();
12003
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
12004
      oprot.writeI64(this.warehouseId);
12005
      oprot.writeFieldEnd();
12006
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
12007
      oprot.writeDouble(this.quantity);
12008
      oprot.writeFieldEnd();
12009
      oprot.writeFieldStop();
12010
      oprot.writeStructEnd();
12011
    }
12012
 
12013
    @Override
12014
    public String toString() {
12015
      StringBuilder sb = new StringBuilder("reserveItemInWarehouse_args(");
12016
      boolean first = true;
12017
 
12018
      sb.append("itemId:");
12019
      sb.append(this.itemId);
12020
      first = false;
12021
      if (!first) sb.append(", ");
12022
      sb.append("warehouseId:");
12023
      sb.append(this.warehouseId);
12024
      first = false;
12025
      if (!first) sb.append(", ");
12026
      sb.append("quantity:");
12027
      sb.append(this.quantity);
12028
      first = false;
12029
      sb.append(")");
12030
      return sb.toString();
12031
    }
12032
 
12033
    public void validate() throws org.apache.thrift.TException {
12034
      // check for required fields
12035
    }
12036
 
12037
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12038
      try {
12039
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12040
      } catch (org.apache.thrift.TException te) {
12041
        throw new java.io.IOException(te);
12042
      }
12043
    }
12044
 
12045
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12046
      try {
12047
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12048
      } catch (org.apache.thrift.TException te) {
12049
        throw new java.io.IOException(te);
12050
      }
12051
    }
12052
 
12053
  }
12054
 
12055
  public static class reserveItemInWarehouse_result implements org.apache.thrift.TBase<reserveItemInWarehouse_result, reserveItemInWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
12056
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reserveItemInWarehouse_result");
12057
 
12058
    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);
12059
    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);
12060
 
12061
    private boolean success; // required
12062
    private InventoryServiceException cex; // required
12063
 
12064
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12065
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12066
      SUCCESS((short)0, "success"),
12067
      CEX((short)1, "cex");
12068
 
12069
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12070
 
12071
      static {
12072
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12073
          byName.put(field.getFieldName(), field);
12074
        }
12075
      }
12076
 
12077
      /**
12078
       * Find the _Fields constant that matches fieldId, or null if its not found.
12079
       */
12080
      public static _Fields findByThriftId(int fieldId) {
12081
        switch(fieldId) {
12082
          case 0: // SUCCESS
12083
            return SUCCESS;
12084
          case 1: // CEX
12085
            return CEX;
12086
          default:
12087
            return null;
12088
        }
12089
      }
12090
 
12091
      /**
12092
       * Find the _Fields constant that matches fieldId, throwing an exception
12093
       * if it is not found.
12094
       */
12095
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12096
        _Fields fields = findByThriftId(fieldId);
12097
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12098
        return fields;
12099
      }
12100
 
12101
      /**
12102
       * Find the _Fields constant that matches name, or null if its not found.
12103
       */
12104
      public static _Fields findByName(String name) {
12105
        return byName.get(name);
12106
      }
12107
 
12108
      private final short _thriftId;
12109
      private final String _fieldName;
12110
 
12111
      _Fields(short thriftId, String fieldName) {
12112
        _thriftId = thriftId;
12113
        _fieldName = fieldName;
12114
      }
12115
 
12116
      public short getThriftFieldId() {
12117
        return _thriftId;
12118
      }
12119
 
12120
      public String getFieldName() {
12121
        return _fieldName;
12122
      }
12123
    }
12124
 
12125
    // isset id assignments
12126
    private static final int __SUCCESS_ISSET_ID = 0;
12127
    private BitSet __isset_bit_vector = new BitSet(1);
12128
 
12129
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12130
    static {
12131
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12132
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12133
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
12134
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12135
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
12136
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12137
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reserveItemInWarehouse_result.class, metaDataMap);
12138
    }
12139
 
12140
    public reserveItemInWarehouse_result() {
12141
    }
12142
 
12143
    public reserveItemInWarehouse_result(
12144
      boolean success,
12145
      InventoryServiceException cex)
12146
    {
12147
      this();
12148
      this.success = success;
12149
      setSuccessIsSet(true);
12150
      this.cex = cex;
12151
    }
12152
 
12153
    /**
12154
     * Performs a deep copy on <i>other</i>.
12155
     */
12156
    public reserveItemInWarehouse_result(reserveItemInWarehouse_result other) {
12157
      __isset_bit_vector.clear();
12158
      __isset_bit_vector.or(other.__isset_bit_vector);
12159
      this.success = other.success;
12160
      if (other.isSetCex()) {
12161
        this.cex = new InventoryServiceException(other.cex);
12162
      }
12163
    }
12164
 
12165
    public reserveItemInWarehouse_result deepCopy() {
12166
      return new reserveItemInWarehouse_result(this);
12167
    }
12168
 
12169
    @Override
12170
    public void clear() {
12171
      setSuccessIsSet(false);
12172
      this.success = false;
12173
      this.cex = null;
12174
    }
12175
 
12176
    public boolean isSuccess() {
12177
      return this.success;
12178
    }
12179
 
12180
    public void setSuccess(boolean success) {
12181
      this.success = success;
12182
      setSuccessIsSet(true);
12183
    }
12184
 
12185
    public void unsetSuccess() {
12186
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
12187
    }
12188
 
12189
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
12190
    public boolean isSetSuccess() {
12191
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
12192
    }
12193
 
12194
    public void setSuccessIsSet(boolean value) {
12195
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
12196
    }
12197
 
12198
    public InventoryServiceException getCex() {
12199
      return this.cex;
12200
    }
12201
 
12202
    public void setCex(InventoryServiceException cex) {
12203
      this.cex = cex;
12204
    }
12205
 
12206
    public void unsetCex() {
12207
      this.cex = null;
12208
    }
12209
 
12210
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
12211
    public boolean isSetCex() {
12212
      return this.cex != null;
12213
    }
12214
 
12215
    public void setCexIsSet(boolean value) {
12216
      if (!value) {
12217
        this.cex = null;
12218
      }
12219
    }
12220
 
12221
    public void setFieldValue(_Fields field, Object value) {
12222
      switch (field) {
12223
      case SUCCESS:
12224
        if (value == null) {
12225
          unsetSuccess();
12226
        } else {
12227
          setSuccess((Boolean)value);
12228
        }
12229
        break;
12230
 
12231
      case CEX:
12232
        if (value == null) {
12233
          unsetCex();
12234
        } else {
12235
          setCex((InventoryServiceException)value);
12236
        }
12237
        break;
12238
 
12239
      }
12240
    }
12241
 
12242
    public Object getFieldValue(_Fields field) {
12243
      switch (field) {
12244
      case SUCCESS:
12245
        return Boolean.valueOf(isSuccess());
12246
 
12247
      case CEX:
12248
        return getCex();
12249
 
12250
      }
12251
      throw new IllegalStateException();
12252
    }
12253
 
12254
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12255
    public boolean isSet(_Fields field) {
12256
      if (field == null) {
12257
        throw new IllegalArgumentException();
12258
      }
12259
 
12260
      switch (field) {
12261
      case SUCCESS:
12262
        return isSetSuccess();
12263
      case CEX:
12264
        return isSetCex();
12265
      }
12266
      throw new IllegalStateException();
12267
    }
12268
 
12269
    @Override
12270
    public boolean equals(Object that) {
12271
      if (that == null)
12272
        return false;
12273
      if (that instanceof reserveItemInWarehouse_result)
12274
        return this.equals((reserveItemInWarehouse_result)that);
12275
      return false;
12276
    }
12277
 
12278
    public boolean equals(reserveItemInWarehouse_result that) {
12279
      if (that == null)
12280
        return false;
12281
 
12282
      boolean this_present_success = true;
12283
      boolean that_present_success = true;
12284
      if (this_present_success || that_present_success) {
12285
        if (!(this_present_success && that_present_success))
12286
          return false;
12287
        if (this.success != that.success)
12288
          return false;
12289
      }
12290
 
12291
      boolean this_present_cex = true && this.isSetCex();
12292
      boolean that_present_cex = true && that.isSetCex();
12293
      if (this_present_cex || that_present_cex) {
12294
        if (!(this_present_cex && that_present_cex))
12295
          return false;
12296
        if (!this.cex.equals(that.cex))
12297
          return false;
12298
      }
12299
 
12300
      return true;
12301
    }
12302
 
12303
    @Override
12304
    public int hashCode() {
12305
      return 0;
12306
    }
12307
 
12308
    public int compareTo(reserveItemInWarehouse_result other) {
12309
      if (!getClass().equals(other.getClass())) {
12310
        return getClass().getName().compareTo(other.getClass().getName());
12311
      }
12312
 
12313
      int lastComparison = 0;
12314
      reserveItemInWarehouse_result typedOther = (reserveItemInWarehouse_result)other;
12315
 
12316
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
12317
      if (lastComparison != 0) {
12318
        return lastComparison;
12319
      }
12320
      if (isSetSuccess()) {
12321
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
12322
        if (lastComparison != 0) {
12323
          return lastComparison;
12324
        }
12325
      }
12326
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
12327
      if (lastComparison != 0) {
12328
        return lastComparison;
12329
      }
12330
      if (isSetCex()) {
12331
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
12332
        if (lastComparison != 0) {
12333
          return lastComparison;
12334
        }
12335
      }
12336
      return 0;
12337
    }
12338
 
12339
    public _Fields fieldForId(int fieldId) {
12340
      return _Fields.findByThriftId(fieldId);
12341
    }
12342
 
12343
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12344
      org.apache.thrift.protocol.TField field;
12345
      iprot.readStructBegin();
12346
      while (true)
12347
      {
12348
        field = iprot.readFieldBegin();
12349
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12350
          break;
12351
        }
12352
        switch (field.id) {
12353
          case 0: // SUCCESS
12354
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
12355
              this.success = iprot.readBool();
12356
              setSuccessIsSet(true);
12357
            } else { 
12358
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12359
            }
12360
            break;
12361
          case 1: // CEX
12362
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
12363
              this.cex = new InventoryServiceException();
12364
              this.cex.read(iprot);
12365
            } else { 
12366
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12367
            }
12368
            break;
12369
          default:
12370
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12371
        }
12372
        iprot.readFieldEnd();
12373
      }
12374
      iprot.readStructEnd();
12375
      validate();
12376
    }
12377
 
12378
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12379
      oprot.writeStructBegin(STRUCT_DESC);
12380
 
12381
      if (this.isSetSuccess()) {
12382
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
12383
        oprot.writeBool(this.success);
12384
        oprot.writeFieldEnd();
12385
      } else if (this.isSetCex()) {
12386
        oprot.writeFieldBegin(CEX_FIELD_DESC);
12387
        this.cex.write(oprot);
12388
        oprot.writeFieldEnd();
12389
      }
12390
      oprot.writeFieldStop();
12391
      oprot.writeStructEnd();
12392
    }
12393
 
12394
    @Override
12395
    public String toString() {
12396
      StringBuilder sb = new StringBuilder("reserveItemInWarehouse_result(");
12397
      boolean first = true;
12398
 
12399
      sb.append("success:");
12400
      sb.append(this.success);
12401
      first = false;
12402
      if (!first) sb.append(", ");
12403
      sb.append("cex:");
12404
      if (this.cex == null) {
12405
        sb.append("null");
12406
      } else {
12407
        sb.append(this.cex);
12408
      }
12409
      first = false;
12410
      sb.append(")");
12411
      return sb.toString();
12412
    }
12413
 
12414
    public void validate() throws org.apache.thrift.TException {
12415
      // check for required fields
12416
    }
12417
 
12418
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12419
      try {
12420
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12421
      } catch (org.apache.thrift.TException te) {
12422
        throw new java.io.IOException(te);
12423
      }
12424
    }
12425
 
12426
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12427
      try {
12428
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12429
      } catch (org.apache.thrift.TException te) {
12430
        throw new java.io.IOException(te);
12431
      }
12432
    }
12433
 
12434
  }
12435
 
12436
  public static class reduceReservationCount_args implements org.apache.thrift.TBase<reduceReservationCount_args, reduceReservationCount_args._Fields>, java.io.Serializable, Cloneable   {
12437
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reduceReservationCount_args");
12438
 
12439
    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);
12440
    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);
12441
    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)3);
12442
 
12443
    private long itemId; // required
12444
    private long warehouseId; // required
12445
    private double quantity; // required
12446
 
12447
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12448
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12449
      ITEM_ID((short)1, "itemId"),
12450
      WAREHOUSE_ID((short)2, "warehouseId"),
12451
      QUANTITY((short)3, "quantity");
12452
 
12453
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12454
 
12455
      static {
12456
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12457
          byName.put(field.getFieldName(), field);
12458
        }
12459
      }
12460
 
12461
      /**
12462
       * Find the _Fields constant that matches fieldId, or null if its not found.
12463
       */
12464
      public static _Fields findByThriftId(int fieldId) {
12465
        switch(fieldId) {
12466
          case 1: // ITEM_ID
12467
            return ITEM_ID;
12468
          case 2: // WAREHOUSE_ID
12469
            return WAREHOUSE_ID;
12470
          case 3: // QUANTITY
12471
            return QUANTITY;
12472
          default:
12473
            return null;
12474
        }
12475
      }
12476
 
12477
      /**
12478
       * Find the _Fields constant that matches fieldId, throwing an exception
12479
       * if it is not found.
12480
       */
12481
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12482
        _Fields fields = findByThriftId(fieldId);
12483
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12484
        return fields;
12485
      }
12486
 
12487
      /**
12488
       * Find the _Fields constant that matches name, or null if its not found.
12489
       */
12490
      public static _Fields findByName(String name) {
12491
        return byName.get(name);
12492
      }
12493
 
12494
      private final short _thriftId;
12495
      private final String _fieldName;
12496
 
12497
      _Fields(short thriftId, String fieldName) {
12498
        _thriftId = thriftId;
12499
        _fieldName = fieldName;
12500
      }
12501
 
12502
      public short getThriftFieldId() {
12503
        return _thriftId;
12504
      }
12505
 
12506
      public String getFieldName() {
12507
        return _fieldName;
12508
      }
12509
    }
12510
 
12511
    // isset id assignments
12512
    private static final int __ITEMID_ISSET_ID = 0;
12513
    private static final int __WAREHOUSEID_ISSET_ID = 1;
12514
    private static final int __QUANTITY_ISSET_ID = 2;
12515
    private BitSet __isset_bit_vector = new BitSet(3);
12516
 
12517
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12518
    static {
12519
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12520
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12521
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12522
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12523
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12524
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12525
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
12526
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12527
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reduceReservationCount_args.class, metaDataMap);
12528
    }
12529
 
12530
    public reduceReservationCount_args() {
12531
    }
12532
 
12533
    public reduceReservationCount_args(
12534
      long itemId,
12535
      long warehouseId,
12536
      double quantity)
12537
    {
12538
      this();
12539
      this.itemId = itemId;
12540
      setItemIdIsSet(true);
12541
      this.warehouseId = warehouseId;
12542
      setWarehouseIdIsSet(true);
12543
      this.quantity = quantity;
12544
      setQuantityIsSet(true);
12545
    }
12546
 
12547
    /**
12548
     * Performs a deep copy on <i>other</i>.
12549
     */
12550
    public reduceReservationCount_args(reduceReservationCount_args other) {
12551
      __isset_bit_vector.clear();
12552
      __isset_bit_vector.or(other.__isset_bit_vector);
12553
      this.itemId = other.itemId;
12554
      this.warehouseId = other.warehouseId;
12555
      this.quantity = other.quantity;
12556
    }
12557
 
12558
    public reduceReservationCount_args deepCopy() {
12559
      return new reduceReservationCount_args(this);
12560
    }
12561
 
12562
    @Override
12563
    public void clear() {
12564
      setItemIdIsSet(false);
12565
      this.itemId = 0;
12566
      setWarehouseIdIsSet(false);
12567
      this.warehouseId = 0;
12568
      setQuantityIsSet(false);
12569
      this.quantity = 0.0;
12570
    }
12571
 
12572
    public long getItemId() {
12573
      return this.itemId;
12574
    }
12575
 
12576
    public void setItemId(long itemId) {
12577
      this.itemId = itemId;
12578
      setItemIdIsSet(true);
12579
    }
12580
 
12581
    public void unsetItemId() {
12582
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
12583
    }
12584
 
12585
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
12586
    public boolean isSetItemId() {
12587
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
12588
    }
12589
 
12590
    public void setItemIdIsSet(boolean value) {
12591
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
12592
    }
12593
 
12594
    public long getWarehouseId() {
12595
      return this.warehouseId;
12596
    }
12597
 
12598
    public void setWarehouseId(long warehouseId) {
12599
      this.warehouseId = warehouseId;
12600
      setWarehouseIdIsSet(true);
12601
    }
12602
 
12603
    public void unsetWarehouseId() {
12604
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
12605
    }
12606
 
12607
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
12608
    public boolean isSetWarehouseId() {
12609
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
12610
    }
12611
 
12612
    public void setWarehouseIdIsSet(boolean value) {
12613
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
12614
    }
12615
 
12616
    public double getQuantity() {
12617
      return this.quantity;
12618
    }
12619
 
12620
    public void setQuantity(double quantity) {
12621
      this.quantity = quantity;
12622
      setQuantityIsSet(true);
12623
    }
12624
 
12625
    public void unsetQuantity() {
12626
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
12627
    }
12628
 
12629
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
12630
    public boolean isSetQuantity() {
12631
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
12632
    }
12633
 
12634
    public void setQuantityIsSet(boolean value) {
12635
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
12636
    }
12637
 
12638
    public void setFieldValue(_Fields field, Object value) {
12639
      switch (field) {
12640
      case ITEM_ID:
12641
        if (value == null) {
12642
          unsetItemId();
12643
        } else {
12644
          setItemId((Long)value);
12645
        }
12646
        break;
12647
 
12648
      case WAREHOUSE_ID:
12649
        if (value == null) {
12650
          unsetWarehouseId();
12651
        } else {
12652
          setWarehouseId((Long)value);
12653
        }
12654
        break;
12655
 
12656
      case QUANTITY:
12657
        if (value == null) {
12658
          unsetQuantity();
12659
        } else {
12660
          setQuantity((Double)value);
12661
        }
12662
        break;
12663
 
12664
      }
12665
    }
12666
 
12667
    public Object getFieldValue(_Fields field) {
12668
      switch (field) {
12669
      case ITEM_ID:
12670
        return Long.valueOf(getItemId());
12671
 
12672
      case WAREHOUSE_ID:
12673
        return Long.valueOf(getWarehouseId());
12674
 
12675
      case QUANTITY:
12676
        return Double.valueOf(getQuantity());
12677
 
12678
      }
12679
      throw new IllegalStateException();
12680
    }
12681
 
12682
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12683
    public boolean isSet(_Fields field) {
12684
      if (field == null) {
12685
        throw new IllegalArgumentException();
12686
      }
12687
 
12688
      switch (field) {
12689
      case ITEM_ID:
12690
        return isSetItemId();
12691
      case WAREHOUSE_ID:
12692
        return isSetWarehouseId();
12693
      case QUANTITY:
12694
        return isSetQuantity();
12695
      }
12696
      throw new IllegalStateException();
12697
    }
12698
 
12699
    @Override
12700
    public boolean equals(Object that) {
12701
      if (that == null)
12702
        return false;
12703
      if (that instanceof reduceReservationCount_args)
12704
        return this.equals((reduceReservationCount_args)that);
12705
      return false;
12706
    }
12707
 
12708
    public boolean equals(reduceReservationCount_args that) {
12709
      if (that == null)
12710
        return false;
12711
 
12712
      boolean this_present_itemId = true;
12713
      boolean that_present_itemId = true;
12714
      if (this_present_itemId || that_present_itemId) {
12715
        if (!(this_present_itemId && that_present_itemId))
12716
          return false;
12717
        if (this.itemId != that.itemId)
12718
          return false;
12719
      }
12720
 
12721
      boolean this_present_warehouseId = true;
12722
      boolean that_present_warehouseId = true;
12723
      if (this_present_warehouseId || that_present_warehouseId) {
12724
        if (!(this_present_warehouseId && that_present_warehouseId))
12725
          return false;
12726
        if (this.warehouseId != that.warehouseId)
12727
          return false;
12728
      }
12729
 
12730
      boolean this_present_quantity = true;
12731
      boolean that_present_quantity = true;
12732
      if (this_present_quantity || that_present_quantity) {
12733
        if (!(this_present_quantity && that_present_quantity))
12734
          return false;
12735
        if (this.quantity != that.quantity)
12736
          return false;
12737
      }
12738
 
12739
      return true;
12740
    }
12741
 
12742
    @Override
12743
    public int hashCode() {
12744
      return 0;
12745
    }
12746
 
12747
    public int compareTo(reduceReservationCount_args other) {
12748
      if (!getClass().equals(other.getClass())) {
12749
        return getClass().getName().compareTo(other.getClass().getName());
12750
      }
12751
 
12752
      int lastComparison = 0;
12753
      reduceReservationCount_args typedOther = (reduceReservationCount_args)other;
12754
 
12755
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
12756
      if (lastComparison != 0) {
12757
        return lastComparison;
12758
      }
12759
      if (isSetItemId()) {
12760
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
12761
        if (lastComparison != 0) {
12762
          return lastComparison;
12763
        }
12764
      }
12765
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
12766
      if (lastComparison != 0) {
12767
        return lastComparison;
12768
      }
12769
      if (isSetWarehouseId()) {
12770
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
12771
        if (lastComparison != 0) {
12772
          return lastComparison;
12773
        }
12774
      }
12775
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
12776
      if (lastComparison != 0) {
12777
        return lastComparison;
12778
      }
12779
      if (isSetQuantity()) {
12780
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
12781
        if (lastComparison != 0) {
12782
          return lastComparison;
12783
        }
12784
      }
12785
      return 0;
12786
    }
12787
 
12788
    public _Fields fieldForId(int fieldId) {
12789
      return _Fields.findByThriftId(fieldId);
12790
    }
12791
 
12792
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12793
      org.apache.thrift.protocol.TField field;
12794
      iprot.readStructBegin();
12795
      while (true)
12796
      {
12797
        field = iprot.readFieldBegin();
12798
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12799
          break;
12800
        }
12801
        switch (field.id) {
12802
          case 1: // ITEM_ID
12803
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12804
              this.itemId = iprot.readI64();
12805
              setItemIdIsSet(true);
12806
            } else { 
12807
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12808
            }
12809
            break;
12810
          case 2: // WAREHOUSE_ID
12811
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12812
              this.warehouseId = iprot.readI64();
12813
              setWarehouseIdIsSet(true);
12814
            } else { 
12815
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12816
            }
12817
            break;
12818
          case 3: // QUANTITY
12819
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
12820
              this.quantity = iprot.readDouble();
12821
              setQuantityIsSet(true);
12822
            } else { 
12823
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12824
            }
12825
            break;
12826
          default:
12827
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12828
        }
12829
        iprot.readFieldEnd();
12830
      }
12831
      iprot.readStructEnd();
12832
      validate();
12833
    }
12834
 
12835
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12836
      validate();
12837
 
12838
      oprot.writeStructBegin(STRUCT_DESC);
12839
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
12840
      oprot.writeI64(this.itemId);
12841
      oprot.writeFieldEnd();
12842
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
12843
      oprot.writeI64(this.warehouseId);
12844
      oprot.writeFieldEnd();
12845
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
12846
      oprot.writeDouble(this.quantity);
12847
      oprot.writeFieldEnd();
12848
      oprot.writeFieldStop();
12849
      oprot.writeStructEnd();
12850
    }
12851
 
12852
    @Override
12853
    public String toString() {
12854
      StringBuilder sb = new StringBuilder("reduceReservationCount_args(");
12855
      boolean first = true;
12856
 
12857
      sb.append("itemId:");
12858
      sb.append(this.itemId);
12859
      first = false;
12860
      if (!first) sb.append(", ");
12861
      sb.append("warehouseId:");
12862
      sb.append(this.warehouseId);
12863
      first = false;
12864
      if (!first) sb.append(", ");
12865
      sb.append("quantity:");
12866
      sb.append(this.quantity);
12867
      first = false;
12868
      sb.append(")");
12869
      return sb.toString();
12870
    }
12871
 
12872
    public void validate() throws org.apache.thrift.TException {
12873
      // check for required fields
12874
    }
12875
 
12876
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12877
      try {
12878
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12879
      } catch (org.apache.thrift.TException te) {
12880
        throw new java.io.IOException(te);
12881
      }
12882
    }
12883
 
12884
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12885
      try {
12886
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12887
      } catch (org.apache.thrift.TException te) {
12888
        throw new java.io.IOException(te);
12889
      }
12890
    }
12891
 
12892
  }
12893
 
12894
  public static class reduceReservationCount_result implements org.apache.thrift.TBase<reduceReservationCount_result, reduceReservationCount_result._Fields>, java.io.Serializable, Cloneable   {
12895
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reduceReservationCount_result");
12896
 
12897
    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);
12898
    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);
12899
 
12900
    private boolean success; // required
12901
    private InventoryServiceException cex; // required
12902
 
12903
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12904
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12905
      SUCCESS((short)0, "success"),
12906
      CEX((short)1, "cex");
12907
 
12908
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12909
 
12910
      static {
12911
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12912
          byName.put(field.getFieldName(), field);
12913
        }
12914
      }
12915
 
12916
      /**
12917
       * Find the _Fields constant that matches fieldId, or null if its not found.
12918
       */
12919
      public static _Fields findByThriftId(int fieldId) {
12920
        switch(fieldId) {
12921
          case 0: // SUCCESS
12922
            return SUCCESS;
12923
          case 1: // CEX
12924
            return CEX;
12925
          default:
12926
            return null;
12927
        }
12928
      }
12929
 
12930
      /**
12931
       * Find the _Fields constant that matches fieldId, throwing an exception
12932
       * if it is not found.
12933
       */
12934
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12935
        _Fields fields = findByThriftId(fieldId);
12936
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12937
        return fields;
12938
      }
12939
 
12940
      /**
12941
       * Find the _Fields constant that matches name, or null if its not found.
12942
       */
12943
      public static _Fields findByName(String name) {
12944
        return byName.get(name);
12945
      }
12946
 
12947
      private final short _thriftId;
12948
      private final String _fieldName;
12949
 
12950
      _Fields(short thriftId, String fieldName) {
12951
        _thriftId = thriftId;
12952
        _fieldName = fieldName;
12953
      }
12954
 
12955
      public short getThriftFieldId() {
12956
        return _thriftId;
12957
      }
12958
 
12959
      public String getFieldName() {
12960
        return _fieldName;
12961
      }
12962
    }
12963
 
12964
    // isset id assignments
12965
    private static final int __SUCCESS_ISSET_ID = 0;
12966
    private BitSet __isset_bit_vector = new BitSet(1);
12967
 
12968
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12969
    static {
12970
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12971
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12972
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
12973
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12974
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
12975
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12976
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reduceReservationCount_result.class, metaDataMap);
12977
    }
12978
 
12979
    public reduceReservationCount_result() {
12980
    }
12981
 
12982
    public reduceReservationCount_result(
12983
      boolean success,
12984
      InventoryServiceException cex)
12985
    {
12986
      this();
12987
      this.success = success;
12988
      setSuccessIsSet(true);
12989
      this.cex = cex;
12990
    }
12991
 
12992
    /**
12993
     * Performs a deep copy on <i>other</i>.
12994
     */
12995
    public reduceReservationCount_result(reduceReservationCount_result other) {
12996
      __isset_bit_vector.clear();
12997
      __isset_bit_vector.or(other.__isset_bit_vector);
12998
      this.success = other.success;
12999
      if (other.isSetCex()) {
13000
        this.cex = new InventoryServiceException(other.cex);
13001
      }
13002
    }
13003
 
13004
    public reduceReservationCount_result deepCopy() {
13005
      return new reduceReservationCount_result(this);
13006
    }
13007
 
13008
    @Override
13009
    public void clear() {
13010
      setSuccessIsSet(false);
13011
      this.success = false;
13012
      this.cex = null;
13013
    }
13014
 
13015
    public boolean isSuccess() {
13016
      return this.success;
13017
    }
13018
 
13019
    public void setSuccess(boolean success) {
13020
      this.success = success;
13021
      setSuccessIsSet(true);
13022
    }
13023
 
13024
    public void unsetSuccess() {
13025
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
13026
    }
13027
 
13028
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13029
    public boolean isSetSuccess() {
13030
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
13031
    }
13032
 
13033
    public void setSuccessIsSet(boolean value) {
13034
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
13035
    }
13036
 
13037
    public InventoryServiceException getCex() {
13038
      return this.cex;
13039
    }
13040
 
13041
    public void setCex(InventoryServiceException cex) {
13042
      this.cex = cex;
13043
    }
13044
 
13045
    public void unsetCex() {
13046
      this.cex = null;
13047
    }
13048
 
13049
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
13050
    public boolean isSetCex() {
13051
      return this.cex != null;
13052
    }
13053
 
13054
    public void setCexIsSet(boolean value) {
13055
      if (!value) {
13056
        this.cex = null;
13057
      }
13058
    }
13059
 
13060
    public void setFieldValue(_Fields field, Object value) {
13061
      switch (field) {
13062
      case SUCCESS:
13063
        if (value == null) {
13064
          unsetSuccess();
13065
        } else {
13066
          setSuccess((Boolean)value);
13067
        }
13068
        break;
13069
 
13070
      case CEX:
13071
        if (value == null) {
13072
          unsetCex();
13073
        } else {
13074
          setCex((InventoryServiceException)value);
13075
        }
13076
        break;
13077
 
13078
      }
13079
    }
13080
 
13081
    public Object getFieldValue(_Fields field) {
13082
      switch (field) {
13083
      case SUCCESS:
13084
        return Boolean.valueOf(isSuccess());
13085
 
13086
      case CEX:
13087
        return getCex();
13088
 
13089
      }
13090
      throw new IllegalStateException();
13091
    }
13092
 
13093
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13094
    public boolean isSet(_Fields field) {
13095
      if (field == null) {
13096
        throw new IllegalArgumentException();
13097
      }
13098
 
13099
      switch (field) {
13100
      case SUCCESS:
13101
        return isSetSuccess();
13102
      case CEX:
13103
        return isSetCex();
13104
      }
13105
      throw new IllegalStateException();
13106
    }
13107
 
13108
    @Override
13109
    public boolean equals(Object that) {
13110
      if (that == null)
13111
        return false;
13112
      if (that instanceof reduceReservationCount_result)
13113
        return this.equals((reduceReservationCount_result)that);
13114
      return false;
13115
    }
13116
 
13117
    public boolean equals(reduceReservationCount_result that) {
13118
      if (that == null)
13119
        return false;
13120
 
13121
      boolean this_present_success = true;
13122
      boolean that_present_success = true;
13123
      if (this_present_success || that_present_success) {
13124
        if (!(this_present_success && that_present_success))
13125
          return false;
13126
        if (this.success != that.success)
13127
          return false;
13128
      }
13129
 
13130
      boolean this_present_cex = true && this.isSetCex();
13131
      boolean that_present_cex = true && that.isSetCex();
13132
      if (this_present_cex || that_present_cex) {
13133
        if (!(this_present_cex && that_present_cex))
13134
          return false;
13135
        if (!this.cex.equals(that.cex))
13136
          return false;
13137
      }
13138
 
13139
      return true;
13140
    }
13141
 
13142
    @Override
13143
    public int hashCode() {
13144
      return 0;
13145
    }
13146
 
13147
    public int compareTo(reduceReservationCount_result other) {
13148
      if (!getClass().equals(other.getClass())) {
13149
        return getClass().getName().compareTo(other.getClass().getName());
13150
      }
13151
 
13152
      int lastComparison = 0;
13153
      reduceReservationCount_result typedOther = (reduceReservationCount_result)other;
13154
 
13155
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13156
      if (lastComparison != 0) {
13157
        return lastComparison;
13158
      }
13159
      if (isSetSuccess()) {
13160
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13161
        if (lastComparison != 0) {
13162
          return lastComparison;
13163
        }
13164
      }
13165
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
13166
      if (lastComparison != 0) {
13167
        return lastComparison;
13168
      }
13169
      if (isSetCex()) {
13170
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
13171
        if (lastComparison != 0) {
13172
          return lastComparison;
13173
        }
13174
      }
13175
      return 0;
13176
    }
13177
 
13178
    public _Fields fieldForId(int fieldId) {
13179
      return _Fields.findByThriftId(fieldId);
13180
    }
13181
 
13182
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13183
      org.apache.thrift.protocol.TField field;
13184
      iprot.readStructBegin();
13185
      while (true)
13186
      {
13187
        field = iprot.readFieldBegin();
13188
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13189
          break;
13190
        }
13191
        switch (field.id) {
13192
          case 0: // SUCCESS
13193
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
13194
              this.success = iprot.readBool();
13195
              setSuccessIsSet(true);
13196
            } else { 
13197
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13198
            }
13199
            break;
13200
          case 1: // CEX
13201
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
13202
              this.cex = new InventoryServiceException();
13203
              this.cex.read(iprot);
13204
            } else { 
13205
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13206
            }
13207
            break;
13208
          default:
13209
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13210
        }
13211
        iprot.readFieldEnd();
13212
      }
13213
      iprot.readStructEnd();
13214
      validate();
13215
    }
13216
 
13217
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13218
      oprot.writeStructBegin(STRUCT_DESC);
13219
 
13220
      if (this.isSetSuccess()) {
13221
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
13222
        oprot.writeBool(this.success);
13223
        oprot.writeFieldEnd();
13224
      } else if (this.isSetCex()) {
13225
        oprot.writeFieldBegin(CEX_FIELD_DESC);
13226
        this.cex.write(oprot);
13227
        oprot.writeFieldEnd();
13228
      }
13229
      oprot.writeFieldStop();
13230
      oprot.writeStructEnd();
13231
    }
13232
 
13233
    @Override
13234
    public String toString() {
13235
      StringBuilder sb = new StringBuilder("reduceReservationCount_result(");
13236
      boolean first = true;
13237
 
13238
      sb.append("success:");
13239
      sb.append(this.success);
13240
      first = false;
13241
      if (!first) sb.append(", ");
13242
      sb.append("cex:");
13243
      if (this.cex == null) {
13244
        sb.append("null");
13245
      } else {
13246
        sb.append(this.cex);
13247
      }
13248
      first = false;
13249
      sb.append(")");
13250
      return sb.toString();
13251
    }
13252
 
13253
    public void validate() throws org.apache.thrift.TException {
13254
      // check for required fields
13255
    }
13256
 
13257
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13258
      try {
13259
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13260
      } catch (org.apache.thrift.TException te) {
13261
        throw new java.io.IOException(te);
13262
      }
13263
    }
13264
 
13265
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13266
      try {
13267
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13268
      } catch (org.apache.thrift.TException te) {
13269
        throw new java.io.IOException(te);
13270
      }
13271
    }
13272
 
13273
  }
13274
 
13275
  public static class getItemPricing_args implements org.apache.thrift.TBase<getItemPricing_args, getItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
13276
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemPricing_args");
13277
 
13278
    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);
13279
    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);
13280
 
13281
    private long itemId; // required
13282
    private long vendorId; // required
13283
 
13284
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13285
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13286
      ITEM_ID((short)1, "itemId"),
13287
      VENDOR_ID((short)2, "vendorId");
13288
 
13289
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13290
 
13291
      static {
13292
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13293
          byName.put(field.getFieldName(), field);
13294
        }
13295
      }
13296
 
13297
      /**
13298
       * Find the _Fields constant that matches fieldId, or null if its not found.
13299
       */
13300
      public static _Fields findByThriftId(int fieldId) {
13301
        switch(fieldId) {
13302
          case 1: // ITEM_ID
13303
            return ITEM_ID;
13304
          case 2: // VENDOR_ID
13305
            return VENDOR_ID;
13306
          default:
13307
            return null;
13308
        }
13309
      }
13310
 
13311
      /**
13312
       * Find the _Fields constant that matches fieldId, throwing an exception
13313
       * if it is not found.
13314
       */
13315
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13316
        _Fields fields = findByThriftId(fieldId);
13317
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13318
        return fields;
13319
      }
13320
 
13321
      /**
13322
       * Find the _Fields constant that matches name, or null if its not found.
13323
       */
13324
      public static _Fields findByName(String name) {
13325
        return byName.get(name);
13326
      }
13327
 
13328
      private final short _thriftId;
13329
      private final String _fieldName;
13330
 
13331
      _Fields(short thriftId, String fieldName) {
13332
        _thriftId = thriftId;
13333
        _fieldName = fieldName;
13334
      }
13335
 
13336
      public short getThriftFieldId() {
13337
        return _thriftId;
13338
      }
13339
 
13340
      public String getFieldName() {
13341
        return _fieldName;
13342
      }
13343
    }
13344
 
13345
    // isset id assignments
13346
    private static final int __ITEMID_ISSET_ID = 0;
13347
    private static final int __VENDORID_ISSET_ID = 1;
13348
    private BitSet __isset_bit_vector = new BitSet(2);
13349
 
13350
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13351
    static {
13352
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13353
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13354
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13355
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13356
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13357
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13358
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemPricing_args.class, metaDataMap);
13359
    }
13360
 
13361
    public getItemPricing_args() {
13362
    }
13363
 
13364
    public getItemPricing_args(
13365
      long itemId,
13366
      long vendorId)
13367
    {
13368
      this();
13369
      this.itemId = itemId;
13370
      setItemIdIsSet(true);
13371
      this.vendorId = vendorId;
13372
      setVendorIdIsSet(true);
13373
    }
13374
 
13375
    /**
13376
     * Performs a deep copy on <i>other</i>.
13377
     */
13378
    public getItemPricing_args(getItemPricing_args other) {
13379
      __isset_bit_vector.clear();
13380
      __isset_bit_vector.or(other.__isset_bit_vector);
13381
      this.itemId = other.itemId;
13382
      this.vendorId = other.vendorId;
13383
    }
13384
 
13385
    public getItemPricing_args deepCopy() {
13386
      return new getItemPricing_args(this);
13387
    }
13388
 
13389
    @Override
13390
    public void clear() {
13391
      setItemIdIsSet(false);
13392
      this.itemId = 0;
13393
      setVendorIdIsSet(false);
13394
      this.vendorId = 0;
13395
    }
13396
 
13397
    public long getItemId() {
13398
      return this.itemId;
13399
    }
13400
 
13401
    public void setItemId(long itemId) {
13402
      this.itemId = itemId;
13403
      setItemIdIsSet(true);
13404
    }
13405
 
13406
    public void unsetItemId() {
13407
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
13408
    }
13409
 
13410
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
13411
    public boolean isSetItemId() {
13412
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
13413
    }
13414
 
13415
    public void setItemIdIsSet(boolean value) {
13416
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
13417
    }
13418
 
13419
    public long getVendorId() {
13420
      return this.vendorId;
13421
    }
13422
 
13423
    public void setVendorId(long vendorId) {
13424
      this.vendorId = vendorId;
13425
      setVendorIdIsSet(true);
13426
    }
13427
 
13428
    public void unsetVendorId() {
13429
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
13430
    }
13431
 
13432
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
13433
    public boolean isSetVendorId() {
13434
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
13435
    }
13436
 
13437
    public void setVendorIdIsSet(boolean value) {
13438
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
13439
    }
13440
 
13441
    public void setFieldValue(_Fields field, Object value) {
13442
      switch (field) {
13443
      case ITEM_ID:
13444
        if (value == null) {
13445
          unsetItemId();
13446
        } else {
13447
          setItemId((Long)value);
13448
        }
13449
        break;
13450
 
13451
      case VENDOR_ID:
13452
        if (value == null) {
13453
          unsetVendorId();
13454
        } else {
13455
          setVendorId((Long)value);
13456
        }
13457
        break;
13458
 
13459
      }
13460
    }
13461
 
13462
    public Object getFieldValue(_Fields field) {
13463
      switch (field) {
13464
      case ITEM_ID:
13465
        return Long.valueOf(getItemId());
13466
 
13467
      case VENDOR_ID:
13468
        return Long.valueOf(getVendorId());
13469
 
13470
      }
13471
      throw new IllegalStateException();
13472
    }
13473
 
13474
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13475
    public boolean isSet(_Fields field) {
13476
      if (field == null) {
13477
        throw new IllegalArgumentException();
13478
      }
13479
 
13480
      switch (field) {
13481
      case ITEM_ID:
13482
        return isSetItemId();
13483
      case VENDOR_ID:
13484
        return isSetVendorId();
13485
      }
13486
      throw new IllegalStateException();
13487
    }
13488
 
13489
    @Override
13490
    public boolean equals(Object that) {
13491
      if (that == null)
13492
        return false;
13493
      if (that instanceof getItemPricing_args)
13494
        return this.equals((getItemPricing_args)that);
13495
      return false;
13496
    }
13497
 
13498
    public boolean equals(getItemPricing_args that) {
13499
      if (that == null)
13500
        return false;
13501
 
13502
      boolean this_present_itemId = true;
13503
      boolean that_present_itemId = true;
13504
      if (this_present_itemId || that_present_itemId) {
13505
        if (!(this_present_itemId && that_present_itemId))
13506
          return false;
13507
        if (this.itemId != that.itemId)
13508
          return false;
13509
      }
13510
 
13511
      boolean this_present_vendorId = true;
13512
      boolean that_present_vendorId = true;
13513
      if (this_present_vendorId || that_present_vendorId) {
13514
        if (!(this_present_vendorId && that_present_vendorId))
13515
          return false;
13516
        if (this.vendorId != that.vendorId)
13517
          return false;
13518
      }
13519
 
13520
      return true;
13521
    }
13522
 
13523
    @Override
13524
    public int hashCode() {
13525
      return 0;
13526
    }
13527
 
13528
    public int compareTo(getItemPricing_args other) {
13529
      if (!getClass().equals(other.getClass())) {
13530
        return getClass().getName().compareTo(other.getClass().getName());
13531
      }
13532
 
13533
      int lastComparison = 0;
13534
      getItemPricing_args typedOther = (getItemPricing_args)other;
13535
 
13536
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
13537
      if (lastComparison != 0) {
13538
        return lastComparison;
13539
      }
13540
      if (isSetItemId()) {
13541
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
13542
        if (lastComparison != 0) {
13543
          return lastComparison;
13544
        }
13545
      }
13546
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
13547
      if (lastComparison != 0) {
13548
        return lastComparison;
13549
      }
13550
      if (isSetVendorId()) {
13551
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
13552
        if (lastComparison != 0) {
13553
          return lastComparison;
13554
        }
13555
      }
13556
      return 0;
13557
    }
13558
 
13559
    public _Fields fieldForId(int fieldId) {
13560
      return _Fields.findByThriftId(fieldId);
13561
    }
13562
 
13563
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13564
      org.apache.thrift.protocol.TField field;
13565
      iprot.readStructBegin();
13566
      while (true)
13567
      {
13568
        field = iprot.readFieldBegin();
13569
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13570
          break;
13571
        }
13572
        switch (field.id) {
13573
          case 1: // ITEM_ID
13574
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13575
              this.itemId = iprot.readI64();
13576
              setItemIdIsSet(true);
13577
            } else { 
13578
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13579
            }
13580
            break;
13581
          case 2: // VENDOR_ID
13582
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13583
              this.vendorId = iprot.readI64();
13584
              setVendorIdIsSet(true);
13585
            } else { 
13586
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13587
            }
13588
            break;
13589
          default:
13590
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13591
        }
13592
        iprot.readFieldEnd();
13593
      }
13594
      iprot.readStructEnd();
13595
      validate();
13596
    }
13597
 
13598
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13599
      validate();
13600
 
13601
      oprot.writeStructBegin(STRUCT_DESC);
13602
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
13603
      oprot.writeI64(this.itemId);
13604
      oprot.writeFieldEnd();
13605
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
13606
      oprot.writeI64(this.vendorId);
13607
      oprot.writeFieldEnd();
13608
      oprot.writeFieldStop();
13609
      oprot.writeStructEnd();
13610
    }
13611
 
13612
    @Override
13613
    public String toString() {
13614
      StringBuilder sb = new StringBuilder("getItemPricing_args(");
13615
      boolean first = true;
13616
 
13617
      sb.append("itemId:");
13618
      sb.append(this.itemId);
13619
      first = false;
13620
      if (!first) sb.append(", ");
13621
      sb.append("vendorId:");
13622
      sb.append(this.vendorId);
13623
      first = false;
13624
      sb.append(")");
13625
      return sb.toString();
13626
    }
13627
 
13628
    public void validate() throws org.apache.thrift.TException {
13629
      // check for required fields
13630
    }
13631
 
13632
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13633
      try {
13634
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13635
      } catch (org.apache.thrift.TException te) {
13636
        throw new java.io.IOException(te);
13637
      }
13638
    }
13639
 
13640
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13641
      try {
13642
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13643
      } catch (org.apache.thrift.TException te) {
13644
        throw new java.io.IOException(te);
13645
      }
13646
    }
13647
 
13648
  }
13649
 
13650
  public static class getItemPricing_result implements org.apache.thrift.TBase<getItemPricing_result, getItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
13651
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemPricing_result");
13652
 
13653
    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);
13654
    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);
13655
 
13656
    private VendorItemPricing success; // required
13657
    private InventoryServiceException cex; // required
13658
 
13659
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13660
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13661
      SUCCESS((short)0, "success"),
13662
      CEX((short)1, "cex");
13663
 
13664
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13665
 
13666
      static {
13667
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13668
          byName.put(field.getFieldName(), field);
13669
        }
13670
      }
13671
 
13672
      /**
13673
       * Find the _Fields constant that matches fieldId, or null if its not found.
13674
       */
13675
      public static _Fields findByThriftId(int fieldId) {
13676
        switch(fieldId) {
13677
          case 0: // SUCCESS
13678
            return SUCCESS;
13679
          case 1: // CEX
13680
            return CEX;
13681
          default:
13682
            return null;
13683
        }
13684
      }
13685
 
13686
      /**
13687
       * Find the _Fields constant that matches fieldId, throwing an exception
13688
       * if it is not found.
13689
       */
13690
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13691
        _Fields fields = findByThriftId(fieldId);
13692
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13693
        return fields;
13694
      }
13695
 
13696
      /**
13697
       * Find the _Fields constant that matches name, or null if its not found.
13698
       */
13699
      public static _Fields findByName(String name) {
13700
        return byName.get(name);
13701
      }
13702
 
13703
      private final short _thriftId;
13704
      private final String _fieldName;
13705
 
13706
      _Fields(short thriftId, String fieldName) {
13707
        _thriftId = thriftId;
13708
        _fieldName = fieldName;
13709
      }
13710
 
13711
      public short getThriftFieldId() {
13712
        return _thriftId;
13713
      }
13714
 
13715
      public String getFieldName() {
13716
        return _fieldName;
13717
      }
13718
    }
13719
 
13720
    // isset id assignments
13721
 
13722
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13723
    static {
13724
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13725
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13726
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class)));
13727
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13728
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
13729
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13730
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemPricing_result.class, metaDataMap);
13731
    }
13732
 
13733
    public getItemPricing_result() {
13734
    }
13735
 
13736
    public getItemPricing_result(
13737
      VendorItemPricing success,
13738
      InventoryServiceException cex)
13739
    {
13740
      this();
13741
      this.success = success;
13742
      this.cex = cex;
13743
    }
13744
 
13745
    /**
13746
     * Performs a deep copy on <i>other</i>.
13747
     */
13748
    public getItemPricing_result(getItemPricing_result other) {
13749
      if (other.isSetSuccess()) {
13750
        this.success = new VendorItemPricing(other.success);
13751
      }
13752
      if (other.isSetCex()) {
13753
        this.cex = new InventoryServiceException(other.cex);
13754
      }
13755
    }
13756
 
13757
    public getItemPricing_result deepCopy() {
13758
      return new getItemPricing_result(this);
13759
    }
13760
 
13761
    @Override
13762
    public void clear() {
13763
      this.success = null;
13764
      this.cex = null;
13765
    }
13766
 
13767
    public VendorItemPricing getSuccess() {
13768
      return this.success;
13769
    }
13770
 
13771
    public void setSuccess(VendorItemPricing success) {
13772
      this.success = success;
13773
    }
13774
 
13775
    public void unsetSuccess() {
13776
      this.success = null;
13777
    }
13778
 
13779
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13780
    public boolean isSetSuccess() {
13781
      return this.success != null;
13782
    }
13783
 
13784
    public void setSuccessIsSet(boolean value) {
13785
      if (!value) {
13786
        this.success = null;
13787
      }
13788
    }
13789
 
13790
    public InventoryServiceException getCex() {
13791
      return this.cex;
13792
    }
13793
 
13794
    public void setCex(InventoryServiceException cex) {
13795
      this.cex = cex;
13796
    }
13797
 
13798
    public void unsetCex() {
13799
      this.cex = null;
13800
    }
13801
 
13802
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
13803
    public boolean isSetCex() {
13804
      return this.cex != null;
13805
    }
13806
 
13807
    public void setCexIsSet(boolean value) {
13808
      if (!value) {
13809
        this.cex = null;
13810
      }
13811
    }
13812
 
13813
    public void setFieldValue(_Fields field, Object value) {
13814
      switch (field) {
13815
      case SUCCESS:
13816
        if (value == null) {
13817
          unsetSuccess();
13818
        } else {
13819
          setSuccess((VendorItemPricing)value);
13820
        }
13821
        break;
13822
 
13823
      case CEX:
13824
        if (value == null) {
13825
          unsetCex();
13826
        } else {
13827
          setCex((InventoryServiceException)value);
13828
        }
13829
        break;
13830
 
13831
      }
13832
    }
13833
 
13834
    public Object getFieldValue(_Fields field) {
13835
      switch (field) {
13836
      case SUCCESS:
13837
        return getSuccess();
13838
 
13839
      case CEX:
13840
        return getCex();
13841
 
13842
      }
13843
      throw new IllegalStateException();
13844
    }
13845
 
13846
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13847
    public boolean isSet(_Fields field) {
13848
      if (field == null) {
13849
        throw new IllegalArgumentException();
13850
      }
13851
 
13852
      switch (field) {
13853
      case SUCCESS:
13854
        return isSetSuccess();
13855
      case CEX:
13856
        return isSetCex();
13857
      }
13858
      throw new IllegalStateException();
13859
    }
13860
 
13861
    @Override
13862
    public boolean equals(Object that) {
13863
      if (that == null)
13864
        return false;
13865
      if (that instanceof getItemPricing_result)
13866
        return this.equals((getItemPricing_result)that);
13867
      return false;
13868
    }
13869
 
13870
    public boolean equals(getItemPricing_result that) {
13871
      if (that == null)
13872
        return false;
13873
 
13874
      boolean this_present_success = true && this.isSetSuccess();
13875
      boolean that_present_success = true && that.isSetSuccess();
13876
      if (this_present_success || that_present_success) {
13877
        if (!(this_present_success && that_present_success))
13878
          return false;
13879
        if (!this.success.equals(that.success))
13880
          return false;
13881
      }
13882
 
13883
      boolean this_present_cex = true && this.isSetCex();
13884
      boolean that_present_cex = true && that.isSetCex();
13885
      if (this_present_cex || that_present_cex) {
13886
        if (!(this_present_cex && that_present_cex))
13887
          return false;
13888
        if (!this.cex.equals(that.cex))
13889
          return false;
13890
      }
13891
 
13892
      return true;
13893
    }
13894
 
13895
    @Override
13896
    public int hashCode() {
13897
      return 0;
13898
    }
13899
 
13900
    public int compareTo(getItemPricing_result other) {
13901
      if (!getClass().equals(other.getClass())) {
13902
        return getClass().getName().compareTo(other.getClass().getName());
13903
      }
13904
 
13905
      int lastComparison = 0;
13906
      getItemPricing_result typedOther = (getItemPricing_result)other;
13907
 
13908
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13909
      if (lastComparison != 0) {
13910
        return lastComparison;
13911
      }
13912
      if (isSetSuccess()) {
13913
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13914
        if (lastComparison != 0) {
13915
          return lastComparison;
13916
        }
13917
      }
13918
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
13919
      if (lastComparison != 0) {
13920
        return lastComparison;
13921
      }
13922
      if (isSetCex()) {
13923
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
13924
        if (lastComparison != 0) {
13925
          return lastComparison;
13926
        }
13927
      }
13928
      return 0;
13929
    }
13930
 
13931
    public _Fields fieldForId(int fieldId) {
13932
      return _Fields.findByThriftId(fieldId);
13933
    }
13934
 
13935
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13936
      org.apache.thrift.protocol.TField field;
13937
      iprot.readStructBegin();
13938
      while (true)
13939
      {
13940
        field = iprot.readFieldBegin();
13941
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13942
          break;
13943
        }
13944
        switch (field.id) {
13945
          case 0: // SUCCESS
13946
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
13947
              this.success = new VendorItemPricing();
13948
              this.success.read(iprot);
13949
            } else { 
13950
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13951
            }
13952
            break;
13953
          case 1: // CEX
13954
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
13955
              this.cex = new InventoryServiceException();
13956
              this.cex.read(iprot);
13957
            } else { 
13958
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13959
            }
13960
            break;
13961
          default:
13962
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13963
        }
13964
        iprot.readFieldEnd();
13965
      }
13966
      iprot.readStructEnd();
13967
      validate();
13968
    }
13969
 
13970
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13971
      oprot.writeStructBegin(STRUCT_DESC);
13972
 
13973
      if (this.isSetSuccess()) {
13974
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
13975
        this.success.write(oprot);
13976
        oprot.writeFieldEnd();
13977
      } else if (this.isSetCex()) {
13978
        oprot.writeFieldBegin(CEX_FIELD_DESC);
13979
        this.cex.write(oprot);
13980
        oprot.writeFieldEnd();
13981
      }
13982
      oprot.writeFieldStop();
13983
      oprot.writeStructEnd();
13984
    }
13985
 
13986
    @Override
13987
    public String toString() {
13988
      StringBuilder sb = new StringBuilder("getItemPricing_result(");
13989
      boolean first = true;
13990
 
13991
      sb.append("success:");
13992
      if (this.success == null) {
13993
        sb.append("null");
13994
      } else {
13995
        sb.append(this.success);
13996
      }
13997
      first = false;
13998
      if (!first) sb.append(", ");
13999
      sb.append("cex:");
14000
      if (this.cex == null) {
14001
        sb.append("null");
14002
      } else {
14003
        sb.append(this.cex);
14004
      }
14005
      first = false;
14006
      sb.append(")");
14007
      return sb.toString();
14008
    }
14009
 
14010
    public void validate() throws org.apache.thrift.TException {
14011
      // check for required fields
14012
    }
14013
 
14014
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14015
      try {
14016
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14017
      } catch (org.apache.thrift.TException te) {
14018
        throw new java.io.IOException(te);
14019
      }
14020
    }
14021
 
14022
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14023
      try {
14024
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14025
      } catch (org.apache.thrift.TException te) {
14026
        throw new java.io.IOException(te);
14027
      }
14028
    }
14029
 
14030
  }
14031
 
14032
  public static class getAllItemPricing_args implements org.apache.thrift.TBase<getAllItemPricing_args, getAllItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
14033
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemPricing_args");
14034
 
14035
    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);
14036
 
14037
    private long itemId; // required
14038
 
14039
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14040
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14041
      ITEM_ID((short)1, "itemId");
14042
 
14043
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14044
 
14045
      static {
14046
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14047
          byName.put(field.getFieldName(), field);
14048
        }
14049
      }
14050
 
14051
      /**
14052
       * Find the _Fields constant that matches fieldId, or null if its not found.
14053
       */
14054
      public static _Fields findByThriftId(int fieldId) {
14055
        switch(fieldId) {
14056
          case 1: // ITEM_ID
14057
            return ITEM_ID;
14058
          default:
14059
            return null;
14060
        }
14061
      }
14062
 
14063
      /**
14064
       * Find the _Fields constant that matches fieldId, throwing an exception
14065
       * if it is not found.
14066
       */
14067
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14068
        _Fields fields = findByThriftId(fieldId);
14069
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14070
        return fields;
14071
      }
14072
 
14073
      /**
14074
       * Find the _Fields constant that matches name, or null if its not found.
14075
       */
14076
      public static _Fields findByName(String name) {
14077
        return byName.get(name);
14078
      }
14079
 
14080
      private final short _thriftId;
14081
      private final String _fieldName;
14082
 
14083
      _Fields(short thriftId, String fieldName) {
14084
        _thriftId = thriftId;
14085
        _fieldName = fieldName;
14086
      }
14087
 
14088
      public short getThriftFieldId() {
14089
        return _thriftId;
14090
      }
14091
 
14092
      public String getFieldName() {
14093
        return _fieldName;
14094
      }
14095
    }
14096
 
14097
    // isset id assignments
14098
    private static final int __ITEMID_ISSET_ID = 0;
14099
    private BitSet __isset_bit_vector = new BitSet(1);
14100
 
14101
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14102
    static {
14103
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14104
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14105
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14106
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14107
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemPricing_args.class, metaDataMap);
14108
    }
14109
 
14110
    public getAllItemPricing_args() {
14111
    }
14112
 
14113
    public getAllItemPricing_args(
14114
      long itemId)
14115
    {
14116
      this();
14117
      this.itemId = itemId;
14118
      setItemIdIsSet(true);
14119
    }
14120
 
14121
    /**
14122
     * Performs a deep copy on <i>other</i>.
14123
     */
14124
    public getAllItemPricing_args(getAllItemPricing_args other) {
14125
      __isset_bit_vector.clear();
14126
      __isset_bit_vector.or(other.__isset_bit_vector);
14127
      this.itemId = other.itemId;
14128
    }
14129
 
14130
    public getAllItemPricing_args deepCopy() {
14131
      return new getAllItemPricing_args(this);
14132
    }
14133
 
14134
    @Override
14135
    public void clear() {
14136
      setItemIdIsSet(false);
14137
      this.itemId = 0;
14138
    }
14139
 
14140
    public long getItemId() {
14141
      return this.itemId;
14142
    }
14143
 
14144
    public void setItemId(long itemId) {
14145
      this.itemId = itemId;
14146
      setItemIdIsSet(true);
14147
    }
14148
 
14149
    public void unsetItemId() {
14150
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
14151
    }
14152
 
14153
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
14154
    public boolean isSetItemId() {
14155
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
14156
    }
14157
 
14158
    public void setItemIdIsSet(boolean value) {
14159
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
14160
    }
14161
 
14162
    public void setFieldValue(_Fields field, Object value) {
14163
      switch (field) {
14164
      case ITEM_ID:
14165
        if (value == null) {
14166
          unsetItemId();
14167
        } else {
14168
          setItemId((Long)value);
14169
        }
14170
        break;
14171
 
14172
      }
14173
    }
14174
 
14175
    public Object getFieldValue(_Fields field) {
14176
      switch (field) {
14177
      case ITEM_ID:
14178
        return Long.valueOf(getItemId());
14179
 
14180
      }
14181
      throw new IllegalStateException();
14182
    }
14183
 
14184
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14185
    public boolean isSet(_Fields field) {
14186
      if (field == null) {
14187
        throw new IllegalArgumentException();
14188
      }
14189
 
14190
      switch (field) {
14191
      case ITEM_ID:
14192
        return isSetItemId();
14193
      }
14194
      throw new IllegalStateException();
14195
    }
14196
 
14197
    @Override
14198
    public boolean equals(Object that) {
14199
      if (that == null)
14200
        return false;
14201
      if (that instanceof getAllItemPricing_args)
14202
        return this.equals((getAllItemPricing_args)that);
14203
      return false;
14204
    }
14205
 
14206
    public boolean equals(getAllItemPricing_args that) {
14207
      if (that == null)
14208
        return false;
14209
 
14210
      boolean this_present_itemId = true;
14211
      boolean that_present_itemId = true;
14212
      if (this_present_itemId || that_present_itemId) {
14213
        if (!(this_present_itemId && that_present_itemId))
14214
          return false;
14215
        if (this.itemId != that.itemId)
14216
          return false;
14217
      }
14218
 
14219
      return true;
14220
    }
14221
 
14222
    @Override
14223
    public int hashCode() {
14224
      return 0;
14225
    }
14226
 
14227
    public int compareTo(getAllItemPricing_args other) {
14228
      if (!getClass().equals(other.getClass())) {
14229
        return getClass().getName().compareTo(other.getClass().getName());
14230
      }
14231
 
14232
      int lastComparison = 0;
14233
      getAllItemPricing_args typedOther = (getAllItemPricing_args)other;
14234
 
14235
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
14236
      if (lastComparison != 0) {
14237
        return lastComparison;
14238
      }
14239
      if (isSetItemId()) {
14240
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
14241
        if (lastComparison != 0) {
14242
          return lastComparison;
14243
        }
14244
      }
14245
      return 0;
14246
    }
14247
 
14248
    public _Fields fieldForId(int fieldId) {
14249
      return _Fields.findByThriftId(fieldId);
14250
    }
14251
 
14252
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14253
      org.apache.thrift.protocol.TField field;
14254
      iprot.readStructBegin();
14255
      while (true)
14256
      {
14257
        field = iprot.readFieldBegin();
14258
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14259
          break;
14260
        }
14261
        switch (field.id) {
14262
          case 1: // ITEM_ID
14263
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14264
              this.itemId = iprot.readI64();
14265
              setItemIdIsSet(true);
14266
            } else { 
14267
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14268
            }
14269
            break;
14270
          default:
14271
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14272
        }
14273
        iprot.readFieldEnd();
14274
      }
14275
      iprot.readStructEnd();
14276
      validate();
14277
    }
14278
 
14279
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14280
      validate();
14281
 
14282
      oprot.writeStructBegin(STRUCT_DESC);
14283
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
14284
      oprot.writeI64(this.itemId);
14285
      oprot.writeFieldEnd();
14286
      oprot.writeFieldStop();
14287
      oprot.writeStructEnd();
14288
    }
14289
 
14290
    @Override
14291
    public String toString() {
14292
      StringBuilder sb = new StringBuilder("getAllItemPricing_args(");
14293
      boolean first = true;
14294
 
14295
      sb.append("itemId:");
14296
      sb.append(this.itemId);
14297
      first = false;
14298
      sb.append(")");
14299
      return sb.toString();
14300
    }
14301
 
14302
    public void validate() throws org.apache.thrift.TException {
14303
      // check for required fields
14304
    }
14305
 
14306
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14307
      try {
14308
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14309
      } catch (org.apache.thrift.TException te) {
14310
        throw new java.io.IOException(te);
14311
      }
14312
    }
14313
 
14314
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14315
      try {
14316
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14317
      } catch (org.apache.thrift.TException te) {
14318
        throw new java.io.IOException(te);
14319
      }
14320
    }
14321
 
14322
  }
14323
 
14324
  public static class getAllItemPricing_result implements org.apache.thrift.TBase<getAllItemPricing_result, getAllItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
14325
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemPricing_result");
14326
 
14327
    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);
14328
    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);
14329
 
14330
    private List<VendorItemPricing> success; // required
14331
    private InventoryServiceException cex; // required
14332
 
14333
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14334
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14335
      SUCCESS((short)0, "success"),
14336
      CEX((short)1, "cex");
14337
 
14338
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14339
 
14340
      static {
14341
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14342
          byName.put(field.getFieldName(), field);
14343
        }
14344
      }
14345
 
14346
      /**
14347
       * Find the _Fields constant that matches fieldId, or null if its not found.
14348
       */
14349
      public static _Fields findByThriftId(int fieldId) {
14350
        switch(fieldId) {
14351
          case 0: // SUCCESS
14352
            return SUCCESS;
14353
          case 1: // CEX
14354
            return CEX;
14355
          default:
14356
            return null;
14357
        }
14358
      }
14359
 
14360
      /**
14361
       * Find the _Fields constant that matches fieldId, throwing an exception
14362
       * if it is not found.
14363
       */
14364
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14365
        _Fields fields = findByThriftId(fieldId);
14366
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14367
        return fields;
14368
      }
14369
 
14370
      /**
14371
       * Find the _Fields constant that matches name, or null if its not found.
14372
       */
14373
      public static _Fields findByName(String name) {
14374
        return byName.get(name);
14375
      }
14376
 
14377
      private final short _thriftId;
14378
      private final String _fieldName;
14379
 
14380
      _Fields(short thriftId, String fieldName) {
14381
        _thriftId = thriftId;
14382
        _fieldName = fieldName;
14383
      }
14384
 
14385
      public short getThriftFieldId() {
14386
        return _thriftId;
14387
      }
14388
 
14389
      public String getFieldName() {
14390
        return _fieldName;
14391
      }
14392
    }
14393
 
14394
    // isset id assignments
14395
 
14396
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14397
    static {
14398
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14399
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14400
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
14401
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class))));
14402
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14403
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
14404
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14405
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemPricing_result.class, metaDataMap);
14406
    }
14407
 
14408
    public getAllItemPricing_result() {
14409
    }
14410
 
14411
    public getAllItemPricing_result(
14412
      List<VendorItemPricing> success,
14413
      InventoryServiceException cex)
14414
    {
14415
      this();
14416
      this.success = success;
14417
      this.cex = cex;
14418
    }
14419
 
14420
    /**
14421
     * Performs a deep copy on <i>other</i>.
14422
     */
14423
    public getAllItemPricing_result(getAllItemPricing_result other) {
14424
      if (other.isSetSuccess()) {
14425
        List<VendorItemPricing> __this__success = new ArrayList<VendorItemPricing>();
14426
        for (VendorItemPricing other_element : other.success) {
14427
          __this__success.add(new VendorItemPricing(other_element));
14428
        }
14429
        this.success = __this__success;
14430
      }
14431
      if (other.isSetCex()) {
14432
        this.cex = new InventoryServiceException(other.cex);
14433
      }
14434
    }
14435
 
14436
    public getAllItemPricing_result deepCopy() {
14437
      return new getAllItemPricing_result(this);
14438
    }
14439
 
14440
    @Override
14441
    public void clear() {
14442
      this.success = null;
14443
      this.cex = null;
14444
    }
14445
 
14446
    public int getSuccessSize() {
14447
      return (this.success == null) ? 0 : this.success.size();
14448
    }
14449
 
14450
    public java.util.Iterator<VendorItemPricing> getSuccessIterator() {
14451
      return (this.success == null) ? null : this.success.iterator();
14452
    }
14453
 
14454
    public void addToSuccess(VendorItemPricing elem) {
14455
      if (this.success == null) {
14456
        this.success = new ArrayList<VendorItemPricing>();
14457
      }
14458
      this.success.add(elem);
14459
    }
14460
 
14461
    public List<VendorItemPricing> getSuccess() {
14462
      return this.success;
14463
    }
14464
 
14465
    public void setSuccess(List<VendorItemPricing> success) {
14466
      this.success = success;
14467
    }
14468
 
14469
    public void unsetSuccess() {
14470
      this.success = null;
14471
    }
14472
 
14473
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
14474
    public boolean isSetSuccess() {
14475
      return this.success != null;
14476
    }
14477
 
14478
    public void setSuccessIsSet(boolean value) {
14479
      if (!value) {
14480
        this.success = null;
14481
      }
14482
    }
14483
 
14484
    public InventoryServiceException getCex() {
14485
      return this.cex;
14486
    }
14487
 
14488
    public void setCex(InventoryServiceException cex) {
14489
      this.cex = cex;
14490
    }
14491
 
14492
    public void unsetCex() {
14493
      this.cex = null;
14494
    }
14495
 
14496
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
14497
    public boolean isSetCex() {
14498
      return this.cex != null;
14499
    }
14500
 
14501
    public void setCexIsSet(boolean value) {
14502
      if (!value) {
14503
        this.cex = null;
14504
      }
14505
    }
14506
 
14507
    public void setFieldValue(_Fields field, Object value) {
14508
      switch (field) {
14509
      case SUCCESS:
14510
        if (value == null) {
14511
          unsetSuccess();
14512
        } else {
14513
          setSuccess((List<VendorItemPricing>)value);
14514
        }
14515
        break;
14516
 
14517
      case CEX:
14518
        if (value == null) {
14519
          unsetCex();
14520
        } else {
14521
          setCex((InventoryServiceException)value);
14522
        }
14523
        break;
14524
 
14525
      }
14526
    }
14527
 
14528
    public Object getFieldValue(_Fields field) {
14529
      switch (field) {
14530
      case SUCCESS:
14531
        return getSuccess();
14532
 
14533
      case CEX:
14534
        return getCex();
14535
 
14536
      }
14537
      throw new IllegalStateException();
14538
    }
14539
 
14540
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14541
    public boolean isSet(_Fields field) {
14542
      if (field == null) {
14543
        throw new IllegalArgumentException();
14544
      }
14545
 
14546
      switch (field) {
14547
      case SUCCESS:
14548
        return isSetSuccess();
14549
      case CEX:
14550
        return isSetCex();
14551
      }
14552
      throw new IllegalStateException();
14553
    }
14554
 
14555
    @Override
14556
    public boolean equals(Object that) {
14557
      if (that == null)
14558
        return false;
14559
      if (that instanceof getAllItemPricing_result)
14560
        return this.equals((getAllItemPricing_result)that);
14561
      return false;
14562
    }
14563
 
14564
    public boolean equals(getAllItemPricing_result that) {
14565
      if (that == null)
14566
        return false;
14567
 
14568
      boolean this_present_success = true && this.isSetSuccess();
14569
      boolean that_present_success = true && that.isSetSuccess();
14570
      if (this_present_success || that_present_success) {
14571
        if (!(this_present_success && that_present_success))
14572
          return false;
14573
        if (!this.success.equals(that.success))
14574
          return false;
14575
      }
14576
 
14577
      boolean this_present_cex = true && this.isSetCex();
14578
      boolean that_present_cex = true && that.isSetCex();
14579
      if (this_present_cex || that_present_cex) {
14580
        if (!(this_present_cex && that_present_cex))
14581
          return false;
14582
        if (!this.cex.equals(that.cex))
14583
          return false;
14584
      }
14585
 
14586
      return true;
14587
    }
14588
 
14589
    @Override
14590
    public int hashCode() {
14591
      return 0;
14592
    }
14593
 
14594
    public int compareTo(getAllItemPricing_result other) {
14595
      if (!getClass().equals(other.getClass())) {
14596
        return getClass().getName().compareTo(other.getClass().getName());
14597
      }
14598
 
14599
      int lastComparison = 0;
14600
      getAllItemPricing_result typedOther = (getAllItemPricing_result)other;
14601
 
14602
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
14603
      if (lastComparison != 0) {
14604
        return lastComparison;
14605
      }
14606
      if (isSetSuccess()) {
14607
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
14608
        if (lastComparison != 0) {
14609
          return lastComparison;
14610
        }
14611
      }
14612
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
14613
      if (lastComparison != 0) {
14614
        return lastComparison;
14615
      }
14616
      if (isSetCex()) {
14617
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
14618
        if (lastComparison != 0) {
14619
          return lastComparison;
14620
        }
14621
      }
14622
      return 0;
14623
    }
14624
 
14625
    public _Fields fieldForId(int fieldId) {
14626
      return _Fields.findByThriftId(fieldId);
14627
    }
14628
 
14629
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14630
      org.apache.thrift.protocol.TField field;
14631
      iprot.readStructBegin();
14632
      while (true)
14633
      {
14634
        field = iprot.readFieldBegin();
14635
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14636
          break;
14637
        }
14638
        switch (field.id) {
14639
          case 0: // SUCCESS
14640
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
14641
              {
14642
                org.apache.thrift.protocol.TList _list32 = iprot.readListBegin();
14643
                this.success = new ArrayList<VendorItemPricing>(_list32.size);
14644
                for (int _i33 = 0; _i33 < _list32.size; ++_i33)
14645
                {
14646
                  VendorItemPricing _elem34; // required
14647
                  _elem34 = new VendorItemPricing();
14648
                  _elem34.read(iprot);
14649
                  this.success.add(_elem34);
14650
                }
14651
                iprot.readListEnd();
14652
              }
14653
            } else { 
14654
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14655
            }
14656
            break;
14657
          case 1: // CEX
14658
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
14659
              this.cex = new InventoryServiceException();
14660
              this.cex.read(iprot);
14661
            } else { 
14662
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14663
            }
14664
            break;
14665
          default:
14666
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14667
        }
14668
        iprot.readFieldEnd();
14669
      }
14670
      iprot.readStructEnd();
14671
      validate();
14672
    }
14673
 
14674
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14675
      oprot.writeStructBegin(STRUCT_DESC);
14676
 
14677
      if (this.isSetSuccess()) {
14678
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
14679
        {
14680
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
14681
          for (VendorItemPricing _iter35 : this.success)
14682
          {
14683
            _iter35.write(oprot);
14684
          }
14685
          oprot.writeListEnd();
14686
        }
14687
        oprot.writeFieldEnd();
14688
      } else if (this.isSetCex()) {
14689
        oprot.writeFieldBegin(CEX_FIELD_DESC);
14690
        this.cex.write(oprot);
14691
        oprot.writeFieldEnd();
14692
      }
14693
      oprot.writeFieldStop();
14694
      oprot.writeStructEnd();
14695
    }
14696
 
14697
    @Override
14698
    public String toString() {
14699
      StringBuilder sb = new StringBuilder("getAllItemPricing_result(");
14700
      boolean first = true;
14701
 
14702
      sb.append("success:");
14703
      if (this.success == null) {
14704
        sb.append("null");
14705
      } else {
14706
        sb.append(this.success);
14707
      }
14708
      first = false;
14709
      if (!first) sb.append(", ");
14710
      sb.append("cex:");
14711
      if (this.cex == null) {
14712
        sb.append("null");
14713
      } else {
14714
        sb.append(this.cex);
14715
      }
14716
      first = false;
14717
      sb.append(")");
14718
      return sb.toString();
14719
    }
14720
 
14721
    public void validate() throws org.apache.thrift.TException {
14722
      // check for required fields
14723
    }
14724
 
14725
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14726
      try {
14727
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14728
      } catch (org.apache.thrift.TException te) {
14729
        throw new java.io.IOException(te);
14730
      }
14731
    }
14732
 
14733
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14734
      try {
14735
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14736
      } catch (org.apache.thrift.TException te) {
14737
        throw new java.io.IOException(te);
14738
      }
14739
    }
14740
 
14741
  }
14742
 
14743
  public static class addVendorItemPricing_args implements org.apache.thrift.TBase<addVendorItemPricing_args, addVendorItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
14744
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemPricing_args");
14745
 
14746
    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);
14747
 
14748
    private VendorItemPricing vendorItemPricing; // required
14749
 
14750
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14751
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14752
      VENDOR_ITEM_PRICING((short)1, "vendorItemPricing");
14753
 
14754
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14755
 
14756
      static {
14757
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14758
          byName.put(field.getFieldName(), field);
14759
        }
14760
      }
14761
 
14762
      /**
14763
       * Find the _Fields constant that matches fieldId, or null if its not found.
14764
       */
14765
      public static _Fields findByThriftId(int fieldId) {
14766
        switch(fieldId) {
14767
          case 1: // VENDOR_ITEM_PRICING
14768
            return VENDOR_ITEM_PRICING;
14769
          default:
14770
            return null;
14771
        }
14772
      }
14773
 
14774
      /**
14775
       * Find the _Fields constant that matches fieldId, throwing an exception
14776
       * if it is not found.
14777
       */
14778
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14779
        _Fields fields = findByThriftId(fieldId);
14780
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14781
        return fields;
14782
      }
14783
 
14784
      /**
14785
       * Find the _Fields constant that matches name, or null if its not found.
14786
       */
14787
      public static _Fields findByName(String name) {
14788
        return byName.get(name);
14789
      }
14790
 
14791
      private final short _thriftId;
14792
      private final String _fieldName;
14793
 
14794
      _Fields(short thriftId, String fieldName) {
14795
        _thriftId = thriftId;
14796
        _fieldName = fieldName;
14797
      }
14798
 
14799
      public short getThriftFieldId() {
14800
        return _thriftId;
14801
      }
14802
 
14803
      public String getFieldName() {
14804
        return _fieldName;
14805
      }
14806
    }
14807
 
14808
    // isset id assignments
14809
 
14810
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14811
    static {
14812
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14813
      tmpMap.put(_Fields.VENDOR_ITEM_PRICING, new org.apache.thrift.meta_data.FieldMetaData("vendorItemPricing", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14814
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class)));
14815
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14816
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemPricing_args.class, metaDataMap);
14817
    }
14818
 
14819
    public addVendorItemPricing_args() {
14820
    }
14821
 
14822
    public addVendorItemPricing_args(
14823
      VendorItemPricing vendorItemPricing)
14824
    {
14825
      this();
14826
      this.vendorItemPricing = vendorItemPricing;
14827
    }
14828
 
14829
    /**
14830
     * Performs a deep copy on <i>other</i>.
14831
     */
14832
    public addVendorItemPricing_args(addVendorItemPricing_args other) {
14833
      if (other.isSetVendorItemPricing()) {
14834
        this.vendorItemPricing = new VendorItemPricing(other.vendorItemPricing);
14835
      }
14836
    }
14837
 
14838
    public addVendorItemPricing_args deepCopy() {
14839
      return new addVendorItemPricing_args(this);
14840
    }
14841
 
14842
    @Override
14843
    public void clear() {
14844
      this.vendorItemPricing = null;
14845
    }
14846
 
14847
    public VendorItemPricing getVendorItemPricing() {
14848
      return this.vendorItemPricing;
14849
    }
14850
 
14851
    public void setVendorItemPricing(VendorItemPricing vendorItemPricing) {
14852
      this.vendorItemPricing = vendorItemPricing;
14853
    }
14854
 
14855
    public void unsetVendorItemPricing() {
14856
      this.vendorItemPricing = null;
14857
    }
14858
 
14859
    /** Returns true if field vendorItemPricing is set (has been assigned a value) and false otherwise */
14860
    public boolean isSetVendorItemPricing() {
14861
      return this.vendorItemPricing != null;
14862
    }
14863
 
14864
    public void setVendorItemPricingIsSet(boolean value) {
14865
      if (!value) {
14866
        this.vendorItemPricing = null;
14867
      }
14868
    }
14869
 
14870
    public void setFieldValue(_Fields field, Object value) {
14871
      switch (field) {
14872
      case VENDOR_ITEM_PRICING:
14873
        if (value == null) {
14874
          unsetVendorItemPricing();
14875
        } else {
14876
          setVendorItemPricing((VendorItemPricing)value);
14877
        }
14878
        break;
14879
 
14880
      }
14881
    }
14882
 
14883
    public Object getFieldValue(_Fields field) {
14884
      switch (field) {
14885
      case VENDOR_ITEM_PRICING:
14886
        return getVendorItemPricing();
14887
 
14888
      }
14889
      throw new IllegalStateException();
14890
    }
14891
 
14892
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14893
    public boolean isSet(_Fields field) {
14894
      if (field == null) {
14895
        throw new IllegalArgumentException();
14896
      }
14897
 
14898
      switch (field) {
14899
      case VENDOR_ITEM_PRICING:
14900
        return isSetVendorItemPricing();
14901
      }
14902
      throw new IllegalStateException();
14903
    }
14904
 
14905
    @Override
14906
    public boolean equals(Object that) {
14907
      if (that == null)
14908
        return false;
14909
      if (that instanceof addVendorItemPricing_args)
14910
        return this.equals((addVendorItemPricing_args)that);
14911
      return false;
14912
    }
14913
 
14914
    public boolean equals(addVendorItemPricing_args that) {
14915
      if (that == null)
14916
        return false;
14917
 
14918
      boolean this_present_vendorItemPricing = true && this.isSetVendorItemPricing();
14919
      boolean that_present_vendorItemPricing = true && that.isSetVendorItemPricing();
14920
      if (this_present_vendorItemPricing || that_present_vendorItemPricing) {
14921
        if (!(this_present_vendorItemPricing && that_present_vendorItemPricing))
14922
          return false;
14923
        if (!this.vendorItemPricing.equals(that.vendorItemPricing))
14924
          return false;
14925
      }
14926
 
14927
      return true;
14928
    }
14929
 
14930
    @Override
14931
    public int hashCode() {
14932
      return 0;
14933
    }
14934
 
14935
    public int compareTo(addVendorItemPricing_args other) {
14936
      if (!getClass().equals(other.getClass())) {
14937
        return getClass().getName().compareTo(other.getClass().getName());
14938
      }
14939
 
14940
      int lastComparison = 0;
14941
      addVendorItemPricing_args typedOther = (addVendorItemPricing_args)other;
14942
 
14943
      lastComparison = Boolean.valueOf(isSetVendorItemPricing()).compareTo(typedOther.isSetVendorItemPricing());
14944
      if (lastComparison != 0) {
14945
        return lastComparison;
14946
      }
14947
      if (isSetVendorItemPricing()) {
14948
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorItemPricing, typedOther.vendorItemPricing);
14949
        if (lastComparison != 0) {
14950
          return lastComparison;
14951
        }
14952
      }
14953
      return 0;
14954
    }
14955
 
14956
    public _Fields fieldForId(int fieldId) {
14957
      return _Fields.findByThriftId(fieldId);
14958
    }
14959
 
14960
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14961
      org.apache.thrift.protocol.TField field;
14962
      iprot.readStructBegin();
14963
      while (true)
14964
      {
14965
        field = iprot.readFieldBegin();
14966
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14967
          break;
14968
        }
14969
        switch (field.id) {
14970
          case 1: // VENDOR_ITEM_PRICING
14971
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
14972
              this.vendorItemPricing = new VendorItemPricing();
14973
              this.vendorItemPricing.read(iprot);
14974
            } else { 
14975
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14976
            }
14977
            break;
14978
          default:
14979
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14980
        }
14981
        iprot.readFieldEnd();
14982
      }
14983
      iprot.readStructEnd();
14984
      validate();
14985
    }
14986
 
14987
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14988
      validate();
14989
 
14990
      oprot.writeStructBegin(STRUCT_DESC);
14991
      if (this.vendorItemPricing != null) {
14992
        oprot.writeFieldBegin(VENDOR_ITEM_PRICING_FIELD_DESC);
14993
        this.vendorItemPricing.write(oprot);
14994
        oprot.writeFieldEnd();
14995
      }
14996
      oprot.writeFieldStop();
14997
      oprot.writeStructEnd();
14998
    }
14999
 
15000
    @Override
15001
    public String toString() {
15002
      StringBuilder sb = new StringBuilder("addVendorItemPricing_args(");
15003
      boolean first = true;
15004
 
15005
      sb.append("vendorItemPricing:");
15006
      if (this.vendorItemPricing == null) {
15007
        sb.append("null");
15008
      } else {
15009
        sb.append(this.vendorItemPricing);
15010
      }
15011
      first = false;
15012
      sb.append(")");
15013
      return sb.toString();
15014
    }
15015
 
15016
    public void validate() throws org.apache.thrift.TException {
15017
      // check for required fields
15018
    }
15019
 
15020
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15021
      try {
15022
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15023
      } catch (org.apache.thrift.TException te) {
15024
        throw new java.io.IOException(te);
15025
      }
15026
    }
15027
 
15028
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15029
      try {
15030
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15031
      } catch (org.apache.thrift.TException te) {
15032
        throw new java.io.IOException(te);
15033
      }
15034
    }
15035
 
15036
  }
15037
 
15038
  public static class addVendorItemPricing_result implements org.apache.thrift.TBase<addVendorItemPricing_result, addVendorItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
15039
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemPricing_result");
15040
 
15041
    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);
15042
 
15043
    private InventoryServiceException cex; // required
15044
 
15045
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15046
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15047
      CEX((short)1, "cex");
15048
 
15049
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15050
 
15051
      static {
15052
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15053
          byName.put(field.getFieldName(), field);
15054
        }
15055
      }
15056
 
15057
      /**
15058
       * Find the _Fields constant that matches fieldId, or null if its not found.
15059
       */
15060
      public static _Fields findByThriftId(int fieldId) {
15061
        switch(fieldId) {
15062
          case 1: // CEX
15063
            return CEX;
15064
          default:
15065
            return null;
15066
        }
15067
      }
15068
 
15069
      /**
15070
       * Find the _Fields constant that matches fieldId, throwing an exception
15071
       * if it is not found.
15072
       */
15073
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15074
        _Fields fields = findByThriftId(fieldId);
15075
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15076
        return fields;
15077
      }
15078
 
15079
      /**
15080
       * Find the _Fields constant that matches name, or null if its not found.
15081
       */
15082
      public static _Fields findByName(String name) {
15083
        return byName.get(name);
15084
      }
15085
 
15086
      private final short _thriftId;
15087
      private final String _fieldName;
15088
 
15089
      _Fields(short thriftId, String fieldName) {
15090
        _thriftId = thriftId;
15091
        _fieldName = fieldName;
15092
      }
15093
 
15094
      public short getThriftFieldId() {
15095
        return _thriftId;
15096
      }
15097
 
15098
      public String getFieldName() {
15099
        return _fieldName;
15100
      }
15101
    }
15102
 
15103
    // isset id assignments
15104
 
15105
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15106
    static {
15107
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15108
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15109
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
15110
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15111
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemPricing_result.class, metaDataMap);
15112
    }
15113
 
15114
    public addVendorItemPricing_result() {
15115
    }
15116
 
15117
    public addVendorItemPricing_result(
15118
      InventoryServiceException cex)
15119
    {
15120
      this();
15121
      this.cex = cex;
15122
    }
15123
 
15124
    /**
15125
     * Performs a deep copy on <i>other</i>.
15126
     */
15127
    public addVendorItemPricing_result(addVendorItemPricing_result other) {
15128
      if (other.isSetCex()) {
15129
        this.cex = new InventoryServiceException(other.cex);
15130
      }
15131
    }
15132
 
15133
    public addVendorItemPricing_result deepCopy() {
15134
      return new addVendorItemPricing_result(this);
15135
    }
15136
 
15137
    @Override
15138
    public void clear() {
15139
      this.cex = null;
15140
    }
15141
 
15142
    public InventoryServiceException getCex() {
15143
      return this.cex;
15144
    }
15145
 
15146
    public void setCex(InventoryServiceException cex) {
15147
      this.cex = cex;
15148
    }
15149
 
15150
    public void unsetCex() {
15151
      this.cex = null;
15152
    }
15153
 
15154
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
15155
    public boolean isSetCex() {
15156
      return this.cex != null;
15157
    }
15158
 
15159
    public void setCexIsSet(boolean value) {
15160
      if (!value) {
15161
        this.cex = null;
15162
      }
15163
    }
15164
 
15165
    public void setFieldValue(_Fields field, Object value) {
15166
      switch (field) {
15167
      case CEX:
15168
        if (value == null) {
15169
          unsetCex();
15170
        } else {
15171
          setCex((InventoryServiceException)value);
15172
        }
15173
        break;
15174
 
15175
      }
15176
    }
15177
 
15178
    public Object getFieldValue(_Fields field) {
15179
      switch (field) {
15180
      case CEX:
15181
        return getCex();
15182
 
15183
      }
15184
      throw new IllegalStateException();
15185
    }
15186
 
15187
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15188
    public boolean isSet(_Fields field) {
15189
      if (field == null) {
15190
        throw new IllegalArgumentException();
15191
      }
15192
 
15193
      switch (field) {
15194
      case CEX:
15195
        return isSetCex();
15196
      }
15197
      throw new IllegalStateException();
15198
    }
15199
 
15200
    @Override
15201
    public boolean equals(Object that) {
15202
      if (that == null)
15203
        return false;
15204
      if (that instanceof addVendorItemPricing_result)
15205
        return this.equals((addVendorItemPricing_result)that);
15206
      return false;
15207
    }
15208
 
15209
    public boolean equals(addVendorItemPricing_result that) {
15210
      if (that == null)
15211
        return false;
15212
 
15213
      boolean this_present_cex = true && this.isSetCex();
15214
      boolean that_present_cex = true && that.isSetCex();
15215
      if (this_present_cex || that_present_cex) {
15216
        if (!(this_present_cex && that_present_cex))
15217
          return false;
15218
        if (!this.cex.equals(that.cex))
15219
          return false;
15220
      }
15221
 
15222
      return true;
15223
    }
15224
 
15225
    @Override
15226
    public int hashCode() {
15227
      return 0;
15228
    }
15229
 
15230
    public int compareTo(addVendorItemPricing_result other) {
15231
      if (!getClass().equals(other.getClass())) {
15232
        return getClass().getName().compareTo(other.getClass().getName());
15233
      }
15234
 
15235
      int lastComparison = 0;
15236
      addVendorItemPricing_result typedOther = (addVendorItemPricing_result)other;
15237
 
15238
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
15239
      if (lastComparison != 0) {
15240
        return lastComparison;
15241
      }
15242
      if (isSetCex()) {
15243
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
15244
        if (lastComparison != 0) {
15245
          return lastComparison;
15246
        }
15247
      }
15248
      return 0;
15249
    }
15250
 
15251
    public _Fields fieldForId(int fieldId) {
15252
      return _Fields.findByThriftId(fieldId);
15253
    }
15254
 
15255
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15256
      org.apache.thrift.protocol.TField field;
15257
      iprot.readStructBegin();
15258
      while (true)
15259
      {
15260
        field = iprot.readFieldBegin();
15261
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15262
          break;
15263
        }
15264
        switch (field.id) {
15265
          case 1: // CEX
15266
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15267
              this.cex = new InventoryServiceException();
15268
              this.cex.read(iprot);
15269
            } else { 
15270
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15271
            }
15272
            break;
15273
          default:
15274
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15275
        }
15276
        iprot.readFieldEnd();
15277
      }
15278
      iprot.readStructEnd();
15279
      validate();
15280
    }
15281
 
15282
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15283
      oprot.writeStructBegin(STRUCT_DESC);
15284
 
15285
      if (this.isSetCex()) {
15286
        oprot.writeFieldBegin(CEX_FIELD_DESC);
15287
        this.cex.write(oprot);
15288
        oprot.writeFieldEnd();
15289
      }
15290
      oprot.writeFieldStop();
15291
      oprot.writeStructEnd();
15292
    }
15293
 
15294
    @Override
15295
    public String toString() {
15296
      StringBuilder sb = new StringBuilder("addVendorItemPricing_result(");
15297
      boolean first = true;
15298
 
15299
      sb.append("cex:");
15300
      if (this.cex == null) {
15301
        sb.append("null");
15302
      } else {
15303
        sb.append(this.cex);
15304
      }
15305
      first = false;
15306
      sb.append(")");
15307
      return sb.toString();
15308
    }
15309
 
15310
    public void validate() throws org.apache.thrift.TException {
15311
      // check for required fields
15312
    }
15313
 
15314
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15315
      try {
15316
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15317
      } catch (org.apache.thrift.TException te) {
15318
        throw new java.io.IOException(te);
15319
      }
15320
    }
15321
 
15322
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15323
      try {
15324
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15325
      } catch (org.apache.thrift.TException te) {
15326
        throw new java.io.IOException(te);
15327
      }
15328
    }
15329
 
15330
  }
15331
 
15332
  public static class getVendor_args implements org.apache.thrift.TBase<getVendor_args, getVendor_args._Fields>, java.io.Serializable, Cloneable   {
15333
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendor_args");
15334
 
15335
    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);
15336
 
15337
    private long vendorId; // required
15338
 
15339
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15340
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15341
      VENDOR_ID((short)1, "vendorId");
15342
 
15343
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15344
 
15345
      static {
15346
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15347
          byName.put(field.getFieldName(), field);
15348
        }
15349
      }
15350
 
15351
      /**
15352
       * Find the _Fields constant that matches fieldId, or null if its not found.
15353
       */
15354
      public static _Fields findByThriftId(int fieldId) {
15355
        switch(fieldId) {
15356
          case 1: // VENDOR_ID
15357
            return VENDOR_ID;
15358
          default:
15359
            return null;
15360
        }
15361
      }
15362
 
15363
      /**
15364
       * Find the _Fields constant that matches fieldId, throwing an exception
15365
       * if it is not found.
15366
       */
15367
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15368
        _Fields fields = findByThriftId(fieldId);
15369
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15370
        return fields;
15371
      }
15372
 
15373
      /**
15374
       * Find the _Fields constant that matches name, or null if its not found.
15375
       */
15376
      public static _Fields findByName(String name) {
15377
        return byName.get(name);
15378
      }
15379
 
15380
      private final short _thriftId;
15381
      private final String _fieldName;
15382
 
15383
      _Fields(short thriftId, String fieldName) {
15384
        _thriftId = thriftId;
15385
        _fieldName = fieldName;
15386
      }
15387
 
15388
      public short getThriftFieldId() {
15389
        return _thriftId;
15390
      }
15391
 
15392
      public String getFieldName() {
15393
        return _fieldName;
15394
      }
15395
    }
15396
 
15397
    // isset id assignments
15398
    private static final int __VENDORID_ISSET_ID = 0;
15399
    private BitSet __isset_bit_vector = new BitSet(1);
15400
 
15401
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15402
    static {
15403
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15404
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15405
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
15406
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15407
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendor_args.class, metaDataMap);
15408
    }
15409
 
15410
    public getVendor_args() {
15411
    }
15412
 
15413
    public getVendor_args(
15414
      long vendorId)
15415
    {
15416
      this();
15417
      this.vendorId = vendorId;
15418
      setVendorIdIsSet(true);
15419
    }
15420
 
15421
    /**
15422
     * Performs a deep copy on <i>other</i>.
15423
     */
15424
    public getVendor_args(getVendor_args other) {
15425
      __isset_bit_vector.clear();
15426
      __isset_bit_vector.or(other.__isset_bit_vector);
15427
      this.vendorId = other.vendorId;
15428
    }
15429
 
15430
    public getVendor_args deepCopy() {
15431
      return new getVendor_args(this);
15432
    }
15433
 
15434
    @Override
15435
    public void clear() {
15436
      setVendorIdIsSet(false);
15437
      this.vendorId = 0;
15438
    }
15439
 
15440
    public long getVendorId() {
15441
      return this.vendorId;
15442
    }
15443
 
15444
    public void setVendorId(long vendorId) {
15445
      this.vendorId = vendorId;
15446
      setVendorIdIsSet(true);
15447
    }
15448
 
15449
    public void unsetVendorId() {
15450
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
15451
    }
15452
 
15453
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
15454
    public boolean isSetVendorId() {
15455
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
15456
    }
15457
 
15458
    public void setVendorIdIsSet(boolean value) {
15459
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
15460
    }
15461
 
15462
    public void setFieldValue(_Fields field, Object value) {
15463
      switch (field) {
15464
      case VENDOR_ID:
15465
        if (value == null) {
15466
          unsetVendorId();
15467
        } else {
15468
          setVendorId((Long)value);
15469
        }
15470
        break;
15471
 
15472
      }
15473
    }
15474
 
15475
    public Object getFieldValue(_Fields field) {
15476
      switch (field) {
15477
      case VENDOR_ID:
15478
        return Long.valueOf(getVendorId());
15479
 
15480
      }
15481
      throw new IllegalStateException();
15482
    }
15483
 
15484
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15485
    public boolean isSet(_Fields field) {
15486
      if (field == null) {
15487
        throw new IllegalArgumentException();
15488
      }
15489
 
15490
      switch (field) {
15491
      case VENDOR_ID:
15492
        return isSetVendorId();
15493
      }
15494
      throw new IllegalStateException();
15495
    }
15496
 
15497
    @Override
15498
    public boolean equals(Object that) {
15499
      if (that == null)
15500
        return false;
15501
      if (that instanceof getVendor_args)
15502
        return this.equals((getVendor_args)that);
15503
      return false;
15504
    }
15505
 
15506
    public boolean equals(getVendor_args that) {
15507
      if (that == null)
15508
        return false;
15509
 
15510
      boolean this_present_vendorId = true;
15511
      boolean that_present_vendorId = true;
15512
      if (this_present_vendorId || that_present_vendorId) {
15513
        if (!(this_present_vendorId && that_present_vendorId))
15514
          return false;
15515
        if (this.vendorId != that.vendorId)
15516
          return false;
15517
      }
15518
 
15519
      return true;
15520
    }
15521
 
15522
    @Override
15523
    public int hashCode() {
15524
      return 0;
15525
    }
15526
 
15527
    public int compareTo(getVendor_args other) {
15528
      if (!getClass().equals(other.getClass())) {
15529
        return getClass().getName().compareTo(other.getClass().getName());
15530
      }
15531
 
15532
      int lastComparison = 0;
15533
      getVendor_args typedOther = (getVendor_args)other;
15534
 
15535
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
15536
      if (lastComparison != 0) {
15537
        return lastComparison;
15538
      }
15539
      if (isSetVendorId()) {
15540
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
15541
        if (lastComparison != 0) {
15542
          return lastComparison;
15543
        }
15544
      }
15545
      return 0;
15546
    }
15547
 
15548
    public _Fields fieldForId(int fieldId) {
15549
      return _Fields.findByThriftId(fieldId);
15550
    }
15551
 
15552
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15553
      org.apache.thrift.protocol.TField field;
15554
      iprot.readStructBegin();
15555
      while (true)
15556
      {
15557
        field = iprot.readFieldBegin();
15558
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15559
          break;
15560
        }
15561
        switch (field.id) {
15562
          case 1: // VENDOR_ID
15563
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15564
              this.vendorId = iprot.readI64();
15565
              setVendorIdIsSet(true);
15566
            } else { 
15567
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15568
            }
15569
            break;
15570
          default:
15571
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15572
        }
15573
        iprot.readFieldEnd();
15574
      }
15575
      iprot.readStructEnd();
15576
      validate();
15577
    }
15578
 
15579
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15580
      validate();
15581
 
15582
      oprot.writeStructBegin(STRUCT_DESC);
15583
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
15584
      oprot.writeI64(this.vendorId);
15585
      oprot.writeFieldEnd();
15586
      oprot.writeFieldStop();
15587
      oprot.writeStructEnd();
15588
    }
15589
 
15590
    @Override
15591
    public String toString() {
15592
      StringBuilder sb = new StringBuilder("getVendor_args(");
15593
      boolean first = true;
15594
 
15595
      sb.append("vendorId:");
15596
      sb.append(this.vendorId);
15597
      first = false;
15598
      sb.append(")");
15599
      return sb.toString();
15600
    }
15601
 
15602
    public void validate() throws org.apache.thrift.TException {
15603
      // check for required fields
15604
    }
15605
 
15606
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15607
      try {
15608
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15609
      } catch (org.apache.thrift.TException te) {
15610
        throw new java.io.IOException(te);
15611
      }
15612
    }
15613
 
15614
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15615
      try {
15616
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
15617
        __isset_bit_vector = new BitSet(1);
15618
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15619
      } catch (org.apache.thrift.TException te) {
15620
        throw new java.io.IOException(te);
15621
      }
15622
    }
15623
 
15624
  }
15625
 
15626
  public static class getVendor_result implements org.apache.thrift.TBase<getVendor_result, getVendor_result._Fields>, java.io.Serializable, Cloneable   {
15627
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendor_result");
15628
 
15629
    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);
15630
 
15631
    private Vendor success; // required
15632
 
15633
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15634
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15635
      SUCCESS((short)0, "success");
15636
 
15637
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15638
 
15639
      static {
15640
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15641
          byName.put(field.getFieldName(), field);
15642
        }
15643
      }
15644
 
15645
      /**
15646
       * Find the _Fields constant that matches fieldId, or null if its not found.
15647
       */
15648
      public static _Fields findByThriftId(int fieldId) {
15649
        switch(fieldId) {
15650
          case 0: // SUCCESS
15651
            return SUCCESS;
15652
          default:
15653
            return null;
15654
        }
15655
      }
15656
 
15657
      /**
15658
       * Find the _Fields constant that matches fieldId, throwing an exception
15659
       * if it is not found.
15660
       */
15661
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15662
        _Fields fields = findByThriftId(fieldId);
15663
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15664
        return fields;
15665
      }
15666
 
15667
      /**
15668
       * Find the _Fields constant that matches name, or null if its not found.
15669
       */
15670
      public static _Fields findByName(String name) {
15671
        return byName.get(name);
15672
      }
15673
 
15674
      private final short _thriftId;
15675
      private final String _fieldName;
15676
 
15677
      _Fields(short thriftId, String fieldName) {
15678
        _thriftId = thriftId;
15679
        _fieldName = fieldName;
15680
      }
15681
 
15682
      public short getThriftFieldId() {
15683
        return _thriftId;
15684
      }
15685
 
15686
      public String getFieldName() {
15687
        return _fieldName;
15688
      }
15689
    }
15690
 
15691
    // isset id assignments
15692
 
15693
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15694
    static {
15695
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15696
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15697
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class)));
15698
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15699
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendor_result.class, metaDataMap);
15700
    }
15701
 
15702
    public getVendor_result() {
15703
    }
15704
 
15705
    public getVendor_result(
15706
      Vendor success)
15707
    {
15708
      this();
15709
      this.success = success;
15710
    }
15711
 
15712
    /**
15713
     * Performs a deep copy on <i>other</i>.
15714
     */
15715
    public getVendor_result(getVendor_result other) {
15716
      if (other.isSetSuccess()) {
15717
        this.success = new Vendor(other.success);
15718
      }
15719
    }
15720
 
15721
    public getVendor_result deepCopy() {
15722
      return new getVendor_result(this);
15723
    }
15724
 
15725
    @Override
15726
    public void clear() {
15727
      this.success = null;
15728
    }
15729
 
15730
    public Vendor getSuccess() {
15731
      return this.success;
15732
    }
15733
 
15734
    public void setSuccess(Vendor success) {
15735
      this.success = success;
15736
    }
15737
 
15738
    public void unsetSuccess() {
15739
      this.success = null;
15740
    }
15741
 
15742
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
15743
    public boolean isSetSuccess() {
15744
      return this.success != null;
15745
    }
15746
 
15747
    public void setSuccessIsSet(boolean value) {
15748
      if (!value) {
15749
        this.success = null;
15750
      }
15751
    }
15752
 
15753
    public void setFieldValue(_Fields field, Object value) {
15754
      switch (field) {
15755
      case SUCCESS:
15756
        if (value == null) {
15757
          unsetSuccess();
15758
        } else {
15759
          setSuccess((Vendor)value);
15760
        }
15761
        break;
15762
 
15763
      }
15764
    }
15765
 
15766
    public Object getFieldValue(_Fields field) {
15767
      switch (field) {
15768
      case SUCCESS:
15769
        return getSuccess();
15770
 
15771
      }
15772
      throw new IllegalStateException();
15773
    }
15774
 
15775
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15776
    public boolean isSet(_Fields field) {
15777
      if (field == null) {
15778
        throw new IllegalArgumentException();
15779
      }
15780
 
15781
      switch (field) {
15782
      case SUCCESS:
15783
        return isSetSuccess();
15784
      }
15785
      throw new IllegalStateException();
15786
    }
15787
 
15788
    @Override
15789
    public boolean equals(Object that) {
15790
      if (that == null)
15791
        return false;
15792
      if (that instanceof getVendor_result)
15793
        return this.equals((getVendor_result)that);
15794
      return false;
15795
    }
15796
 
15797
    public boolean equals(getVendor_result that) {
15798
      if (that == null)
15799
        return false;
15800
 
15801
      boolean this_present_success = true && this.isSetSuccess();
15802
      boolean that_present_success = true && that.isSetSuccess();
15803
      if (this_present_success || that_present_success) {
15804
        if (!(this_present_success && that_present_success))
15805
          return false;
15806
        if (!this.success.equals(that.success))
15807
          return false;
15808
      }
15809
 
15810
      return true;
15811
    }
15812
 
15813
    @Override
15814
    public int hashCode() {
15815
      return 0;
15816
    }
15817
 
15818
    public int compareTo(getVendor_result other) {
15819
      if (!getClass().equals(other.getClass())) {
15820
        return getClass().getName().compareTo(other.getClass().getName());
15821
      }
15822
 
15823
      int lastComparison = 0;
15824
      getVendor_result typedOther = (getVendor_result)other;
15825
 
15826
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
15827
      if (lastComparison != 0) {
15828
        return lastComparison;
15829
      }
15830
      if (isSetSuccess()) {
15831
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
15832
        if (lastComparison != 0) {
15833
          return lastComparison;
15834
        }
15835
      }
15836
      return 0;
15837
    }
15838
 
15839
    public _Fields fieldForId(int fieldId) {
15840
      return _Fields.findByThriftId(fieldId);
15841
    }
15842
 
15843
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15844
      org.apache.thrift.protocol.TField field;
15845
      iprot.readStructBegin();
15846
      while (true)
15847
      {
15848
        field = iprot.readFieldBegin();
15849
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15850
          break;
15851
        }
15852
        switch (field.id) {
15853
          case 0: // SUCCESS
15854
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15855
              this.success = new Vendor();
15856
              this.success.read(iprot);
15857
            } else { 
15858
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15859
            }
15860
            break;
15861
          default:
15862
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15863
        }
15864
        iprot.readFieldEnd();
15865
      }
15866
      iprot.readStructEnd();
15867
      validate();
15868
    }
15869
 
15870
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15871
      oprot.writeStructBegin(STRUCT_DESC);
15872
 
15873
      if (this.isSetSuccess()) {
15874
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
15875
        this.success.write(oprot);
15876
        oprot.writeFieldEnd();
15877
      }
15878
      oprot.writeFieldStop();
15879
      oprot.writeStructEnd();
15880
    }
15881
 
15882
    @Override
15883
    public String toString() {
15884
      StringBuilder sb = new StringBuilder("getVendor_result(");
15885
      boolean first = true;
15886
 
15887
      sb.append("success:");
15888
      if (this.success == null) {
15889
        sb.append("null");
15890
      } else {
15891
        sb.append(this.success);
15892
      }
15893
      first = false;
15894
      sb.append(")");
15895
      return sb.toString();
15896
    }
15897
 
15898
    public void validate() throws org.apache.thrift.TException {
15899
      // check for required fields
15900
    }
15901
 
15902
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15903
      try {
15904
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15905
      } catch (org.apache.thrift.TException te) {
15906
        throw new java.io.IOException(te);
15907
      }
15908
    }
15909
 
15910
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15911
      try {
15912
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15913
      } catch (org.apache.thrift.TException te) {
15914
        throw new java.io.IOException(te);
15915
      }
15916
    }
15917
 
15918
  }
15919
 
15920
  public static class getAllVendors_args implements org.apache.thrift.TBase<getAllVendors_args, getAllVendors_args._Fields>, java.io.Serializable, Cloneable   {
15921
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendors_args");
15922
 
15923
 
15924
 
15925
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15926
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15927
;
15928
 
15929
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15930
 
15931
      static {
15932
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15933
          byName.put(field.getFieldName(), field);
15934
        }
15935
      }
15936
 
15937
      /**
15938
       * Find the _Fields constant that matches fieldId, or null if its not found.
15939
       */
15940
      public static _Fields findByThriftId(int fieldId) {
15941
        switch(fieldId) {
15942
          default:
15943
            return null;
15944
        }
15945
      }
15946
 
15947
      /**
15948
       * Find the _Fields constant that matches fieldId, throwing an exception
15949
       * if it is not found.
15950
       */
15951
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15952
        _Fields fields = findByThriftId(fieldId);
15953
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15954
        return fields;
15955
      }
15956
 
15957
      /**
15958
       * Find the _Fields constant that matches name, or null if its not found.
15959
       */
15960
      public static _Fields findByName(String name) {
15961
        return byName.get(name);
15962
      }
15963
 
15964
      private final short _thriftId;
15965
      private final String _fieldName;
15966
 
15967
      _Fields(short thriftId, String fieldName) {
15968
        _thriftId = thriftId;
15969
        _fieldName = fieldName;
15970
      }
15971
 
15972
      public short getThriftFieldId() {
15973
        return _thriftId;
15974
      }
15975
 
15976
      public String getFieldName() {
15977
        return _fieldName;
15978
      }
15979
    }
15980
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15981
    static {
15982
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15983
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15984
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendors_args.class, metaDataMap);
15985
    }
15986
 
15987
    public getAllVendors_args() {
15988
    }
15989
 
15990
    /**
15991
     * Performs a deep copy on <i>other</i>.
15992
     */
15993
    public getAllVendors_args(getAllVendors_args other) {
15994
    }
15995
 
15996
    public getAllVendors_args deepCopy() {
15997
      return new getAllVendors_args(this);
15998
    }
15999
 
16000
    @Override
16001
    public void clear() {
16002
    }
16003
 
16004
    public void setFieldValue(_Fields field, Object value) {
16005
      switch (field) {
16006
      }
16007
    }
16008
 
16009
    public Object getFieldValue(_Fields field) {
16010
      switch (field) {
16011
      }
16012
      throw new IllegalStateException();
16013
    }
16014
 
16015
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16016
    public boolean isSet(_Fields field) {
16017
      if (field == null) {
16018
        throw new IllegalArgumentException();
16019
      }
16020
 
16021
      switch (field) {
16022
      }
16023
      throw new IllegalStateException();
16024
    }
16025
 
16026
    @Override
16027
    public boolean equals(Object that) {
16028
      if (that == null)
16029
        return false;
16030
      if (that instanceof getAllVendors_args)
16031
        return this.equals((getAllVendors_args)that);
16032
      return false;
16033
    }
16034
 
16035
    public boolean equals(getAllVendors_args that) {
16036
      if (that == null)
16037
        return false;
16038
 
16039
      return true;
16040
    }
16041
 
16042
    @Override
16043
    public int hashCode() {
16044
      return 0;
16045
    }
16046
 
16047
    public int compareTo(getAllVendors_args other) {
16048
      if (!getClass().equals(other.getClass())) {
16049
        return getClass().getName().compareTo(other.getClass().getName());
16050
      }
16051
 
16052
      int lastComparison = 0;
16053
      getAllVendors_args typedOther = (getAllVendors_args)other;
16054
 
16055
      return 0;
16056
    }
16057
 
16058
    public _Fields fieldForId(int fieldId) {
16059
      return _Fields.findByThriftId(fieldId);
16060
    }
16061
 
16062
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16063
      org.apache.thrift.protocol.TField field;
16064
      iprot.readStructBegin();
16065
      while (true)
16066
      {
16067
        field = iprot.readFieldBegin();
16068
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16069
          break;
16070
        }
16071
        switch (field.id) {
16072
          default:
16073
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16074
        }
16075
        iprot.readFieldEnd();
16076
      }
16077
      iprot.readStructEnd();
16078
      validate();
16079
    }
16080
 
16081
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16082
      validate();
16083
 
16084
      oprot.writeStructBegin(STRUCT_DESC);
16085
      oprot.writeFieldStop();
16086
      oprot.writeStructEnd();
16087
    }
16088
 
16089
    @Override
16090
    public String toString() {
16091
      StringBuilder sb = new StringBuilder("getAllVendors_args(");
16092
      boolean first = true;
16093
 
16094
      sb.append(")");
16095
      return sb.toString();
16096
    }
16097
 
16098
    public void validate() throws org.apache.thrift.TException {
16099
      // check for required fields
16100
    }
16101
 
16102
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16103
      try {
16104
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16105
      } catch (org.apache.thrift.TException te) {
16106
        throw new java.io.IOException(te);
16107
      }
16108
    }
16109
 
16110
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16111
      try {
16112
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16113
      } catch (org.apache.thrift.TException te) {
16114
        throw new java.io.IOException(te);
16115
      }
16116
    }
16117
 
16118
  }
16119
 
16120
  public static class getAllVendors_result implements org.apache.thrift.TBase<getAllVendors_result, getAllVendors_result._Fields>, java.io.Serializable, Cloneable   {
16121
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendors_result");
16122
 
16123
    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);
16124
 
16125
    private List<Vendor> success; // required
16126
 
16127
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16128
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16129
      SUCCESS((short)0, "success");
16130
 
16131
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16132
 
16133
      static {
16134
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16135
          byName.put(field.getFieldName(), field);
16136
        }
16137
      }
16138
 
16139
      /**
16140
       * Find the _Fields constant that matches fieldId, or null if its not found.
16141
       */
16142
      public static _Fields findByThriftId(int fieldId) {
16143
        switch(fieldId) {
16144
          case 0: // SUCCESS
16145
            return SUCCESS;
16146
          default:
16147
            return null;
16148
        }
16149
      }
16150
 
16151
      /**
16152
       * Find the _Fields constant that matches fieldId, throwing an exception
16153
       * if it is not found.
16154
       */
16155
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16156
        _Fields fields = findByThriftId(fieldId);
16157
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16158
        return fields;
16159
      }
16160
 
16161
      /**
16162
       * Find the _Fields constant that matches name, or null if its not found.
16163
       */
16164
      public static _Fields findByName(String name) {
16165
        return byName.get(name);
16166
      }
16167
 
16168
      private final short _thriftId;
16169
      private final String _fieldName;
16170
 
16171
      _Fields(short thriftId, String fieldName) {
16172
        _thriftId = thriftId;
16173
        _fieldName = fieldName;
16174
      }
16175
 
16176
      public short getThriftFieldId() {
16177
        return _thriftId;
16178
      }
16179
 
16180
      public String getFieldName() {
16181
        return _fieldName;
16182
      }
16183
    }
16184
 
16185
    // isset id assignments
16186
 
16187
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16188
    static {
16189
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16190
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16191
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
16192
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class))));
16193
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16194
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendors_result.class, metaDataMap);
16195
    }
16196
 
16197
    public getAllVendors_result() {
16198
    }
16199
 
16200
    public getAllVendors_result(
16201
      List<Vendor> success)
16202
    {
16203
      this();
16204
      this.success = success;
16205
    }
16206
 
16207
    /**
16208
     * Performs a deep copy on <i>other</i>.
16209
     */
16210
    public getAllVendors_result(getAllVendors_result other) {
16211
      if (other.isSetSuccess()) {
16212
        List<Vendor> __this__success = new ArrayList<Vendor>();
16213
        for (Vendor other_element : other.success) {
16214
          __this__success.add(new Vendor(other_element));
16215
        }
16216
        this.success = __this__success;
16217
      }
16218
    }
16219
 
16220
    public getAllVendors_result deepCopy() {
16221
      return new getAllVendors_result(this);
16222
    }
16223
 
16224
    @Override
16225
    public void clear() {
16226
      this.success = null;
16227
    }
16228
 
16229
    public int getSuccessSize() {
16230
      return (this.success == null) ? 0 : this.success.size();
16231
    }
16232
 
16233
    public java.util.Iterator<Vendor> getSuccessIterator() {
16234
      return (this.success == null) ? null : this.success.iterator();
16235
    }
16236
 
16237
    public void addToSuccess(Vendor elem) {
16238
      if (this.success == null) {
16239
        this.success = new ArrayList<Vendor>();
16240
      }
16241
      this.success.add(elem);
16242
    }
16243
 
16244
    public List<Vendor> getSuccess() {
16245
      return this.success;
16246
    }
16247
 
16248
    public void setSuccess(List<Vendor> success) {
16249
      this.success = success;
16250
    }
16251
 
16252
    public void unsetSuccess() {
16253
      this.success = null;
16254
    }
16255
 
16256
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
16257
    public boolean isSetSuccess() {
16258
      return this.success != null;
16259
    }
16260
 
16261
    public void setSuccessIsSet(boolean value) {
16262
      if (!value) {
16263
        this.success = null;
16264
      }
16265
    }
16266
 
16267
    public void setFieldValue(_Fields field, Object value) {
16268
      switch (field) {
16269
      case SUCCESS:
16270
        if (value == null) {
16271
          unsetSuccess();
16272
        } else {
16273
          setSuccess((List<Vendor>)value);
16274
        }
16275
        break;
16276
 
16277
      }
16278
    }
16279
 
16280
    public Object getFieldValue(_Fields field) {
16281
      switch (field) {
16282
      case SUCCESS:
16283
        return getSuccess();
16284
 
16285
      }
16286
      throw new IllegalStateException();
16287
    }
16288
 
16289
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16290
    public boolean isSet(_Fields field) {
16291
      if (field == null) {
16292
        throw new IllegalArgumentException();
16293
      }
16294
 
16295
      switch (field) {
16296
      case SUCCESS:
16297
        return isSetSuccess();
16298
      }
16299
      throw new IllegalStateException();
16300
    }
16301
 
16302
    @Override
16303
    public boolean equals(Object that) {
16304
      if (that == null)
16305
        return false;
16306
      if (that instanceof getAllVendors_result)
16307
        return this.equals((getAllVendors_result)that);
16308
      return false;
16309
    }
16310
 
16311
    public boolean equals(getAllVendors_result that) {
16312
      if (that == null)
16313
        return false;
16314
 
16315
      boolean this_present_success = true && this.isSetSuccess();
16316
      boolean that_present_success = true && that.isSetSuccess();
16317
      if (this_present_success || that_present_success) {
16318
        if (!(this_present_success && that_present_success))
16319
          return false;
16320
        if (!this.success.equals(that.success))
16321
          return false;
16322
      }
16323
 
16324
      return true;
16325
    }
16326
 
16327
    @Override
16328
    public int hashCode() {
16329
      return 0;
16330
    }
16331
 
16332
    public int compareTo(getAllVendors_result other) {
16333
      if (!getClass().equals(other.getClass())) {
16334
        return getClass().getName().compareTo(other.getClass().getName());
16335
      }
16336
 
16337
      int lastComparison = 0;
16338
      getAllVendors_result typedOther = (getAllVendors_result)other;
16339
 
16340
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
16341
      if (lastComparison != 0) {
16342
        return lastComparison;
16343
      }
16344
      if (isSetSuccess()) {
16345
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
16346
        if (lastComparison != 0) {
16347
          return lastComparison;
16348
        }
16349
      }
16350
      return 0;
16351
    }
16352
 
16353
    public _Fields fieldForId(int fieldId) {
16354
      return _Fields.findByThriftId(fieldId);
16355
    }
16356
 
16357
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16358
      org.apache.thrift.protocol.TField field;
16359
      iprot.readStructBegin();
16360
      while (true)
16361
      {
16362
        field = iprot.readFieldBegin();
16363
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16364
          break;
16365
        }
16366
        switch (field.id) {
16367
          case 0: // SUCCESS
16368
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
16369
              {
16370
                org.apache.thrift.protocol.TList _list36 = iprot.readListBegin();
16371
                this.success = new ArrayList<Vendor>(_list36.size);
16372
                for (int _i37 = 0; _i37 < _list36.size; ++_i37)
16373
                {
16374
                  Vendor _elem38; // required
16375
                  _elem38 = new Vendor();
16376
                  _elem38.read(iprot);
16377
                  this.success.add(_elem38);
16378
                }
16379
                iprot.readListEnd();
16380
              }
16381
            } else { 
16382
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16383
            }
16384
            break;
16385
          default:
16386
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16387
        }
16388
        iprot.readFieldEnd();
16389
      }
16390
      iprot.readStructEnd();
16391
      validate();
16392
    }
16393
 
16394
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16395
      oprot.writeStructBegin(STRUCT_DESC);
16396
 
16397
      if (this.isSetSuccess()) {
16398
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
16399
        {
16400
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
16401
          for (Vendor _iter39 : this.success)
16402
          {
16403
            _iter39.write(oprot);
16404
          }
16405
          oprot.writeListEnd();
16406
        }
16407
        oprot.writeFieldEnd();
16408
      }
16409
      oprot.writeFieldStop();
16410
      oprot.writeStructEnd();
16411
    }
16412
 
16413
    @Override
16414
    public String toString() {
16415
      StringBuilder sb = new StringBuilder("getAllVendors_result(");
16416
      boolean first = true;
16417
 
16418
      sb.append("success:");
16419
      if (this.success == null) {
16420
        sb.append("null");
16421
      } else {
16422
        sb.append(this.success);
16423
      }
16424
      first = false;
16425
      sb.append(")");
16426
      return sb.toString();
16427
    }
16428
 
16429
    public void validate() throws org.apache.thrift.TException {
16430
      // check for required fields
16431
    }
16432
 
16433
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16434
      try {
16435
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16436
      } catch (org.apache.thrift.TException te) {
16437
        throw new java.io.IOException(te);
16438
      }
16439
    }
16440
 
16441
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16442
      try {
16443
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16444
      } catch (org.apache.thrift.TException te) {
16445
        throw new java.io.IOException(te);
16446
      }
16447
    }
16448
 
16449
  }
16450
 
16451
  public static class addVendorItemMapping_args implements org.apache.thrift.TBase<addVendorItemMapping_args, addVendorItemMapping_args._Fields>, java.io.Serializable, Cloneable   {
16452
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemMapping_args");
16453
 
16454
    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);
16455
    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);
16456
 
16457
    private String key; // required
16458
    private VendorItemMapping vendorItemMapping; // required
16459
 
16460
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16461
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16462
      KEY((short)1, "key"),
16463
      VENDOR_ITEM_MAPPING((short)2, "vendorItemMapping");
16464
 
16465
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16466
 
16467
      static {
16468
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16469
          byName.put(field.getFieldName(), field);
16470
        }
16471
      }
16472
 
16473
      /**
16474
       * Find the _Fields constant that matches fieldId, or null if its not found.
16475
       */
16476
      public static _Fields findByThriftId(int fieldId) {
16477
        switch(fieldId) {
16478
          case 1: // KEY
16479
            return KEY;
16480
          case 2: // VENDOR_ITEM_MAPPING
16481
            return VENDOR_ITEM_MAPPING;
16482
          default:
16483
            return null;
16484
        }
16485
      }
16486
 
16487
      /**
16488
       * Find the _Fields constant that matches fieldId, throwing an exception
16489
       * if it is not found.
16490
       */
16491
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16492
        _Fields fields = findByThriftId(fieldId);
16493
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16494
        return fields;
16495
      }
16496
 
16497
      /**
16498
       * Find the _Fields constant that matches name, or null if its not found.
16499
       */
16500
      public static _Fields findByName(String name) {
16501
        return byName.get(name);
16502
      }
16503
 
16504
      private final short _thriftId;
16505
      private final String _fieldName;
16506
 
16507
      _Fields(short thriftId, String fieldName) {
16508
        _thriftId = thriftId;
16509
        _fieldName = fieldName;
16510
      }
16511
 
16512
      public short getThriftFieldId() {
16513
        return _thriftId;
16514
      }
16515
 
16516
      public String getFieldName() {
16517
        return _fieldName;
16518
      }
16519
    }
16520
 
16521
    // isset id assignments
16522
 
16523
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16524
    static {
16525
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16526
      tmpMap.put(_Fields.KEY, new org.apache.thrift.meta_data.FieldMetaData("key", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16527
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
16528
      tmpMap.put(_Fields.VENDOR_ITEM_MAPPING, new org.apache.thrift.meta_data.FieldMetaData("vendorItemMapping", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16529
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class)));
16530
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16531
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemMapping_args.class, metaDataMap);
16532
    }
16533
 
16534
    public addVendorItemMapping_args() {
16535
    }
16536
 
16537
    public addVendorItemMapping_args(
16538
      String key,
16539
      VendorItemMapping vendorItemMapping)
16540
    {
16541
      this();
16542
      this.key = key;
16543
      this.vendorItemMapping = vendorItemMapping;
16544
    }
16545
 
16546
    /**
16547
     * Performs a deep copy on <i>other</i>.
16548
     */
16549
    public addVendorItemMapping_args(addVendorItemMapping_args other) {
16550
      if (other.isSetKey()) {
16551
        this.key = other.key;
16552
      }
16553
      if (other.isSetVendorItemMapping()) {
16554
        this.vendorItemMapping = new VendorItemMapping(other.vendorItemMapping);
16555
      }
16556
    }
16557
 
16558
    public addVendorItemMapping_args deepCopy() {
16559
      return new addVendorItemMapping_args(this);
16560
    }
16561
 
16562
    @Override
16563
    public void clear() {
16564
      this.key = null;
16565
      this.vendorItemMapping = null;
16566
    }
16567
 
16568
    public String getKey() {
16569
      return this.key;
16570
    }
16571
 
16572
    public void setKey(String key) {
16573
      this.key = key;
16574
    }
16575
 
16576
    public void unsetKey() {
16577
      this.key = null;
16578
    }
16579
 
16580
    /** Returns true if field key is set (has been assigned a value) and false otherwise */
16581
    public boolean isSetKey() {
16582
      return this.key != null;
16583
    }
16584
 
16585
    public void setKeyIsSet(boolean value) {
16586
      if (!value) {
16587
        this.key = null;
16588
      }
16589
    }
16590
 
16591
    public VendorItemMapping getVendorItemMapping() {
16592
      return this.vendorItemMapping;
16593
    }
16594
 
16595
    public void setVendorItemMapping(VendorItemMapping vendorItemMapping) {
16596
      this.vendorItemMapping = vendorItemMapping;
16597
    }
16598
 
16599
    public void unsetVendorItemMapping() {
16600
      this.vendorItemMapping = null;
16601
    }
16602
 
16603
    /** Returns true if field vendorItemMapping is set (has been assigned a value) and false otherwise */
16604
    public boolean isSetVendorItemMapping() {
16605
      return this.vendorItemMapping != null;
16606
    }
16607
 
16608
    public void setVendorItemMappingIsSet(boolean value) {
16609
      if (!value) {
16610
        this.vendorItemMapping = null;
16611
      }
16612
    }
16613
 
16614
    public void setFieldValue(_Fields field, Object value) {
16615
      switch (field) {
16616
      case KEY:
16617
        if (value == null) {
16618
          unsetKey();
16619
        } else {
16620
          setKey((String)value);
16621
        }
16622
        break;
16623
 
16624
      case VENDOR_ITEM_MAPPING:
16625
        if (value == null) {
16626
          unsetVendorItemMapping();
16627
        } else {
16628
          setVendorItemMapping((VendorItemMapping)value);
16629
        }
16630
        break;
16631
 
16632
      }
16633
    }
16634
 
16635
    public Object getFieldValue(_Fields field) {
16636
      switch (field) {
16637
      case KEY:
16638
        return getKey();
16639
 
16640
      case VENDOR_ITEM_MAPPING:
16641
        return getVendorItemMapping();
16642
 
16643
      }
16644
      throw new IllegalStateException();
16645
    }
16646
 
16647
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16648
    public boolean isSet(_Fields field) {
16649
      if (field == null) {
16650
        throw new IllegalArgumentException();
16651
      }
16652
 
16653
      switch (field) {
16654
      case KEY:
16655
        return isSetKey();
16656
      case VENDOR_ITEM_MAPPING:
16657
        return isSetVendorItemMapping();
16658
      }
16659
      throw new IllegalStateException();
16660
    }
16661
 
16662
    @Override
16663
    public boolean equals(Object that) {
16664
      if (that == null)
16665
        return false;
16666
      if (that instanceof addVendorItemMapping_args)
16667
        return this.equals((addVendorItemMapping_args)that);
16668
      return false;
16669
    }
16670
 
16671
    public boolean equals(addVendorItemMapping_args that) {
16672
      if (that == null)
16673
        return false;
16674
 
16675
      boolean this_present_key = true && this.isSetKey();
16676
      boolean that_present_key = true && that.isSetKey();
16677
      if (this_present_key || that_present_key) {
16678
        if (!(this_present_key && that_present_key))
16679
          return false;
16680
        if (!this.key.equals(that.key))
16681
          return false;
16682
      }
16683
 
16684
      boolean this_present_vendorItemMapping = true && this.isSetVendorItemMapping();
16685
      boolean that_present_vendorItemMapping = true && that.isSetVendorItemMapping();
16686
      if (this_present_vendorItemMapping || that_present_vendorItemMapping) {
16687
        if (!(this_present_vendorItemMapping && that_present_vendorItemMapping))
16688
          return false;
16689
        if (!this.vendorItemMapping.equals(that.vendorItemMapping))
16690
          return false;
16691
      }
16692
 
16693
      return true;
16694
    }
16695
 
16696
    @Override
16697
    public int hashCode() {
16698
      return 0;
16699
    }
16700
 
16701
    public int compareTo(addVendorItemMapping_args other) {
16702
      if (!getClass().equals(other.getClass())) {
16703
        return getClass().getName().compareTo(other.getClass().getName());
16704
      }
16705
 
16706
      int lastComparison = 0;
16707
      addVendorItemMapping_args typedOther = (addVendorItemMapping_args)other;
16708
 
16709
      lastComparison = Boolean.valueOf(isSetKey()).compareTo(typedOther.isSetKey());
16710
      if (lastComparison != 0) {
16711
        return lastComparison;
16712
      }
16713
      if (isSetKey()) {
16714
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.key, typedOther.key);
16715
        if (lastComparison != 0) {
16716
          return lastComparison;
16717
        }
16718
      }
16719
      lastComparison = Boolean.valueOf(isSetVendorItemMapping()).compareTo(typedOther.isSetVendorItemMapping());
16720
      if (lastComparison != 0) {
16721
        return lastComparison;
16722
      }
16723
      if (isSetVendorItemMapping()) {
16724
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorItemMapping, typedOther.vendorItemMapping);
16725
        if (lastComparison != 0) {
16726
          return lastComparison;
16727
        }
16728
      }
16729
      return 0;
16730
    }
16731
 
16732
    public _Fields fieldForId(int fieldId) {
16733
      return _Fields.findByThriftId(fieldId);
16734
    }
16735
 
16736
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16737
      org.apache.thrift.protocol.TField field;
16738
      iprot.readStructBegin();
16739
      while (true)
16740
      {
16741
        field = iprot.readFieldBegin();
16742
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16743
          break;
16744
        }
16745
        switch (field.id) {
16746
          case 1: // KEY
16747
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
16748
              this.key = iprot.readString();
16749
            } else { 
16750
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16751
            }
16752
            break;
16753
          case 2: // VENDOR_ITEM_MAPPING
16754
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16755
              this.vendorItemMapping = new VendorItemMapping();
16756
              this.vendorItemMapping.read(iprot);
16757
            } else { 
16758
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16759
            }
16760
            break;
16761
          default:
16762
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16763
        }
16764
        iprot.readFieldEnd();
16765
      }
16766
      iprot.readStructEnd();
16767
      validate();
16768
    }
16769
 
16770
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16771
      validate();
16772
 
16773
      oprot.writeStructBegin(STRUCT_DESC);
16774
      if (this.key != null) {
16775
        oprot.writeFieldBegin(KEY_FIELD_DESC);
16776
        oprot.writeString(this.key);
16777
        oprot.writeFieldEnd();
16778
      }
16779
      if (this.vendorItemMapping != null) {
16780
        oprot.writeFieldBegin(VENDOR_ITEM_MAPPING_FIELD_DESC);
16781
        this.vendorItemMapping.write(oprot);
16782
        oprot.writeFieldEnd();
16783
      }
16784
      oprot.writeFieldStop();
16785
      oprot.writeStructEnd();
16786
    }
16787
 
16788
    @Override
16789
    public String toString() {
16790
      StringBuilder sb = new StringBuilder("addVendorItemMapping_args(");
16791
      boolean first = true;
16792
 
16793
      sb.append("key:");
16794
      if (this.key == null) {
16795
        sb.append("null");
16796
      } else {
16797
        sb.append(this.key);
16798
      }
16799
      first = false;
16800
      if (!first) sb.append(", ");
16801
      sb.append("vendorItemMapping:");
16802
      if (this.vendorItemMapping == null) {
16803
        sb.append("null");
16804
      } else {
16805
        sb.append(this.vendorItemMapping);
16806
      }
16807
      first = false;
16808
      sb.append(")");
16809
      return sb.toString();
16810
    }
16811
 
16812
    public void validate() throws org.apache.thrift.TException {
16813
      // check for required fields
16814
    }
16815
 
16816
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16817
      try {
16818
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16819
      } catch (org.apache.thrift.TException te) {
16820
        throw new java.io.IOException(te);
16821
      }
16822
    }
16823
 
16824
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16825
      try {
16826
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16827
      } catch (org.apache.thrift.TException te) {
16828
        throw new java.io.IOException(te);
16829
      }
16830
    }
16831
 
16832
  }
16833
 
16834
  public static class addVendorItemMapping_result implements org.apache.thrift.TBase<addVendorItemMapping_result, addVendorItemMapping_result._Fields>, java.io.Serializable, Cloneable   {
16835
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemMapping_result");
16836
 
16837
    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);
16838
 
16839
    private InventoryServiceException cex; // required
16840
 
16841
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16842
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16843
      CEX((short)1, "cex");
16844
 
16845
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16846
 
16847
      static {
16848
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16849
          byName.put(field.getFieldName(), field);
16850
        }
16851
      }
16852
 
16853
      /**
16854
       * Find the _Fields constant that matches fieldId, or null if its not found.
16855
       */
16856
      public static _Fields findByThriftId(int fieldId) {
16857
        switch(fieldId) {
16858
          case 1: // CEX
16859
            return CEX;
16860
          default:
16861
            return null;
16862
        }
16863
      }
16864
 
16865
      /**
16866
       * Find the _Fields constant that matches fieldId, throwing an exception
16867
       * if it is not found.
16868
       */
16869
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16870
        _Fields fields = findByThriftId(fieldId);
16871
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16872
        return fields;
16873
      }
16874
 
16875
      /**
16876
       * Find the _Fields constant that matches name, or null if its not found.
16877
       */
16878
      public static _Fields findByName(String name) {
16879
        return byName.get(name);
16880
      }
16881
 
16882
      private final short _thriftId;
16883
      private final String _fieldName;
16884
 
16885
      _Fields(short thriftId, String fieldName) {
16886
        _thriftId = thriftId;
16887
        _fieldName = fieldName;
16888
      }
16889
 
16890
      public short getThriftFieldId() {
16891
        return _thriftId;
16892
      }
16893
 
16894
      public String getFieldName() {
16895
        return _fieldName;
16896
      }
16897
    }
16898
 
16899
    // isset id assignments
16900
 
16901
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16902
    static {
16903
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16904
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16905
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
16906
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16907
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemMapping_result.class, metaDataMap);
16908
    }
16909
 
16910
    public addVendorItemMapping_result() {
16911
    }
16912
 
16913
    public addVendorItemMapping_result(
16914
      InventoryServiceException cex)
16915
    {
16916
      this();
16917
      this.cex = cex;
16918
    }
16919
 
16920
    /**
16921
     * Performs a deep copy on <i>other</i>.
16922
     */
16923
    public addVendorItemMapping_result(addVendorItemMapping_result other) {
16924
      if (other.isSetCex()) {
16925
        this.cex = new InventoryServiceException(other.cex);
16926
      }
16927
    }
16928
 
16929
    public addVendorItemMapping_result deepCopy() {
16930
      return new addVendorItemMapping_result(this);
16931
    }
16932
 
16933
    @Override
16934
    public void clear() {
16935
      this.cex = null;
16936
    }
16937
 
16938
    public InventoryServiceException getCex() {
16939
      return this.cex;
16940
    }
16941
 
16942
    public void setCex(InventoryServiceException cex) {
16943
      this.cex = cex;
16944
    }
16945
 
16946
    public void unsetCex() {
16947
      this.cex = null;
16948
    }
16949
 
16950
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
16951
    public boolean isSetCex() {
16952
      return this.cex != null;
16953
    }
16954
 
16955
    public void setCexIsSet(boolean value) {
16956
      if (!value) {
16957
        this.cex = null;
16958
      }
16959
    }
16960
 
16961
    public void setFieldValue(_Fields field, Object value) {
16962
      switch (field) {
16963
      case CEX:
16964
        if (value == null) {
16965
          unsetCex();
16966
        } else {
16967
          setCex((InventoryServiceException)value);
16968
        }
16969
        break;
16970
 
16971
      }
16972
    }
16973
 
16974
    public Object getFieldValue(_Fields field) {
16975
      switch (field) {
16976
      case CEX:
16977
        return getCex();
16978
 
16979
      }
16980
      throw new IllegalStateException();
16981
    }
16982
 
16983
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16984
    public boolean isSet(_Fields field) {
16985
      if (field == null) {
16986
        throw new IllegalArgumentException();
16987
      }
16988
 
16989
      switch (field) {
16990
      case CEX:
16991
        return isSetCex();
16992
      }
16993
      throw new IllegalStateException();
16994
    }
16995
 
16996
    @Override
16997
    public boolean equals(Object that) {
16998
      if (that == null)
16999
        return false;
17000
      if (that instanceof addVendorItemMapping_result)
17001
        return this.equals((addVendorItemMapping_result)that);
17002
      return false;
17003
    }
17004
 
17005
    public boolean equals(addVendorItemMapping_result that) {
17006
      if (that == null)
17007
        return false;
17008
 
17009
      boolean this_present_cex = true && this.isSetCex();
17010
      boolean that_present_cex = true && that.isSetCex();
17011
      if (this_present_cex || that_present_cex) {
17012
        if (!(this_present_cex && that_present_cex))
17013
          return false;
17014
        if (!this.cex.equals(that.cex))
17015
          return false;
17016
      }
17017
 
17018
      return true;
17019
    }
17020
 
17021
    @Override
17022
    public int hashCode() {
17023
      return 0;
17024
    }
17025
 
17026
    public int compareTo(addVendorItemMapping_result other) {
17027
      if (!getClass().equals(other.getClass())) {
17028
        return getClass().getName().compareTo(other.getClass().getName());
17029
      }
17030
 
17031
      int lastComparison = 0;
17032
      addVendorItemMapping_result typedOther = (addVendorItemMapping_result)other;
17033
 
17034
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
17035
      if (lastComparison != 0) {
17036
        return lastComparison;
17037
      }
17038
      if (isSetCex()) {
17039
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
17040
        if (lastComparison != 0) {
17041
          return lastComparison;
17042
        }
17043
      }
17044
      return 0;
17045
    }
17046
 
17047
    public _Fields fieldForId(int fieldId) {
17048
      return _Fields.findByThriftId(fieldId);
17049
    }
17050
 
17051
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17052
      org.apache.thrift.protocol.TField field;
17053
      iprot.readStructBegin();
17054
      while (true)
17055
      {
17056
        field = iprot.readFieldBegin();
17057
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17058
          break;
17059
        }
17060
        switch (field.id) {
17061
          case 1: // CEX
17062
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
17063
              this.cex = new InventoryServiceException();
17064
              this.cex.read(iprot);
17065
            } else { 
17066
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17067
            }
17068
            break;
17069
          default:
17070
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17071
        }
17072
        iprot.readFieldEnd();
17073
      }
17074
      iprot.readStructEnd();
17075
      validate();
17076
    }
17077
 
17078
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17079
      oprot.writeStructBegin(STRUCT_DESC);
17080
 
17081
      if (this.isSetCex()) {
17082
        oprot.writeFieldBegin(CEX_FIELD_DESC);
17083
        this.cex.write(oprot);
17084
        oprot.writeFieldEnd();
17085
      }
17086
      oprot.writeFieldStop();
17087
      oprot.writeStructEnd();
17088
    }
17089
 
17090
    @Override
17091
    public String toString() {
17092
      StringBuilder sb = new StringBuilder("addVendorItemMapping_result(");
17093
      boolean first = true;
17094
 
17095
      sb.append("cex:");
17096
      if (this.cex == null) {
17097
        sb.append("null");
17098
      } else {
17099
        sb.append(this.cex);
17100
      }
17101
      first = false;
17102
      sb.append(")");
17103
      return sb.toString();
17104
    }
17105
 
17106
    public void validate() throws org.apache.thrift.TException {
17107
      // check for required fields
17108
    }
17109
 
17110
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17111
      try {
17112
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17113
      } catch (org.apache.thrift.TException te) {
17114
        throw new java.io.IOException(te);
17115
      }
17116
    }
17117
 
17118
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17119
      try {
17120
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17121
      } catch (org.apache.thrift.TException te) {
17122
        throw new java.io.IOException(te);
17123
      }
17124
    }
17125
 
17126
  }
17127
 
17128
  public static class getVendorItemMappings_args implements org.apache.thrift.TBase<getVendorItemMappings_args, getVendorItemMappings_args._Fields>, java.io.Serializable, Cloneable   {
17129
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendorItemMappings_args");
17130
 
17131
    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);
17132
 
17133
    private long itemId; // required
17134
 
17135
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17136
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17137
      ITEM_ID((short)1, "itemId");
17138
 
17139
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17140
 
17141
      static {
17142
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17143
          byName.put(field.getFieldName(), field);
17144
        }
17145
      }
17146
 
17147
      /**
17148
       * Find the _Fields constant that matches fieldId, or null if its not found.
17149
       */
17150
      public static _Fields findByThriftId(int fieldId) {
17151
        switch(fieldId) {
17152
          case 1: // ITEM_ID
17153
            return ITEM_ID;
17154
          default:
17155
            return null;
17156
        }
17157
      }
17158
 
17159
      /**
17160
       * Find the _Fields constant that matches fieldId, throwing an exception
17161
       * if it is not found.
17162
       */
17163
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17164
        _Fields fields = findByThriftId(fieldId);
17165
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17166
        return fields;
17167
      }
17168
 
17169
      /**
17170
       * Find the _Fields constant that matches name, or null if its not found.
17171
       */
17172
      public static _Fields findByName(String name) {
17173
        return byName.get(name);
17174
      }
17175
 
17176
      private final short _thriftId;
17177
      private final String _fieldName;
17178
 
17179
      _Fields(short thriftId, String fieldName) {
17180
        _thriftId = thriftId;
17181
        _fieldName = fieldName;
17182
      }
17183
 
17184
      public short getThriftFieldId() {
17185
        return _thriftId;
17186
      }
17187
 
17188
      public String getFieldName() {
17189
        return _fieldName;
17190
      }
17191
    }
17192
 
17193
    // isset id assignments
17194
    private static final int __ITEMID_ISSET_ID = 0;
17195
    private BitSet __isset_bit_vector = new BitSet(1);
17196
 
17197
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17198
    static {
17199
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17200
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17201
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17202
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17203
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendorItemMappings_args.class, metaDataMap);
17204
    }
17205
 
17206
    public getVendorItemMappings_args() {
17207
    }
17208
 
17209
    public getVendorItemMappings_args(
17210
      long itemId)
17211
    {
17212
      this();
17213
      this.itemId = itemId;
17214
      setItemIdIsSet(true);
17215
    }
17216
 
17217
    /**
17218
     * Performs a deep copy on <i>other</i>.
17219
     */
17220
    public getVendorItemMappings_args(getVendorItemMappings_args other) {
17221
      __isset_bit_vector.clear();
17222
      __isset_bit_vector.or(other.__isset_bit_vector);
17223
      this.itemId = other.itemId;
17224
    }
17225
 
17226
    public getVendorItemMappings_args deepCopy() {
17227
      return new getVendorItemMappings_args(this);
17228
    }
17229
 
17230
    @Override
17231
    public void clear() {
17232
      setItemIdIsSet(false);
17233
      this.itemId = 0;
17234
    }
17235
 
17236
    public long getItemId() {
17237
      return this.itemId;
17238
    }
17239
 
17240
    public void setItemId(long itemId) {
17241
      this.itemId = itemId;
17242
      setItemIdIsSet(true);
17243
    }
17244
 
17245
    public void unsetItemId() {
17246
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
17247
    }
17248
 
17249
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
17250
    public boolean isSetItemId() {
17251
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
17252
    }
17253
 
17254
    public void setItemIdIsSet(boolean value) {
17255
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
17256
    }
17257
 
17258
    public void setFieldValue(_Fields field, Object value) {
17259
      switch (field) {
17260
      case ITEM_ID:
17261
        if (value == null) {
17262
          unsetItemId();
17263
        } else {
17264
          setItemId((Long)value);
17265
        }
17266
        break;
17267
 
17268
      }
17269
    }
17270
 
17271
    public Object getFieldValue(_Fields field) {
17272
      switch (field) {
17273
      case ITEM_ID:
17274
        return Long.valueOf(getItemId());
17275
 
17276
      }
17277
      throw new IllegalStateException();
17278
    }
17279
 
17280
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17281
    public boolean isSet(_Fields field) {
17282
      if (field == null) {
17283
        throw new IllegalArgumentException();
17284
      }
17285
 
17286
      switch (field) {
17287
      case ITEM_ID:
17288
        return isSetItemId();
17289
      }
17290
      throw new IllegalStateException();
17291
    }
17292
 
17293
    @Override
17294
    public boolean equals(Object that) {
17295
      if (that == null)
17296
        return false;
17297
      if (that instanceof getVendorItemMappings_args)
17298
        return this.equals((getVendorItemMappings_args)that);
17299
      return false;
17300
    }
17301
 
17302
    public boolean equals(getVendorItemMappings_args that) {
17303
      if (that == null)
17304
        return false;
17305
 
17306
      boolean this_present_itemId = true;
17307
      boolean that_present_itemId = true;
17308
      if (this_present_itemId || that_present_itemId) {
17309
        if (!(this_present_itemId && that_present_itemId))
17310
          return false;
17311
        if (this.itemId != that.itemId)
17312
          return false;
17313
      }
17314
 
17315
      return true;
17316
    }
17317
 
17318
    @Override
17319
    public int hashCode() {
17320
      return 0;
17321
    }
17322
 
17323
    public int compareTo(getVendorItemMappings_args other) {
17324
      if (!getClass().equals(other.getClass())) {
17325
        return getClass().getName().compareTo(other.getClass().getName());
17326
      }
17327
 
17328
      int lastComparison = 0;
17329
      getVendorItemMappings_args typedOther = (getVendorItemMappings_args)other;
17330
 
17331
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
17332
      if (lastComparison != 0) {
17333
        return lastComparison;
17334
      }
17335
      if (isSetItemId()) {
17336
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
17337
        if (lastComparison != 0) {
17338
          return lastComparison;
17339
        }
17340
      }
17341
      return 0;
17342
    }
17343
 
17344
    public _Fields fieldForId(int fieldId) {
17345
      return _Fields.findByThriftId(fieldId);
17346
    }
17347
 
17348
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17349
      org.apache.thrift.protocol.TField field;
17350
      iprot.readStructBegin();
17351
      while (true)
17352
      {
17353
        field = iprot.readFieldBegin();
17354
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17355
          break;
17356
        }
17357
        switch (field.id) {
17358
          case 1: // ITEM_ID
17359
            if (field.type == org.apache.thrift.protocol.TType.I64) {
17360
              this.itemId = iprot.readI64();
17361
              setItemIdIsSet(true);
17362
            } else { 
17363
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17364
            }
17365
            break;
17366
          default:
17367
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17368
        }
17369
        iprot.readFieldEnd();
17370
      }
17371
      iprot.readStructEnd();
17372
      validate();
17373
    }
17374
 
17375
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17376
      validate();
17377
 
17378
      oprot.writeStructBegin(STRUCT_DESC);
17379
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
17380
      oprot.writeI64(this.itemId);
17381
      oprot.writeFieldEnd();
17382
      oprot.writeFieldStop();
17383
      oprot.writeStructEnd();
17384
    }
17385
 
17386
    @Override
17387
    public String toString() {
17388
      StringBuilder sb = new StringBuilder("getVendorItemMappings_args(");
17389
      boolean first = true;
17390
 
17391
      sb.append("itemId:");
17392
      sb.append(this.itemId);
17393
      first = false;
17394
      sb.append(")");
17395
      return sb.toString();
17396
    }
17397
 
17398
    public void validate() throws org.apache.thrift.TException {
17399
      // check for required fields
17400
    }
17401
 
17402
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17403
      try {
17404
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17405
      } catch (org.apache.thrift.TException te) {
17406
        throw new java.io.IOException(te);
17407
      }
17408
    }
17409
 
17410
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17411
      try {
17412
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17413
      } catch (org.apache.thrift.TException te) {
17414
        throw new java.io.IOException(te);
17415
      }
17416
    }
17417
 
17418
  }
17419
 
17420
  public static class getVendorItemMappings_result implements org.apache.thrift.TBase<getVendorItemMappings_result, getVendorItemMappings_result._Fields>, java.io.Serializable, Cloneable   {
17421
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendorItemMappings_result");
17422
 
17423
    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);
17424
    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);
17425
 
17426
    private List<VendorItemMapping> success; // required
17427
    private InventoryServiceException cex; // required
17428
 
17429
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17430
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17431
      SUCCESS((short)0, "success"),
17432
      CEX((short)1, "cex");
17433
 
17434
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17435
 
17436
      static {
17437
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17438
          byName.put(field.getFieldName(), field);
17439
        }
17440
      }
17441
 
17442
      /**
17443
       * Find the _Fields constant that matches fieldId, or null if its not found.
17444
       */
17445
      public static _Fields findByThriftId(int fieldId) {
17446
        switch(fieldId) {
17447
          case 0: // SUCCESS
17448
            return SUCCESS;
17449
          case 1: // CEX
17450
            return CEX;
17451
          default:
17452
            return null;
17453
        }
17454
      }
17455
 
17456
      /**
17457
       * Find the _Fields constant that matches fieldId, throwing an exception
17458
       * if it is not found.
17459
       */
17460
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17461
        _Fields fields = findByThriftId(fieldId);
17462
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17463
        return fields;
17464
      }
17465
 
17466
      /**
17467
       * Find the _Fields constant that matches name, or null if its not found.
17468
       */
17469
      public static _Fields findByName(String name) {
17470
        return byName.get(name);
17471
      }
17472
 
17473
      private final short _thriftId;
17474
      private final String _fieldName;
17475
 
17476
      _Fields(short thriftId, String fieldName) {
17477
        _thriftId = thriftId;
17478
        _fieldName = fieldName;
17479
      }
17480
 
17481
      public short getThriftFieldId() {
17482
        return _thriftId;
17483
      }
17484
 
17485
      public String getFieldName() {
17486
        return _fieldName;
17487
      }
17488
    }
17489
 
17490
    // isset id assignments
17491
 
17492
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17493
    static {
17494
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17495
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17496
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
17497
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class))));
17498
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17499
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
17500
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17501
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendorItemMappings_result.class, metaDataMap);
17502
    }
17503
 
17504
    public getVendorItemMappings_result() {
17505
    }
17506
 
17507
    public getVendorItemMappings_result(
17508
      List<VendorItemMapping> success,
17509
      InventoryServiceException cex)
17510
    {
17511
      this();
17512
      this.success = success;
17513
      this.cex = cex;
17514
    }
17515
 
17516
    /**
17517
     * Performs a deep copy on <i>other</i>.
17518
     */
17519
    public getVendorItemMappings_result(getVendorItemMappings_result other) {
17520
      if (other.isSetSuccess()) {
17521
        List<VendorItemMapping> __this__success = new ArrayList<VendorItemMapping>();
17522
        for (VendorItemMapping other_element : other.success) {
17523
          __this__success.add(new VendorItemMapping(other_element));
17524
        }
17525
        this.success = __this__success;
17526
      }
17527
      if (other.isSetCex()) {
17528
        this.cex = new InventoryServiceException(other.cex);
17529
      }
17530
    }
17531
 
17532
    public getVendorItemMappings_result deepCopy() {
17533
      return new getVendorItemMappings_result(this);
17534
    }
17535
 
17536
    @Override
17537
    public void clear() {
17538
      this.success = null;
17539
      this.cex = null;
17540
    }
17541
 
17542
    public int getSuccessSize() {
17543
      return (this.success == null) ? 0 : this.success.size();
17544
    }
17545
 
17546
    public java.util.Iterator<VendorItemMapping> getSuccessIterator() {
17547
      return (this.success == null) ? null : this.success.iterator();
17548
    }
17549
 
17550
    public void addToSuccess(VendorItemMapping elem) {
17551
      if (this.success == null) {
17552
        this.success = new ArrayList<VendorItemMapping>();
17553
      }
17554
      this.success.add(elem);
17555
    }
17556
 
17557
    public List<VendorItemMapping> getSuccess() {
17558
      return this.success;
17559
    }
17560
 
17561
    public void setSuccess(List<VendorItemMapping> success) {
17562
      this.success = success;
17563
    }
17564
 
17565
    public void unsetSuccess() {
17566
      this.success = null;
17567
    }
17568
 
17569
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17570
    public boolean isSetSuccess() {
17571
      return this.success != null;
17572
    }
17573
 
17574
    public void setSuccessIsSet(boolean value) {
17575
      if (!value) {
17576
        this.success = null;
17577
      }
17578
    }
17579
 
17580
    public InventoryServiceException getCex() {
17581
      return this.cex;
17582
    }
17583
 
17584
    public void setCex(InventoryServiceException cex) {
17585
      this.cex = cex;
17586
    }
17587
 
17588
    public void unsetCex() {
17589
      this.cex = null;
17590
    }
17591
 
17592
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
17593
    public boolean isSetCex() {
17594
      return this.cex != null;
17595
    }
17596
 
17597
    public void setCexIsSet(boolean value) {
17598
      if (!value) {
17599
        this.cex = null;
17600
      }
17601
    }
17602
 
17603
    public void setFieldValue(_Fields field, Object value) {
17604
      switch (field) {
17605
      case SUCCESS:
17606
        if (value == null) {
17607
          unsetSuccess();
17608
        } else {
17609
          setSuccess((List<VendorItemMapping>)value);
17610
        }
17611
        break;
17612
 
17613
      case CEX:
17614
        if (value == null) {
17615
          unsetCex();
17616
        } else {
17617
          setCex((InventoryServiceException)value);
17618
        }
17619
        break;
17620
 
17621
      }
17622
    }
17623
 
17624
    public Object getFieldValue(_Fields field) {
17625
      switch (field) {
17626
      case SUCCESS:
17627
        return getSuccess();
17628
 
17629
      case CEX:
17630
        return getCex();
17631
 
17632
      }
17633
      throw new IllegalStateException();
17634
    }
17635
 
17636
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17637
    public boolean isSet(_Fields field) {
17638
      if (field == null) {
17639
        throw new IllegalArgumentException();
17640
      }
17641
 
17642
      switch (field) {
17643
      case SUCCESS:
17644
        return isSetSuccess();
17645
      case CEX:
17646
        return isSetCex();
17647
      }
17648
      throw new IllegalStateException();
17649
    }
17650
 
17651
    @Override
17652
    public boolean equals(Object that) {
17653
      if (that == null)
17654
        return false;
17655
      if (that instanceof getVendorItemMappings_result)
17656
        return this.equals((getVendorItemMappings_result)that);
17657
      return false;
17658
    }
17659
 
17660
    public boolean equals(getVendorItemMappings_result that) {
17661
      if (that == null)
17662
        return false;
17663
 
17664
      boolean this_present_success = true && this.isSetSuccess();
17665
      boolean that_present_success = true && that.isSetSuccess();
17666
      if (this_present_success || that_present_success) {
17667
        if (!(this_present_success && that_present_success))
17668
          return false;
17669
        if (!this.success.equals(that.success))
17670
          return false;
17671
      }
17672
 
17673
      boolean this_present_cex = true && this.isSetCex();
17674
      boolean that_present_cex = true && that.isSetCex();
17675
      if (this_present_cex || that_present_cex) {
17676
        if (!(this_present_cex && that_present_cex))
17677
          return false;
17678
        if (!this.cex.equals(that.cex))
17679
          return false;
17680
      }
17681
 
17682
      return true;
17683
    }
17684
 
17685
    @Override
17686
    public int hashCode() {
17687
      return 0;
17688
    }
17689
 
17690
    public int compareTo(getVendorItemMappings_result other) {
17691
      if (!getClass().equals(other.getClass())) {
17692
        return getClass().getName().compareTo(other.getClass().getName());
17693
      }
17694
 
17695
      int lastComparison = 0;
17696
      getVendorItemMappings_result typedOther = (getVendorItemMappings_result)other;
17697
 
17698
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17699
      if (lastComparison != 0) {
17700
        return lastComparison;
17701
      }
17702
      if (isSetSuccess()) {
17703
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17704
        if (lastComparison != 0) {
17705
          return lastComparison;
17706
        }
17707
      }
17708
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
17709
      if (lastComparison != 0) {
17710
        return lastComparison;
17711
      }
17712
      if (isSetCex()) {
17713
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
17714
        if (lastComparison != 0) {
17715
          return lastComparison;
17716
        }
17717
      }
17718
      return 0;
17719
    }
17720
 
17721
    public _Fields fieldForId(int fieldId) {
17722
      return _Fields.findByThriftId(fieldId);
17723
    }
17724
 
17725
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17726
      org.apache.thrift.protocol.TField field;
17727
      iprot.readStructBegin();
17728
      while (true)
17729
      {
17730
        field = iprot.readFieldBegin();
17731
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17732
          break;
17733
        }
17734
        switch (field.id) {
17735
          case 0: // SUCCESS
17736
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
17737
              {
17738
                org.apache.thrift.protocol.TList _list40 = iprot.readListBegin();
17739
                this.success = new ArrayList<VendorItemMapping>(_list40.size);
17740
                for (int _i41 = 0; _i41 < _list40.size; ++_i41)
17741
                {
17742
                  VendorItemMapping _elem42; // required
17743
                  _elem42 = new VendorItemMapping();
17744
                  _elem42.read(iprot);
17745
                  this.success.add(_elem42);
17746
                }
17747
                iprot.readListEnd();
17748
              }
17749
            } else { 
17750
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17751
            }
17752
            break;
17753
          case 1: // CEX
17754
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
17755
              this.cex = new InventoryServiceException();
17756
              this.cex.read(iprot);
17757
            } else { 
17758
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17759
            }
17760
            break;
17761
          default:
17762
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17763
        }
17764
        iprot.readFieldEnd();
17765
      }
17766
      iprot.readStructEnd();
17767
      validate();
17768
    }
17769
 
17770
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17771
      oprot.writeStructBegin(STRUCT_DESC);
17772
 
17773
      if (this.isSetSuccess()) {
17774
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17775
        {
17776
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
17777
          for (VendorItemMapping _iter43 : this.success)
17778
          {
17779
            _iter43.write(oprot);
17780
          }
17781
          oprot.writeListEnd();
17782
        }
17783
        oprot.writeFieldEnd();
17784
      } else if (this.isSetCex()) {
17785
        oprot.writeFieldBegin(CEX_FIELD_DESC);
17786
        this.cex.write(oprot);
17787
        oprot.writeFieldEnd();
17788
      }
17789
      oprot.writeFieldStop();
17790
      oprot.writeStructEnd();
17791
    }
17792
 
17793
    @Override
17794
    public String toString() {
17795
      StringBuilder sb = new StringBuilder("getVendorItemMappings_result(");
17796
      boolean first = true;
17797
 
17798
      sb.append("success:");
17799
      if (this.success == null) {
17800
        sb.append("null");
17801
      } else {
17802
        sb.append(this.success);
17803
      }
17804
      first = false;
17805
      if (!first) sb.append(", ");
17806
      sb.append("cex:");
17807
      if (this.cex == null) {
17808
        sb.append("null");
17809
      } else {
17810
        sb.append(this.cex);
17811
      }
17812
      first = false;
17813
      sb.append(")");
17814
      return sb.toString();
17815
    }
17816
 
17817
    public void validate() throws org.apache.thrift.TException {
17818
      // check for required fields
17819
    }
17820
 
17821
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17822
      try {
17823
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17824
      } catch (org.apache.thrift.TException te) {
17825
        throw new java.io.IOException(te);
17826
      }
17827
    }
17828
 
17829
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17830
      try {
17831
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17832
      } catch (org.apache.thrift.TException te) {
17833
        throw new java.io.IOException(te);
17834
      }
17835
    }
17836
 
17837
  }
17838
 
17839
  public static class getPendingOrdersInventory_args implements org.apache.thrift.TBase<getPendingOrdersInventory_args, getPendingOrdersInventory_args._Fields>, java.io.Serializable, Cloneable   {
17840
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPendingOrdersInventory_args");
17841
 
17842
    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);
17843
 
17844
    private long vendorid; // required
17845
 
17846
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17847
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17848
      VENDORID((short)1, "vendorid");
17849
 
17850
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17851
 
17852
      static {
17853
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17854
          byName.put(field.getFieldName(), field);
17855
        }
17856
      }
17857
 
17858
      /**
17859
       * Find the _Fields constant that matches fieldId, or null if its not found.
17860
       */
17861
      public static _Fields findByThriftId(int fieldId) {
17862
        switch(fieldId) {
17863
          case 1: // VENDORID
17864
            return VENDORID;
17865
          default:
17866
            return null;
17867
        }
17868
      }
17869
 
17870
      /**
17871
       * Find the _Fields constant that matches fieldId, throwing an exception
17872
       * if it is not found.
17873
       */
17874
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17875
        _Fields fields = findByThriftId(fieldId);
17876
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17877
        return fields;
17878
      }
17879
 
17880
      /**
17881
       * Find the _Fields constant that matches name, or null if its not found.
17882
       */
17883
      public static _Fields findByName(String name) {
17884
        return byName.get(name);
17885
      }
17886
 
17887
      private final short _thriftId;
17888
      private final String _fieldName;
17889
 
17890
      _Fields(short thriftId, String fieldName) {
17891
        _thriftId = thriftId;
17892
        _fieldName = fieldName;
17893
      }
17894
 
17895
      public short getThriftFieldId() {
17896
        return _thriftId;
17897
      }
17898
 
17899
      public String getFieldName() {
17900
        return _fieldName;
17901
      }
17902
    }
17903
 
17904
    // isset id assignments
17905
    private static final int __VENDORID_ISSET_ID = 0;
17906
    private BitSet __isset_bit_vector = new BitSet(1);
17907
 
17908
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17909
    static {
17910
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17911
      tmpMap.put(_Fields.VENDORID, new org.apache.thrift.meta_data.FieldMetaData("vendorid", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17912
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
17913
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17914
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPendingOrdersInventory_args.class, metaDataMap);
17915
    }
17916
 
17917
    public getPendingOrdersInventory_args() {
17918
    }
17919
 
17920
    public getPendingOrdersInventory_args(
17921
      long vendorid)
17922
    {
17923
      this();
17924
      this.vendorid = vendorid;
17925
      setVendoridIsSet(true);
17926
    }
17927
 
17928
    /**
17929
     * Performs a deep copy on <i>other</i>.
17930
     */
17931
    public getPendingOrdersInventory_args(getPendingOrdersInventory_args other) {
17932
      __isset_bit_vector.clear();
17933
      __isset_bit_vector.or(other.__isset_bit_vector);
17934
      this.vendorid = other.vendorid;
17935
    }
17936
 
17937
    public getPendingOrdersInventory_args deepCopy() {
17938
      return new getPendingOrdersInventory_args(this);
17939
    }
17940
 
17941
    @Override
17942
    public void clear() {
17943
      setVendoridIsSet(false);
17944
      this.vendorid = 0;
17945
    }
17946
 
17947
    public long getVendorid() {
17948
      return this.vendorid;
17949
    }
17950
 
17951
    public void setVendorid(long vendorid) {
17952
      this.vendorid = vendorid;
17953
      setVendoridIsSet(true);
17954
    }
17955
 
17956
    public void unsetVendorid() {
17957
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
17958
    }
17959
 
17960
    /** Returns true if field vendorid is set (has been assigned a value) and false otherwise */
17961
    public boolean isSetVendorid() {
17962
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
17963
    }
17964
 
17965
    public void setVendoridIsSet(boolean value) {
17966
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
17967
    }
17968
 
17969
    public void setFieldValue(_Fields field, Object value) {
17970
      switch (field) {
17971
      case VENDORID:
17972
        if (value == null) {
17973
          unsetVendorid();
17974
        } else {
17975
          setVendorid((Long)value);
17976
        }
17977
        break;
17978
 
17979
      }
17980
    }
17981
 
17982
    public Object getFieldValue(_Fields field) {
17983
      switch (field) {
17984
      case VENDORID:
17985
        return Long.valueOf(getVendorid());
17986
 
17987
      }
17988
      throw new IllegalStateException();
17989
    }
17990
 
17991
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17992
    public boolean isSet(_Fields field) {
17993
      if (field == null) {
17994
        throw new IllegalArgumentException();
17995
      }
17996
 
17997
      switch (field) {
17998
      case VENDORID:
17999
        return isSetVendorid();
18000
      }
18001
      throw new IllegalStateException();
18002
    }
18003
 
18004
    @Override
18005
    public boolean equals(Object that) {
18006
      if (that == null)
18007
        return false;
18008
      if (that instanceof getPendingOrdersInventory_args)
18009
        return this.equals((getPendingOrdersInventory_args)that);
18010
      return false;
18011
    }
18012
 
18013
    public boolean equals(getPendingOrdersInventory_args that) {
18014
      if (that == null)
18015
        return false;
18016
 
18017
      boolean this_present_vendorid = true;
18018
      boolean that_present_vendorid = true;
18019
      if (this_present_vendorid || that_present_vendorid) {
18020
        if (!(this_present_vendorid && that_present_vendorid))
18021
          return false;
18022
        if (this.vendorid != that.vendorid)
18023
          return false;
18024
      }
18025
 
18026
      return true;
18027
    }
18028
 
18029
    @Override
18030
    public int hashCode() {
18031
      return 0;
18032
    }
18033
 
18034
    public int compareTo(getPendingOrdersInventory_args other) {
18035
      if (!getClass().equals(other.getClass())) {
18036
        return getClass().getName().compareTo(other.getClass().getName());
18037
      }
18038
 
18039
      int lastComparison = 0;
18040
      getPendingOrdersInventory_args typedOther = (getPendingOrdersInventory_args)other;
18041
 
18042
      lastComparison = Boolean.valueOf(isSetVendorid()).compareTo(typedOther.isSetVendorid());
18043
      if (lastComparison != 0) {
18044
        return lastComparison;
18045
      }
18046
      if (isSetVendorid()) {
18047
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorid, typedOther.vendorid);
18048
        if (lastComparison != 0) {
18049
          return lastComparison;
18050
        }
18051
      }
18052
      return 0;
18053
    }
18054
 
18055
    public _Fields fieldForId(int fieldId) {
18056
      return _Fields.findByThriftId(fieldId);
18057
    }
18058
 
18059
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18060
      org.apache.thrift.protocol.TField field;
18061
      iprot.readStructBegin();
18062
      while (true)
18063
      {
18064
        field = iprot.readFieldBegin();
18065
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18066
          break;
18067
        }
18068
        switch (field.id) {
18069
          case 1: // VENDORID
18070
            if (field.type == org.apache.thrift.protocol.TType.I64) {
18071
              this.vendorid = iprot.readI64();
18072
              setVendoridIsSet(true);
18073
            } else { 
18074
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18075
            }
18076
            break;
18077
          default:
18078
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18079
        }
18080
        iprot.readFieldEnd();
18081
      }
18082
      iprot.readStructEnd();
18083
      validate();
18084
    }
18085
 
18086
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18087
      validate();
18088
 
18089
      oprot.writeStructBegin(STRUCT_DESC);
18090
      oprot.writeFieldBegin(VENDORID_FIELD_DESC);
18091
      oprot.writeI64(this.vendorid);
18092
      oprot.writeFieldEnd();
18093
      oprot.writeFieldStop();
18094
      oprot.writeStructEnd();
18095
    }
18096
 
18097
    @Override
18098
    public String toString() {
18099
      StringBuilder sb = new StringBuilder("getPendingOrdersInventory_args(");
18100
      boolean first = true;
18101
 
18102
      sb.append("vendorid:");
18103
      sb.append(this.vendorid);
18104
      first = false;
18105
      sb.append(")");
18106
      return sb.toString();
18107
    }
18108
 
18109
    public void validate() throws org.apache.thrift.TException {
18110
      // check for required fields
18111
    }
18112
 
18113
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18114
      try {
18115
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18116
      } catch (org.apache.thrift.TException te) {
18117
        throw new java.io.IOException(te);
18118
      }
18119
    }
18120
 
18121
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18122
      try {
18123
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
18124
        __isset_bit_vector = new BitSet(1);
18125
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18126
      } catch (org.apache.thrift.TException te) {
18127
        throw new java.io.IOException(te);
18128
      }
18129
    }
18130
 
18131
  }
18132
 
18133
  public static class getPendingOrdersInventory_result implements org.apache.thrift.TBase<getPendingOrdersInventory_result, getPendingOrdersInventory_result._Fields>, java.io.Serializable, Cloneable   {
18134
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPendingOrdersInventory_result");
18135
 
18136
    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);
18137
 
18138
    private List<AvailableAndReservedStock> success; // required
18139
 
18140
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18141
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18142
      SUCCESS((short)0, "success");
18143
 
18144
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18145
 
18146
      static {
18147
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18148
          byName.put(field.getFieldName(), field);
18149
        }
18150
      }
18151
 
18152
      /**
18153
       * Find the _Fields constant that matches fieldId, or null if its not found.
18154
       */
18155
      public static _Fields findByThriftId(int fieldId) {
18156
        switch(fieldId) {
18157
          case 0: // SUCCESS
18158
            return SUCCESS;
18159
          default:
18160
            return null;
18161
        }
18162
      }
18163
 
18164
      /**
18165
       * Find the _Fields constant that matches fieldId, throwing an exception
18166
       * if it is not found.
18167
       */
18168
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18169
        _Fields fields = findByThriftId(fieldId);
18170
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18171
        return fields;
18172
      }
18173
 
18174
      /**
18175
       * Find the _Fields constant that matches name, or null if its not found.
18176
       */
18177
      public static _Fields findByName(String name) {
18178
        return byName.get(name);
18179
      }
18180
 
18181
      private final short _thriftId;
18182
      private final String _fieldName;
18183
 
18184
      _Fields(short thriftId, String fieldName) {
18185
        _thriftId = thriftId;
18186
        _fieldName = fieldName;
18187
      }
18188
 
18189
      public short getThriftFieldId() {
18190
        return _thriftId;
18191
      }
18192
 
18193
      public String getFieldName() {
18194
        return _fieldName;
18195
      }
18196
    }
18197
 
18198
    // isset id assignments
18199
 
18200
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18201
    static {
18202
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18203
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18204
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
18205
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, AvailableAndReservedStock.class))));
18206
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18207
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPendingOrdersInventory_result.class, metaDataMap);
18208
    }
18209
 
18210
    public getPendingOrdersInventory_result() {
18211
    }
18212
 
18213
    public getPendingOrdersInventory_result(
18214
      List<AvailableAndReservedStock> success)
18215
    {
18216
      this();
18217
      this.success = success;
18218
    }
18219
 
18220
    /**
18221
     * Performs a deep copy on <i>other</i>.
18222
     */
18223
    public getPendingOrdersInventory_result(getPendingOrdersInventory_result other) {
18224
      if (other.isSetSuccess()) {
18225
        List<AvailableAndReservedStock> __this__success = new ArrayList<AvailableAndReservedStock>();
18226
        for (AvailableAndReservedStock other_element : other.success) {
18227
          __this__success.add(new AvailableAndReservedStock(other_element));
18228
        }
18229
        this.success = __this__success;
18230
      }
18231
    }
18232
 
18233
    public getPendingOrdersInventory_result deepCopy() {
18234
      return new getPendingOrdersInventory_result(this);
18235
    }
18236
 
18237
    @Override
18238
    public void clear() {
18239
      this.success = null;
18240
    }
18241
 
18242
    public int getSuccessSize() {
18243
      return (this.success == null) ? 0 : this.success.size();
18244
    }
18245
 
18246
    public java.util.Iterator<AvailableAndReservedStock> getSuccessIterator() {
18247
      return (this.success == null) ? null : this.success.iterator();
18248
    }
18249
 
18250
    public void addToSuccess(AvailableAndReservedStock elem) {
18251
      if (this.success == null) {
18252
        this.success = new ArrayList<AvailableAndReservedStock>();
18253
      }
18254
      this.success.add(elem);
18255
    }
18256
 
18257
    public List<AvailableAndReservedStock> getSuccess() {
18258
      return this.success;
18259
    }
18260
 
18261
    public void setSuccess(List<AvailableAndReservedStock> success) {
18262
      this.success = success;
18263
    }
18264
 
18265
    public void unsetSuccess() {
18266
      this.success = null;
18267
    }
18268
 
18269
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
18270
    public boolean isSetSuccess() {
18271
      return this.success != null;
18272
    }
18273
 
18274
    public void setSuccessIsSet(boolean value) {
18275
      if (!value) {
18276
        this.success = null;
18277
      }
18278
    }
18279
 
18280
    public void setFieldValue(_Fields field, Object value) {
18281
      switch (field) {
18282
      case SUCCESS:
18283
        if (value == null) {
18284
          unsetSuccess();
18285
        } else {
18286
          setSuccess((List<AvailableAndReservedStock>)value);
18287
        }
18288
        break;
18289
 
18290
      }
18291
    }
18292
 
18293
    public Object getFieldValue(_Fields field) {
18294
      switch (field) {
18295
      case SUCCESS:
18296
        return getSuccess();
18297
 
18298
      }
18299
      throw new IllegalStateException();
18300
    }
18301
 
18302
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18303
    public boolean isSet(_Fields field) {
18304
      if (field == null) {
18305
        throw new IllegalArgumentException();
18306
      }
18307
 
18308
      switch (field) {
18309
      case SUCCESS:
18310
        return isSetSuccess();
18311
      }
18312
      throw new IllegalStateException();
18313
    }
18314
 
18315
    @Override
18316
    public boolean equals(Object that) {
18317
      if (that == null)
18318
        return false;
18319
      if (that instanceof getPendingOrdersInventory_result)
18320
        return this.equals((getPendingOrdersInventory_result)that);
18321
      return false;
18322
    }
18323
 
18324
    public boolean equals(getPendingOrdersInventory_result that) {
18325
      if (that == null)
18326
        return false;
18327
 
18328
      boolean this_present_success = true && this.isSetSuccess();
18329
      boolean that_present_success = true && that.isSetSuccess();
18330
      if (this_present_success || that_present_success) {
18331
        if (!(this_present_success && that_present_success))
18332
          return false;
18333
        if (!this.success.equals(that.success))
18334
          return false;
18335
      }
18336
 
18337
      return true;
18338
    }
18339
 
18340
    @Override
18341
    public int hashCode() {
18342
      return 0;
18343
    }
18344
 
18345
    public int compareTo(getPendingOrdersInventory_result other) {
18346
      if (!getClass().equals(other.getClass())) {
18347
        return getClass().getName().compareTo(other.getClass().getName());
18348
      }
18349
 
18350
      int lastComparison = 0;
18351
      getPendingOrdersInventory_result typedOther = (getPendingOrdersInventory_result)other;
18352
 
18353
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
18354
      if (lastComparison != 0) {
18355
        return lastComparison;
18356
      }
18357
      if (isSetSuccess()) {
18358
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
18359
        if (lastComparison != 0) {
18360
          return lastComparison;
18361
        }
18362
      }
18363
      return 0;
18364
    }
18365
 
18366
    public _Fields fieldForId(int fieldId) {
18367
      return _Fields.findByThriftId(fieldId);
18368
    }
18369
 
18370
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18371
      org.apache.thrift.protocol.TField field;
18372
      iprot.readStructBegin();
18373
      while (true)
18374
      {
18375
        field = iprot.readFieldBegin();
18376
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18377
          break;
18378
        }
18379
        switch (field.id) {
18380
          case 0: // SUCCESS
18381
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
18382
              {
18383
                org.apache.thrift.protocol.TList _list44 = iprot.readListBegin();
18384
                this.success = new ArrayList<AvailableAndReservedStock>(_list44.size);
18385
                for (int _i45 = 0; _i45 < _list44.size; ++_i45)
18386
                {
18387
                  AvailableAndReservedStock _elem46; // required
18388
                  _elem46 = new AvailableAndReservedStock();
18389
                  _elem46.read(iprot);
18390
                  this.success.add(_elem46);
18391
                }
18392
                iprot.readListEnd();
18393
              }
18394
            } else { 
18395
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18396
            }
18397
            break;
18398
          default:
18399
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18400
        }
18401
        iprot.readFieldEnd();
18402
      }
18403
      iprot.readStructEnd();
18404
      validate();
18405
    }
18406
 
18407
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18408
      oprot.writeStructBegin(STRUCT_DESC);
18409
 
18410
      if (this.isSetSuccess()) {
18411
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
18412
        {
18413
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
18414
          for (AvailableAndReservedStock _iter47 : this.success)
18415
          {
18416
            _iter47.write(oprot);
18417
          }
18418
          oprot.writeListEnd();
18419
        }
18420
        oprot.writeFieldEnd();
18421
      }
18422
      oprot.writeFieldStop();
18423
      oprot.writeStructEnd();
18424
    }
18425
 
18426
    @Override
18427
    public String toString() {
18428
      StringBuilder sb = new StringBuilder("getPendingOrdersInventory_result(");
18429
      boolean first = true;
18430
 
18431
      sb.append("success:");
18432
      if (this.success == null) {
18433
        sb.append("null");
18434
      } else {
18435
        sb.append(this.success);
18436
      }
18437
      first = false;
18438
      sb.append(")");
18439
      return sb.toString();
18440
    }
18441
 
18442
    public void validate() throws org.apache.thrift.TException {
18443
      // check for required fields
18444
    }
18445
 
18446
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18447
      try {
18448
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18449
      } catch (org.apache.thrift.TException te) {
18450
        throw new java.io.IOException(te);
18451
      }
18452
    }
18453
 
18454
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18455
      try {
18456
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18457
      } catch (org.apache.thrift.TException te) {
18458
        throw new java.io.IOException(te);
18459
      }
18460
    }
18461
 
18462
  }
18463
 
18464
  public static class getWarehouses_args implements org.apache.thrift.TBase<getWarehouses_args, getWarehouses_args._Fields>, java.io.Serializable, Cloneable   {
18465
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouses_args");
18466
 
18467
    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);
18468
    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);
18469
    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);
18470
    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);
18471
    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);
18472
 
18473
    private WarehouseType warehouseType; // required
18474
    private InventoryType inventoryType; // required
18475
    private long vendorId; // required
18476
    private long billingWarehouseId; // required
18477
    private long shippingWarehouseId; // required
18478
 
18479
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18480
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18481
      /**
18482
       * 
18483
       * @see WarehouseType
18484
       */
18485
      WAREHOUSE_TYPE((short)1, "warehouseType"),
18486
      /**
18487
       * 
18488
       * @see InventoryType
18489
       */
18490
      INVENTORY_TYPE((short)2, "inventoryType"),
18491
      VENDOR_ID((short)3, "vendorId"),
18492
      BILLING_WAREHOUSE_ID((short)4, "billingWarehouseId"),
18493
      SHIPPING_WAREHOUSE_ID((short)5, "shippingWarehouseId");
18494
 
18495
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18496
 
18497
      static {
18498
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18499
          byName.put(field.getFieldName(), field);
18500
        }
18501
      }
18502
 
18503
      /**
18504
       * Find the _Fields constant that matches fieldId, or null if its not found.
18505
       */
18506
      public static _Fields findByThriftId(int fieldId) {
18507
        switch(fieldId) {
18508
          case 1: // WAREHOUSE_TYPE
18509
            return WAREHOUSE_TYPE;
18510
          case 2: // INVENTORY_TYPE
18511
            return INVENTORY_TYPE;
18512
          case 3: // VENDOR_ID
18513
            return VENDOR_ID;
18514
          case 4: // BILLING_WAREHOUSE_ID
18515
            return BILLING_WAREHOUSE_ID;
18516
          case 5: // SHIPPING_WAREHOUSE_ID
18517
            return SHIPPING_WAREHOUSE_ID;
18518
          default:
18519
            return null;
18520
        }
18521
      }
18522
 
18523
      /**
18524
       * Find the _Fields constant that matches fieldId, throwing an exception
18525
       * if it is not found.
18526
       */
18527
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18528
        _Fields fields = findByThriftId(fieldId);
18529
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18530
        return fields;
18531
      }
18532
 
18533
      /**
18534
       * Find the _Fields constant that matches name, or null if its not found.
18535
       */
18536
      public static _Fields findByName(String name) {
18537
        return byName.get(name);
18538
      }
18539
 
18540
      private final short _thriftId;
18541
      private final String _fieldName;
18542
 
18543
      _Fields(short thriftId, String fieldName) {
18544
        _thriftId = thriftId;
18545
        _fieldName = fieldName;
18546
      }
18547
 
18548
      public short getThriftFieldId() {
18549
        return _thriftId;
18550
      }
18551
 
18552
      public String getFieldName() {
18553
        return _fieldName;
18554
      }
18555
    }
18556
 
18557
    // isset id assignments
18558
    private static final int __VENDORID_ISSET_ID = 0;
18559
    private static final int __BILLINGWAREHOUSEID_ISSET_ID = 1;
18560
    private static final int __SHIPPINGWAREHOUSEID_ISSET_ID = 2;
18561
    private BitSet __isset_bit_vector = new BitSet(3);
18562
 
18563
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18564
    static {
18565
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18566
      tmpMap.put(_Fields.WAREHOUSE_TYPE, new org.apache.thrift.meta_data.FieldMetaData("warehouseType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18567
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, WarehouseType.class)));
18568
      tmpMap.put(_Fields.INVENTORY_TYPE, new org.apache.thrift.meta_data.FieldMetaData("inventoryType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18569
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, InventoryType.class)));
18570
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18571
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
18572
      tmpMap.put(_Fields.BILLING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("billingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18573
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
18574
      tmpMap.put(_Fields.SHIPPING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("shippingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18575
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
18576
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18577
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouses_args.class, metaDataMap);
18578
    }
18579
 
18580
    public getWarehouses_args() {
18581
    }
18582
 
18583
    public getWarehouses_args(
18584
      WarehouseType warehouseType,
18585
      InventoryType inventoryType,
18586
      long vendorId,
18587
      long billingWarehouseId,
18588
      long shippingWarehouseId)
18589
    {
18590
      this();
18591
      this.warehouseType = warehouseType;
18592
      this.inventoryType = inventoryType;
18593
      this.vendorId = vendorId;
18594
      setVendorIdIsSet(true);
18595
      this.billingWarehouseId = billingWarehouseId;
18596
      setBillingWarehouseIdIsSet(true);
18597
      this.shippingWarehouseId = shippingWarehouseId;
18598
      setShippingWarehouseIdIsSet(true);
18599
    }
18600
 
18601
    /**
18602
     * Performs a deep copy on <i>other</i>.
18603
     */
18604
    public getWarehouses_args(getWarehouses_args other) {
18605
      __isset_bit_vector.clear();
18606
      __isset_bit_vector.or(other.__isset_bit_vector);
18607
      if (other.isSetWarehouseType()) {
18608
        this.warehouseType = other.warehouseType;
18609
      }
18610
      if (other.isSetInventoryType()) {
18611
        this.inventoryType = other.inventoryType;
18612
      }
18613
      this.vendorId = other.vendorId;
18614
      this.billingWarehouseId = other.billingWarehouseId;
18615
      this.shippingWarehouseId = other.shippingWarehouseId;
18616
    }
18617
 
18618
    public getWarehouses_args deepCopy() {
18619
      return new getWarehouses_args(this);
18620
    }
18621
 
18622
    @Override
18623
    public void clear() {
18624
      this.warehouseType = null;
18625
      this.inventoryType = null;
18626
      setVendorIdIsSet(false);
18627
      this.vendorId = 0;
18628
      setBillingWarehouseIdIsSet(false);
18629
      this.billingWarehouseId = 0;
18630
      setShippingWarehouseIdIsSet(false);
18631
      this.shippingWarehouseId = 0;
18632
    }
18633
 
18634
    /**
18635
     * 
18636
     * @see WarehouseType
18637
     */
18638
    public WarehouseType getWarehouseType() {
18639
      return this.warehouseType;
18640
    }
18641
 
18642
    /**
18643
     * 
18644
     * @see WarehouseType
18645
     */
18646
    public void setWarehouseType(WarehouseType warehouseType) {
18647
      this.warehouseType = warehouseType;
18648
    }
18649
 
18650
    public void unsetWarehouseType() {
18651
      this.warehouseType = null;
18652
    }
18653
 
18654
    /** Returns true if field warehouseType is set (has been assigned a value) and false otherwise */
18655
    public boolean isSetWarehouseType() {
18656
      return this.warehouseType != null;
18657
    }
18658
 
18659
    public void setWarehouseTypeIsSet(boolean value) {
18660
      if (!value) {
18661
        this.warehouseType = null;
18662
      }
18663
    }
18664
 
18665
    /**
18666
     * 
18667
     * @see InventoryType
18668
     */
18669
    public InventoryType getInventoryType() {
18670
      return this.inventoryType;
18671
    }
18672
 
18673
    /**
18674
     * 
18675
     * @see InventoryType
18676
     */
18677
    public void setInventoryType(InventoryType inventoryType) {
18678
      this.inventoryType = inventoryType;
18679
    }
18680
 
18681
    public void unsetInventoryType() {
18682
      this.inventoryType = null;
18683
    }
18684
 
18685
    /** Returns true if field inventoryType is set (has been assigned a value) and false otherwise */
18686
    public boolean isSetInventoryType() {
18687
      return this.inventoryType != null;
18688
    }
18689
 
18690
    public void setInventoryTypeIsSet(boolean value) {
18691
      if (!value) {
18692
        this.inventoryType = null;
18693
      }
18694
    }
18695
 
18696
    public long getVendorId() {
18697
      return this.vendorId;
18698
    }
18699
 
18700
    public void setVendorId(long vendorId) {
18701
      this.vendorId = vendorId;
18702
      setVendorIdIsSet(true);
18703
    }
18704
 
18705
    public void unsetVendorId() {
18706
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
18707
    }
18708
 
18709
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
18710
    public boolean isSetVendorId() {
18711
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
18712
    }
18713
 
18714
    public void setVendorIdIsSet(boolean value) {
18715
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
18716
    }
18717
 
18718
    public long getBillingWarehouseId() {
18719
      return this.billingWarehouseId;
18720
    }
18721
 
18722
    public void setBillingWarehouseId(long billingWarehouseId) {
18723
      this.billingWarehouseId = billingWarehouseId;
18724
      setBillingWarehouseIdIsSet(true);
18725
    }
18726
 
18727
    public void unsetBillingWarehouseId() {
18728
      __isset_bit_vector.clear(__BILLINGWAREHOUSEID_ISSET_ID);
18729
    }
18730
 
18731
    /** Returns true if field billingWarehouseId is set (has been assigned a value) and false otherwise */
18732
    public boolean isSetBillingWarehouseId() {
18733
      return __isset_bit_vector.get(__BILLINGWAREHOUSEID_ISSET_ID);
18734
    }
18735
 
18736
    public void setBillingWarehouseIdIsSet(boolean value) {
18737
      __isset_bit_vector.set(__BILLINGWAREHOUSEID_ISSET_ID, value);
18738
    }
18739
 
18740
    public long getShippingWarehouseId() {
18741
      return this.shippingWarehouseId;
18742
    }
18743
 
18744
    public void setShippingWarehouseId(long shippingWarehouseId) {
18745
      this.shippingWarehouseId = shippingWarehouseId;
18746
      setShippingWarehouseIdIsSet(true);
18747
    }
18748
 
18749
    public void unsetShippingWarehouseId() {
18750
      __isset_bit_vector.clear(__SHIPPINGWAREHOUSEID_ISSET_ID);
18751
    }
18752
 
18753
    /** Returns true if field shippingWarehouseId is set (has been assigned a value) and false otherwise */
18754
    public boolean isSetShippingWarehouseId() {
18755
      return __isset_bit_vector.get(__SHIPPINGWAREHOUSEID_ISSET_ID);
18756
    }
18757
 
18758
    public void setShippingWarehouseIdIsSet(boolean value) {
18759
      __isset_bit_vector.set(__SHIPPINGWAREHOUSEID_ISSET_ID, value);
18760
    }
18761
 
18762
    public void setFieldValue(_Fields field, Object value) {
18763
      switch (field) {
18764
      case WAREHOUSE_TYPE:
18765
        if (value == null) {
18766
          unsetWarehouseType();
18767
        } else {
18768
          setWarehouseType((WarehouseType)value);
18769
        }
18770
        break;
18771
 
18772
      case INVENTORY_TYPE:
18773
        if (value == null) {
18774
          unsetInventoryType();
18775
        } else {
18776
          setInventoryType((InventoryType)value);
18777
        }
18778
        break;
18779
 
18780
      case VENDOR_ID:
18781
        if (value == null) {
18782
          unsetVendorId();
18783
        } else {
18784
          setVendorId((Long)value);
18785
        }
18786
        break;
18787
 
18788
      case BILLING_WAREHOUSE_ID:
18789
        if (value == null) {
18790
          unsetBillingWarehouseId();
18791
        } else {
18792
          setBillingWarehouseId((Long)value);
18793
        }
18794
        break;
18795
 
18796
      case SHIPPING_WAREHOUSE_ID:
18797
        if (value == null) {
18798
          unsetShippingWarehouseId();
18799
        } else {
18800
          setShippingWarehouseId((Long)value);
18801
        }
18802
        break;
18803
 
18804
      }
18805
    }
18806
 
18807
    public Object getFieldValue(_Fields field) {
18808
      switch (field) {
18809
      case WAREHOUSE_TYPE:
18810
        return getWarehouseType();
18811
 
18812
      case INVENTORY_TYPE:
18813
        return getInventoryType();
18814
 
18815
      case VENDOR_ID:
18816
        return Long.valueOf(getVendorId());
18817
 
18818
      case BILLING_WAREHOUSE_ID:
18819
        return Long.valueOf(getBillingWarehouseId());
18820
 
18821
      case SHIPPING_WAREHOUSE_ID:
18822
        return Long.valueOf(getShippingWarehouseId());
18823
 
18824
      }
18825
      throw new IllegalStateException();
18826
    }
18827
 
18828
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18829
    public boolean isSet(_Fields field) {
18830
      if (field == null) {
18831
        throw new IllegalArgumentException();
18832
      }
18833
 
18834
      switch (field) {
18835
      case WAREHOUSE_TYPE:
18836
        return isSetWarehouseType();
18837
      case INVENTORY_TYPE:
18838
        return isSetInventoryType();
18839
      case VENDOR_ID:
18840
        return isSetVendorId();
18841
      case BILLING_WAREHOUSE_ID:
18842
        return isSetBillingWarehouseId();
18843
      case SHIPPING_WAREHOUSE_ID:
18844
        return isSetShippingWarehouseId();
18845
      }
18846
      throw new IllegalStateException();
18847
    }
18848
 
18849
    @Override
18850
    public boolean equals(Object that) {
18851
      if (that == null)
18852
        return false;
18853
      if (that instanceof getWarehouses_args)
18854
        return this.equals((getWarehouses_args)that);
18855
      return false;
18856
    }
18857
 
18858
    public boolean equals(getWarehouses_args that) {
18859
      if (that == null)
18860
        return false;
18861
 
18862
      boolean this_present_warehouseType = true && this.isSetWarehouseType();
18863
      boolean that_present_warehouseType = true && that.isSetWarehouseType();
18864
      if (this_present_warehouseType || that_present_warehouseType) {
18865
        if (!(this_present_warehouseType && that_present_warehouseType))
18866
          return false;
18867
        if (!this.warehouseType.equals(that.warehouseType))
18868
          return false;
18869
      }
18870
 
18871
      boolean this_present_inventoryType = true && this.isSetInventoryType();
18872
      boolean that_present_inventoryType = true && that.isSetInventoryType();
18873
      if (this_present_inventoryType || that_present_inventoryType) {
18874
        if (!(this_present_inventoryType && that_present_inventoryType))
18875
          return false;
18876
        if (!this.inventoryType.equals(that.inventoryType))
18877
          return false;
18878
      }
18879
 
18880
      boolean this_present_vendorId = true;
18881
      boolean that_present_vendorId = true;
18882
      if (this_present_vendorId || that_present_vendorId) {
18883
        if (!(this_present_vendorId && that_present_vendorId))
18884
          return false;
18885
        if (this.vendorId != that.vendorId)
18886
          return false;
18887
      }
18888
 
18889
      boolean this_present_billingWarehouseId = true;
18890
      boolean that_present_billingWarehouseId = true;
18891
      if (this_present_billingWarehouseId || that_present_billingWarehouseId) {
18892
        if (!(this_present_billingWarehouseId && that_present_billingWarehouseId))
18893
          return false;
18894
        if (this.billingWarehouseId != that.billingWarehouseId)
18895
          return false;
18896
      }
18897
 
18898
      boolean this_present_shippingWarehouseId = true;
18899
      boolean that_present_shippingWarehouseId = true;
18900
      if (this_present_shippingWarehouseId || that_present_shippingWarehouseId) {
18901
        if (!(this_present_shippingWarehouseId && that_present_shippingWarehouseId))
18902
          return false;
18903
        if (this.shippingWarehouseId != that.shippingWarehouseId)
18904
          return false;
18905
      }
18906
 
18907
      return true;
18908
    }
18909
 
18910
    @Override
18911
    public int hashCode() {
18912
      return 0;
18913
    }
18914
 
18915
    public int compareTo(getWarehouses_args other) {
18916
      if (!getClass().equals(other.getClass())) {
18917
        return getClass().getName().compareTo(other.getClass().getName());
18918
      }
18919
 
18920
      int lastComparison = 0;
18921
      getWarehouses_args typedOther = (getWarehouses_args)other;
18922
 
18923
      lastComparison = Boolean.valueOf(isSetWarehouseType()).compareTo(typedOther.isSetWarehouseType());
18924
      if (lastComparison != 0) {
18925
        return lastComparison;
18926
      }
18927
      if (isSetWarehouseType()) {
18928
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseType, typedOther.warehouseType);
18929
        if (lastComparison != 0) {
18930
          return lastComparison;
18931
        }
18932
      }
18933
      lastComparison = Boolean.valueOf(isSetInventoryType()).compareTo(typedOther.isSetInventoryType());
18934
      if (lastComparison != 0) {
18935
        return lastComparison;
18936
      }
18937
      if (isSetInventoryType()) {
18938
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.inventoryType, typedOther.inventoryType);
18939
        if (lastComparison != 0) {
18940
          return lastComparison;
18941
        }
18942
      }
18943
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
18944
      if (lastComparison != 0) {
18945
        return lastComparison;
18946
      }
18947
      if (isSetVendorId()) {
18948
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
18949
        if (lastComparison != 0) {
18950
          return lastComparison;
18951
        }
18952
      }
18953
      lastComparison = Boolean.valueOf(isSetBillingWarehouseId()).compareTo(typedOther.isSetBillingWarehouseId());
18954
      if (lastComparison != 0) {
18955
        return lastComparison;
18956
      }
18957
      if (isSetBillingWarehouseId()) {
18958
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.billingWarehouseId, typedOther.billingWarehouseId);
18959
        if (lastComparison != 0) {
18960
          return lastComparison;
18961
        }
18962
      }
18963
      lastComparison = Boolean.valueOf(isSetShippingWarehouseId()).compareTo(typedOther.isSetShippingWarehouseId());
18964
      if (lastComparison != 0) {
18965
        return lastComparison;
18966
      }
18967
      if (isSetShippingWarehouseId()) {
18968
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.shippingWarehouseId, typedOther.shippingWarehouseId);
18969
        if (lastComparison != 0) {
18970
          return lastComparison;
18971
        }
18972
      }
18973
      return 0;
18974
    }
18975
 
18976
    public _Fields fieldForId(int fieldId) {
18977
      return _Fields.findByThriftId(fieldId);
18978
    }
18979
 
18980
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18981
      org.apache.thrift.protocol.TField field;
18982
      iprot.readStructBegin();
18983
      while (true)
18984
      {
18985
        field = iprot.readFieldBegin();
18986
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18987
          break;
18988
        }
18989
        switch (field.id) {
18990
          case 1: // WAREHOUSE_TYPE
18991
            if (field.type == org.apache.thrift.protocol.TType.I32) {
18992
              this.warehouseType = WarehouseType.findByValue(iprot.readI32());
18993
            } else { 
18994
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18995
            }
18996
            break;
18997
          case 2: // INVENTORY_TYPE
18998
            if (field.type == org.apache.thrift.protocol.TType.I32) {
18999
              this.inventoryType = InventoryType.findByValue(iprot.readI32());
19000
            } else { 
19001
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19002
            }
19003
            break;
19004
          case 3: // VENDOR_ID
19005
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19006
              this.vendorId = iprot.readI64();
19007
              setVendorIdIsSet(true);
19008
            } else { 
19009
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19010
            }
19011
            break;
19012
          case 4: // BILLING_WAREHOUSE_ID
19013
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19014
              this.billingWarehouseId = iprot.readI64();
19015
              setBillingWarehouseIdIsSet(true);
19016
            } else { 
19017
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19018
            }
19019
            break;
19020
          case 5: // SHIPPING_WAREHOUSE_ID
19021
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19022
              this.shippingWarehouseId = iprot.readI64();
19023
              setShippingWarehouseIdIsSet(true);
19024
            } else { 
19025
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19026
            }
19027
            break;
19028
          default:
19029
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19030
        }
19031
        iprot.readFieldEnd();
19032
      }
19033
      iprot.readStructEnd();
19034
      validate();
19035
    }
19036
 
19037
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19038
      validate();
19039
 
19040
      oprot.writeStructBegin(STRUCT_DESC);
19041
      if (this.warehouseType != null) {
19042
        oprot.writeFieldBegin(WAREHOUSE_TYPE_FIELD_DESC);
19043
        oprot.writeI32(this.warehouseType.getValue());
19044
        oprot.writeFieldEnd();
19045
      }
19046
      if (this.inventoryType != null) {
19047
        oprot.writeFieldBegin(INVENTORY_TYPE_FIELD_DESC);
19048
        oprot.writeI32(this.inventoryType.getValue());
19049
        oprot.writeFieldEnd();
19050
      }
19051
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
19052
      oprot.writeI64(this.vendorId);
19053
      oprot.writeFieldEnd();
19054
      oprot.writeFieldBegin(BILLING_WAREHOUSE_ID_FIELD_DESC);
19055
      oprot.writeI64(this.billingWarehouseId);
19056
      oprot.writeFieldEnd();
19057
      oprot.writeFieldBegin(SHIPPING_WAREHOUSE_ID_FIELD_DESC);
19058
      oprot.writeI64(this.shippingWarehouseId);
19059
      oprot.writeFieldEnd();
19060
      oprot.writeFieldStop();
19061
      oprot.writeStructEnd();
19062
    }
19063
 
19064
    @Override
19065
    public String toString() {
19066
      StringBuilder sb = new StringBuilder("getWarehouses_args(");
19067
      boolean first = true;
19068
 
19069
      sb.append("warehouseType:");
19070
      if (this.warehouseType == null) {
19071
        sb.append("null");
19072
      } else {
19073
        sb.append(this.warehouseType);
19074
      }
19075
      first = false;
19076
      if (!first) sb.append(", ");
19077
      sb.append("inventoryType:");
19078
      if (this.inventoryType == null) {
19079
        sb.append("null");
19080
      } else {
19081
        sb.append(this.inventoryType);
19082
      }
19083
      first = false;
19084
      if (!first) sb.append(", ");
19085
      sb.append("vendorId:");
19086
      sb.append(this.vendorId);
19087
      first = false;
19088
      if (!first) sb.append(", ");
19089
      sb.append("billingWarehouseId:");
19090
      sb.append(this.billingWarehouseId);
19091
      first = false;
19092
      if (!first) sb.append(", ");
19093
      sb.append("shippingWarehouseId:");
19094
      sb.append(this.shippingWarehouseId);
19095
      first = false;
19096
      sb.append(")");
19097
      return sb.toString();
19098
    }
19099
 
19100
    public void validate() throws org.apache.thrift.TException {
19101
      // check for required fields
19102
    }
19103
 
19104
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19105
      try {
19106
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19107
      } catch (org.apache.thrift.TException te) {
19108
        throw new java.io.IOException(te);
19109
      }
19110
    }
19111
 
19112
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19113
      try {
19114
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19115
      } catch (org.apache.thrift.TException te) {
19116
        throw new java.io.IOException(te);
19117
      }
19118
    }
19119
 
19120
  }
19121
 
19122
  public static class getWarehouses_result implements org.apache.thrift.TBase<getWarehouses_result, getWarehouses_result._Fields>, java.io.Serializable, Cloneable   {
19123
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouses_result");
19124
 
19125
    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);
19126
 
19127
    private List<Warehouse> success; // required
19128
 
19129
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19130
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19131
      SUCCESS((short)0, "success");
19132
 
19133
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19134
 
19135
      static {
19136
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19137
          byName.put(field.getFieldName(), field);
19138
        }
19139
      }
19140
 
19141
      /**
19142
       * Find the _Fields constant that matches fieldId, or null if its not found.
19143
       */
19144
      public static _Fields findByThriftId(int fieldId) {
19145
        switch(fieldId) {
19146
          case 0: // SUCCESS
19147
            return SUCCESS;
19148
          default:
19149
            return null;
19150
        }
19151
      }
19152
 
19153
      /**
19154
       * Find the _Fields constant that matches fieldId, throwing an exception
19155
       * if it is not found.
19156
       */
19157
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19158
        _Fields fields = findByThriftId(fieldId);
19159
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19160
        return fields;
19161
      }
19162
 
19163
      /**
19164
       * Find the _Fields constant that matches name, or null if its not found.
19165
       */
19166
      public static _Fields findByName(String name) {
19167
        return byName.get(name);
19168
      }
19169
 
19170
      private final short _thriftId;
19171
      private final String _fieldName;
19172
 
19173
      _Fields(short thriftId, String fieldName) {
19174
        _thriftId = thriftId;
19175
        _fieldName = fieldName;
19176
      }
19177
 
19178
      public short getThriftFieldId() {
19179
        return _thriftId;
19180
      }
19181
 
19182
      public String getFieldName() {
19183
        return _fieldName;
19184
      }
19185
    }
19186
 
19187
    // isset id assignments
19188
 
19189
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19190
    static {
19191
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19192
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19193
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
19194
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
19195
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19196
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouses_result.class, metaDataMap);
19197
    }
19198
 
19199
    public getWarehouses_result() {
19200
    }
19201
 
19202
    public getWarehouses_result(
19203
      List<Warehouse> success)
19204
    {
19205
      this();
19206
      this.success = success;
19207
    }
19208
 
19209
    /**
19210
     * Performs a deep copy on <i>other</i>.
19211
     */
19212
    public getWarehouses_result(getWarehouses_result other) {
19213
      if (other.isSetSuccess()) {
19214
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
19215
        for (Warehouse other_element : other.success) {
19216
          __this__success.add(new Warehouse(other_element));
19217
        }
19218
        this.success = __this__success;
19219
      }
19220
    }
19221
 
19222
    public getWarehouses_result deepCopy() {
19223
      return new getWarehouses_result(this);
19224
    }
19225
 
19226
    @Override
19227
    public void clear() {
19228
      this.success = null;
19229
    }
19230
 
19231
    public int getSuccessSize() {
19232
      return (this.success == null) ? 0 : this.success.size();
19233
    }
19234
 
19235
    public java.util.Iterator<Warehouse> getSuccessIterator() {
19236
      return (this.success == null) ? null : this.success.iterator();
19237
    }
19238
 
19239
    public void addToSuccess(Warehouse elem) {
19240
      if (this.success == null) {
19241
        this.success = new ArrayList<Warehouse>();
19242
      }
19243
      this.success.add(elem);
19244
    }
19245
 
19246
    public List<Warehouse> getSuccess() {
19247
      return this.success;
19248
    }
19249
 
19250
    public void setSuccess(List<Warehouse> success) {
19251
      this.success = success;
19252
    }
19253
 
19254
    public void unsetSuccess() {
19255
      this.success = null;
19256
    }
19257
 
19258
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
19259
    public boolean isSetSuccess() {
19260
      return this.success != null;
19261
    }
19262
 
19263
    public void setSuccessIsSet(boolean value) {
19264
      if (!value) {
19265
        this.success = null;
19266
      }
19267
    }
19268
 
19269
    public void setFieldValue(_Fields field, Object value) {
19270
      switch (field) {
19271
      case SUCCESS:
19272
        if (value == null) {
19273
          unsetSuccess();
19274
        } else {
19275
          setSuccess((List<Warehouse>)value);
19276
        }
19277
        break;
19278
 
19279
      }
19280
    }
19281
 
19282
    public Object getFieldValue(_Fields field) {
19283
      switch (field) {
19284
      case SUCCESS:
19285
        return getSuccess();
19286
 
19287
      }
19288
      throw new IllegalStateException();
19289
    }
19290
 
19291
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19292
    public boolean isSet(_Fields field) {
19293
      if (field == null) {
19294
        throw new IllegalArgumentException();
19295
      }
19296
 
19297
      switch (field) {
19298
      case SUCCESS:
19299
        return isSetSuccess();
19300
      }
19301
      throw new IllegalStateException();
19302
    }
19303
 
19304
    @Override
19305
    public boolean equals(Object that) {
19306
      if (that == null)
19307
        return false;
19308
      if (that instanceof getWarehouses_result)
19309
        return this.equals((getWarehouses_result)that);
19310
      return false;
19311
    }
19312
 
19313
    public boolean equals(getWarehouses_result that) {
19314
      if (that == null)
19315
        return false;
19316
 
19317
      boolean this_present_success = true && this.isSetSuccess();
19318
      boolean that_present_success = true && that.isSetSuccess();
19319
      if (this_present_success || that_present_success) {
19320
        if (!(this_present_success && that_present_success))
19321
          return false;
19322
        if (!this.success.equals(that.success))
19323
          return false;
19324
      }
19325
 
19326
      return true;
19327
    }
19328
 
19329
    @Override
19330
    public int hashCode() {
19331
      return 0;
19332
    }
19333
 
19334
    public int compareTo(getWarehouses_result other) {
19335
      if (!getClass().equals(other.getClass())) {
19336
        return getClass().getName().compareTo(other.getClass().getName());
19337
      }
19338
 
19339
      int lastComparison = 0;
19340
      getWarehouses_result typedOther = (getWarehouses_result)other;
19341
 
19342
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
19343
      if (lastComparison != 0) {
19344
        return lastComparison;
19345
      }
19346
      if (isSetSuccess()) {
19347
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
19348
        if (lastComparison != 0) {
19349
          return lastComparison;
19350
        }
19351
      }
19352
      return 0;
19353
    }
19354
 
19355
    public _Fields fieldForId(int fieldId) {
19356
      return _Fields.findByThriftId(fieldId);
19357
    }
19358
 
19359
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19360
      org.apache.thrift.protocol.TField field;
19361
      iprot.readStructBegin();
19362
      while (true)
19363
      {
19364
        field = iprot.readFieldBegin();
19365
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19366
          break;
19367
        }
19368
        switch (field.id) {
19369
          case 0: // SUCCESS
19370
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
19371
              {
19372
                org.apache.thrift.protocol.TList _list48 = iprot.readListBegin();
19373
                this.success = new ArrayList<Warehouse>(_list48.size);
19374
                for (int _i49 = 0; _i49 < _list48.size; ++_i49)
19375
                {
19376
                  Warehouse _elem50; // required
19377
                  _elem50 = new Warehouse();
19378
                  _elem50.read(iprot);
19379
                  this.success.add(_elem50);
19380
                }
19381
                iprot.readListEnd();
19382
              }
19383
            } else { 
19384
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19385
            }
19386
            break;
19387
          default:
19388
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19389
        }
19390
        iprot.readFieldEnd();
19391
      }
19392
      iprot.readStructEnd();
19393
      validate();
19394
    }
19395
 
19396
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19397
      oprot.writeStructBegin(STRUCT_DESC);
19398
 
19399
      if (this.isSetSuccess()) {
19400
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
19401
        {
19402
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
19403
          for (Warehouse _iter51 : this.success)
19404
          {
19405
            _iter51.write(oprot);
19406
          }
19407
          oprot.writeListEnd();
19408
        }
19409
        oprot.writeFieldEnd();
19410
      }
19411
      oprot.writeFieldStop();
19412
      oprot.writeStructEnd();
19413
    }
19414
 
19415
    @Override
19416
    public String toString() {
19417
      StringBuilder sb = new StringBuilder("getWarehouses_result(");
19418
      boolean first = true;
19419
 
19420
      sb.append("success:");
19421
      if (this.success == null) {
19422
        sb.append("null");
19423
      } else {
19424
        sb.append(this.success);
19425
      }
19426
      first = false;
19427
      sb.append(")");
19428
      return sb.toString();
19429
    }
19430
 
19431
    public void validate() throws org.apache.thrift.TException {
19432
      // check for required fields
19433
    }
19434
 
19435
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19436
      try {
19437
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19438
      } catch (org.apache.thrift.TException te) {
19439
        throw new java.io.IOException(te);
19440
      }
19441
    }
19442
 
19443
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19444
      try {
19445
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19446
      } catch (org.apache.thrift.TException te) {
19447
        throw new java.io.IOException(te);
19448
      }
19449
    }
19450
 
19451
  }
19452
 
19453
  public static class resetAvailability_args implements org.apache.thrift.TBase<resetAvailability_args, resetAvailability_args._Fields>, java.io.Serializable, Cloneable   {
19454
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailability_args");
19455
 
19456
    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);
19457
    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);
19458
    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);
19459
    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);
19460
 
19461
    private String itemKey; // required
19462
    private long vendorId; // required
19463
    private long quantity; // required
19464
    private long warehouseId; // required
19465
 
19466
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19467
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19468
      ITEM_KEY((short)1, "itemKey"),
19469
      VENDOR_ID((short)2, "vendorId"),
19470
      QUANTITY((short)3, "quantity"),
19471
      WAREHOUSE_ID((short)4, "warehouseId");
19472
 
19473
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19474
 
19475
      static {
19476
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19477
          byName.put(field.getFieldName(), field);
19478
        }
19479
      }
19480
 
19481
      /**
19482
       * Find the _Fields constant that matches fieldId, or null if its not found.
19483
       */
19484
      public static _Fields findByThriftId(int fieldId) {
19485
        switch(fieldId) {
19486
          case 1: // ITEM_KEY
19487
            return ITEM_KEY;
19488
          case 2: // VENDOR_ID
19489
            return VENDOR_ID;
19490
          case 3: // QUANTITY
19491
            return QUANTITY;
19492
          case 4: // WAREHOUSE_ID
19493
            return WAREHOUSE_ID;
19494
          default:
19495
            return null;
19496
        }
19497
      }
19498
 
19499
      /**
19500
       * Find the _Fields constant that matches fieldId, throwing an exception
19501
       * if it is not found.
19502
       */
19503
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19504
        _Fields fields = findByThriftId(fieldId);
19505
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19506
        return fields;
19507
      }
19508
 
19509
      /**
19510
       * Find the _Fields constant that matches name, or null if its not found.
19511
       */
19512
      public static _Fields findByName(String name) {
19513
        return byName.get(name);
19514
      }
19515
 
19516
      private final short _thriftId;
19517
      private final String _fieldName;
19518
 
19519
      _Fields(short thriftId, String fieldName) {
19520
        _thriftId = thriftId;
19521
        _fieldName = fieldName;
19522
      }
19523
 
19524
      public short getThriftFieldId() {
19525
        return _thriftId;
19526
      }
19527
 
19528
      public String getFieldName() {
19529
        return _fieldName;
19530
      }
19531
    }
19532
 
19533
    // isset id assignments
19534
    private static final int __VENDORID_ISSET_ID = 0;
19535
    private static final int __QUANTITY_ISSET_ID = 1;
19536
    private static final int __WAREHOUSEID_ISSET_ID = 2;
19537
    private BitSet __isset_bit_vector = new BitSet(3);
19538
 
19539
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19540
    static {
19541
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19542
      tmpMap.put(_Fields.ITEM_KEY, new org.apache.thrift.meta_data.FieldMetaData("itemKey", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19543
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
19544
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19545
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
19546
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19547
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
19548
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19549
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
19550
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19551
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailability_args.class, metaDataMap);
19552
    }
19553
 
19554
    public resetAvailability_args() {
19555
    }
19556
 
19557
    public resetAvailability_args(
19558
      String itemKey,
19559
      long vendorId,
19560
      long quantity,
19561
      long warehouseId)
19562
    {
19563
      this();
19564
      this.itemKey = itemKey;
19565
      this.vendorId = vendorId;
19566
      setVendorIdIsSet(true);
19567
      this.quantity = quantity;
19568
      setQuantityIsSet(true);
19569
      this.warehouseId = warehouseId;
19570
      setWarehouseIdIsSet(true);
19571
    }
19572
 
19573
    /**
19574
     * Performs a deep copy on <i>other</i>.
19575
     */
19576
    public resetAvailability_args(resetAvailability_args other) {
19577
      __isset_bit_vector.clear();
19578
      __isset_bit_vector.or(other.__isset_bit_vector);
19579
      if (other.isSetItemKey()) {
19580
        this.itemKey = other.itemKey;
19581
      }
19582
      this.vendorId = other.vendorId;
19583
      this.quantity = other.quantity;
19584
      this.warehouseId = other.warehouseId;
19585
    }
19586
 
19587
    public resetAvailability_args deepCopy() {
19588
      return new resetAvailability_args(this);
19589
    }
19590
 
19591
    @Override
19592
    public void clear() {
19593
      this.itemKey = null;
19594
      setVendorIdIsSet(false);
19595
      this.vendorId = 0;
19596
      setQuantityIsSet(false);
19597
      this.quantity = 0;
19598
      setWarehouseIdIsSet(false);
19599
      this.warehouseId = 0;
19600
    }
19601
 
19602
    public String getItemKey() {
19603
      return this.itemKey;
19604
    }
19605
 
19606
    public void setItemKey(String itemKey) {
19607
      this.itemKey = itemKey;
19608
    }
19609
 
19610
    public void unsetItemKey() {
19611
      this.itemKey = null;
19612
    }
19613
 
19614
    /** Returns true if field itemKey is set (has been assigned a value) and false otherwise */
19615
    public boolean isSetItemKey() {
19616
      return this.itemKey != null;
19617
    }
19618
 
19619
    public void setItemKeyIsSet(boolean value) {
19620
      if (!value) {
19621
        this.itemKey = null;
19622
      }
19623
    }
19624
 
19625
    public long getVendorId() {
19626
      return this.vendorId;
19627
    }
19628
 
19629
    public void setVendorId(long vendorId) {
19630
      this.vendorId = vendorId;
19631
      setVendorIdIsSet(true);
19632
    }
19633
 
19634
    public void unsetVendorId() {
19635
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
19636
    }
19637
 
19638
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
19639
    public boolean isSetVendorId() {
19640
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
19641
    }
19642
 
19643
    public void setVendorIdIsSet(boolean value) {
19644
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
19645
    }
19646
 
19647
    public long getQuantity() {
19648
      return this.quantity;
19649
    }
19650
 
19651
    public void setQuantity(long quantity) {
19652
      this.quantity = quantity;
19653
      setQuantityIsSet(true);
19654
    }
19655
 
19656
    public void unsetQuantity() {
19657
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
19658
    }
19659
 
19660
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
19661
    public boolean isSetQuantity() {
19662
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
19663
    }
19664
 
19665
    public void setQuantityIsSet(boolean value) {
19666
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
19667
    }
19668
 
19669
    public long getWarehouseId() {
19670
      return this.warehouseId;
19671
    }
19672
 
19673
    public void setWarehouseId(long warehouseId) {
19674
      this.warehouseId = warehouseId;
19675
      setWarehouseIdIsSet(true);
19676
    }
19677
 
19678
    public void unsetWarehouseId() {
19679
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
19680
    }
19681
 
19682
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
19683
    public boolean isSetWarehouseId() {
19684
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
19685
    }
19686
 
19687
    public void setWarehouseIdIsSet(boolean value) {
19688
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
19689
    }
19690
 
19691
    public void setFieldValue(_Fields field, Object value) {
19692
      switch (field) {
19693
      case ITEM_KEY:
19694
        if (value == null) {
19695
          unsetItemKey();
19696
        } else {
19697
          setItemKey((String)value);
19698
        }
19699
        break;
19700
 
19701
      case VENDOR_ID:
19702
        if (value == null) {
19703
          unsetVendorId();
19704
        } else {
19705
          setVendorId((Long)value);
19706
        }
19707
        break;
19708
 
19709
      case QUANTITY:
19710
        if (value == null) {
19711
          unsetQuantity();
19712
        } else {
19713
          setQuantity((Long)value);
19714
        }
19715
        break;
19716
 
19717
      case WAREHOUSE_ID:
19718
        if (value == null) {
19719
          unsetWarehouseId();
19720
        } else {
19721
          setWarehouseId((Long)value);
19722
        }
19723
        break;
19724
 
19725
      }
19726
    }
19727
 
19728
    public Object getFieldValue(_Fields field) {
19729
      switch (field) {
19730
      case ITEM_KEY:
19731
        return getItemKey();
19732
 
19733
      case VENDOR_ID:
19734
        return Long.valueOf(getVendorId());
19735
 
19736
      case QUANTITY:
19737
        return Long.valueOf(getQuantity());
19738
 
19739
      case WAREHOUSE_ID:
19740
        return Long.valueOf(getWarehouseId());
19741
 
19742
      }
19743
      throw new IllegalStateException();
19744
    }
19745
 
19746
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19747
    public boolean isSet(_Fields field) {
19748
      if (field == null) {
19749
        throw new IllegalArgumentException();
19750
      }
19751
 
19752
      switch (field) {
19753
      case ITEM_KEY:
19754
        return isSetItemKey();
19755
      case VENDOR_ID:
19756
        return isSetVendorId();
19757
      case QUANTITY:
19758
        return isSetQuantity();
19759
      case WAREHOUSE_ID:
19760
        return isSetWarehouseId();
19761
      }
19762
      throw new IllegalStateException();
19763
    }
19764
 
19765
    @Override
19766
    public boolean equals(Object that) {
19767
      if (that == null)
19768
        return false;
19769
      if (that instanceof resetAvailability_args)
19770
        return this.equals((resetAvailability_args)that);
19771
      return false;
19772
    }
19773
 
19774
    public boolean equals(resetAvailability_args that) {
19775
      if (that == null)
19776
        return false;
19777
 
19778
      boolean this_present_itemKey = true && this.isSetItemKey();
19779
      boolean that_present_itemKey = true && that.isSetItemKey();
19780
      if (this_present_itemKey || that_present_itemKey) {
19781
        if (!(this_present_itemKey && that_present_itemKey))
19782
          return false;
19783
        if (!this.itemKey.equals(that.itemKey))
19784
          return false;
19785
      }
19786
 
19787
      boolean this_present_vendorId = true;
19788
      boolean that_present_vendorId = true;
19789
      if (this_present_vendorId || that_present_vendorId) {
19790
        if (!(this_present_vendorId && that_present_vendorId))
19791
          return false;
19792
        if (this.vendorId != that.vendorId)
19793
          return false;
19794
      }
19795
 
19796
      boolean this_present_quantity = true;
19797
      boolean that_present_quantity = true;
19798
      if (this_present_quantity || that_present_quantity) {
19799
        if (!(this_present_quantity && that_present_quantity))
19800
          return false;
19801
        if (this.quantity != that.quantity)
19802
          return false;
19803
      }
19804
 
19805
      boolean this_present_warehouseId = true;
19806
      boolean that_present_warehouseId = true;
19807
      if (this_present_warehouseId || that_present_warehouseId) {
19808
        if (!(this_present_warehouseId && that_present_warehouseId))
19809
          return false;
19810
        if (this.warehouseId != that.warehouseId)
19811
          return false;
19812
      }
19813
 
19814
      return true;
19815
    }
19816
 
19817
    @Override
19818
    public int hashCode() {
19819
      return 0;
19820
    }
19821
 
19822
    public int compareTo(resetAvailability_args other) {
19823
      if (!getClass().equals(other.getClass())) {
19824
        return getClass().getName().compareTo(other.getClass().getName());
19825
      }
19826
 
19827
      int lastComparison = 0;
19828
      resetAvailability_args typedOther = (resetAvailability_args)other;
19829
 
19830
      lastComparison = Boolean.valueOf(isSetItemKey()).compareTo(typedOther.isSetItemKey());
19831
      if (lastComparison != 0) {
19832
        return lastComparison;
19833
      }
19834
      if (isSetItemKey()) {
19835
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemKey, typedOther.itemKey);
19836
        if (lastComparison != 0) {
19837
          return lastComparison;
19838
        }
19839
      }
19840
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
19841
      if (lastComparison != 0) {
19842
        return lastComparison;
19843
      }
19844
      if (isSetVendorId()) {
19845
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
19846
        if (lastComparison != 0) {
19847
          return lastComparison;
19848
        }
19849
      }
19850
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
19851
      if (lastComparison != 0) {
19852
        return lastComparison;
19853
      }
19854
      if (isSetQuantity()) {
19855
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
19856
        if (lastComparison != 0) {
19857
          return lastComparison;
19858
        }
19859
      }
19860
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
19861
      if (lastComparison != 0) {
19862
        return lastComparison;
19863
      }
19864
      if (isSetWarehouseId()) {
19865
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
19866
        if (lastComparison != 0) {
19867
          return lastComparison;
19868
        }
19869
      }
19870
      return 0;
19871
    }
19872
 
19873
    public _Fields fieldForId(int fieldId) {
19874
      return _Fields.findByThriftId(fieldId);
19875
    }
19876
 
19877
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19878
      org.apache.thrift.protocol.TField field;
19879
      iprot.readStructBegin();
19880
      while (true)
19881
      {
19882
        field = iprot.readFieldBegin();
19883
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19884
          break;
19885
        }
19886
        switch (field.id) {
19887
          case 1: // ITEM_KEY
19888
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
19889
              this.itemKey = iprot.readString();
19890
            } else { 
19891
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19892
            }
19893
            break;
19894
          case 2: // VENDOR_ID
19895
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19896
              this.vendorId = iprot.readI64();
19897
              setVendorIdIsSet(true);
19898
            } else { 
19899
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19900
            }
19901
            break;
19902
          case 3: // QUANTITY
19903
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19904
              this.quantity = iprot.readI64();
19905
              setQuantityIsSet(true);
19906
            } else { 
19907
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19908
            }
19909
            break;
19910
          case 4: // WAREHOUSE_ID
19911
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19912
              this.warehouseId = iprot.readI64();
19913
              setWarehouseIdIsSet(true);
19914
            } else { 
19915
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19916
            }
19917
            break;
19918
          default:
19919
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19920
        }
19921
        iprot.readFieldEnd();
19922
      }
19923
      iprot.readStructEnd();
19924
      validate();
19925
    }
19926
 
19927
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19928
      validate();
19929
 
19930
      oprot.writeStructBegin(STRUCT_DESC);
19931
      if (this.itemKey != null) {
19932
        oprot.writeFieldBegin(ITEM_KEY_FIELD_DESC);
19933
        oprot.writeString(this.itemKey);
19934
        oprot.writeFieldEnd();
19935
      }
19936
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
19937
      oprot.writeI64(this.vendorId);
19938
      oprot.writeFieldEnd();
19939
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
19940
      oprot.writeI64(this.quantity);
19941
      oprot.writeFieldEnd();
19942
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
19943
      oprot.writeI64(this.warehouseId);
19944
      oprot.writeFieldEnd();
19945
      oprot.writeFieldStop();
19946
      oprot.writeStructEnd();
19947
    }
19948
 
19949
    @Override
19950
    public String toString() {
19951
      StringBuilder sb = new StringBuilder("resetAvailability_args(");
19952
      boolean first = true;
19953
 
19954
      sb.append("itemKey:");
19955
      if (this.itemKey == null) {
19956
        sb.append("null");
19957
      } else {
19958
        sb.append(this.itemKey);
19959
      }
19960
      first = false;
19961
      if (!first) sb.append(", ");
19962
      sb.append("vendorId:");
19963
      sb.append(this.vendorId);
19964
      first = false;
19965
      if (!first) sb.append(", ");
19966
      sb.append("quantity:");
19967
      sb.append(this.quantity);
19968
      first = false;
19969
      if (!first) sb.append(", ");
19970
      sb.append("warehouseId:");
19971
      sb.append(this.warehouseId);
19972
      first = false;
19973
      sb.append(")");
19974
      return sb.toString();
19975
    }
19976
 
19977
    public void validate() throws org.apache.thrift.TException {
19978
      // check for required fields
19979
    }
19980
 
19981
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19982
      try {
19983
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19984
      } catch (org.apache.thrift.TException te) {
19985
        throw new java.io.IOException(te);
19986
      }
19987
    }
19988
 
19989
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19990
      try {
19991
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
19992
        __isset_bit_vector = new BitSet(1);
19993
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19994
      } catch (org.apache.thrift.TException te) {
19995
        throw new java.io.IOException(te);
19996
      }
19997
    }
19998
 
19999
  }
20000
 
20001
  public static class resetAvailability_result implements org.apache.thrift.TBase<resetAvailability_result, resetAvailability_result._Fields>, java.io.Serializable, Cloneable   {
20002
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailability_result");
20003
 
20004
    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);
20005
 
20006
    private InventoryServiceException cex; // required
20007
 
20008
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20009
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20010
      CEX((short)1, "cex");
20011
 
20012
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20013
 
20014
      static {
20015
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20016
          byName.put(field.getFieldName(), field);
20017
        }
20018
      }
20019
 
20020
      /**
20021
       * Find the _Fields constant that matches fieldId, or null if its not found.
20022
       */
20023
      public static _Fields findByThriftId(int fieldId) {
20024
        switch(fieldId) {
20025
          case 1: // CEX
20026
            return CEX;
20027
          default:
20028
            return null;
20029
        }
20030
      }
20031
 
20032
      /**
20033
       * Find the _Fields constant that matches fieldId, throwing an exception
20034
       * if it is not found.
20035
       */
20036
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20037
        _Fields fields = findByThriftId(fieldId);
20038
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20039
        return fields;
20040
      }
20041
 
20042
      /**
20043
       * Find the _Fields constant that matches name, or null if its not found.
20044
       */
20045
      public static _Fields findByName(String name) {
20046
        return byName.get(name);
20047
      }
20048
 
20049
      private final short _thriftId;
20050
      private final String _fieldName;
20051
 
20052
      _Fields(short thriftId, String fieldName) {
20053
        _thriftId = thriftId;
20054
        _fieldName = fieldName;
20055
      }
20056
 
20057
      public short getThriftFieldId() {
20058
        return _thriftId;
20059
      }
20060
 
20061
      public String getFieldName() {
20062
        return _fieldName;
20063
      }
20064
    }
20065
 
20066
    // isset id assignments
20067
 
20068
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20069
    static {
20070
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20071
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20072
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
20073
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20074
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailability_result.class, metaDataMap);
20075
    }
20076
 
20077
    public resetAvailability_result() {
20078
    }
20079
 
20080
    public resetAvailability_result(
20081
      InventoryServiceException cex)
20082
    {
20083
      this();
20084
      this.cex = cex;
20085
    }
20086
 
20087
    /**
20088
     * Performs a deep copy on <i>other</i>.
20089
     */
20090
    public resetAvailability_result(resetAvailability_result other) {
20091
      if (other.isSetCex()) {
20092
        this.cex = new InventoryServiceException(other.cex);
20093
      }
20094
    }
20095
 
20096
    public resetAvailability_result deepCopy() {
20097
      return new resetAvailability_result(this);
20098
    }
20099
 
20100
    @Override
20101
    public void clear() {
20102
      this.cex = null;
20103
    }
20104
 
20105
    public InventoryServiceException getCex() {
20106
      return this.cex;
20107
    }
20108
 
20109
    public void setCex(InventoryServiceException cex) {
20110
      this.cex = cex;
20111
    }
20112
 
20113
    public void unsetCex() {
20114
      this.cex = null;
20115
    }
20116
 
20117
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
20118
    public boolean isSetCex() {
20119
      return this.cex != null;
20120
    }
20121
 
20122
    public void setCexIsSet(boolean value) {
20123
      if (!value) {
20124
        this.cex = null;
20125
      }
20126
    }
20127
 
20128
    public void setFieldValue(_Fields field, Object value) {
20129
      switch (field) {
20130
      case CEX:
20131
        if (value == null) {
20132
          unsetCex();
20133
        } else {
20134
          setCex((InventoryServiceException)value);
20135
        }
20136
        break;
20137
 
20138
      }
20139
    }
20140
 
20141
    public Object getFieldValue(_Fields field) {
20142
      switch (field) {
20143
      case CEX:
20144
        return getCex();
20145
 
20146
      }
20147
      throw new IllegalStateException();
20148
    }
20149
 
20150
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20151
    public boolean isSet(_Fields field) {
20152
      if (field == null) {
20153
        throw new IllegalArgumentException();
20154
      }
20155
 
20156
      switch (field) {
20157
      case CEX:
20158
        return isSetCex();
20159
      }
20160
      throw new IllegalStateException();
20161
    }
20162
 
20163
    @Override
20164
    public boolean equals(Object that) {
20165
      if (that == null)
20166
        return false;
20167
      if (that instanceof resetAvailability_result)
20168
        return this.equals((resetAvailability_result)that);
20169
      return false;
20170
    }
20171
 
20172
    public boolean equals(resetAvailability_result that) {
20173
      if (that == null)
20174
        return false;
20175
 
20176
      boolean this_present_cex = true && this.isSetCex();
20177
      boolean that_present_cex = true && that.isSetCex();
20178
      if (this_present_cex || that_present_cex) {
20179
        if (!(this_present_cex && that_present_cex))
20180
          return false;
20181
        if (!this.cex.equals(that.cex))
20182
          return false;
20183
      }
20184
 
20185
      return true;
20186
    }
20187
 
20188
    @Override
20189
    public int hashCode() {
20190
      return 0;
20191
    }
20192
 
20193
    public int compareTo(resetAvailability_result other) {
20194
      if (!getClass().equals(other.getClass())) {
20195
        return getClass().getName().compareTo(other.getClass().getName());
20196
      }
20197
 
20198
      int lastComparison = 0;
20199
      resetAvailability_result typedOther = (resetAvailability_result)other;
20200
 
20201
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
20202
      if (lastComparison != 0) {
20203
        return lastComparison;
20204
      }
20205
      if (isSetCex()) {
20206
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
20207
        if (lastComparison != 0) {
20208
          return lastComparison;
20209
        }
20210
      }
20211
      return 0;
20212
    }
20213
 
20214
    public _Fields fieldForId(int fieldId) {
20215
      return _Fields.findByThriftId(fieldId);
20216
    }
20217
 
20218
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20219
      org.apache.thrift.protocol.TField field;
20220
      iprot.readStructBegin();
20221
      while (true)
20222
      {
20223
        field = iprot.readFieldBegin();
20224
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20225
          break;
20226
        }
20227
        switch (field.id) {
20228
          case 1: // CEX
20229
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
20230
              this.cex = new InventoryServiceException();
20231
              this.cex.read(iprot);
20232
            } else { 
20233
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20234
            }
20235
            break;
20236
          default:
20237
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20238
        }
20239
        iprot.readFieldEnd();
20240
      }
20241
      iprot.readStructEnd();
20242
      validate();
20243
    }
20244
 
20245
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20246
      oprot.writeStructBegin(STRUCT_DESC);
20247
 
20248
      if (this.isSetCex()) {
20249
        oprot.writeFieldBegin(CEX_FIELD_DESC);
20250
        this.cex.write(oprot);
20251
        oprot.writeFieldEnd();
20252
      }
20253
      oprot.writeFieldStop();
20254
      oprot.writeStructEnd();
20255
    }
20256
 
20257
    @Override
20258
    public String toString() {
20259
      StringBuilder sb = new StringBuilder("resetAvailability_result(");
20260
      boolean first = true;
20261
 
20262
      sb.append("cex:");
20263
      if (this.cex == null) {
20264
        sb.append("null");
20265
      } else {
20266
        sb.append(this.cex);
20267
      }
20268
      first = false;
20269
      sb.append(")");
20270
      return sb.toString();
20271
    }
20272
 
20273
    public void validate() throws org.apache.thrift.TException {
20274
      // check for required fields
20275
    }
20276
 
20277
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20278
      try {
20279
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20280
      } catch (org.apache.thrift.TException te) {
20281
        throw new java.io.IOException(te);
20282
      }
20283
    }
20284
 
20285
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20286
      try {
20287
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20288
      } catch (org.apache.thrift.TException te) {
20289
        throw new java.io.IOException(te);
20290
      }
20291
    }
20292
 
20293
  }
20294
 
20295
  public static class resetAvailabilityForWarehouse_args implements org.apache.thrift.TBase<resetAvailabilityForWarehouse_args, resetAvailabilityForWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
20296
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailabilityForWarehouse_args");
20297
 
20298
    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);
20299
 
20300
    private long warehouseId; // required
20301
 
20302
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20303
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20304
      WAREHOUSE_ID((short)1, "warehouseId");
20305
 
20306
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20307
 
20308
      static {
20309
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20310
          byName.put(field.getFieldName(), field);
20311
        }
20312
      }
20313
 
20314
      /**
20315
       * Find the _Fields constant that matches fieldId, or null if its not found.
20316
       */
20317
      public static _Fields findByThriftId(int fieldId) {
20318
        switch(fieldId) {
20319
          case 1: // WAREHOUSE_ID
20320
            return WAREHOUSE_ID;
20321
          default:
20322
            return null;
20323
        }
20324
      }
20325
 
20326
      /**
20327
       * Find the _Fields constant that matches fieldId, throwing an exception
20328
       * if it is not found.
20329
       */
20330
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20331
        _Fields fields = findByThriftId(fieldId);
20332
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20333
        return fields;
20334
      }
20335
 
20336
      /**
20337
       * Find the _Fields constant that matches name, or null if its not found.
20338
       */
20339
      public static _Fields findByName(String name) {
20340
        return byName.get(name);
20341
      }
20342
 
20343
      private final short _thriftId;
20344
      private final String _fieldName;
20345
 
20346
      _Fields(short thriftId, String fieldName) {
20347
        _thriftId = thriftId;
20348
        _fieldName = fieldName;
20349
      }
20350
 
20351
      public short getThriftFieldId() {
20352
        return _thriftId;
20353
      }
20354
 
20355
      public String getFieldName() {
20356
        return _fieldName;
20357
      }
20358
    }
20359
 
20360
    // isset id assignments
20361
    private static final int __WAREHOUSEID_ISSET_ID = 0;
20362
    private BitSet __isset_bit_vector = new BitSet(1);
20363
 
20364
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20365
    static {
20366
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20367
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20368
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20369
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20370
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailabilityForWarehouse_args.class, metaDataMap);
20371
    }
20372
 
20373
    public resetAvailabilityForWarehouse_args() {
20374
    }
20375
 
20376
    public resetAvailabilityForWarehouse_args(
20377
      long warehouseId)
20378
    {
20379
      this();
20380
      this.warehouseId = warehouseId;
20381
      setWarehouseIdIsSet(true);
20382
    }
20383
 
20384
    /**
20385
     * Performs a deep copy on <i>other</i>.
20386
     */
20387
    public resetAvailabilityForWarehouse_args(resetAvailabilityForWarehouse_args other) {
20388
      __isset_bit_vector.clear();
20389
      __isset_bit_vector.or(other.__isset_bit_vector);
20390
      this.warehouseId = other.warehouseId;
20391
    }
20392
 
20393
    public resetAvailabilityForWarehouse_args deepCopy() {
20394
      return new resetAvailabilityForWarehouse_args(this);
20395
    }
20396
 
20397
    @Override
20398
    public void clear() {
20399
      setWarehouseIdIsSet(false);
20400
      this.warehouseId = 0;
20401
    }
20402
 
20403
    public long getWarehouseId() {
20404
      return this.warehouseId;
20405
    }
20406
 
20407
    public void setWarehouseId(long warehouseId) {
20408
      this.warehouseId = warehouseId;
20409
      setWarehouseIdIsSet(true);
20410
    }
20411
 
20412
    public void unsetWarehouseId() {
20413
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
20414
    }
20415
 
20416
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
20417
    public boolean isSetWarehouseId() {
20418
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
20419
    }
20420
 
20421
    public void setWarehouseIdIsSet(boolean value) {
20422
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
20423
    }
20424
 
20425
    public void setFieldValue(_Fields field, Object value) {
20426
      switch (field) {
20427
      case WAREHOUSE_ID:
20428
        if (value == null) {
20429
          unsetWarehouseId();
20430
        } else {
20431
          setWarehouseId((Long)value);
20432
        }
20433
        break;
20434
 
20435
      }
20436
    }
20437
 
20438
    public Object getFieldValue(_Fields field) {
20439
      switch (field) {
20440
      case WAREHOUSE_ID:
20441
        return Long.valueOf(getWarehouseId());
20442
 
20443
      }
20444
      throw new IllegalStateException();
20445
    }
20446
 
20447
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20448
    public boolean isSet(_Fields field) {
20449
      if (field == null) {
20450
        throw new IllegalArgumentException();
20451
      }
20452
 
20453
      switch (field) {
20454
      case WAREHOUSE_ID:
20455
        return isSetWarehouseId();
20456
      }
20457
      throw new IllegalStateException();
20458
    }
20459
 
20460
    @Override
20461
    public boolean equals(Object that) {
20462
      if (that == null)
20463
        return false;
20464
      if (that instanceof resetAvailabilityForWarehouse_args)
20465
        return this.equals((resetAvailabilityForWarehouse_args)that);
20466
      return false;
20467
    }
20468
 
20469
    public boolean equals(resetAvailabilityForWarehouse_args that) {
20470
      if (that == null)
20471
        return false;
20472
 
20473
      boolean this_present_warehouseId = true;
20474
      boolean that_present_warehouseId = true;
20475
      if (this_present_warehouseId || that_present_warehouseId) {
20476
        if (!(this_present_warehouseId && that_present_warehouseId))
20477
          return false;
20478
        if (this.warehouseId != that.warehouseId)
20479
          return false;
20480
      }
20481
 
20482
      return true;
20483
    }
20484
 
20485
    @Override
20486
    public int hashCode() {
20487
      return 0;
20488
    }
20489
 
20490
    public int compareTo(resetAvailabilityForWarehouse_args other) {
20491
      if (!getClass().equals(other.getClass())) {
20492
        return getClass().getName().compareTo(other.getClass().getName());
20493
      }
20494
 
20495
      int lastComparison = 0;
20496
      resetAvailabilityForWarehouse_args typedOther = (resetAvailabilityForWarehouse_args)other;
20497
 
20498
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
20499
      if (lastComparison != 0) {
20500
        return lastComparison;
20501
      }
20502
      if (isSetWarehouseId()) {
20503
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
20504
        if (lastComparison != 0) {
20505
          return lastComparison;
20506
        }
20507
      }
20508
      return 0;
20509
    }
20510
 
20511
    public _Fields fieldForId(int fieldId) {
20512
      return _Fields.findByThriftId(fieldId);
20513
    }
20514
 
20515
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20516
      org.apache.thrift.protocol.TField field;
20517
      iprot.readStructBegin();
20518
      while (true)
20519
      {
20520
        field = iprot.readFieldBegin();
20521
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20522
          break;
20523
        }
20524
        switch (field.id) {
20525
          case 1: // WAREHOUSE_ID
20526
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20527
              this.warehouseId = iprot.readI64();
20528
              setWarehouseIdIsSet(true);
20529
            } else { 
20530
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20531
            }
20532
            break;
20533
          default:
20534
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20535
        }
20536
        iprot.readFieldEnd();
20537
      }
20538
      iprot.readStructEnd();
20539
      validate();
20540
    }
20541
 
20542
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20543
      validate();
20544
 
20545
      oprot.writeStructBegin(STRUCT_DESC);
20546
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
20547
      oprot.writeI64(this.warehouseId);
20548
      oprot.writeFieldEnd();
20549
      oprot.writeFieldStop();
20550
      oprot.writeStructEnd();
20551
    }
20552
 
20553
    @Override
20554
    public String toString() {
20555
      StringBuilder sb = new StringBuilder("resetAvailabilityForWarehouse_args(");
20556
      boolean first = true;
20557
 
20558
      sb.append("warehouseId:");
20559
      sb.append(this.warehouseId);
20560
      first = false;
20561
      sb.append(")");
20562
      return sb.toString();
20563
    }
20564
 
20565
    public void validate() throws org.apache.thrift.TException {
20566
      // check for required fields
20567
    }
20568
 
20569
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20570
      try {
20571
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20572
      } catch (org.apache.thrift.TException te) {
20573
        throw new java.io.IOException(te);
20574
      }
20575
    }
20576
 
20577
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20578
      try {
20579
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
20580
        __isset_bit_vector = new BitSet(1);
20581
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20582
      } catch (org.apache.thrift.TException te) {
20583
        throw new java.io.IOException(te);
20584
      }
20585
    }
20586
 
20587
  }
20588
 
20589
  public static class resetAvailabilityForWarehouse_result implements org.apache.thrift.TBase<resetAvailabilityForWarehouse_result, resetAvailabilityForWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
20590
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailabilityForWarehouse_result");
20591
 
20592
    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);
20593
 
20594
    private InventoryServiceException cex; // required
20595
 
20596
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20597
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20598
      CEX((short)1, "cex");
20599
 
20600
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20601
 
20602
      static {
20603
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20604
          byName.put(field.getFieldName(), field);
20605
        }
20606
      }
20607
 
20608
      /**
20609
       * Find the _Fields constant that matches fieldId, or null if its not found.
20610
       */
20611
      public static _Fields findByThriftId(int fieldId) {
20612
        switch(fieldId) {
20613
          case 1: // CEX
20614
            return CEX;
20615
          default:
20616
            return null;
20617
        }
20618
      }
20619
 
20620
      /**
20621
       * Find the _Fields constant that matches fieldId, throwing an exception
20622
       * if it is not found.
20623
       */
20624
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20625
        _Fields fields = findByThriftId(fieldId);
20626
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20627
        return fields;
20628
      }
20629
 
20630
      /**
20631
       * Find the _Fields constant that matches name, or null if its not found.
20632
       */
20633
      public static _Fields findByName(String name) {
20634
        return byName.get(name);
20635
      }
20636
 
20637
      private final short _thriftId;
20638
      private final String _fieldName;
20639
 
20640
      _Fields(short thriftId, String fieldName) {
20641
        _thriftId = thriftId;
20642
        _fieldName = fieldName;
20643
      }
20644
 
20645
      public short getThriftFieldId() {
20646
        return _thriftId;
20647
      }
20648
 
20649
      public String getFieldName() {
20650
        return _fieldName;
20651
      }
20652
    }
20653
 
20654
    // isset id assignments
20655
 
20656
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20657
    static {
20658
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20659
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20660
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
20661
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20662
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailabilityForWarehouse_result.class, metaDataMap);
20663
    }
20664
 
20665
    public resetAvailabilityForWarehouse_result() {
20666
    }
20667
 
20668
    public resetAvailabilityForWarehouse_result(
20669
      InventoryServiceException cex)
20670
    {
20671
      this();
20672
      this.cex = cex;
20673
    }
20674
 
20675
    /**
20676
     * Performs a deep copy on <i>other</i>.
20677
     */
20678
    public resetAvailabilityForWarehouse_result(resetAvailabilityForWarehouse_result other) {
20679
      if (other.isSetCex()) {
20680
        this.cex = new InventoryServiceException(other.cex);
20681
      }
20682
    }
20683
 
20684
    public resetAvailabilityForWarehouse_result deepCopy() {
20685
      return new resetAvailabilityForWarehouse_result(this);
20686
    }
20687
 
20688
    @Override
20689
    public void clear() {
20690
      this.cex = null;
20691
    }
20692
 
20693
    public InventoryServiceException getCex() {
20694
      return this.cex;
20695
    }
20696
 
20697
    public void setCex(InventoryServiceException cex) {
20698
      this.cex = cex;
20699
    }
20700
 
20701
    public void unsetCex() {
20702
      this.cex = null;
20703
    }
20704
 
20705
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
20706
    public boolean isSetCex() {
20707
      return this.cex != null;
20708
    }
20709
 
20710
    public void setCexIsSet(boolean value) {
20711
      if (!value) {
20712
        this.cex = null;
20713
      }
20714
    }
20715
 
20716
    public void setFieldValue(_Fields field, Object value) {
20717
      switch (field) {
20718
      case CEX:
20719
        if (value == null) {
20720
          unsetCex();
20721
        } else {
20722
          setCex((InventoryServiceException)value);
20723
        }
20724
        break;
20725
 
20726
      }
20727
    }
20728
 
20729
    public Object getFieldValue(_Fields field) {
20730
      switch (field) {
20731
      case CEX:
20732
        return getCex();
20733
 
20734
      }
20735
      throw new IllegalStateException();
20736
    }
20737
 
20738
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20739
    public boolean isSet(_Fields field) {
20740
      if (field == null) {
20741
        throw new IllegalArgumentException();
20742
      }
20743
 
20744
      switch (field) {
20745
      case CEX:
20746
        return isSetCex();
20747
      }
20748
      throw new IllegalStateException();
20749
    }
20750
 
20751
    @Override
20752
    public boolean equals(Object that) {
20753
      if (that == null)
20754
        return false;
20755
      if (that instanceof resetAvailabilityForWarehouse_result)
20756
        return this.equals((resetAvailabilityForWarehouse_result)that);
20757
      return false;
20758
    }
20759
 
20760
    public boolean equals(resetAvailabilityForWarehouse_result that) {
20761
      if (that == null)
20762
        return false;
20763
 
20764
      boolean this_present_cex = true && this.isSetCex();
20765
      boolean that_present_cex = true && that.isSetCex();
20766
      if (this_present_cex || that_present_cex) {
20767
        if (!(this_present_cex && that_present_cex))
20768
          return false;
20769
        if (!this.cex.equals(that.cex))
20770
          return false;
20771
      }
20772
 
20773
      return true;
20774
    }
20775
 
20776
    @Override
20777
    public int hashCode() {
20778
      return 0;
20779
    }
20780
 
20781
    public int compareTo(resetAvailabilityForWarehouse_result other) {
20782
      if (!getClass().equals(other.getClass())) {
20783
        return getClass().getName().compareTo(other.getClass().getName());
20784
      }
20785
 
20786
      int lastComparison = 0;
20787
      resetAvailabilityForWarehouse_result typedOther = (resetAvailabilityForWarehouse_result)other;
20788
 
20789
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
20790
      if (lastComparison != 0) {
20791
        return lastComparison;
20792
      }
20793
      if (isSetCex()) {
20794
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
20795
        if (lastComparison != 0) {
20796
          return lastComparison;
20797
        }
20798
      }
20799
      return 0;
20800
    }
20801
 
20802
    public _Fields fieldForId(int fieldId) {
20803
      return _Fields.findByThriftId(fieldId);
20804
    }
20805
 
20806
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20807
      org.apache.thrift.protocol.TField field;
20808
      iprot.readStructBegin();
20809
      while (true)
20810
      {
20811
        field = iprot.readFieldBegin();
20812
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20813
          break;
20814
        }
20815
        switch (field.id) {
20816
          case 1: // CEX
20817
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
20818
              this.cex = new InventoryServiceException();
20819
              this.cex.read(iprot);
20820
            } else { 
20821
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20822
            }
20823
            break;
20824
          default:
20825
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20826
        }
20827
        iprot.readFieldEnd();
20828
      }
20829
      iprot.readStructEnd();
20830
      validate();
20831
    }
20832
 
20833
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20834
      oprot.writeStructBegin(STRUCT_DESC);
20835
 
20836
      if (this.isSetCex()) {
20837
        oprot.writeFieldBegin(CEX_FIELD_DESC);
20838
        this.cex.write(oprot);
20839
        oprot.writeFieldEnd();
20840
      }
20841
      oprot.writeFieldStop();
20842
      oprot.writeStructEnd();
20843
    }
20844
 
20845
    @Override
20846
    public String toString() {
20847
      StringBuilder sb = new StringBuilder("resetAvailabilityForWarehouse_result(");
20848
      boolean first = true;
20849
 
20850
      sb.append("cex:");
20851
      if (this.cex == null) {
20852
        sb.append("null");
20853
      } else {
20854
        sb.append(this.cex);
20855
      }
20856
      first = false;
20857
      sb.append(")");
20858
      return sb.toString();
20859
    }
20860
 
20861
    public void validate() throws org.apache.thrift.TException {
20862
      // check for required fields
20863
    }
20864
 
20865
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20866
      try {
20867
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20868
      } catch (org.apache.thrift.TException te) {
20869
        throw new java.io.IOException(te);
20870
      }
20871
    }
20872
 
20873
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20874
      try {
20875
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20876
      } catch (org.apache.thrift.TException te) {
20877
        throw new java.io.IOException(te);
20878
      }
20879
    }
20880
 
20881
  }
20882
 
20883
  public static class getItemKeysToBeProcessed_args implements org.apache.thrift.TBase<getItemKeysToBeProcessed_args, getItemKeysToBeProcessed_args._Fields>, java.io.Serializable, Cloneable   {
20884
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemKeysToBeProcessed_args");
20885
 
20886
    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);
20887
 
20888
    private long warehouseId; // required
20889
 
20890
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20891
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20892
      WAREHOUSE_ID((short)1, "warehouseId");
20893
 
20894
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20895
 
20896
      static {
20897
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20898
          byName.put(field.getFieldName(), field);
20899
        }
20900
      }
20901
 
20902
      /**
20903
       * Find the _Fields constant that matches fieldId, or null if its not found.
20904
       */
20905
      public static _Fields findByThriftId(int fieldId) {
20906
        switch(fieldId) {
20907
          case 1: // WAREHOUSE_ID
20908
            return WAREHOUSE_ID;
20909
          default:
20910
            return null;
20911
        }
20912
      }
20913
 
20914
      /**
20915
       * Find the _Fields constant that matches fieldId, throwing an exception
20916
       * if it is not found.
20917
       */
20918
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20919
        _Fields fields = findByThriftId(fieldId);
20920
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20921
        return fields;
20922
      }
20923
 
20924
      /**
20925
       * Find the _Fields constant that matches name, or null if its not found.
20926
       */
20927
      public static _Fields findByName(String name) {
20928
        return byName.get(name);
20929
      }
20930
 
20931
      private final short _thriftId;
20932
      private final String _fieldName;
20933
 
20934
      _Fields(short thriftId, String fieldName) {
20935
        _thriftId = thriftId;
20936
        _fieldName = fieldName;
20937
      }
20938
 
20939
      public short getThriftFieldId() {
20940
        return _thriftId;
20941
      }
20942
 
20943
      public String getFieldName() {
20944
        return _fieldName;
20945
      }
20946
    }
20947
 
20948
    // isset id assignments
20949
    private static final int __WAREHOUSEID_ISSET_ID = 0;
20950
    private BitSet __isset_bit_vector = new BitSet(1);
20951
 
20952
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20953
    static {
20954
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20955
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20956
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20957
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20958
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemKeysToBeProcessed_args.class, metaDataMap);
20959
    }
20960
 
20961
    public getItemKeysToBeProcessed_args() {
20962
    }
20963
 
20964
    public getItemKeysToBeProcessed_args(
20965
      long warehouseId)
20966
    {
20967
      this();
20968
      this.warehouseId = warehouseId;
20969
      setWarehouseIdIsSet(true);
20970
    }
20971
 
20972
    /**
20973
     * Performs a deep copy on <i>other</i>.
20974
     */
20975
    public getItemKeysToBeProcessed_args(getItemKeysToBeProcessed_args other) {
20976
      __isset_bit_vector.clear();
20977
      __isset_bit_vector.or(other.__isset_bit_vector);
20978
      this.warehouseId = other.warehouseId;
20979
    }
20980
 
20981
    public getItemKeysToBeProcessed_args deepCopy() {
20982
      return new getItemKeysToBeProcessed_args(this);
20983
    }
20984
 
20985
    @Override
20986
    public void clear() {
20987
      setWarehouseIdIsSet(false);
20988
      this.warehouseId = 0;
20989
    }
20990
 
20991
    public long getWarehouseId() {
20992
      return this.warehouseId;
20993
    }
20994
 
20995
    public void setWarehouseId(long warehouseId) {
20996
      this.warehouseId = warehouseId;
20997
      setWarehouseIdIsSet(true);
20998
    }
20999
 
21000
    public void unsetWarehouseId() {
21001
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
21002
    }
21003
 
21004
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
21005
    public boolean isSetWarehouseId() {
21006
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
21007
    }
21008
 
21009
    public void setWarehouseIdIsSet(boolean value) {
21010
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
21011
    }
21012
 
21013
    public void setFieldValue(_Fields field, Object value) {
21014
      switch (field) {
21015
      case WAREHOUSE_ID:
21016
        if (value == null) {
21017
          unsetWarehouseId();
21018
        } else {
21019
          setWarehouseId((Long)value);
21020
        }
21021
        break;
21022
 
21023
      }
21024
    }
21025
 
21026
    public Object getFieldValue(_Fields field) {
21027
      switch (field) {
21028
      case WAREHOUSE_ID:
21029
        return Long.valueOf(getWarehouseId());
21030
 
21031
      }
21032
      throw new IllegalStateException();
21033
    }
21034
 
21035
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21036
    public boolean isSet(_Fields field) {
21037
      if (field == null) {
21038
        throw new IllegalArgumentException();
21039
      }
21040
 
21041
      switch (field) {
21042
      case WAREHOUSE_ID:
21043
        return isSetWarehouseId();
21044
      }
21045
      throw new IllegalStateException();
21046
    }
21047
 
21048
    @Override
21049
    public boolean equals(Object that) {
21050
      if (that == null)
21051
        return false;
21052
      if (that instanceof getItemKeysToBeProcessed_args)
21053
        return this.equals((getItemKeysToBeProcessed_args)that);
21054
      return false;
21055
    }
21056
 
21057
    public boolean equals(getItemKeysToBeProcessed_args that) {
21058
      if (that == null)
21059
        return false;
21060
 
21061
      boolean this_present_warehouseId = true;
21062
      boolean that_present_warehouseId = true;
21063
      if (this_present_warehouseId || that_present_warehouseId) {
21064
        if (!(this_present_warehouseId && that_present_warehouseId))
21065
          return false;
21066
        if (this.warehouseId != that.warehouseId)
21067
          return false;
21068
      }
21069
 
21070
      return true;
21071
    }
21072
 
21073
    @Override
21074
    public int hashCode() {
21075
      return 0;
21076
    }
21077
 
21078
    public int compareTo(getItemKeysToBeProcessed_args other) {
21079
      if (!getClass().equals(other.getClass())) {
21080
        return getClass().getName().compareTo(other.getClass().getName());
21081
      }
21082
 
21083
      int lastComparison = 0;
21084
      getItemKeysToBeProcessed_args typedOther = (getItemKeysToBeProcessed_args)other;
21085
 
21086
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
21087
      if (lastComparison != 0) {
21088
        return lastComparison;
21089
      }
21090
      if (isSetWarehouseId()) {
21091
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
21092
        if (lastComparison != 0) {
21093
          return lastComparison;
21094
        }
21095
      }
21096
      return 0;
21097
    }
21098
 
21099
    public _Fields fieldForId(int fieldId) {
21100
      return _Fields.findByThriftId(fieldId);
21101
    }
21102
 
21103
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21104
      org.apache.thrift.protocol.TField field;
21105
      iprot.readStructBegin();
21106
      while (true)
21107
      {
21108
        field = iprot.readFieldBegin();
21109
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21110
          break;
21111
        }
21112
        switch (field.id) {
21113
          case 1: // WAREHOUSE_ID
21114
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21115
              this.warehouseId = iprot.readI64();
21116
              setWarehouseIdIsSet(true);
21117
            } else { 
21118
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21119
            }
21120
            break;
21121
          default:
21122
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21123
        }
21124
        iprot.readFieldEnd();
21125
      }
21126
      iprot.readStructEnd();
21127
      validate();
21128
    }
21129
 
21130
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21131
      validate();
21132
 
21133
      oprot.writeStructBegin(STRUCT_DESC);
21134
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
21135
      oprot.writeI64(this.warehouseId);
21136
      oprot.writeFieldEnd();
21137
      oprot.writeFieldStop();
21138
      oprot.writeStructEnd();
21139
    }
21140
 
21141
    @Override
21142
    public String toString() {
21143
      StringBuilder sb = new StringBuilder("getItemKeysToBeProcessed_args(");
21144
      boolean first = true;
21145
 
21146
      sb.append("warehouseId:");
21147
      sb.append(this.warehouseId);
21148
      first = false;
21149
      sb.append(")");
21150
      return sb.toString();
21151
    }
21152
 
21153
    public void validate() throws org.apache.thrift.TException {
21154
      // check for required fields
21155
    }
21156
 
21157
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21158
      try {
21159
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21160
      } catch (org.apache.thrift.TException te) {
21161
        throw new java.io.IOException(te);
21162
      }
21163
    }
21164
 
21165
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21166
      try {
21167
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21168
      } catch (org.apache.thrift.TException te) {
21169
        throw new java.io.IOException(te);
21170
      }
21171
    }
21172
 
21173
  }
21174
 
21175
  public static class getItemKeysToBeProcessed_result implements org.apache.thrift.TBase<getItemKeysToBeProcessed_result, getItemKeysToBeProcessed_result._Fields>, java.io.Serializable, Cloneable   {
21176
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemKeysToBeProcessed_result");
21177
 
21178
    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);
21179
 
21180
    private List<String> success; // required
21181
 
21182
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21183
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21184
      SUCCESS((short)0, "success");
21185
 
21186
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21187
 
21188
      static {
21189
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21190
          byName.put(field.getFieldName(), field);
21191
        }
21192
      }
21193
 
21194
      /**
21195
       * Find the _Fields constant that matches fieldId, or null if its not found.
21196
       */
21197
      public static _Fields findByThriftId(int fieldId) {
21198
        switch(fieldId) {
21199
          case 0: // SUCCESS
21200
            return SUCCESS;
21201
          default:
21202
            return null;
21203
        }
21204
      }
21205
 
21206
      /**
21207
       * Find the _Fields constant that matches fieldId, throwing an exception
21208
       * if it is not found.
21209
       */
21210
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21211
        _Fields fields = findByThriftId(fieldId);
21212
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21213
        return fields;
21214
      }
21215
 
21216
      /**
21217
       * Find the _Fields constant that matches name, or null if its not found.
21218
       */
21219
      public static _Fields findByName(String name) {
21220
        return byName.get(name);
21221
      }
21222
 
21223
      private final short _thriftId;
21224
      private final String _fieldName;
21225
 
21226
      _Fields(short thriftId, String fieldName) {
21227
        _thriftId = thriftId;
21228
        _fieldName = fieldName;
21229
      }
21230
 
21231
      public short getThriftFieldId() {
21232
        return _thriftId;
21233
      }
21234
 
21235
      public String getFieldName() {
21236
        return _fieldName;
21237
      }
21238
    }
21239
 
21240
    // isset id assignments
21241
 
21242
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21243
    static {
21244
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21245
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21246
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
21247
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
21248
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21249
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemKeysToBeProcessed_result.class, metaDataMap);
21250
    }
21251
 
21252
    public getItemKeysToBeProcessed_result() {
21253
    }
21254
 
21255
    public getItemKeysToBeProcessed_result(
21256
      List<String> success)
21257
    {
21258
      this();
21259
      this.success = success;
21260
    }
21261
 
21262
    /**
21263
     * Performs a deep copy on <i>other</i>.
21264
     */
21265
    public getItemKeysToBeProcessed_result(getItemKeysToBeProcessed_result other) {
21266
      if (other.isSetSuccess()) {
21267
        List<String> __this__success = new ArrayList<String>();
21268
        for (String other_element : other.success) {
21269
          __this__success.add(other_element);
21270
        }
21271
        this.success = __this__success;
21272
      }
21273
    }
21274
 
21275
    public getItemKeysToBeProcessed_result deepCopy() {
21276
      return new getItemKeysToBeProcessed_result(this);
21277
    }
21278
 
21279
    @Override
21280
    public void clear() {
21281
      this.success = null;
21282
    }
21283
 
21284
    public int getSuccessSize() {
21285
      return (this.success == null) ? 0 : this.success.size();
21286
    }
21287
 
21288
    public java.util.Iterator<String> getSuccessIterator() {
21289
      return (this.success == null) ? null : this.success.iterator();
21290
    }
21291
 
21292
    public void addToSuccess(String elem) {
21293
      if (this.success == null) {
21294
        this.success = new ArrayList<String>();
21295
      }
21296
      this.success.add(elem);
21297
    }
21298
 
21299
    public List<String> getSuccess() {
21300
      return this.success;
21301
    }
21302
 
21303
    public void setSuccess(List<String> success) {
21304
      this.success = success;
21305
    }
21306
 
21307
    public void unsetSuccess() {
21308
      this.success = null;
21309
    }
21310
 
21311
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
21312
    public boolean isSetSuccess() {
21313
      return this.success != null;
21314
    }
21315
 
21316
    public void setSuccessIsSet(boolean value) {
21317
      if (!value) {
21318
        this.success = null;
21319
      }
21320
    }
21321
 
21322
    public void setFieldValue(_Fields field, Object value) {
21323
      switch (field) {
21324
      case SUCCESS:
21325
        if (value == null) {
21326
          unsetSuccess();
21327
        } else {
21328
          setSuccess((List<String>)value);
21329
        }
21330
        break;
21331
 
21332
      }
21333
    }
21334
 
21335
    public Object getFieldValue(_Fields field) {
21336
      switch (field) {
21337
      case SUCCESS:
21338
        return getSuccess();
21339
 
21340
      }
21341
      throw new IllegalStateException();
21342
    }
21343
 
21344
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21345
    public boolean isSet(_Fields field) {
21346
      if (field == null) {
21347
        throw new IllegalArgumentException();
21348
      }
21349
 
21350
      switch (field) {
21351
      case SUCCESS:
21352
        return isSetSuccess();
21353
      }
21354
      throw new IllegalStateException();
21355
    }
21356
 
21357
    @Override
21358
    public boolean equals(Object that) {
21359
      if (that == null)
21360
        return false;
21361
      if (that instanceof getItemKeysToBeProcessed_result)
21362
        return this.equals((getItemKeysToBeProcessed_result)that);
21363
      return false;
21364
    }
21365
 
21366
    public boolean equals(getItemKeysToBeProcessed_result that) {
21367
      if (that == null)
21368
        return false;
21369
 
21370
      boolean this_present_success = true && this.isSetSuccess();
21371
      boolean that_present_success = true && that.isSetSuccess();
21372
      if (this_present_success || that_present_success) {
21373
        if (!(this_present_success && that_present_success))
21374
          return false;
21375
        if (!this.success.equals(that.success))
21376
          return false;
21377
      }
21378
 
21379
      return true;
21380
    }
21381
 
21382
    @Override
21383
    public int hashCode() {
21384
      return 0;
21385
    }
21386
 
21387
    public int compareTo(getItemKeysToBeProcessed_result other) {
21388
      if (!getClass().equals(other.getClass())) {
21389
        return getClass().getName().compareTo(other.getClass().getName());
21390
      }
21391
 
21392
      int lastComparison = 0;
21393
      getItemKeysToBeProcessed_result typedOther = (getItemKeysToBeProcessed_result)other;
21394
 
21395
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
21396
      if (lastComparison != 0) {
21397
        return lastComparison;
21398
      }
21399
      if (isSetSuccess()) {
21400
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
21401
        if (lastComparison != 0) {
21402
          return lastComparison;
21403
        }
21404
      }
21405
      return 0;
21406
    }
21407
 
21408
    public _Fields fieldForId(int fieldId) {
21409
      return _Fields.findByThriftId(fieldId);
21410
    }
21411
 
21412
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21413
      org.apache.thrift.protocol.TField field;
21414
      iprot.readStructBegin();
21415
      while (true)
21416
      {
21417
        field = iprot.readFieldBegin();
21418
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21419
          break;
21420
        }
21421
        switch (field.id) {
21422
          case 0: // SUCCESS
21423
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
21424
              {
21425
                org.apache.thrift.protocol.TList _list52 = iprot.readListBegin();
21426
                this.success = new ArrayList<String>(_list52.size);
21427
                for (int _i53 = 0; _i53 < _list52.size; ++_i53)
21428
                {
21429
                  String _elem54; // required
21430
                  _elem54 = iprot.readString();
21431
                  this.success.add(_elem54);
21432
                }
21433
                iprot.readListEnd();
21434
              }
21435
            } else { 
21436
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21437
            }
21438
            break;
21439
          default:
21440
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21441
        }
21442
        iprot.readFieldEnd();
21443
      }
21444
      iprot.readStructEnd();
21445
      validate();
21446
    }
21447
 
21448
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21449
      oprot.writeStructBegin(STRUCT_DESC);
21450
 
21451
      if (this.isSetSuccess()) {
21452
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
21453
        {
21454
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, this.success.size()));
21455
          for (String _iter55 : this.success)
21456
          {
21457
            oprot.writeString(_iter55);
21458
          }
21459
          oprot.writeListEnd();
21460
        }
21461
        oprot.writeFieldEnd();
21462
      }
21463
      oprot.writeFieldStop();
21464
      oprot.writeStructEnd();
21465
    }
21466
 
21467
    @Override
21468
    public String toString() {
21469
      StringBuilder sb = new StringBuilder("getItemKeysToBeProcessed_result(");
21470
      boolean first = true;
21471
 
21472
      sb.append("success:");
21473
      if (this.success == null) {
21474
        sb.append("null");
21475
      } else {
21476
        sb.append(this.success);
21477
      }
21478
      first = false;
21479
      sb.append(")");
21480
      return sb.toString();
21481
    }
21482
 
21483
    public void validate() throws org.apache.thrift.TException {
21484
      // check for required fields
21485
    }
21486
 
21487
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21488
      try {
21489
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21490
      } catch (org.apache.thrift.TException te) {
21491
        throw new java.io.IOException(te);
21492
      }
21493
    }
21494
 
21495
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21496
      try {
21497
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21498
      } catch (org.apache.thrift.TException te) {
21499
        throw new java.io.IOException(te);
21500
      }
21501
    }
21502
 
21503
  }
21504
 
21505
  public static class markMissedInventoryUpdatesAsProcessed_args implements org.apache.thrift.TBase<markMissedInventoryUpdatesAsProcessed_args, markMissedInventoryUpdatesAsProcessed_args._Fields>, java.io.Serializable, Cloneable   {
21506
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markMissedInventoryUpdatesAsProcessed_args");
21507
 
21508
    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);
21509
    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);
21510
 
21511
    private String itemKey; // required
21512
    private long warehouseId; // required
21513
 
21514
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21515
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21516
      ITEM_KEY((short)1, "itemKey"),
21517
      WAREHOUSE_ID((short)2, "warehouseId");
21518
 
21519
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21520
 
21521
      static {
21522
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21523
          byName.put(field.getFieldName(), field);
21524
        }
21525
      }
21526
 
21527
      /**
21528
       * Find the _Fields constant that matches fieldId, or null if its not found.
21529
       */
21530
      public static _Fields findByThriftId(int fieldId) {
21531
        switch(fieldId) {
21532
          case 1: // ITEM_KEY
21533
            return ITEM_KEY;
21534
          case 2: // WAREHOUSE_ID
21535
            return WAREHOUSE_ID;
21536
          default:
21537
            return null;
21538
        }
21539
      }
21540
 
21541
      /**
21542
       * Find the _Fields constant that matches fieldId, throwing an exception
21543
       * if it is not found.
21544
       */
21545
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21546
        _Fields fields = findByThriftId(fieldId);
21547
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21548
        return fields;
21549
      }
21550
 
21551
      /**
21552
       * Find the _Fields constant that matches name, or null if its not found.
21553
       */
21554
      public static _Fields findByName(String name) {
21555
        return byName.get(name);
21556
      }
21557
 
21558
      private final short _thriftId;
21559
      private final String _fieldName;
21560
 
21561
      _Fields(short thriftId, String fieldName) {
21562
        _thriftId = thriftId;
21563
        _fieldName = fieldName;
21564
      }
21565
 
21566
      public short getThriftFieldId() {
21567
        return _thriftId;
21568
      }
21569
 
21570
      public String getFieldName() {
21571
        return _fieldName;
21572
      }
21573
    }
21574
 
21575
    // isset id assignments
21576
    private static final int __WAREHOUSEID_ISSET_ID = 0;
21577
    private BitSet __isset_bit_vector = new BitSet(1);
21578
 
21579
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21580
    static {
21581
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21582
      tmpMap.put(_Fields.ITEM_KEY, new org.apache.thrift.meta_data.FieldMetaData("itemKey", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21583
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
21584
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21585
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21586
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21587
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markMissedInventoryUpdatesAsProcessed_args.class, metaDataMap);
21588
    }
21589
 
21590
    public markMissedInventoryUpdatesAsProcessed_args() {
21591
    }
21592
 
21593
    public markMissedInventoryUpdatesAsProcessed_args(
21594
      String itemKey,
21595
      long warehouseId)
21596
    {
21597
      this();
21598
      this.itemKey = itemKey;
21599
      this.warehouseId = warehouseId;
21600
      setWarehouseIdIsSet(true);
21601
    }
21602
 
21603
    /**
21604
     * Performs a deep copy on <i>other</i>.
21605
     */
21606
    public markMissedInventoryUpdatesAsProcessed_args(markMissedInventoryUpdatesAsProcessed_args other) {
21607
      __isset_bit_vector.clear();
21608
      __isset_bit_vector.or(other.__isset_bit_vector);
21609
      if (other.isSetItemKey()) {
21610
        this.itemKey = other.itemKey;
21611
      }
21612
      this.warehouseId = other.warehouseId;
21613
    }
21614
 
21615
    public markMissedInventoryUpdatesAsProcessed_args deepCopy() {
21616
      return new markMissedInventoryUpdatesAsProcessed_args(this);
21617
    }
21618
 
21619
    @Override
21620
    public void clear() {
21621
      this.itemKey = null;
21622
      setWarehouseIdIsSet(false);
21623
      this.warehouseId = 0;
21624
    }
21625
 
21626
    public String getItemKey() {
21627
      return this.itemKey;
21628
    }
21629
 
21630
    public void setItemKey(String itemKey) {
21631
      this.itemKey = itemKey;
21632
    }
21633
 
21634
    public void unsetItemKey() {
21635
      this.itemKey = null;
21636
    }
21637
 
21638
    /** Returns true if field itemKey is set (has been assigned a value) and false otherwise */
21639
    public boolean isSetItemKey() {
21640
      return this.itemKey != null;
21641
    }
21642
 
21643
    public void setItemKeyIsSet(boolean value) {
21644
      if (!value) {
21645
        this.itemKey = null;
21646
      }
21647
    }
21648
 
21649
    public long getWarehouseId() {
21650
      return this.warehouseId;
21651
    }
21652
 
21653
    public void setWarehouseId(long warehouseId) {
21654
      this.warehouseId = warehouseId;
21655
      setWarehouseIdIsSet(true);
21656
    }
21657
 
21658
    public void unsetWarehouseId() {
21659
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
21660
    }
21661
 
21662
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
21663
    public boolean isSetWarehouseId() {
21664
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
21665
    }
21666
 
21667
    public void setWarehouseIdIsSet(boolean value) {
21668
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
21669
    }
21670
 
21671
    public void setFieldValue(_Fields field, Object value) {
21672
      switch (field) {
21673
      case ITEM_KEY:
21674
        if (value == null) {
21675
          unsetItemKey();
21676
        } else {
21677
          setItemKey((String)value);
21678
        }
21679
        break;
21680
 
21681
      case WAREHOUSE_ID:
21682
        if (value == null) {
21683
          unsetWarehouseId();
21684
        } else {
21685
          setWarehouseId((Long)value);
21686
        }
21687
        break;
21688
 
21689
      }
21690
    }
21691
 
21692
    public Object getFieldValue(_Fields field) {
21693
      switch (field) {
21694
      case ITEM_KEY:
21695
        return getItemKey();
21696
 
21697
      case WAREHOUSE_ID:
21698
        return Long.valueOf(getWarehouseId());
21699
 
21700
      }
21701
      throw new IllegalStateException();
21702
    }
21703
 
21704
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21705
    public boolean isSet(_Fields field) {
21706
      if (field == null) {
21707
        throw new IllegalArgumentException();
21708
      }
21709
 
21710
      switch (field) {
21711
      case ITEM_KEY:
21712
        return isSetItemKey();
21713
      case WAREHOUSE_ID:
21714
        return isSetWarehouseId();
21715
      }
21716
      throw new IllegalStateException();
21717
    }
21718
 
21719
    @Override
21720
    public boolean equals(Object that) {
21721
      if (that == null)
21722
        return false;
21723
      if (that instanceof markMissedInventoryUpdatesAsProcessed_args)
21724
        return this.equals((markMissedInventoryUpdatesAsProcessed_args)that);
21725
      return false;
21726
    }
21727
 
21728
    public boolean equals(markMissedInventoryUpdatesAsProcessed_args that) {
21729
      if (that == null)
21730
        return false;
21731
 
21732
      boolean this_present_itemKey = true && this.isSetItemKey();
21733
      boolean that_present_itemKey = true && that.isSetItemKey();
21734
      if (this_present_itemKey || that_present_itemKey) {
21735
        if (!(this_present_itemKey && that_present_itemKey))
21736
          return false;
21737
        if (!this.itemKey.equals(that.itemKey))
21738
          return false;
21739
      }
21740
 
21741
      boolean this_present_warehouseId = true;
21742
      boolean that_present_warehouseId = true;
21743
      if (this_present_warehouseId || that_present_warehouseId) {
21744
        if (!(this_present_warehouseId && that_present_warehouseId))
21745
          return false;
21746
        if (this.warehouseId != that.warehouseId)
21747
          return false;
21748
      }
21749
 
21750
      return true;
21751
    }
21752
 
21753
    @Override
21754
    public int hashCode() {
21755
      return 0;
21756
    }
21757
 
21758
    public int compareTo(markMissedInventoryUpdatesAsProcessed_args other) {
21759
      if (!getClass().equals(other.getClass())) {
21760
        return getClass().getName().compareTo(other.getClass().getName());
21761
      }
21762
 
21763
      int lastComparison = 0;
21764
      markMissedInventoryUpdatesAsProcessed_args typedOther = (markMissedInventoryUpdatesAsProcessed_args)other;
21765
 
21766
      lastComparison = Boolean.valueOf(isSetItemKey()).compareTo(typedOther.isSetItemKey());
21767
      if (lastComparison != 0) {
21768
        return lastComparison;
21769
      }
21770
      if (isSetItemKey()) {
21771
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemKey, typedOther.itemKey);
21772
        if (lastComparison != 0) {
21773
          return lastComparison;
21774
        }
21775
      }
21776
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
21777
      if (lastComparison != 0) {
21778
        return lastComparison;
21779
      }
21780
      if (isSetWarehouseId()) {
21781
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
21782
        if (lastComparison != 0) {
21783
          return lastComparison;
21784
        }
21785
      }
21786
      return 0;
21787
    }
21788
 
21789
    public _Fields fieldForId(int fieldId) {
21790
      return _Fields.findByThriftId(fieldId);
21791
    }
21792
 
21793
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21794
      org.apache.thrift.protocol.TField field;
21795
      iprot.readStructBegin();
21796
      while (true)
21797
      {
21798
        field = iprot.readFieldBegin();
21799
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21800
          break;
21801
        }
21802
        switch (field.id) {
21803
          case 1: // ITEM_KEY
21804
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
21805
              this.itemKey = iprot.readString();
21806
            } else { 
21807
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21808
            }
21809
            break;
21810
          case 2: // WAREHOUSE_ID
21811
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21812
              this.warehouseId = iprot.readI64();
21813
              setWarehouseIdIsSet(true);
21814
            } else { 
21815
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21816
            }
21817
            break;
21818
          default:
21819
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21820
        }
21821
        iprot.readFieldEnd();
21822
      }
21823
      iprot.readStructEnd();
21824
      validate();
21825
    }
21826
 
21827
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21828
      validate();
21829
 
21830
      oprot.writeStructBegin(STRUCT_DESC);
21831
      if (this.itemKey != null) {
21832
        oprot.writeFieldBegin(ITEM_KEY_FIELD_DESC);
21833
        oprot.writeString(this.itemKey);
21834
        oprot.writeFieldEnd();
21835
      }
21836
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
21837
      oprot.writeI64(this.warehouseId);
21838
      oprot.writeFieldEnd();
21839
      oprot.writeFieldStop();
21840
      oprot.writeStructEnd();
21841
    }
21842
 
21843
    @Override
21844
    public String toString() {
21845
      StringBuilder sb = new StringBuilder("markMissedInventoryUpdatesAsProcessed_args(");
21846
      boolean first = true;
21847
 
21848
      sb.append("itemKey:");
21849
      if (this.itemKey == null) {
21850
        sb.append("null");
21851
      } else {
21852
        sb.append(this.itemKey);
21853
      }
21854
      first = false;
21855
      if (!first) sb.append(", ");
21856
      sb.append("warehouseId:");
21857
      sb.append(this.warehouseId);
21858
      first = false;
21859
      sb.append(")");
21860
      return sb.toString();
21861
    }
21862
 
21863
    public void validate() throws org.apache.thrift.TException {
21864
      // check for required fields
21865
    }
21866
 
21867
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21868
      try {
21869
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21870
      } catch (org.apache.thrift.TException te) {
21871
        throw new java.io.IOException(te);
21872
      }
21873
    }
21874
 
21875
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21876
      try {
21877
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21878
      } catch (org.apache.thrift.TException te) {
21879
        throw new java.io.IOException(te);
21880
      }
21881
    }
21882
 
21883
  }
21884
 
21885
  public static class markMissedInventoryUpdatesAsProcessed_result implements org.apache.thrift.TBase<markMissedInventoryUpdatesAsProcessed_result, markMissedInventoryUpdatesAsProcessed_result._Fields>, java.io.Serializable, Cloneable   {
21886
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markMissedInventoryUpdatesAsProcessed_result");
21887
 
21888
 
21889
 
21890
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21891
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21892
;
21893
 
21894
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21895
 
21896
      static {
21897
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21898
          byName.put(field.getFieldName(), field);
21899
        }
21900
      }
21901
 
21902
      /**
21903
       * Find the _Fields constant that matches fieldId, or null if its not found.
21904
       */
21905
      public static _Fields findByThriftId(int fieldId) {
21906
        switch(fieldId) {
21907
          default:
21908
            return null;
21909
        }
21910
      }
21911
 
21912
      /**
21913
       * Find the _Fields constant that matches fieldId, throwing an exception
21914
       * if it is not found.
21915
       */
21916
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21917
        _Fields fields = findByThriftId(fieldId);
21918
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21919
        return fields;
21920
      }
21921
 
21922
      /**
21923
       * Find the _Fields constant that matches name, or null if its not found.
21924
       */
21925
      public static _Fields findByName(String name) {
21926
        return byName.get(name);
21927
      }
21928
 
21929
      private final short _thriftId;
21930
      private final String _fieldName;
21931
 
21932
      _Fields(short thriftId, String fieldName) {
21933
        _thriftId = thriftId;
21934
        _fieldName = fieldName;
21935
      }
21936
 
21937
      public short getThriftFieldId() {
21938
        return _thriftId;
21939
      }
21940
 
21941
      public String getFieldName() {
21942
        return _fieldName;
21943
      }
21944
    }
21945
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21946
    static {
21947
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21948
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21949
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markMissedInventoryUpdatesAsProcessed_result.class, metaDataMap);
21950
    }
21951
 
21952
    public markMissedInventoryUpdatesAsProcessed_result() {
21953
    }
21954
 
21955
    /**
21956
     * Performs a deep copy on <i>other</i>.
21957
     */
21958
    public markMissedInventoryUpdatesAsProcessed_result(markMissedInventoryUpdatesAsProcessed_result other) {
21959
    }
21960
 
21961
    public markMissedInventoryUpdatesAsProcessed_result deepCopy() {
21962
      return new markMissedInventoryUpdatesAsProcessed_result(this);
21963
    }
21964
 
21965
    @Override
21966
    public void clear() {
21967
    }
21968
 
21969
    public void setFieldValue(_Fields field, Object value) {
21970
      switch (field) {
21971
      }
21972
    }
21973
 
21974
    public Object getFieldValue(_Fields field) {
21975
      switch (field) {
21976
      }
21977
      throw new IllegalStateException();
21978
    }
21979
 
21980
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21981
    public boolean isSet(_Fields field) {
21982
      if (field == null) {
21983
        throw new IllegalArgumentException();
21984
      }
21985
 
21986
      switch (field) {
21987
      }
21988
      throw new IllegalStateException();
21989
    }
21990
 
21991
    @Override
21992
    public boolean equals(Object that) {
21993
      if (that == null)
21994
        return false;
21995
      if (that instanceof markMissedInventoryUpdatesAsProcessed_result)
21996
        return this.equals((markMissedInventoryUpdatesAsProcessed_result)that);
21997
      return false;
21998
    }
21999
 
22000
    public boolean equals(markMissedInventoryUpdatesAsProcessed_result that) {
22001
      if (that == null)
22002
        return false;
22003
 
22004
      return true;
22005
    }
22006
 
22007
    @Override
22008
    public int hashCode() {
22009
      return 0;
22010
    }
22011
 
22012
    public int compareTo(markMissedInventoryUpdatesAsProcessed_result other) {
22013
      if (!getClass().equals(other.getClass())) {
22014
        return getClass().getName().compareTo(other.getClass().getName());
22015
      }
22016
 
22017
      int lastComparison = 0;
22018
      markMissedInventoryUpdatesAsProcessed_result typedOther = (markMissedInventoryUpdatesAsProcessed_result)other;
22019
 
22020
      return 0;
22021
    }
22022
 
22023
    public _Fields fieldForId(int fieldId) {
22024
      return _Fields.findByThriftId(fieldId);
22025
    }
22026
 
22027
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22028
      org.apache.thrift.protocol.TField field;
22029
      iprot.readStructBegin();
22030
      while (true)
22031
      {
22032
        field = iprot.readFieldBegin();
22033
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22034
          break;
22035
        }
22036
        switch (field.id) {
22037
          default:
22038
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22039
        }
22040
        iprot.readFieldEnd();
22041
      }
22042
      iprot.readStructEnd();
22043
      validate();
22044
    }
22045
 
22046
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22047
      oprot.writeStructBegin(STRUCT_DESC);
22048
 
22049
      oprot.writeFieldStop();
22050
      oprot.writeStructEnd();
22051
    }
22052
 
22053
    @Override
22054
    public String toString() {
22055
      StringBuilder sb = new StringBuilder("markMissedInventoryUpdatesAsProcessed_result(");
22056
      boolean first = true;
22057
 
22058
      sb.append(")");
22059
      return sb.toString();
22060
    }
22061
 
22062
    public void validate() throws org.apache.thrift.TException {
22063
      // check for required fields
22064
    }
22065
 
22066
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22067
      try {
22068
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22069
      } catch (org.apache.thrift.TException te) {
22070
        throw new java.io.IOException(te);
22071
      }
22072
    }
22073
 
22074
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22075
      try {
22076
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22077
      } catch (org.apache.thrift.TException te) {
22078
        throw new java.io.IOException(te);
22079
      }
22080
    }
22081
 
22082
  }
22083
 
22084
  public static class getIgnoredItemKeys_args implements org.apache.thrift.TBase<getIgnoredItemKeys_args, getIgnoredItemKeys_args._Fields>, java.io.Serializable, Cloneable   {
22085
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getIgnoredItemKeys_args");
22086
 
22087
 
22088
 
22089
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22090
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22091
;
22092
 
22093
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22094
 
22095
      static {
22096
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22097
          byName.put(field.getFieldName(), field);
22098
        }
22099
      }
22100
 
22101
      /**
22102
       * Find the _Fields constant that matches fieldId, or null if its not found.
22103
       */
22104
      public static _Fields findByThriftId(int fieldId) {
22105
        switch(fieldId) {
22106
          default:
22107
            return null;
22108
        }
22109
      }
22110
 
22111
      /**
22112
       * Find the _Fields constant that matches fieldId, throwing an exception
22113
       * if it is not found.
22114
       */
22115
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22116
        _Fields fields = findByThriftId(fieldId);
22117
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22118
        return fields;
22119
      }
22120
 
22121
      /**
22122
       * Find the _Fields constant that matches name, or null if its not found.
22123
       */
22124
      public static _Fields findByName(String name) {
22125
        return byName.get(name);
22126
      }
22127
 
22128
      private final short _thriftId;
22129
      private final String _fieldName;
22130
 
22131
      _Fields(short thriftId, String fieldName) {
22132
        _thriftId = thriftId;
22133
        _fieldName = fieldName;
22134
      }
22135
 
22136
      public short getThriftFieldId() {
22137
        return _thriftId;
22138
      }
22139
 
22140
      public String getFieldName() {
22141
        return _fieldName;
22142
      }
22143
    }
22144
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22145
    static {
22146
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22147
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22148
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getIgnoredItemKeys_args.class, metaDataMap);
22149
    }
22150
 
22151
    public getIgnoredItemKeys_args() {
22152
    }
22153
 
22154
    /**
22155
     * Performs a deep copy on <i>other</i>.
22156
     */
22157
    public getIgnoredItemKeys_args(getIgnoredItemKeys_args other) {
22158
    }
22159
 
22160
    public getIgnoredItemKeys_args deepCopy() {
22161
      return new getIgnoredItemKeys_args(this);
22162
    }
22163
 
22164
    @Override
22165
    public void clear() {
22166
    }
22167
 
22168
    public void setFieldValue(_Fields field, Object value) {
22169
      switch (field) {
22170
      }
22171
    }
22172
 
22173
    public Object getFieldValue(_Fields field) {
22174
      switch (field) {
22175
      }
22176
      throw new IllegalStateException();
22177
    }
22178
 
22179
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22180
    public boolean isSet(_Fields field) {
22181
      if (field == null) {
22182
        throw new IllegalArgumentException();
22183
      }
22184
 
22185
      switch (field) {
22186
      }
22187
      throw new IllegalStateException();
22188
    }
22189
 
22190
    @Override
22191
    public boolean equals(Object that) {
22192
      if (that == null)
22193
        return false;
22194
      if (that instanceof getIgnoredItemKeys_args)
22195
        return this.equals((getIgnoredItemKeys_args)that);
22196
      return false;
22197
    }
22198
 
22199
    public boolean equals(getIgnoredItemKeys_args that) {
22200
      if (that == null)
22201
        return false;
22202
 
22203
      return true;
22204
    }
22205
 
22206
    @Override
22207
    public int hashCode() {
22208
      return 0;
22209
    }
22210
 
22211
    public int compareTo(getIgnoredItemKeys_args other) {
22212
      if (!getClass().equals(other.getClass())) {
22213
        return getClass().getName().compareTo(other.getClass().getName());
22214
      }
22215
 
22216
      int lastComparison = 0;
22217
      getIgnoredItemKeys_args typedOther = (getIgnoredItemKeys_args)other;
22218
 
22219
      return 0;
22220
    }
22221
 
22222
    public _Fields fieldForId(int fieldId) {
22223
      return _Fields.findByThriftId(fieldId);
22224
    }
22225
 
22226
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22227
      org.apache.thrift.protocol.TField field;
22228
      iprot.readStructBegin();
22229
      while (true)
22230
      {
22231
        field = iprot.readFieldBegin();
22232
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22233
          break;
22234
        }
22235
        switch (field.id) {
22236
          default:
22237
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22238
        }
22239
        iprot.readFieldEnd();
22240
      }
22241
      iprot.readStructEnd();
22242
      validate();
22243
    }
22244
 
22245
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22246
      validate();
22247
 
22248
      oprot.writeStructBegin(STRUCT_DESC);
22249
      oprot.writeFieldStop();
22250
      oprot.writeStructEnd();
22251
    }
22252
 
22253
    @Override
22254
    public String toString() {
22255
      StringBuilder sb = new StringBuilder("getIgnoredItemKeys_args(");
22256
      boolean first = true;
22257
 
22258
      sb.append(")");
22259
      return sb.toString();
22260
    }
22261
 
22262
    public void validate() throws org.apache.thrift.TException {
22263
      // check for required fields
22264
    }
22265
 
22266
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22267
      try {
22268
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22269
      } catch (org.apache.thrift.TException te) {
22270
        throw new java.io.IOException(te);
22271
      }
22272
    }
22273
 
22274
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22275
      try {
22276
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22277
      } catch (org.apache.thrift.TException te) {
22278
        throw new java.io.IOException(te);
22279
      }
22280
    }
22281
 
22282
  }
22283
 
22284
  public static class getIgnoredItemKeys_result implements org.apache.thrift.TBase<getIgnoredItemKeys_result, getIgnoredItemKeys_result._Fields>, java.io.Serializable, Cloneable   {
22285
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getIgnoredItemKeys_result");
22286
 
22287
    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);
22288
 
22289
    private Map<String,Map<Long,Long>> success; // required
22290
 
22291
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22292
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22293
      SUCCESS((short)0, "success");
22294
 
22295
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22296
 
22297
      static {
22298
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22299
          byName.put(field.getFieldName(), field);
22300
        }
22301
      }
22302
 
22303
      /**
22304
       * Find the _Fields constant that matches fieldId, or null if its not found.
22305
       */
22306
      public static _Fields findByThriftId(int fieldId) {
22307
        switch(fieldId) {
22308
          case 0: // SUCCESS
22309
            return SUCCESS;
22310
          default:
22311
            return null;
22312
        }
22313
      }
22314
 
22315
      /**
22316
       * Find the _Fields constant that matches fieldId, throwing an exception
22317
       * if it is not found.
22318
       */
22319
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22320
        _Fields fields = findByThriftId(fieldId);
22321
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22322
        return fields;
22323
      }
22324
 
22325
      /**
22326
       * Find the _Fields constant that matches name, or null if its not found.
22327
       */
22328
      public static _Fields findByName(String name) {
22329
        return byName.get(name);
22330
      }
22331
 
22332
      private final short _thriftId;
22333
      private final String _fieldName;
22334
 
22335
      _Fields(short thriftId, String fieldName) {
22336
        _thriftId = thriftId;
22337
        _fieldName = fieldName;
22338
      }
22339
 
22340
      public short getThriftFieldId() {
22341
        return _thriftId;
22342
      }
22343
 
22344
      public String getFieldName() {
22345
        return _fieldName;
22346
      }
22347
    }
22348
 
22349
    // isset id assignments
22350
 
22351
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22352
    static {
22353
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22354
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22355
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
22356
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
22357
              new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
22358
                  new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
22359
                  new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)))));
22360
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22361
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getIgnoredItemKeys_result.class, metaDataMap);
22362
    }
22363
 
22364
    public getIgnoredItemKeys_result() {
22365
    }
22366
 
22367
    public getIgnoredItemKeys_result(
22368
      Map<String,Map<Long,Long>> success)
22369
    {
22370
      this();
22371
      this.success = success;
22372
    }
22373
 
22374
    /**
22375
     * Performs a deep copy on <i>other</i>.
22376
     */
22377
    public getIgnoredItemKeys_result(getIgnoredItemKeys_result other) {
22378
      if (other.isSetSuccess()) {
22379
        Map<String,Map<Long,Long>> __this__success = new HashMap<String,Map<Long,Long>>();
22380
        for (Map.Entry<String, Map<Long,Long>> other_element : other.success.entrySet()) {
22381
 
22382
          String other_element_key = other_element.getKey();
22383
          Map<Long,Long> other_element_value = other_element.getValue();
22384
 
22385
          String __this__success_copy_key = other_element_key;
22386
 
22387
          Map<Long,Long> __this__success_copy_value = new HashMap<Long,Long>();
22388
          for (Map.Entry<Long, Long> other_element_value_element : other_element_value.entrySet()) {
22389
 
22390
            Long other_element_value_element_key = other_element_value_element.getKey();
22391
            Long other_element_value_element_value = other_element_value_element.getValue();
22392
 
22393
            Long __this__success_copy_value_copy_key = other_element_value_element_key;
22394
 
22395
            Long __this__success_copy_value_copy_value = other_element_value_element_value;
22396
 
22397
            __this__success_copy_value.put(__this__success_copy_value_copy_key, __this__success_copy_value_copy_value);
22398
          }
22399
 
22400
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
22401
        }
22402
        this.success = __this__success;
22403
      }
22404
    }
22405
 
22406
    public getIgnoredItemKeys_result deepCopy() {
22407
      return new getIgnoredItemKeys_result(this);
22408
    }
22409
 
22410
    @Override
22411
    public void clear() {
22412
      this.success = null;
22413
    }
22414
 
22415
    public int getSuccessSize() {
22416
      return (this.success == null) ? 0 : this.success.size();
22417
    }
22418
 
22419
    public void putToSuccess(String key, Map<Long,Long> val) {
22420
      if (this.success == null) {
22421
        this.success = new HashMap<String,Map<Long,Long>>();
22422
      }
22423
      this.success.put(key, val);
22424
    }
22425
 
22426
    public Map<String,Map<Long,Long>> getSuccess() {
22427
      return this.success;
22428
    }
22429
 
22430
    public void setSuccess(Map<String,Map<Long,Long>> success) {
22431
      this.success = success;
22432
    }
22433
 
22434
    public void unsetSuccess() {
22435
      this.success = null;
22436
    }
22437
 
22438
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
22439
    public boolean isSetSuccess() {
22440
      return this.success != null;
22441
    }
22442
 
22443
    public void setSuccessIsSet(boolean value) {
22444
      if (!value) {
22445
        this.success = null;
22446
      }
22447
    }
22448
 
22449
    public void setFieldValue(_Fields field, Object value) {
22450
      switch (field) {
22451
      case SUCCESS:
22452
        if (value == null) {
22453
          unsetSuccess();
22454
        } else {
22455
          setSuccess((Map<String,Map<Long,Long>>)value);
22456
        }
22457
        break;
22458
 
22459
      }
22460
    }
22461
 
22462
    public Object getFieldValue(_Fields field) {
22463
      switch (field) {
22464
      case SUCCESS:
22465
        return getSuccess();
22466
 
22467
      }
22468
      throw new IllegalStateException();
22469
    }
22470
 
22471
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22472
    public boolean isSet(_Fields field) {
22473
      if (field == null) {
22474
        throw new IllegalArgumentException();
22475
      }
22476
 
22477
      switch (field) {
22478
      case SUCCESS:
22479
        return isSetSuccess();
22480
      }
22481
      throw new IllegalStateException();
22482
    }
22483
 
22484
    @Override
22485
    public boolean equals(Object that) {
22486
      if (that == null)
22487
        return false;
22488
      if (that instanceof getIgnoredItemKeys_result)
22489
        return this.equals((getIgnoredItemKeys_result)that);
22490
      return false;
22491
    }
22492
 
22493
    public boolean equals(getIgnoredItemKeys_result that) {
22494
      if (that == null)
22495
        return false;
22496
 
22497
      boolean this_present_success = true && this.isSetSuccess();
22498
      boolean that_present_success = true && that.isSetSuccess();
22499
      if (this_present_success || that_present_success) {
22500
        if (!(this_present_success && that_present_success))
22501
          return false;
22502
        if (!this.success.equals(that.success))
22503
          return false;
22504
      }
22505
 
22506
      return true;
22507
    }
22508
 
22509
    @Override
22510
    public int hashCode() {
22511
      return 0;
22512
    }
22513
 
22514
    public int compareTo(getIgnoredItemKeys_result other) {
22515
      if (!getClass().equals(other.getClass())) {
22516
        return getClass().getName().compareTo(other.getClass().getName());
22517
      }
22518
 
22519
      int lastComparison = 0;
22520
      getIgnoredItemKeys_result typedOther = (getIgnoredItemKeys_result)other;
22521
 
22522
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
22523
      if (lastComparison != 0) {
22524
        return lastComparison;
22525
      }
22526
      if (isSetSuccess()) {
22527
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
22528
        if (lastComparison != 0) {
22529
          return lastComparison;
22530
        }
22531
      }
22532
      return 0;
22533
    }
22534
 
22535
    public _Fields fieldForId(int fieldId) {
22536
      return _Fields.findByThriftId(fieldId);
22537
    }
22538
 
22539
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22540
      org.apache.thrift.protocol.TField field;
22541
      iprot.readStructBegin();
22542
      while (true)
22543
      {
22544
        field = iprot.readFieldBegin();
22545
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22546
          break;
22547
        }
22548
        switch (field.id) {
22549
          case 0: // SUCCESS
22550
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
22551
              {
22552
                org.apache.thrift.protocol.TMap _map56 = iprot.readMapBegin();
22553
                this.success = new HashMap<String,Map<Long,Long>>(2*_map56.size);
22554
                for (int _i57 = 0; _i57 < _map56.size; ++_i57)
22555
                {
22556
                  String _key58; // required
22557
                  Map<Long,Long> _val59; // required
22558
                  _key58 = iprot.readString();
22559
                  {
22560
                    org.apache.thrift.protocol.TMap _map60 = iprot.readMapBegin();
22561
                    _val59 = new HashMap<Long,Long>(2*_map60.size);
22562
                    for (int _i61 = 0; _i61 < _map60.size; ++_i61)
22563
                    {
22564
                      long _key62; // required
22565
                      long _val63; // required
22566
                      _key62 = iprot.readI64();
22567
                      _val63 = iprot.readI64();
22568
                      _val59.put(_key62, _val63);
22569
                    }
22570
                    iprot.readMapEnd();
22571
                  }
22572
                  this.success.put(_key58, _val59);
22573
                }
22574
                iprot.readMapEnd();
22575
              }
22576
            } else { 
22577
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22578
            }
22579
            break;
22580
          default:
22581
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22582
        }
22583
        iprot.readFieldEnd();
22584
      }
22585
      iprot.readStructEnd();
22586
      validate();
22587
    }
22588
 
22589
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22590
      oprot.writeStructBegin(STRUCT_DESC);
22591
 
22592
      if (this.isSetSuccess()) {
22593
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
22594
        {
22595
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.MAP, this.success.size()));
22596
          for (Map.Entry<String, Map<Long,Long>> _iter64 : this.success.entrySet())
22597
          {
22598
            oprot.writeString(_iter64.getKey());
22599
            {
22600
              oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.I64, _iter64.getValue().size()));
22601
              for (Map.Entry<Long, Long> _iter65 : _iter64.getValue().entrySet())
22602
              {
22603
                oprot.writeI64(_iter65.getKey());
22604
                oprot.writeI64(_iter65.getValue());
22605
              }
22606
              oprot.writeMapEnd();
22607
            }
22608
          }
22609
          oprot.writeMapEnd();
22610
        }
22611
        oprot.writeFieldEnd();
22612
      }
22613
      oprot.writeFieldStop();
22614
      oprot.writeStructEnd();
22615
    }
22616
 
22617
    @Override
22618
    public String toString() {
22619
      StringBuilder sb = new StringBuilder("getIgnoredItemKeys_result(");
22620
      boolean first = true;
22621
 
22622
      sb.append("success:");
22623
      if (this.success == null) {
22624
        sb.append("null");
22625
      } else {
22626
        sb.append(this.success);
22627
      }
22628
      first = false;
22629
      sb.append(")");
22630
      return sb.toString();
22631
    }
22632
 
22633
    public void validate() throws org.apache.thrift.TException {
22634
      // check for required fields
22635
    }
22636
 
22637
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22638
      try {
22639
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22640
      } catch (org.apache.thrift.TException te) {
22641
        throw new java.io.IOException(te);
22642
      }
22643
    }
22644
 
22645
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22646
      try {
22647
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22648
      } catch (org.apache.thrift.TException te) {
22649
        throw new java.io.IOException(te);
22650
      }
22651
    }
22652
 
22653
  }
22654
 
22655
  public static class addBadInventory_args implements org.apache.thrift.TBase<addBadInventory_args, addBadInventory_args._Fields>, java.io.Serializable, Cloneable   {
22656
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addBadInventory_args");
22657
 
22658
    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);
22659
    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);
22660
    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);
22661
 
22662
    private long itemId; // required
22663
    private long warehouseId; // required
22664
    private long quantity; // required
22665
 
22666
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22667
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22668
      ITEM_ID((short)1, "itemId"),
22669
      WAREHOUSE_ID((short)2, "warehouseId"),
22670
      QUANTITY((short)3, "quantity");
22671
 
22672
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22673
 
22674
      static {
22675
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22676
          byName.put(field.getFieldName(), field);
22677
        }
22678
      }
22679
 
22680
      /**
22681
       * Find the _Fields constant that matches fieldId, or null if its not found.
22682
       */
22683
      public static _Fields findByThriftId(int fieldId) {
22684
        switch(fieldId) {
22685
          case 1: // ITEM_ID
22686
            return ITEM_ID;
22687
          case 2: // WAREHOUSE_ID
22688
            return WAREHOUSE_ID;
22689
          case 3: // QUANTITY
22690
            return QUANTITY;
22691
          default:
22692
            return null;
22693
        }
22694
      }
22695
 
22696
      /**
22697
       * Find the _Fields constant that matches fieldId, throwing an exception
22698
       * if it is not found.
22699
       */
22700
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22701
        _Fields fields = findByThriftId(fieldId);
22702
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22703
        return fields;
22704
      }
22705
 
22706
      /**
22707
       * Find the _Fields constant that matches name, or null if its not found.
22708
       */
22709
      public static _Fields findByName(String name) {
22710
        return byName.get(name);
22711
      }
22712
 
22713
      private final short _thriftId;
22714
      private final String _fieldName;
22715
 
22716
      _Fields(short thriftId, String fieldName) {
22717
        _thriftId = thriftId;
22718
        _fieldName = fieldName;
22719
      }
22720
 
22721
      public short getThriftFieldId() {
22722
        return _thriftId;
22723
      }
22724
 
22725
      public String getFieldName() {
22726
        return _fieldName;
22727
      }
22728
    }
22729
 
22730
    // isset id assignments
22731
    private static final int __ITEMID_ISSET_ID = 0;
22732
    private static final int __WAREHOUSEID_ISSET_ID = 1;
22733
    private static final int __QUANTITY_ISSET_ID = 2;
22734
    private BitSet __isset_bit_vector = new BitSet(3);
22735
 
22736
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22737
    static {
22738
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22739
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22740
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
22741
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22742
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
22743
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22744
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
22745
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22746
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addBadInventory_args.class, metaDataMap);
22747
    }
22748
 
22749
    public addBadInventory_args() {
22750
    }
22751
 
22752
    public addBadInventory_args(
22753
      long itemId,
22754
      long warehouseId,
22755
      long quantity)
22756
    {
22757
      this();
22758
      this.itemId = itemId;
22759
      setItemIdIsSet(true);
22760
      this.warehouseId = warehouseId;
22761
      setWarehouseIdIsSet(true);
22762
      this.quantity = quantity;
22763
      setQuantityIsSet(true);
22764
    }
22765
 
22766
    /**
22767
     * Performs a deep copy on <i>other</i>.
22768
     */
22769
    public addBadInventory_args(addBadInventory_args other) {
22770
      __isset_bit_vector.clear();
22771
      __isset_bit_vector.or(other.__isset_bit_vector);
22772
      this.itemId = other.itemId;
22773
      this.warehouseId = other.warehouseId;
22774
      this.quantity = other.quantity;
22775
    }
22776
 
22777
    public addBadInventory_args deepCopy() {
22778
      return new addBadInventory_args(this);
22779
    }
22780
 
22781
    @Override
22782
    public void clear() {
22783
      setItemIdIsSet(false);
22784
      this.itemId = 0;
22785
      setWarehouseIdIsSet(false);
22786
      this.warehouseId = 0;
22787
      setQuantityIsSet(false);
22788
      this.quantity = 0;
22789
    }
22790
 
22791
    public long getItemId() {
22792
      return this.itemId;
22793
    }
22794
 
22795
    public void setItemId(long itemId) {
22796
      this.itemId = itemId;
22797
      setItemIdIsSet(true);
22798
    }
22799
 
22800
    public void unsetItemId() {
22801
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
22802
    }
22803
 
22804
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
22805
    public boolean isSetItemId() {
22806
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
22807
    }
22808
 
22809
    public void setItemIdIsSet(boolean value) {
22810
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
22811
    }
22812
 
22813
    public long getWarehouseId() {
22814
      return this.warehouseId;
22815
    }
22816
 
22817
    public void setWarehouseId(long warehouseId) {
22818
      this.warehouseId = warehouseId;
22819
      setWarehouseIdIsSet(true);
22820
    }
22821
 
22822
    public void unsetWarehouseId() {
22823
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
22824
    }
22825
 
22826
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
22827
    public boolean isSetWarehouseId() {
22828
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
22829
    }
22830
 
22831
    public void setWarehouseIdIsSet(boolean value) {
22832
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
22833
    }
22834
 
22835
    public long getQuantity() {
22836
      return this.quantity;
22837
    }
22838
 
22839
    public void setQuantity(long quantity) {
22840
      this.quantity = quantity;
22841
      setQuantityIsSet(true);
22842
    }
22843
 
22844
    public void unsetQuantity() {
22845
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
22846
    }
22847
 
22848
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
22849
    public boolean isSetQuantity() {
22850
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
22851
    }
22852
 
22853
    public void setQuantityIsSet(boolean value) {
22854
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
22855
    }
22856
 
22857
    public void setFieldValue(_Fields field, Object value) {
22858
      switch (field) {
22859
      case ITEM_ID:
22860
        if (value == null) {
22861
          unsetItemId();
22862
        } else {
22863
          setItemId((Long)value);
22864
        }
22865
        break;
22866
 
22867
      case WAREHOUSE_ID:
22868
        if (value == null) {
22869
          unsetWarehouseId();
22870
        } else {
22871
          setWarehouseId((Long)value);
22872
        }
22873
        break;
22874
 
22875
      case QUANTITY:
22876
        if (value == null) {
22877
          unsetQuantity();
22878
        } else {
22879
          setQuantity((Long)value);
22880
        }
22881
        break;
22882
 
22883
      }
22884
    }
22885
 
22886
    public Object getFieldValue(_Fields field) {
22887
      switch (field) {
22888
      case ITEM_ID:
22889
        return Long.valueOf(getItemId());
22890
 
22891
      case WAREHOUSE_ID:
22892
        return Long.valueOf(getWarehouseId());
22893
 
22894
      case QUANTITY:
22895
        return Long.valueOf(getQuantity());
22896
 
22897
      }
22898
      throw new IllegalStateException();
22899
    }
22900
 
22901
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22902
    public boolean isSet(_Fields field) {
22903
      if (field == null) {
22904
        throw new IllegalArgumentException();
22905
      }
22906
 
22907
      switch (field) {
22908
      case ITEM_ID:
22909
        return isSetItemId();
22910
      case WAREHOUSE_ID:
22911
        return isSetWarehouseId();
22912
      case QUANTITY:
22913
        return isSetQuantity();
22914
      }
22915
      throw new IllegalStateException();
22916
    }
22917
 
22918
    @Override
22919
    public boolean equals(Object that) {
22920
      if (that == null)
22921
        return false;
22922
      if (that instanceof addBadInventory_args)
22923
        return this.equals((addBadInventory_args)that);
22924
      return false;
22925
    }
22926
 
22927
    public boolean equals(addBadInventory_args that) {
22928
      if (that == null)
22929
        return false;
22930
 
22931
      boolean this_present_itemId = true;
22932
      boolean that_present_itemId = true;
22933
      if (this_present_itemId || that_present_itemId) {
22934
        if (!(this_present_itemId && that_present_itemId))
22935
          return false;
22936
        if (this.itemId != that.itemId)
22937
          return false;
22938
      }
22939
 
22940
      boolean this_present_warehouseId = true;
22941
      boolean that_present_warehouseId = true;
22942
      if (this_present_warehouseId || that_present_warehouseId) {
22943
        if (!(this_present_warehouseId && that_present_warehouseId))
22944
          return false;
22945
        if (this.warehouseId != that.warehouseId)
22946
          return false;
22947
      }
22948
 
22949
      boolean this_present_quantity = true;
22950
      boolean that_present_quantity = true;
22951
      if (this_present_quantity || that_present_quantity) {
22952
        if (!(this_present_quantity && that_present_quantity))
22953
          return false;
22954
        if (this.quantity != that.quantity)
22955
          return false;
22956
      }
22957
 
22958
      return true;
22959
    }
22960
 
22961
    @Override
22962
    public int hashCode() {
22963
      return 0;
22964
    }
22965
 
22966
    public int compareTo(addBadInventory_args other) {
22967
      if (!getClass().equals(other.getClass())) {
22968
        return getClass().getName().compareTo(other.getClass().getName());
22969
      }
22970
 
22971
      int lastComparison = 0;
22972
      addBadInventory_args typedOther = (addBadInventory_args)other;
22973
 
22974
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
22975
      if (lastComparison != 0) {
22976
        return lastComparison;
22977
      }
22978
      if (isSetItemId()) {
22979
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
22980
        if (lastComparison != 0) {
22981
          return lastComparison;
22982
        }
22983
      }
22984
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
22985
      if (lastComparison != 0) {
22986
        return lastComparison;
22987
      }
22988
      if (isSetWarehouseId()) {
22989
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
22990
        if (lastComparison != 0) {
22991
          return lastComparison;
22992
        }
22993
      }
22994
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
22995
      if (lastComparison != 0) {
22996
        return lastComparison;
22997
      }
22998
      if (isSetQuantity()) {
22999
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
23000
        if (lastComparison != 0) {
23001
          return lastComparison;
23002
        }
23003
      }
23004
      return 0;
23005
    }
23006
 
23007
    public _Fields fieldForId(int fieldId) {
23008
      return _Fields.findByThriftId(fieldId);
23009
    }
23010
 
23011
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23012
      org.apache.thrift.protocol.TField field;
23013
      iprot.readStructBegin();
23014
      while (true)
23015
      {
23016
        field = iprot.readFieldBegin();
23017
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23018
          break;
23019
        }
23020
        switch (field.id) {
23021
          case 1: // ITEM_ID
23022
            if (field.type == org.apache.thrift.protocol.TType.I64) {
23023
              this.itemId = iprot.readI64();
23024
              setItemIdIsSet(true);
23025
            } else { 
23026
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23027
            }
23028
            break;
23029
          case 2: // WAREHOUSE_ID
23030
            if (field.type == org.apache.thrift.protocol.TType.I64) {
23031
              this.warehouseId = iprot.readI64();
23032
              setWarehouseIdIsSet(true);
23033
            } else { 
23034
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23035
            }
23036
            break;
23037
          case 3: // QUANTITY
23038
            if (field.type == org.apache.thrift.protocol.TType.I64) {
23039
              this.quantity = iprot.readI64();
23040
              setQuantityIsSet(true);
23041
            } else { 
23042
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23043
            }
23044
            break;
23045
          default:
23046
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23047
        }
23048
        iprot.readFieldEnd();
23049
      }
23050
      iprot.readStructEnd();
23051
      validate();
23052
    }
23053
 
23054
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23055
      validate();
23056
 
23057
      oprot.writeStructBegin(STRUCT_DESC);
23058
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
23059
      oprot.writeI64(this.itemId);
23060
      oprot.writeFieldEnd();
23061
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
23062
      oprot.writeI64(this.warehouseId);
23063
      oprot.writeFieldEnd();
23064
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
23065
      oprot.writeI64(this.quantity);
23066
      oprot.writeFieldEnd();
23067
      oprot.writeFieldStop();
23068
      oprot.writeStructEnd();
23069
    }
23070
 
23071
    @Override
23072
    public String toString() {
23073
      StringBuilder sb = new StringBuilder("addBadInventory_args(");
23074
      boolean first = true;
23075
 
23076
      sb.append("itemId:");
23077
      sb.append(this.itemId);
23078
      first = false;
23079
      if (!first) sb.append(", ");
23080
      sb.append("warehouseId:");
23081
      sb.append(this.warehouseId);
23082
      first = false;
23083
      if (!first) sb.append(", ");
23084
      sb.append("quantity:");
23085
      sb.append(this.quantity);
23086
      first = false;
23087
      sb.append(")");
23088
      return sb.toString();
23089
    }
23090
 
23091
    public void validate() throws org.apache.thrift.TException {
23092
      // check for required fields
23093
    }
23094
 
23095
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23096
      try {
23097
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23098
      } catch (org.apache.thrift.TException te) {
23099
        throw new java.io.IOException(te);
23100
      }
23101
    }
23102
 
23103
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23104
      try {
23105
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
23106
        __isset_bit_vector = new BitSet(1);
23107
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23108
      } catch (org.apache.thrift.TException te) {
23109
        throw new java.io.IOException(te);
23110
      }
23111
    }
23112
 
23113
  }
23114
 
23115
  public static class addBadInventory_result implements org.apache.thrift.TBase<addBadInventory_result, addBadInventory_result._Fields>, java.io.Serializable, Cloneable   {
23116
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addBadInventory_result");
23117
 
23118
    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);
23119
 
23120
    private InventoryServiceException cex; // required
23121
 
23122
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23123
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23124
      CEX((short)1, "cex");
23125
 
23126
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23127
 
23128
      static {
23129
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23130
          byName.put(field.getFieldName(), field);
23131
        }
23132
      }
23133
 
23134
      /**
23135
       * Find the _Fields constant that matches fieldId, or null if its not found.
23136
       */
23137
      public static _Fields findByThriftId(int fieldId) {
23138
        switch(fieldId) {
23139
          case 1: // CEX
23140
            return CEX;
23141
          default:
23142
            return null;
23143
        }
23144
      }
23145
 
23146
      /**
23147
       * Find the _Fields constant that matches fieldId, throwing an exception
23148
       * if it is not found.
23149
       */
23150
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23151
        _Fields fields = findByThriftId(fieldId);
23152
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23153
        return fields;
23154
      }
23155
 
23156
      /**
23157
       * Find the _Fields constant that matches name, or null if its not found.
23158
       */
23159
      public static _Fields findByName(String name) {
23160
        return byName.get(name);
23161
      }
23162
 
23163
      private final short _thriftId;
23164
      private final String _fieldName;
23165
 
23166
      _Fields(short thriftId, String fieldName) {
23167
        _thriftId = thriftId;
23168
        _fieldName = fieldName;
23169
      }
23170
 
23171
      public short getThriftFieldId() {
23172
        return _thriftId;
23173
      }
23174
 
23175
      public String getFieldName() {
23176
        return _fieldName;
23177
      }
23178
    }
23179
 
23180
    // isset id assignments
23181
 
23182
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23183
    static {
23184
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23185
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23186
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
23187
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23188
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addBadInventory_result.class, metaDataMap);
23189
    }
23190
 
23191
    public addBadInventory_result() {
23192
    }
23193
 
23194
    public addBadInventory_result(
23195
      InventoryServiceException cex)
23196
    {
23197
      this();
23198
      this.cex = cex;
23199
    }
23200
 
23201
    /**
23202
     * Performs a deep copy on <i>other</i>.
23203
     */
23204
    public addBadInventory_result(addBadInventory_result other) {
23205
      if (other.isSetCex()) {
23206
        this.cex = new InventoryServiceException(other.cex);
23207
      }
23208
    }
23209
 
23210
    public addBadInventory_result deepCopy() {
23211
      return new addBadInventory_result(this);
23212
    }
23213
 
23214
    @Override
23215
    public void clear() {
23216
      this.cex = null;
23217
    }
23218
 
23219
    public InventoryServiceException getCex() {
23220
      return this.cex;
23221
    }
23222
 
23223
    public void setCex(InventoryServiceException cex) {
23224
      this.cex = cex;
23225
    }
23226
 
23227
    public void unsetCex() {
23228
      this.cex = null;
23229
    }
23230
 
23231
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
23232
    public boolean isSetCex() {
23233
      return this.cex != null;
23234
    }
23235
 
23236
    public void setCexIsSet(boolean value) {
23237
      if (!value) {
23238
        this.cex = null;
23239
      }
23240
    }
23241
 
23242
    public void setFieldValue(_Fields field, Object value) {
23243
      switch (field) {
23244
      case CEX:
23245
        if (value == null) {
23246
          unsetCex();
23247
        } else {
23248
          setCex((InventoryServiceException)value);
23249
        }
23250
        break;
23251
 
23252
      }
23253
    }
23254
 
23255
    public Object getFieldValue(_Fields field) {
23256
      switch (field) {
23257
      case CEX:
23258
        return getCex();
23259
 
23260
      }
23261
      throw new IllegalStateException();
23262
    }
23263
 
23264
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23265
    public boolean isSet(_Fields field) {
23266
      if (field == null) {
23267
        throw new IllegalArgumentException();
23268
      }
23269
 
23270
      switch (field) {
23271
      case CEX:
23272
        return isSetCex();
23273
      }
23274
      throw new IllegalStateException();
23275
    }
23276
 
23277
    @Override
23278
    public boolean equals(Object that) {
23279
      if (that == null)
23280
        return false;
23281
      if (that instanceof addBadInventory_result)
23282
        return this.equals((addBadInventory_result)that);
23283
      return false;
23284
    }
23285
 
23286
    public boolean equals(addBadInventory_result that) {
23287
      if (that == null)
23288
        return false;
23289
 
23290
      boolean this_present_cex = true && this.isSetCex();
23291
      boolean that_present_cex = true && that.isSetCex();
23292
      if (this_present_cex || that_present_cex) {
23293
        if (!(this_present_cex && that_present_cex))
23294
          return false;
23295
        if (!this.cex.equals(that.cex))
23296
          return false;
23297
      }
23298
 
23299
      return true;
23300
    }
23301
 
23302
    @Override
23303
    public int hashCode() {
23304
      return 0;
23305
    }
23306
 
23307
    public int compareTo(addBadInventory_result other) {
23308
      if (!getClass().equals(other.getClass())) {
23309
        return getClass().getName().compareTo(other.getClass().getName());
23310
      }
23311
 
23312
      int lastComparison = 0;
23313
      addBadInventory_result typedOther = (addBadInventory_result)other;
23314
 
23315
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
23316
      if (lastComparison != 0) {
23317
        return lastComparison;
23318
      }
23319
      if (isSetCex()) {
23320
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
23321
        if (lastComparison != 0) {
23322
          return lastComparison;
23323
        }
23324
      }
23325
      return 0;
23326
    }
23327
 
23328
    public _Fields fieldForId(int fieldId) {
23329
      return _Fields.findByThriftId(fieldId);
23330
    }
23331
 
23332
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23333
      org.apache.thrift.protocol.TField field;
23334
      iprot.readStructBegin();
23335
      while (true)
23336
      {
23337
        field = iprot.readFieldBegin();
23338
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23339
          break;
23340
        }
23341
        switch (field.id) {
23342
          case 1: // CEX
23343
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
23344
              this.cex = new InventoryServiceException();
23345
              this.cex.read(iprot);
23346
            } else { 
23347
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23348
            }
23349
            break;
23350
          default:
23351
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23352
        }
23353
        iprot.readFieldEnd();
23354
      }
23355
      iprot.readStructEnd();
23356
      validate();
23357
    }
23358
 
23359
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23360
      oprot.writeStructBegin(STRUCT_DESC);
23361
 
23362
      if (this.isSetCex()) {
23363
        oprot.writeFieldBegin(CEX_FIELD_DESC);
23364
        this.cex.write(oprot);
23365
        oprot.writeFieldEnd();
23366
      }
23367
      oprot.writeFieldStop();
23368
      oprot.writeStructEnd();
23369
    }
23370
 
23371
    @Override
23372
    public String toString() {
23373
      StringBuilder sb = new StringBuilder("addBadInventory_result(");
23374
      boolean first = true;
23375
 
23376
      sb.append("cex:");
23377
      if (this.cex == null) {
23378
        sb.append("null");
23379
      } else {
23380
        sb.append(this.cex);
23381
      }
23382
      first = false;
23383
      sb.append(")");
23384
      return sb.toString();
23385
    }
23386
 
23387
    public void validate() throws org.apache.thrift.TException {
23388
      // check for required fields
23389
    }
23390
 
23391
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23392
      try {
23393
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23394
      } catch (org.apache.thrift.TException te) {
23395
        throw new java.io.IOException(te);
23396
      }
23397
    }
23398
 
23399
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23400
      try {
23401
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23402
      } catch (org.apache.thrift.TException te) {
23403
        throw new java.io.IOException(te);
23404
      }
23405
    }
23406
 
23407
  }
23408
 
23409
  public static class getShippingLocations_args implements org.apache.thrift.TBase<getShippingLocations_args, getShippingLocations_args._Fields>, java.io.Serializable, Cloneable   {
23410
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShippingLocations_args");
23411
 
23412
 
23413
 
23414
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23415
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23416
;
23417
 
23418
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23419
 
23420
      static {
23421
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23422
          byName.put(field.getFieldName(), field);
23423
        }
23424
      }
23425
 
23426
      /**
23427
       * Find the _Fields constant that matches fieldId, or null if its not found.
23428
       */
23429
      public static _Fields findByThriftId(int fieldId) {
23430
        switch(fieldId) {
23431
          default:
23432
            return null;
23433
        }
23434
      }
23435
 
23436
      /**
23437
       * Find the _Fields constant that matches fieldId, throwing an exception
23438
       * if it is not found.
23439
       */
23440
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23441
        _Fields fields = findByThriftId(fieldId);
23442
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23443
        return fields;
23444
      }
23445
 
23446
      /**
23447
       * Find the _Fields constant that matches name, or null if its not found.
23448
       */
23449
      public static _Fields findByName(String name) {
23450
        return byName.get(name);
23451
      }
23452
 
23453
      private final short _thriftId;
23454
      private final String _fieldName;
23455
 
23456
      _Fields(short thriftId, String fieldName) {
23457
        _thriftId = thriftId;
23458
        _fieldName = fieldName;
23459
      }
23460
 
23461
      public short getThriftFieldId() {
23462
        return _thriftId;
23463
      }
23464
 
23465
      public String getFieldName() {
23466
        return _fieldName;
23467
      }
23468
    }
23469
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23470
    static {
23471
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23472
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23473
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShippingLocations_args.class, metaDataMap);
23474
    }
23475
 
23476
    public getShippingLocations_args() {
23477
    }
23478
 
23479
    /**
23480
     * Performs a deep copy on <i>other</i>.
23481
     */
23482
    public getShippingLocations_args(getShippingLocations_args other) {
23483
    }
23484
 
23485
    public getShippingLocations_args deepCopy() {
23486
      return new getShippingLocations_args(this);
23487
    }
23488
 
23489
    @Override
23490
    public void clear() {
23491
    }
23492
 
23493
    public void setFieldValue(_Fields field, Object value) {
23494
      switch (field) {
23495
      }
23496
    }
23497
 
23498
    public Object getFieldValue(_Fields field) {
23499
      switch (field) {
23500
      }
23501
      throw new IllegalStateException();
23502
    }
23503
 
23504
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23505
    public boolean isSet(_Fields field) {
23506
      if (field == null) {
23507
        throw new IllegalArgumentException();
23508
      }
23509
 
23510
      switch (field) {
23511
      }
23512
      throw new IllegalStateException();
23513
    }
23514
 
23515
    @Override
23516
    public boolean equals(Object that) {
23517
      if (that == null)
23518
        return false;
23519
      if (that instanceof getShippingLocations_args)
23520
        return this.equals((getShippingLocations_args)that);
23521
      return false;
23522
    }
23523
 
23524
    public boolean equals(getShippingLocations_args that) {
23525
      if (that == null)
23526
        return false;
23527
 
23528
      return true;
23529
    }
23530
 
23531
    @Override
23532
    public int hashCode() {
23533
      return 0;
23534
    }
23535
 
23536
    public int compareTo(getShippingLocations_args other) {
23537
      if (!getClass().equals(other.getClass())) {
23538
        return getClass().getName().compareTo(other.getClass().getName());
23539
      }
23540
 
23541
      int lastComparison = 0;
23542
      getShippingLocations_args typedOther = (getShippingLocations_args)other;
23543
 
23544
      return 0;
23545
    }
23546
 
23547
    public _Fields fieldForId(int fieldId) {
23548
      return _Fields.findByThriftId(fieldId);
23549
    }
23550
 
23551
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23552
      org.apache.thrift.protocol.TField field;
23553
      iprot.readStructBegin();
23554
      while (true)
23555
      {
23556
        field = iprot.readFieldBegin();
23557
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23558
          break;
23559
        }
23560
        switch (field.id) {
23561
          default:
23562
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23563
        }
23564
        iprot.readFieldEnd();
23565
      }
23566
      iprot.readStructEnd();
23567
      validate();
23568
    }
23569
 
23570
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23571
      validate();
23572
 
23573
      oprot.writeStructBegin(STRUCT_DESC);
23574
      oprot.writeFieldStop();
23575
      oprot.writeStructEnd();
23576
    }
23577
 
23578
    @Override
23579
    public String toString() {
23580
      StringBuilder sb = new StringBuilder("getShippingLocations_args(");
23581
      boolean first = true;
23582
 
23583
      sb.append(")");
23584
      return sb.toString();
23585
    }
23586
 
23587
    public void validate() throws org.apache.thrift.TException {
23588
      // check for required fields
23589
    }
23590
 
23591
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23592
      try {
23593
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23594
      } catch (org.apache.thrift.TException te) {
23595
        throw new java.io.IOException(te);
23596
      }
23597
    }
23598
 
23599
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23600
      try {
23601
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23602
      } catch (org.apache.thrift.TException te) {
23603
        throw new java.io.IOException(te);
23604
      }
23605
    }
23606
 
23607
  }
23608
 
23609
  public static class getShippingLocations_result implements org.apache.thrift.TBase<getShippingLocations_result, getShippingLocations_result._Fields>, java.io.Serializable, Cloneable   {
23610
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShippingLocations_result");
23611
 
23612
    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);
23613
 
23614
    private List<Warehouse> success; // required
23615
 
23616
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23617
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23618
      SUCCESS((short)0, "success");
23619
 
23620
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23621
 
23622
      static {
23623
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23624
          byName.put(field.getFieldName(), field);
23625
        }
23626
      }
23627
 
23628
      /**
23629
       * Find the _Fields constant that matches fieldId, or null if its not found.
23630
       */
23631
      public static _Fields findByThriftId(int fieldId) {
23632
        switch(fieldId) {
23633
          case 0: // SUCCESS
23634
            return SUCCESS;
23635
          default:
23636
            return null;
23637
        }
23638
      }
23639
 
23640
      /**
23641
       * Find the _Fields constant that matches fieldId, throwing an exception
23642
       * if it is not found.
23643
       */
23644
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23645
        _Fields fields = findByThriftId(fieldId);
23646
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23647
        return fields;
23648
      }
23649
 
23650
      /**
23651
       * Find the _Fields constant that matches name, or null if its not found.
23652
       */
23653
      public static _Fields findByName(String name) {
23654
        return byName.get(name);
23655
      }
23656
 
23657
      private final short _thriftId;
23658
      private final String _fieldName;
23659
 
23660
      _Fields(short thriftId, String fieldName) {
23661
        _thriftId = thriftId;
23662
        _fieldName = fieldName;
23663
      }
23664
 
23665
      public short getThriftFieldId() {
23666
        return _thriftId;
23667
      }
23668
 
23669
      public String getFieldName() {
23670
        return _fieldName;
23671
      }
23672
    }
23673
 
23674
    // isset id assignments
23675
 
23676
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23677
    static {
23678
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23679
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23680
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
23681
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
23682
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23683
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShippingLocations_result.class, metaDataMap);
23684
    }
23685
 
23686
    public getShippingLocations_result() {
23687
    }
23688
 
23689
    public getShippingLocations_result(
23690
      List<Warehouse> success)
23691
    {
23692
      this();
23693
      this.success = success;
23694
    }
23695
 
23696
    /**
23697
     * Performs a deep copy on <i>other</i>.
23698
     */
23699
    public getShippingLocations_result(getShippingLocations_result other) {
23700
      if (other.isSetSuccess()) {
23701
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
23702
        for (Warehouse other_element : other.success) {
23703
          __this__success.add(new Warehouse(other_element));
23704
        }
23705
        this.success = __this__success;
23706
      }
23707
    }
23708
 
23709
    public getShippingLocations_result deepCopy() {
23710
      return new getShippingLocations_result(this);
23711
    }
23712
 
23713
    @Override
23714
    public void clear() {
23715
      this.success = null;
23716
    }
23717
 
23718
    public int getSuccessSize() {
23719
      return (this.success == null) ? 0 : this.success.size();
23720
    }
23721
 
23722
    public java.util.Iterator<Warehouse> getSuccessIterator() {
23723
      return (this.success == null) ? null : this.success.iterator();
23724
    }
23725
 
23726
    public void addToSuccess(Warehouse elem) {
23727
      if (this.success == null) {
23728
        this.success = new ArrayList<Warehouse>();
23729
      }
23730
      this.success.add(elem);
23731
    }
23732
 
23733
    public List<Warehouse> getSuccess() {
23734
      return this.success;
23735
    }
23736
 
23737
    public void setSuccess(List<Warehouse> success) {
23738
      this.success = success;
23739
    }
23740
 
23741
    public void unsetSuccess() {
23742
      this.success = null;
23743
    }
23744
 
23745
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
23746
    public boolean isSetSuccess() {
23747
      return this.success != null;
23748
    }
23749
 
23750
    public void setSuccessIsSet(boolean value) {
23751
      if (!value) {
23752
        this.success = null;
23753
      }
23754
    }
23755
 
23756
    public void setFieldValue(_Fields field, Object value) {
23757
      switch (field) {
23758
      case SUCCESS:
23759
        if (value == null) {
23760
          unsetSuccess();
23761
        } else {
23762
          setSuccess((List<Warehouse>)value);
23763
        }
23764
        break;
23765
 
23766
      }
23767
    }
23768
 
23769
    public Object getFieldValue(_Fields field) {
23770
      switch (field) {
23771
      case SUCCESS:
23772
        return getSuccess();
23773
 
23774
      }
23775
      throw new IllegalStateException();
23776
    }
23777
 
23778
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23779
    public boolean isSet(_Fields field) {
23780
      if (field == null) {
23781
        throw new IllegalArgumentException();
23782
      }
23783
 
23784
      switch (field) {
23785
      case SUCCESS:
23786
        return isSetSuccess();
23787
      }
23788
      throw new IllegalStateException();
23789
    }
23790
 
23791
    @Override
23792
    public boolean equals(Object that) {
23793
      if (that == null)
23794
        return false;
23795
      if (that instanceof getShippingLocations_result)
23796
        return this.equals((getShippingLocations_result)that);
23797
      return false;
23798
    }
23799
 
23800
    public boolean equals(getShippingLocations_result that) {
23801
      if (that == null)
23802
        return false;
23803
 
23804
      boolean this_present_success = true && this.isSetSuccess();
23805
      boolean that_present_success = true && that.isSetSuccess();
23806
      if (this_present_success || that_present_success) {
23807
        if (!(this_present_success && that_present_success))
23808
          return false;
23809
        if (!this.success.equals(that.success))
23810
          return false;
23811
      }
23812
 
23813
      return true;
23814
    }
23815
 
23816
    @Override
23817
    public int hashCode() {
23818
      return 0;
23819
    }
23820
 
23821
    public int compareTo(getShippingLocations_result other) {
23822
      if (!getClass().equals(other.getClass())) {
23823
        return getClass().getName().compareTo(other.getClass().getName());
23824
      }
23825
 
23826
      int lastComparison = 0;
23827
      getShippingLocations_result typedOther = (getShippingLocations_result)other;
23828
 
23829
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
23830
      if (lastComparison != 0) {
23831
        return lastComparison;
23832
      }
23833
      if (isSetSuccess()) {
23834
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
23835
        if (lastComparison != 0) {
23836
          return lastComparison;
23837
        }
23838
      }
23839
      return 0;
23840
    }
23841
 
23842
    public _Fields fieldForId(int fieldId) {
23843
      return _Fields.findByThriftId(fieldId);
23844
    }
23845
 
23846
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23847
      org.apache.thrift.protocol.TField field;
23848
      iprot.readStructBegin();
23849
      while (true)
23850
      {
23851
        field = iprot.readFieldBegin();
23852
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23853
          break;
23854
        }
23855
        switch (field.id) {
23856
          case 0: // SUCCESS
23857
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
23858
              {
23859
                org.apache.thrift.protocol.TList _list66 = iprot.readListBegin();
23860
                this.success = new ArrayList<Warehouse>(_list66.size);
23861
                for (int _i67 = 0; _i67 < _list66.size; ++_i67)
23862
                {
23863
                  Warehouse _elem68; // required
23864
                  _elem68 = new Warehouse();
23865
                  _elem68.read(iprot);
23866
                  this.success.add(_elem68);
23867
                }
23868
                iprot.readListEnd();
23869
              }
23870
            } else { 
23871
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23872
            }
23873
            break;
23874
          default:
23875
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23876
        }
23877
        iprot.readFieldEnd();
23878
      }
23879
      iprot.readStructEnd();
23880
      validate();
23881
    }
23882
 
23883
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23884
      oprot.writeStructBegin(STRUCT_DESC);
23885
 
23886
      if (this.isSetSuccess()) {
23887
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
23888
        {
23889
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
23890
          for (Warehouse _iter69 : this.success)
23891
          {
23892
            _iter69.write(oprot);
23893
          }
23894
          oprot.writeListEnd();
23895
        }
23896
        oprot.writeFieldEnd();
23897
      }
23898
      oprot.writeFieldStop();
23899
      oprot.writeStructEnd();
23900
    }
23901
 
23902
    @Override
23903
    public String toString() {
23904
      StringBuilder sb = new StringBuilder("getShippingLocations_result(");
23905
      boolean first = true;
23906
 
23907
      sb.append("success:");
23908
      if (this.success == null) {
23909
        sb.append("null");
23910
      } else {
23911
        sb.append(this.success);
23912
      }
23913
      first = false;
23914
      sb.append(")");
23915
      return sb.toString();
23916
    }
23917
 
23918
    public void validate() throws org.apache.thrift.TException {
23919
      // check for required fields
23920
    }
23921
 
23922
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23923
      try {
23924
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23925
      } catch (org.apache.thrift.TException te) {
23926
        throw new java.io.IOException(te);
23927
      }
23928
    }
23929
 
23930
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23931
      try {
23932
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23933
      } catch (org.apache.thrift.TException te) {
23934
        throw new java.io.IOException(te);
23935
      }
23936
    }
23937
 
23938
  }
23939
 
23940
  public static class getAllVendorItemMappings_args implements org.apache.thrift.TBase<getAllVendorItemMappings_args, getAllVendorItemMappings_args._Fields>, java.io.Serializable, Cloneable   {
23941
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendorItemMappings_args");
23942
 
23943
 
23944
 
23945
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23946
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23947
;
23948
 
23949
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23950
 
23951
      static {
23952
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23953
          byName.put(field.getFieldName(), field);
23954
        }
23955
      }
23956
 
23957
      /**
23958
       * Find the _Fields constant that matches fieldId, or null if its not found.
23959
       */
23960
      public static _Fields findByThriftId(int fieldId) {
23961
        switch(fieldId) {
23962
          default:
23963
            return null;
23964
        }
23965
      }
23966
 
23967
      /**
23968
       * Find the _Fields constant that matches fieldId, throwing an exception
23969
       * if it is not found.
23970
       */
23971
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23972
        _Fields fields = findByThriftId(fieldId);
23973
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23974
        return fields;
23975
      }
23976
 
23977
      /**
23978
       * Find the _Fields constant that matches name, or null if its not found.
23979
       */
23980
      public static _Fields findByName(String name) {
23981
        return byName.get(name);
23982
      }
23983
 
23984
      private final short _thriftId;
23985
      private final String _fieldName;
23986
 
23987
      _Fields(short thriftId, String fieldName) {
23988
        _thriftId = thriftId;
23989
        _fieldName = fieldName;
23990
      }
23991
 
23992
      public short getThriftFieldId() {
23993
        return _thriftId;
23994
      }
23995
 
23996
      public String getFieldName() {
23997
        return _fieldName;
23998
      }
23999
    }
24000
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24001
    static {
24002
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24003
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24004
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendorItemMappings_args.class, metaDataMap);
24005
    }
24006
 
24007
    public getAllVendorItemMappings_args() {
24008
    }
24009
 
24010
    /**
24011
     * Performs a deep copy on <i>other</i>.
24012
     */
24013
    public getAllVendorItemMappings_args(getAllVendorItemMappings_args other) {
24014
    }
24015
 
24016
    public getAllVendorItemMappings_args deepCopy() {
24017
      return new getAllVendorItemMappings_args(this);
24018
    }
24019
 
24020
    @Override
24021
    public void clear() {
24022
    }
24023
 
24024
    public void setFieldValue(_Fields field, Object value) {
24025
      switch (field) {
24026
      }
24027
    }
24028
 
24029
    public Object getFieldValue(_Fields field) {
24030
      switch (field) {
24031
      }
24032
      throw new IllegalStateException();
24033
    }
24034
 
24035
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24036
    public boolean isSet(_Fields field) {
24037
      if (field == null) {
24038
        throw new IllegalArgumentException();
24039
      }
24040
 
24041
      switch (field) {
24042
      }
24043
      throw new IllegalStateException();
24044
    }
24045
 
24046
    @Override
24047
    public boolean equals(Object that) {
24048
      if (that == null)
24049
        return false;
24050
      if (that instanceof getAllVendorItemMappings_args)
24051
        return this.equals((getAllVendorItemMappings_args)that);
24052
      return false;
24053
    }
24054
 
24055
    public boolean equals(getAllVendorItemMappings_args that) {
24056
      if (that == null)
24057
        return false;
24058
 
24059
      return true;
24060
    }
24061
 
24062
    @Override
24063
    public int hashCode() {
24064
      return 0;
24065
    }
24066
 
24067
    public int compareTo(getAllVendorItemMappings_args other) {
24068
      if (!getClass().equals(other.getClass())) {
24069
        return getClass().getName().compareTo(other.getClass().getName());
24070
      }
24071
 
24072
      int lastComparison = 0;
24073
      getAllVendorItemMappings_args typedOther = (getAllVendorItemMappings_args)other;
24074
 
24075
      return 0;
24076
    }
24077
 
24078
    public _Fields fieldForId(int fieldId) {
24079
      return _Fields.findByThriftId(fieldId);
24080
    }
24081
 
24082
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24083
      org.apache.thrift.protocol.TField field;
24084
      iprot.readStructBegin();
24085
      while (true)
24086
      {
24087
        field = iprot.readFieldBegin();
24088
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24089
          break;
24090
        }
24091
        switch (field.id) {
24092
          default:
24093
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24094
        }
24095
        iprot.readFieldEnd();
24096
      }
24097
      iprot.readStructEnd();
24098
      validate();
24099
    }
24100
 
24101
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24102
      validate();
24103
 
24104
      oprot.writeStructBegin(STRUCT_DESC);
24105
      oprot.writeFieldStop();
24106
      oprot.writeStructEnd();
24107
    }
24108
 
24109
    @Override
24110
    public String toString() {
24111
      StringBuilder sb = new StringBuilder("getAllVendorItemMappings_args(");
24112
      boolean first = true;
24113
 
24114
      sb.append(")");
24115
      return sb.toString();
24116
    }
24117
 
24118
    public void validate() throws org.apache.thrift.TException {
24119
      // check for required fields
24120
    }
24121
 
24122
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24123
      try {
24124
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24125
      } catch (org.apache.thrift.TException te) {
24126
        throw new java.io.IOException(te);
24127
      }
24128
    }
24129
 
24130
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24131
      try {
24132
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24133
      } catch (org.apache.thrift.TException te) {
24134
        throw new java.io.IOException(te);
24135
      }
24136
    }
24137
 
24138
  }
24139
 
24140
  public static class getAllVendorItemMappings_result implements org.apache.thrift.TBase<getAllVendorItemMappings_result, getAllVendorItemMappings_result._Fields>, java.io.Serializable, Cloneable   {
24141
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendorItemMappings_result");
24142
 
24143
    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);
24144
 
24145
    private List<VendorItemMapping> success; // required
24146
 
24147
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24148
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24149
      SUCCESS((short)0, "success");
24150
 
24151
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24152
 
24153
      static {
24154
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24155
          byName.put(field.getFieldName(), field);
24156
        }
24157
      }
24158
 
24159
      /**
24160
       * Find the _Fields constant that matches fieldId, or null if its not found.
24161
       */
24162
      public static _Fields findByThriftId(int fieldId) {
24163
        switch(fieldId) {
24164
          case 0: // SUCCESS
24165
            return SUCCESS;
24166
          default:
24167
            return null;
24168
        }
24169
      }
24170
 
24171
      /**
24172
       * Find the _Fields constant that matches fieldId, throwing an exception
24173
       * if it is not found.
24174
       */
24175
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24176
        _Fields fields = findByThriftId(fieldId);
24177
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24178
        return fields;
24179
      }
24180
 
24181
      /**
24182
       * Find the _Fields constant that matches name, or null if its not found.
24183
       */
24184
      public static _Fields findByName(String name) {
24185
        return byName.get(name);
24186
      }
24187
 
24188
      private final short _thriftId;
24189
      private final String _fieldName;
24190
 
24191
      _Fields(short thriftId, String fieldName) {
24192
        _thriftId = thriftId;
24193
        _fieldName = fieldName;
24194
      }
24195
 
24196
      public short getThriftFieldId() {
24197
        return _thriftId;
24198
      }
24199
 
24200
      public String getFieldName() {
24201
        return _fieldName;
24202
      }
24203
    }
24204
 
24205
    // isset id assignments
24206
 
24207
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24208
    static {
24209
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24210
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24211
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
24212
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class))));
24213
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24214
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendorItemMappings_result.class, metaDataMap);
24215
    }
24216
 
24217
    public getAllVendorItemMappings_result() {
24218
    }
24219
 
24220
    public getAllVendorItemMappings_result(
24221
      List<VendorItemMapping> success)
24222
    {
24223
      this();
24224
      this.success = success;
24225
    }
24226
 
24227
    /**
24228
     * Performs a deep copy on <i>other</i>.
24229
     */
24230
    public getAllVendorItemMappings_result(getAllVendorItemMappings_result other) {
24231
      if (other.isSetSuccess()) {
24232
        List<VendorItemMapping> __this__success = new ArrayList<VendorItemMapping>();
24233
        for (VendorItemMapping other_element : other.success) {
24234
          __this__success.add(new VendorItemMapping(other_element));
24235
        }
24236
        this.success = __this__success;
24237
      }
24238
    }
24239
 
24240
    public getAllVendorItemMappings_result deepCopy() {
24241
      return new getAllVendorItemMappings_result(this);
24242
    }
24243
 
24244
    @Override
24245
    public void clear() {
24246
      this.success = null;
24247
    }
24248
 
24249
    public int getSuccessSize() {
24250
      return (this.success == null) ? 0 : this.success.size();
24251
    }
24252
 
24253
    public java.util.Iterator<VendorItemMapping> getSuccessIterator() {
24254
      return (this.success == null) ? null : this.success.iterator();
24255
    }
24256
 
24257
    public void addToSuccess(VendorItemMapping elem) {
24258
      if (this.success == null) {
24259
        this.success = new ArrayList<VendorItemMapping>();
24260
      }
24261
      this.success.add(elem);
24262
    }
24263
 
24264
    public List<VendorItemMapping> getSuccess() {
24265
      return this.success;
24266
    }
24267
 
24268
    public void setSuccess(List<VendorItemMapping> success) {
24269
      this.success = success;
24270
    }
24271
 
24272
    public void unsetSuccess() {
24273
      this.success = null;
24274
    }
24275
 
24276
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
24277
    public boolean isSetSuccess() {
24278
      return this.success != null;
24279
    }
24280
 
24281
    public void setSuccessIsSet(boolean value) {
24282
      if (!value) {
24283
        this.success = null;
24284
      }
24285
    }
24286
 
24287
    public void setFieldValue(_Fields field, Object value) {
24288
      switch (field) {
24289
      case SUCCESS:
24290
        if (value == null) {
24291
          unsetSuccess();
24292
        } else {
24293
          setSuccess((List<VendorItemMapping>)value);
24294
        }
24295
        break;
24296
 
24297
      }
24298
    }
24299
 
24300
    public Object getFieldValue(_Fields field) {
24301
      switch (field) {
24302
      case SUCCESS:
24303
        return getSuccess();
24304
 
24305
      }
24306
      throw new IllegalStateException();
24307
    }
24308
 
24309
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24310
    public boolean isSet(_Fields field) {
24311
      if (field == null) {
24312
        throw new IllegalArgumentException();
24313
      }
24314
 
24315
      switch (field) {
24316
      case SUCCESS:
24317
        return isSetSuccess();
24318
      }
24319
      throw new IllegalStateException();
24320
    }
24321
 
24322
    @Override
24323
    public boolean equals(Object that) {
24324
      if (that == null)
24325
        return false;
24326
      if (that instanceof getAllVendorItemMappings_result)
24327
        return this.equals((getAllVendorItemMappings_result)that);
24328
      return false;
24329
    }
24330
 
24331
    public boolean equals(getAllVendorItemMappings_result that) {
24332
      if (that == null)
24333
        return false;
24334
 
24335
      boolean this_present_success = true && this.isSetSuccess();
24336
      boolean that_present_success = true && that.isSetSuccess();
24337
      if (this_present_success || that_present_success) {
24338
        if (!(this_present_success && that_present_success))
24339
          return false;
24340
        if (!this.success.equals(that.success))
24341
          return false;
24342
      }
24343
 
24344
      return true;
24345
    }
24346
 
24347
    @Override
24348
    public int hashCode() {
24349
      return 0;
24350
    }
24351
 
24352
    public int compareTo(getAllVendorItemMappings_result other) {
24353
      if (!getClass().equals(other.getClass())) {
24354
        return getClass().getName().compareTo(other.getClass().getName());
24355
      }
24356
 
24357
      int lastComparison = 0;
24358
      getAllVendorItemMappings_result typedOther = (getAllVendorItemMappings_result)other;
24359
 
24360
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
24361
      if (lastComparison != 0) {
24362
        return lastComparison;
24363
      }
24364
      if (isSetSuccess()) {
24365
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
24366
        if (lastComparison != 0) {
24367
          return lastComparison;
24368
        }
24369
      }
24370
      return 0;
24371
    }
24372
 
24373
    public _Fields fieldForId(int fieldId) {
24374
      return _Fields.findByThriftId(fieldId);
24375
    }
24376
 
24377
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24378
      org.apache.thrift.protocol.TField field;
24379
      iprot.readStructBegin();
24380
      while (true)
24381
      {
24382
        field = iprot.readFieldBegin();
24383
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24384
          break;
24385
        }
24386
        switch (field.id) {
24387
          case 0: // SUCCESS
24388
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
24389
              {
24390
                org.apache.thrift.protocol.TList _list70 = iprot.readListBegin();
24391
                this.success = new ArrayList<VendorItemMapping>(_list70.size);
24392
                for (int _i71 = 0; _i71 < _list70.size; ++_i71)
24393
                {
24394
                  VendorItemMapping _elem72; // required
24395
                  _elem72 = new VendorItemMapping();
24396
                  _elem72.read(iprot);
24397
                  this.success.add(_elem72);
24398
                }
24399
                iprot.readListEnd();
24400
              }
24401
            } else { 
24402
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24403
            }
24404
            break;
24405
          default:
24406
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24407
        }
24408
        iprot.readFieldEnd();
24409
      }
24410
      iprot.readStructEnd();
24411
      validate();
24412
    }
24413
 
24414
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24415
      oprot.writeStructBegin(STRUCT_DESC);
24416
 
24417
      if (this.isSetSuccess()) {
24418
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
24419
        {
24420
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
24421
          for (VendorItemMapping _iter73 : this.success)
24422
          {
24423
            _iter73.write(oprot);
24424
          }
24425
          oprot.writeListEnd();
24426
        }
24427
        oprot.writeFieldEnd();
24428
      }
24429
      oprot.writeFieldStop();
24430
      oprot.writeStructEnd();
24431
    }
24432
 
24433
    @Override
24434
    public String toString() {
24435
      StringBuilder sb = new StringBuilder("getAllVendorItemMappings_result(");
24436
      boolean first = true;
24437
 
24438
      sb.append("success:");
24439
      if (this.success == null) {
24440
        sb.append("null");
24441
      } else {
24442
        sb.append(this.success);
24443
      }
24444
      first = false;
24445
      sb.append(")");
24446
      return sb.toString();
24447
    }
24448
 
24449
    public void validate() throws org.apache.thrift.TException {
24450
      // check for required fields
24451
    }
24452
 
24453
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24454
      try {
24455
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24456
      } catch (org.apache.thrift.TException te) {
24457
        throw new java.io.IOException(te);
24458
      }
24459
    }
24460
 
24461
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24462
      try {
24463
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24464
      } catch (org.apache.thrift.TException te) {
24465
        throw new java.io.IOException(te);
24466
      }
24467
    }
24468
 
24469
  }
24470
 
24471
  public static class getInventorySnapshot_args implements org.apache.thrift.TBase<getInventorySnapshot_args, getInventorySnapshot_args._Fields>, java.io.Serializable, Cloneable   {
24472
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventorySnapshot_args");
24473
 
24474
    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);
24475
 
24476
    private long warehouseId; // required
24477
 
24478
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24479
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24480
      WAREHOUSE_ID((short)1, "warehouseId");
24481
 
24482
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24483
 
24484
      static {
24485
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24486
          byName.put(field.getFieldName(), field);
24487
        }
24488
      }
24489
 
24490
      /**
24491
       * Find the _Fields constant that matches fieldId, or null if its not found.
24492
       */
24493
      public static _Fields findByThriftId(int fieldId) {
24494
        switch(fieldId) {
24495
          case 1: // WAREHOUSE_ID
24496
            return WAREHOUSE_ID;
24497
          default:
24498
            return null;
24499
        }
24500
      }
24501
 
24502
      /**
24503
       * Find the _Fields constant that matches fieldId, throwing an exception
24504
       * if it is not found.
24505
       */
24506
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24507
        _Fields fields = findByThriftId(fieldId);
24508
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24509
        return fields;
24510
      }
24511
 
24512
      /**
24513
       * Find the _Fields constant that matches name, or null if its not found.
24514
       */
24515
      public static _Fields findByName(String name) {
24516
        return byName.get(name);
24517
      }
24518
 
24519
      private final short _thriftId;
24520
      private final String _fieldName;
24521
 
24522
      _Fields(short thriftId, String fieldName) {
24523
        _thriftId = thriftId;
24524
        _fieldName = fieldName;
24525
      }
24526
 
24527
      public short getThriftFieldId() {
24528
        return _thriftId;
24529
      }
24530
 
24531
      public String getFieldName() {
24532
        return _fieldName;
24533
      }
24534
    }
24535
 
24536
    // isset id assignments
24537
    private static final int __WAREHOUSEID_ISSET_ID = 0;
24538
    private BitSet __isset_bit_vector = new BitSet(1);
24539
 
24540
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24541
    static {
24542
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24543
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24544
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24545
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24546
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventorySnapshot_args.class, metaDataMap);
24547
    }
24548
 
24549
    public getInventorySnapshot_args() {
24550
    }
24551
 
24552
    public getInventorySnapshot_args(
24553
      long warehouseId)
24554
    {
24555
      this();
24556
      this.warehouseId = warehouseId;
24557
      setWarehouseIdIsSet(true);
24558
    }
24559
 
24560
    /**
24561
     * Performs a deep copy on <i>other</i>.
24562
     */
24563
    public getInventorySnapshot_args(getInventorySnapshot_args other) {
24564
      __isset_bit_vector.clear();
24565
      __isset_bit_vector.or(other.__isset_bit_vector);
24566
      this.warehouseId = other.warehouseId;
24567
    }
24568
 
24569
    public getInventorySnapshot_args deepCopy() {
24570
      return new getInventorySnapshot_args(this);
24571
    }
24572
 
24573
    @Override
24574
    public void clear() {
24575
      setWarehouseIdIsSet(false);
24576
      this.warehouseId = 0;
24577
    }
24578
 
24579
    public long getWarehouseId() {
24580
      return this.warehouseId;
24581
    }
24582
 
24583
    public void setWarehouseId(long warehouseId) {
24584
      this.warehouseId = warehouseId;
24585
      setWarehouseIdIsSet(true);
24586
    }
24587
 
24588
    public void unsetWarehouseId() {
24589
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
24590
    }
24591
 
24592
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
24593
    public boolean isSetWarehouseId() {
24594
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
24595
    }
24596
 
24597
    public void setWarehouseIdIsSet(boolean value) {
24598
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
24599
    }
24600
 
24601
    public void setFieldValue(_Fields field, Object value) {
24602
      switch (field) {
24603
      case WAREHOUSE_ID:
24604
        if (value == null) {
24605
          unsetWarehouseId();
24606
        } else {
24607
          setWarehouseId((Long)value);
24608
        }
24609
        break;
24610
 
24611
      }
24612
    }
24613
 
24614
    public Object getFieldValue(_Fields field) {
24615
      switch (field) {
24616
      case WAREHOUSE_ID:
24617
        return Long.valueOf(getWarehouseId());
24618
 
24619
      }
24620
      throw new IllegalStateException();
24621
    }
24622
 
24623
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24624
    public boolean isSet(_Fields field) {
24625
      if (field == null) {
24626
        throw new IllegalArgumentException();
24627
      }
24628
 
24629
      switch (field) {
24630
      case WAREHOUSE_ID:
24631
        return isSetWarehouseId();
24632
      }
24633
      throw new IllegalStateException();
24634
    }
24635
 
24636
    @Override
24637
    public boolean equals(Object that) {
24638
      if (that == null)
24639
        return false;
24640
      if (that instanceof getInventorySnapshot_args)
24641
        return this.equals((getInventorySnapshot_args)that);
24642
      return false;
24643
    }
24644
 
24645
    public boolean equals(getInventorySnapshot_args that) {
24646
      if (that == null)
24647
        return false;
24648
 
24649
      boolean this_present_warehouseId = true;
24650
      boolean that_present_warehouseId = true;
24651
      if (this_present_warehouseId || that_present_warehouseId) {
24652
        if (!(this_present_warehouseId && that_present_warehouseId))
24653
          return false;
24654
        if (this.warehouseId != that.warehouseId)
24655
          return false;
24656
      }
24657
 
24658
      return true;
24659
    }
24660
 
24661
    @Override
24662
    public int hashCode() {
24663
      return 0;
24664
    }
24665
 
24666
    public int compareTo(getInventorySnapshot_args other) {
24667
      if (!getClass().equals(other.getClass())) {
24668
        return getClass().getName().compareTo(other.getClass().getName());
24669
      }
24670
 
24671
      int lastComparison = 0;
24672
      getInventorySnapshot_args typedOther = (getInventorySnapshot_args)other;
24673
 
24674
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
24675
      if (lastComparison != 0) {
24676
        return lastComparison;
24677
      }
24678
      if (isSetWarehouseId()) {
24679
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
24680
        if (lastComparison != 0) {
24681
          return lastComparison;
24682
        }
24683
      }
24684
      return 0;
24685
    }
24686
 
24687
    public _Fields fieldForId(int fieldId) {
24688
      return _Fields.findByThriftId(fieldId);
24689
    }
24690
 
24691
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24692
      org.apache.thrift.protocol.TField field;
24693
      iprot.readStructBegin();
24694
      while (true)
24695
      {
24696
        field = iprot.readFieldBegin();
24697
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24698
          break;
24699
        }
24700
        switch (field.id) {
24701
          case 1: // WAREHOUSE_ID
24702
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24703
              this.warehouseId = iprot.readI64();
24704
              setWarehouseIdIsSet(true);
24705
            } else { 
24706
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24707
            }
24708
            break;
24709
          default:
24710
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24711
        }
24712
        iprot.readFieldEnd();
24713
      }
24714
      iprot.readStructEnd();
24715
      validate();
24716
    }
24717
 
24718
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24719
      validate();
24720
 
24721
      oprot.writeStructBegin(STRUCT_DESC);
24722
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
24723
      oprot.writeI64(this.warehouseId);
24724
      oprot.writeFieldEnd();
24725
      oprot.writeFieldStop();
24726
      oprot.writeStructEnd();
24727
    }
24728
 
24729
    @Override
24730
    public String toString() {
24731
      StringBuilder sb = new StringBuilder("getInventorySnapshot_args(");
24732
      boolean first = true;
24733
 
24734
      sb.append("warehouseId:");
24735
      sb.append(this.warehouseId);
24736
      first = false;
24737
      sb.append(")");
24738
      return sb.toString();
24739
    }
24740
 
24741
    public void validate() throws org.apache.thrift.TException {
24742
      // check for required fields
24743
    }
24744
 
24745
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24746
      try {
24747
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24748
      } catch (org.apache.thrift.TException te) {
24749
        throw new java.io.IOException(te);
24750
      }
24751
    }
24752
 
24753
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24754
      try {
24755
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
24756
        __isset_bit_vector = new BitSet(1);
24757
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24758
      } catch (org.apache.thrift.TException te) {
24759
        throw new java.io.IOException(te);
24760
      }
24761
    }
24762
 
24763
  }
24764
 
24765
  public static class getInventorySnapshot_result implements org.apache.thrift.TBase<getInventorySnapshot_result, getInventorySnapshot_result._Fields>, java.io.Serializable, Cloneable   {
24766
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventorySnapshot_result");
24767
 
24768
    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);
24769
 
24770
    private Map<Long,ItemInventory> success; // required
24771
 
24772
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24773
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24774
      SUCCESS((short)0, "success");
24775
 
24776
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24777
 
24778
      static {
24779
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24780
          byName.put(field.getFieldName(), field);
24781
        }
24782
      }
24783
 
24784
      /**
24785
       * Find the _Fields constant that matches fieldId, or null if its not found.
24786
       */
24787
      public static _Fields findByThriftId(int fieldId) {
24788
        switch(fieldId) {
24789
          case 0: // SUCCESS
24790
            return SUCCESS;
24791
          default:
24792
            return null;
24793
        }
24794
      }
24795
 
24796
      /**
24797
       * Find the _Fields constant that matches fieldId, throwing an exception
24798
       * if it is not found.
24799
       */
24800
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24801
        _Fields fields = findByThriftId(fieldId);
24802
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24803
        return fields;
24804
      }
24805
 
24806
      /**
24807
       * Find the _Fields constant that matches name, or null if its not found.
24808
       */
24809
      public static _Fields findByName(String name) {
24810
        return byName.get(name);
24811
      }
24812
 
24813
      private final short _thriftId;
24814
      private final String _fieldName;
24815
 
24816
      _Fields(short thriftId, String fieldName) {
24817
        _thriftId = thriftId;
24818
        _fieldName = fieldName;
24819
      }
24820
 
24821
      public short getThriftFieldId() {
24822
        return _thriftId;
24823
      }
24824
 
24825
      public String getFieldName() {
24826
        return _fieldName;
24827
      }
24828
    }
24829
 
24830
    // isset id assignments
24831
 
24832
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24833
    static {
24834
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24835
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24836
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
24837
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
24838
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ItemInventory.class))));
24839
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24840
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventorySnapshot_result.class, metaDataMap);
24841
    }
24842
 
24843
    public getInventorySnapshot_result() {
24844
    }
24845
 
24846
    public getInventorySnapshot_result(
24847
      Map<Long,ItemInventory> success)
24848
    {
24849
      this();
24850
      this.success = success;
24851
    }
24852
 
24853
    /**
24854
     * Performs a deep copy on <i>other</i>.
24855
     */
24856
    public getInventorySnapshot_result(getInventorySnapshot_result other) {
24857
      if (other.isSetSuccess()) {
24858
        Map<Long,ItemInventory> __this__success = new HashMap<Long,ItemInventory>();
24859
        for (Map.Entry<Long, ItemInventory> other_element : other.success.entrySet()) {
24860
 
24861
          Long other_element_key = other_element.getKey();
24862
          ItemInventory other_element_value = other_element.getValue();
24863
 
24864
          Long __this__success_copy_key = other_element_key;
24865
 
24866
          ItemInventory __this__success_copy_value = new ItemInventory(other_element_value);
24867
 
24868
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
24869
        }
24870
        this.success = __this__success;
24871
      }
24872
    }
24873
 
24874
    public getInventorySnapshot_result deepCopy() {
24875
      return new getInventorySnapshot_result(this);
24876
    }
24877
 
24878
    @Override
24879
    public void clear() {
24880
      this.success = null;
24881
    }
24882
 
24883
    public int getSuccessSize() {
24884
      return (this.success == null) ? 0 : this.success.size();
24885
    }
24886
 
24887
    public void putToSuccess(long key, ItemInventory val) {
24888
      if (this.success == null) {
24889
        this.success = new HashMap<Long,ItemInventory>();
24890
      }
24891
      this.success.put(key, val);
24892
    }
24893
 
24894
    public Map<Long,ItemInventory> getSuccess() {
24895
      return this.success;
24896
    }
24897
 
24898
    public void setSuccess(Map<Long,ItemInventory> success) {
24899
      this.success = success;
24900
    }
24901
 
24902
    public void unsetSuccess() {
24903
      this.success = null;
24904
    }
24905
 
24906
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
24907
    public boolean isSetSuccess() {
24908
      return this.success != null;
24909
    }
24910
 
24911
    public void setSuccessIsSet(boolean value) {
24912
      if (!value) {
24913
        this.success = null;
24914
      }
24915
    }
24916
 
24917
    public void setFieldValue(_Fields field, Object value) {
24918
      switch (field) {
24919
      case SUCCESS:
24920
        if (value == null) {
24921
          unsetSuccess();
24922
        } else {
24923
          setSuccess((Map<Long,ItemInventory>)value);
24924
        }
24925
        break;
24926
 
24927
      }
24928
    }
24929
 
24930
    public Object getFieldValue(_Fields field) {
24931
      switch (field) {
24932
      case SUCCESS:
24933
        return getSuccess();
24934
 
24935
      }
24936
      throw new IllegalStateException();
24937
    }
24938
 
24939
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24940
    public boolean isSet(_Fields field) {
24941
      if (field == null) {
24942
        throw new IllegalArgumentException();
24943
      }
24944
 
24945
      switch (field) {
24946
      case SUCCESS:
24947
        return isSetSuccess();
24948
      }
24949
      throw new IllegalStateException();
24950
    }
24951
 
24952
    @Override
24953
    public boolean equals(Object that) {
24954
      if (that == null)
24955
        return false;
24956
      if (that instanceof getInventorySnapshot_result)
24957
        return this.equals((getInventorySnapshot_result)that);
24958
      return false;
24959
    }
24960
 
24961
    public boolean equals(getInventorySnapshot_result that) {
24962
      if (that == null)
24963
        return false;
24964
 
24965
      boolean this_present_success = true && this.isSetSuccess();
24966
      boolean that_present_success = true && that.isSetSuccess();
24967
      if (this_present_success || that_present_success) {
24968
        if (!(this_present_success && that_present_success))
24969
          return false;
24970
        if (!this.success.equals(that.success))
24971
          return false;
24972
      }
24973
 
24974
      return true;
24975
    }
24976
 
24977
    @Override
24978
    public int hashCode() {
24979
      return 0;
24980
    }
24981
 
24982
    public int compareTo(getInventorySnapshot_result other) {
24983
      if (!getClass().equals(other.getClass())) {
24984
        return getClass().getName().compareTo(other.getClass().getName());
24985
      }
24986
 
24987
      int lastComparison = 0;
24988
      getInventorySnapshot_result typedOther = (getInventorySnapshot_result)other;
24989
 
24990
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
24991
      if (lastComparison != 0) {
24992
        return lastComparison;
24993
      }
24994
      if (isSetSuccess()) {
24995
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
24996
        if (lastComparison != 0) {
24997
          return lastComparison;
24998
        }
24999
      }
25000
      return 0;
25001
    }
25002
 
25003
    public _Fields fieldForId(int fieldId) {
25004
      return _Fields.findByThriftId(fieldId);
25005
    }
25006
 
25007
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25008
      org.apache.thrift.protocol.TField field;
25009
      iprot.readStructBegin();
25010
      while (true)
25011
      {
25012
        field = iprot.readFieldBegin();
25013
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25014
          break;
25015
        }
25016
        switch (field.id) {
25017
          case 0: // SUCCESS
25018
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
25019
              {
25020
                org.apache.thrift.protocol.TMap _map74 = iprot.readMapBegin();
25021
                this.success = new HashMap<Long,ItemInventory>(2*_map74.size);
25022
                for (int _i75 = 0; _i75 < _map74.size; ++_i75)
25023
                {
25024
                  long _key76; // required
25025
                  ItemInventory _val77; // required
25026
                  _key76 = iprot.readI64();
25027
                  _val77 = new ItemInventory();
25028
                  _val77.read(iprot);
25029
                  this.success.put(_key76, _val77);
25030
                }
25031
                iprot.readMapEnd();
25032
              }
25033
            } else { 
25034
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25035
            }
25036
            break;
25037
          default:
25038
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25039
        }
25040
        iprot.readFieldEnd();
25041
      }
25042
      iprot.readStructEnd();
25043
      validate();
25044
    }
25045
 
25046
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25047
      oprot.writeStructBegin(STRUCT_DESC);
25048
 
25049
      if (this.isSetSuccess()) {
25050
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
25051
        {
25052
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
25053
          for (Map.Entry<Long, ItemInventory> _iter78 : this.success.entrySet())
25054
          {
25055
            oprot.writeI64(_iter78.getKey());
25056
            _iter78.getValue().write(oprot);
25057
          }
25058
          oprot.writeMapEnd();
25059
        }
25060
        oprot.writeFieldEnd();
25061
      }
25062
      oprot.writeFieldStop();
25063
      oprot.writeStructEnd();
25064
    }
25065
 
25066
    @Override
25067
    public String toString() {
25068
      StringBuilder sb = new StringBuilder("getInventorySnapshot_result(");
25069
      boolean first = true;
25070
 
25071
      sb.append("success:");
25072
      if (this.success == null) {
25073
        sb.append("null");
25074
      } else {
25075
        sb.append(this.success);
25076
      }
25077
      first = false;
25078
      sb.append(")");
25079
      return sb.toString();
25080
    }
25081
 
25082
    public void validate() throws org.apache.thrift.TException {
25083
      // check for required fields
25084
    }
25085
 
25086
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25087
      try {
25088
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25089
      } catch (org.apache.thrift.TException te) {
25090
        throw new java.io.IOException(te);
25091
      }
25092
    }
25093
 
25094
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25095
      try {
25096
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25097
      } catch (org.apache.thrift.TException te) {
25098
        throw new java.io.IOException(te);
25099
      }
25100
    }
25101
 
25102
  }
25103
 
25104
  public static class clearItemAvailabilityCache_args implements org.apache.thrift.TBase<clearItemAvailabilityCache_args, clearItemAvailabilityCache_args._Fields>, java.io.Serializable, Cloneable   {
25105
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCache_args");
25106
 
25107
 
25108
 
25109
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25110
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25111
;
25112
 
25113
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25114
 
25115
      static {
25116
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25117
          byName.put(field.getFieldName(), field);
25118
        }
25119
      }
25120
 
25121
      /**
25122
       * Find the _Fields constant that matches fieldId, or null if its not found.
25123
       */
25124
      public static _Fields findByThriftId(int fieldId) {
25125
        switch(fieldId) {
25126
          default:
25127
            return null;
25128
        }
25129
      }
25130
 
25131
      /**
25132
       * Find the _Fields constant that matches fieldId, throwing an exception
25133
       * if it is not found.
25134
       */
25135
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25136
        _Fields fields = findByThriftId(fieldId);
25137
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25138
        return fields;
25139
      }
25140
 
25141
      /**
25142
       * Find the _Fields constant that matches name, or null if its not found.
25143
       */
25144
      public static _Fields findByName(String name) {
25145
        return byName.get(name);
25146
      }
25147
 
25148
      private final short _thriftId;
25149
      private final String _fieldName;
25150
 
25151
      _Fields(short thriftId, String fieldName) {
25152
        _thriftId = thriftId;
25153
        _fieldName = fieldName;
25154
      }
25155
 
25156
      public short getThriftFieldId() {
25157
        return _thriftId;
25158
      }
25159
 
25160
      public String getFieldName() {
25161
        return _fieldName;
25162
      }
25163
    }
25164
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25165
    static {
25166
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25167
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25168
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCache_args.class, metaDataMap);
25169
    }
25170
 
25171
    public clearItemAvailabilityCache_args() {
25172
    }
25173
 
25174
    /**
25175
     * Performs a deep copy on <i>other</i>.
25176
     */
25177
    public clearItemAvailabilityCache_args(clearItemAvailabilityCache_args other) {
25178
    }
25179
 
25180
    public clearItemAvailabilityCache_args deepCopy() {
25181
      return new clearItemAvailabilityCache_args(this);
25182
    }
25183
 
25184
    @Override
25185
    public void clear() {
25186
    }
25187
 
25188
    public void setFieldValue(_Fields field, Object value) {
25189
      switch (field) {
25190
      }
25191
    }
25192
 
25193
    public Object getFieldValue(_Fields field) {
25194
      switch (field) {
25195
      }
25196
      throw new IllegalStateException();
25197
    }
25198
 
25199
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25200
    public boolean isSet(_Fields field) {
25201
      if (field == null) {
25202
        throw new IllegalArgumentException();
25203
      }
25204
 
25205
      switch (field) {
25206
      }
25207
      throw new IllegalStateException();
25208
    }
25209
 
25210
    @Override
25211
    public boolean equals(Object that) {
25212
      if (that == null)
25213
        return false;
25214
      if (that instanceof clearItemAvailabilityCache_args)
25215
        return this.equals((clearItemAvailabilityCache_args)that);
25216
      return false;
25217
    }
25218
 
25219
    public boolean equals(clearItemAvailabilityCache_args that) {
25220
      if (that == null)
25221
        return false;
25222
 
25223
      return true;
25224
    }
25225
 
25226
    @Override
25227
    public int hashCode() {
25228
      return 0;
25229
    }
25230
 
25231
    public int compareTo(clearItemAvailabilityCache_args other) {
25232
      if (!getClass().equals(other.getClass())) {
25233
        return getClass().getName().compareTo(other.getClass().getName());
25234
      }
25235
 
25236
      int lastComparison = 0;
25237
      clearItemAvailabilityCache_args typedOther = (clearItemAvailabilityCache_args)other;
25238
 
25239
      return 0;
25240
    }
25241
 
25242
    public _Fields fieldForId(int fieldId) {
25243
      return _Fields.findByThriftId(fieldId);
25244
    }
25245
 
25246
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25247
      org.apache.thrift.protocol.TField field;
25248
      iprot.readStructBegin();
25249
      while (true)
25250
      {
25251
        field = iprot.readFieldBegin();
25252
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25253
          break;
25254
        }
25255
        switch (field.id) {
25256
          default:
25257
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25258
        }
25259
        iprot.readFieldEnd();
25260
      }
25261
      iprot.readStructEnd();
25262
      validate();
25263
    }
25264
 
25265
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25266
      validate();
25267
 
25268
      oprot.writeStructBegin(STRUCT_DESC);
25269
      oprot.writeFieldStop();
25270
      oprot.writeStructEnd();
25271
    }
25272
 
25273
    @Override
25274
    public String toString() {
25275
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCache_args(");
25276
      boolean first = true;
25277
 
25278
      sb.append(")");
25279
      return sb.toString();
25280
    }
25281
 
25282
    public void validate() throws org.apache.thrift.TException {
25283
      // check for required fields
25284
    }
25285
 
25286
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25287
      try {
25288
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25289
      } catch (org.apache.thrift.TException te) {
25290
        throw new java.io.IOException(te);
25291
      }
25292
    }
25293
 
25294
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25295
      try {
25296
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25297
      } catch (org.apache.thrift.TException te) {
25298
        throw new java.io.IOException(te);
25299
      }
25300
    }
25301
 
25302
  }
25303
 
25304
  public static class clearItemAvailabilityCache_result implements org.apache.thrift.TBase<clearItemAvailabilityCache_result, clearItemAvailabilityCache_result._Fields>, java.io.Serializable, Cloneable   {
25305
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCache_result");
25306
 
25307
 
25308
 
25309
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25310
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25311
;
25312
 
25313
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25314
 
25315
      static {
25316
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25317
          byName.put(field.getFieldName(), field);
25318
        }
25319
      }
25320
 
25321
      /**
25322
       * Find the _Fields constant that matches fieldId, or null if its not found.
25323
       */
25324
      public static _Fields findByThriftId(int fieldId) {
25325
        switch(fieldId) {
25326
          default:
25327
            return null;
25328
        }
25329
      }
25330
 
25331
      /**
25332
       * Find the _Fields constant that matches fieldId, throwing an exception
25333
       * if it is not found.
25334
       */
25335
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25336
        _Fields fields = findByThriftId(fieldId);
25337
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25338
        return fields;
25339
      }
25340
 
25341
      /**
25342
       * Find the _Fields constant that matches name, or null if its not found.
25343
       */
25344
      public static _Fields findByName(String name) {
25345
        return byName.get(name);
25346
      }
25347
 
25348
      private final short _thriftId;
25349
      private final String _fieldName;
25350
 
25351
      _Fields(short thriftId, String fieldName) {
25352
        _thriftId = thriftId;
25353
        _fieldName = fieldName;
25354
      }
25355
 
25356
      public short getThriftFieldId() {
25357
        return _thriftId;
25358
      }
25359
 
25360
      public String getFieldName() {
25361
        return _fieldName;
25362
      }
25363
    }
25364
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25365
    static {
25366
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25367
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25368
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCache_result.class, metaDataMap);
25369
    }
25370
 
25371
    public clearItemAvailabilityCache_result() {
25372
    }
25373
 
25374
    /**
25375
     * Performs a deep copy on <i>other</i>.
25376
     */
25377
    public clearItemAvailabilityCache_result(clearItemAvailabilityCache_result other) {
25378
    }
25379
 
25380
    public clearItemAvailabilityCache_result deepCopy() {
25381
      return new clearItemAvailabilityCache_result(this);
25382
    }
25383
 
25384
    @Override
25385
    public void clear() {
25386
    }
25387
 
25388
    public void setFieldValue(_Fields field, Object value) {
25389
      switch (field) {
25390
      }
25391
    }
25392
 
25393
    public Object getFieldValue(_Fields field) {
25394
      switch (field) {
25395
      }
25396
      throw new IllegalStateException();
25397
    }
25398
 
25399
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25400
    public boolean isSet(_Fields field) {
25401
      if (field == null) {
25402
        throw new IllegalArgumentException();
25403
      }
25404
 
25405
      switch (field) {
25406
      }
25407
      throw new IllegalStateException();
25408
    }
25409
 
25410
    @Override
25411
    public boolean equals(Object that) {
25412
      if (that == null)
25413
        return false;
25414
      if (that instanceof clearItemAvailabilityCache_result)
25415
        return this.equals((clearItemAvailabilityCache_result)that);
25416
      return false;
25417
    }
25418
 
25419
    public boolean equals(clearItemAvailabilityCache_result that) {
25420
      if (that == null)
25421
        return false;
25422
 
25423
      return true;
25424
    }
25425
 
25426
    @Override
25427
    public int hashCode() {
25428
      return 0;
25429
    }
25430
 
25431
    public int compareTo(clearItemAvailabilityCache_result other) {
25432
      if (!getClass().equals(other.getClass())) {
25433
        return getClass().getName().compareTo(other.getClass().getName());
25434
      }
25435
 
25436
      int lastComparison = 0;
25437
      clearItemAvailabilityCache_result typedOther = (clearItemAvailabilityCache_result)other;
25438
 
25439
      return 0;
25440
    }
25441
 
25442
    public _Fields fieldForId(int fieldId) {
25443
      return _Fields.findByThriftId(fieldId);
25444
    }
25445
 
25446
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25447
      org.apache.thrift.protocol.TField field;
25448
      iprot.readStructBegin();
25449
      while (true)
25450
      {
25451
        field = iprot.readFieldBegin();
25452
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25453
          break;
25454
        }
25455
        switch (field.id) {
25456
          default:
25457
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25458
        }
25459
        iprot.readFieldEnd();
25460
      }
25461
      iprot.readStructEnd();
25462
      validate();
25463
    }
25464
 
25465
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25466
      oprot.writeStructBegin(STRUCT_DESC);
25467
 
25468
      oprot.writeFieldStop();
25469
      oprot.writeStructEnd();
25470
    }
25471
 
25472
    @Override
25473
    public String toString() {
25474
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCache_result(");
25475
      boolean first = true;
25476
 
25477
      sb.append(")");
25478
      return sb.toString();
25479
    }
25480
 
25481
    public void validate() throws org.apache.thrift.TException {
25482
      // check for required fields
25483
    }
25484
 
25485
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25486
      try {
25487
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25488
      } catch (org.apache.thrift.TException te) {
25489
        throw new java.io.IOException(te);
25490
      }
25491
    }
25492
 
25493
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25494
      try {
25495
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25496
      } catch (org.apache.thrift.TException te) {
25497
        throw new java.io.IOException(te);
25498
      }
25499
    }
25500
 
25501
  }
25502
 
25503
  public static class updateVendorString_args implements org.apache.thrift.TBase<updateVendorString_args, updateVendorString_args._Fields>, java.io.Serializable, Cloneable   {
25504
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateVendorString_args");
25505
 
25506
    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);
25507
    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);
25508
 
25509
    private long warehouseId; // required
25510
    private String vendorString; // required
25511
 
25512
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25513
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25514
      WAREHOUSE_ID((short)1, "warehouseId"),
25515
      VENDOR_STRING((short)2, "vendorString");
25516
 
25517
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25518
 
25519
      static {
25520
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25521
          byName.put(field.getFieldName(), field);
25522
        }
25523
      }
25524
 
25525
      /**
25526
       * Find the _Fields constant that matches fieldId, or null if its not found.
25527
       */
25528
      public static _Fields findByThriftId(int fieldId) {
25529
        switch(fieldId) {
25530
          case 1: // WAREHOUSE_ID
25531
            return WAREHOUSE_ID;
25532
          case 2: // VENDOR_STRING
25533
            return VENDOR_STRING;
25534
          default:
25535
            return null;
25536
        }
25537
      }
25538
 
25539
      /**
25540
       * Find the _Fields constant that matches fieldId, throwing an exception
25541
       * if it is not found.
25542
       */
25543
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25544
        _Fields fields = findByThriftId(fieldId);
25545
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25546
        return fields;
25547
      }
25548
 
25549
      /**
25550
       * Find the _Fields constant that matches name, or null if its not found.
25551
       */
25552
      public static _Fields findByName(String name) {
25553
        return byName.get(name);
25554
      }
25555
 
25556
      private final short _thriftId;
25557
      private final String _fieldName;
25558
 
25559
      _Fields(short thriftId, String fieldName) {
25560
        _thriftId = thriftId;
25561
        _fieldName = fieldName;
25562
      }
25563
 
25564
      public short getThriftFieldId() {
25565
        return _thriftId;
25566
      }
25567
 
25568
      public String getFieldName() {
25569
        return _fieldName;
25570
      }
25571
    }
25572
 
25573
    // isset id assignments
25574
    private static final int __WAREHOUSEID_ISSET_ID = 0;
25575
    private BitSet __isset_bit_vector = new BitSet(1);
25576
 
25577
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25578
    static {
25579
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25580
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
25581
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
25582
      tmpMap.put(_Fields.VENDOR_STRING, new org.apache.thrift.meta_data.FieldMetaData("vendorString", org.apache.thrift.TFieldRequirementType.DEFAULT, 
25583
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
25584
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25585
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateVendorString_args.class, metaDataMap);
25586
    }
25587
 
25588
    public updateVendorString_args() {
25589
    }
25590
 
25591
    public updateVendorString_args(
25592
      long warehouseId,
25593
      String vendorString)
25594
    {
25595
      this();
25596
      this.warehouseId = warehouseId;
25597
      setWarehouseIdIsSet(true);
25598
      this.vendorString = vendorString;
25599
    }
25600
 
25601
    /**
25602
     * Performs a deep copy on <i>other</i>.
25603
     */
25604
    public updateVendorString_args(updateVendorString_args other) {
25605
      __isset_bit_vector.clear();
25606
      __isset_bit_vector.or(other.__isset_bit_vector);
25607
      this.warehouseId = other.warehouseId;
25608
      if (other.isSetVendorString()) {
25609
        this.vendorString = other.vendorString;
25610
      }
25611
    }
25612
 
25613
    public updateVendorString_args deepCopy() {
25614
      return new updateVendorString_args(this);
25615
    }
25616
 
25617
    @Override
25618
    public void clear() {
25619
      setWarehouseIdIsSet(false);
25620
      this.warehouseId = 0;
25621
      this.vendorString = null;
25622
    }
25623
 
25624
    public long getWarehouseId() {
25625
      return this.warehouseId;
25626
    }
25627
 
25628
    public void setWarehouseId(long warehouseId) {
25629
      this.warehouseId = warehouseId;
25630
      setWarehouseIdIsSet(true);
25631
    }
25632
 
25633
    public void unsetWarehouseId() {
25634
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
25635
    }
25636
 
25637
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
25638
    public boolean isSetWarehouseId() {
25639
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
25640
    }
25641
 
25642
    public void setWarehouseIdIsSet(boolean value) {
25643
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
25644
    }
25645
 
25646
    public String getVendorString() {
25647
      return this.vendorString;
25648
    }
25649
 
25650
    public void setVendorString(String vendorString) {
25651
      this.vendorString = vendorString;
25652
    }
25653
 
25654
    public void unsetVendorString() {
25655
      this.vendorString = null;
25656
    }
25657
 
25658
    /** Returns true if field vendorString is set (has been assigned a value) and false otherwise */
25659
    public boolean isSetVendorString() {
25660
      return this.vendorString != null;
25661
    }
25662
 
25663
    public void setVendorStringIsSet(boolean value) {
25664
      if (!value) {
25665
        this.vendorString = null;
25666
      }
25667
    }
25668
 
25669
    public void setFieldValue(_Fields field, Object value) {
25670
      switch (field) {
25671
      case WAREHOUSE_ID:
25672
        if (value == null) {
25673
          unsetWarehouseId();
25674
        } else {
25675
          setWarehouseId((Long)value);
25676
        }
25677
        break;
25678
 
25679
      case VENDOR_STRING:
25680
        if (value == null) {
25681
          unsetVendorString();
25682
        } else {
25683
          setVendorString((String)value);
25684
        }
25685
        break;
25686
 
25687
      }
25688
    }
25689
 
25690
    public Object getFieldValue(_Fields field) {
25691
      switch (field) {
25692
      case WAREHOUSE_ID:
25693
        return Long.valueOf(getWarehouseId());
25694
 
25695
      case VENDOR_STRING:
25696
        return getVendorString();
25697
 
25698
      }
25699
      throw new IllegalStateException();
25700
    }
25701
 
25702
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25703
    public boolean isSet(_Fields field) {
25704
      if (field == null) {
25705
        throw new IllegalArgumentException();
25706
      }
25707
 
25708
      switch (field) {
25709
      case WAREHOUSE_ID:
25710
        return isSetWarehouseId();
25711
      case VENDOR_STRING:
25712
        return isSetVendorString();
25713
      }
25714
      throw new IllegalStateException();
25715
    }
25716
 
25717
    @Override
25718
    public boolean equals(Object that) {
25719
      if (that == null)
25720
        return false;
25721
      if (that instanceof updateVendorString_args)
25722
        return this.equals((updateVendorString_args)that);
25723
      return false;
25724
    }
25725
 
25726
    public boolean equals(updateVendorString_args that) {
25727
      if (that == null)
25728
        return false;
25729
 
25730
      boolean this_present_warehouseId = true;
25731
      boolean that_present_warehouseId = true;
25732
      if (this_present_warehouseId || that_present_warehouseId) {
25733
        if (!(this_present_warehouseId && that_present_warehouseId))
25734
          return false;
25735
        if (this.warehouseId != that.warehouseId)
25736
          return false;
25737
      }
25738
 
25739
      boolean this_present_vendorString = true && this.isSetVendorString();
25740
      boolean that_present_vendorString = true && that.isSetVendorString();
25741
      if (this_present_vendorString || that_present_vendorString) {
25742
        if (!(this_present_vendorString && that_present_vendorString))
25743
          return false;
25744
        if (!this.vendorString.equals(that.vendorString))
25745
          return false;
25746
      }
25747
 
25748
      return true;
25749
    }
25750
 
25751
    @Override
25752
    public int hashCode() {
25753
      return 0;
25754
    }
25755
 
25756
    public int compareTo(updateVendorString_args other) {
25757
      if (!getClass().equals(other.getClass())) {
25758
        return getClass().getName().compareTo(other.getClass().getName());
25759
      }
25760
 
25761
      int lastComparison = 0;
25762
      updateVendorString_args typedOther = (updateVendorString_args)other;
25763
 
25764
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
25765
      if (lastComparison != 0) {
25766
        return lastComparison;
25767
      }
25768
      if (isSetWarehouseId()) {
25769
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
25770
        if (lastComparison != 0) {
25771
          return lastComparison;
25772
        }
25773
      }
25774
      lastComparison = Boolean.valueOf(isSetVendorString()).compareTo(typedOther.isSetVendorString());
25775
      if (lastComparison != 0) {
25776
        return lastComparison;
25777
      }
25778
      if (isSetVendorString()) {
25779
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorString, typedOther.vendorString);
25780
        if (lastComparison != 0) {
25781
          return lastComparison;
25782
        }
25783
      }
25784
      return 0;
25785
    }
25786
 
25787
    public _Fields fieldForId(int fieldId) {
25788
      return _Fields.findByThriftId(fieldId);
25789
    }
25790
 
25791
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25792
      org.apache.thrift.protocol.TField field;
25793
      iprot.readStructBegin();
25794
      while (true)
25795
      {
25796
        field = iprot.readFieldBegin();
25797
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25798
          break;
25799
        }
25800
        switch (field.id) {
25801
          case 1: // WAREHOUSE_ID
25802
            if (field.type == org.apache.thrift.protocol.TType.I64) {
25803
              this.warehouseId = iprot.readI64();
25804
              setWarehouseIdIsSet(true);
25805
            } else { 
25806
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25807
            }
25808
            break;
25809
          case 2: // VENDOR_STRING
25810
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
25811
              this.vendorString = iprot.readString();
25812
            } else { 
25813
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25814
            }
25815
            break;
25816
          default:
25817
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25818
        }
25819
        iprot.readFieldEnd();
25820
      }
25821
      iprot.readStructEnd();
25822
      validate();
25823
    }
25824
 
25825
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25826
      validate();
25827
 
25828
      oprot.writeStructBegin(STRUCT_DESC);
25829
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
25830
      oprot.writeI64(this.warehouseId);
25831
      oprot.writeFieldEnd();
25832
      if (this.vendorString != null) {
25833
        oprot.writeFieldBegin(VENDOR_STRING_FIELD_DESC);
25834
        oprot.writeString(this.vendorString);
25835
        oprot.writeFieldEnd();
25836
      }
25837
      oprot.writeFieldStop();
25838
      oprot.writeStructEnd();
25839
    }
25840
 
25841
    @Override
25842
    public String toString() {
25843
      StringBuilder sb = new StringBuilder("updateVendorString_args(");
25844
      boolean first = true;
25845
 
25846
      sb.append("warehouseId:");
25847
      sb.append(this.warehouseId);
25848
      first = false;
25849
      if (!first) sb.append(", ");
25850
      sb.append("vendorString:");
25851
      if (this.vendorString == null) {
25852
        sb.append("null");
25853
      } else {
25854
        sb.append(this.vendorString);
25855
      }
25856
      first = false;
25857
      sb.append(")");
25858
      return sb.toString();
25859
    }
25860
 
25861
    public void validate() throws org.apache.thrift.TException {
25862
      // check for required fields
25863
    }
25864
 
25865
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25866
      try {
25867
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25868
      } catch (org.apache.thrift.TException te) {
25869
        throw new java.io.IOException(te);
25870
      }
25871
    }
25872
 
25873
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25874
      try {
25875
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25876
      } catch (org.apache.thrift.TException te) {
25877
        throw new java.io.IOException(te);
25878
      }
25879
    }
25880
 
25881
  }
25882
 
25883
  public static class updateVendorString_result implements org.apache.thrift.TBase<updateVendorString_result, updateVendorString_result._Fields>, java.io.Serializable, Cloneable   {
25884
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateVendorString_result");
25885
 
25886
 
25887
 
25888
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25889
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25890
;
25891
 
25892
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25893
 
25894
      static {
25895
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25896
          byName.put(field.getFieldName(), field);
25897
        }
25898
      }
25899
 
25900
      /**
25901
       * Find the _Fields constant that matches fieldId, or null if its not found.
25902
       */
25903
      public static _Fields findByThriftId(int fieldId) {
25904
        switch(fieldId) {
25905
          default:
25906
            return null;
25907
        }
25908
      }
25909
 
25910
      /**
25911
       * Find the _Fields constant that matches fieldId, throwing an exception
25912
       * if it is not found.
25913
       */
25914
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25915
        _Fields fields = findByThriftId(fieldId);
25916
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25917
        return fields;
25918
      }
25919
 
25920
      /**
25921
       * Find the _Fields constant that matches name, or null if its not found.
25922
       */
25923
      public static _Fields findByName(String name) {
25924
        return byName.get(name);
25925
      }
25926
 
25927
      private final short _thriftId;
25928
      private final String _fieldName;
25929
 
25930
      _Fields(short thriftId, String fieldName) {
25931
        _thriftId = thriftId;
25932
        _fieldName = fieldName;
25933
      }
25934
 
25935
      public short getThriftFieldId() {
25936
        return _thriftId;
25937
      }
25938
 
25939
      public String getFieldName() {
25940
        return _fieldName;
25941
      }
25942
    }
25943
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25944
    static {
25945
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25946
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25947
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateVendorString_result.class, metaDataMap);
25948
    }
25949
 
25950
    public updateVendorString_result() {
25951
    }
25952
 
25953
    /**
25954
     * Performs a deep copy on <i>other</i>.
25955
     */
25956
    public updateVendorString_result(updateVendorString_result other) {
25957
    }
25958
 
25959
    public updateVendorString_result deepCopy() {
25960
      return new updateVendorString_result(this);
25961
    }
25962
 
25963
    @Override
25964
    public void clear() {
25965
    }
25966
 
25967
    public void setFieldValue(_Fields field, Object value) {
25968
      switch (field) {
25969
      }
25970
    }
25971
 
25972
    public Object getFieldValue(_Fields field) {
25973
      switch (field) {
25974
      }
25975
      throw new IllegalStateException();
25976
    }
25977
 
25978
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25979
    public boolean isSet(_Fields field) {
25980
      if (field == null) {
25981
        throw new IllegalArgumentException();
25982
      }
25983
 
25984
      switch (field) {
25985
      }
25986
      throw new IllegalStateException();
25987
    }
25988
 
25989
    @Override
25990
    public boolean equals(Object that) {
25991
      if (that == null)
25992
        return false;
25993
      if (that instanceof updateVendorString_result)
25994
        return this.equals((updateVendorString_result)that);
25995
      return false;
25996
    }
25997
 
25998
    public boolean equals(updateVendorString_result that) {
25999
      if (that == null)
26000
        return false;
26001
 
26002
      return true;
26003
    }
26004
 
26005
    @Override
26006
    public int hashCode() {
26007
      return 0;
26008
    }
26009
 
26010
    public int compareTo(updateVendorString_result other) {
26011
      if (!getClass().equals(other.getClass())) {
26012
        return getClass().getName().compareTo(other.getClass().getName());
26013
      }
26014
 
26015
      int lastComparison = 0;
26016
      updateVendorString_result typedOther = (updateVendorString_result)other;
26017
 
26018
      return 0;
26019
    }
26020
 
26021
    public _Fields fieldForId(int fieldId) {
26022
      return _Fields.findByThriftId(fieldId);
26023
    }
26024
 
26025
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26026
      org.apache.thrift.protocol.TField field;
26027
      iprot.readStructBegin();
26028
      while (true)
26029
      {
26030
        field = iprot.readFieldBegin();
26031
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26032
          break;
26033
        }
26034
        switch (field.id) {
26035
          default:
26036
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26037
        }
26038
        iprot.readFieldEnd();
26039
      }
26040
      iprot.readStructEnd();
26041
      validate();
26042
    }
26043
 
26044
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26045
      oprot.writeStructBegin(STRUCT_DESC);
26046
 
26047
      oprot.writeFieldStop();
26048
      oprot.writeStructEnd();
26049
    }
26050
 
26051
    @Override
26052
    public String toString() {
26053
      StringBuilder sb = new StringBuilder("updateVendorString_result(");
26054
      boolean first = true;
26055
 
26056
      sb.append(")");
26057
      return sb.toString();
26058
    }
26059
 
26060
    public void validate() throws org.apache.thrift.TException {
26061
      // check for required fields
26062
    }
26063
 
26064
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26065
      try {
26066
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26067
      } catch (org.apache.thrift.TException te) {
26068
        throw new java.io.IOException(te);
26069
      }
26070
    }
26071
 
26072
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26073
      try {
26074
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26075
      } catch (org.apache.thrift.TException te) {
26076
        throw new java.io.IOException(te);
26077
      }
26078
    }
26079
 
26080
  }
26081
 
26082
}