Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
5945 mandeep.dh 1
/**
2
 * Autogenerated by Thrift Compiler (0.7.0)
3
 *
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
 */
6
package in.shop2020.model.v1.inventory;
7
 
8
import java.util.List;
9
import java.util.ArrayList;
10
import java.util.Map;
11
import java.util.HashMap;
12
import java.util.EnumMap;
13
import java.util.Set;
14
import java.util.HashSet;
15
import java.util.EnumSet;
16
import java.util.Collections;
17
import java.util.BitSet;
18
import java.nio.ByteBuffer;
19
import java.util.Arrays;
20
import org.slf4j.Logger;
21
import org.slf4j.LoggerFactory;
22
 
23
public class InventoryService {
24
 
25
  public interface Iface extends in.shop2020.generic.GenericService.Iface {
26
 
27
    public long addWarehouse(Warehouse warehouse) throws InventoryServiceException, org.apache.thrift.TException;
28
 
29
    /**
30
     * add a new vendor
31
     * 
32
     * @param vendor
33
     */
34
    public long addVendor(Vendor vendor) throws InventoryServiceException, org.apache.thrift.TException;
35
 
36
    /**
37
     * Stores the incremental warehouse updates of items.
38
     * 
39
     * @param warehouse_id
40
     * @param timestamp
41
     * @param availability
42
     */
43
    public void updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException;
44
 
45
    /**
46
     * Stores the final inventory stocks of items.
47
     * 
48
     * @param warehouse_id
49
     * @param timestamp
50
     * @param availability
51
     */
52
    public void updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException;
53
 
54
    /**
55
     * Add the inventory to existing stock.
56
     * 
57
     * @param itemId
58
     * @param warehouseId
59
     * @param quantity
60
     */
61
    public void addInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException;
62
 
63
    public void retireWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException;
64
 
65
    public ItemInventory getItemInventoryByItemId(long item_id) throws InventoryServiceException, org.apache.thrift.TException;
66
 
67
    public long getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws InventoryServiceException, org.apache.thrift.TException;
68
 
69
    /**
70
     * Determines the warehouse that should be used to fulfil an order for the given item.
71
     * It first checks all the warehouses which are in the logistics location given by the
72
     * warehouse_loc parameter. If none of the warehouses there have any inventory, then the
73
     * preferred warehouse for the item is used.
74
     * 
75
     * Returns an ordered list of size 4 with following elements in the given order:
76
     * 1. Id of the fulfillment warehouse which was finally picked up.
77
     * 2. Expected delay added by the category manager.
78
     * 3. Id of the billing warehouse which was finally picked up.
79
     * 
80
     * @param itemId
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
    /**
5967 rajveer 96
     * Depending on reservation in the table, verify wether we can bill this order or not.
97
     * 
98
     * @param itemId
99
     * @param warehouseId
100
     * @param sourceId
101
     * @param orderId
102
     */
103
    public boolean isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId) throws org.apache.thrift.TException;
104
 
105
    /**
5945 mandeep.dh 106
     * Increases the reservation count for an item in a warehouse. Should always succeed normally.
107
     * 
108
     * @param itemId
109
     * @param warehouseId
5967 rajveer 110
     * @param sourceId
111
     * @param orderId
112
     * @param createdTimestamp
113
     * @param promisedShippingTimestamp
5945 mandeep.dh 114
     * @param quantity
115
     */
5967 rajveer 116
    public boolean reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity) throws InventoryServiceException, org.apache.thrift.TException;
5945 mandeep.dh 117
 
118
    /**
119
     * Decreases the reservation count for an item in a warehouse. Should always succeed normally.
120
     * 
121
     * @param itemId
122
     * @param warehouseId
5967 rajveer 123
     * @param sourceId
124
     * @param orderId
5945 mandeep.dh 125
     * @param quantity
126
     */
5967 rajveer 127
    public boolean reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity) throws InventoryServiceException, org.apache.thrift.TException;
5945 mandeep.dh 128
 
129
    /**
130
     * Returns the pricing information of an item associated with the vendor of the given warehouse.
131
     * Raises an exception if either the item, vendor or the associated pricing information can't be found.
132
     * 
133
     * @param itemId
134
     * @param vendorId
135
     */
136
    public VendorItemPricing getItemPricing(long itemId, long vendorId) throws InventoryServiceException, org.apache.thrift.TException;
137
 
138
    /**
139
     * Returns the list of vendor pricing information of an item.
140
     * Raises an exception if item not found corresponding to itemId
141
     * 
142
     * @param itemId
143
     */
144
    public List<VendorItemPricing> getAllItemPricing(long itemId) throws InventoryServiceException, org.apache.thrift.TException;
145
 
146
    /**
147
     * Adds vendor prices corresponding to the item. If pricing already exists then updates the prices.
148
     * Raises an exception if either the item or vendor can't be found corresponding to their ids.
149
     * 
150
     * @param vendorItemPricing
151
     */
152
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing) throws InventoryServiceException, org.apache.thrift.TException;
153
 
154
    /**
155
     * Returns a vendor given its id
156
     * 
157
     * @param vendorId
158
     */
159
    public Vendor getVendor(long vendorId) throws org.apache.thrift.TException;
160
 
161
    /**
162
     * Return list of all vendors
163
     */
164
    public List<Vendor> getAllVendors() throws org.apache.thrift.TException;
165
 
166
    /**
167
     * Adds VendorItemMapping. Updates VendorItemMapping if exists corresponding to the item key.
168
     * 
169
     * @param key
170
     * @param vendorItemMapping
171
     */
172
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws InventoryServiceException, org.apache.thrift.TException;
173
 
174
    /**
175
     * Returns the list of vendor item mapping corresponding to itemId passed as parameter.
176
     * Raises an exception if item not found corresponding to itemId
177
     * 
178
     * @param itemId
179
     */
180
    public List<VendorItemMapping> getVendorItemMappings(long itemId) throws InventoryServiceException, org.apache.thrift.TException;
181
 
182
    /**
183
     * Returns a list of inventory stock for items for which there are pending orders for the given vendor.
184
     * 
185
     * @param vendorid
186
     */
187
    public List<AvailableAndReservedStock> getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException;
188
 
189
    /**
190
     * This method returns all warehouses for a given warehosueType, inventoryType, vendor, billingWarehouse and shippingWarehouse.
191
     * 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
192
     * 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
193
     *    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
194
     *    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
195
     * 
196
     * @param warehouseType
197
     * @param inventoryType
198
     * @param vendorId
199
     * @param billingWarehouseId
200
     * @param shippingWarehouseId
201
     */
202
    public List<Warehouse> getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException;
203
 
204
    /**
205
     * Resets availability of an item to the quantity mentioned in a warehouse.
206
     * 
207
     * @param itemKey
208
     * @param vendorId
209
     * @param quantity
210
     * @param warehouseId
211
     */
212
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws InventoryServiceException, org.apache.thrift.TException;
213
 
214
    /**
215
     * Resets availability of a warehouse to zero.
216
     * 
217
     * @param warehouseId
218
     */
219
    public void resetAvailabilityForWarehouse(long warehouseId) throws InventoryServiceException, org.apache.thrift.TException;
220
 
221
    /**
222
     * Returns the list of item keys which need to be processed for a given warehouse.
223
     * This is currently used by Support application to send item keys whose inventory needs
224
     * to be updated from PLB
225
     * 
226
     * @param warehouseId
227
     */
228
    public List<String> getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException;
229
 
230
    /**
231
     * Marks/Deletes missed inventory updates for a given key and warehouse.
232
     * This generally happens when updates from PLB are applied on the currentinventorysnapshot for an item
233
     * 
234
     * @param itemKey
235
     * @param warehouseId
236
     */
237
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException;
238
 
239
    /**
240
     * Returns all the item key mappings that have been ignored until date. Value of map has the warehouse id
241
     * and the timestamp from where alert was raised.
242
     */
243
    public Map<String,Map<Long,Long>> getIgnoredItemKeys() throws org.apache.thrift.TException;
244
 
245
    /**
246
     * Add the BAD type inventory to existing stock.
247
     * 
248
     * @param itemId
249
     * @param warehouseId
250
     * @param quantity
251
     */
252
    public void addBadInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException;
253
 
254
    /**
255
     * Returns all shipping locations
256
     */
257
    public List<Warehouse> getShippingLocations() throws org.apache.thrift.TException;
258
 
259
    /**
260
     * Fetches all the vendor item mappings present.
261
     */
262
    public List<VendorItemMapping> getAllVendorItemMappings() throws org.apache.thrift.TException;
263
 
264
    /**
265
     * Gets items' inventory for a warehouse
266
     * If warehouse is passed as zero, items' inventory across all warehouses is sent
267
     * 
268
     * @param warehouseId
269
     */
270
    public Map<Long,ItemInventory> getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException;
271
 
272
    /**
273
     * Clear item availability cache.
274
     */
275
    public void clearItemAvailabilityCache() throws org.apache.thrift.TException;
276
 
277
    public void updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException;
278
 
279
  }
280
 
281
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
282
 
283
    public void addWarehouse(Warehouse warehouse, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addWarehouse_call> resultHandler) throws org.apache.thrift.TException;
284
 
285
    public void addVendor(Vendor vendor, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendor_call> resultHandler) throws org.apache.thrift.TException;
286
 
287
    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;
288
 
289
    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;
290
 
291
    public void addInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addInventory_call> resultHandler) throws org.apache.thrift.TException;
292
 
293
    public void retireWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.retireWarehouse_call> resultHandler) throws org.apache.thrift.TException;
294
 
295
    public void getItemInventoryByItemId(long item_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemInventoryByItemId_call> resultHandler) throws org.apache.thrift.TException;
296
 
297
    public void getItemAvailibilityAtWarehouse(long warehouse_id, long item_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemAvailibilityAtWarehouse_call> resultHandler) throws org.apache.thrift.TException;
298
 
299
    public void getItemAvailabilityAtLocation(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemAvailabilityAtLocation_call> resultHandler) throws org.apache.thrift.TException;
300
 
301
    public void getAllWarehouses(boolean isActive, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllWarehouses_call> resultHandler) throws org.apache.thrift.TException;
302
 
303
    public void getWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getWarehouse_call> resultHandler) throws org.apache.thrift.TException;
304
 
305
    public void getAllItemsForWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllItemsForWarehouse_call> resultHandler) throws org.apache.thrift.TException;
306
 
5967 rajveer 307
    public void isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.isOrderBillable_call> resultHandler) throws org.apache.thrift.TException;
5945 mandeep.dh 308
 
5967 rajveer 309
    public void reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.reserveItemInWarehouse_call> resultHandler) throws org.apache.thrift.TException;
5945 mandeep.dh 310
 
5967 rajveer 311
    public void reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.reduceReservationCount_call> resultHandler) throws org.apache.thrift.TException;
312
 
5945 mandeep.dh 313
    public void getItemPricing(long itemId, long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemPricing_call> resultHandler) throws org.apache.thrift.TException;
314
 
315
    public void getAllItemPricing(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllItemPricing_call> resultHandler) throws org.apache.thrift.TException;
316
 
317
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendorItemPricing_call> resultHandler) throws org.apache.thrift.TException;
318
 
319
    public void getVendor(long vendorId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getVendor_call> resultHandler) throws org.apache.thrift.TException;
320
 
321
    public void getAllVendors(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllVendors_call> resultHandler) throws org.apache.thrift.TException;
322
 
323
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addVendorItemMapping_call> resultHandler) throws org.apache.thrift.TException;
324
 
325
    public void getVendorItemMappings(long itemId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException;
326
 
327
    public void getPendingOrdersInventory(long vendorid, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getPendingOrdersInventory_call> resultHandler) throws org.apache.thrift.TException;
328
 
329
    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;
330
 
331
    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;
332
 
333
    public void resetAvailabilityForWarehouse(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.resetAvailabilityForWarehouse_call> resultHandler) throws org.apache.thrift.TException;
334
 
335
    public void getItemKeysToBeProcessed(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getItemKeysToBeProcessed_call> resultHandler) throws org.apache.thrift.TException;
336
 
337
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.markMissedInventoryUpdatesAsProcessed_call> resultHandler) throws org.apache.thrift.TException;
338
 
339
    public void getIgnoredItemKeys(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getIgnoredItemKeys_call> resultHandler) throws org.apache.thrift.TException;
340
 
341
    public void addBadInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.addBadInventory_call> resultHandler) throws org.apache.thrift.TException;
342
 
343
    public void getShippingLocations(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getShippingLocations_call> resultHandler) throws org.apache.thrift.TException;
344
 
345
    public void getAllVendorItemMappings(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException;
346
 
347
    public void getInventorySnapshot(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getInventorySnapshot_call> resultHandler) throws org.apache.thrift.TException;
348
 
349
    public void clearItemAvailabilityCache(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.clearItemAvailabilityCache_call> resultHandler) throws org.apache.thrift.TException;
350
 
351
    public void updateVendorString(long warehouseId, String vendorString, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.updateVendorString_call> resultHandler) throws org.apache.thrift.TException;
352
 
353
  }
354
 
355
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
356
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
357
      public Factory() {}
358
      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
359
        return new Client(prot);
360
      }
361
      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
362
        return new Client(iprot, oprot);
363
      }
364
    }
365
 
366
    public Client(org.apache.thrift.protocol.TProtocol prot)
367
    {
368
      super(prot, prot);
369
    }
370
 
371
    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
372
      super(iprot, oprot);
373
    }
374
 
375
    public long addWarehouse(Warehouse warehouse) throws InventoryServiceException, org.apache.thrift.TException
376
    {
377
      send_addWarehouse(warehouse);
378
      return recv_addWarehouse();
379
    }
380
 
381
    public void send_addWarehouse(Warehouse warehouse) throws org.apache.thrift.TException
382
    {
383
      addWarehouse_args args = new addWarehouse_args();
384
      args.setWarehouse(warehouse);
385
      sendBase("addWarehouse", args);
386
    }
387
 
388
    public long recv_addWarehouse() throws InventoryServiceException, org.apache.thrift.TException
389
    {
390
      addWarehouse_result result = new addWarehouse_result();
391
      receiveBase(result, "addWarehouse");
392
      if (result.isSetSuccess()) {
393
        return result.success;
394
      }
395
      if (result.cex != null) {
396
        throw result.cex;
397
      }
398
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addWarehouse failed: unknown result");
399
    }
400
 
401
    public long addVendor(Vendor vendor) throws InventoryServiceException, org.apache.thrift.TException
402
    {
403
      send_addVendor(vendor);
404
      return recv_addVendor();
405
    }
406
 
407
    public void send_addVendor(Vendor vendor) throws org.apache.thrift.TException
408
    {
409
      addVendor_args args = new addVendor_args();
410
      args.setVendor(vendor);
411
      sendBase("addVendor", args);
412
    }
413
 
414
    public long recv_addVendor() throws InventoryServiceException, org.apache.thrift.TException
415
    {
416
      addVendor_result result = new addVendor_result();
417
      receiveBase(result, "addVendor");
418
      if (result.isSetSuccess()) {
419
        return result.success;
420
      }
421
      if (result.cex != null) {
422
        throw result.cex;
423
      }
424
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "addVendor failed: unknown result");
425
    }
426
 
427
    public void updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException
428
    {
429
      send_updateInventoryHistory(warehouse_id, timestamp, availability);
430
      recv_updateInventoryHistory();
431
    }
432
 
433
    public void send_updateInventoryHistory(long warehouse_id, String timestamp, Map<String,Long> availability) throws org.apache.thrift.TException
434
    {
435
      updateInventoryHistory_args args = new updateInventoryHistory_args();
436
      args.setWarehouse_id(warehouse_id);
437
      args.setTimestamp(timestamp);
438
      args.setAvailability(availability);
439
      sendBase("updateInventoryHistory", args);
440
    }
441
 
442
    public void recv_updateInventoryHistory() throws InventoryServiceException, org.apache.thrift.TException
443
    {
444
      updateInventoryHistory_result result = new updateInventoryHistory_result();
445
      receiveBase(result, "updateInventoryHistory");
446
      if (result.cex != null) {
447
        throw result.cex;
448
      }
449
      return;
450
    }
451
 
452
    public void updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws InventoryServiceException, org.apache.thrift.TException
453
    {
454
      send_updateInventory(warehouse_id, timestamp, availability);
455
      recv_updateInventory();
456
    }
457
 
458
    public void send_updateInventory(long warehouse_id, String timestamp, Map<String,Long> availability) throws org.apache.thrift.TException
459
    {
460
      updateInventory_args args = new updateInventory_args();
461
      args.setWarehouse_id(warehouse_id);
462
      args.setTimestamp(timestamp);
463
      args.setAvailability(availability);
464
      sendBase("updateInventory", args);
465
    }
466
 
467
    public void recv_updateInventory() throws InventoryServiceException, org.apache.thrift.TException
468
    {
469
      updateInventory_result result = new updateInventory_result();
470
      receiveBase(result, "updateInventory");
471
      if (result.cex != null) {
472
        throw result.cex;
473
      }
474
      return;
475
    }
476
 
477
    public void addInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException
478
    {
479
      send_addInventory(itemId, warehouseId, quantity);
480
      recv_addInventory();
481
    }
482
 
483
    public void send_addInventory(long itemId, long warehouseId, long quantity) throws org.apache.thrift.TException
484
    {
485
      addInventory_args args = new addInventory_args();
486
      args.setItemId(itemId);
487
      args.setWarehouseId(warehouseId);
488
      args.setQuantity(quantity);
489
      sendBase("addInventory", args);
490
    }
491
 
492
    public void recv_addInventory() throws InventoryServiceException, org.apache.thrift.TException
493
    {
494
      addInventory_result result = new addInventory_result();
495
      receiveBase(result, "addInventory");
496
      if (result.cex != null) {
497
        throw result.cex;
498
      }
499
      return;
500
    }
501
 
502
    public void retireWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
503
    {
504
      send_retireWarehouse(warehouse_id);
505
      recv_retireWarehouse();
506
    }
507
 
508
    public void send_retireWarehouse(long warehouse_id) throws org.apache.thrift.TException
509
    {
510
      retireWarehouse_args args = new retireWarehouse_args();
511
      args.setWarehouse_id(warehouse_id);
512
      sendBase("retireWarehouse", args);
513
    }
514
 
515
    public void recv_retireWarehouse() throws InventoryServiceException, org.apache.thrift.TException
516
    {
517
      retireWarehouse_result result = new retireWarehouse_result();
518
      receiveBase(result, "retireWarehouse");
519
      if (result.cex != null) {
520
        throw result.cex;
521
      }
522
      return;
523
    }
524
 
525
    public ItemInventory getItemInventoryByItemId(long item_id) throws InventoryServiceException, org.apache.thrift.TException
526
    {
527
      send_getItemInventoryByItemId(item_id);
528
      return recv_getItemInventoryByItemId();
529
    }
530
 
531
    public void send_getItemInventoryByItemId(long item_id) throws org.apache.thrift.TException
532
    {
533
      getItemInventoryByItemId_args args = new getItemInventoryByItemId_args();
534
      args.setItem_id(item_id);
535
      sendBase("getItemInventoryByItemId", args);
536
    }
537
 
538
    public ItemInventory recv_getItemInventoryByItemId() throws InventoryServiceException, org.apache.thrift.TException
539
    {
540
      getItemInventoryByItemId_result result = new getItemInventoryByItemId_result();
541
      receiveBase(result, "getItemInventoryByItemId");
542
      if (result.isSetSuccess()) {
543
        return result.success;
544
      }
545
      if (result.cex != null) {
546
        throw result.cex;
547
      }
548
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemInventoryByItemId failed: unknown result");
549
    }
550
 
551
    public long getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws InventoryServiceException, org.apache.thrift.TException
552
    {
553
      send_getItemAvailibilityAtWarehouse(warehouse_id, item_id);
554
      return recv_getItemAvailibilityAtWarehouse();
555
    }
556
 
557
    public void send_getItemAvailibilityAtWarehouse(long warehouse_id, long item_id) throws org.apache.thrift.TException
558
    {
559
      getItemAvailibilityAtWarehouse_args args = new getItemAvailibilityAtWarehouse_args();
560
      args.setWarehouse_id(warehouse_id);
561
      args.setItem_id(item_id);
562
      sendBase("getItemAvailibilityAtWarehouse", args);
563
    }
564
 
565
    public long recv_getItemAvailibilityAtWarehouse() throws InventoryServiceException, org.apache.thrift.TException
566
    {
567
      getItemAvailibilityAtWarehouse_result result = new getItemAvailibilityAtWarehouse_result();
568
      receiveBase(result, "getItemAvailibilityAtWarehouse");
569
      if (result.isSetSuccess()) {
570
        return result.success;
571
      }
572
      if (result.cex != null) {
573
        throw result.cex;
574
      }
575
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemAvailibilityAtWarehouse failed: unknown result");
576
    }
577
 
578
    public List<Long> getItemAvailabilityAtLocation(long itemId) throws InventoryServiceException, org.apache.thrift.TException
579
    {
580
      send_getItemAvailabilityAtLocation(itemId);
581
      return recv_getItemAvailabilityAtLocation();
582
    }
583
 
584
    public void send_getItemAvailabilityAtLocation(long itemId) throws org.apache.thrift.TException
585
    {
586
      getItemAvailabilityAtLocation_args args = new getItemAvailabilityAtLocation_args();
587
      args.setItemId(itemId);
588
      sendBase("getItemAvailabilityAtLocation", args);
589
    }
590
 
591
    public List<Long> recv_getItemAvailabilityAtLocation() throws InventoryServiceException, org.apache.thrift.TException
592
    {
593
      getItemAvailabilityAtLocation_result result = new getItemAvailabilityAtLocation_result();
594
      receiveBase(result, "getItemAvailabilityAtLocation");
595
      if (result.isSetSuccess()) {
596
        return result.success;
597
      }
598
      if (result.isex != null) {
599
        throw result.isex;
600
      }
601
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemAvailabilityAtLocation failed: unknown result");
602
    }
603
 
604
    public List<Warehouse> getAllWarehouses(boolean isActive) throws InventoryServiceException, org.apache.thrift.TException
605
    {
606
      send_getAllWarehouses(isActive);
607
      return recv_getAllWarehouses();
608
    }
609
 
610
    public void send_getAllWarehouses(boolean isActive) throws org.apache.thrift.TException
611
    {
612
      getAllWarehouses_args args = new getAllWarehouses_args();
613
      args.setIsActive(isActive);
614
      sendBase("getAllWarehouses", args);
615
    }
616
 
617
    public List<Warehouse> recv_getAllWarehouses() throws InventoryServiceException, org.apache.thrift.TException
618
    {
619
      getAllWarehouses_result result = new getAllWarehouses_result();
620
      receiveBase(result, "getAllWarehouses");
621
      if (result.isSetSuccess()) {
622
        return result.success;
623
      }
624
      if (result.cex != null) {
625
        throw result.cex;
626
      }
627
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllWarehouses failed: unknown result");
628
    }
629
 
630
    public Warehouse getWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
631
    {
632
      send_getWarehouse(warehouse_id);
633
      return recv_getWarehouse();
634
    }
635
 
636
    public void send_getWarehouse(long warehouse_id) throws org.apache.thrift.TException
637
    {
638
      getWarehouse_args args = new getWarehouse_args();
639
      args.setWarehouse_id(warehouse_id);
640
      sendBase("getWarehouse", args);
641
    }
642
 
643
    public Warehouse recv_getWarehouse() throws InventoryServiceException, org.apache.thrift.TException
644
    {
645
      getWarehouse_result result = new getWarehouse_result();
646
      receiveBase(result, "getWarehouse");
647
      if (result.isSetSuccess()) {
648
        return result.success;
649
      }
650
      if (result.cex != null) {
651
        throw result.cex;
652
      }
653
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getWarehouse failed: unknown result");
654
    }
655
 
656
    public List<Long> getAllItemsForWarehouse(long warehouse_id) throws InventoryServiceException, org.apache.thrift.TException
657
    {
658
      send_getAllItemsForWarehouse(warehouse_id);
659
      return recv_getAllItemsForWarehouse();
660
    }
661
 
662
    public void send_getAllItemsForWarehouse(long warehouse_id) throws org.apache.thrift.TException
663
    {
664
      getAllItemsForWarehouse_args args = new getAllItemsForWarehouse_args();
665
      args.setWarehouse_id(warehouse_id);
666
      sendBase("getAllItemsForWarehouse", args);
667
    }
668
 
669
    public List<Long> recv_getAllItemsForWarehouse() throws InventoryServiceException, org.apache.thrift.TException
670
    {
671
      getAllItemsForWarehouse_result result = new getAllItemsForWarehouse_result();
672
      receiveBase(result, "getAllItemsForWarehouse");
673
      if (result.isSetSuccess()) {
674
        return result.success;
675
      }
676
      if (result.cex != null) {
677
        throw result.cex;
678
      }
679
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllItemsForWarehouse failed: unknown result");
680
    }
681
 
5967 rajveer 682
    public boolean isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId) throws org.apache.thrift.TException
5945 mandeep.dh 683
    {
5967 rajveer 684
      send_isOrderBillable(itemId, warehouseId, sourceId, orderId);
685
      return recv_isOrderBillable();
686
    }
687
 
688
    public void send_isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId) throws org.apache.thrift.TException
689
    {
690
      isOrderBillable_args args = new isOrderBillable_args();
691
      args.setItemId(itemId);
692
      args.setWarehouseId(warehouseId);
693
      args.setSourceId(sourceId);
694
      args.setOrderId(orderId);
695
      sendBase("isOrderBillable", args);
696
    }
697
 
698
    public boolean recv_isOrderBillable() throws org.apache.thrift.TException
699
    {
700
      isOrderBillable_result result = new isOrderBillable_result();
701
      receiveBase(result, "isOrderBillable");
702
      if (result.isSetSuccess()) {
703
        return result.success;
704
      }
705
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "isOrderBillable failed: unknown result");
706
    }
707
 
708
    public boolean reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity) throws InventoryServiceException, org.apache.thrift.TException
709
    {
710
      send_reserveItemInWarehouse(itemId, warehouseId, sourceId, orderId, createdTimestamp, promisedShippingTimestamp, quantity);
5945 mandeep.dh 711
      return recv_reserveItemInWarehouse();
712
    }
713
 
5967 rajveer 714
    public void send_reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity) throws org.apache.thrift.TException
5945 mandeep.dh 715
    {
716
      reserveItemInWarehouse_args args = new reserveItemInWarehouse_args();
717
      args.setItemId(itemId);
718
      args.setWarehouseId(warehouseId);
5967 rajveer 719
      args.setSourceId(sourceId);
720
      args.setOrderId(orderId);
721
      args.setCreatedTimestamp(createdTimestamp);
722
      args.setPromisedShippingTimestamp(promisedShippingTimestamp);
5945 mandeep.dh 723
      args.setQuantity(quantity);
724
      sendBase("reserveItemInWarehouse", args);
725
    }
726
 
727
    public boolean recv_reserveItemInWarehouse() throws InventoryServiceException, org.apache.thrift.TException
728
    {
729
      reserveItemInWarehouse_result result = new reserveItemInWarehouse_result();
730
      receiveBase(result, "reserveItemInWarehouse");
731
      if (result.isSetSuccess()) {
732
        return result.success;
733
      }
734
      if (result.cex != null) {
735
        throw result.cex;
736
      }
737
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "reserveItemInWarehouse failed: unknown result");
738
    }
739
 
5967 rajveer 740
    public boolean reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity) throws InventoryServiceException, org.apache.thrift.TException
5945 mandeep.dh 741
    {
5967 rajveer 742
      send_reduceReservationCount(itemId, warehouseId, sourceId, orderId, quantity);
5945 mandeep.dh 743
      return recv_reduceReservationCount();
744
    }
745
 
5967 rajveer 746
    public void send_reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity) throws org.apache.thrift.TException
5945 mandeep.dh 747
    {
748
      reduceReservationCount_args args = new reduceReservationCount_args();
749
      args.setItemId(itemId);
750
      args.setWarehouseId(warehouseId);
5967 rajveer 751
      args.setSourceId(sourceId);
752
      args.setOrderId(orderId);
5945 mandeep.dh 753
      args.setQuantity(quantity);
754
      sendBase("reduceReservationCount", args);
755
    }
756
 
757
    public boolean recv_reduceReservationCount() throws InventoryServiceException, org.apache.thrift.TException
758
    {
759
      reduceReservationCount_result result = new reduceReservationCount_result();
760
      receiveBase(result, "reduceReservationCount");
761
      if (result.isSetSuccess()) {
762
        return result.success;
763
      }
764
      if (result.cex != null) {
765
        throw result.cex;
766
      }
767
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "reduceReservationCount failed: unknown result");
768
    }
769
 
770
    public VendorItemPricing getItemPricing(long itemId, long vendorId) throws InventoryServiceException, org.apache.thrift.TException
771
    {
772
      send_getItemPricing(itemId, vendorId);
773
      return recv_getItemPricing();
774
    }
775
 
776
    public void send_getItemPricing(long itemId, long vendorId) throws org.apache.thrift.TException
777
    {
778
      getItemPricing_args args = new getItemPricing_args();
779
      args.setItemId(itemId);
780
      args.setVendorId(vendorId);
781
      sendBase("getItemPricing", args);
782
    }
783
 
784
    public VendorItemPricing recv_getItemPricing() throws InventoryServiceException, org.apache.thrift.TException
785
    {
786
      getItemPricing_result result = new getItemPricing_result();
787
      receiveBase(result, "getItemPricing");
788
      if (result.isSetSuccess()) {
789
        return result.success;
790
      }
791
      if (result.cex != null) {
792
        throw result.cex;
793
      }
794
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemPricing failed: unknown result");
795
    }
796
 
797
    public List<VendorItemPricing> getAllItemPricing(long itemId) throws InventoryServiceException, org.apache.thrift.TException
798
    {
799
      send_getAllItemPricing(itemId);
800
      return recv_getAllItemPricing();
801
    }
802
 
803
    public void send_getAllItemPricing(long itemId) throws org.apache.thrift.TException
804
    {
805
      getAllItemPricing_args args = new getAllItemPricing_args();
806
      args.setItemId(itemId);
807
      sendBase("getAllItemPricing", args);
808
    }
809
 
810
    public List<VendorItemPricing> recv_getAllItemPricing() throws InventoryServiceException, org.apache.thrift.TException
811
    {
812
      getAllItemPricing_result result = new getAllItemPricing_result();
813
      receiveBase(result, "getAllItemPricing");
814
      if (result.isSetSuccess()) {
815
        return result.success;
816
      }
817
      if (result.cex != null) {
818
        throw result.cex;
819
      }
820
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllItemPricing failed: unknown result");
821
    }
822
 
823
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing) throws InventoryServiceException, org.apache.thrift.TException
824
    {
825
      send_addVendorItemPricing(vendorItemPricing);
826
      recv_addVendorItemPricing();
827
    }
828
 
829
    public void send_addVendorItemPricing(VendorItemPricing vendorItemPricing) throws org.apache.thrift.TException
830
    {
831
      addVendorItemPricing_args args = new addVendorItemPricing_args();
832
      args.setVendorItemPricing(vendorItemPricing);
833
      sendBase("addVendorItemPricing", args);
834
    }
835
 
836
    public void recv_addVendorItemPricing() throws InventoryServiceException, org.apache.thrift.TException
837
    {
838
      addVendorItemPricing_result result = new addVendorItemPricing_result();
839
      receiveBase(result, "addVendorItemPricing");
840
      if (result.cex != null) {
841
        throw result.cex;
842
      }
843
      return;
844
    }
845
 
846
    public Vendor getVendor(long vendorId) throws org.apache.thrift.TException
847
    {
848
      send_getVendor(vendorId);
849
      return recv_getVendor();
850
    }
851
 
852
    public void send_getVendor(long vendorId) throws org.apache.thrift.TException
853
    {
854
      getVendor_args args = new getVendor_args();
855
      args.setVendorId(vendorId);
856
      sendBase("getVendor", args);
857
    }
858
 
859
    public Vendor recv_getVendor() throws org.apache.thrift.TException
860
    {
861
      getVendor_result result = new getVendor_result();
862
      receiveBase(result, "getVendor");
863
      if (result.isSetSuccess()) {
864
        return result.success;
865
      }
866
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getVendor failed: unknown result");
867
    }
868
 
869
    public List<Vendor> getAllVendors() throws org.apache.thrift.TException
870
    {
871
      send_getAllVendors();
872
      return recv_getAllVendors();
873
    }
874
 
875
    public void send_getAllVendors() throws org.apache.thrift.TException
876
    {
877
      getAllVendors_args args = new getAllVendors_args();
878
      sendBase("getAllVendors", args);
879
    }
880
 
881
    public List<Vendor> recv_getAllVendors() throws org.apache.thrift.TException
882
    {
883
      getAllVendors_result result = new getAllVendors_result();
884
      receiveBase(result, "getAllVendors");
885
      if (result.isSetSuccess()) {
886
        return result.success;
887
      }
888
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllVendors failed: unknown result");
889
    }
890
 
891
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws InventoryServiceException, org.apache.thrift.TException
892
    {
893
      send_addVendorItemMapping(key, vendorItemMapping);
894
      recv_addVendorItemMapping();
895
    }
896
 
897
    public void send_addVendorItemMapping(String key, VendorItemMapping vendorItemMapping) throws org.apache.thrift.TException
898
    {
899
      addVendorItemMapping_args args = new addVendorItemMapping_args();
900
      args.setKey(key);
901
      args.setVendorItemMapping(vendorItemMapping);
902
      sendBase("addVendorItemMapping", args);
903
    }
904
 
905
    public void recv_addVendorItemMapping() throws InventoryServiceException, org.apache.thrift.TException
906
    {
907
      addVendorItemMapping_result result = new addVendorItemMapping_result();
908
      receiveBase(result, "addVendorItemMapping");
909
      if (result.cex != null) {
910
        throw result.cex;
911
      }
912
      return;
913
    }
914
 
915
    public List<VendorItemMapping> getVendorItemMappings(long itemId) throws InventoryServiceException, org.apache.thrift.TException
916
    {
917
      send_getVendorItemMappings(itemId);
918
      return recv_getVendorItemMappings();
919
    }
920
 
921
    public void send_getVendorItemMappings(long itemId) throws org.apache.thrift.TException
922
    {
923
      getVendorItemMappings_args args = new getVendorItemMappings_args();
924
      args.setItemId(itemId);
925
      sendBase("getVendorItemMappings", args);
926
    }
927
 
928
    public List<VendorItemMapping> recv_getVendorItemMappings() throws InventoryServiceException, org.apache.thrift.TException
929
    {
930
      getVendorItemMappings_result result = new getVendorItemMappings_result();
931
      receiveBase(result, "getVendorItemMappings");
932
      if (result.isSetSuccess()) {
933
        return result.success;
934
      }
935
      if (result.cex != null) {
936
        throw result.cex;
937
      }
938
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getVendorItemMappings failed: unknown result");
939
    }
940
 
941
    public List<AvailableAndReservedStock> getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException
942
    {
943
      send_getPendingOrdersInventory(vendorid);
944
      return recv_getPendingOrdersInventory();
945
    }
946
 
947
    public void send_getPendingOrdersInventory(long vendorid) throws org.apache.thrift.TException
948
    {
949
      getPendingOrdersInventory_args args = new getPendingOrdersInventory_args();
950
      args.setVendorid(vendorid);
951
      sendBase("getPendingOrdersInventory", args);
952
    }
953
 
954
    public List<AvailableAndReservedStock> recv_getPendingOrdersInventory() throws org.apache.thrift.TException
955
    {
956
      getPendingOrdersInventory_result result = new getPendingOrdersInventory_result();
957
      receiveBase(result, "getPendingOrdersInventory");
958
      if (result.isSetSuccess()) {
959
        return result.success;
960
      }
961
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getPendingOrdersInventory failed: unknown result");
962
    }
963
 
964
    public List<Warehouse> getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException
965
    {
966
      send_getWarehouses(warehouseType, inventoryType, vendorId, billingWarehouseId, shippingWarehouseId);
967
      return recv_getWarehouses();
968
    }
969
 
970
    public void send_getWarehouses(WarehouseType warehouseType, InventoryType inventoryType, long vendorId, long billingWarehouseId, long shippingWarehouseId) throws org.apache.thrift.TException
971
    {
972
      getWarehouses_args args = new getWarehouses_args();
973
      args.setWarehouseType(warehouseType);
974
      args.setInventoryType(inventoryType);
975
      args.setVendorId(vendorId);
976
      args.setBillingWarehouseId(billingWarehouseId);
977
      args.setShippingWarehouseId(shippingWarehouseId);
978
      sendBase("getWarehouses", args);
979
    }
980
 
981
    public List<Warehouse> recv_getWarehouses() throws org.apache.thrift.TException
982
    {
983
      getWarehouses_result result = new getWarehouses_result();
984
      receiveBase(result, "getWarehouses");
985
      if (result.isSetSuccess()) {
986
        return result.success;
987
      }
988
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getWarehouses failed: unknown result");
989
    }
990
 
991
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws InventoryServiceException, org.apache.thrift.TException
992
    {
993
      send_resetAvailability(itemKey, vendorId, quantity, warehouseId);
994
      recv_resetAvailability();
995
    }
996
 
997
    public void send_resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId) throws org.apache.thrift.TException
998
    {
999
      resetAvailability_args args = new resetAvailability_args();
1000
      args.setItemKey(itemKey);
1001
      args.setVendorId(vendorId);
1002
      args.setQuantity(quantity);
1003
      args.setWarehouseId(warehouseId);
1004
      sendBase("resetAvailability", args);
1005
    }
1006
 
1007
    public void recv_resetAvailability() throws InventoryServiceException, org.apache.thrift.TException
1008
    {
1009
      resetAvailability_result result = new resetAvailability_result();
1010
      receiveBase(result, "resetAvailability");
1011
      if (result.cex != null) {
1012
        throw result.cex;
1013
      }
1014
      return;
1015
    }
1016
 
1017
    public void resetAvailabilityForWarehouse(long warehouseId) throws InventoryServiceException, org.apache.thrift.TException
1018
    {
1019
      send_resetAvailabilityForWarehouse(warehouseId);
1020
      recv_resetAvailabilityForWarehouse();
1021
    }
1022
 
1023
    public void send_resetAvailabilityForWarehouse(long warehouseId) throws org.apache.thrift.TException
1024
    {
1025
      resetAvailabilityForWarehouse_args args = new resetAvailabilityForWarehouse_args();
1026
      args.setWarehouseId(warehouseId);
1027
      sendBase("resetAvailabilityForWarehouse", args);
1028
    }
1029
 
1030
    public void recv_resetAvailabilityForWarehouse() throws InventoryServiceException, org.apache.thrift.TException
1031
    {
1032
      resetAvailabilityForWarehouse_result result = new resetAvailabilityForWarehouse_result();
1033
      receiveBase(result, "resetAvailabilityForWarehouse");
1034
      if (result.cex != null) {
1035
        throw result.cex;
1036
      }
1037
      return;
1038
    }
1039
 
1040
    public List<String> getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException
1041
    {
1042
      send_getItemKeysToBeProcessed(warehouseId);
1043
      return recv_getItemKeysToBeProcessed();
1044
    }
1045
 
1046
    public void send_getItemKeysToBeProcessed(long warehouseId) throws org.apache.thrift.TException
1047
    {
1048
      getItemKeysToBeProcessed_args args = new getItemKeysToBeProcessed_args();
1049
      args.setWarehouseId(warehouseId);
1050
      sendBase("getItemKeysToBeProcessed", args);
1051
    }
1052
 
1053
    public List<String> recv_getItemKeysToBeProcessed() throws org.apache.thrift.TException
1054
    {
1055
      getItemKeysToBeProcessed_result result = new getItemKeysToBeProcessed_result();
1056
      receiveBase(result, "getItemKeysToBeProcessed");
1057
      if (result.isSetSuccess()) {
1058
        return result.success;
1059
      }
1060
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getItemKeysToBeProcessed failed: unknown result");
1061
    }
1062
 
1063
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException
1064
    {
1065
      send_markMissedInventoryUpdatesAsProcessed(itemKey, warehouseId);
1066
      recv_markMissedInventoryUpdatesAsProcessed();
1067
    }
1068
 
1069
    public void send_markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId) throws org.apache.thrift.TException
1070
    {
1071
      markMissedInventoryUpdatesAsProcessed_args args = new markMissedInventoryUpdatesAsProcessed_args();
1072
      args.setItemKey(itemKey);
1073
      args.setWarehouseId(warehouseId);
1074
      sendBase("markMissedInventoryUpdatesAsProcessed", args);
1075
    }
1076
 
1077
    public void recv_markMissedInventoryUpdatesAsProcessed() throws org.apache.thrift.TException
1078
    {
1079
      markMissedInventoryUpdatesAsProcessed_result result = new markMissedInventoryUpdatesAsProcessed_result();
1080
      receiveBase(result, "markMissedInventoryUpdatesAsProcessed");
1081
      return;
1082
    }
1083
 
1084
    public Map<String,Map<Long,Long>> getIgnoredItemKeys() throws org.apache.thrift.TException
1085
    {
1086
      send_getIgnoredItemKeys();
1087
      return recv_getIgnoredItemKeys();
1088
    }
1089
 
1090
    public void send_getIgnoredItemKeys() throws org.apache.thrift.TException
1091
    {
1092
      getIgnoredItemKeys_args args = new getIgnoredItemKeys_args();
1093
      sendBase("getIgnoredItemKeys", args);
1094
    }
1095
 
1096
    public Map<String,Map<Long,Long>> recv_getIgnoredItemKeys() throws org.apache.thrift.TException
1097
    {
1098
      getIgnoredItemKeys_result result = new getIgnoredItemKeys_result();
1099
      receiveBase(result, "getIgnoredItemKeys");
1100
      if (result.isSetSuccess()) {
1101
        return result.success;
1102
      }
1103
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getIgnoredItemKeys failed: unknown result");
1104
    }
1105
 
1106
    public void addBadInventory(long itemId, long warehouseId, long quantity) throws InventoryServiceException, org.apache.thrift.TException
1107
    {
1108
      send_addBadInventory(itemId, warehouseId, quantity);
1109
      recv_addBadInventory();
1110
    }
1111
 
1112
    public void send_addBadInventory(long itemId, long warehouseId, long quantity) throws org.apache.thrift.TException
1113
    {
1114
      addBadInventory_args args = new addBadInventory_args();
1115
      args.setItemId(itemId);
1116
      args.setWarehouseId(warehouseId);
1117
      args.setQuantity(quantity);
1118
      sendBase("addBadInventory", args);
1119
    }
1120
 
1121
    public void recv_addBadInventory() throws InventoryServiceException, org.apache.thrift.TException
1122
    {
1123
      addBadInventory_result result = new addBadInventory_result();
1124
      receiveBase(result, "addBadInventory");
1125
      if (result.cex != null) {
1126
        throw result.cex;
1127
      }
1128
      return;
1129
    }
1130
 
1131
    public List<Warehouse> getShippingLocations() throws org.apache.thrift.TException
1132
    {
1133
      send_getShippingLocations();
1134
      return recv_getShippingLocations();
1135
    }
1136
 
1137
    public void send_getShippingLocations() throws org.apache.thrift.TException
1138
    {
1139
      getShippingLocations_args args = new getShippingLocations_args();
1140
      sendBase("getShippingLocations", args);
1141
    }
1142
 
1143
    public List<Warehouse> recv_getShippingLocations() throws org.apache.thrift.TException
1144
    {
1145
      getShippingLocations_result result = new getShippingLocations_result();
1146
      receiveBase(result, "getShippingLocations");
1147
      if (result.isSetSuccess()) {
1148
        return result.success;
1149
      }
1150
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getShippingLocations failed: unknown result");
1151
    }
1152
 
1153
    public List<VendorItemMapping> getAllVendorItemMappings() throws org.apache.thrift.TException
1154
    {
1155
      send_getAllVendorItemMappings();
1156
      return recv_getAllVendorItemMappings();
1157
    }
1158
 
1159
    public void send_getAllVendorItemMappings() throws org.apache.thrift.TException
1160
    {
1161
      getAllVendorItemMappings_args args = new getAllVendorItemMappings_args();
1162
      sendBase("getAllVendorItemMappings", args);
1163
    }
1164
 
1165
    public List<VendorItemMapping> recv_getAllVendorItemMappings() throws org.apache.thrift.TException
1166
    {
1167
      getAllVendorItemMappings_result result = new getAllVendorItemMappings_result();
1168
      receiveBase(result, "getAllVendorItemMappings");
1169
      if (result.isSetSuccess()) {
1170
        return result.success;
1171
      }
1172
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllVendorItemMappings failed: unknown result");
1173
    }
1174
 
1175
    public Map<Long,ItemInventory> getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException
1176
    {
1177
      send_getInventorySnapshot(warehouseId);
1178
      return recv_getInventorySnapshot();
1179
    }
1180
 
1181
    public void send_getInventorySnapshot(long warehouseId) throws org.apache.thrift.TException
1182
    {
1183
      getInventorySnapshot_args args = new getInventorySnapshot_args();
1184
      args.setWarehouseId(warehouseId);
1185
      sendBase("getInventorySnapshot", args);
1186
    }
1187
 
1188
    public Map<Long,ItemInventory> recv_getInventorySnapshot() throws org.apache.thrift.TException
1189
    {
1190
      getInventorySnapshot_result result = new getInventorySnapshot_result();
1191
      receiveBase(result, "getInventorySnapshot");
1192
      if (result.isSetSuccess()) {
1193
        return result.success;
1194
      }
1195
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getInventorySnapshot failed: unknown result");
1196
    }
1197
 
1198
    public void clearItemAvailabilityCache() throws org.apache.thrift.TException
1199
    {
1200
      send_clearItemAvailabilityCache();
1201
      recv_clearItemAvailabilityCache();
1202
    }
1203
 
1204
    public void send_clearItemAvailabilityCache() throws org.apache.thrift.TException
1205
    {
1206
      clearItemAvailabilityCache_args args = new clearItemAvailabilityCache_args();
1207
      sendBase("clearItemAvailabilityCache", args);
1208
    }
1209
 
1210
    public void recv_clearItemAvailabilityCache() throws org.apache.thrift.TException
1211
    {
1212
      clearItemAvailabilityCache_result result = new clearItemAvailabilityCache_result();
1213
      receiveBase(result, "clearItemAvailabilityCache");
1214
      return;
1215
    }
1216
 
1217
    public void updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException
1218
    {
1219
      send_updateVendorString(warehouseId, vendorString);
1220
      recv_updateVendorString();
1221
    }
1222
 
1223
    public void send_updateVendorString(long warehouseId, String vendorString) throws org.apache.thrift.TException
1224
    {
1225
      updateVendorString_args args = new updateVendorString_args();
1226
      args.setWarehouseId(warehouseId);
1227
      args.setVendorString(vendorString);
1228
      sendBase("updateVendorString", args);
1229
    }
1230
 
1231
    public void recv_updateVendorString() throws org.apache.thrift.TException
1232
    {
1233
      updateVendorString_result result = new updateVendorString_result();
1234
      receiveBase(result, "updateVendorString");
1235
      return;
1236
    }
1237
 
1238
  }
1239
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
1240
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
1241
      private org.apache.thrift.async.TAsyncClientManager clientManager;
1242
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
1243
      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
1244
        this.clientManager = clientManager;
1245
        this.protocolFactory = protocolFactory;
1246
      }
1247
      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
1248
        return new AsyncClient(protocolFactory, clientManager, transport);
1249
      }
1250
    }
1251
 
1252
    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
1253
      super(protocolFactory, clientManager, transport);
1254
    }
1255
 
1256
    public void addWarehouse(Warehouse warehouse, org.apache.thrift.async.AsyncMethodCallback<addWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1257
      checkReady();
1258
      addWarehouse_call method_call = new addWarehouse_call(warehouse, resultHandler, this, ___protocolFactory, ___transport);
1259
      this.___currentMethod = method_call;
1260
      ___manager.call(method_call);
1261
    }
1262
 
1263
    public static class addWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1264
      private Warehouse warehouse;
1265
      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 {
1266
        super(client, protocolFactory, transport, resultHandler, false);
1267
        this.warehouse = warehouse;
1268
      }
1269
 
1270
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1271
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1272
        addWarehouse_args args = new addWarehouse_args();
1273
        args.setWarehouse(warehouse);
1274
        args.write(prot);
1275
        prot.writeMessageEnd();
1276
      }
1277
 
1278
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1279
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1280
          throw new IllegalStateException("Method call not finished!");
1281
        }
1282
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1283
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1284
        return (new Client(prot)).recv_addWarehouse();
1285
      }
1286
    }
1287
 
1288
    public void addVendor(Vendor vendor, org.apache.thrift.async.AsyncMethodCallback<addVendor_call> resultHandler) throws org.apache.thrift.TException {
1289
      checkReady();
1290
      addVendor_call method_call = new addVendor_call(vendor, resultHandler, this, ___protocolFactory, ___transport);
1291
      this.___currentMethod = method_call;
1292
      ___manager.call(method_call);
1293
    }
1294
 
1295
    public static class addVendor_call extends org.apache.thrift.async.TAsyncMethodCall {
1296
      private Vendor vendor;
1297
      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 {
1298
        super(client, protocolFactory, transport, resultHandler, false);
1299
        this.vendor = vendor;
1300
      }
1301
 
1302
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1303
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendor", org.apache.thrift.protocol.TMessageType.CALL, 0));
1304
        addVendor_args args = new addVendor_args();
1305
        args.setVendor(vendor);
1306
        args.write(prot);
1307
        prot.writeMessageEnd();
1308
      }
1309
 
1310
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1311
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1312
          throw new IllegalStateException("Method call not finished!");
1313
        }
1314
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1315
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1316
        return (new Client(prot)).recv_addVendor();
1317
      }
1318
    }
1319
 
1320
    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 {
1321
      checkReady();
1322
      updateInventoryHistory_call method_call = new updateInventoryHistory_call(warehouse_id, timestamp, availability, resultHandler, this, ___protocolFactory, ___transport);
1323
      this.___currentMethod = method_call;
1324
      ___manager.call(method_call);
1325
    }
1326
 
1327
    public static class updateInventoryHistory_call extends org.apache.thrift.async.TAsyncMethodCall {
1328
      private long warehouse_id;
1329
      private String timestamp;
1330
      private Map<String,Long> availability;
1331
      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 {
1332
        super(client, protocolFactory, transport, resultHandler, false);
1333
        this.warehouse_id = warehouse_id;
1334
        this.timestamp = timestamp;
1335
        this.availability = availability;
1336
      }
1337
 
1338
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1339
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateInventoryHistory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1340
        updateInventoryHistory_args args = new updateInventoryHistory_args();
1341
        args.setWarehouse_id(warehouse_id);
1342
        args.setTimestamp(timestamp);
1343
        args.setAvailability(availability);
1344
        args.write(prot);
1345
        prot.writeMessageEnd();
1346
      }
1347
 
1348
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1349
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1350
          throw new IllegalStateException("Method call not finished!");
1351
        }
1352
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1353
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1354
        (new Client(prot)).recv_updateInventoryHistory();
1355
      }
1356
    }
1357
 
1358
    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 {
1359
      checkReady();
1360
      updateInventory_call method_call = new updateInventory_call(warehouse_id, timestamp, availability, resultHandler, this, ___protocolFactory, ___transport);
1361
      this.___currentMethod = method_call;
1362
      ___manager.call(method_call);
1363
    }
1364
 
1365
    public static class updateInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
1366
      private long warehouse_id;
1367
      private String timestamp;
1368
      private Map<String,Long> availability;
1369
      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 {
1370
        super(client, protocolFactory, transport, resultHandler, false);
1371
        this.warehouse_id = warehouse_id;
1372
        this.timestamp = timestamp;
1373
        this.availability = availability;
1374
      }
1375
 
1376
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1377
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1378
        updateInventory_args args = new updateInventory_args();
1379
        args.setWarehouse_id(warehouse_id);
1380
        args.setTimestamp(timestamp);
1381
        args.setAvailability(availability);
1382
        args.write(prot);
1383
        prot.writeMessageEnd();
1384
      }
1385
 
1386
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1387
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1388
          throw new IllegalStateException("Method call not finished!");
1389
        }
1390
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1391
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1392
        (new Client(prot)).recv_updateInventory();
1393
      }
1394
    }
1395
 
1396
    public void addInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addInventory_call> resultHandler) throws org.apache.thrift.TException {
1397
      checkReady();
1398
      addInventory_call method_call = new addInventory_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
1399
      this.___currentMethod = method_call;
1400
      ___manager.call(method_call);
1401
    }
1402
 
1403
    public static class addInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
1404
      private long itemId;
1405
      private long warehouseId;
1406
      private long quantity;
1407
      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 {
1408
        super(client, protocolFactory, transport, resultHandler, false);
1409
        this.itemId = itemId;
1410
        this.warehouseId = warehouseId;
1411
        this.quantity = quantity;
1412
      }
1413
 
1414
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1415
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
1416
        addInventory_args args = new addInventory_args();
1417
        args.setItemId(itemId);
1418
        args.setWarehouseId(warehouseId);
1419
        args.setQuantity(quantity);
1420
        args.write(prot);
1421
        prot.writeMessageEnd();
1422
      }
1423
 
1424
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1425
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1426
          throw new IllegalStateException("Method call not finished!");
1427
        }
1428
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1429
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1430
        (new Client(prot)).recv_addInventory();
1431
      }
1432
    }
1433
 
1434
    public void retireWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<retireWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1435
      checkReady();
1436
      retireWarehouse_call method_call = new retireWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1437
      this.___currentMethod = method_call;
1438
      ___manager.call(method_call);
1439
    }
1440
 
1441
    public static class retireWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1442
      private long warehouse_id;
1443
      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 {
1444
        super(client, protocolFactory, transport, resultHandler, false);
1445
        this.warehouse_id = warehouse_id;
1446
      }
1447
 
1448
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1449
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("retireWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1450
        retireWarehouse_args args = new retireWarehouse_args();
1451
        args.setWarehouse_id(warehouse_id);
1452
        args.write(prot);
1453
        prot.writeMessageEnd();
1454
      }
1455
 
1456
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1457
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1458
          throw new IllegalStateException("Method call not finished!");
1459
        }
1460
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1461
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1462
        (new Client(prot)).recv_retireWarehouse();
1463
      }
1464
    }
1465
 
1466
    public void getItemInventoryByItemId(long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemInventoryByItemId_call> resultHandler) throws org.apache.thrift.TException {
1467
      checkReady();
1468
      getItemInventoryByItemId_call method_call = new getItemInventoryByItemId_call(item_id, resultHandler, this, ___protocolFactory, ___transport);
1469
      this.___currentMethod = method_call;
1470
      ___manager.call(method_call);
1471
    }
1472
 
1473
    public static class getItemInventoryByItemId_call extends org.apache.thrift.async.TAsyncMethodCall {
1474
      private long item_id;
1475
      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 {
1476
        super(client, protocolFactory, transport, resultHandler, false);
1477
        this.item_id = item_id;
1478
      }
1479
 
1480
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1481
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemInventoryByItemId", org.apache.thrift.protocol.TMessageType.CALL, 0));
1482
        getItemInventoryByItemId_args args = new getItemInventoryByItemId_args();
1483
        args.setItem_id(item_id);
1484
        args.write(prot);
1485
        prot.writeMessageEnd();
1486
      }
1487
 
1488
      public ItemInventory getResult() throws InventoryServiceException, org.apache.thrift.TException {
1489
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1490
          throw new IllegalStateException("Method call not finished!");
1491
        }
1492
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1493
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1494
        return (new Client(prot)).recv_getItemInventoryByItemId();
1495
      }
1496
    }
1497
 
1498
    public void getItemAvailibilityAtWarehouse(long warehouse_id, long item_id, org.apache.thrift.async.AsyncMethodCallback<getItemAvailibilityAtWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1499
      checkReady();
1500
      getItemAvailibilityAtWarehouse_call method_call = new getItemAvailibilityAtWarehouse_call(warehouse_id, item_id, resultHandler, this, ___protocolFactory, ___transport);
1501
      this.___currentMethod = method_call;
1502
      ___manager.call(method_call);
1503
    }
1504
 
1505
    public static class getItemAvailibilityAtWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1506
      private long warehouse_id;
1507
      private long item_id;
1508
      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 {
1509
        super(client, protocolFactory, transport, resultHandler, false);
1510
        this.warehouse_id = warehouse_id;
1511
        this.item_id = item_id;
1512
      }
1513
 
1514
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1515
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemAvailibilityAtWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1516
        getItemAvailibilityAtWarehouse_args args = new getItemAvailibilityAtWarehouse_args();
1517
        args.setWarehouse_id(warehouse_id);
1518
        args.setItem_id(item_id);
1519
        args.write(prot);
1520
        prot.writeMessageEnd();
1521
      }
1522
 
1523
      public long getResult() throws InventoryServiceException, org.apache.thrift.TException {
1524
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1525
          throw new IllegalStateException("Method call not finished!");
1526
        }
1527
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1528
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1529
        return (new Client(prot)).recv_getItemAvailibilityAtWarehouse();
1530
      }
1531
    }
1532
 
1533
    public void getItemAvailabilityAtLocation(long itemId, org.apache.thrift.async.AsyncMethodCallback<getItemAvailabilityAtLocation_call> resultHandler) throws org.apache.thrift.TException {
1534
      checkReady();
1535
      getItemAvailabilityAtLocation_call method_call = new getItemAvailabilityAtLocation_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1536
      this.___currentMethod = method_call;
1537
      ___manager.call(method_call);
1538
    }
1539
 
1540
    public static class getItemAvailabilityAtLocation_call extends org.apache.thrift.async.TAsyncMethodCall {
1541
      private long itemId;
1542
      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 {
1543
        super(client, protocolFactory, transport, resultHandler, false);
1544
        this.itemId = itemId;
1545
      }
1546
 
1547
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1548
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemAvailabilityAtLocation", org.apache.thrift.protocol.TMessageType.CALL, 0));
1549
        getItemAvailabilityAtLocation_args args = new getItemAvailabilityAtLocation_args();
1550
        args.setItemId(itemId);
1551
        args.write(prot);
1552
        prot.writeMessageEnd();
1553
      }
1554
 
1555
      public List<Long> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1556
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1557
          throw new IllegalStateException("Method call not finished!");
1558
        }
1559
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1560
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1561
        return (new Client(prot)).recv_getItemAvailabilityAtLocation();
1562
      }
1563
    }
1564
 
1565
    public void getAllWarehouses(boolean isActive, org.apache.thrift.async.AsyncMethodCallback<getAllWarehouses_call> resultHandler) throws org.apache.thrift.TException {
1566
      checkReady();
1567
      getAllWarehouses_call method_call = new getAllWarehouses_call(isActive, resultHandler, this, ___protocolFactory, ___transport);
1568
      this.___currentMethod = method_call;
1569
      ___manager.call(method_call);
1570
    }
1571
 
1572
    public static class getAllWarehouses_call extends org.apache.thrift.async.TAsyncMethodCall {
1573
      private boolean isActive;
1574
      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 {
1575
        super(client, protocolFactory, transport, resultHandler, false);
1576
        this.isActive = isActive;
1577
      }
1578
 
1579
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1580
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllWarehouses", org.apache.thrift.protocol.TMessageType.CALL, 0));
1581
        getAllWarehouses_args args = new getAllWarehouses_args();
1582
        args.setIsActive(isActive);
1583
        args.write(prot);
1584
        prot.writeMessageEnd();
1585
      }
1586
 
1587
      public List<Warehouse> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1588
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1589
          throw new IllegalStateException("Method call not finished!");
1590
        }
1591
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1592
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1593
        return (new Client(prot)).recv_getAllWarehouses();
1594
      }
1595
    }
1596
 
1597
    public void getWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1598
      checkReady();
1599
      getWarehouse_call method_call = new getWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1600
      this.___currentMethod = method_call;
1601
      ___manager.call(method_call);
1602
    }
1603
 
1604
    public static class getWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1605
      private long warehouse_id;
1606
      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 {
1607
        super(client, protocolFactory, transport, resultHandler, false);
1608
        this.warehouse_id = warehouse_id;
1609
      }
1610
 
1611
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1612
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1613
        getWarehouse_args args = new getWarehouse_args();
1614
        args.setWarehouse_id(warehouse_id);
1615
        args.write(prot);
1616
        prot.writeMessageEnd();
1617
      }
1618
 
1619
      public Warehouse getResult() throws InventoryServiceException, org.apache.thrift.TException {
1620
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1621
          throw new IllegalStateException("Method call not finished!");
1622
        }
1623
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1624
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1625
        return (new Client(prot)).recv_getWarehouse();
1626
      }
1627
    }
1628
 
1629
    public void getAllItemsForWarehouse(long warehouse_id, org.apache.thrift.async.AsyncMethodCallback<getAllItemsForWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1630
      checkReady();
1631
      getAllItemsForWarehouse_call method_call = new getAllItemsForWarehouse_call(warehouse_id, resultHandler, this, ___protocolFactory, ___transport);
1632
      this.___currentMethod = method_call;
1633
      ___manager.call(method_call);
1634
    }
1635
 
1636
    public static class getAllItemsForWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1637
      private long warehouse_id;
1638
      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 {
1639
        super(client, protocolFactory, transport, resultHandler, false);
1640
        this.warehouse_id = warehouse_id;
1641
      }
1642
 
1643
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1644
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllItemsForWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1645
        getAllItemsForWarehouse_args args = new getAllItemsForWarehouse_args();
1646
        args.setWarehouse_id(warehouse_id);
1647
        args.write(prot);
1648
        prot.writeMessageEnd();
1649
      }
1650
 
1651
      public List<Long> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1652
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1653
          throw new IllegalStateException("Method call not finished!");
1654
        }
1655
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1656
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1657
        return (new Client(prot)).recv_getAllItemsForWarehouse();
1658
      }
1659
    }
1660
 
5967 rajveer 1661
    public void isOrderBillable(long itemId, long warehouseId, long sourceId, long orderId, org.apache.thrift.async.AsyncMethodCallback<isOrderBillable_call> resultHandler) throws org.apache.thrift.TException {
5945 mandeep.dh 1662
      checkReady();
5967 rajveer 1663
      isOrderBillable_call method_call = new isOrderBillable_call(itemId, warehouseId, sourceId, orderId, resultHandler, this, ___protocolFactory, ___transport);
5945 mandeep.dh 1664
      this.___currentMethod = method_call;
1665
      ___manager.call(method_call);
1666
    }
1667
 
5967 rajveer 1668
    public static class isOrderBillable_call extends org.apache.thrift.async.TAsyncMethodCall {
1669
      private long itemId;
1670
      private long warehouseId;
1671
      private long sourceId;
1672
      private long orderId;
1673
      public isOrderBillable_call(long itemId, long warehouseId, long sourceId, long orderId, org.apache.thrift.async.AsyncMethodCallback<isOrderBillable_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
1674
        super(client, protocolFactory, transport, resultHandler, false);
1675
        this.itemId = itemId;
1676
        this.warehouseId = warehouseId;
1677
        this.sourceId = sourceId;
1678
        this.orderId = orderId;
1679
      }
1680
 
1681
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1682
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("isOrderBillable", org.apache.thrift.protocol.TMessageType.CALL, 0));
1683
        isOrderBillable_args args = new isOrderBillable_args();
1684
        args.setItemId(itemId);
1685
        args.setWarehouseId(warehouseId);
1686
        args.setSourceId(sourceId);
1687
        args.setOrderId(orderId);
1688
        args.write(prot);
1689
        prot.writeMessageEnd();
1690
      }
1691
 
1692
      public boolean getResult() throws org.apache.thrift.TException {
1693
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1694
          throw new IllegalStateException("Method call not finished!");
1695
        }
1696
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1697
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1698
        return (new Client(prot)).recv_isOrderBillable();
1699
      }
1700
    }
1701
 
1702
    public void reserveItemInWarehouse(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity, org.apache.thrift.async.AsyncMethodCallback<reserveItemInWarehouse_call> resultHandler) throws org.apache.thrift.TException {
1703
      checkReady();
1704
      reserveItemInWarehouse_call method_call = new reserveItemInWarehouse_call(itemId, warehouseId, sourceId, orderId, createdTimestamp, promisedShippingTimestamp, quantity, resultHandler, this, ___protocolFactory, ___transport);
1705
      this.___currentMethod = method_call;
1706
      ___manager.call(method_call);
1707
    }
1708
 
5945 mandeep.dh 1709
    public static class reserveItemInWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
1710
      private long itemId;
1711
      private long warehouseId;
5967 rajveer 1712
      private long sourceId;
1713
      private long orderId;
1714
      private long createdTimestamp;
1715
      private long promisedShippingTimestamp;
5945 mandeep.dh 1716
      private double quantity;
5967 rajveer 1717
      public reserveItemInWarehouse_call(long itemId, long warehouseId, long sourceId, long orderId, long createdTimestamp, long promisedShippingTimestamp, double quantity, org.apache.thrift.async.AsyncMethodCallback<reserveItemInWarehouse_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
5945 mandeep.dh 1718
        super(client, protocolFactory, transport, resultHandler, false);
1719
        this.itemId = itemId;
1720
        this.warehouseId = warehouseId;
5967 rajveer 1721
        this.sourceId = sourceId;
1722
        this.orderId = orderId;
1723
        this.createdTimestamp = createdTimestamp;
1724
        this.promisedShippingTimestamp = promisedShippingTimestamp;
5945 mandeep.dh 1725
        this.quantity = quantity;
1726
      }
1727
 
1728
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1729
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("reserveItemInWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
1730
        reserveItemInWarehouse_args args = new reserveItemInWarehouse_args();
1731
        args.setItemId(itemId);
1732
        args.setWarehouseId(warehouseId);
5967 rajveer 1733
        args.setSourceId(sourceId);
1734
        args.setOrderId(orderId);
1735
        args.setCreatedTimestamp(createdTimestamp);
1736
        args.setPromisedShippingTimestamp(promisedShippingTimestamp);
5945 mandeep.dh 1737
        args.setQuantity(quantity);
1738
        args.write(prot);
1739
        prot.writeMessageEnd();
1740
      }
1741
 
1742
      public boolean getResult() throws InventoryServiceException, org.apache.thrift.TException {
1743
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1744
          throw new IllegalStateException("Method call not finished!");
1745
        }
1746
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1747
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1748
        return (new Client(prot)).recv_reserveItemInWarehouse();
1749
      }
1750
    }
1751
 
5967 rajveer 1752
    public void reduceReservationCount(long itemId, long warehouseId, long sourceId, long orderId, double quantity, org.apache.thrift.async.AsyncMethodCallback<reduceReservationCount_call> resultHandler) throws org.apache.thrift.TException {
5945 mandeep.dh 1753
      checkReady();
5967 rajveer 1754
      reduceReservationCount_call method_call = new reduceReservationCount_call(itemId, warehouseId, sourceId, orderId, quantity, resultHandler, this, ___protocolFactory, ___transport);
5945 mandeep.dh 1755
      this.___currentMethod = method_call;
1756
      ___manager.call(method_call);
1757
    }
1758
 
1759
    public static class reduceReservationCount_call extends org.apache.thrift.async.TAsyncMethodCall {
1760
      private long itemId;
1761
      private long warehouseId;
5967 rajveer 1762
      private long sourceId;
1763
      private long orderId;
5945 mandeep.dh 1764
      private double quantity;
5967 rajveer 1765
      public reduceReservationCount_call(long itemId, long warehouseId, long sourceId, long orderId, double quantity, org.apache.thrift.async.AsyncMethodCallback<reduceReservationCount_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
5945 mandeep.dh 1766
        super(client, protocolFactory, transport, resultHandler, false);
1767
        this.itemId = itemId;
1768
        this.warehouseId = warehouseId;
5967 rajveer 1769
        this.sourceId = sourceId;
1770
        this.orderId = orderId;
5945 mandeep.dh 1771
        this.quantity = quantity;
1772
      }
1773
 
1774
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1775
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("reduceReservationCount", org.apache.thrift.protocol.TMessageType.CALL, 0));
1776
        reduceReservationCount_args args = new reduceReservationCount_args();
1777
        args.setItemId(itemId);
1778
        args.setWarehouseId(warehouseId);
5967 rajveer 1779
        args.setSourceId(sourceId);
1780
        args.setOrderId(orderId);
5945 mandeep.dh 1781
        args.setQuantity(quantity);
1782
        args.write(prot);
1783
        prot.writeMessageEnd();
1784
      }
1785
 
1786
      public boolean getResult() throws InventoryServiceException, org.apache.thrift.TException {
1787
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1788
          throw new IllegalStateException("Method call not finished!");
1789
        }
1790
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1791
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1792
        return (new Client(prot)).recv_reduceReservationCount();
1793
      }
1794
    }
1795
 
1796
    public void getItemPricing(long itemId, long vendorId, org.apache.thrift.async.AsyncMethodCallback<getItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1797
      checkReady();
1798
      getItemPricing_call method_call = new getItemPricing_call(itemId, vendorId, resultHandler, this, ___protocolFactory, ___transport);
1799
      this.___currentMethod = method_call;
1800
      ___manager.call(method_call);
1801
    }
1802
 
1803
    public static class getItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1804
      private long itemId;
1805
      private long vendorId;
1806
      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 {
1807
        super(client, protocolFactory, transport, resultHandler, false);
1808
        this.itemId = itemId;
1809
        this.vendorId = vendorId;
1810
      }
1811
 
1812
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1813
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1814
        getItemPricing_args args = new getItemPricing_args();
1815
        args.setItemId(itemId);
1816
        args.setVendorId(vendorId);
1817
        args.write(prot);
1818
        prot.writeMessageEnd();
1819
      }
1820
 
1821
      public VendorItemPricing getResult() throws InventoryServiceException, org.apache.thrift.TException {
1822
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1823
          throw new IllegalStateException("Method call not finished!");
1824
        }
1825
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1826
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1827
        return (new Client(prot)).recv_getItemPricing();
1828
      }
1829
    }
1830
 
1831
    public void getAllItemPricing(long itemId, org.apache.thrift.async.AsyncMethodCallback<getAllItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1832
      checkReady();
1833
      getAllItemPricing_call method_call = new getAllItemPricing_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1834
      this.___currentMethod = method_call;
1835
      ___manager.call(method_call);
1836
    }
1837
 
1838
    public static class getAllItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1839
      private long itemId;
1840
      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 {
1841
        super(client, protocolFactory, transport, resultHandler, false);
1842
        this.itemId = itemId;
1843
      }
1844
 
1845
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1846
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1847
        getAllItemPricing_args args = new getAllItemPricing_args();
1848
        args.setItemId(itemId);
1849
        args.write(prot);
1850
        prot.writeMessageEnd();
1851
      }
1852
 
1853
      public List<VendorItemPricing> getResult() throws InventoryServiceException, org.apache.thrift.TException {
1854
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1855
          throw new IllegalStateException("Method call not finished!");
1856
        }
1857
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1858
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1859
        return (new Client(prot)).recv_getAllItemPricing();
1860
      }
1861
    }
1862
 
1863
    public void addVendorItemPricing(VendorItemPricing vendorItemPricing, org.apache.thrift.async.AsyncMethodCallback<addVendorItemPricing_call> resultHandler) throws org.apache.thrift.TException {
1864
      checkReady();
1865
      addVendorItemPricing_call method_call = new addVendorItemPricing_call(vendorItemPricing, resultHandler, this, ___protocolFactory, ___transport);
1866
      this.___currentMethod = method_call;
1867
      ___manager.call(method_call);
1868
    }
1869
 
1870
    public static class addVendorItemPricing_call extends org.apache.thrift.async.TAsyncMethodCall {
1871
      private VendorItemPricing vendorItemPricing;
1872
      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 {
1873
        super(client, protocolFactory, transport, resultHandler, false);
1874
        this.vendorItemPricing = vendorItemPricing;
1875
      }
1876
 
1877
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1878
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendorItemPricing", org.apache.thrift.protocol.TMessageType.CALL, 0));
1879
        addVendorItemPricing_args args = new addVendorItemPricing_args();
1880
        args.setVendorItemPricing(vendorItemPricing);
1881
        args.write(prot);
1882
        prot.writeMessageEnd();
1883
      }
1884
 
1885
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1886
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1887
          throw new IllegalStateException("Method call not finished!");
1888
        }
1889
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1890
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1891
        (new Client(prot)).recv_addVendorItemPricing();
1892
      }
1893
    }
1894
 
1895
    public void getVendor(long vendorId, org.apache.thrift.async.AsyncMethodCallback<getVendor_call> resultHandler) throws org.apache.thrift.TException {
1896
      checkReady();
1897
      getVendor_call method_call = new getVendor_call(vendorId, resultHandler, this, ___protocolFactory, ___transport);
1898
      this.___currentMethod = method_call;
1899
      ___manager.call(method_call);
1900
    }
1901
 
1902
    public static class getVendor_call extends org.apache.thrift.async.TAsyncMethodCall {
1903
      private long vendorId;
1904
      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 {
1905
        super(client, protocolFactory, transport, resultHandler, false);
1906
        this.vendorId = vendorId;
1907
      }
1908
 
1909
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1910
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getVendor", org.apache.thrift.protocol.TMessageType.CALL, 0));
1911
        getVendor_args args = new getVendor_args();
1912
        args.setVendorId(vendorId);
1913
        args.write(prot);
1914
        prot.writeMessageEnd();
1915
      }
1916
 
1917
      public Vendor getResult() throws org.apache.thrift.TException {
1918
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1919
          throw new IllegalStateException("Method call not finished!");
1920
        }
1921
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1922
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1923
        return (new Client(prot)).recv_getVendor();
1924
      }
1925
    }
1926
 
1927
    public void getAllVendors(org.apache.thrift.async.AsyncMethodCallback<getAllVendors_call> resultHandler) throws org.apache.thrift.TException {
1928
      checkReady();
1929
      getAllVendors_call method_call = new getAllVendors_call(resultHandler, this, ___protocolFactory, ___transport);
1930
      this.___currentMethod = method_call;
1931
      ___manager.call(method_call);
1932
    }
1933
 
1934
    public static class getAllVendors_call extends org.apache.thrift.async.TAsyncMethodCall {
1935
      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 {
1936
        super(client, protocolFactory, transport, resultHandler, false);
1937
      }
1938
 
1939
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1940
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllVendors", org.apache.thrift.protocol.TMessageType.CALL, 0));
1941
        getAllVendors_args args = new getAllVendors_args();
1942
        args.write(prot);
1943
        prot.writeMessageEnd();
1944
      }
1945
 
1946
      public List<Vendor> getResult() throws org.apache.thrift.TException {
1947
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1948
          throw new IllegalStateException("Method call not finished!");
1949
        }
1950
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1951
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1952
        return (new Client(prot)).recv_getAllVendors();
1953
      }
1954
    }
1955
 
1956
    public void addVendorItemMapping(String key, VendorItemMapping vendorItemMapping, org.apache.thrift.async.AsyncMethodCallback<addVendorItemMapping_call> resultHandler) throws org.apache.thrift.TException {
1957
      checkReady();
1958
      addVendorItemMapping_call method_call = new addVendorItemMapping_call(key, vendorItemMapping, resultHandler, this, ___protocolFactory, ___transport);
1959
      this.___currentMethod = method_call;
1960
      ___manager.call(method_call);
1961
    }
1962
 
1963
    public static class addVendorItemMapping_call extends org.apache.thrift.async.TAsyncMethodCall {
1964
      private String key;
1965
      private VendorItemMapping vendorItemMapping;
1966
      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 {
1967
        super(client, protocolFactory, transport, resultHandler, false);
1968
        this.key = key;
1969
        this.vendorItemMapping = vendorItemMapping;
1970
      }
1971
 
1972
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
1973
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addVendorItemMapping", org.apache.thrift.protocol.TMessageType.CALL, 0));
1974
        addVendorItemMapping_args args = new addVendorItemMapping_args();
1975
        args.setKey(key);
1976
        args.setVendorItemMapping(vendorItemMapping);
1977
        args.write(prot);
1978
        prot.writeMessageEnd();
1979
      }
1980
 
1981
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
1982
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
1983
          throw new IllegalStateException("Method call not finished!");
1984
        }
1985
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
1986
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
1987
        (new Client(prot)).recv_addVendorItemMapping();
1988
      }
1989
    }
1990
 
1991
    public void getVendorItemMappings(long itemId, org.apache.thrift.async.AsyncMethodCallback<getVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException {
1992
      checkReady();
1993
      getVendorItemMappings_call method_call = new getVendorItemMappings_call(itemId, resultHandler, this, ___protocolFactory, ___transport);
1994
      this.___currentMethod = method_call;
1995
      ___manager.call(method_call);
1996
    }
1997
 
1998
    public static class getVendorItemMappings_call extends org.apache.thrift.async.TAsyncMethodCall {
1999
      private long itemId;
2000
      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 {
2001
        super(client, protocolFactory, transport, resultHandler, false);
2002
        this.itemId = itemId;
2003
      }
2004
 
2005
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2006
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getVendorItemMappings", org.apache.thrift.protocol.TMessageType.CALL, 0));
2007
        getVendorItemMappings_args args = new getVendorItemMappings_args();
2008
        args.setItemId(itemId);
2009
        args.write(prot);
2010
        prot.writeMessageEnd();
2011
      }
2012
 
2013
      public List<VendorItemMapping> getResult() throws InventoryServiceException, org.apache.thrift.TException {
2014
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2015
          throw new IllegalStateException("Method call not finished!");
2016
        }
2017
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2018
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2019
        return (new Client(prot)).recv_getVendorItemMappings();
2020
      }
2021
    }
2022
 
2023
    public void getPendingOrdersInventory(long vendorid, org.apache.thrift.async.AsyncMethodCallback<getPendingOrdersInventory_call> resultHandler) throws org.apache.thrift.TException {
2024
      checkReady();
2025
      getPendingOrdersInventory_call method_call = new getPendingOrdersInventory_call(vendorid, resultHandler, this, ___protocolFactory, ___transport);
2026
      this.___currentMethod = method_call;
2027
      ___manager.call(method_call);
2028
    }
2029
 
2030
    public static class getPendingOrdersInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
2031
      private long vendorid;
2032
      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 {
2033
        super(client, protocolFactory, transport, resultHandler, false);
2034
        this.vendorid = vendorid;
2035
      }
2036
 
2037
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2038
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getPendingOrdersInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
2039
        getPendingOrdersInventory_args args = new getPendingOrdersInventory_args();
2040
        args.setVendorid(vendorid);
2041
        args.write(prot);
2042
        prot.writeMessageEnd();
2043
      }
2044
 
2045
      public List<AvailableAndReservedStock> getResult() throws org.apache.thrift.TException {
2046
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2047
          throw new IllegalStateException("Method call not finished!");
2048
        }
2049
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2050
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2051
        return (new Client(prot)).recv_getPendingOrdersInventory();
2052
      }
2053
    }
2054
 
2055
    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 {
2056
      checkReady();
2057
      getWarehouses_call method_call = new getWarehouses_call(warehouseType, inventoryType, vendorId, billingWarehouseId, shippingWarehouseId, resultHandler, this, ___protocolFactory, ___transport);
2058
      this.___currentMethod = method_call;
2059
      ___manager.call(method_call);
2060
    }
2061
 
2062
    public static class getWarehouses_call extends org.apache.thrift.async.TAsyncMethodCall {
2063
      private WarehouseType warehouseType;
2064
      private InventoryType inventoryType;
2065
      private long vendorId;
2066
      private long billingWarehouseId;
2067
      private long shippingWarehouseId;
2068
      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 {
2069
        super(client, protocolFactory, transport, resultHandler, false);
2070
        this.warehouseType = warehouseType;
2071
        this.inventoryType = inventoryType;
2072
        this.vendorId = vendorId;
2073
        this.billingWarehouseId = billingWarehouseId;
2074
        this.shippingWarehouseId = shippingWarehouseId;
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("getWarehouses", org.apache.thrift.protocol.TMessageType.CALL, 0));
2079
        getWarehouses_args args = new getWarehouses_args();
2080
        args.setWarehouseType(warehouseType);
2081
        args.setInventoryType(inventoryType);
2082
        args.setVendorId(vendorId);
2083
        args.setBillingWarehouseId(billingWarehouseId);
2084
        args.setShippingWarehouseId(shippingWarehouseId);
2085
        args.write(prot);
2086
        prot.writeMessageEnd();
2087
      }
2088
 
2089
      public List<Warehouse> getResult() throws org.apache.thrift.TException {
2090
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2091
          throw new IllegalStateException("Method call not finished!");
2092
        }
2093
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2094
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2095
        return (new Client(prot)).recv_getWarehouses();
2096
      }
2097
    }
2098
 
2099
    public void resetAvailability(String itemKey, long vendorId, long quantity, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailability_call> resultHandler) throws org.apache.thrift.TException {
2100
      checkReady();
2101
      resetAvailability_call method_call = new resetAvailability_call(itemKey, vendorId, quantity, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2102
      this.___currentMethod = method_call;
2103
      ___manager.call(method_call);
2104
    }
2105
 
2106
    public static class resetAvailability_call extends org.apache.thrift.async.TAsyncMethodCall {
2107
      private String itemKey;
2108
      private long vendorId;
2109
      private long quantity;
2110
      private long warehouseId;
2111
      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 {
2112
        super(client, protocolFactory, transport, resultHandler, false);
2113
        this.itemKey = itemKey;
2114
        this.vendorId = vendorId;
2115
        this.quantity = quantity;
2116
        this.warehouseId = warehouseId;
2117
      }
2118
 
2119
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2120
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("resetAvailability", org.apache.thrift.protocol.TMessageType.CALL, 0));
2121
        resetAvailability_args args = new resetAvailability_args();
2122
        args.setItemKey(itemKey);
2123
        args.setVendorId(vendorId);
2124
        args.setQuantity(quantity);
2125
        args.setWarehouseId(warehouseId);
2126
        args.write(prot);
2127
        prot.writeMessageEnd();
2128
      }
2129
 
2130
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2131
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2132
          throw new IllegalStateException("Method call not finished!");
2133
        }
2134
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2135
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2136
        (new Client(prot)).recv_resetAvailability();
2137
      }
2138
    }
2139
 
2140
    public void resetAvailabilityForWarehouse(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<resetAvailabilityForWarehouse_call> resultHandler) throws org.apache.thrift.TException {
2141
      checkReady();
2142
      resetAvailabilityForWarehouse_call method_call = new resetAvailabilityForWarehouse_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2143
      this.___currentMethod = method_call;
2144
      ___manager.call(method_call);
2145
    }
2146
 
2147
    public static class resetAvailabilityForWarehouse_call extends org.apache.thrift.async.TAsyncMethodCall {
2148
      private long warehouseId;
2149
      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 {
2150
        super(client, protocolFactory, transport, resultHandler, false);
2151
        this.warehouseId = warehouseId;
2152
      }
2153
 
2154
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2155
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("resetAvailabilityForWarehouse", org.apache.thrift.protocol.TMessageType.CALL, 0));
2156
        resetAvailabilityForWarehouse_args args = new resetAvailabilityForWarehouse_args();
2157
        args.setWarehouseId(warehouseId);
2158
        args.write(prot);
2159
        prot.writeMessageEnd();
2160
      }
2161
 
2162
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2163
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2164
          throw new IllegalStateException("Method call not finished!");
2165
        }
2166
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2167
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2168
        (new Client(prot)).recv_resetAvailabilityForWarehouse();
2169
      }
2170
    }
2171
 
2172
    public void getItemKeysToBeProcessed(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getItemKeysToBeProcessed_call> resultHandler) throws org.apache.thrift.TException {
2173
      checkReady();
2174
      getItemKeysToBeProcessed_call method_call = new getItemKeysToBeProcessed_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2175
      this.___currentMethod = method_call;
2176
      ___manager.call(method_call);
2177
    }
2178
 
2179
    public static class getItemKeysToBeProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
2180
      private long warehouseId;
2181
      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 {
2182
        super(client, protocolFactory, transport, resultHandler, false);
2183
        this.warehouseId = warehouseId;
2184
      }
2185
 
2186
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2187
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getItemKeysToBeProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
2188
        getItemKeysToBeProcessed_args args = new getItemKeysToBeProcessed_args();
2189
        args.setWarehouseId(warehouseId);
2190
        args.write(prot);
2191
        prot.writeMessageEnd();
2192
      }
2193
 
2194
      public List<String> getResult() throws org.apache.thrift.TException {
2195
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2196
          throw new IllegalStateException("Method call not finished!");
2197
        }
2198
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2199
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2200
        return (new Client(prot)).recv_getItemKeysToBeProcessed();
2201
      }
2202
    }
2203
 
2204
    public void markMissedInventoryUpdatesAsProcessed(String itemKey, long warehouseId, org.apache.thrift.async.AsyncMethodCallback<markMissedInventoryUpdatesAsProcessed_call> resultHandler) throws org.apache.thrift.TException {
2205
      checkReady();
2206
      markMissedInventoryUpdatesAsProcessed_call method_call = new markMissedInventoryUpdatesAsProcessed_call(itemKey, warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2207
      this.___currentMethod = method_call;
2208
      ___manager.call(method_call);
2209
    }
2210
 
2211
    public static class markMissedInventoryUpdatesAsProcessed_call extends org.apache.thrift.async.TAsyncMethodCall {
2212
      private String itemKey;
2213
      private long warehouseId;
2214
      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 {
2215
        super(client, protocolFactory, transport, resultHandler, false);
2216
        this.itemKey = itemKey;
2217
        this.warehouseId = warehouseId;
2218
      }
2219
 
2220
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2221
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("markMissedInventoryUpdatesAsProcessed", org.apache.thrift.protocol.TMessageType.CALL, 0));
2222
        markMissedInventoryUpdatesAsProcessed_args args = new markMissedInventoryUpdatesAsProcessed_args();
2223
        args.setItemKey(itemKey);
2224
        args.setWarehouseId(warehouseId);
2225
        args.write(prot);
2226
        prot.writeMessageEnd();
2227
      }
2228
 
2229
      public void getResult() throws org.apache.thrift.TException {
2230
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2231
          throw new IllegalStateException("Method call not finished!");
2232
        }
2233
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2234
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2235
        (new Client(prot)).recv_markMissedInventoryUpdatesAsProcessed();
2236
      }
2237
    }
2238
 
2239
    public void getIgnoredItemKeys(org.apache.thrift.async.AsyncMethodCallback<getIgnoredItemKeys_call> resultHandler) throws org.apache.thrift.TException {
2240
      checkReady();
2241
      getIgnoredItemKeys_call method_call = new getIgnoredItemKeys_call(resultHandler, this, ___protocolFactory, ___transport);
2242
      this.___currentMethod = method_call;
2243
      ___manager.call(method_call);
2244
    }
2245
 
2246
    public static class getIgnoredItemKeys_call extends org.apache.thrift.async.TAsyncMethodCall {
2247
      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 {
2248
        super(client, protocolFactory, transport, resultHandler, false);
2249
      }
2250
 
2251
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2252
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getIgnoredItemKeys", org.apache.thrift.protocol.TMessageType.CALL, 0));
2253
        getIgnoredItemKeys_args args = new getIgnoredItemKeys_args();
2254
        args.write(prot);
2255
        prot.writeMessageEnd();
2256
      }
2257
 
2258
      public Map<String,Map<Long,Long>> getResult() throws org.apache.thrift.TException {
2259
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2260
          throw new IllegalStateException("Method call not finished!");
2261
        }
2262
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2263
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2264
        return (new Client(prot)).recv_getIgnoredItemKeys();
2265
      }
2266
    }
2267
 
2268
    public void addBadInventory(long itemId, long warehouseId, long quantity, org.apache.thrift.async.AsyncMethodCallback<addBadInventory_call> resultHandler) throws org.apache.thrift.TException {
2269
      checkReady();
2270
      addBadInventory_call method_call = new addBadInventory_call(itemId, warehouseId, quantity, resultHandler, this, ___protocolFactory, ___transport);
2271
      this.___currentMethod = method_call;
2272
      ___manager.call(method_call);
2273
    }
2274
 
2275
    public static class addBadInventory_call extends org.apache.thrift.async.TAsyncMethodCall {
2276
      private long itemId;
2277
      private long warehouseId;
2278
      private long quantity;
2279
      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 {
2280
        super(client, protocolFactory, transport, resultHandler, false);
2281
        this.itemId = itemId;
2282
        this.warehouseId = warehouseId;
2283
        this.quantity = quantity;
2284
      }
2285
 
2286
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2287
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("addBadInventory", org.apache.thrift.protocol.TMessageType.CALL, 0));
2288
        addBadInventory_args args = new addBadInventory_args();
2289
        args.setItemId(itemId);
2290
        args.setWarehouseId(warehouseId);
2291
        args.setQuantity(quantity);
2292
        args.write(prot);
2293
        prot.writeMessageEnd();
2294
      }
2295
 
2296
      public void getResult() throws InventoryServiceException, org.apache.thrift.TException {
2297
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2298
          throw new IllegalStateException("Method call not finished!");
2299
        }
2300
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2301
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2302
        (new Client(prot)).recv_addBadInventory();
2303
      }
2304
    }
2305
 
2306
    public void getShippingLocations(org.apache.thrift.async.AsyncMethodCallback<getShippingLocations_call> resultHandler) throws org.apache.thrift.TException {
2307
      checkReady();
2308
      getShippingLocations_call method_call = new getShippingLocations_call(resultHandler, this, ___protocolFactory, ___transport);
2309
      this.___currentMethod = method_call;
2310
      ___manager.call(method_call);
2311
    }
2312
 
2313
    public static class getShippingLocations_call extends org.apache.thrift.async.TAsyncMethodCall {
2314
      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 {
2315
        super(client, protocolFactory, transport, resultHandler, false);
2316
      }
2317
 
2318
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2319
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getShippingLocations", org.apache.thrift.protocol.TMessageType.CALL, 0));
2320
        getShippingLocations_args args = new getShippingLocations_args();
2321
        args.write(prot);
2322
        prot.writeMessageEnd();
2323
      }
2324
 
2325
      public List<Warehouse> getResult() throws org.apache.thrift.TException {
2326
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2327
          throw new IllegalStateException("Method call not finished!");
2328
        }
2329
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2330
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2331
        return (new Client(prot)).recv_getShippingLocations();
2332
      }
2333
    }
2334
 
2335
    public void getAllVendorItemMappings(org.apache.thrift.async.AsyncMethodCallback<getAllVendorItemMappings_call> resultHandler) throws org.apache.thrift.TException {
2336
      checkReady();
2337
      getAllVendorItemMappings_call method_call = new getAllVendorItemMappings_call(resultHandler, this, ___protocolFactory, ___transport);
2338
      this.___currentMethod = method_call;
2339
      ___manager.call(method_call);
2340
    }
2341
 
2342
    public static class getAllVendorItemMappings_call extends org.apache.thrift.async.TAsyncMethodCall {
2343
      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 {
2344
        super(client, protocolFactory, transport, resultHandler, false);
2345
      }
2346
 
2347
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2348
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllVendorItemMappings", org.apache.thrift.protocol.TMessageType.CALL, 0));
2349
        getAllVendorItemMappings_args args = new getAllVendorItemMappings_args();
2350
        args.write(prot);
2351
        prot.writeMessageEnd();
2352
      }
2353
 
2354
      public List<VendorItemMapping> getResult() throws org.apache.thrift.TException {
2355
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2356
          throw new IllegalStateException("Method call not finished!");
2357
        }
2358
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2359
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2360
        return (new Client(prot)).recv_getAllVendorItemMappings();
2361
      }
2362
    }
2363
 
2364
    public void getInventorySnapshot(long warehouseId, org.apache.thrift.async.AsyncMethodCallback<getInventorySnapshot_call> resultHandler) throws org.apache.thrift.TException {
2365
      checkReady();
2366
      getInventorySnapshot_call method_call = new getInventorySnapshot_call(warehouseId, resultHandler, this, ___protocolFactory, ___transport);
2367
      this.___currentMethod = method_call;
2368
      ___manager.call(method_call);
2369
    }
2370
 
2371
    public static class getInventorySnapshot_call extends org.apache.thrift.async.TAsyncMethodCall {
2372
      private long warehouseId;
2373
      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 {
2374
        super(client, protocolFactory, transport, resultHandler, false);
2375
        this.warehouseId = warehouseId;
2376
      }
2377
 
2378
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2379
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getInventorySnapshot", org.apache.thrift.protocol.TMessageType.CALL, 0));
2380
        getInventorySnapshot_args args = new getInventorySnapshot_args();
2381
        args.setWarehouseId(warehouseId);
2382
        args.write(prot);
2383
        prot.writeMessageEnd();
2384
      }
2385
 
2386
      public Map<Long,ItemInventory> getResult() throws org.apache.thrift.TException {
2387
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2388
          throw new IllegalStateException("Method call not finished!");
2389
        }
2390
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2391
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2392
        return (new Client(prot)).recv_getInventorySnapshot();
2393
      }
2394
    }
2395
 
2396
    public void clearItemAvailabilityCache(org.apache.thrift.async.AsyncMethodCallback<clearItemAvailabilityCache_call> resultHandler) throws org.apache.thrift.TException {
2397
      checkReady();
2398
      clearItemAvailabilityCache_call method_call = new clearItemAvailabilityCache_call(resultHandler, this, ___protocolFactory, ___transport);
2399
      this.___currentMethod = method_call;
2400
      ___manager.call(method_call);
2401
    }
2402
 
2403
    public static class clearItemAvailabilityCache_call extends org.apache.thrift.async.TAsyncMethodCall {
2404
      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 {
2405
        super(client, protocolFactory, transport, resultHandler, false);
2406
      }
2407
 
2408
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2409
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("clearItemAvailabilityCache", org.apache.thrift.protocol.TMessageType.CALL, 0));
2410
        clearItemAvailabilityCache_args args = new clearItemAvailabilityCache_args();
2411
        args.write(prot);
2412
        prot.writeMessageEnd();
2413
      }
2414
 
2415
      public void getResult() throws org.apache.thrift.TException {
2416
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2417
          throw new IllegalStateException("Method call not finished!");
2418
        }
2419
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2420
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2421
        (new Client(prot)).recv_clearItemAvailabilityCache();
2422
      }
2423
    }
2424
 
2425
    public void updateVendorString(long warehouseId, String vendorString, org.apache.thrift.async.AsyncMethodCallback<updateVendorString_call> resultHandler) throws org.apache.thrift.TException {
2426
      checkReady();
2427
      updateVendorString_call method_call = new updateVendorString_call(warehouseId, vendorString, resultHandler, this, ___protocolFactory, ___transport);
2428
      this.___currentMethod = method_call;
2429
      ___manager.call(method_call);
2430
    }
2431
 
2432
    public static class updateVendorString_call extends org.apache.thrift.async.TAsyncMethodCall {
2433
      private long warehouseId;
2434
      private String vendorString;
2435
      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 {
2436
        super(client, protocolFactory, transport, resultHandler, false);
2437
        this.warehouseId = warehouseId;
2438
        this.vendorString = vendorString;
2439
      }
2440
 
2441
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
2442
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("updateVendorString", org.apache.thrift.protocol.TMessageType.CALL, 0));
2443
        updateVendorString_args args = new updateVendorString_args();
2444
        args.setWarehouseId(warehouseId);
2445
        args.setVendorString(vendorString);
2446
        args.write(prot);
2447
        prot.writeMessageEnd();
2448
      }
2449
 
2450
      public void getResult() throws org.apache.thrift.TException {
2451
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
2452
          throw new IllegalStateException("Method call not finished!");
2453
        }
2454
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
2455
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
2456
        (new Client(prot)).recv_updateVendorString();
2457
      }
2458
    }
2459
 
2460
  }
2461
 
2462
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
2463
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
2464
    public Processor(I iface) {
2465
      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
2466
    }
2467
 
2468
    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
2469
      super(iface, getProcessMap(processMap));
2470
    }
2471
 
2472
    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) {
2473
      processMap.put("addWarehouse", new addWarehouse());
2474
      processMap.put("addVendor", new addVendor());
2475
      processMap.put("updateInventoryHistory", new updateInventoryHistory());
2476
      processMap.put("updateInventory", new updateInventory());
2477
      processMap.put("addInventory", new addInventory());
2478
      processMap.put("retireWarehouse", new retireWarehouse());
2479
      processMap.put("getItemInventoryByItemId", new getItemInventoryByItemId());
2480
      processMap.put("getItemAvailibilityAtWarehouse", new getItemAvailibilityAtWarehouse());
2481
      processMap.put("getItemAvailabilityAtLocation", new getItemAvailabilityAtLocation());
2482
      processMap.put("getAllWarehouses", new getAllWarehouses());
2483
      processMap.put("getWarehouse", new getWarehouse());
2484
      processMap.put("getAllItemsForWarehouse", new getAllItemsForWarehouse());
5967 rajveer 2485
      processMap.put("isOrderBillable", new isOrderBillable());
5945 mandeep.dh 2486
      processMap.put("reserveItemInWarehouse", new reserveItemInWarehouse());
2487
      processMap.put("reduceReservationCount", new reduceReservationCount());
2488
      processMap.put("getItemPricing", new getItemPricing());
2489
      processMap.put("getAllItemPricing", new getAllItemPricing());
2490
      processMap.put("addVendorItemPricing", new addVendorItemPricing());
2491
      processMap.put("getVendor", new getVendor());
2492
      processMap.put("getAllVendors", new getAllVendors());
2493
      processMap.put("addVendorItemMapping", new addVendorItemMapping());
2494
      processMap.put("getVendorItemMappings", new getVendorItemMappings());
2495
      processMap.put("getPendingOrdersInventory", new getPendingOrdersInventory());
2496
      processMap.put("getWarehouses", new getWarehouses());
2497
      processMap.put("resetAvailability", new resetAvailability());
2498
      processMap.put("resetAvailabilityForWarehouse", new resetAvailabilityForWarehouse());
2499
      processMap.put("getItemKeysToBeProcessed", new getItemKeysToBeProcessed());
2500
      processMap.put("markMissedInventoryUpdatesAsProcessed", new markMissedInventoryUpdatesAsProcessed());
2501
      processMap.put("getIgnoredItemKeys", new getIgnoredItemKeys());
2502
      processMap.put("addBadInventory", new addBadInventory());
2503
      processMap.put("getShippingLocations", new getShippingLocations());
2504
      processMap.put("getAllVendorItemMappings", new getAllVendorItemMappings());
2505
      processMap.put("getInventorySnapshot", new getInventorySnapshot());
2506
      processMap.put("clearItemAvailabilityCache", new clearItemAvailabilityCache());
2507
      processMap.put("updateVendorString", new updateVendorString());
2508
      return processMap;
2509
    }
2510
 
2511
    private static class addWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addWarehouse_args> {
2512
      public addWarehouse() {
2513
        super("addWarehouse");
2514
      }
2515
 
2516
      protected addWarehouse_args getEmptyArgsInstance() {
2517
        return new addWarehouse_args();
2518
      }
2519
 
2520
      protected addWarehouse_result getResult(I iface, addWarehouse_args args) throws org.apache.thrift.TException {
2521
        addWarehouse_result result = new addWarehouse_result();
2522
        try {
2523
          result.success = iface.addWarehouse(args.warehouse);
2524
          result.setSuccessIsSet(true);
2525
        } catch (InventoryServiceException cex) {
2526
          result.cex = cex;
2527
        }
2528
        return result;
2529
      }
2530
    }
2531
 
2532
    private static class addVendor<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendor_args> {
2533
      public addVendor() {
2534
        super("addVendor");
2535
      }
2536
 
2537
      protected addVendor_args getEmptyArgsInstance() {
2538
        return new addVendor_args();
2539
      }
2540
 
2541
      protected addVendor_result getResult(I iface, addVendor_args args) throws org.apache.thrift.TException {
2542
        addVendor_result result = new addVendor_result();
2543
        try {
2544
          result.success = iface.addVendor(args.vendor);
2545
          result.setSuccessIsSet(true);
2546
        } catch (InventoryServiceException cex) {
2547
          result.cex = cex;
2548
        }
2549
        return result;
2550
      }
2551
    }
2552
 
2553
    private static class updateInventoryHistory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateInventoryHistory_args> {
2554
      public updateInventoryHistory() {
2555
        super("updateInventoryHistory");
2556
      }
2557
 
2558
      protected updateInventoryHistory_args getEmptyArgsInstance() {
2559
        return new updateInventoryHistory_args();
2560
      }
2561
 
2562
      protected updateInventoryHistory_result getResult(I iface, updateInventoryHistory_args args) throws org.apache.thrift.TException {
2563
        updateInventoryHistory_result result = new updateInventoryHistory_result();
2564
        try {
2565
          iface.updateInventoryHistory(args.warehouse_id, args.timestamp, args.availability);
2566
        } catch (InventoryServiceException cex) {
2567
          result.cex = cex;
2568
        }
2569
        return result;
2570
      }
2571
    }
2572
 
2573
    private static class updateInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateInventory_args> {
2574
      public updateInventory() {
2575
        super("updateInventory");
2576
      }
2577
 
2578
      protected updateInventory_args getEmptyArgsInstance() {
2579
        return new updateInventory_args();
2580
      }
2581
 
2582
      protected updateInventory_result getResult(I iface, updateInventory_args args) throws org.apache.thrift.TException {
2583
        updateInventory_result result = new updateInventory_result();
2584
        try {
2585
          iface.updateInventory(args.warehouse_id, args.timestamp, args.availability);
2586
        } catch (InventoryServiceException cex) {
2587
          result.cex = cex;
2588
        }
2589
        return result;
2590
      }
2591
    }
2592
 
2593
    private static class addInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addInventory_args> {
2594
      public addInventory() {
2595
        super("addInventory");
2596
      }
2597
 
2598
      protected addInventory_args getEmptyArgsInstance() {
2599
        return new addInventory_args();
2600
      }
2601
 
2602
      protected addInventory_result getResult(I iface, addInventory_args args) throws org.apache.thrift.TException {
2603
        addInventory_result result = new addInventory_result();
2604
        try {
2605
          iface.addInventory(args.itemId, args.warehouseId, args.quantity);
2606
        } catch (InventoryServiceException cex) {
2607
          result.cex = cex;
2608
        }
2609
        return result;
2610
      }
2611
    }
2612
 
2613
    private static class retireWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, retireWarehouse_args> {
2614
      public retireWarehouse() {
2615
        super("retireWarehouse");
2616
      }
2617
 
2618
      protected retireWarehouse_args getEmptyArgsInstance() {
2619
        return new retireWarehouse_args();
2620
      }
2621
 
2622
      protected retireWarehouse_result getResult(I iface, retireWarehouse_args args) throws org.apache.thrift.TException {
2623
        retireWarehouse_result result = new retireWarehouse_result();
2624
        try {
2625
          iface.retireWarehouse(args.warehouse_id);
2626
        } catch (InventoryServiceException cex) {
2627
          result.cex = cex;
2628
        }
2629
        return result;
2630
      }
2631
    }
2632
 
2633
    private static class getItemInventoryByItemId<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemInventoryByItemId_args> {
2634
      public getItemInventoryByItemId() {
2635
        super("getItemInventoryByItemId");
2636
      }
2637
 
2638
      protected getItemInventoryByItemId_args getEmptyArgsInstance() {
2639
        return new getItemInventoryByItemId_args();
2640
      }
2641
 
2642
      protected getItemInventoryByItemId_result getResult(I iface, getItemInventoryByItemId_args args) throws org.apache.thrift.TException {
2643
        getItemInventoryByItemId_result result = new getItemInventoryByItemId_result();
2644
        try {
2645
          result.success = iface.getItemInventoryByItemId(args.item_id);
2646
        } catch (InventoryServiceException cex) {
2647
          result.cex = cex;
2648
        }
2649
        return result;
2650
      }
2651
    }
2652
 
2653
    private static class getItemAvailibilityAtWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemAvailibilityAtWarehouse_args> {
2654
      public getItemAvailibilityAtWarehouse() {
2655
        super("getItemAvailibilityAtWarehouse");
2656
      }
2657
 
2658
      protected getItemAvailibilityAtWarehouse_args getEmptyArgsInstance() {
2659
        return new getItemAvailibilityAtWarehouse_args();
2660
      }
2661
 
2662
      protected getItemAvailibilityAtWarehouse_result getResult(I iface, getItemAvailibilityAtWarehouse_args args) throws org.apache.thrift.TException {
2663
        getItemAvailibilityAtWarehouse_result result = new getItemAvailibilityAtWarehouse_result();
2664
        try {
2665
          result.success = iface.getItemAvailibilityAtWarehouse(args.warehouse_id, args.item_id);
2666
          result.setSuccessIsSet(true);
2667
        } catch (InventoryServiceException cex) {
2668
          result.cex = cex;
2669
        }
2670
        return result;
2671
      }
2672
    }
2673
 
2674
    private static class getItemAvailabilityAtLocation<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemAvailabilityAtLocation_args> {
2675
      public getItemAvailabilityAtLocation() {
2676
        super("getItemAvailabilityAtLocation");
2677
      }
2678
 
2679
      protected getItemAvailabilityAtLocation_args getEmptyArgsInstance() {
2680
        return new getItemAvailabilityAtLocation_args();
2681
      }
2682
 
2683
      protected getItemAvailabilityAtLocation_result getResult(I iface, getItemAvailabilityAtLocation_args args) throws org.apache.thrift.TException {
2684
        getItemAvailabilityAtLocation_result result = new getItemAvailabilityAtLocation_result();
2685
        try {
2686
          result.success = iface.getItemAvailabilityAtLocation(args.itemId);
2687
        } catch (InventoryServiceException isex) {
2688
          result.isex = isex;
2689
        }
2690
        return result;
2691
      }
2692
    }
2693
 
2694
    private static class getAllWarehouses<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllWarehouses_args> {
2695
      public getAllWarehouses() {
2696
        super("getAllWarehouses");
2697
      }
2698
 
2699
      protected getAllWarehouses_args getEmptyArgsInstance() {
2700
        return new getAllWarehouses_args();
2701
      }
2702
 
2703
      protected getAllWarehouses_result getResult(I iface, getAllWarehouses_args args) throws org.apache.thrift.TException {
2704
        getAllWarehouses_result result = new getAllWarehouses_result();
2705
        try {
2706
          result.success = iface.getAllWarehouses(args.isActive);
2707
        } catch (InventoryServiceException cex) {
2708
          result.cex = cex;
2709
        }
2710
        return result;
2711
      }
2712
    }
2713
 
2714
    private static class getWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getWarehouse_args> {
2715
      public getWarehouse() {
2716
        super("getWarehouse");
2717
      }
2718
 
2719
      protected getWarehouse_args getEmptyArgsInstance() {
2720
        return new getWarehouse_args();
2721
      }
2722
 
2723
      protected getWarehouse_result getResult(I iface, getWarehouse_args args) throws org.apache.thrift.TException {
2724
        getWarehouse_result result = new getWarehouse_result();
2725
        try {
2726
          result.success = iface.getWarehouse(args.warehouse_id);
2727
        } catch (InventoryServiceException cex) {
2728
          result.cex = cex;
2729
        }
2730
        return result;
2731
      }
2732
    }
2733
 
2734
    private static class getAllItemsForWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllItemsForWarehouse_args> {
2735
      public getAllItemsForWarehouse() {
2736
        super("getAllItemsForWarehouse");
2737
      }
2738
 
2739
      protected getAllItemsForWarehouse_args getEmptyArgsInstance() {
2740
        return new getAllItemsForWarehouse_args();
2741
      }
2742
 
2743
      protected getAllItemsForWarehouse_result getResult(I iface, getAllItemsForWarehouse_args args) throws org.apache.thrift.TException {
2744
        getAllItemsForWarehouse_result result = new getAllItemsForWarehouse_result();
2745
        try {
2746
          result.success = iface.getAllItemsForWarehouse(args.warehouse_id);
2747
        } catch (InventoryServiceException cex) {
2748
          result.cex = cex;
2749
        }
2750
        return result;
2751
      }
2752
    }
2753
 
5967 rajveer 2754
    private static class isOrderBillable<I extends Iface> extends org.apache.thrift.ProcessFunction<I, isOrderBillable_args> {
2755
      public isOrderBillable() {
2756
        super("isOrderBillable");
2757
      }
2758
 
2759
      protected isOrderBillable_args getEmptyArgsInstance() {
2760
        return new isOrderBillable_args();
2761
      }
2762
 
2763
      protected isOrderBillable_result getResult(I iface, isOrderBillable_args args) throws org.apache.thrift.TException {
2764
        isOrderBillable_result result = new isOrderBillable_result();
2765
        result.success = iface.isOrderBillable(args.itemId, args.warehouseId, args.sourceId, args.orderId);
2766
        result.setSuccessIsSet(true);
2767
        return result;
2768
      }
2769
    }
2770
 
5945 mandeep.dh 2771
    private static class reserveItemInWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, reserveItemInWarehouse_args> {
2772
      public reserveItemInWarehouse() {
2773
        super("reserveItemInWarehouse");
2774
      }
2775
 
2776
      protected reserveItemInWarehouse_args getEmptyArgsInstance() {
2777
        return new reserveItemInWarehouse_args();
2778
      }
2779
 
2780
      protected reserveItemInWarehouse_result getResult(I iface, reserveItemInWarehouse_args args) throws org.apache.thrift.TException {
2781
        reserveItemInWarehouse_result result = new reserveItemInWarehouse_result();
2782
        try {
5967 rajveer 2783
          result.success = iface.reserveItemInWarehouse(args.itemId, args.warehouseId, args.sourceId, args.orderId, args.createdTimestamp, args.promisedShippingTimestamp, args.quantity);
5945 mandeep.dh 2784
          result.setSuccessIsSet(true);
2785
        } catch (InventoryServiceException cex) {
2786
          result.cex = cex;
2787
        }
2788
        return result;
2789
      }
2790
    }
2791
 
2792
    private static class reduceReservationCount<I extends Iface> extends org.apache.thrift.ProcessFunction<I, reduceReservationCount_args> {
2793
      public reduceReservationCount() {
2794
        super("reduceReservationCount");
2795
      }
2796
 
2797
      protected reduceReservationCount_args getEmptyArgsInstance() {
2798
        return new reduceReservationCount_args();
2799
      }
2800
 
2801
      protected reduceReservationCount_result getResult(I iface, reduceReservationCount_args args) throws org.apache.thrift.TException {
2802
        reduceReservationCount_result result = new reduceReservationCount_result();
2803
        try {
5967 rajveer 2804
          result.success = iface.reduceReservationCount(args.itemId, args.warehouseId, args.sourceId, args.orderId, args.quantity);
5945 mandeep.dh 2805
          result.setSuccessIsSet(true);
2806
        } catch (InventoryServiceException cex) {
2807
          result.cex = cex;
2808
        }
2809
        return result;
2810
      }
2811
    }
2812
 
2813
    private static class getItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemPricing_args> {
2814
      public getItemPricing() {
2815
        super("getItemPricing");
2816
      }
2817
 
2818
      protected getItemPricing_args getEmptyArgsInstance() {
2819
        return new getItemPricing_args();
2820
      }
2821
 
2822
      protected getItemPricing_result getResult(I iface, getItemPricing_args args) throws org.apache.thrift.TException {
2823
        getItemPricing_result result = new getItemPricing_result();
2824
        try {
2825
          result.success = iface.getItemPricing(args.itemId, args.vendorId);
2826
        } catch (InventoryServiceException cex) {
2827
          result.cex = cex;
2828
        }
2829
        return result;
2830
      }
2831
    }
2832
 
2833
    private static class getAllItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllItemPricing_args> {
2834
      public getAllItemPricing() {
2835
        super("getAllItemPricing");
2836
      }
2837
 
2838
      protected getAllItemPricing_args getEmptyArgsInstance() {
2839
        return new getAllItemPricing_args();
2840
      }
2841
 
2842
      protected getAllItemPricing_result getResult(I iface, getAllItemPricing_args args) throws org.apache.thrift.TException {
2843
        getAllItemPricing_result result = new getAllItemPricing_result();
2844
        try {
2845
          result.success = iface.getAllItemPricing(args.itemId);
2846
        } catch (InventoryServiceException cex) {
2847
          result.cex = cex;
2848
        }
2849
        return result;
2850
      }
2851
    }
2852
 
2853
    private static class addVendorItemPricing<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendorItemPricing_args> {
2854
      public addVendorItemPricing() {
2855
        super("addVendorItemPricing");
2856
      }
2857
 
2858
      protected addVendorItemPricing_args getEmptyArgsInstance() {
2859
        return new addVendorItemPricing_args();
2860
      }
2861
 
2862
      protected addVendorItemPricing_result getResult(I iface, addVendorItemPricing_args args) throws org.apache.thrift.TException {
2863
        addVendorItemPricing_result result = new addVendorItemPricing_result();
2864
        try {
2865
          iface.addVendorItemPricing(args.vendorItemPricing);
2866
        } catch (InventoryServiceException cex) {
2867
          result.cex = cex;
2868
        }
2869
        return result;
2870
      }
2871
    }
2872
 
2873
    private static class getVendor<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getVendor_args> {
2874
      public getVendor() {
2875
        super("getVendor");
2876
      }
2877
 
2878
      protected getVendor_args getEmptyArgsInstance() {
2879
        return new getVendor_args();
2880
      }
2881
 
2882
      protected getVendor_result getResult(I iface, getVendor_args args) throws org.apache.thrift.TException {
2883
        getVendor_result result = new getVendor_result();
2884
        result.success = iface.getVendor(args.vendorId);
2885
        return result;
2886
      }
2887
    }
2888
 
2889
    private static class getAllVendors<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllVendors_args> {
2890
      public getAllVendors() {
2891
        super("getAllVendors");
2892
      }
2893
 
2894
      protected getAllVendors_args getEmptyArgsInstance() {
2895
        return new getAllVendors_args();
2896
      }
2897
 
2898
      protected getAllVendors_result getResult(I iface, getAllVendors_args args) throws org.apache.thrift.TException {
2899
        getAllVendors_result result = new getAllVendors_result();
2900
        result.success = iface.getAllVendors();
2901
        return result;
2902
      }
2903
    }
2904
 
2905
    private static class addVendorItemMapping<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addVendorItemMapping_args> {
2906
      public addVendorItemMapping() {
2907
        super("addVendorItemMapping");
2908
      }
2909
 
2910
      protected addVendorItemMapping_args getEmptyArgsInstance() {
2911
        return new addVendorItemMapping_args();
2912
      }
2913
 
2914
      protected addVendorItemMapping_result getResult(I iface, addVendorItemMapping_args args) throws org.apache.thrift.TException {
2915
        addVendorItemMapping_result result = new addVendorItemMapping_result();
2916
        try {
2917
          iface.addVendorItemMapping(args.key, args.vendorItemMapping);
2918
        } catch (InventoryServiceException cex) {
2919
          result.cex = cex;
2920
        }
2921
        return result;
2922
      }
2923
    }
2924
 
2925
    private static class getVendorItemMappings<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getVendorItemMappings_args> {
2926
      public getVendorItemMappings() {
2927
        super("getVendorItemMappings");
2928
      }
2929
 
2930
      protected getVendorItemMappings_args getEmptyArgsInstance() {
2931
        return new getVendorItemMappings_args();
2932
      }
2933
 
2934
      protected getVendorItemMappings_result getResult(I iface, getVendorItemMappings_args args) throws org.apache.thrift.TException {
2935
        getVendorItemMappings_result result = new getVendorItemMappings_result();
2936
        try {
2937
          result.success = iface.getVendorItemMappings(args.itemId);
2938
        } catch (InventoryServiceException cex) {
2939
          result.cex = cex;
2940
        }
2941
        return result;
2942
      }
2943
    }
2944
 
2945
    private static class getPendingOrdersInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getPendingOrdersInventory_args> {
2946
      public getPendingOrdersInventory() {
2947
        super("getPendingOrdersInventory");
2948
      }
2949
 
2950
      protected getPendingOrdersInventory_args getEmptyArgsInstance() {
2951
        return new getPendingOrdersInventory_args();
2952
      }
2953
 
2954
      protected getPendingOrdersInventory_result getResult(I iface, getPendingOrdersInventory_args args) throws org.apache.thrift.TException {
2955
        getPendingOrdersInventory_result result = new getPendingOrdersInventory_result();
2956
        result.success = iface.getPendingOrdersInventory(args.vendorid);
2957
        return result;
2958
      }
2959
    }
2960
 
2961
    private static class getWarehouses<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getWarehouses_args> {
2962
      public getWarehouses() {
2963
        super("getWarehouses");
2964
      }
2965
 
2966
      protected getWarehouses_args getEmptyArgsInstance() {
2967
        return new getWarehouses_args();
2968
      }
2969
 
2970
      protected getWarehouses_result getResult(I iface, getWarehouses_args args) throws org.apache.thrift.TException {
2971
        getWarehouses_result result = new getWarehouses_result();
2972
        result.success = iface.getWarehouses(args.warehouseType, args.inventoryType, args.vendorId, args.billingWarehouseId, args.shippingWarehouseId);
2973
        return result;
2974
      }
2975
    }
2976
 
2977
    private static class resetAvailability<I extends Iface> extends org.apache.thrift.ProcessFunction<I, resetAvailability_args> {
2978
      public resetAvailability() {
2979
        super("resetAvailability");
2980
      }
2981
 
2982
      protected resetAvailability_args getEmptyArgsInstance() {
2983
        return new resetAvailability_args();
2984
      }
2985
 
2986
      protected resetAvailability_result getResult(I iface, resetAvailability_args args) throws org.apache.thrift.TException {
2987
        resetAvailability_result result = new resetAvailability_result();
2988
        try {
2989
          iface.resetAvailability(args.itemKey, args.vendorId, args.quantity, args.warehouseId);
2990
        } catch (InventoryServiceException cex) {
2991
          result.cex = cex;
2992
        }
2993
        return result;
2994
      }
2995
    }
2996
 
2997
    private static class resetAvailabilityForWarehouse<I extends Iface> extends org.apache.thrift.ProcessFunction<I, resetAvailabilityForWarehouse_args> {
2998
      public resetAvailabilityForWarehouse() {
2999
        super("resetAvailabilityForWarehouse");
3000
      }
3001
 
3002
      protected resetAvailabilityForWarehouse_args getEmptyArgsInstance() {
3003
        return new resetAvailabilityForWarehouse_args();
3004
      }
3005
 
3006
      protected resetAvailabilityForWarehouse_result getResult(I iface, resetAvailabilityForWarehouse_args args) throws org.apache.thrift.TException {
3007
        resetAvailabilityForWarehouse_result result = new resetAvailabilityForWarehouse_result();
3008
        try {
3009
          iface.resetAvailabilityForWarehouse(args.warehouseId);
3010
        } catch (InventoryServiceException cex) {
3011
          result.cex = cex;
3012
        }
3013
        return result;
3014
      }
3015
    }
3016
 
3017
    private static class getItemKeysToBeProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getItemKeysToBeProcessed_args> {
3018
      public getItemKeysToBeProcessed() {
3019
        super("getItemKeysToBeProcessed");
3020
      }
3021
 
3022
      protected getItemKeysToBeProcessed_args getEmptyArgsInstance() {
3023
        return new getItemKeysToBeProcessed_args();
3024
      }
3025
 
3026
      protected getItemKeysToBeProcessed_result getResult(I iface, getItemKeysToBeProcessed_args args) throws org.apache.thrift.TException {
3027
        getItemKeysToBeProcessed_result result = new getItemKeysToBeProcessed_result();
3028
        result.success = iface.getItemKeysToBeProcessed(args.warehouseId);
3029
        return result;
3030
      }
3031
    }
3032
 
3033
    private static class markMissedInventoryUpdatesAsProcessed<I extends Iface> extends org.apache.thrift.ProcessFunction<I, markMissedInventoryUpdatesAsProcessed_args> {
3034
      public markMissedInventoryUpdatesAsProcessed() {
3035
        super("markMissedInventoryUpdatesAsProcessed");
3036
      }
3037
 
3038
      protected markMissedInventoryUpdatesAsProcessed_args getEmptyArgsInstance() {
3039
        return new markMissedInventoryUpdatesAsProcessed_args();
3040
      }
3041
 
3042
      protected markMissedInventoryUpdatesAsProcessed_result getResult(I iface, markMissedInventoryUpdatesAsProcessed_args args) throws org.apache.thrift.TException {
3043
        markMissedInventoryUpdatesAsProcessed_result result = new markMissedInventoryUpdatesAsProcessed_result();
3044
        iface.markMissedInventoryUpdatesAsProcessed(args.itemKey, args.warehouseId);
3045
        return result;
3046
      }
3047
    }
3048
 
3049
    private static class getIgnoredItemKeys<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getIgnoredItemKeys_args> {
3050
      public getIgnoredItemKeys() {
3051
        super("getIgnoredItemKeys");
3052
      }
3053
 
3054
      protected getIgnoredItemKeys_args getEmptyArgsInstance() {
3055
        return new getIgnoredItemKeys_args();
3056
      }
3057
 
3058
      protected getIgnoredItemKeys_result getResult(I iface, getIgnoredItemKeys_args args) throws org.apache.thrift.TException {
3059
        getIgnoredItemKeys_result result = new getIgnoredItemKeys_result();
3060
        result.success = iface.getIgnoredItemKeys();
3061
        return result;
3062
      }
3063
    }
3064
 
3065
    private static class addBadInventory<I extends Iface> extends org.apache.thrift.ProcessFunction<I, addBadInventory_args> {
3066
      public addBadInventory() {
3067
        super("addBadInventory");
3068
      }
3069
 
3070
      protected addBadInventory_args getEmptyArgsInstance() {
3071
        return new addBadInventory_args();
3072
      }
3073
 
3074
      protected addBadInventory_result getResult(I iface, addBadInventory_args args) throws org.apache.thrift.TException {
3075
        addBadInventory_result result = new addBadInventory_result();
3076
        try {
3077
          iface.addBadInventory(args.itemId, args.warehouseId, args.quantity);
3078
        } catch (InventoryServiceException cex) {
3079
          result.cex = cex;
3080
        }
3081
        return result;
3082
      }
3083
    }
3084
 
3085
    private static class getShippingLocations<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getShippingLocations_args> {
3086
      public getShippingLocations() {
3087
        super("getShippingLocations");
3088
      }
3089
 
3090
      protected getShippingLocations_args getEmptyArgsInstance() {
3091
        return new getShippingLocations_args();
3092
      }
3093
 
3094
      protected getShippingLocations_result getResult(I iface, getShippingLocations_args args) throws org.apache.thrift.TException {
3095
        getShippingLocations_result result = new getShippingLocations_result();
3096
        result.success = iface.getShippingLocations();
3097
        return result;
3098
      }
3099
    }
3100
 
3101
    private static class getAllVendorItemMappings<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllVendorItemMappings_args> {
3102
      public getAllVendorItemMappings() {
3103
        super("getAllVendorItemMappings");
3104
      }
3105
 
3106
      protected getAllVendorItemMappings_args getEmptyArgsInstance() {
3107
        return new getAllVendorItemMappings_args();
3108
      }
3109
 
3110
      protected getAllVendorItemMappings_result getResult(I iface, getAllVendorItemMappings_args args) throws org.apache.thrift.TException {
3111
        getAllVendorItemMappings_result result = new getAllVendorItemMappings_result();
3112
        result.success = iface.getAllVendorItemMappings();
3113
        return result;
3114
      }
3115
    }
3116
 
3117
    private static class getInventorySnapshot<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getInventorySnapshot_args> {
3118
      public getInventorySnapshot() {
3119
        super("getInventorySnapshot");
3120
      }
3121
 
3122
      protected getInventorySnapshot_args getEmptyArgsInstance() {
3123
        return new getInventorySnapshot_args();
3124
      }
3125
 
3126
      protected getInventorySnapshot_result getResult(I iface, getInventorySnapshot_args args) throws org.apache.thrift.TException {
3127
        getInventorySnapshot_result result = new getInventorySnapshot_result();
3128
        result.success = iface.getInventorySnapshot(args.warehouseId);
3129
        return result;
3130
      }
3131
    }
3132
 
3133
    private static class clearItemAvailabilityCache<I extends Iface> extends org.apache.thrift.ProcessFunction<I, clearItemAvailabilityCache_args> {
3134
      public clearItemAvailabilityCache() {
3135
        super("clearItemAvailabilityCache");
3136
      }
3137
 
3138
      protected clearItemAvailabilityCache_args getEmptyArgsInstance() {
3139
        return new clearItemAvailabilityCache_args();
3140
      }
3141
 
3142
      protected clearItemAvailabilityCache_result getResult(I iface, clearItemAvailabilityCache_args args) throws org.apache.thrift.TException {
3143
        clearItemAvailabilityCache_result result = new clearItemAvailabilityCache_result();
3144
        iface.clearItemAvailabilityCache();
3145
        return result;
3146
      }
3147
    }
3148
 
3149
    private static class updateVendorString<I extends Iface> extends org.apache.thrift.ProcessFunction<I, updateVendorString_args> {
3150
      public updateVendorString() {
3151
        super("updateVendorString");
3152
      }
3153
 
3154
      protected updateVendorString_args getEmptyArgsInstance() {
3155
        return new updateVendorString_args();
3156
      }
3157
 
3158
      protected updateVendorString_result getResult(I iface, updateVendorString_args args) throws org.apache.thrift.TException {
3159
        updateVendorString_result result = new updateVendorString_result();
3160
        iface.updateVendorString(args.warehouseId, args.vendorString);
3161
        return result;
3162
      }
3163
    }
3164
 
3165
  }
3166
 
3167
  public static class addWarehouse_args implements org.apache.thrift.TBase<addWarehouse_args, addWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
3168
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addWarehouse_args");
3169
 
3170
    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);
3171
 
3172
    private Warehouse warehouse; // required
3173
 
3174
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3175
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3176
      WAREHOUSE((short)1, "warehouse");
3177
 
3178
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3179
 
3180
      static {
3181
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3182
          byName.put(field.getFieldName(), field);
3183
        }
3184
      }
3185
 
3186
      /**
3187
       * Find the _Fields constant that matches fieldId, or null if its not found.
3188
       */
3189
      public static _Fields findByThriftId(int fieldId) {
3190
        switch(fieldId) {
3191
          case 1: // WAREHOUSE
3192
            return WAREHOUSE;
3193
          default:
3194
            return null;
3195
        }
3196
      }
3197
 
3198
      /**
3199
       * Find the _Fields constant that matches fieldId, throwing an exception
3200
       * if it is not found.
3201
       */
3202
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3203
        _Fields fields = findByThriftId(fieldId);
3204
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3205
        return fields;
3206
      }
3207
 
3208
      /**
3209
       * Find the _Fields constant that matches name, or null if its not found.
3210
       */
3211
      public static _Fields findByName(String name) {
3212
        return byName.get(name);
3213
      }
3214
 
3215
      private final short _thriftId;
3216
      private final String _fieldName;
3217
 
3218
      _Fields(short thriftId, String fieldName) {
3219
        _thriftId = thriftId;
3220
        _fieldName = fieldName;
3221
      }
3222
 
3223
      public short getThriftFieldId() {
3224
        return _thriftId;
3225
      }
3226
 
3227
      public String getFieldName() {
3228
        return _fieldName;
3229
      }
3230
    }
3231
 
3232
    // isset id assignments
3233
 
3234
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3235
    static {
3236
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3237
      tmpMap.put(_Fields.WAREHOUSE, new org.apache.thrift.meta_data.FieldMetaData("warehouse", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3238
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class)));
3239
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3240
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addWarehouse_args.class, metaDataMap);
3241
    }
3242
 
3243
    public addWarehouse_args() {
3244
    }
3245
 
3246
    public addWarehouse_args(
3247
      Warehouse warehouse)
3248
    {
3249
      this();
3250
      this.warehouse = warehouse;
3251
    }
3252
 
3253
    /**
3254
     * Performs a deep copy on <i>other</i>.
3255
     */
3256
    public addWarehouse_args(addWarehouse_args other) {
3257
      if (other.isSetWarehouse()) {
3258
        this.warehouse = new Warehouse(other.warehouse);
3259
      }
3260
    }
3261
 
3262
    public addWarehouse_args deepCopy() {
3263
      return new addWarehouse_args(this);
3264
    }
3265
 
3266
    @Override
3267
    public void clear() {
3268
      this.warehouse = null;
3269
    }
3270
 
3271
    public Warehouse getWarehouse() {
3272
      return this.warehouse;
3273
    }
3274
 
3275
    public void setWarehouse(Warehouse warehouse) {
3276
      this.warehouse = warehouse;
3277
    }
3278
 
3279
    public void unsetWarehouse() {
3280
      this.warehouse = null;
3281
    }
3282
 
3283
    /** Returns true if field warehouse is set (has been assigned a value) and false otherwise */
3284
    public boolean isSetWarehouse() {
3285
      return this.warehouse != null;
3286
    }
3287
 
3288
    public void setWarehouseIsSet(boolean value) {
3289
      if (!value) {
3290
        this.warehouse = null;
3291
      }
3292
    }
3293
 
3294
    public void setFieldValue(_Fields field, Object value) {
3295
      switch (field) {
3296
      case WAREHOUSE:
3297
        if (value == null) {
3298
          unsetWarehouse();
3299
        } else {
3300
          setWarehouse((Warehouse)value);
3301
        }
3302
        break;
3303
 
3304
      }
3305
    }
3306
 
3307
    public Object getFieldValue(_Fields field) {
3308
      switch (field) {
3309
      case WAREHOUSE:
3310
        return getWarehouse();
3311
 
3312
      }
3313
      throw new IllegalStateException();
3314
    }
3315
 
3316
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3317
    public boolean isSet(_Fields field) {
3318
      if (field == null) {
3319
        throw new IllegalArgumentException();
3320
      }
3321
 
3322
      switch (field) {
3323
      case WAREHOUSE:
3324
        return isSetWarehouse();
3325
      }
3326
      throw new IllegalStateException();
3327
    }
3328
 
3329
    @Override
3330
    public boolean equals(Object that) {
3331
      if (that == null)
3332
        return false;
3333
      if (that instanceof addWarehouse_args)
3334
        return this.equals((addWarehouse_args)that);
3335
      return false;
3336
    }
3337
 
3338
    public boolean equals(addWarehouse_args that) {
3339
      if (that == null)
3340
        return false;
3341
 
3342
      boolean this_present_warehouse = true && this.isSetWarehouse();
3343
      boolean that_present_warehouse = true && that.isSetWarehouse();
3344
      if (this_present_warehouse || that_present_warehouse) {
3345
        if (!(this_present_warehouse && that_present_warehouse))
3346
          return false;
3347
        if (!this.warehouse.equals(that.warehouse))
3348
          return false;
3349
      }
3350
 
3351
      return true;
3352
    }
3353
 
3354
    @Override
3355
    public int hashCode() {
3356
      return 0;
3357
    }
3358
 
3359
    public int compareTo(addWarehouse_args other) {
3360
      if (!getClass().equals(other.getClass())) {
3361
        return getClass().getName().compareTo(other.getClass().getName());
3362
      }
3363
 
3364
      int lastComparison = 0;
3365
      addWarehouse_args typedOther = (addWarehouse_args)other;
3366
 
3367
      lastComparison = Boolean.valueOf(isSetWarehouse()).compareTo(typedOther.isSetWarehouse());
3368
      if (lastComparison != 0) {
3369
        return lastComparison;
3370
      }
3371
      if (isSetWarehouse()) {
3372
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse, typedOther.warehouse);
3373
        if (lastComparison != 0) {
3374
          return lastComparison;
3375
        }
3376
      }
3377
      return 0;
3378
    }
3379
 
3380
    public _Fields fieldForId(int fieldId) {
3381
      return _Fields.findByThriftId(fieldId);
3382
    }
3383
 
3384
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3385
      org.apache.thrift.protocol.TField field;
3386
      iprot.readStructBegin();
3387
      while (true)
3388
      {
3389
        field = iprot.readFieldBegin();
3390
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3391
          break;
3392
        }
3393
        switch (field.id) {
3394
          case 1: // WAREHOUSE
3395
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3396
              this.warehouse = new Warehouse();
3397
              this.warehouse.read(iprot);
3398
            } else { 
3399
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3400
            }
3401
            break;
3402
          default:
3403
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3404
        }
3405
        iprot.readFieldEnd();
3406
      }
3407
      iprot.readStructEnd();
3408
      validate();
3409
    }
3410
 
3411
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3412
      validate();
3413
 
3414
      oprot.writeStructBegin(STRUCT_DESC);
3415
      if (this.warehouse != null) {
3416
        oprot.writeFieldBegin(WAREHOUSE_FIELD_DESC);
3417
        this.warehouse.write(oprot);
3418
        oprot.writeFieldEnd();
3419
      }
3420
      oprot.writeFieldStop();
3421
      oprot.writeStructEnd();
3422
    }
3423
 
3424
    @Override
3425
    public String toString() {
3426
      StringBuilder sb = new StringBuilder("addWarehouse_args(");
3427
      boolean first = true;
3428
 
3429
      sb.append("warehouse:");
3430
      if (this.warehouse == null) {
3431
        sb.append("null");
3432
      } else {
3433
        sb.append(this.warehouse);
3434
      }
3435
      first = false;
3436
      sb.append(")");
3437
      return sb.toString();
3438
    }
3439
 
3440
    public void validate() throws org.apache.thrift.TException {
3441
      // check for required fields
3442
    }
3443
 
3444
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3445
      try {
3446
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3447
      } catch (org.apache.thrift.TException te) {
3448
        throw new java.io.IOException(te);
3449
      }
3450
    }
3451
 
3452
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3453
      try {
3454
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3455
      } catch (org.apache.thrift.TException te) {
3456
        throw new java.io.IOException(te);
3457
      }
3458
    }
3459
 
3460
  }
3461
 
3462
  public static class addWarehouse_result implements org.apache.thrift.TBase<addWarehouse_result, addWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
3463
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addWarehouse_result");
3464
 
3465
    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);
3466
    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);
3467
 
3468
    private long success; // required
3469
    private InventoryServiceException cex; // required
3470
 
3471
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3472
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3473
      SUCCESS((short)0, "success"),
3474
      CEX((short)1, "cex");
3475
 
3476
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3477
 
3478
      static {
3479
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3480
          byName.put(field.getFieldName(), field);
3481
        }
3482
      }
3483
 
3484
      /**
3485
       * Find the _Fields constant that matches fieldId, or null if its not found.
3486
       */
3487
      public static _Fields findByThriftId(int fieldId) {
3488
        switch(fieldId) {
3489
          case 0: // SUCCESS
3490
            return SUCCESS;
3491
          case 1: // CEX
3492
            return CEX;
3493
          default:
3494
            return null;
3495
        }
3496
      }
3497
 
3498
      /**
3499
       * Find the _Fields constant that matches fieldId, throwing an exception
3500
       * if it is not found.
3501
       */
3502
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3503
        _Fields fields = findByThriftId(fieldId);
3504
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3505
        return fields;
3506
      }
3507
 
3508
      /**
3509
       * Find the _Fields constant that matches name, or null if its not found.
3510
       */
3511
      public static _Fields findByName(String name) {
3512
        return byName.get(name);
3513
      }
3514
 
3515
      private final short _thriftId;
3516
      private final String _fieldName;
3517
 
3518
      _Fields(short thriftId, String fieldName) {
3519
        _thriftId = thriftId;
3520
        _fieldName = fieldName;
3521
      }
3522
 
3523
      public short getThriftFieldId() {
3524
        return _thriftId;
3525
      }
3526
 
3527
      public String getFieldName() {
3528
        return _fieldName;
3529
      }
3530
    }
3531
 
3532
    // isset id assignments
3533
    private static final int __SUCCESS_ISSET_ID = 0;
3534
    private BitSet __isset_bit_vector = new BitSet(1);
3535
 
3536
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3537
    static {
3538
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3539
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3540
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3541
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3542
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3543
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3544
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addWarehouse_result.class, metaDataMap);
3545
    }
3546
 
3547
    public addWarehouse_result() {
3548
    }
3549
 
3550
    public addWarehouse_result(
3551
      long success,
3552
      InventoryServiceException cex)
3553
    {
3554
      this();
3555
      this.success = success;
3556
      setSuccessIsSet(true);
3557
      this.cex = cex;
3558
    }
3559
 
3560
    /**
3561
     * Performs a deep copy on <i>other</i>.
3562
     */
3563
    public addWarehouse_result(addWarehouse_result other) {
3564
      __isset_bit_vector.clear();
3565
      __isset_bit_vector.or(other.__isset_bit_vector);
3566
      this.success = other.success;
3567
      if (other.isSetCex()) {
3568
        this.cex = new InventoryServiceException(other.cex);
3569
      }
3570
    }
3571
 
3572
    public addWarehouse_result deepCopy() {
3573
      return new addWarehouse_result(this);
3574
    }
3575
 
3576
    @Override
3577
    public void clear() {
3578
      setSuccessIsSet(false);
3579
      this.success = 0;
3580
      this.cex = null;
3581
    }
3582
 
3583
    public long getSuccess() {
3584
      return this.success;
3585
    }
3586
 
3587
    public void setSuccess(long success) {
3588
      this.success = success;
3589
      setSuccessIsSet(true);
3590
    }
3591
 
3592
    public void unsetSuccess() {
3593
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
3594
    }
3595
 
3596
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
3597
    public boolean isSetSuccess() {
3598
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
3599
    }
3600
 
3601
    public void setSuccessIsSet(boolean value) {
3602
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
3603
    }
3604
 
3605
    public InventoryServiceException getCex() {
3606
      return this.cex;
3607
    }
3608
 
3609
    public void setCex(InventoryServiceException cex) {
3610
      this.cex = cex;
3611
    }
3612
 
3613
    public void unsetCex() {
3614
      this.cex = null;
3615
    }
3616
 
3617
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
3618
    public boolean isSetCex() {
3619
      return this.cex != null;
3620
    }
3621
 
3622
    public void setCexIsSet(boolean value) {
3623
      if (!value) {
3624
        this.cex = null;
3625
      }
3626
    }
3627
 
3628
    public void setFieldValue(_Fields field, Object value) {
3629
      switch (field) {
3630
      case SUCCESS:
3631
        if (value == null) {
3632
          unsetSuccess();
3633
        } else {
3634
          setSuccess((Long)value);
3635
        }
3636
        break;
3637
 
3638
      case CEX:
3639
        if (value == null) {
3640
          unsetCex();
3641
        } else {
3642
          setCex((InventoryServiceException)value);
3643
        }
3644
        break;
3645
 
3646
      }
3647
    }
3648
 
3649
    public Object getFieldValue(_Fields field) {
3650
      switch (field) {
3651
      case SUCCESS:
3652
        return Long.valueOf(getSuccess());
3653
 
3654
      case CEX:
3655
        return getCex();
3656
 
3657
      }
3658
      throw new IllegalStateException();
3659
    }
3660
 
3661
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3662
    public boolean isSet(_Fields field) {
3663
      if (field == null) {
3664
        throw new IllegalArgumentException();
3665
      }
3666
 
3667
      switch (field) {
3668
      case SUCCESS:
3669
        return isSetSuccess();
3670
      case CEX:
3671
        return isSetCex();
3672
      }
3673
      throw new IllegalStateException();
3674
    }
3675
 
3676
    @Override
3677
    public boolean equals(Object that) {
3678
      if (that == null)
3679
        return false;
3680
      if (that instanceof addWarehouse_result)
3681
        return this.equals((addWarehouse_result)that);
3682
      return false;
3683
    }
3684
 
3685
    public boolean equals(addWarehouse_result that) {
3686
      if (that == null)
3687
        return false;
3688
 
3689
      boolean this_present_success = true;
3690
      boolean that_present_success = true;
3691
      if (this_present_success || that_present_success) {
3692
        if (!(this_present_success && that_present_success))
3693
          return false;
3694
        if (this.success != that.success)
3695
          return false;
3696
      }
3697
 
3698
      boolean this_present_cex = true && this.isSetCex();
3699
      boolean that_present_cex = true && that.isSetCex();
3700
      if (this_present_cex || that_present_cex) {
3701
        if (!(this_present_cex && that_present_cex))
3702
          return false;
3703
        if (!this.cex.equals(that.cex))
3704
          return false;
3705
      }
3706
 
3707
      return true;
3708
    }
3709
 
3710
    @Override
3711
    public int hashCode() {
3712
      return 0;
3713
    }
3714
 
3715
    public int compareTo(addWarehouse_result other) {
3716
      if (!getClass().equals(other.getClass())) {
3717
        return getClass().getName().compareTo(other.getClass().getName());
3718
      }
3719
 
3720
      int lastComparison = 0;
3721
      addWarehouse_result typedOther = (addWarehouse_result)other;
3722
 
3723
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
3724
      if (lastComparison != 0) {
3725
        return lastComparison;
3726
      }
3727
      if (isSetSuccess()) {
3728
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3729
        if (lastComparison != 0) {
3730
          return lastComparison;
3731
        }
3732
      }
3733
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
3734
      if (lastComparison != 0) {
3735
        return lastComparison;
3736
      }
3737
      if (isSetCex()) {
3738
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
3739
        if (lastComparison != 0) {
3740
          return lastComparison;
3741
        }
3742
      }
3743
      return 0;
3744
    }
3745
 
3746
    public _Fields fieldForId(int fieldId) {
3747
      return _Fields.findByThriftId(fieldId);
3748
    }
3749
 
3750
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3751
      org.apache.thrift.protocol.TField field;
3752
      iprot.readStructBegin();
3753
      while (true)
3754
      {
3755
        field = iprot.readFieldBegin();
3756
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
3757
          break;
3758
        }
3759
        switch (field.id) {
3760
          case 0: // SUCCESS
3761
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3762
              this.success = iprot.readI64();
3763
              setSuccessIsSet(true);
3764
            } else { 
3765
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3766
            }
3767
            break;
3768
          case 1: // CEX
3769
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3770
              this.cex = new InventoryServiceException();
3771
              this.cex.read(iprot);
3772
            } else { 
3773
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3774
            }
3775
            break;
3776
          default:
3777
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3778
        }
3779
        iprot.readFieldEnd();
3780
      }
3781
      iprot.readStructEnd();
3782
      validate();
3783
    }
3784
 
3785
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
3786
      oprot.writeStructBegin(STRUCT_DESC);
3787
 
3788
      if (this.isSetSuccess()) {
3789
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3790
        oprot.writeI64(this.success);
3791
        oprot.writeFieldEnd();
3792
      } else if (this.isSetCex()) {
3793
        oprot.writeFieldBegin(CEX_FIELD_DESC);
3794
        this.cex.write(oprot);
3795
        oprot.writeFieldEnd();
3796
      }
3797
      oprot.writeFieldStop();
3798
      oprot.writeStructEnd();
3799
    }
3800
 
3801
    @Override
3802
    public String toString() {
3803
      StringBuilder sb = new StringBuilder("addWarehouse_result(");
3804
      boolean first = true;
3805
 
3806
      sb.append("success:");
3807
      sb.append(this.success);
3808
      first = false;
3809
      if (!first) sb.append(", ");
3810
      sb.append("cex:");
3811
      if (this.cex == null) {
3812
        sb.append("null");
3813
      } else {
3814
        sb.append(this.cex);
3815
      }
3816
      first = false;
3817
      sb.append(")");
3818
      return sb.toString();
3819
    }
3820
 
3821
    public void validate() throws org.apache.thrift.TException {
3822
      // check for required fields
3823
    }
3824
 
3825
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3826
      try {
3827
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3828
      } catch (org.apache.thrift.TException te) {
3829
        throw new java.io.IOException(te);
3830
      }
3831
    }
3832
 
3833
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3834
      try {
3835
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3836
      } catch (org.apache.thrift.TException te) {
3837
        throw new java.io.IOException(te);
3838
      }
3839
    }
3840
 
3841
  }
3842
 
3843
  public static class addVendor_args implements org.apache.thrift.TBase<addVendor_args, addVendor_args._Fields>, java.io.Serializable, Cloneable   {
3844
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendor_args");
3845
 
3846
    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);
3847
 
3848
    private Vendor vendor; // required
3849
 
3850
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3851
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3852
      VENDOR((short)1, "vendor");
3853
 
3854
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3855
 
3856
      static {
3857
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3858
          byName.put(field.getFieldName(), field);
3859
        }
3860
      }
3861
 
3862
      /**
3863
       * Find the _Fields constant that matches fieldId, or null if its not found.
3864
       */
3865
      public static _Fields findByThriftId(int fieldId) {
3866
        switch(fieldId) {
3867
          case 1: // VENDOR
3868
            return VENDOR;
3869
          default:
3870
            return null;
3871
        }
3872
      }
3873
 
3874
      /**
3875
       * Find the _Fields constant that matches fieldId, throwing an exception
3876
       * if it is not found.
3877
       */
3878
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3879
        _Fields fields = findByThriftId(fieldId);
3880
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3881
        return fields;
3882
      }
3883
 
3884
      /**
3885
       * Find the _Fields constant that matches name, or null if its not found.
3886
       */
3887
      public static _Fields findByName(String name) {
3888
        return byName.get(name);
3889
      }
3890
 
3891
      private final short _thriftId;
3892
      private final String _fieldName;
3893
 
3894
      _Fields(short thriftId, String fieldName) {
3895
        _thriftId = thriftId;
3896
        _fieldName = fieldName;
3897
      }
3898
 
3899
      public short getThriftFieldId() {
3900
        return _thriftId;
3901
      }
3902
 
3903
      public String getFieldName() {
3904
        return _fieldName;
3905
      }
3906
    }
3907
 
3908
    // isset id assignments
3909
 
3910
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
3911
    static {
3912
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3913
      tmpMap.put(_Fields.VENDOR, new org.apache.thrift.meta_data.FieldMetaData("vendor", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3914
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class)));
3915
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3916
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendor_args.class, metaDataMap);
3917
    }
3918
 
3919
    public addVendor_args() {
3920
    }
3921
 
3922
    public addVendor_args(
3923
      Vendor vendor)
3924
    {
3925
      this();
3926
      this.vendor = vendor;
3927
    }
3928
 
3929
    /**
3930
     * Performs a deep copy on <i>other</i>.
3931
     */
3932
    public addVendor_args(addVendor_args other) {
3933
      if (other.isSetVendor()) {
3934
        this.vendor = new Vendor(other.vendor);
3935
      }
3936
    }
3937
 
3938
    public addVendor_args deepCopy() {
3939
      return new addVendor_args(this);
3940
    }
3941
 
3942
    @Override
3943
    public void clear() {
3944
      this.vendor = null;
3945
    }
3946
 
3947
    public Vendor getVendor() {
3948
      return this.vendor;
3949
    }
3950
 
3951
    public void setVendor(Vendor vendor) {
3952
      this.vendor = vendor;
3953
    }
3954
 
3955
    public void unsetVendor() {
3956
      this.vendor = null;
3957
    }
3958
 
3959
    /** Returns true if field vendor is set (has been assigned a value) and false otherwise */
3960
    public boolean isSetVendor() {
3961
      return this.vendor != null;
3962
    }
3963
 
3964
    public void setVendorIsSet(boolean value) {
3965
      if (!value) {
3966
        this.vendor = null;
3967
      }
3968
    }
3969
 
3970
    public void setFieldValue(_Fields field, Object value) {
3971
      switch (field) {
3972
      case VENDOR:
3973
        if (value == null) {
3974
          unsetVendor();
3975
        } else {
3976
          setVendor((Vendor)value);
3977
        }
3978
        break;
3979
 
3980
      }
3981
    }
3982
 
3983
    public Object getFieldValue(_Fields field) {
3984
      switch (field) {
3985
      case VENDOR:
3986
        return getVendor();
3987
 
3988
      }
3989
      throw new IllegalStateException();
3990
    }
3991
 
3992
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3993
    public boolean isSet(_Fields field) {
3994
      if (field == null) {
3995
        throw new IllegalArgumentException();
3996
      }
3997
 
3998
      switch (field) {
3999
      case VENDOR:
4000
        return isSetVendor();
4001
      }
4002
      throw new IllegalStateException();
4003
    }
4004
 
4005
    @Override
4006
    public boolean equals(Object that) {
4007
      if (that == null)
4008
        return false;
4009
      if (that instanceof addVendor_args)
4010
        return this.equals((addVendor_args)that);
4011
      return false;
4012
    }
4013
 
4014
    public boolean equals(addVendor_args that) {
4015
      if (that == null)
4016
        return false;
4017
 
4018
      boolean this_present_vendor = true && this.isSetVendor();
4019
      boolean that_present_vendor = true && that.isSetVendor();
4020
      if (this_present_vendor || that_present_vendor) {
4021
        if (!(this_present_vendor && that_present_vendor))
4022
          return false;
4023
        if (!this.vendor.equals(that.vendor))
4024
          return false;
4025
      }
4026
 
4027
      return true;
4028
    }
4029
 
4030
    @Override
4031
    public int hashCode() {
4032
      return 0;
4033
    }
4034
 
4035
    public int compareTo(addVendor_args other) {
4036
      if (!getClass().equals(other.getClass())) {
4037
        return getClass().getName().compareTo(other.getClass().getName());
4038
      }
4039
 
4040
      int lastComparison = 0;
4041
      addVendor_args typedOther = (addVendor_args)other;
4042
 
4043
      lastComparison = Boolean.valueOf(isSetVendor()).compareTo(typedOther.isSetVendor());
4044
      if (lastComparison != 0) {
4045
        return lastComparison;
4046
      }
4047
      if (isSetVendor()) {
4048
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendor, typedOther.vendor);
4049
        if (lastComparison != 0) {
4050
          return lastComparison;
4051
        }
4052
      }
4053
      return 0;
4054
    }
4055
 
4056
    public _Fields fieldForId(int fieldId) {
4057
      return _Fields.findByThriftId(fieldId);
4058
    }
4059
 
4060
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4061
      org.apache.thrift.protocol.TField field;
4062
      iprot.readStructBegin();
4063
      while (true)
4064
      {
4065
        field = iprot.readFieldBegin();
4066
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4067
          break;
4068
        }
4069
        switch (field.id) {
4070
          case 1: // VENDOR
4071
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4072
              this.vendor = new Vendor();
4073
              this.vendor.read(iprot);
4074
            } else { 
4075
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4076
            }
4077
            break;
4078
          default:
4079
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4080
        }
4081
        iprot.readFieldEnd();
4082
      }
4083
      iprot.readStructEnd();
4084
      validate();
4085
    }
4086
 
4087
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4088
      validate();
4089
 
4090
      oprot.writeStructBegin(STRUCT_DESC);
4091
      if (this.vendor != null) {
4092
        oprot.writeFieldBegin(VENDOR_FIELD_DESC);
4093
        this.vendor.write(oprot);
4094
        oprot.writeFieldEnd();
4095
      }
4096
      oprot.writeFieldStop();
4097
      oprot.writeStructEnd();
4098
    }
4099
 
4100
    @Override
4101
    public String toString() {
4102
      StringBuilder sb = new StringBuilder("addVendor_args(");
4103
      boolean first = true;
4104
 
4105
      sb.append("vendor:");
4106
      if (this.vendor == null) {
4107
        sb.append("null");
4108
      } else {
4109
        sb.append(this.vendor);
4110
      }
4111
      first = false;
4112
      sb.append(")");
4113
      return sb.toString();
4114
    }
4115
 
4116
    public void validate() throws org.apache.thrift.TException {
4117
      // check for required fields
4118
    }
4119
 
4120
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4121
      try {
4122
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4123
      } catch (org.apache.thrift.TException te) {
4124
        throw new java.io.IOException(te);
4125
      }
4126
    }
4127
 
4128
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4129
      try {
4130
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4131
      } catch (org.apache.thrift.TException te) {
4132
        throw new java.io.IOException(te);
4133
      }
4134
    }
4135
 
4136
  }
4137
 
4138
  public static class addVendor_result implements org.apache.thrift.TBase<addVendor_result, addVendor_result._Fields>, java.io.Serializable, Cloneable   {
4139
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendor_result");
4140
 
4141
    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);
4142
    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);
4143
 
4144
    private long success; // required
4145
    private InventoryServiceException cex; // required
4146
 
4147
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4148
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4149
      SUCCESS((short)0, "success"),
4150
      CEX((short)1, "cex");
4151
 
4152
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4153
 
4154
      static {
4155
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4156
          byName.put(field.getFieldName(), field);
4157
        }
4158
      }
4159
 
4160
      /**
4161
       * Find the _Fields constant that matches fieldId, or null if its not found.
4162
       */
4163
      public static _Fields findByThriftId(int fieldId) {
4164
        switch(fieldId) {
4165
          case 0: // SUCCESS
4166
            return SUCCESS;
4167
          case 1: // CEX
4168
            return CEX;
4169
          default:
4170
            return null;
4171
        }
4172
      }
4173
 
4174
      /**
4175
       * Find the _Fields constant that matches fieldId, throwing an exception
4176
       * if it is not found.
4177
       */
4178
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4179
        _Fields fields = findByThriftId(fieldId);
4180
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4181
        return fields;
4182
      }
4183
 
4184
      /**
4185
       * Find the _Fields constant that matches name, or null if its not found.
4186
       */
4187
      public static _Fields findByName(String name) {
4188
        return byName.get(name);
4189
      }
4190
 
4191
      private final short _thriftId;
4192
      private final String _fieldName;
4193
 
4194
      _Fields(short thriftId, String fieldName) {
4195
        _thriftId = thriftId;
4196
        _fieldName = fieldName;
4197
      }
4198
 
4199
      public short getThriftFieldId() {
4200
        return _thriftId;
4201
      }
4202
 
4203
      public String getFieldName() {
4204
        return _fieldName;
4205
      }
4206
    }
4207
 
4208
    // isset id assignments
4209
    private static final int __SUCCESS_ISSET_ID = 0;
4210
    private BitSet __isset_bit_vector = new BitSet(1);
4211
 
4212
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4213
    static {
4214
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4215
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4216
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4217
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4218
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4219
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4220
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendor_result.class, metaDataMap);
4221
    }
4222
 
4223
    public addVendor_result() {
4224
    }
4225
 
4226
    public addVendor_result(
4227
      long success,
4228
      InventoryServiceException cex)
4229
    {
4230
      this();
4231
      this.success = success;
4232
      setSuccessIsSet(true);
4233
      this.cex = cex;
4234
    }
4235
 
4236
    /**
4237
     * Performs a deep copy on <i>other</i>.
4238
     */
4239
    public addVendor_result(addVendor_result other) {
4240
      __isset_bit_vector.clear();
4241
      __isset_bit_vector.or(other.__isset_bit_vector);
4242
      this.success = other.success;
4243
      if (other.isSetCex()) {
4244
        this.cex = new InventoryServiceException(other.cex);
4245
      }
4246
    }
4247
 
4248
    public addVendor_result deepCopy() {
4249
      return new addVendor_result(this);
4250
    }
4251
 
4252
    @Override
4253
    public void clear() {
4254
      setSuccessIsSet(false);
4255
      this.success = 0;
4256
      this.cex = null;
4257
    }
4258
 
4259
    public long getSuccess() {
4260
      return this.success;
4261
    }
4262
 
4263
    public void setSuccess(long success) {
4264
      this.success = success;
4265
      setSuccessIsSet(true);
4266
    }
4267
 
4268
    public void unsetSuccess() {
4269
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
4270
    }
4271
 
4272
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
4273
    public boolean isSetSuccess() {
4274
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
4275
    }
4276
 
4277
    public void setSuccessIsSet(boolean value) {
4278
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
4279
    }
4280
 
4281
    public InventoryServiceException getCex() {
4282
      return this.cex;
4283
    }
4284
 
4285
    public void setCex(InventoryServiceException cex) {
4286
      this.cex = cex;
4287
    }
4288
 
4289
    public void unsetCex() {
4290
      this.cex = null;
4291
    }
4292
 
4293
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
4294
    public boolean isSetCex() {
4295
      return this.cex != null;
4296
    }
4297
 
4298
    public void setCexIsSet(boolean value) {
4299
      if (!value) {
4300
        this.cex = null;
4301
      }
4302
    }
4303
 
4304
    public void setFieldValue(_Fields field, Object value) {
4305
      switch (field) {
4306
      case SUCCESS:
4307
        if (value == null) {
4308
          unsetSuccess();
4309
        } else {
4310
          setSuccess((Long)value);
4311
        }
4312
        break;
4313
 
4314
      case CEX:
4315
        if (value == null) {
4316
          unsetCex();
4317
        } else {
4318
          setCex((InventoryServiceException)value);
4319
        }
4320
        break;
4321
 
4322
      }
4323
    }
4324
 
4325
    public Object getFieldValue(_Fields field) {
4326
      switch (field) {
4327
      case SUCCESS:
4328
        return Long.valueOf(getSuccess());
4329
 
4330
      case CEX:
4331
        return getCex();
4332
 
4333
      }
4334
      throw new IllegalStateException();
4335
    }
4336
 
4337
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4338
    public boolean isSet(_Fields field) {
4339
      if (field == null) {
4340
        throw new IllegalArgumentException();
4341
      }
4342
 
4343
      switch (field) {
4344
      case SUCCESS:
4345
        return isSetSuccess();
4346
      case CEX:
4347
        return isSetCex();
4348
      }
4349
      throw new IllegalStateException();
4350
    }
4351
 
4352
    @Override
4353
    public boolean equals(Object that) {
4354
      if (that == null)
4355
        return false;
4356
      if (that instanceof addVendor_result)
4357
        return this.equals((addVendor_result)that);
4358
      return false;
4359
    }
4360
 
4361
    public boolean equals(addVendor_result that) {
4362
      if (that == null)
4363
        return false;
4364
 
4365
      boolean this_present_success = true;
4366
      boolean that_present_success = true;
4367
      if (this_present_success || that_present_success) {
4368
        if (!(this_present_success && that_present_success))
4369
          return false;
4370
        if (this.success != that.success)
4371
          return false;
4372
      }
4373
 
4374
      boolean this_present_cex = true && this.isSetCex();
4375
      boolean that_present_cex = true && that.isSetCex();
4376
      if (this_present_cex || that_present_cex) {
4377
        if (!(this_present_cex && that_present_cex))
4378
          return false;
4379
        if (!this.cex.equals(that.cex))
4380
          return false;
4381
      }
4382
 
4383
      return true;
4384
    }
4385
 
4386
    @Override
4387
    public int hashCode() {
4388
      return 0;
4389
    }
4390
 
4391
    public int compareTo(addVendor_result other) {
4392
      if (!getClass().equals(other.getClass())) {
4393
        return getClass().getName().compareTo(other.getClass().getName());
4394
      }
4395
 
4396
      int lastComparison = 0;
4397
      addVendor_result typedOther = (addVendor_result)other;
4398
 
4399
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
4400
      if (lastComparison != 0) {
4401
        return lastComparison;
4402
      }
4403
      if (isSetSuccess()) {
4404
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
4405
        if (lastComparison != 0) {
4406
          return lastComparison;
4407
        }
4408
      }
4409
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
4410
      if (lastComparison != 0) {
4411
        return lastComparison;
4412
      }
4413
      if (isSetCex()) {
4414
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
4415
        if (lastComparison != 0) {
4416
          return lastComparison;
4417
        }
4418
      }
4419
      return 0;
4420
    }
4421
 
4422
    public _Fields fieldForId(int fieldId) {
4423
      return _Fields.findByThriftId(fieldId);
4424
    }
4425
 
4426
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4427
      org.apache.thrift.protocol.TField field;
4428
      iprot.readStructBegin();
4429
      while (true)
4430
      {
4431
        field = iprot.readFieldBegin();
4432
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4433
          break;
4434
        }
4435
        switch (field.id) {
4436
          case 0: // SUCCESS
4437
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4438
              this.success = iprot.readI64();
4439
              setSuccessIsSet(true);
4440
            } else { 
4441
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4442
            }
4443
            break;
4444
          case 1: // CEX
4445
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4446
              this.cex = new InventoryServiceException();
4447
              this.cex.read(iprot);
4448
            } else { 
4449
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4450
            }
4451
            break;
4452
          default:
4453
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4454
        }
4455
        iprot.readFieldEnd();
4456
      }
4457
      iprot.readStructEnd();
4458
      validate();
4459
    }
4460
 
4461
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4462
      oprot.writeStructBegin(STRUCT_DESC);
4463
 
4464
      if (this.isSetSuccess()) {
4465
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
4466
        oprot.writeI64(this.success);
4467
        oprot.writeFieldEnd();
4468
      } else if (this.isSetCex()) {
4469
        oprot.writeFieldBegin(CEX_FIELD_DESC);
4470
        this.cex.write(oprot);
4471
        oprot.writeFieldEnd();
4472
      }
4473
      oprot.writeFieldStop();
4474
      oprot.writeStructEnd();
4475
    }
4476
 
4477
    @Override
4478
    public String toString() {
4479
      StringBuilder sb = new StringBuilder("addVendor_result(");
4480
      boolean first = true;
4481
 
4482
      sb.append("success:");
4483
      sb.append(this.success);
4484
      first = false;
4485
      if (!first) sb.append(", ");
4486
      sb.append("cex:");
4487
      if (this.cex == null) {
4488
        sb.append("null");
4489
      } else {
4490
        sb.append(this.cex);
4491
      }
4492
      first = false;
4493
      sb.append(")");
4494
      return sb.toString();
4495
    }
4496
 
4497
    public void validate() throws org.apache.thrift.TException {
4498
      // check for required fields
4499
    }
4500
 
4501
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4502
      try {
4503
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4504
      } catch (org.apache.thrift.TException te) {
4505
        throw new java.io.IOException(te);
4506
      }
4507
    }
4508
 
4509
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4510
      try {
4511
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4512
      } catch (org.apache.thrift.TException te) {
4513
        throw new java.io.IOException(te);
4514
      }
4515
    }
4516
 
4517
  }
4518
 
4519
  public static class updateInventoryHistory_args implements org.apache.thrift.TBase<updateInventoryHistory_args, updateInventoryHistory_args._Fields>, java.io.Serializable, Cloneable   {
4520
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventoryHistory_args");
4521
 
4522
    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);
4523
    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);
4524
    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);
4525
 
4526
    private long warehouse_id; // required
4527
    private String timestamp; // required
4528
    private Map<String,Long> availability; // required
4529
 
4530
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
4531
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
4532
      WAREHOUSE_ID((short)1, "warehouse_id"),
4533
      TIMESTAMP((short)2, "timestamp"),
4534
      AVAILABILITY((short)3, "availability");
4535
 
4536
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4537
 
4538
      static {
4539
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4540
          byName.put(field.getFieldName(), field);
4541
        }
4542
      }
4543
 
4544
      /**
4545
       * Find the _Fields constant that matches fieldId, or null if its not found.
4546
       */
4547
      public static _Fields findByThriftId(int fieldId) {
4548
        switch(fieldId) {
4549
          case 1: // WAREHOUSE_ID
4550
            return WAREHOUSE_ID;
4551
          case 2: // TIMESTAMP
4552
            return TIMESTAMP;
4553
          case 3: // AVAILABILITY
4554
            return AVAILABILITY;
4555
          default:
4556
            return null;
4557
        }
4558
      }
4559
 
4560
      /**
4561
       * Find the _Fields constant that matches fieldId, throwing an exception
4562
       * if it is not found.
4563
       */
4564
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4565
        _Fields fields = findByThriftId(fieldId);
4566
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4567
        return fields;
4568
      }
4569
 
4570
      /**
4571
       * Find the _Fields constant that matches name, or null if its not found.
4572
       */
4573
      public static _Fields findByName(String name) {
4574
        return byName.get(name);
4575
      }
4576
 
4577
      private final short _thriftId;
4578
      private final String _fieldName;
4579
 
4580
      _Fields(short thriftId, String fieldName) {
4581
        _thriftId = thriftId;
4582
        _fieldName = fieldName;
4583
      }
4584
 
4585
      public short getThriftFieldId() {
4586
        return _thriftId;
4587
      }
4588
 
4589
      public String getFieldName() {
4590
        return _fieldName;
4591
      }
4592
    }
4593
 
4594
    // isset id assignments
4595
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
4596
    private BitSet __isset_bit_vector = new BitSet(1);
4597
 
4598
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
4599
    static {
4600
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4601
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4602
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4603
      tmpMap.put(_Fields.TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("timestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4604
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
4605
      tmpMap.put(_Fields.AVAILABILITY, new org.apache.thrift.meta_data.FieldMetaData("availability", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4606
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
4607
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
4608
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
4609
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4610
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventoryHistory_args.class, metaDataMap);
4611
    }
4612
 
4613
    public updateInventoryHistory_args() {
4614
    }
4615
 
4616
    public updateInventoryHistory_args(
4617
      long warehouse_id,
4618
      String timestamp,
4619
      Map<String,Long> availability)
4620
    {
4621
      this();
4622
      this.warehouse_id = warehouse_id;
4623
      setWarehouse_idIsSet(true);
4624
      this.timestamp = timestamp;
4625
      this.availability = availability;
4626
    }
4627
 
4628
    /**
4629
     * Performs a deep copy on <i>other</i>.
4630
     */
4631
    public updateInventoryHistory_args(updateInventoryHistory_args other) {
4632
      __isset_bit_vector.clear();
4633
      __isset_bit_vector.or(other.__isset_bit_vector);
4634
      this.warehouse_id = other.warehouse_id;
4635
      if (other.isSetTimestamp()) {
4636
        this.timestamp = other.timestamp;
4637
      }
4638
      if (other.isSetAvailability()) {
4639
        Map<String,Long> __this__availability = new HashMap<String,Long>();
4640
        for (Map.Entry<String, Long> other_element : other.availability.entrySet()) {
4641
 
4642
          String other_element_key = other_element.getKey();
4643
          Long other_element_value = other_element.getValue();
4644
 
4645
          String __this__availability_copy_key = other_element_key;
4646
 
4647
          Long __this__availability_copy_value = other_element_value;
4648
 
4649
          __this__availability.put(__this__availability_copy_key, __this__availability_copy_value);
4650
        }
4651
        this.availability = __this__availability;
4652
      }
4653
    }
4654
 
4655
    public updateInventoryHistory_args deepCopy() {
4656
      return new updateInventoryHistory_args(this);
4657
    }
4658
 
4659
    @Override
4660
    public void clear() {
4661
      setWarehouse_idIsSet(false);
4662
      this.warehouse_id = 0;
4663
      this.timestamp = null;
4664
      this.availability = null;
4665
    }
4666
 
4667
    public long getWarehouse_id() {
4668
      return this.warehouse_id;
4669
    }
4670
 
4671
    public void setWarehouse_id(long warehouse_id) {
4672
      this.warehouse_id = warehouse_id;
4673
      setWarehouse_idIsSet(true);
4674
    }
4675
 
4676
    public void unsetWarehouse_id() {
4677
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
4678
    }
4679
 
4680
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
4681
    public boolean isSetWarehouse_id() {
4682
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
4683
    }
4684
 
4685
    public void setWarehouse_idIsSet(boolean value) {
4686
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
4687
    }
4688
 
4689
    public String getTimestamp() {
4690
      return this.timestamp;
4691
    }
4692
 
4693
    public void setTimestamp(String timestamp) {
4694
      this.timestamp = timestamp;
4695
    }
4696
 
4697
    public void unsetTimestamp() {
4698
      this.timestamp = null;
4699
    }
4700
 
4701
    /** Returns true if field timestamp is set (has been assigned a value) and false otherwise */
4702
    public boolean isSetTimestamp() {
4703
      return this.timestamp != null;
4704
    }
4705
 
4706
    public void setTimestampIsSet(boolean value) {
4707
      if (!value) {
4708
        this.timestamp = null;
4709
      }
4710
    }
4711
 
4712
    public int getAvailabilitySize() {
4713
      return (this.availability == null) ? 0 : this.availability.size();
4714
    }
4715
 
4716
    public void putToAvailability(String key, long val) {
4717
      if (this.availability == null) {
4718
        this.availability = new HashMap<String,Long>();
4719
      }
4720
      this.availability.put(key, val);
4721
    }
4722
 
4723
    public Map<String,Long> getAvailability() {
4724
      return this.availability;
4725
    }
4726
 
4727
    public void setAvailability(Map<String,Long> availability) {
4728
      this.availability = availability;
4729
    }
4730
 
4731
    public void unsetAvailability() {
4732
      this.availability = null;
4733
    }
4734
 
4735
    /** Returns true if field availability is set (has been assigned a value) and false otherwise */
4736
    public boolean isSetAvailability() {
4737
      return this.availability != null;
4738
    }
4739
 
4740
    public void setAvailabilityIsSet(boolean value) {
4741
      if (!value) {
4742
        this.availability = null;
4743
      }
4744
    }
4745
 
4746
    public void setFieldValue(_Fields field, Object value) {
4747
      switch (field) {
4748
      case WAREHOUSE_ID:
4749
        if (value == null) {
4750
          unsetWarehouse_id();
4751
        } else {
4752
          setWarehouse_id((Long)value);
4753
        }
4754
        break;
4755
 
4756
      case TIMESTAMP:
4757
        if (value == null) {
4758
          unsetTimestamp();
4759
        } else {
4760
          setTimestamp((String)value);
4761
        }
4762
        break;
4763
 
4764
      case AVAILABILITY:
4765
        if (value == null) {
4766
          unsetAvailability();
4767
        } else {
4768
          setAvailability((Map<String,Long>)value);
4769
        }
4770
        break;
4771
 
4772
      }
4773
    }
4774
 
4775
    public Object getFieldValue(_Fields field) {
4776
      switch (field) {
4777
      case WAREHOUSE_ID:
4778
        return Long.valueOf(getWarehouse_id());
4779
 
4780
      case TIMESTAMP:
4781
        return getTimestamp();
4782
 
4783
      case AVAILABILITY:
4784
        return getAvailability();
4785
 
4786
      }
4787
      throw new IllegalStateException();
4788
    }
4789
 
4790
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4791
    public boolean isSet(_Fields field) {
4792
      if (field == null) {
4793
        throw new IllegalArgumentException();
4794
      }
4795
 
4796
      switch (field) {
4797
      case WAREHOUSE_ID:
4798
        return isSetWarehouse_id();
4799
      case TIMESTAMP:
4800
        return isSetTimestamp();
4801
      case AVAILABILITY:
4802
        return isSetAvailability();
4803
      }
4804
      throw new IllegalStateException();
4805
    }
4806
 
4807
    @Override
4808
    public boolean equals(Object that) {
4809
      if (that == null)
4810
        return false;
4811
      if (that instanceof updateInventoryHistory_args)
4812
        return this.equals((updateInventoryHistory_args)that);
4813
      return false;
4814
    }
4815
 
4816
    public boolean equals(updateInventoryHistory_args that) {
4817
      if (that == null)
4818
        return false;
4819
 
4820
      boolean this_present_warehouse_id = true;
4821
      boolean that_present_warehouse_id = true;
4822
      if (this_present_warehouse_id || that_present_warehouse_id) {
4823
        if (!(this_present_warehouse_id && that_present_warehouse_id))
4824
          return false;
4825
        if (this.warehouse_id != that.warehouse_id)
4826
          return false;
4827
      }
4828
 
4829
      boolean this_present_timestamp = true && this.isSetTimestamp();
4830
      boolean that_present_timestamp = true && that.isSetTimestamp();
4831
      if (this_present_timestamp || that_present_timestamp) {
4832
        if (!(this_present_timestamp && that_present_timestamp))
4833
          return false;
4834
        if (!this.timestamp.equals(that.timestamp))
4835
          return false;
4836
      }
4837
 
4838
      boolean this_present_availability = true && this.isSetAvailability();
4839
      boolean that_present_availability = true && that.isSetAvailability();
4840
      if (this_present_availability || that_present_availability) {
4841
        if (!(this_present_availability && that_present_availability))
4842
          return false;
4843
        if (!this.availability.equals(that.availability))
4844
          return false;
4845
      }
4846
 
4847
      return true;
4848
    }
4849
 
4850
    @Override
4851
    public int hashCode() {
4852
      return 0;
4853
    }
4854
 
4855
    public int compareTo(updateInventoryHistory_args other) {
4856
      if (!getClass().equals(other.getClass())) {
4857
        return getClass().getName().compareTo(other.getClass().getName());
4858
      }
4859
 
4860
      int lastComparison = 0;
4861
      updateInventoryHistory_args typedOther = (updateInventoryHistory_args)other;
4862
 
4863
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
4864
      if (lastComparison != 0) {
4865
        return lastComparison;
4866
      }
4867
      if (isSetWarehouse_id()) {
4868
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
4869
        if (lastComparison != 0) {
4870
          return lastComparison;
4871
        }
4872
      }
4873
      lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(typedOther.isSetTimestamp());
4874
      if (lastComparison != 0) {
4875
        return lastComparison;
4876
      }
4877
      if (isSetTimestamp()) {
4878
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.timestamp, typedOther.timestamp);
4879
        if (lastComparison != 0) {
4880
          return lastComparison;
4881
        }
4882
      }
4883
      lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(typedOther.isSetAvailability());
4884
      if (lastComparison != 0) {
4885
        return lastComparison;
4886
      }
4887
      if (isSetAvailability()) {
4888
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.availability, typedOther.availability);
4889
        if (lastComparison != 0) {
4890
          return lastComparison;
4891
        }
4892
      }
4893
      return 0;
4894
    }
4895
 
4896
    public _Fields fieldForId(int fieldId) {
4897
      return _Fields.findByThriftId(fieldId);
4898
    }
4899
 
4900
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4901
      org.apache.thrift.protocol.TField field;
4902
      iprot.readStructBegin();
4903
      while (true)
4904
      {
4905
        field = iprot.readFieldBegin();
4906
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
4907
          break;
4908
        }
4909
        switch (field.id) {
4910
          case 1: // WAREHOUSE_ID
4911
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4912
              this.warehouse_id = iprot.readI64();
4913
              setWarehouse_idIsSet(true);
4914
            } else { 
4915
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4916
            }
4917
            break;
4918
          case 2: // TIMESTAMP
4919
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
4920
              this.timestamp = iprot.readString();
4921
            } else { 
4922
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4923
            }
4924
            break;
4925
          case 3: // AVAILABILITY
4926
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
4927
              {
4928
                org.apache.thrift.protocol.TMap _map10 = iprot.readMapBegin();
4929
                this.availability = new HashMap<String,Long>(2*_map10.size);
4930
                for (int _i11 = 0; _i11 < _map10.size; ++_i11)
4931
                {
4932
                  String _key12; // required
4933
                  long _val13; // required
4934
                  _key12 = iprot.readString();
4935
                  _val13 = iprot.readI64();
4936
                  this.availability.put(_key12, _val13);
4937
                }
4938
                iprot.readMapEnd();
4939
              }
4940
            } else { 
4941
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4942
            }
4943
            break;
4944
          default:
4945
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4946
        }
4947
        iprot.readFieldEnd();
4948
      }
4949
      iprot.readStructEnd();
4950
      validate();
4951
    }
4952
 
4953
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
4954
      validate();
4955
 
4956
      oprot.writeStructBegin(STRUCT_DESC);
4957
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
4958
      oprot.writeI64(this.warehouse_id);
4959
      oprot.writeFieldEnd();
4960
      if (this.timestamp != null) {
4961
        oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
4962
        oprot.writeString(this.timestamp);
4963
        oprot.writeFieldEnd();
4964
      }
4965
      if (this.availability != null) {
4966
        oprot.writeFieldBegin(AVAILABILITY_FIELD_DESC);
4967
        {
4968
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.I64, this.availability.size()));
4969
          for (Map.Entry<String, Long> _iter14 : this.availability.entrySet())
4970
          {
4971
            oprot.writeString(_iter14.getKey());
4972
            oprot.writeI64(_iter14.getValue());
4973
          }
4974
          oprot.writeMapEnd();
4975
        }
4976
        oprot.writeFieldEnd();
4977
      }
4978
      oprot.writeFieldStop();
4979
      oprot.writeStructEnd();
4980
    }
4981
 
4982
    @Override
4983
    public String toString() {
4984
      StringBuilder sb = new StringBuilder("updateInventoryHistory_args(");
4985
      boolean first = true;
4986
 
4987
      sb.append("warehouse_id:");
4988
      sb.append(this.warehouse_id);
4989
      first = false;
4990
      if (!first) sb.append(", ");
4991
      sb.append("timestamp:");
4992
      if (this.timestamp == null) {
4993
        sb.append("null");
4994
      } else {
4995
        sb.append(this.timestamp);
4996
      }
4997
      first = false;
4998
      if (!first) sb.append(", ");
4999
      sb.append("availability:");
5000
      if (this.availability == null) {
5001
        sb.append("null");
5002
      } else {
5003
        sb.append(this.availability);
5004
      }
5005
      first = false;
5006
      sb.append(")");
5007
      return sb.toString();
5008
    }
5009
 
5010
    public void validate() throws org.apache.thrift.TException {
5011
      // check for required fields
5012
    }
5013
 
5014
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5015
      try {
5016
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5017
      } catch (org.apache.thrift.TException te) {
5018
        throw new java.io.IOException(te);
5019
      }
5020
    }
5021
 
5022
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5023
      try {
5024
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
5025
        __isset_bit_vector = new BitSet(1);
5026
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5027
      } catch (org.apache.thrift.TException te) {
5028
        throw new java.io.IOException(te);
5029
      }
5030
    }
5031
 
5032
  }
5033
 
5034
  public static class updateInventoryHistory_result implements org.apache.thrift.TBase<updateInventoryHistory_result, updateInventoryHistory_result._Fields>, java.io.Serializable, Cloneable   {
5035
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventoryHistory_result");
5036
 
5037
    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);
5038
 
5039
    private InventoryServiceException cex; // required
5040
 
5041
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5042
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5043
      CEX((short)1, "cex");
5044
 
5045
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5046
 
5047
      static {
5048
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5049
          byName.put(field.getFieldName(), field);
5050
        }
5051
      }
5052
 
5053
      /**
5054
       * Find the _Fields constant that matches fieldId, or null if its not found.
5055
       */
5056
      public static _Fields findByThriftId(int fieldId) {
5057
        switch(fieldId) {
5058
          case 1: // CEX
5059
            return CEX;
5060
          default:
5061
            return null;
5062
        }
5063
      }
5064
 
5065
      /**
5066
       * Find the _Fields constant that matches fieldId, throwing an exception
5067
       * if it is not found.
5068
       */
5069
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5070
        _Fields fields = findByThriftId(fieldId);
5071
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5072
        return fields;
5073
      }
5074
 
5075
      /**
5076
       * Find the _Fields constant that matches name, or null if its not found.
5077
       */
5078
      public static _Fields findByName(String name) {
5079
        return byName.get(name);
5080
      }
5081
 
5082
      private final short _thriftId;
5083
      private final String _fieldName;
5084
 
5085
      _Fields(short thriftId, String fieldName) {
5086
        _thriftId = thriftId;
5087
        _fieldName = fieldName;
5088
      }
5089
 
5090
      public short getThriftFieldId() {
5091
        return _thriftId;
5092
      }
5093
 
5094
      public String getFieldName() {
5095
        return _fieldName;
5096
      }
5097
    }
5098
 
5099
    // isset id assignments
5100
 
5101
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5102
    static {
5103
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5104
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5105
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5106
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5107
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventoryHistory_result.class, metaDataMap);
5108
    }
5109
 
5110
    public updateInventoryHistory_result() {
5111
    }
5112
 
5113
    public updateInventoryHistory_result(
5114
      InventoryServiceException cex)
5115
    {
5116
      this();
5117
      this.cex = cex;
5118
    }
5119
 
5120
    /**
5121
     * Performs a deep copy on <i>other</i>.
5122
     */
5123
    public updateInventoryHistory_result(updateInventoryHistory_result other) {
5124
      if (other.isSetCex()) {
5125
        this.cex = new InventoryServiceException(other.cex);
5126
      }
5127
    }
5128
 
5129
    public updateInventoryHistory_result deepCopy() {
5130
      return new updateInventoryHistory_result(this);
5131
    }
5132
 
5133
    @Override
5134
    public void clear() {
5135
      this.cex = null;
5136
    }
5137
 
5138
    public InventoryServiceException getCex() {
5139
      return this.cex;
5140
    }
5141
 
5142
    public void setCex(InventoryServiceException cex) {
5143
      this.cex = cex;
5144
    }
5145
 
5146
    public void unsetCex() {
5147
      this.cex = null;
5148
    }
5149
 
5150
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
5151
    public boolean isSetCex() {
5152
      return this.cex != null;
5153
    }
5154
 
5155
    public void setCexIsSet(boolean value) {
5156
      if (!value) {
5157
        this.cex = null;
5158
      }
5159
    }
5160
 
5161
    public void setFieldValue(_Fields field, Object value) {
5162
      switch (field) {
5163
      case CEX:
5164
        if (value == null) {
5165
          unsetCex();
5166
        } else {
5167
          setCex((InventoryServiceException)value);
5168
        }
5169
        break;
5170
 
5171
      }
5172
    }
5173
 
5174
    public Object getFieldValue(_Fields field) {
5175
      switch (field) {
5176
      case CEX:
5177
        return getCex();
5178
 
5179
      }
5180
      throw new IllegalStateException();
5181
    }
5182
 
5183
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5184
    public boolean isSet(_Fields field) {
5185
      if (field == null) {
5186
        throw new IllegalArgumentException();
5187
      }
5188
 
5189
      switch (field) {
5190
      case CEX:
5191
        return isSetCex();
5192
      }
5193
      throw new IllegalStateException();
5194
    }
5195
 
5196
    @Override
5197
    public boolean equals(Object that) {
5198
      if (that == null)
5199
        return false;
5200
      if (that instanceof updateInventoryHistory_result)
5201
        return this.equals((updateInventoryHistory_result)that);
5202
      return false;
5203
    }
5204
 
5205
    public boolean equals(updateInventoryHistory_result that) {
5206
      if (that == null)
5207
        return false;
5208
 
5209
      boolean this_present_cex = true && this.isSetCex();
5210
      boolean that_present_cex = true && that.isSetCex();
5211
      if (this_present_cex || that_present_cex) {
5212
        if (!(this_present_cex && that_present_cex))
5213
          return false;
5214
        if (!this.cex.equals(that.cex))
5215
          return false;
5216
      }
5217
 
5218
      return true;
5219
    }
5220
 
5221
    @Override
5222
    public int hashCode() {
5223
      return 0;
5224
    }
5225
 
5226
    public int compareTo(updateInventoryHistory_result other) {
5227
      if (!getClass().equals(other.getClass())) {
5228
        return getClass().getName().compareTo(other.getClass().getName());
5229
      }
5230
 
5231
      int lastComparison = 0;
5232
      updateInventoryHistory_result typedOther = (updateInventoryHistory_result)other;
5233
 
5234
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
5235
      if (lastComparison != 0) {
5236
        return lastComparison;
5237
      }
5238
      if (isSetCex()) {
5239
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
5240
        if (lastComparison != 0) {
5241
          return lastComparison;
5242
        }
5243
      }
5244
      return 0;
5245
    }
5246
 
5247
    public _Fields fieldForId(int fieldId) {
5248
      return _Fields.findByThriftId(fieldId);
5249
    }
5250
 
5251
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5252
      org.apache.thrift.protocol.TField field;
5253
      iprot.readStructBegin();
5254
      while (true)
5255
      {
5256
        field = iprot.readFieldBegin();
5257
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5258
          break;
5259
        }
5260
        switch (field.id) {
5261
          case 1: // CEX
5262
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5263
              this.cex = new InventoryServiceException();
5264
              this.cex.read(iprot);
5265
            } else { 
5266
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5267
            }
5268
            break;
5269
          default:
5270
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5271
        }
5272
        iprot.readFieldEnd();
5273
      }
5274
      iprot.readStructEnd();
5275
      validate();
5276
    }
5277
 
5278
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5279
      oprot.writeStructBegin(STRUCT_DESC);
5280
 
5281
      if (this.isSetCex()) {
5282
        oprot.writeFieldBegin(CEX_FIELD_DESC);
5283
        this.cex.write(oprot);
5284
        oprot.writeFieldEnd();
5285
      }
5286
      oprot.writeFieldStop();
5287
      oprot.writeStructEnd();
5288
    }
5289
 
5290
    @Override
5291
    public String toString() {
5292
      StringBuilder sb = new StringBuilder("updateInventoryHistory_result(");
5293
      boolean first = true;
5294
 
5295
      sb.append("cex:");
5296
      if (this.cex == null) {
5297
        sb.append("null");
5298
      } else {
5299
        sb.append(this.cex);
5300
      }
5301
      first = false;
5302
      sb.append(")");
5303
      return sb.toString();
5304
    }
5305
 
5306
    public void validate() throws org.apache.thrift.TException {
5307
      // check for required fields
5308
    }
5309
 
5310
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5311
      try {
5312
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5313
      } catch (org.apache.thrift.TException te) {
5314
        throw new java.io.IOException(te);
5315
      }
5316
    }
5317
 
5318
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5319
      try {
5320
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5321
      } catch (org.apache.thrift.TException te) {
5322
        throw new java.io.IOException(te);
5323
      }
5324
    }
5325
 
5326
  }
5327
 
5328
  public static class updateInventory_args implements org.apache.thrift.TBase<updateInventory_args, updateInventory_args._Fields>, java.io.Serializable, Cloneable   {
5329
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventory_args");
5330
 
5331
    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);
5332
    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);
5333
    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);
5334
 
5335
    private long warehouse_id; // required
5336
    private String timestamp; // required
5337
    private Map<String,Long> availability; // required
5338
 
5339
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5340
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5341
      WAREHOUSE_ID((short)1, "warehouse_id"),
5342
      TIMESTAMP((short)2, "timestamp"),
5343
      AVAILABILITY((short)3, "availability");
5344
 
5345
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5346
 
5347
      static {
5348
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5349
          byName.put(field.getFieldName(), field);
5350
        }
5351
      }
5352
 
5353
      /**
5354
       * Find the _Fields constant that matches fieldId, or null if its not found.
5355
       */
5356
      public static _Fields findByThriftId(int fieldId) {
5357
        switch(fieldId) {
5358
          case 1: // WAREHOUSE_ID
5359
            return WAREHOUSE_ID;
5360
          case 2: // TIMESTAMP
5361
            return TIMESTAMP;
5362
          case 3: // AVAILABILITY
5363
            return AVAILABILITY;
5364
          default:
5365
            return null;
5366
        }
5367
      }
5368
 
5369
      /**
5370
       * Find the _Fields constant that matches fieldId, throwing an exception
5371
       * if it is not found.
5372
       */
5373
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5374
        _Fields fields = findByThriftId(fieldId);
5375
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5376
        return fields;
5377
      }
5378
 
5379
      /**
5380
       * Find the _Fields constant that matches name, or null if its not found.
5381
       */
5382
      public static _Fields findByName(String name) {
5383
        return byName.get(name);
5384
      }
5385
 
5386
      private final short _thriftId;
5387
      private final String _fieldName;
5388
 
5389
      _Fields(short thriftId, String fieldName) {
5390
        _thriftId = thriftId;
5391
        _fieldName = fieldName;
5392
      }
5393
 
5394
      public short getThriftFieldId() {
5395
        return _thriftId;
5396
      }
5397
 
5398
      public String getFieldName() {
5399
        return _fieldName;
5400
      }
5401
    }
5402
 
5403
    // isset id assignments
5404
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
5405
    private BitSet __isset_bit_vector = new BitSet(1);
5406
 
5407
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5408
    static {
5409
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5410
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5411
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5412
      tmpMap.put(_Fields.TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("timestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5413
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
5414
      tmpMap.put(_Fields.AVAILABILITY, new org.apache.thrift.meta_data.FieldMetaData("availability", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5415
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
5416
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
5417
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
5418
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5419
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventory_args.class, metaDataMap);
5420
    }
5421
 
5422
    public updateInventory_args() {
5423
    }
5424
 
5425
    public updateInventory_args(
5426
      long warehouse_id,
5427
      String timestamp,
5428
      Map<String,Long> availability)
5429
    {
5430
      this();
5431
      this.warehouse_id = warehouse_id;
5432
      setWarehouse_idIsSet(true);
5433
      this.timestamp = timestamp;
5434
      this.availability = availability;
5435
    }
5436
 
5437
    /**
5438
     * Performs a deep copy on <i>other</i>.
5439
     */
5440
    public updateInventory_args(updateInventory_args other) {
5441
      __isset_bit_vector.clear();
5442
      __isset_bit_vector.or(other.__isset_bit_vector);
5443
      this.warehouse_id = other.warehouse_id;
5444
      if (other.isSetTimestamp()) {
5445
        this.timestamp = other.timestamp;
5446
      }
5447
      if (other.isSetAvailability()) {
5448
        Map<String,Long> __this__availability = new HashMap<String,Long>();
5449
        for (Map.Entry<String, Long> other_element : other.availability.entrySet()) {
5450
 
5451
          String other_element_key = other_element.getKey();
5452
          Long other_element_value = other_element.getValue();
5453
 
5454
          String __this__availability_copy_key = other_element_key;
5455
 
5456
          Long __this__availability_copy_value = other_element_value;
5457
 
5458
          __this__availability.put(__this__availability_copy_key, __this__availability_copy_value);
5459
        }
5460
        this.availability = __this__availability;
5461
      }
5462
    }
5463
 
5464
    public updateInventory_args deepCopy() {
5465
      return new updateInventory_args(this);
5466
    }
5467
 
5468
    @Override
5469
    public void clear() {
5470
      setWarehouse_idIsSet(false);
5471
      this.warehouse_id = 0;
5472
      this.timestamp = null;
5473
      this.availability = null;
5474
    }
5475
 
5476
    public long getWarehouse_id() {
5477
      return this.warehouse_id;
5478
    }
5479
 
5480
    public void setWarehouse_id(long warehouse_id) {
5481
      this.warehouse_id = warehouse_id;
5482
      setWarehouse_idIsSet(true);
5483
    }
5484
 
5485
    public void unsetWarehouse_id() {
5486
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
5487
    }
5488
 
5489
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
5490
    public boolean isSetWarehouse_id() {
5491
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
5492
    }
5493
 
5494
    public void setWarehouse_idIsSet(boolean value) {
5495
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
5496
    }
5497
 
5498
    public String getTimestamp() {
5499
      return this.timestamp;
5500
    }
5501
 
5502
    public void setTimestamp(String timestamp) {
5503
      this.timestamp = timestamp;
5504
    }
5505
 
5506
    public void unsetTimestamp() {
5507
      this.timestamp = null;
5508
    }
5509
 
5510
    /** Returns true if field timestamp is set (has been assigned a value) and false otherwise */
5511
    public boolean isSetTimestamp() {
5512
      return this.timestamp != null;
5513
    }
5514
 
5515
    public void setTimestampIsSet(boolean value) {
5516
      if (!value) {
5517
        this.timestamp = null;
5518
      }
5519
    }
5520
 
5521
    public int getAvailabilitySize() {
5522
      return (this.availability == null) ? 0 : this.availability.size();
5523
    }
5524
 
5525
    public void putToAvailability(String key, long val) {
5526
      if (this.availability == null) {
5527
        this.availability = new HashMap<String,Long>();
5528
      }
5529
      this.availability.put(key, val);
5530
    }
5531
 
5532
    public Map<String,Long> getAvailability() {
5533
      return this.availability;
5534
    }
5535
 
5536
    public void setAvailability(Map<String,Long> availability) {
5537
      this.availability = availability;
5538
    }
5539
 
5540
    public void unsetAvailability() {
5541
      this.availability = null;
5542
    }
5543
 
5544
    /** Returns true if field availability is set (has been assigned a value) and false otherwise */
5545
    public boolean isSetAvailability() {
5546
      return this.availability != null;
5547
    }
5548
 
5549
    public void setAvailabilityIsSet(boolean value) {
5550
      if (!value) {
5551
        this.availability = null;
5552
      }
5553
    }
5554
 
5555
    public void setFieldValue(_Fields field, Object value) {
5556
      switch (field) {
5557
      case WAREHOUSE_ID:
5558
        if (value == null) {
5559
          unsetWarehouse_id();
5560
        } else {
5561
          setWarehouse_id((Long)value);
5562
        }
5563
        break;
5564
 
5565
      case TIMESTAMP:
5566
        if (value == null) {
5567
          unsetTimestamp();
5568
        } else {
5569
          setTimestamp((String)value);
5570
        }
5571
        break;
5572
 
5573
      case AVAILABILITY:
5574
        if (value == null) {
5575
          unsetAvailability();
5576
        } else {
5577
          setAvailability((Map<String,Long>)value);
5578
        }
5579
        break;
5580
 
5581
      }
5582
    }
5583
 
5584
    public Object getFieldValue(_Fields field) {
5585
      switch (field) {
5586
      case WAREHOUSE_ID:
5587
        return Long.valueOf(getWarehouse_id());
5588
 
5589
      case TIMESTAMP:
5590
        return getTimestamp();
5591
 
5592
      case AVAILABILITY:
5593
        return getAvailability();
5594
 
5595
      }
5596
      throw new IllegalStateException();
5597
    }
5598
 
5599
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5600
    public boolean isSet(_Fields field) {
5601
      if (field == null) {
5602
        throw new IllegalArgumentException();
5603
      }
5604
 
5605
      switch (field) {
5606
      case WAREHOUSE_ID:
5607
        return isSetWarehouse_id();
5608
      case TIMESTAMP:
5609
        return isSetTimestamp();
5610
      case AVAILABILITY:
5611
        return isSetAvailability();
5612
      }
5613
      throw new IllegalStateException();
5614
    }
5615
 
5616
    @Override
5617
    public boolean equals(Object that) {
5618
      if (that == null)
5619
        return false;
5620
      if (that instanceof updateInventory_args)
5621
        return this.equals((updateInventory_args)that);
5622
      return false;
5623
    }
5624
 
5625
    public boolean equals(updateInventory_args that) {
5626
      if (that == null)
5627
        return false;
5628
 
5629
      boolean this_present_warehouse_id = true;
5630
      boolean that_present_warehouse_id = true;
5631
      if (this_present_warehouse_id || that_present_warehouse_id) {
5632
        if (!(this_present_warehouse_id && that_present_warehouse_id))
5633
          return false;
5634
        if (this.warehouse_id != that.warehouse_id)
5635
          return false;
5636
      }
5637
 
5638
      boolean this_present_timestamp = true && this.isSetTimestamp();
5639
      boolean that_present_timestamp = true && that.isSetTimestamp();
5640
      if (this_present_timestamp || that_present_timestamp) {
5641
        if (!(this_present_timestamp && that_present_timestamp))
5642
          return false;
5643
        if (!this.timestamp.equals(that.timestamp))
5644
          return false;
5645
      }
5646
 
5647
      boolean this_present_availability = true && this.isSetAvailability();
5648
      boolean that_present_availability = true && that.isSetAvailability();
5649
      if (this_present_availability || that_present_availability) {
5650
        if (!(this_present_availability && that_present_availability))
5651
          return false;
5652
        if (!this.availability.equals(that.availability))
5653
          return false;
5654
      }
5655
 
5656
      return true;
5657
    }
5658
 
5659
    @Override
5660
    public int hashCode() {
5661
      return 0;
5662
    }
5663
 
5664
    public int compareTo(updateInventory_args other) {
5665
      if (!getClass().equals(other.getClass())) {
5666
        return getClass().getName().compareTo(other.getClass().getName());
5667
      }
5668
 
5669
      int lastComparison = 0;
5670
      updateInventory_args typedOther = (updateInventory_args)other;
5671
 
5672
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
5673
      if (lastComparison != 0) {
5674
        return lastComparison;
5675
      }
5676
      if (isSetWarehouse_id()) {
5677
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
5678
        if (lastComparison != 0) {
5679
          return lastComparison;
5680
        }
5681
      }
5682
      lastComparison = Boolean.valueOf(isSetTimestamp()).compareTo(typedOther.isSetTimestamp());
5683
      if (lastComparison != 0) {
5684
        return lastComparison;
5685
      }
5686
      if (isSetTimestamp()) {
5687
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.timestamp, typedOther.timestamp);
5688
        if (lastComparison != 0) {
5689
          return lastComparison;
5690
        }
5691
      }
5692
      lastComparison = Boolean.valueOf(isSetAvailability()).compareTo(typedOther.isSetAvailability());
5693
      if (lastComparison != 0) {
5694
        return lastComparison;
5695
      }
5696
      if (isSetAvailability()) {
5697
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.availability, typedOther.availability);
5698
        if (lastComparison != 0) {
5699
          return lastComparison;
5700
        }
5701
      }
5702
      return 0;
5703
    }
5704
 
5705
    public _Fields fieldForId(int fieldId) {
5706
      return _Fields.findByThriftId(fieldId);
5707
    }
5708
 
5709
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5710
      org.apache.thrift.protocol.TField field;
5711
      iprot.readStructBegin();
5712
      while (true)
5713
      {
5714
        field = iprot.readFieldBegin();
5715
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
5716
          break;
5717
        }
5718
        switch (field.id) {
5719
          case 1: // WAREHOUSE_ID
5720
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5721
              this.warehouse_id = iprot.readI64();
5722
              setWarehouse_idIsSet(true);
5723
            } else { 
5724
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5725
            }
5726
            break;
5727
          case 2: // TIMESTAMP
5728
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
5729
              this.timestamp = iprot.readString();
5730
            } else { 
5731
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5732
            }
5733
            break;
5734
          case 3: // AVAILABILITY
5735
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
5736
              {
5737
                org.apache.thrift.protocol.TMap _map15 = iprot.readMapBegin();
5738
                this.availability = new HashMap<String,Long>(2*_map15.size);
5739
                for (int _i16 = 0; _i16 < _map15.size; ++_i16)
5740
                {
5741
                  String _key17; // required
5742
                  long _val18; // required
5743
                  _key17 = iprot.readString();
5744
                  _val18 = iprot.readI64();
5745
                  this.availability.put(_key17, _val18);
5746
                }
5747
                iprot.readMapEnd();
5748
              }
5749
            } else { 
5750
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5751
            }
5752
            break;
5753
          default:
5754
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5755
        }
5756
        iprot.readFieldEnd();
5757
      }
5758
      iprot.readStructEnd();
5759
      validate();
5760
    }
5761
 
5762
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
5763
      validate();
5764
 
5765
      oprot.writeStructBegin(STRUCT_DESC);
5766
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
5767
      oprot.writeI64(this.warehouse_id);
5768
      oprot.writeFieldEnd();
5769
      if (this.timestamp != null) {
5770
        oprot.writeFieldBegin(TIMESTAMP_FIELD_DESC);
5771
        oprot.writeString(this.timestamp);
5772
        oprot.writeFieldEnd();
5773
      }
5774
      if (this.availability != null) {
5775
        oprot.writeFieldBegin(AVAILABILITY_FIELD_DESC);
5776
        {
5777
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.I64, this.availability.size()));
5778
          for (Map.Entry<String, Long> _iter19 : this.availability.entrySet())
5779
          {
5780
            oprot.writeString(_iter19.getKey());
5781
            oprot.writeI64(_iter19.getValue());
5782
          }
5783
          oprot.writeMapEnd();
5784
        }
5785
        oprot.writeFieldEnd();
5786
      }
5787
      oprot.writeFieldStop();
5788
      oprot.writeStructEnd();
5789
    }
5790
 
5791
    @Override
5792
    public String toString() {
5793
      StringBuilder sb = new StringBuilder("updateInventory_args(");
5794
      boolean first = true;
5795
 
5796
      sb.append("warehouse_id:");
5797
      sb.append(this.warehouse_id);
5798
      first = false;
5799
      if (!first) sb.append(", ");
5800
      sb.append("timestamp:");
5801
      if (this.timestamp == null) {
5802
        sb.append("null");
5803
      } else {
5804
        sb.append(this.timestamp);
5805
      }
5806
      first = false;
5807
      if (!first) sb.append(", ");
5808
      sb.append("availability:");
5809
      if (this.availability == null) {
5810
        sb.append("null");
5811
      } else {
5812
        sb.append(this.availability);
5813
      }
5814
      first = false;
5815
      sb.append(")");
5816
      return sb.toString();
5817
    }
5818
 
5819
    public void validate() throws org.apache.thrift.TException {
5820
      // check for required fields
5821
    }
5822
 
5823
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5824
      try {
5825
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5826
      } catch (org.apache.thrift.TException te) {
5827
        throw new java.io.IOException(te);
5828
      }
5829
    }
5830
 
5831
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5832
      try {
5833
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
5834
        __isset_bit_vector = new BitSet(1);
5835
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5836
      } catch (org.apache.thrift.TException te) {
5837
        throw new java.io.IOException(te);
5838
      }
5839
    }
5840
 
5841
  }
5842
 
5843
  public static class updateInventory_result implements org.apache.thrift.TBase<updateInventory_result, updateInventory_result._Fields>, java.io.Serializable, Cloneable   {
5844
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateInventory_result");
5845
 
5846
    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);
5847
 
5848
    private InventoryServiceException cex; // required
5849
 
5850
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
5851
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5852
      CEX((short)1, "cex");
5853
 
5854
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5855
 
5856
      static {
5857
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5858
          byName.put(field.getFieldName(), field);
5859
        }
5860
      }
5861
 
5862
      /**
5863
       * Find the _Fields constant that matches fieldId, or null if its not found.
5864
       */
5865
      public static _Fields findByThriftId(int fieldId) {
5866
        switch(fieldId) {
5867
          case 1: // CEX
5868
            return CEX;
5869
          default:
5870
            return null;
5871
        }
5872
      }
5873
 
5874
      /**
5875
       * Find the _Fields constant that matches fieldId, throwing an exception
5876
       * if it is not found.
5877
       */
5878
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5879
        _Fields fields = findByThriftId(fieldId);
5880
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5881
        return fields;
5882
      }
5883
 
5884
      /**
5885
       * Find the _Fields constant that matches name, or null if its not found.
5886
       */
5887
      public static _Fields findByName(String name) {
5888
        return byName.get(name);
5889
      }
5890
 
5891
      private final short _thriftId;
5892
      private final String _fieldName;
5893
 
5894
      _Fields(short thriftId, String fieldName) {
5895
        _thriftId = thriftId;
5896
        _fieldName = fieldName;
5897
      }
5898
 
5899
      public short getThriftFieldId() {
5900
        return _thriftId;
5901
      }
5902
 
5903
      public String getFieldName() {
5904
        return _fieldName;
5905
      }
5906
    }
5907
 
5908
    // isset id assignments
5909
 
5910
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
5911
    static {
5912
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5913
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5914
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5915
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5916
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateInventory_result.class, metaDataMap);
5917
    }
5918
 
5919
    public updateInventory_result() {
5920
    }
5921
 
5922
    public updateInventory_result(
5923
      InventoryServiceException cex)
5924
    {
5925
      this();
5926
      this.cex = cex;
5927
    }
5928
 
5929
    /**
5930
     * Performs a deep copy on <i>other</i>.
5931
     */
5932
    public updateInventory_result(updateInventory_result other) {
5933
      if (other.isSetCex()) {
5934
        this.cex = new InventoryServiceException(other.cex);
5935
      }
5936
    }
5937
 
5938
    public updateInventory_result deepCopy() {
5939
      return new updateInventory_result(this);
5940
    }
5941
 
5942
    @Override
5943
    public void clear() {
5944
      this.cex = null;
5945
    }
5946
 
5947
    public InventoryServiceException getCex() {
5948
      return this.cex;
5949
    }
5950
 
5951
    public void setCex(InventoryServiceException cex) {
5952
      this.cex = cex;
5953
    }
5954
 
5955
    public void unsetCex() {
5956
      this.cex = null;
5957
    }
5958
 
5959
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
5960
    public boolean isSetCex() {
5961
      return this.cex != null;
5962
    }
5963
 
5964
    public void setCexIsSet(boolean value) {
5965
      if (!value) {
5966
        this.cex = null;
5967
      }
5968
    }
5969
 
5970
    public void setFieldValue(_Fields field, Object value) {
5971
      switch (field) {
5972
      case CEX:
5973
        if (value == null) {
5974
          unsetCex();
5975
        } else {
5976
          setCex((InventoryServiceException)value);
5977
        }
5978
        break;
5979
 
5980
      }
5981
    }
5982
 
5983
    public Object getFieldValue(_Fields field) {
5984
      switch (field) {
5985
      case CEX:
5986
        return getCex();
5987
 
5988
      }
5989
      throw new IllegalStateException();
5990
    }
5991
 
5992
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5993
    public boolean isSet(_Fields field) {
5994
      if (field == null) {
5995
        throw new IllegalArgumentException();
5996
      }
5997
 
5998
      switch (field) {
5999
      case CEX:
6000
        return isSetCex();
6001
      }
6002
      throw new IllegalStateException();
6003
    }
6004
 
6005
    @Override
6006
    public boolean equals(Object that) {
6007
      if (that == null)
6008
        return false;
6009
      if (that instanceof updateInventory_result)
6010
        return this.equals((updateInventory_result)that);
6011
      return false;
6012
    }
6013
 
6014
    public boolean equals(updateInventory_result that) {
6015
      if (that == null)
6016
        return false;
6017
 
6018
      boolean this_present_cex = true && this.isSetCex();
6019
      boolean that_present_cex = true && that.isSetCex();
6020
      if (this_present_cex || that_present_cex) {
6021
        if (!(this_present_cex && that_present_cex))
6022
          return false;
6023
        if (!this.cex.equals(that.cex))
6024
          return false;
6025
      }
6026
 
6027
      return true;
6028
    }
6029
 
6030
    @Override
6031
    public int hashCode() {
6032
      return 0;
6033
    }
6034
 
6035
    public int compareTo(updateInventory_result other) {
6036
      if (!getClass().equals(other.getClass())) {
6037
        return getClass().getName().compareTo(other.getClass().getName());
6038
      }
6039
 
6040
      int lastComparison = 0;
6041
      updateInventory_result typedOther = (updateInventory_result)other;
6042
 
6043
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
6044
      if (lastComparison != 0) {
6045
        return lastComparison;
6046
      }
6047
      if (isSetCex()) {
6048
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
6049
        if (lastComparison != 0) {
6050
          return lastComparison;
6051
        }
6052
      }
6053
      return 0;
6054
    }
6055
 
6056
    public _Fields fieldForId(int fieldId) {
6057
      return _Fields.findByThriftId(fieldId);
6058
    }
6059
 
6060
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6061
      org.apache.thrift.protocol.TField field;
6062
      iprot.readStructBegin();
6063
      while (true)
6064
      {
6065
        field = iprot.readFieldBegin();
6066
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6067
          break;
6068
        }
6069
        switch (field.id) {
6070
          case 1: // CEX
6071
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6072
              this.cex = new InventoryServiceException();
6073
              this.cex.read(iprot);
6074
            } else { 
6075
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6076
            }
6077
            break;
6078
          default:
6079
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6080
        }
6081
        iprot.readFieldEnd();
6082
      }
6083
      iprot.readStructEnd();
6084
      validate();
6085
    }
6086
 
6087
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6088
      oprot.writeStructBegin(STRUCT_DESC);
6089
 
6090
      if (this.isSetCex()) {
6091
        oprot.writeFieldBegin(CEX_FIELD_DESC);
6092
        this.cex.write(oprot);
6093
        oprot.writeFieldEnd();
6094
      }
6095
      oprot.writeFieldStop();
6096
      oprot.writeStructEnd();
6097
    }
6098
 
6099
    @Override
6100
    public String toString() {
6101
      StringBuilder sb = new StringBuilder("updateInventory_result(");
6102
      boolean first = true;
6103
 
6104
      sb.append("cex:");
6105
      if (this.cex == null) {
6106
        sb.append("null");
6107
      } else {
6108
        sb.append(this.cex);
6109
      }
6110
      first = false;
6111
      sb.append(")");
6112
      return sb.toString();
6113
    }
6114
 
6115
    public void validate() throws org.apache.thrift.TException {
6116
      // check for required fields
6117
    }
6118
 
6119
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6120
      try {
6121
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6122
      } catch (org.apache.thrift.TException te) {
6123
        throw new java.io.IOException(te);
6124
      }
6125
    }
6126
 
6127
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6128
      try {
6129
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6130
      } catch (org.apache.thrift.TException te) {
6131
        throw new java.io.IOException(te);
6132
      }
6133
    }
6134
 
6135
  }
6136
 
6137
  public static class addInventory_args implements org.apache.thrift.TBase<addInventory_args, addInventory_args._Fields>, java.io.Serializable, Cloneable   {
6138
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addInventory_args");
6139
 
6140
    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);
6141
    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);
6142
    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);
6143
 
6144
    private long itemId; // required
6145
    private long warehouseId; // required
6146
    private long quantity; // required
6147
 
6148
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6149
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6150
      ITEM_ID((short)1, "itemId"),
6151
      WAREHOUSE_ID((short)2, "warehouseId"),
6152
      QUANTITY((short)3, "quantity");
6153
 
6154
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6155
 
6156
      static {
6157
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6158
          byName.put(field.getFieldName(), field);
6159
        }
6160
      }
6161
 
6162
      /**
6163
       * Find the _Fields constant that matches fieldId, or null if its not found.
6164
       */
6165
      public static _Fields findByThriftId(int fieldId) {
6166
        switch(fieldId) {
6167
          case 1: // ITEM_ID
6168
            return ITEM_ID;
6169
          case 2: // WAREHOUSE_ID
6170
            return WAREHOUSE_ID;
6171
          case 3: // QUANTITY
6172
            return QUANTITY;
6173
          default:
6174
            return null;
6175
        }
6176
      }
6177
 
6178
      /**
6179
       * Find the _Fields constant that matches fieldId, throwing an exception
6180
       * if it is not found.
6181
       */
6182
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6183
        _Fields fields = findByThriftId(fieldId);
6184
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6185
        return fields;
6186
      }
6187
 
6188
      /**
6189
       * Find the _Fields constant that matches name, or null if its not found.
6190
       */
6191
      public static _Fields findByName(String name) {
6192
        return byName.get(name);
6193
      }
6194
 
6195
      private final short _thriftId;
6196
      private final String _fieldName;
6197
 
6198
      _Fields(short thriftId, String fieldName) {
6199
        _thriftId = thriftId;
6200
        _fieldName = fieldName;
6201
      }
6202
 
6203
      public short getThriftFieldId() {
6204
        return _thriftId;
6205
      }
6206
 
6207
      public String getFieldName() {
6208
        return _fieldName;
6209
      }
6210
    }
6211
 
6212
    // isset id assignments
6213
    private static final int __ITEMID_ISSET_ID = 0;
6214
    private static final int __WAREHOUSEID_ISSET_ID = 1;
6215
    private static final int __QUANTITY_ISSET_ID = 2;
6216
    private BitSet __isset_bit_vector = new BitSet(3);
6217
 
6218
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6219
    static {
6220
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6221
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6222
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6223
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6224
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6225
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6226
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6227
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6228
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addInventory_args.class, metaDataMap);
6229
    }
6230
 
6231
    public addInventory_args() {
6232
    }
6233
 
6234
    public addInventory_args(
6235
      long itemId,
6236
      long warehouseId,
6237
      long quantity)
6238
    {
6239
      this();
6240
      this.itemId = itemId;
6241
      setItemIdIsSet(true);
6242
      this.warehouseId = warehouseId;
6243
      setWarehouseIdIsSet(true);
6244
      this.quantity = quantity;
6245
      setQuantityIsSet(true);
6246
    }
6247
 
6248
    /**
6249
     * Performs a deep copy on <i>other</i>.
6250
     */
6251
    public addInventory_args(addInventory_args other) {
6252
      __isset_bit_vector.clear();
6253
      __isset_bit_vector.or(other.__isset_bit_vector);
6254
      this.itemId = other.itemId;
6255
      this.warehouseId = other.warehouseId;
6256
      this.quantity = other.quantity;
6257
    }
6258
 
6259
    public addInventory_args deepCopy() {
6260
      return new addInventory_args(this);
6261
    }
6262
 
6263
    @Override
6264
    public void clear() {
6265
      setItemIdIsSet(false);
6266
      this.itemId = 0;
6267
      setWarehouseIdIsSet(false);
6268
      this.warehouseId = 0;
6269
      setQuantityIsSet(false);
6270
      this.quantity = 0;
6271
    }
6272
 
6273
    public long getItemId() {
6274
      return this.itemId;
6275
    }
6276
 
6277
    public void setItemId(long itemId) {
6278
      this.itemId = itemId;
6279
      setItemIdIsSet(true);
6280
    }
6281
 
6282
    public void unsetItemId() {
6283
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
6284
    }
6285
 
6286
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
6287
    public boolean isSetItemId() {
6288
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
6289
    }
6290
 
6291
    public void setItemIdIsSet(boolean value) {
6292
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
6293
    }
6294
 
6295
    public long getWarehouseId() {
6296
      return this.warehouseId;
6297
    }
6298
 
6299
    public void setWarehouseId(long warehouseId) {
6300
      this.warehouseId = warehouseId;
6301
      setWarehouseIdIsSet(true);
6302
    }
6303
 
6304
    public void unsetWarehouseId() {
6305
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
6306
    }
6307
 
6308
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
6309
    public boolean isSetWarehouseId() {
6310
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
6311
    }
6312
 
6313
    public void setWarehouseIdIsSet(boolean value) {
6314
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
6315
    }
6316
 
6317
    public long getQuantity() {
6318
      return this.quantity;
6319
    }
6320
 
6321
    public void setQuantity(long quantity) {
6322
      this.quantity = quantity;
6323
      setQuantityIsSet(true);
6324
    }
6325
 
6326
    public void unsetQuantity() {
6327
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
6328
    }
6329
 
6330
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
6331
    public boolean isSetQuantity() {
6332
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
6333
    }
6334
 
6335
    public void setQuantityIsSet(boolean value) {
6336
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
6337
    }
6338
 
6339
    public void setFieldValue(_Fields field, Object value) {
6340
      switch (field) {
6341
      case ITEM_ID:
6342
        if (value == null) {
6343
          unsetItemId();
6344
        } else {
6345
          setItemId((Long)value);
6346
        }
6347
        break;
6348
 
6349
      case WAREHOUSE_ID:
6350
        if (value == null) {
6351
          unsetWarehouseId();
6352
        } else {
6353
          setWarehouseId((Long)value);
6354
        }
6355
        break;
6356
 
6357
      case QUANTITY:
6358
        if (value == null) {
6359
          unsetQuantity();
6360
        } else {
6361
          setQuantity((Long)value);
6362
        }
6363
        break;
6364
 
6365
      }
6366
    }
6367
 
6368
    public Object getFieldValue(_Fields field) {
6369
      switch (field) {
6370
      case ITEM_ID:
6371
        return Long.valueOf(getItemId());
6372
 
6373
      case WAREHOUSE_ID:
6374
        return Long.valueOf(getWarehouseId());
6375
 
6376
      case QUANTITY:
6377
        return Long.valueOf(getQuantity());
6378
 
6379
      }
6380
      throw new IllegalStateException();
6381
    }
6382
 
6383
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6384
    public boolean isSet(_Fields field) {
6385
      if (field == null) {
6386
        throw new IllegalArgumentException();
6387
      }
6388
 
6389
      switch (field) {
6390
      case ITEM_ID:
6391
        return isSetItemId();
6392
      case WAREHOUSE_ID:
6393
        return isSetWarehouseId();
6394
      case QUANTITY:
6395
        return isSetQuantity();
6396
      }
6397
      throw new IllegalStateException();
6398
    }
6399
 
6400
    @Override
6401
    public boolean equals(Object that) {
6402
      if (that == null)
6403
        return false;
6404
      if (that instanceof addInventory_args)
6405
        return this.equals((addInventory_args)that);
6406
      return false;
6407
    }
6408
 
6409
    public boolean equals(addInventory_args that) {
6410
      if (that == null)
6411
        return false;
6412
 
6413
      boolean this_present_itemId = true;
6414
      boolean that_present_itemId = true;
6415
      if (this_present_itemId || that_present_itemId) {
6416
        if (!(this_present_itemId && that_present_itemId))
6417
          return false;
6418
        if (this.itemId != that.itemId)
6419
          return false;
6420
      }
6421
 
6422
      boolean this_present_warehouseId = true;
6423
      boolean that_present_warehouseId = true;
6424
      if (this_present_warehouseId || that_present_warehouseId) {
6425
        if (!(this_present_warehouseId && that_present_warehouseId))
6426
          return false;
6427
        if (this.warehouseId != that.warehouseId)
6428
          return false;
6429
      }
6430
 
6431
      boolean this_present_quantity = true;
6432
      boolean that_present_quantity = true;
6433
      if (this_present_quantity || that_present_quantity) {
6434
        if (!(this_present_quantity && that_present_quantity))
6435
          return false;
6436
        if (this.quantity != that.quantity)
6437
          return false;
6438
      }
6439
 
6440
      return true;
6441
    }
6442
 
6443
    @Override
6444
    public int hashCode() {
6445
      return 0;
6446
    }
6447
 
6448
    public int compareTo(addInventory_args other) {
6449
      if (!getClass().equals(other.getClass())) {
6450
        return getClass().getName().compareTo(other.getClass().getName());
6451
      }
6452
 
6453
      int lastComparison = 0;
6454
      addInventory_args typedOther = (addInventory_args)other;
6455
 
6456
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
6457
      if (lastComparison != 0) {
6458
        return lastComparison;
6459
      }
6460
      if (isSetItemId()) {
6461
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
6462
        if (lastComparison != 0) {
6463
          return lastComparison;
6464
        }
6465
      }
6466
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
6467
      if (lastComparison != 0) {
6468
        return lastComparison;
6469
      }
6470
      if (isSetWarehouseId()) {
6471
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
6472
        if (lastComparison != 0) {
6473
          return lastComparison;
6474
        }
6475
      }
6476
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
6477
      if (lastComparison != 0) {
6478
        return lastComparison;
6479
      }
6480
      if (isSetQuantity()) {
6481
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
6482
        if (lastComparison != 0) {
6483
          return lastComparison;
6484
        }
6485
      }
6486
      return 0;
6487
    }
6488
 
6489
    public _Fields fieldForId(int fieldId) {
6490
      return _Fields.findByThriftId(fieldId);
6491
    }
6492
 
6493
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6494
      org.apache.thrift.protocol.TField field;
6495
      iprot.readStructBegin();
6496
      while (true)
6497
      {
6498
        field = iprot.readFieldBegin();
6499
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6500
          break;
6501
        }
6502
        switch (field.id) {
6503
          case 1: // ITEM_ID
6504
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6505
              this.itemId = iprot.readI64();
6506
              setItemIdIsSet(true);
6507
            } else { 
6508
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6509
            }
6510
            break;
6511
          case 2: // WAREHOUSE_ID
6512
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6513
              this.warehouseId = iprot.readI64();
6514
              setWarehouseIdIsSet(true);
6515
            } else { 
6516
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6517
            }
6518
            break;
6519
          case 3: // QUANTITY
6520
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6521
              this.quantity = iprot.readI64();
6522
              setQuantityIsSet(true);
6523
            } else { 
6524
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6525
            }
6526
            break;
6527
          default:
6528
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6529
        }
6530
        iprot.readFieldEnd();
6531
      }
6532
      iprot.readStructEnd();
6533
      validate();
6534
    }
6535
 
6536
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6537
      validate();
6538
 
6539
      oprot.writeStructBegin(STRUCT_DESC);
6540
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
6541
      oprot.writeI64(this.itemId);
6542
      oprot.writeFieldEnd();
6543
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
6544
      oprot.writeI64(this.warehouseId);
6545
      oprot.writeFieldEnd();
6546
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
6547
      oprot.writeI64(this.quantity);
6548
      oprot.writeFieldEnd();
6549
      oprot.writeFieldStop();
6550
      oprot.writeStructEnd();
6551
    }
6552
 
6553
    @Override
6554
    public String toString() {
6555
      StringBuilder sb = new StringBuilder("addInventory_args(");
6556
      boolean first = true;
6557
 
6558
      sb.append("itemId:");
6559
      sb.append(this.itemId);
6560
      first = false;
6561
      if (!first) sb.append(", ");
6562
      sb.append("warehouseId:");
6563
      sb.append(this.warehouseId);
6564
      first = false;
6565
      if (!first) sb.append(", ");
6566
      sb.append("quantity:");
6567
      sb.append(this.quantity);
6568
      first = false;
6569
      sb.append(")");
6570
      return sb.toString();
6571
    }
6572
 
6573
    public void validate() throws org.apache.thrift.TException {
6574
      // check for required fields
6575
    }
6576
 
6577
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6578
      try {
6579
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6580
      } catch (org.apache.thrift.TException te) {
6581
        throw new java.io.IOException(te);
6582
      }
6583
    }
6584
 
6585
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6586
      try {
6587
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
6588
        __isset_bit_vector = new BitSet(1);
6589
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6590
      } catch (org.apache.thrift.TException te) {
6591
        throw new java.io.IOException(te);
6592
      }
6593
    }
6594
 
6595
  }
6596
 
6597
  public static class addInventory_result implements org.apache.thrift.TBase<addInventory_result, addInventory_result._Fields>, java.io.Serializable, Cloneable   {
6598
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addInventory_result");
6599
 
6600
    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);
6601
 
6602
    private InventoryServiceException cex; // required
6603
 
6604
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6605
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6606
      CEX((short)1, "cex");
6607
 
6608
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6609
 
6610
      static {
6611
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6612
          byName.put(field.getFieldName(), field);
6613
        }
6614
      }
6615
 
6616
      /**
6617
       * Find the _Fields constant that matches fieldId, or null if its not found.
6618
       */
6619
      public static _Fields findByThriftId(int fieldId) {
6620
        switch(fieldId) {
6621
          case 1: // CEX
6622
            return CEX;
6623
          default:
6624
            return null;
6625
        }
6626
      }
6627
 
6628
      /**
6629
       * Find the _Fields constant that matches fieldId, throwing an exception
6630
       * if it is not found.
6631
       */
6632
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6633
        _Fields fields = findByThriftId(fieldId);
6634
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6635
        return fields;
6636
      }
6637
 
6638
      /**
6639
       * Find the _Fields constant that matches name, or null if its not found.
6640
       */
6641
      public static _Fields findByName(String name) {
6642
        return byName.get(name);
6643
      }
6644
 
6645
      private final short _thriftId;
6646
      private final String _fieldName;
6647
 
6648
      _Fields(short thriftId, String fieldName) {
6649
        _thriftId = thriftId;
6650
        _fieldName = fieldName;
6651
      }
6652
 
6653
      public short getThriftFieldId() {
6654
        return _thriftId;
6655
      }
6656
 
6657
      public String getFieldName() {
6658
        return _fieldName;
6659
      }
6660
    }
6661
 
6662
    // isset id assignments
6663
 
6664
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6665
    static {
6666
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6667
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6668
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6669
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6670
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addInventory_result.class, metaDataMap);
6671
    }
6672
 
6673
    public addInventory_result() {
6674
    }
6675
 
6676
    public addInventory_result(
6677
      InventoryServiceException cex)
6678
    {
6679
      this();
6680
      this.cex = cex;
6681
    }
6682
 
6683
    /**
6684
     * Performs a deep copy on <i>other</i>.
6685
     */
6686
    public addInventory_result(addInventory_result other) {
6687
      if (other.isSetCex()) {
6688
        this.cex = new InventoryServiceException(other.cex);
6689
      }
6690
    }
6691
 
6692
    public addInventory_result deepCopy() {
6693
      return new addInventory_result(this);
6694
    }
6695
 
6696
    @Override
6697
    public void clear() {
6698
      this.cex = null;
6699
    }
6700
 
6701
    public InventoryServiceException getCex() {
6702
      return this.cex;
6703
    }
6704
 
6705
    public void setCex(InventoryServiceException cex) {
6706
      this.cex = cex;
6707
    }
6708
 
6709
    public void unsetCex() {
6710
      this.cex = null;
6711
    }
6712
 
6713
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
6714
    public boolean isSetCex() {
6715
      return this.cex != null;
6716
    }
6717
 
6718
    public void setCexIsSet(boolean value) {
6719
      if (!value) {
6720
        this.cex = null;
6721
      }
6722
    }
6723
 
6724
    public void setFieldValue(_Fields field, Object value) {
6725
      switch (field) {
6726
      case CEX:
6727
        if (value == null) {
6728
          unsetCex();
6729
        } else {
6730
          setCex((InventoryServiceException)value);
6731
        }
6732
        break;
6733
 
6734
      }
6735
    }
6736
 
6737
    public Object getFieldValue(_Fields field) {
6738
      switch (field) {
6739
      case CEX:
6740
        return getCex();
6741
 
6742
      }
6743
      throw new IllegalStateException();
6744
    }
6745
 
6746
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6747
    public boolean isSet(_Fields field) {
6748
      if (field == null) {
6749
        throw new IllegalArgumentException();
6750
      }
6751
 
6752
      switch (field) {
6753
      case CEX:
6754
        return isSetCex();
6755
      }
6756
      throw new IllegalStateException();
6757
    }
6758
 
6759
    @Override
6760
    public boolean equals(Object that) {
6761
      if (that == null)
6762
        return false;
6763
      if (that instanceof addInventory_result)
6764
        return this.equals((addInventory_result)that);
6765
      return false;
6766
    }
6767
 
6768
    public boolean equals(addInventory_result that) {
6769
      if (that == null)
6770
        return false;
6771
 
6772
      boolean this_present_cex = true && this.isSetCex();
6773
      boolean that_present_cex = true && that.isSetCex();
6774
      if (this_present_cex || that_present_cex) {
6775
        if (!(this_present_cex && that_present_cex))
6776
          return false;
6777
        if (!this.cex.equals(that.cex))
6778
          return false;
6779
      }
6780
 
6781
      return true;
6782
    }
6783
 
6784
    @Override
6785
    public int hashCode() {
6786
      return 0;
6787
    }
6788
 
6789
    public int compareTo(addInventory_result other) {
6790
      if (!getClass().equals(other.getClass())) {
6791
        return getClass().getName().compareTo(other.getClass().getName());
6792
      }
6793
 
6794
      int lastComparison = 0;
6795
      addInventory_result typedOther = (addInventory_result)other;
6796
 
6797
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
6798
      if (lastComparison != 0) {
6799
        return lastComparison;
6800
      }
6801
      if (isSetCex()) {
6802
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
6803
        if (lastComparison != 0) {
6804
          return lastComparison;
6805
        }
6806
      }
6807
      return 0;
6808
    }
6809
 
6810
    public _Fields fieldForId(int fieldId) {
6811
      return _Fields.findByThriftId(fieldId);
6812
    }
6813
 
6814
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6815
      org.apache.thrift.protocol.TField field;
6816
      iprot.readStructBegin();
6817
      while (true)
6818
      {
6819
        field = iprot.readFieldBegin();
6820
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
6821
          break;
6822
        }
6823
        switch (field.id) {
6824
          case 1: // CEX
6825
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6826
              this.cex = new InventoryServiceException();
6827
              this.cex.read(iprot);
6828
            } else { 
6829
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6830
            }
6831
            break;
6832
          default:
6833
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6834
        }
6835
        iprot.readFieldEnd();
6836
      }
6837
      iprot.readStructEnd();
6838
      validate();
6839
    }
6840
 
6841
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
6842
      oprot.writeStructBegin(STRUCT_DESC);
6843
 
6844
      if (this.isSetCex()) {
6845
        oprot.writeFieldBegin(CEX_FIELD_DESC);
6846
        this.cex.write(oprot);
6847
        oprot.writeFieldEnd();
6848
      }
6849
      oprot.writeFieldStop();
6850
      oprot.writeStructEnd();
6851
    }
6852
 
6853
    @Override
6854
    public String toString() {
6855
      StringBuilder sb = new StringBuilder("addInventory_result(");
6856
      boolean first = true;
6857
 
6858
      sb.append("cex:");
6859
      if (this.cex == null) {
6860
        sb.append("null");
6861
      } else {
6862
        sb.append(this.cex);
6863
      }
6864
      first = false;
6865
      sb.append(")");
6866
      return sb.toString();
6867
    }
6868
 
6869
    public void validate() throws org.apache.thrift.TException {
6870
      // check for required fields
6871
    }
6872
 
6873
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6874
      try {
6875
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6876
      } catch (org.apache.thrift.TException te) {
6877
        throw new java.io.IOException(te);
6878
      }
6879
    }
6880
 
6881
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6882
      try {
6883
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6884
      } catch (org.apache.thrift.TException te) {
6885
        throw new java.io.IOException(te);
6886
      }
6887
    }
6888
 
6889
  }
6890
 
6891
  public static class retireWarehouse_args implements org.apache.thrift.TBase<retireWarehouse_args, retireWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
6892
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("retireWarehouse_args");
6893
 
6894
    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);
6895
 
6896
    private long warehouse_id; // required
6897
 
6898
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
6899
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
6900
      WAREHOUSE_ID((short)1, "warehouse_id");
6901
 
6902
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6903
 
6904
      static {
6905
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6906
          byName.put(field.getFieldName(), field);
6907
        }
6908
      }
6909
 
6910
      /**
6911
       * Find the _Fields constant that matches fieldId, or null if its not found.
6912
       */
6913
      public static _Fields findByThriftId(int fieldId) {
6914
        switch(fieldId) {
6915
          case 1: // WAREHOUSE_ID
6916
            return WAREHOUSE_ID;
6917
          default:
6918
            return null;
6919
        }
6920
      }
6921
 
6922
      /**
6923
       * Find the _Fields constant that matches fieldId, throwing an exception
6924
       * if it is not found.
6925
       */
6926
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6927
        _Fields fields = findByThriftId(fieldId);
6928
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6929
        return fields;
6930
      }
6931
 
6932
      /**
6933
       * Find the _Fields constant that matches name, or null if its not found.
6934
       */
6935
      public static _Fields findByName(String name) {
6936
        return byName.get(name);
6937
      }
6938
 
6939
      private final short _thriftId;
6940
      private final String _fieldName;
6941
 
6942
      _Fields(short thriftId, String fieldName) {
6943
        _thriftId = thriftId;
6944
        _fieldName = fieldName;
6945
      }
6946
 
6947
      public short getThriftFieldId() {
6948
        return _thriftId;
6949
      }
6950
 
6951
      public String getFieldName() {
6952
        return _fieldName;
6953
      }
6954
    }
6955
 
6956
    // isset id assignments
6957
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
6958
    private BitSet __isset_bit_vector = new BitSet(1);
6959
 
6960
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
6961
    static {
6962
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6963
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6964
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6965
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6966
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(retireWarehouse_args.class, metaDataMap);
6967
    }
6968
 
6969
    public retireWarehouse_args() {
6970
    }
6971
 
6972
    public retireWarehouse_args(
6973
      long warehouse_id)
6974
    {
6975
      this();
6976
      this.warehouse_id = warehouse_id;
6977
      setWarehouse_idIsSet(true);
6978
    }
6979
 
6980
    /**
6981
     * Performs a deep copy on <i>other</i>.
6982
     */
6983
    public retireWarehouse_args(retireWarehouse_args other) {
6984
      __isset_bit_vector.clear();
6985
      __isset_bit_vector.or(other.__isset_bit_vector);
6986
      this.warehouse_id = other.warehouse_id;
6987
    }
6988
 
6989
    public retireWarehouse_args deepCopy() {
6990
      return new retireWarehouse_args(this);
6991
    }
6992
 
6993
    @Override
6994
    public void clear() {
6995
      setWarehouse_idIsSet(false);
6996
      this.warehouse_id = 0;
6997
    }
6998
 
6999
    public long getWarehouse_id() {
7000
      return this.warehouse_id;
7001
    }
7002
 
7003
    public void setWarehouse_id(long warehouse_id) {
7004
      this.warehouse_id = warehouse_id;
7005
      setWarehouse_idIsSet(true);
7006
    }
7007
 
7008
    public void unsetWarehouse_id() {
7009
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
7010
    }
7011
 
7012
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
7013
    public boolean isSetWarehouse_id() {
7014
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
7015
    }
7016
 
7017
    public void setWarehouse_idIsSet(boolean value) {
7018
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
7019
    }
7020
 
7021
    public void setFieldValue(_Fields field, Object value) {
7022
      switch (field) {
7023
      case WAREHOUSE_ID:
7024
        if (value == null) {
7025
          unsetWarehouse_id();
7026
        } else {
7027
          setWarehouse_id((Long)value);
7028
        }
7029
        break;
7030
 
7031
      }
7032
    }
7033
 
7034
    public Object getFieldValue(_Fields field) {
7035
      switch (field) {
7036
      case WAREHOUSE_ID:
7037
        return Long.valueOf(getWarehouse_id());
7038
 
7039
      }
7040
      throw new IllegalStateException();
7041
    }
7042
 
7043
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7044
    public boolean isSet(_Fields field) {
7045
      if (field == null) {
7046
        throw new IllegalArgumentException();
7047
      }
7048
 
7049
      switch (field) {
7050
      case WAREHOUSE_ID:
7051
        return isSetWarehouse_id();
7052
      }
7053
      throw new IllegalStateException();
7054
    }
7055
 
7056
    @Override
7057
    public boolean equals(Object that) {
7058
      if (that == null)
7059
        return false;
7060
      if (that instanceof retireWarehouse_args)
7061
        return this.equals((retireWarehouse_args)that);
7062
      return false;
7063
    }
7064
 
7065
    public boolean equals(retireWarehouse_args that) {
7066
      if (that == null)
7067
        return false;
7068
 
7069
      boolean this_present_warehouse_id = true;
7070
      boolean that_present_warehouse_id = true;
7071
      if (this_present_warehouse_id || that_present_warehouse_id) {
7072
        if (!(this_present_warehouse_id && that_present_warehouse_id))
7073
          return false;
7074
        if (this.warehouse_id != that.warehouse_id)
7075
          return false;
7076
      }
7077
 
7078
      return true;
7079
    }
7080
 
7081
    @Override
7082
    public int hashCode() {
7083
      return 0;
7084
    }
7085
 
7086
    public int compareTo(retireWarehouse_args other) {
7087
      if (!getClass().equals(other.getClass())) {
7088
        return getClass().getName().compareTo(other.getClass().getName());
7089
      }
7090
 
7091
      int lastComparison = 0;
7092
      retireWarehouse_args typedOther = (retireWarehouse_args)other;
7093
 
7094
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
7095
      if (lastComparison != 0) {
7096
        return lastComparison;
7097
      }
7098
      if (isSetWarehouse_id()) {
7099
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
7100
        if (lastComparison != 0) {
7101
          return lastComparison;
7102
        }
7103
      }
7104
      return 0;
7105
    }
7106
 
7107
    public _Fields fieldForId(int fieldId) {
7108
      return _Fields.findByThriftId(fieldId);
7109
    }
7110
 
7111
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7112
      org.apache.thrift.protocol.TField field;
7113
      iprot.readStructBegin();
7114
      while (true)
7115
      {
7116
        field = iprot.readFieldBegin();
7117
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7118
          break;
7119
        }
7120
        switch (field.id) {
7121
          case 1: // WAREHOUSE_ID
7122
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7123
              this.warehouse_id = iprot.readI64();
7124
              setWarehouse_idIsSet(true);
7125
            } else { 
7126
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7127
            }
7128
            break;
7129
          default:
7130
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7131
        }
7132
        iprot.readFieldEnd();
7133
      }
7134
      iprot.readStructEnd();
7135
      validate();
7136
    }
7137
 
7138
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7139
      validate();
7140
 
7141
      oprot.writeStructBegin(STRUCT_DESC);
7142
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
7143
      oprot.writeI64(this.warehouse_id);
7144
      oprot.writeFieldEnd();
7145
      oprot.writeFieldStop();
7146
      oprot.writeStructEnd();
7147
    }
7148
 
7149
    @Override
7150
    public String toString() {
7151
      StringBuilder sb = new StringBuilder("retireWarehouse_args(");
7152
      boolean first = true;
7153
 
7154
      sb.append("warehouse_id:");
7155
      sb.append(this.warehouse_id);
7156
      first = false;
7157
      sb.append(")");
7158
      return sb.toString();
7159
    }
7160
 
7161
    public void validate() throws org.apache.thrift.TException {
7162
      // check for required fields
7163
    }
7164
 
7165
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7166
      try {
7167
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7168
      } catch (org.apache.thrift.TException te) {
7169
        throw new java.io.IOException(te);
7170
      }
7171
    }
7172
 
7173
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7174
      try {
7175
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7176
        __isset_bit_vector = new BitSet(1);
7177
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7178
      } catch (org.apache.thrift.TException te) {
7179
        throw new java.io.IOException(te);
7180
      }
7181
    }
7182
 
7183
  }
7184
 
7185
  public static class retireWarehouse_result implements org.apache.thrift.TBase<retireWarehouse_result, retireWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
7186
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("retireWarehouse_result");
7187
 
7188
    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);
7189
 
7190
    private InventoryServiceException cex; // required
7191
 
7192
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7193
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7194
      CEX((short)1, "cex");
7195
 
7196
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7197
 
7198
      static {
7199
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7200
          byName.put(field.getFieldName(), field);
7201
        }
7202
      }
7203
 
7204
      /**
7205
       * Find the _Fields constant that matches fieldId, or null if its not found.
7206
       */
7207
      public static _Fields findByThriftId(int fieldId) {
7208
        switch(fieldId) {
7209
          case 1: // CEX
7210
            return CEX;
7211
          default:
7212
            return null;
7213
        }
7214
      }
7215
 
7216
      /**
7217
       * Find the _Fields constant that matches fieldId, throwing an exception
7218
       * if it is not found.
7219
       */
7220
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7221
        _Fields fields = findByThriftId(fieldId);
7222
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7223
        return fields;
7224
      }
7225
 
7226
      /**
7227
       * Find the _Fields constant that matches name, or null if its not found.
7228
       */
7229
      public static _Fields findByName(String name) {
7230
        return byName.get(name);
7231
      }
7232
 
7233
      private final short _thriftId;
7234
      private final String _fieldName;
7235
 
7236
      _Fields(short thriftId, String fieldName) {
7237
        _thriftId = thriftId;
7238
        _fieldName = fieldName;
7239
      }
7240
 
7241
      public short getThriftFieldId() {
7242
        return _thriftId;
7243
      }
7244
 
7245
      public String getFieldName() {
7246
        return _fieldName;
7247
      }
7248
    }
7249
 
7250
    // isset id assignments
7251
 
7252
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7253
    static {
7254
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7255
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7256
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7257
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7258
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(retireWarehouse_result.class, metaDataMap);
7259
    }
7260
 
7261
    public retireWarehouse_result() {
7262
    }
7263
 
7264
    public retireWarehouse_result(
7265
      InventoryServiceException cex)
7266
    {
7267
      this();
7268
      this.cex = cex;
7269
    }
7270
 
7271
    /**
7272
     * Performs a deep copy on <i>other</i>.
7273
     */
7274
    public retireWarehouse_result(retireWarehouse_result other) {
7275
      if (other.isSetCex()) {
7276
        this.cex = new InventoryServiceException(other.cex);
7277
      }
7278
    }
7279
 
7280
    public retireWarehouse_result deepCopy() {
7281
      return new retireWarehouse_result(this);
7282
    }
7283
 
7284
    @Override
7285
    public void clear() {
7286
      this.cex = null;
7287
    }
7288
 
7289
    public InventoryServiceException getCex() {
7290
      return this.cex;
7291
    }
7292
 
7293
    public void setCex(InventoryServiceException cex) {
7294
      this.cex = cex;
7295
    }
7296
 
7297
    public void unsetCex() {
7298
      this.cex = null;
7299
    }
7300
 
7301
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
7302
    public boolean isSetCex() {
7303
      return this.cex != null;
7304
    }
7305
 
7306
    public void setCexIsSet(boolean value) {
7307
      if (!value) {
7308
        this.cex = null;
7309
      }
7310
    }
7311
 
7312
    public void setFieldValue(_Fields field, Object value) {
7313
      switch (field) {
7314
      case CEX:
7315
        if (value == null) {
7316
          unsetCex();
7317
        } else {
7318
          setCex((InventoryServiceException)value);
7319
        }
7320
        break;
7321
 
7322
      }
7323
    }
7324
 
7325
    public Object getFieldValue(_Fields field) {
7326
      switch (field) {
7327
      case CEX:
7328
        return getCex();
7329
 
7330
      }
7331
      throw new IllegalStateException();
7332
    }
7333
 
7334
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7335
    public boolean isSet(_Fields field) {
7336
      if (field == null) {
7337
        throw new IllegalArgumentException();
7338
      }
7339
 
7340
      switch (field) {
7341
      case CEX:
7342
        return isSetCex();
7343
      }
7344
      throw new IllegalStateException();
7345
    }
7346
 
7347
    @Override
7348
    public boolean equals(Object that) {
7349
      if (that == null)
7350
        return false;
7351
      if (that instanceof retireWarehouse_result)
7352
        return this.equals((retireWarehouse_result)that);
7353
      return false;
7354
    }
7355
 
7356
    public boolean equals(retireWarehouse_result that) {
7357
      if (that == null)
7358
        return false;
7359
 
7360
      boolean this_present_cex = true && this.isSetCex();
7361
      boolean that_present_cex = true && that.isSetCex();
7362
      if (this_present_cex || that_present_cex) {
7363
        if (!(this_present_cex && that_present_cex))
7364
          return false;
7365
        if (!this.cex.equals(that.cex))
7366
          return false;
7367
      }
7368
 
7369
      return true;
7370
    }
7371
 
7372
    @Override
7373
    public int hashCode() {
7374
      return 0;
7375
    }
7376
 
7377
    public int compareTo(retireWarehouse_result other) {
7378
      if (!getClass().equals(other.getClass())) {
7379
        return getClass().getName().compareTo(other.getClass().getName());
7380
      }
7381
 
7382
      int lastComparison = 0;
7383
      retireWarehouse_result typedOther = (retireWarehouse_result)other;
7384
 
7385
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
7386
      if (lastComparison != 0) {
7387
        return lastComparison;
7388
      }
7389
      if (isSetCex()) {
7390
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
7391
        if (lastComparison != 0) {
7392
          return lastComparison;
7393
        }
7394
      }
7395
      return 0;
7396
    }
7397
 
7398
    public _Fields fieldForId(int fieldId) {
7399
      return _Fields.findByThriftId(fieldId);
7400
    }
7401
 
7402
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7403
      org.apache.thrift.protocol.TField field;
7404
      iprot.readStructBegin();
7405
      while (true)
7406
      {
7407
        field = iprot.readFieldBegin();
7408
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7409
          break;
7410
        }
7411
        switch (field.id) {
7412
          case 1: // CEX
7413
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
7414
              this.cex = new InventoryServiceException();
7415
              this.cex.read(iprot);
7416
            } else { 
7417
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7418
            }
7419
            break;
7420
          default:
7421
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7422
        }
7423
        iprot.readFieldEnd();
7424
      }
7425
      iprot.readStructEnd();
7426
      validate();
7427
    }
7428
 
7429
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7430
      oprot.writeStructBegin(STRUCT_DESC);
7431
 
7432
      if (this.isSetCex()) {
7433
        oprot.writeFieldBegin(CEX_FIELD_DESC);
7434
        this.cex.write(oprot);
7435
        oprot.writeFieldEnd();
7436
      }
7437
      oprot.writeFieldStop();
7438
      oprot.writeStructEnd();
7439
    }
7440
 
7441
    @Override
7442
    public String toString() {
7443
      StringBuilder sb = new StringBuilder("retireWarehouse_result(");
7444
      boolean first = true;
7445
 
7446
      sb.append("cex:");
7447
      if (this.cex == null) {
7448
        sb.append("null");
7449
      } else {
7450
        sb.append(this.cex);
7451
      }
7452
      first = false;
7453
      sb.append(")");
7454
      return sb.toString();
7455
    }
7456
 
7457
    public void validate() throws org.apache.thrift.TException {
7458
      // check for required fields
7459
    }
7460
 
7461
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7462
      try {
7463
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7464
      } catch (org.apache.thrift.TException te) {
7465
        throw new java.io.IOException(te);
7466
      }
7467
    }
7468
 
7469
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7470
      try {
7471
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7472
      } catch (org.apache.thrift.TException te) {
7473
        throw new java.io.IOException(te);
7474
      }
7475
    }
7476
 
7477
  }
7478
 
7479
  public static class getItemInventoryByItemId_args implements org.apache.thrift.TBase<getItemInventoryByItemId_args, getItemInventoryByItemId_args._Fields>, java.io.Serializable, Cloneable   {
7480
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemInventoryByItemId_args");
7481
 
7482
    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);
7483
 
7484
    private long item_id; // required
7485
 
7486
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7487
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7488
      ITEM_ID((short)1, "item_id");
7489
 
7490
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7491
 
7492
      static {
7493
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7494
          byName.put(field.getFieldName(), field);
7495
        }
7496
      }
7497
 
7498
      /**
7499
       * Find the _Fields constant that matches fieldId, or null if its not found.
7500
       */
7501
      public static _Fields findByThriftId(int fieldId) {
7502
        switch(fieldId) {
7503
          case 1: // ITEM_ID
7504
            return ITEM_ID;
7505
          default:
7506
            return null;
7507
        }
7508
      }
7509
 
7510
      /**
7511
       * Find the _Fields constant that matches fieldId, throwing an exception
7512
       * if it is not found.
7513
       */
7514
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7515
        _Fields fields = findByThriftId(fieldId);
7516
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7517
        return fields;
7518
      }
7519
 
7520
      /**
7521
       * Find the _Fields constant that matches name, or null if its not found.
7522
       */
7523
      public static _Fields findByName(String name) {
7524
        return byName.get(name);
7525
      }
7526
 
7527
      private final short _thriftId;
7528
      private final String _fieldName;
7529
 
7530
      _Fields(short thriftId, String fieldName) {
7531
        _thriftId = thriftId;
7532
        _fieldName = fieldName;
7533
      }
7534
 
7535
      public short getThriftFieldId() {
7536
        return _thriftId;
7537
      }
7538
 
7539
      public String getFieldName() {
7540
        return _fieldName;
7541
      }
7542
    }
7543
 
7544
    // isset id assignments
7545
    private static final int __ITEM_ID_ISSET_ID = 0;
7546
    private BitSet __isset_bit_vector = new BitSet(1);
7547
 
7548
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7549
    static {
7550
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7551
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7552
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7553
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7554
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemInventoryByItemId_args.class, metaDataMap);
7555
    }
7556
 
7557
    public getItemInventoryByItemId_args() {
7558
    }
7559
 
7560
    public getItemInventoryByItemId_args(
7561
      long item_id)
7562
    {
7563
      this();
7564
      this.item_id = item_id;
7565
      setItem_idIsSet(true);
7566
    }
7567
 
7568
    /**
7569
     * Performs a deep copy on <i>other</i>.
7570
     */
7571
    public getItemInventoryByItemId_args(getItemInventoryByItemId_args other) {
7572
      __isset_bit_vector.clear();
7573
      __isset_bit_vector.or(other.__isset_bit_vector);
7574
      this.item_id = other.item_id;
7575
    }
7576
 
7577
    public getItemInventoryByItemId_args deepCopy() {
7578
      return new getItemInventoryByItemId_args(this);
7579
    }
7580
 
7581
    @Override
7582
    public void clear() {
7583
      setItem_idIsSet(false);
7584
      this.item_id = 0;
7585
    }
7586
 
7587
    public long getItem_id() {
7588
      return this.item_id;
7589
    }
7590
 
7591
    public void setItem_id(long item_id) {
7592
      this.item_id = item_id;
7593
      setItem_idIsSet(true);
7594
    }
7595
 
7596
    public void unsetItem_id() {
7597
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
7598
    }
7599
 
7600
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
7601
    public boolean isSetItem_id() {
7602
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
7603
    }
7604
 
7605
    public void setItem_idIsSet(boolean value) {
7606
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
7607
    }
7608
 
7609
    public void setFieldValue(_Fields field, Object value) {
7610
      switch (field) {
7611
      case ITEM_ID:
7612
        if (value == null) {
7613
          unsetItem_id();
7614
        } else {
7615
          setItem_id((Long)value);
7616
        }
7617
        break;
7618
 
7619
      }
7620
    }
7621
 
7622
    public Object getFieldValue(_Fields field) {
7623
      switch (field) {
7624
      case ITEM_ID:
7625
        return Long.valueOf(getItem_id());
7626
 
7627
      }
7628
      throw new IllegalStateException();
7629
    }
7630
 
7631
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7632
    public boolean isSet(_Fields field) {
7633
      if (field == null) {
7634
        throw new IllegalArgumentException();
7635
      }
7636
 
7637
      switch (field) {
7638
      case ITEM_ID:
7639
        return isSetItem_id();
7640
      }
7641
      throw new IllegalStateException();
7642
    }
7643
 
7644
    @Override
7645
    public boolean equals(Object that) {
7646
      if (that == null)
7647
        return false;
7648
      if (that instanceof getItemInventoryByItemId_args)
7649
        return this.equals((getItemInventoryByItemId_args)that);
7650
      return false;
7651
    }
7652
 
7653
    public boolean equals(getItemInventoryByItemId_args that) {
7654
      if (that == null)
7655
        return false;
7656
 
7657
      boolean this_present_item_id = true;
7658
      boolean that_present_item_id = true;
7659
      if (this_present_item_id || that_present_item_id) {
7660
        if (!(this_present_item_id && that_present_item_id))
7661
          return false;
7662
        if (this.item_id != that.item_id)
7663
          return false;
7664
      }
7665
 
7666
      return true;
7667
    }
7668
 
7669
    @Override
7670
    public int hashCode() {
7671
      return 0;
7672
    }
7673
 
7674
    public int compareTo(getItemInventoryByItemId_args other) {
7675
      if (!getClass().equals(other.getClass())) {
7676
        return getClass().getName().compareTo(other.getClass().getName());
7677
      }
7678
 
7679
      int lastComparison = 0;
7680
      getItemInventoryByItemId_args typedOther = (getItemInventoryByItemId_args)other;
7681
 
7682
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
7683
      if (lastComparison != 0) {
7684
        return lastComparison;
7685
      }
7686
      if (isSetItem_id()) {
7687
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
7688
        if (lastComparison != 0) {
7689
          return lastComparison;
7690
        }
7691
      }
7692
      return 0;
7693
    }
7694
 
7695
    public _Fields fieldForId(int fieldId) {
7696
      return _Fields.findByThriftId(fieldId);
7697
    }
7698
 
7699
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7700
      org.apache.thrift.protocol.TField field;
7701
      iprot.readStructBegin();
7702
      while (true)
7703
      {
7704
        field = iprot.readFieldBegin();
7705
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
7706
          break;
7707
        }
7708
        switch (field.id) {
7709
          case 1: // ITEM_ID
7710
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7711
              this.item_id = iprot.readI64();
7712
              setItem_idIsSet(true);
7713
            } else { 
7714
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7715
            }
7716
            break;
7717
          default:
7718
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7719
        }
7720
        iprot.readFieldEnd();
7721
      }
7722
      iprot.readStructEnd();
7723
      validate();
7724
    }
7725
 
7726
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
7727
      validate();
7728
 
7729
      oprot.writeStructBegin(STRUCT_DESC);
7730
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
7731
      oprot.writeI64(this.item_id);
7732
      oprot.writeFieldEnd();
7733
      oprot.writeFieldStop();
7734
      oprot.writeStructEnd();
7735
    }
7736
 
7737
    @Override
7738
    public String toString() {
7739
      StringBuilder sb = new StringBuilder("getItemInventoryByItemId_args(");
7740
      boolean first = true;
7741
 
7742
      sb.append("item_id:");
7743
      sb.append(this.item_id);
7744
      first = false;
7745
      sb.append(")");
7746
      return sb.toString();
7747
    }
7748
 
7749
    public void validate() throws org.apache.thrift.TException {
7750
      // check for required fields
7751
    }
7752
 
7753
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7754
      try {
7755
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7756
      } catch (org.apache.thrift.TException te) {
7757
        throw new java.io.IOException(te);
7758
      }
7759
    }
7760
 
7761
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7762
      try {
7763
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7764
        __isset_bit_vector = new BitSet(1);
7765
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7766
      } catch (org.apache.thrift.TException te) {
7767
        throw new java.io.IOException(te);
7768
      }
7769
    }
7770
 
7771
  }
7772
 
7773
  public static class getItemInventoryByItemId_result implements org.apache.thrift.TBase<getItemInventoryByItemId_result, getItemInventoryByItemId_result._Fields>, java.io.Serializable, Cloneable   {
7774
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemInventoryByItemId_result");
7775
 
7776
    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);
7777
    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);
7778
 
7779
    private ItemInventory success; // required
7780
    private InventoryServiceException cex; // required
7781
 
7782
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7783
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7784
      SUCCESS((short)0, "success"),
7785
      CEX((short)1, "cex");
7786
 
7787
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7788
 
7789
      static {
7790
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7791
          byName.put(field.getFieldName(), field);
7792
        }
7793
      }
7794
 
7795
      /**
7796
       * Find the _Fields constant that matches fieldId, or null if its not found.
7797
       */
7798
      public static _Fields findByThriftId(int fieldId) {
7799
        switch(fieldId) {
7800
          case 0: // SUCCESS
7801
            return SUCCESS;
7802
          case 1: // CEX
7803
            return CEX;
7804
          default:
7805
            return null;
7806
        }
7807
      }
7808
 
7809
      /**
7810
       * Find the _Fields constant that matches fieldId, throwing an exception
7811
       * if it is not found.
7812
       */
7813
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7814
        _Fields fields = findByThriftId(fieldId);
7815
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7816
        return fields;
7817
      }
7818
 
7819
      /**
7820
       * Find the _Fields constant that matches name, or null if its not found.
7821
       */
7822
      public static _Fields findByName(String name) {
7823
        return byName.get(name);
7824
      }
7825
 
7826
      private final short _thriftId;
7827
      private final String _fieldName;
7828
 
7829
      _Fields(short thriftId, String fieldName) {
7830
        _thriftId = thriftId;
7831
        _fieldName = fieldName;
7832
      }
7833
 
7834
      public short getThriftFieldId() {
7835
        return _thriftId;
7836
      }
7837
 
7838
      public String getFieldName() {
7839
        return _fieldName;
7840
      }
7841
    }
7842
 
7843
    // isset id assignments
7844
 
7845
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7846
    static {
7847
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7848
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7849
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ItemInventory.class)));
7850
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7851
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
7852
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7853
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemInventoryByItemId_result.class, metaDataMap);
7854
    }
7855
 
7856
    public getItemInventoryByItemId_result() {
7857
    }
7858
 
7859
    public getItemInventoryByItemId_result(
7860
      ItemInventory success,
7861
      InventoryServiceException cex)
7862
    {
7863
      this();
7864
      this.success = success;
7865
      this.cex = cex;
7866
    }
7867
 
7868
    /**
7869
     * Performs a deep copy on <i>other</i>.
7870
     */
7871
    public getItemInventoryByItemId_result(getItemInventoryByItemId_result other) {
7872
      if (other.isSetSuccess()) {
7873
        this.success = new ItemInventory(other.success);
7874
      }
7875
      if (other.isSetCex()) {
7876
        this.cex = new InventoryServiceException(other.cex);
7877
      }
7878
    }
7879
 
7880
    public getItemInventoryByItemId_result deepCopy() {
7881
      return new getItemInventoryByItemId_result(this);
7882
    }
7883
 
7884
    @Override
7885
    public void clear() {
7886
      this.success = null;
7887
      this.cex = null;
7888
    }
7889
 
7890
    public ItemInventory getSuccess() {
7891
      return this.success;
7892
    }
7893
 
7894
    public void setSuccess(ItemInventory success) {
7895
      this.success = success;
7896
    }
7897
 
7898
    public void unsetSuccess() {
7899
      this.success = null;
7900
    }
7901
 
7902
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
7903
    public boolean isSetSuccess() {
7904
      return this.success != null;
7905
    }
7906
 
7907
    public void setSuccessIsSet(boolean value) {
7908
      if (!value) {
7909
        this.success = null;
7910
      }
7911
    }
7912
 
7913
    public InventoryServiceException getCex() {
7914
      return this.cex;
7915
    }
7916
 
7917
    public void setCex(InventoryServiceException cex) {
7918
      this.cex = cex;
7919
    }
7920
 
7921
    public void unsetCex() {
7922
      this.cex = null;
7923
    }
7924
 
7925
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
7926
    public boolean isSetCex() {
7927
      return this.cex != null;
7928
    }
7929
 
7930
    public void setCexIsSet(boolean value) {
7931
      if (!value) {
7932
        this.cex = null;
7933
      }
7934
    }
7935
 
7936
    public void setFieldValue(_Fields field, Object value) {
7937
      switch (field) {
7938
      case SUCCESS:
7939
        if (value == null) {
7940
          unsetSuccess();
7941
        } else {
7942
          setSuccess((ItemInventory)value);
7943
        }
7944
        break;
7945
 
7946
      case CEX:
7947
        if (value == null) {
7948
          unsetCex();
7949
        } else {
7950
          setCex((InventoryServiceException)value);
7951
        }
7952
        break;
7953
 
7954
      }
7955
    }
7956
 
7957
    public Object getFieldValue(_Fields field) {
7958
      switch (field) {
7959
      case SUCCESS:
7960
        return getSuccess();
7961
 
7962
      case CEX:
7963
        return getCex();
7964
 
7965
      }
7966
      throw new IllegalStateException();
7967
    }
7968
 
7969
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7970
    public boolean isSet(_Fields field) {
7971
      if (field == null) {
7972
        throw new IllegalArgumentException();
7973
      }
7974
 
7975
      switch (field) {
7976
      case SUCCESS:
7977
        return isSetSuccess();
7978
      case CEX:
7979
        return isSetCex();
7980
      }
7981
      throw new IllegalStateException();
7982
    }
7983
 
7984
    @Override
7985
    public boolean equals(Object that) {
7986
      if (that == null)
7987
        return false;
7988
      if (that instanceof getItemInventoryByItemId_result)
7989
        return this.equals((getItemInventoryByItemId_result)that);
7990
      return false;
7991
    }
7992
 
7993
    public boolean equals(getItemInventoryByItemId_result that) {
7994
      if (that == null)
7995
        return false;
7996
 
7997
      boolean this_present_success = true && this.isSetSuccess();
7998
      boolean that_present_success = true && that.isSetSuccess();
7999
      if (this_present_success || that_present_success) {
8000
        if (!(this_present_success && that_present_success))
8001
          return false;
8002
        if (!this.success.equals(that.success))
8003
          return false;
8004
      }
8005
 
8006
      boolean this_present_cex = true && this.isSetCex();
8007
      boolean that_present_cex = true && that.isSetCex();
8008
      if (this_present_cex || that_present_cex) {
8009
        if (!(this_present_cex && that_present_cex))
8010
          return false;
8011
        if (!this.cex.equals(that.cex))
8012
          return false;
8013
      }
8014
 
8015
      return true;
8016
    }
8017
 
8018
    @Override
8019
    public int hashCode() {
8020
      return 0;
8021
    }
8022
 
8023
    public int compareTo(getItemInventoryByItemId_result other) {
8024
      if (!getClass().equals(other.getClass())) {
8025
        return getClass().getName().compareTo(other.getClass().getName());
8026
      }
8027
 
8028
      int lastComparison = 0;
8029
      getItemInventoryByItemId_result typedOther = (getItemInventoryByItemId_result)other;
8030
 
8031
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
8032
      if (lastComparison != 0) {
8033
        return lastComparison;
8034
      }
8035
      if (isSetSuccess()) {
8036
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8037
        if (lastComparison != 0) {
8038
          return lastComparison;
8039
        }
8040
      }
8041
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
8042
      if (lastComparison != 0) {
8043
        return lastComparison;
8044
      }
8045
      if (isSetCex()) {
8046
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
8047
        if (lastComparison != 0) {
8048
          return lastComparison;
8049
        }
8050
      }
8051
      return 0;
8052
    }
8053
 
8054
    public _Fields fieldForId(int fieldId) {
8055
      return _Fields.findByThriftId(fieldId);
8056
    }
8057
 
8058
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8059
      org.apache.thrift.protocol.TField field;
8060
      iprot.readStructBegin();
8061
      while (true)
8062
      {
8063
        field = iprot.readFieldBegin();
8064
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8065
          break;
8066
        }
8067
        switch (field.id) {
8068
          case 0: // SUCCESS
8069
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8070
              this.success = new ItemInventory();
8071
              this.success.read(iprot);
8072
            } else { 
8073
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8074
            }
8075
            break;
8076
          case 1: // CEX
8077
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8078
              this.cex = new InventoryServiceException();
8079
              this.cex.read(iprot);
8080
            } else { 
8081
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8082
            }
8083
            break;
8084
          default:
8085
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8086
        }
8087
        iprot.readFieldEnd();
8088
      }
8089
      iprot.readStructEnd();
8090
      validate();
8091
    }
8092
 
8093
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8094
      oprot.writeStructBegin(STRUCT_DESC);
8095
 
8096
      if (this.isSetSuccess()) {
8097
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8098
        this.success.write(oprot);
8099
        oprot.writeFieldEnd();
8100
      } else if (this.isSetCex()) {
8101
        oprot.writeFieldBegin(CEX_FIELD_DESC);
8102
        this.cex.write(oprot);
8103
        oprot.writeFieldEnd();
8104
      }
8105
      oprot.writeFieldStop();
8106
      oprot.writeStructEnd();
8107
    }
8108
 
8109
    @Override
8110
    public String toString() {
8111
      StringBuilder sb = new StringBuilder("getItemInventoryByItemId_result(");
8112
      boolean first = true;
8113
 
8114
      sb.append("success:");
8115
      if (this.success == null) {
8116
        sb.append("null");
8117
      } else {
8118
        sb.append(this.success);
8119
      }
8120
      first = false;
8121
      if (!first) sb.append(", ");
8122
      sb.append("cex:");
8123
      if (this.cex == null) {
8124
        sb.append("null");
8125
      } else {
8126
        sb.append(this.cex);
8127
      }
8128
      first = false;
8129
      sb.append(")");
8130
      return sb.toString();
8131
    }
8132
 
8133
    public void validate() throws org.apache.thrift.TException {
8134
      // check for required fields
8135
    }
8136
 
8137
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8138
      try {
8139
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8140
      } catch (org.apache.thrift.TException te) {
8141
        throw new java.io.IOException(te);
8142
      }
8143
    }
8144
 
8145
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8146
      try {
8147
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8148
      } catch (org.apache.thrift.TException te) {
8149
        throw new java.io.IOException(te);
8150
      }
8151
    }
8152
 
8153
  }
8154
 
8155
  public static class getItemAvailibilityAtWarehouse_args implements org.apache.thrift.TBase<getItemAvailibilityAtWarehouse_args, getItemAvailibilityAtWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
8156
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailibilityAtWarehouse_args");
8157
 
8158
    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);
8159
    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);
8160
 
8161
    private long warehouse_id; // required
8162
    private long item_id; // required
8163
 
8164
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8165
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8166
      WAREHOUSE_ID((short)1, "warehouse_id"),
8167
      ITEM_ID((short)2, "item_id");
8168
 
8169
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8170
 
8171
      static {
8172
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8173
          byName.put(field.getFieldName(), field);
8174
        }
8175
      }
8176
 
8177
      /**
8178
       * Find the _Fields constant that matches fieldId, or null if its not found.
8179
       */
8180
      public static _Fields findByThriftId(int fieldId) {
8181
        switch(fieldId) {
8182
          case 1: // WAREHOUSE_ID
8183
            return WAREHOUSE_ID;
8184
          case 2: // ITEM_ID
8185
            return ITEM_ID;
8186
          default:
8187
            return null;
8188
        }
8189
      }
8190
 
8191
      /**
8192
       * Find the _Fields constant that matches fieldId, throwing an exception
8193
       * if it is not found.
8194
       */
8195
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8196
        _Fields fields = findByThriftId(fieldId);
8197
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8198
        return fields;
8199
      }
8200
 
8201
      /**
8202
       * Find the _Fields constant that matches name, or null if its not found.
8203
       */
8204
      public static _Fields findByName(String name) {
8205
        return byName.get(name);
8206
      }
8207
 
8208
      private final short _thriftId;
8209
      private final String _fieldName;
8210
 
8211
      _Fields(short thriftId, String fieldName) {
8212
        _thriftId = thriftId;
8213
        _fieldName = fieldName;
8214
      }
8215
 
8216
      public short getThriftFieldId() {
8217
        return _thriftId;
8218
      }
8219
 
8220
      public String getFieldName() {
8221
        return _fieldName;
8222
      }
8223
    }
8224
 
8225
    // isset id assignments
8226
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
8227
    private static final int __ITEM_ID_ISSET_ID = 1;
8228
    private BitSet __isset_bit_vector = new BitSet(2);
8229
 
8230
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8231
    static {
8232
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8233
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8234
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8235
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8236
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8237
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8238
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailibilityAtWarehouse_args.class, metaDataMap);
8239
    }
8240
 
8241
    public getItemAvailibilityAtWarehouse_args() {
8242
    }
8243
 
8244
    public getItemAvailibilityAtWarehouse_args(
8245
      long warehouse_id,
8246
      long item_id)
8247
    {
8248
      this();
8249
      this.warehouse_id = warehouse_id;
8250
      setWarehouse_idIsSet(true);
8251
      this.item_id = item_id;
8252
      setItem_idIsSet(true);
8253
    }
8254
 
8255
    /**
8256
     * Performs a deep copy on <i>other</i>.
8257
     */
8258
    public getItemAvailibilityAtWarehouse_args(getItemAvailibilityAtWarehouse_args other) {
8259
      __isset_bit_vector.clear();
8260
      __isset_bit_vector.or(other.__isset_bit_vector);
8261
      this.warehouse_id = other.warehouse_id;
8262
      this.item_id = other.item_id;
8263
    }
8264
 
8265
    public getItemAvailibilityAtWarehouse_args deepCopy() {
8266
      return new getItemAvailibilityAtWarehouse_args(this);
8267
    }
8268
 
8269
    @Override
8270
    public void clear() {
8271
      setWarehouse_idIsSet(false);
8272
      this.warehouse_id = 0;
8273
      setItem_idIsSet(false);
8274
      this.item_id = 0;
8275
    }
8276
 
8277
    public long getWarehouse_id() {
8278
      return this.warehouse_id;
8279
    }
8280
 
8281
    public void setWarehouse_id(long warehouse_id) {
8282
      this.warehouse_id = warehouse_id;
8283
      setWarehouse_idIsSet(true);
8284
    }
8285
 
8286
    public void unsetWarehouse_id() {
8287
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
8288
    }
8289
 
8290
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
8291
    public boolean isSetWarehouse_id() {
8292
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
8293
    }
8294
 
8295
    public void setWarehouse_idIsSet(boolean value) {
8296
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
8297
    }
8298
 
8299
    public long getItem_id() {
8300
      return this.item_id;
8301
    }
8302
 
8303
    public void setItem_id(long item_id) {
8304
      this.item_id = item_id;
8305
      setItem_idIsSet(true);
8306
    }
8307
 
8308
    public void unsetItem_id() {
8309
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
8310
    }
8311
 
8312
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
8313
    public boolean isSetItem_id() {
8314
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
8315
    }
8316
 
8317
    public void setItem_idIsSet(boolean value) {
8318
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
8319
    }
8320
 
8321
    public void setFieldValue(_Fields field, Object value) {
8322
      switch (field) {
8323
      case WAREHOUSE_ID:
8324
        if (value == null) {
8325
          unsetWarehouse_id();
8326
        } else {
8327
          setWarehouse_id((Long)value);
8328
        }
8329
        break;
8330
 
8331
      case ITEM_ID:
8332
        if (value == null) {
8333
          unsetItem_id();
8334
        } else {
8335
          setItem_id((Long)value);
8336
        }
8337
        break;
8338
 
8339
      }
8340
    }
8341
 
8342
    public Object getFieldValue(_Fields field) {
8343
      switch (field) {
8344
      case WAREHOUSE_ID:
8345
        return Long.valueOf(getWarehouse_id());
8346
 
8347
      case ITEM_ID:
8348
        return Long.valueOf(getItem_id());
8349
 
8350
      }
8351
      throw new IllegalStateException();
8352
    }
8353
 
8354
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8355
    public boolean isSet(_Fields field) {
8356
      if (field == null) {
8357
        throw new IllegalArgumentException();
8358
      }
8359
 
8360
      switch (field) {
8361
      case WAREHOUSE_ID:
8362
        return isSetWarehouse_id();
8363
      case ITEM_ID:
8364
        return isSetItem_id();
8365
      }
8366
      throw new IllegalStateException();
8367
    }
8368
 
8369
    @Override
8370
    public boolean equals(Object that) {
8371
      if (that == null)
8372
        return false;
8373
      if (that instanceof getItemAvailibilityAtWarehouse_args)
8374
        return this.equals((getItemAvailibilityAtWarehouse_args)that);
8375
      return false;
8376
    }
8377
 
8378
    public boolean equals(getItemAvailibilityAtWarehouse_args that) {
8379
      if (that == null)
8380
        return false;
8381
 
8382
      boolean this_present_warehouse_id = true;
8383
      boolean that_present_warehouse_id = true;
8384
      if (this_present_warehouse_id || that_present_warehouse_id) {
8385
        if (!(this_present_warehouse_id && that_present_warehouse_id))
8386
          return false;
8387
        if (this.warehouse_id != that.warehouse_id)
8388
          return false;
8389
      }
8390
 
8391
      boolean this_present_item_id = true;
8392
      boolean that_present_item_id = true;
8393
      if (this_present_item_id || that_present_item_id) {
8394
        if (!(this_present_item_id && that_present_item_id))
8395
          return false;
8396
        if (this.item_id != that.item_id)
8397
          return false;
8398
      }
8399
 
8400
      return true;
8401
    }
8402
 
8403
    @Override
8404
    public int hashCode() {
8405
      return 0;
8406
    }
8407
 
8408
    public int compareTo(getItemAvailibilityAtWarehouse_args other) {
8409
      if (!getClass().equals(other.getClass())) {
8410
        return getClass().getName().compareTo(other.getClass().getName());
8411
      }
8412
 
8413
      int lastComparison = 0;
8414
      getItemAvailibilityAtWarehouse_args typedOther = (getItemAvailibilityAtWarehouse_args)other;
8415
 
8416
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
8417
      if (lastComparison != 0) {
8418
        return lastComparison;
8419
      }
8420
      if (isSetWarehouse_id()) {
8421
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
8422
        if (lastComparison != 0) {
8423
          return lastComparison;
8424
        }
8425
      }
8426
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
8427
      if (lastComparison != 0) {
8428
        return lastComparison;
8429
      }
8430
      if (isSetItem_id()) {
8431
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
8432
        if (lastComparison != 0) {
8433
          return lastComparison;
8434
        }
8435
      }
8436
      return 0;
8437
    }
8438
 
8439
    public _Fields fieldForId(int fieldId) {
8440
      return _Fields.findByThriftId(fieldId);
8441
    }
8442
 
8443
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8444
      org.apache.thrift.protocol.TField field;
8445
      iprot.readStructBegin();
8446
      while (true)
8447
      {
8448
        field = iprot.readFieldBegin();
8449
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8450
          break;
8451
        }
8452
        switch (field.id) {
8453
          case 1: // WAREHOUSE_ID
8454
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8455
              this.warehouse_id = iprot.readI64();
8456
              setWarehouse_idIsSet(true);
8457
            } else { 
8458
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8459
            }
8460
            break;
8461
          case 2: // ITEM_ID
8462
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8463
              this.item_id = iprot.readI64();
8464
              setItem_idIsSet(true);
8465
            } else { 
8466
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8467
            }
8468
            break;
8469
          default:
8470
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8471
        }
8472
        iprot.readFieldEnd();
8473
      }
8474
      iprot.readStructEnd();
8475
      validate();
8476
    }
8477
 
8478
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8479
      validate();
8480
 
8481
      oprot.writeStructBegin(STRUCT_DESC);
8482
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
8483
      oprot.writeI64(this.warehouse_id);
8484
      oprot.writeFieldEnd();
8485
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
8486
      oprot.writeI64(this.item_id);
8487
      oprot.writeFieldEnd();
8488
      oprot.writeFieldStop();
8489
      oprot.writeStructEnd();
8490
    }
8491
 
8492
    @Override
8493
    public String toString() {
8494
      StringBuilder sb = new StringBuilder("getItemAvailibilityAtWarehouse_args(");
8495
      boolean first = true;
8496
 
8497
      sb.append("warehouse_id:");
8498
      sb.append(this.warehouse_id);
8499
      first = false;
8500
      if (!first) sb.append(", ");
8501
      sb.append("item_id:");
8502
      sb.append(this.item_id);
8503
      first = false;
8504
      sb.append(")");
8505
      return sb.toString();
8506
    }
8507
 
8508
    public void validate() throws org.apache.thrift.TException {
8509
      // check for required fields
8510
    }
8511
 
8512
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8513
      try {
8514
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8515
      } catch (org.apache.thrift.TException te) {
8516
        throw new java.io.IOException(te);
8517
      }
8518
    }
8519
 
8520
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8521
      try {
8522
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
8523
        __isset_bit_vector = new BitSet(1);
8524
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8525
      } catch (org.apache.thrift.TException te) {
8526
        throw new java.io.IOException(te);
8527
      }
8528
    }
8529
 
8530
  }
8531
 
8532
  public static class getItemAvailibilityAtWarehouse_result implements org.apache.thrift.TBase<getItemAvailibilityAtWarehouse_result, getItemAvailibilityAtWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
8533
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailibilityAtWarehouse_result");
8534
 
8535
    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);
8536
    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);
8537
 
8538
    private long success; // required
8539
    private InventoryServiceException cex; // required
8540
 
8541
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8542
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8543
      SUCCESS((short)0, "success"),
8544
      CEX((short)1, "cex");
8545
 
8546
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8547
 
8548
      static {
8549
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8550
          byName.put(field.getFieldName(), field);
8551
        }
8552
      }
8553
 
8554
      /**
8555
       * Find the _Fields constant that matches fieldId, or null if its not found.
8556
       */
8557
      public static _Fields findByThriftId(int fieldId) {
8558
        switch(fieldId) {
8559
          case 0: // SUCCESS
8560
            return SUCCESS;
8561
          case 1: // CEX
8562
            return CEX;
8563
          default:
8564
            return null;
8565
        }
8566
      }
8567
 
8568
      /**
8569
       * Find the _Fields constant that matches fieldId, throwing an exception
8570
       * if it is not found.
8571
       */
8572
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8573
        _Fields fields = findByThriftId(fieldId);
8574
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8575
        return fields;
8576
      }
8577
 
8578
      /**
8579
       * Find the _Fields constant that matches name, or null if its not found.
8580
       */
8581
      public static _Fields findByName(String name) {
8582
        return byName.get(name);
8583
      }
8584
 
8585
      private final short _thriftId;
8586
      private final String _fieldName;
8587
 
8588
      _Fields(short thriftId, String fieldName) {
8589
        _thriftId = thriftId;
8590
        _fieldName = fieldName;
8591
      }
8592
 
8593
      public short getThriftFieldId() {
8594
        return _thriftId;
8595
      }
8596
 
8597
      public String getFieldName() {
8598
        return _fieldName;
8599
      }
8600
    }
8601
 
8602
    // isset id assignments
8603
    private static final int __SUCCESS_ISSET_ID = 0;
8604
    private BitSet __isset_bit_vector = new BitSet(1);
8605
 
8606
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8607
    static {
8608
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8609
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8610
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8611
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8612
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
8613
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8614
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailibilityAtWarehouse_result.class, metaDataMap);
8615
    }
8616
 
8617
    public getItemAvailibilityAtWarehouse_result() {
8618
    }
8619
 
8620
    public getItemAvailibilityAtWarehouse_result(
8621
      long success,
8622
      InventoryServiceException cex)
8623
    {
8624
      this();
8625
      this.success = success;
8626
      setSuccessIsSet(true);
8627
      this.cex = cex;
8628
    }
8629
 
8630
    /**
8631
     * Performs a deep copy on <i>other</i>.
8632
     */
8633
    public getItemAvailibilityAtWarehouse_result(getItemAvailibilityAtWarehouse_result other) {
8634
      __isset_bit_vector.clear();
8635
      __isset_bit_vector.or(other.__isset_bit_vector);
8636
      this.success = other.success;
8637
      if (other.isSetCex()) {
8638
        this.cex = new InventoryServiceException(other.cex);
8639
      }
8640
    }
8641
 
8642
    public getItemAvailibilityAtWarehouse_result deepCopy() {
8643
      return new getItemAvailibilityAtWarehouse_result(this);
8644
    }
8645
 
8646
    @Override
8647
    public void clear() {
8648
      setSuccessIsSet(false);
8649
      this.success = 0;
8650
      this.cex = null;
8651
    }
8652
 
8653
    public long getSuccess() {
8654
      return this.success;
8655
    }
8656
 
8657
    public void setSuccess(long success) {
8658
      this.success = success;
8659
      setSuccessIsSet(true);
8660
    }
8661
 
8662
    public void unsetSuccess() {
8663
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
8664
    }
8665
 
8666
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
8667
    public boolean isSetSuccess() {
8668
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
8669
    }
8670
 
8671
    public void setSuccessIsSet(boolean value) {
8672
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
8673
    }
8674
 
8675
    public InventoryServiceException getCex() {
8676
      return this.cex;
8677
    }
8678
 
8679
    public void setCex(InventoryServiceException cex) {
8680
      this.cex = cex;
8681
    }
8682
 
8683
    public void unsetCex() {
8684
      this.cex = null;
8685
    }
8686
 
8687
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
8688
    public boolean isSetCex() {
8689
      return this.cex != null;
8690
    }
8691
 
8692
    public void setCexIsSet(boolean value) {
8693
      if (!value) {
8694
        this.cex = null;
8695
      }
8696
    }
8697
 
8698
    public void setFieldValue(_Fields field, Object value) {
8699
      switch (field) {
8700
      case SUCCESS:
8701
        if (value == null) {
8702
          unsetSuccess();
8703
        } else {
8704
          setSuccess((Long)value);
8705
        }
8706
        break;
8707
 
8708
      case CEX:
8709
        if (value == null) {
8710
          unsetCex();
8711
        } else {
8712
          setCex((InventoryServiceException)value);
8713
        }
8714
        break;
8715
 
8716
      }
8717
    }
8718
 
8719
    public Object getFieldValue(_Fields field) {
8720
      switch (field) {
8721
      case SUCCESS:
8722
        return Long.valueOf(getSuccess());
8723
 
8724
      case CEX:
8725
        return getCex();
8726
 
8727
      }
8728
      throw new IllegalStateException();
8729
    }
8730
 
8731
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8732
    public boolean isSet(_Fields field) {
8733
      if (field == null) {
8734
        throw new IllegalArgumentException();
8735
      }
8736
 
8737
      switch (field) {
8738
      case SUCCESS:
8739
        return isSetSuccess();
8740
      case CEX:
8741
        return isSetCex();
8742
      }
8743
      throw new IllegalStateException();
8744
    }
8745
 
8746
    @Override
8747
    public boolean equals(Object that) {
8748
      if (that == null)
8749
        return false;
8750
      if (that instanceof getItemAvailibilityAtWarehouse_result)
8751
        return this.equals((getItemAvailibilityAtWarehouse_result)that);
8752
      return false;
8753
    }
8754
 
8755
    public boolean equals(getItemAvailibilityAtWarehouse_result that) {
8756
      if (that == null)
8757
        return false;
8758
 
8759
      boolean this_present_success = true;
8760
      boolean that_present_success = true;
8761
      if (this_present_success || that_present_success) {
8762
        if (!(this_present_success && that_present_success))
8763
          return false;
8764
        if (this.success != that.success)
8765
          return false;
8766
      }
8767
 
8768
      boolean this_present_cex = true && this.isSetCex();
8769
      boolean that_present_cex = true && that.isSetCex();
8770
      if (this_present_cex || that_present_cex) {
8771
        if (!(this_present_cex && that_present_cex))
8772
          return false;
8773
        if (!this.cex.equals(that.cex))
8774
          return false;
8775
      }
8776
 
8777
      return true;
8778
    }
8779
 
8780
    @Override
8781
    public int hashCode() {
8782
      return 0;
8783
    }
8784
 
8785
    public int compareTo(getItemAvailibilityAtWarehouse_result other) {
8786
      if (!getClass().equals(other.getClass())) {
8787
        return getClass().getName().compareTo(other.getClass().getName());
8788
      }
8789
 
8790
      int lastComparison = 0;
8791
      getItemAvailibilityAtWarehouse_result typedOther = (getItemAvailibilityAtWarehouse_result)other;
8792
 
8793
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
8794
      if (lastComparison != 0) {
8795
        return lastComparison;
8796
      }
8797
      if (isSetSuccess()) {
8798
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8799
        if (lastComparison != 0) {
8800
          return lastComparison;
8801
        }
8802
      }
8803
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
8804
      if (lastComparison != 0) {
8805
        return lastComparison;
8806
      }
8807
      if (isSetCex()) {
8808
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
8809
        if (lastComparison != 0) {
8810
          return lastComparison;
8811
        }
8812
      }
8813
      return 0;
8814
    }
8815
 
8816
    public _Fields fieldForId(int fieldId) {
8817
      return _Fields.findByThriftId(fieldId);
8818
    }
8819
 
8820
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8821
      org.apache.thrift.protocol.TField field;
8822
      iprot.readStructBegin();
8823
      while (true)
8824
      {
8825
        field = iprot.readFieldBegin();
8826
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8827
          break;
8828
        }
8829
        switch (field.id) {
8830
          case 0: // SUCCESS
8831
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8832
              this.success = iprot.readI64();
8833
              setSuccessIsSet(true);
8834
            } else { 
8835
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8836
            }
8837
            break;
8838
          case 1: // CEX
8839
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8840
              this.cex = new InventoryServiceException();
8841
              this.cex.read(iprot);
8842
            } else { 
8843
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8844
            }
8845
            break;
8846
          default:
8847
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8848
        }
8849
        iprot.readFieldEnd();
8850
      }
8851
      iprot.readStructEnd();
8852
      validate();
8853
    }
8854
 
8855
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8856
      oprot.writeStructBegin(STRUCT_DESC);
8857
 
8858
      if (this.isSetSuccess()) {
8859
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8860
        oprot.writeI64(this.success);
8861
        oprot.writeFieldEnd();
8862
      } else if (this.isSetCex()) {
8863
        oprot.writeFieldBegin(CEX_FIELD_DESC);
8864
        this.cex.write(oprot);
8865
        oprot.writeFieldEnd();
8866
      }
8867
      oprot.writeFieldStop();
8868
      oprot.writeStructEnd();
8869
    }
8870
 
8871
    @Override
8872
    public String toString() {
8873
      StringBuilder sb = new StringBuilder("getItemAvailibilityAtWarehouse_result(");
8874
      boolean first = true;
8875
 
8876
      sb.append("success:");
8877
      sb.append(this.success);
8878
      first = false;
8879
      if (!first) sb.append(", ");
8880
      sb.append("cex:");
8881
      if (this.cex == null) {
8882
        sb.append("null");
8883
      } else {
8884
        sb.append(this.cex);
8885
      }
8886
      first = false;
8887
      sb.append(")");
8888
      return sb.toString();
8889
    }
8890
 
8891
    public void validate() throws org.apache.thrift.TException {
8892
      // check for required fields
8893
    }
8894
 
8895
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8896
      try {
8897
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8898
      } catch (org.apache.thrift.TException te) {
8899
        throw new java.io.IOException(te);
8900
      }
8901
    }
8902
 
8903
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8904
      try {
8905
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8906
      } catch (org.apache.thrift.TException te) {
8907
        throw new java.io.IOException(te);
8908
      }
8909
    }
8910
 
8911
  }
8912
 
8913
  public static class getItemAvailabilityAtLocation_args implements org.apache.thrift.TBase<getItemAvailabilityAtLocation_args, getItemAvailabilityAtLocation_args._Fields>, java.io.Serializable, Cloneable   {
8914
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailabilityAtLocation_args");
8915
 
8916
    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);
8917
 
8918
    private long itemId; // required
8919
 
8920
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8921
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8922
      ITEM_ID((short)1, "itemId");
8923
 
8924
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8925
 
8926
      static {
8927
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8928
          byName.put(field.getFieldName(), field);
8929
        }
8930
      }
8931
 
8932
      /**
8933
       * Find the _Fields constant that matches fieldId, or null if its not found.
8934
       */
8935
      public static _Fields findByThriftId(int fieldId) {
8936
        switch(fieldId) {
8937
          case 1: // ITEM_ID
8938
            return ITEM_ID;
8939
          default:
8940
            return null;
8941
        }
8942
      }
8943
 
8944
      /**
8945
       * Find the _Fields constant that matches fieldId, throwing an exception
8946
       * if it is not found.
8947
       */
8948
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8949
        _Fields fields = findByThriftId(fieldId);
8950
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8951
        return fields;
8952
      }
8953
 
8954
      /**
8955
       * Find the _Fields constant that matches name, or null if its not found.
8956
       */
8957
      public static _Fields findByName(String name) {
8958
        return byName.get(name);
8959
      }
8960
 
8961
      private final short _thriftId;
8962
      private final String _fieldName;
8963
 
8964
      _Fields(short thriftId, String fieldName) {
8965
        _thriftId = thriftId;
8966
        _fieldName = fieldName;
8967
      }
8968
 
8969
      public short getThriftFieldId() {
8970
        return _thriftId;
8971
      }
8972
 
8973
      public String getFieldName() {
8974
        return _fieldName;
8975
      }
8976
    }
8977
 
8978
    // isset id assignments
8979
    private static final int __ITEMID_ISSET_ID = 0;
8980
    private BitSet __isset_bit_vector = new BitSet(1);
8981
 
8982
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8983
    static {
8984
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8985
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8986
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
8987
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8988
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailabilityAtLocation_args.class, metaDataMap);
8989
    }
8990
 
8991
    public getItemAvailabilityAtLocation_args() {
8992
    }
8993
 
8994
    public getItemAvailabilityAtLocation_args(
8995
      long itemId)
8996
    {
8997
      this();
8998
      this.itemId = itemId;
8999
      setItemIdIsSet(true);
9000
    }
9001
 
9002
    /**
9003
     * Performs a deep copy on <i>other</i>.
9004
     */
9005
    public getItemAvailabilityAtLocation_args(getItemAvailabilityAtLocation_args other) {
9006
      __isset_bit_vector.clear();
9007
      __isset_bit_vector.or(other.__isset_bit_vector);
9008
      this.itemId = other.itemId;
9009
    }
9010
 
9011
    public getItemAvailabilityAtLocation_args deepCopy() {
9012
      return new getItemAvailabilityAtLocation_args(this);
9013
    }
9014
 
9015
    @Override
9016
    public void clear() {
9017
      setItemIdIsSet(false);
9018
      this.itemId = 0;
9019
    }
9020
 
9021
    public long getItemId() {
9022
      return this.itemId;
9023
    }
9024
 
9025
    public void setItemId(long itemId) {
9026
      this.itemId = itemId;
9027
      setItemIdIsSet(true);
9028
    }
9029
 
9030
    public void unsetItemId() {
9031
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
9032
    }
9033
 
9034
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
9035
    public boolean isSetItemId() {
9036
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
9037
    }
9038
 
9039
    public void setItemIdIsSet(boolean value) {
9040
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
9041
    }
9042
 
9043
    public void setFieldValue(_Fields field, Object value) {
9044
      switch (field) {
9045
      case ITEM_ID:
9046
        if (value == null) {
9047
          unsetItemId();
9048
        } else {
9049
          setItemId((Long)value);
9050
        }
9051
        break;
9052
 
9053
      }
9054
    }
9055
 
9056
    public Object getFieldValue(_Fields field) {
9057
      switch (field) {
9058
      case ITEM_ID:
9059
        return Long.valueOf(getItemId());
9060
 
9061
      }
9062
      throw new IllegalStateException();
9063
    }
9064
 
9065
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9066
    public boolean isSet(_Fields field) {
9067
      if (field == null) {
9068
        throw new IllegalArgumentException();
9069
      }
9070
 
9071
      switch (field) {
9072
      case ITEM_ID:
9073
        return isSetItemId();
9074
      }
9075
      throw new IllegalStateException();
9076
    }
9077
 
9078
    @Override
9079
    public boolean equals(Object that) {
9080
      if (that == null)
9081
        return false;
9082
      if (that instanceof getItemAvailabilityAtLocation_args)
9083
        return this.equals((getItemAvailabilityAtLocation_args)that);
9084
      return false;
9085
    }
9086
 
9087
    public boolean equals(getItemAvailabilityAtLocation_args that) {
9088
      if (that == null)
9089
        return false;
9090
 
9091
      boolean this_present_itemId = true;
9092
      boolean that_present_itemId = true;
9093
      if (this_present_itemId || that_present_itemId) {
9094
        if (!(this_present_itemId && that_present_itemId))
9095
          return false;
9096
        if (this.itemId != that.itemId)
9097
          return false;
9098
      }
9099
 
9100
      return true;
9101
    }
9102
 
9103
    @Override
9104
    public int hashCode() {
9105
      return 0;
9106
    }
9107
 
9108
    public int compareTo(getItemAvailabilityAtLocation_args other) {
9109
      if (!getClass().equals(other.getClass())) {
9110
        return getClass().getName().compareTo(other.getClass().getName());
9111
      }
9112
 
9113
      int lastComparison = 0;
9114
      getItemAvailabilityAtLocation_args typedOther = (getItemAvailabilityAtLocation_args)other;
9115
 
9116
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
9117
      if (lastComparison != 0) {
9118
        return lastComparison;
9119
      }
9120
      if (isSetItemId()) {
9121
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
9122
        if (lastComparison != 0) {
9123
          return lastComparison;
9124
        }
9125
      }
9126
      return 0;
9127
    }
9128
 
9129
    public _Fields fieldForId(int fieldId) {
9130
      return _Fields.findByThriftId(fieldId);
9131
    }
9132
 
9133
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9134
      org.apache.thrift.protocol.TField field;
9135
      iprot.readStructBegin();
9136
      while (true)
9137
      {
9138
        field = iprot.readFieldBegin();
9139
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9140
          break;
9141
        }
9142
        switch (field.id) {
9143
          case 1: // ITEM_ID
9144
            if (field.type == org.apache.thrift.protocol.TType.I64) {
9145
              this.itemId = iprot.readI64();
9146
              setItemIdIsSet(true);
9147
            } else { 
9148
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9149
            }
9150
            break;
9151
          default:
9152
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9153
        }
9154
        iprot.readFieldEnd();
9155
      }
9156
      iprot.readStructEnd();
9157
      validate();
9158
    }
9159
 
9160
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9161
      validate();
9162
 
9163
      oprot.writeStructBegin(STRUCT_DESC);
9164
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
9165
      oprot.writeI64(this.itemId);
9166
      oprot.writeFieldEnd();
9167
      oprot.writeFieldStop();
9168
      oprot.writeStructEnd();
9169
    }
9170
 
9171
    @Override
9172
    public String toString() {
9173
      StringBuilder sb = new StringBuilder("getItemAvailabilityAtLocation_args(");
9174
      boolean first = true;
9175
 
9176
      sb.append("itemId:");
9177
      sb.append(this.itemId);
9178
      first = false;
9179
      sb.append(")");
9180
      return sb.toString();
9181
    }
9182
 
9183
    public void validate() throws org.apache.thrift.TException {
9184
      // check for required fields
9185
    }
9186
 
9187
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9188
      try {
9189
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9190
      } catch (org.apache.thrift.TException te) {
9191
        throw new java.io.IOException(te);
9192
      }
9193
    }
9194
 
9195
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9196
      try {
9197
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9198
      } catch (org.apache.thrift.TException te) {
9199
        throw new java.io.IOException(te);
9200
      }
9201
    }
9202
 
9203
  }
9204
 
9205
  public static class getItemAvailabilityAtLocation_result implements org.apache.thrift.TBase<getItemAvailabilityAtLocation_result, getItemAvailabilityAtLocation_result._Fields>, java.io.Serializable, Cloneable   {
9206
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemAvailabilityAtLocation_result");
9207
 
9208
    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);
9209
    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);
9210
 
9211
    private List<Long> success; // required
9212
    private InventoryServiceException isex; // required
9213
 
9214
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9215
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9216
      SUCCESS((short)0, "success"),
9217
      ISEX((short)1, "isex");
9218
 
9219
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9220
 
9221
      static {
9222
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9223
          byName.put(field.getFieldName(), field);
9224
        }
9225
      }
9226
 
9227
      /**
9228
       * Find the _Fields constant that matches fieldId, or null if its not found.
9229
       */
9230
      public static _Fields findByThriftId(int fieldId) {
9231
        switch(fieldId) {
9232
          case 0: // SUCCESS
9233
            return SUCCESS;
9234
          case 1: // ISEX
9235
            return ISEX;
9236
          default:
9237
            return null;
9238
        }
9239
      }
9240
 
9241
      /**
9242
       * Find the _Fields constant that matches fieldId, throwing an exception
9243
       * if it is not found.
9244
       */
9245
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9246
        _Fields fields = findByThriftId(fieldId);
9247
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9248
        return fields;
9249
      }
9250
 
9251
      /**
9252
       * Find the _Fields constant that matches name, or null if its not found.
9253
       */
9254
      public static _Fields findByName(String name) {
9255
        return byName.get(name);
9256
      }
9257
 
9258
      private final short _thriftId;
9259
      private final String _fieldName;
9260
 
9261
      _Fields(short thriftId, String fieldName) {
9262
        _thriftId = thriftId;
9263
        _fieldName = fieldName;
9264
      }
9265
 
9266
      public short getThriftFieldId() {
9267
        return _thriftId;
9268
      }
9269
 
9270
      public String getFieldName() {
9271
        return _fieldName;
9272
      }
9273
    }
9274
 
9275
    // isset id assignments
9276
 
9277
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9278
    static {
9279
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9280
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9281
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9282
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
9283
      tmpMap.put(_Fields.ISEX, new org.apache.thrift.meta_data.FieldMetaData("isex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9284
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9285
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9286
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemAvailabilityAtLocation_result.class, metaDataMap);
9287
    }
9288
 
9289
    public getItemAvailabilityAtLocation_result() {
9290
    }
9291
 
9292
    public getItemAvailabilityAtLocation_result(
9293
      List<Long> success,
9294
      InventoryServiceException isex)
9295
    {
9296
      this();
9297
      this.success = success;
9298
      this.isex = isex;
9299
    }
9300
 
9301
    /**
9302
     * Performs a deep copy on <i>other</i>.
9303
     */
9304
    public getItemAvailabilityAtLocation_result(getItemAvailabilityAtLocation_result other) {
9305
      if (other.isSetSuccess()) {
9306
        List<Long> __this__success = new ArrayList<Long>();
9307
        for (Long other_element : other.success) {
9308
          __this__success.add(other_element);
9309
        }
9310
        this.success = __this__success;
9311
      }
9312
      if (other.isSetIsex()) {
9313
        this.isex = new InventoryServiceException(other.isex);
9314
      }
9315
    }
9316
 
9317
    public getItemAvailabilityAtLocation_result deepCopy() {
9318
      return new getItemAvailabilityAtLocation_result(this);
9319
    }
9320
 
9321
    @Override
9322
    public void clear() {
9323
      this.success = null;
9324
      this.isex = null;
9325
    }
9326
 
9327
    public int getSuccessSize() {
9328
      return (this.success == null) ? 0 : this.success.size();
9329
    }
9330
 
9331
    public java.util.Iterator<Long> getSuccessIterator() {
9332
      return (this.success == null) ? null : this.success.iterator();
9333
    }
9334
 
9335
    public void addToSuccess(long elem) {
9336
      if (this.success == null) {
9337
        this.success = new ArrayList<Long>();
9338
      }
9339
      this.success.add(elem);
9340
    }
9341
 
9342
    public List<Long> getSuccess() {
9343
      return this.success;
9344
    }
9345
 
9346
    public void setSuccess(List<Long> success) {
9347
      this.success = success;
9348
    }
9349
 
9350
    public void unsetSuccess() {
9351
      this.success = null;
9352
    }
9353
 
9354
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
9355
    public boolean isSetSuccess() {
9356
      return this.success != null;
9357
    }
9358
 
9359
    public void setSuccessIsSet(boolean value) {
9360
      if (!value) {
9361
        this.success = null;
9362
      }
9363
    }
9364
 
9365
    public InventoryServiceException getIsex() {
9366
      return this.isex;
9367
    }
9368
 
9369
    public void setIsex(InventoryServiceException isex) {
9370
      this.isex = isex;
9371
    }
9372
 
9373
    public void unsetIsex() {
9374
      this.isex = null;
9375
    }
9376
 
9377
    /** Returns true if field isex is set (has been assigned a value) and false otherwise */
9378
    public boolean isSetIsex() {
9379
      return this.isex != null;
9380
    }
9381
 
9382
    public void setIsexIsSet(boolean value) {
9383
      if (!value) {
9384
        this.isex = null;
9385
      }
9386
    }
9387
 
9388
    public void setFieldValue(_Fields field, Object value) {
9389
      switch (field) {
9390
      case SUCCESS:
9391
        if (value == null) {
9392
          unsetSuccess();
9393
        } else {
9394
          setSuccess((List<Long>)value);
9395
        }
9396
        break;
9397
 
9398
      case ISEX:
9399
        if (value == null) {
9400
          unsetIsex();
9401
        } else {
9402
          setIsex((InventoryServiceException)value);
9403
        }
9404
        break;
9405
 
9406
      }
9407
    }
9408
 
9409
    public Object getFieldValue(_Fields field) {
9410
      switch (field) {
9411
      case SUCCESS:
9412
        return getSuccess();
9413
 
9414
      case ISEX:
9415
        return getIsex();
9416
 
9417
      }
9418
      throw new IllegalStateException();
9419
    }
9420
 
9421
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9422
    public boolean isSet(_Fields field) {
9423
      if (field == null) {
9424
        throw new IllegalArgumentException();
9425
      }
9426
 
9427
      switch (field) {
9428
      case SUCCESS:
9429
        return isSetSuccess();
9430
      case ISEX:
9431
        return isSetIsex();
9432
      }
9433
      throw new IllegalStateException();
9434
    }
9435
 
9436
    @Override
9437
    public boolean equals(Object that) {
9438
      if (that == null)
9439
        return false;
9440
      if (that instanceof getItemAvailabilityAtLocation_result)
9441
        return this.equals((getItemAvailabilityAtLocation_result)that);
9442
      return false;
9443
    }
9444
 
9445
    public boolean equals(getItemAvailabilityAtLocation_result that) {
9446
      if (that == null)
9447
        return false;
9448
 
9449
      boolean this_present_success = true && this.isSetSuccess();
9450
      boolean that_present_success = true && that.isSetSuccess();
9451
      if (this_present_success || that_present_success) {
9452
        if (!(this_present_success && that_present_success))
9453
          return false;
9454
        if (!this.success.equals(that.success))
9455
          return false;
9456
      }
9457
 
9458
      boolean this_present_isex = true && this.isSetIsex();
9459
      boolean that_present_isex = true && that.isSetIsex();
9460
      if (this_present_isex || that_present_isex) {
9461
        if (!(this_present_isex && that_present_isex))
9462
          return false;
9463
        if (!this.isex.equals(that.isex))
9464
          return false;
9465
      }
9466
 
9467
      return true;
9468
    }
9469
 
9470
    @Override
9471
    public int hashCode() {
9472
      return 0;
9473
    }
9474
 
9475
    public int compareTo(getItemAvailabilityAtLocation_result other) {
9476
      if (!getClass().equals(other.getClass())) {
9477
        return getClass().getName().compareTo(other.getClass().getName());
9478
      }
9479
 
9480
      int lastComparison = 0;
9481
      getItemAvailabilityAtLocation_result typedOther = (getItemAvailabilityAtLocation_result)other;
9482
 
9483
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
9484
      if (lastComparison != 0) {
9485
        return lastComparison;
9486
      }
9487
      if (isSetSuccess()) {
9488
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
9489
        if (lastComparison != 0) {
9490
          return lastComparison;
9491
        }
9492
      }
9493
      lastComparison = Boolean.valueOf(isSetIsex()).compareTo(typedOther.isSetIsex());
9494
      if (lastComparison != 0) {
9495
        return lastComparison;
9496
      }
9497
      if (isSetIsex()) {
9498
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isex, typedOther.isex);
9499
        if (lastComparison != 0) {
9500
          return lastComparison;
9501
        }
9502
      }
9503
      return 0;
9504
    }
9505
 
9506
    public _Fields fieldForId(int fieldId) {
9507
      return _Fields.findByThriftId(fieldId);
9508
    }
9509
 
9510
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9511
      org.apache.thrift.protocol.TField field;
9512
      iprot.readStructBegin();
9513
      while (true)
9514
      {
9515
        field = iprot.readFieldBegin();
9516
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9517
          break;
9518
        }
9519
        switch (field.id) {
9520
          case 0: // SUCCESS
9521
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
9522
              {
9523
                org.apache.thrift.protocol.TList _list20 = iprot.readListBegin();
9524
                this.success = new ArrayList<Long>(_list20.size);
9525
                for (int _i21 = 0; _i21 < _list20.size; ++_i21)
9526
                {
9527
                  long _elem22; // required
9528
                  _elem22 = iprot.readI64();
9529
                  this.success.add(_elem22);
9530
                }
9531
                iprot.readListEnd();
9532
              }
9533
            } else { 
9534
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9535
            }
9536
            break;
9537
          case 1: // ISEX
9538
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
9539
              this.isex = new InventoryServiceException();
9540
              this.isex.read(iprot);
9541
            } else { 
9542
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9543
            }
9544
            break;
9545
          default:
9546
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9547
        }
9548
        iprot.readFieldEnd();
9549
      }
9550
      iprot.readStructEnd();
9551
      validate();
9552
    }
9553
 
9554
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9555
      oprot.writeStructBegin(STRUCT_DESC);
9556
 
9557
      if (this.isSetSuccess()) {
9558
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
9559
        {
9560
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
9561
          for (long _iter23 : this.success)
9562
          {
9563
            oprot.writeI64(_iter23);
9564
          }
9565
          oprot.writeListEnd();
9566
        }
9567
        oprot.writeFieldEnd();
9568
      } else if (this.isSetIsex()) {
9569
        oprot.writeFieldBegin(ISEX_FIELD_DESC);
9570
        this.isex.write(oprot);
9571
        oprot.writeFieldEnd();
9572
      }
9573
      oprot.writeFieldStop();
9574
      oprot.writeStructEnd();
9575
    }
9576
 
9577
    @Override
9578
    public String toString() {
9579
      StringBuilder sb = new StringBuilder("getItemAvailabilityAtLocation_result(");
9580
      boolean first = true;
9581
 
9582
      sb.append("success:");
9583
      if (this.success == null) {
9584
        sb.append("null");
9585
      } else {
9586
        sb.append(this.success);
9587
      }
9588
      first = false;
9589
      if (!first) sb.append(", ");
9590
      sb.append("isex:");
9591
      if (this.isex == null) {
9592
        sb.append("null");
9593
      } else {
9594
        sb.append(this.isex);
9595
      }
9596
      first = false;
9597
      sb.append(")");
9598
      return sb.toString();
9599
    }
9600
 
9601
    public void validate() throws org.apache.thrift.TException {
9602
      // check for required fields
9603
    }
9604
 
9605
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9606
      try {
9607
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9608
      } catch (org.apache.thrift.TException te) {
9609
        throw new java.io.IOException(te);
9610
      }
9611
    }
9612
 
9613
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9614
      try {
9615
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9616
      } catch (org.apache.thrift.TException te) {
9617
        throw new java.io.IOException(te);
9618
      }
9619
    }
9620
 
9621
  }
9622
 
9623
  public static class getAllWarehouses_args implements org.apache.thrift.TBase<getAllWarehouses_args, getAllWarehouses_args._Fields>, java.io.Serializable, Cloneable   {
9624
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllWarehouses_args");
9625
 
9626
    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);
9627
 
9628
    private boolean isActive; // required
9629
 
9630
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9631
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9632
      IS_ACTIVE((short)1, "isActive");
9633
 
9634
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9635
 
9636
      static {
9637
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9638
          byName.put(field.getFieldName(), field);
9639
        }
9640
      }
9641
 
9642
      /**
9643
       * Find the _Fields constant that matches fieldId, or null if its not found.
9644
       */
9645
      public static _Fields findByThriftId(int fieldId) {
9646
        switch(fieldId) {
9647
          case 1: // IS_ACTIVE
9648
            return IS_ACTIVE;
9649
          default:
9650
            return null;
9651
        }
9652
      }
9653
 
9654
      /**
9655
       * Find the _Fields constant that matches fieldId, throwing an exception
9656
       * if it is not found.
9657
       */
9658
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9659
        _Fields fields = findByThriftId(fieldId);
9660
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9661
        return fields;
9662
      }
9663
 
9664
      /**
9665
       * Find the _Fields constant that matches name, or null if its not found.
9666
       */
9667
      public static _Fields findByName(String name) {
9668
        return byName.get(name);
9669
      }
9670
 
9671
      private final short _thriftId;
9672
      private final String _fieldName;
9673
 
9674
      _Fields(short thriftId, String fieldName) {
9675
        _thriftId = thriftId;
9676
        _fieldName = fieldName;
9677
      }
9678
 
9679
      public short getThriftFieldId() {
9680
        return _thriftId;
9681
      }
9682
 
9683
      public String getFieldName() {
9684
        return _fieldName;
9685
      }
9686
    }
9687
 
9688
    // isset id assignments
9689
    private static final int __ISACTIVE_ISSET_ID = 0;
9690
    private BitSet __isset_bit_vector = new BitSet(1);
9691
 
9692
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9693
    static {
9694
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9695
      tmpMap.put(_Fields.IS_ACTIVE, new org.apache.thrift.meta_data.FieldMetaData("isActive", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9696
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
9697
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9698
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllWarehouses_args.class, metaDataMap);
9699
    }
9700
 
9701
    public getAllWarehouses_args() {
9702
    }
9703
 
9704
    public getAllWarehouses_args(
9705
      boolean isActive)
9706
    {
9707
      this();
9708
      this.isActive = isActive;
9709
      setIsActiveIsSet(true);
9710
    }
9711
 
9712
    /**
9713
     * Performs a deep copy on <i>other</i>.
9714
     */
9715
    public getAllWarehouses_args(getAllWarehouses_args other) {
9716
      __isset_bit_vector.clear();
9717
      __isset_bit_vector.or(other.__isset_bit_vector);
9718
      this.isActive = other.isActive;
9719
    }
9720
 
9721
    public getAllWarehouses_args deepCopy() {
9722
      return new getAllWarehouses_args(this);
9723
    }
9724
 
9725
    @Override
9726
    public void clear() {
9727
      setIsActiveIsSet(false);
9728
      this.isActive = false;
9729
    }
9730
 
9731
    public boolean isIsActive() {
9732
      return this.isActive;
9733
    }
9734
 
9735
    public void setIsActive(boolean isActive) {
9736
      this.isActive = isActive;
9737
      setIsActiveIsSet(true);
9738
    }
9739
 
9740
    public void unsetIsActive() {
9741
      __isset_bit_vector.clear(__ISACTIVE_ISSET_ID);
9742
    }
9743
 
9744
    /** Returns true if field isActive is set (has been assigned a value) and false otherwise */
9745
    public boolean isSetIsActive() {
9746
      return __isset_bit_vector.get(__ISACTIVE_ISSET_ID);
9747
    }
9748
 
9749
    public void setIsActiveIsSet(boolean value) {
9750
      __isset_bit_vector.set(__ISACTIVE_ISSET_ID, value);
9751
    }
9752
 
9753
    public void setFieldValue(_Fields field, Object value) {
9754
      switch (field) {
9755
      case IS_ACTIVE:
9756
        if (value == null) {
9757
          unsetIsActive();
9758
        } else {
9759
          setIsActive((Boolean)value);
9760
        }
9761
        break;
9762
 
9763
      }
9764
    }
9765
 
9766
    public Object getFieldValue(_Fields field) {
9767
      switch (field) {
9768
      case IS_ACTIVE:
9769
        return Boolean.valueOf(isIsActive());
9770
 
9771
      }
9772
      throw new IllegalStateException();
9773
    }
9774
 
9775
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
9776
    public boolean isSet(_Fields field) {
9777
      if (field == null) {
9778
        throw new IllegalArgumentException();
9779
      }
9780
 
9781
      switch (field) {
9782
      case IS_ACTIVE:
9783
        return isSetIsActive();
9784
      }
9785
      throw new IllegalStateException();
9786
    }
9787
 
9788
    @Override
9789
    public boolean equals(Object that) {
9790
      if (that == null)
9791
        return false;
9792
      if (that instanceof getAllWarehouses_args)
9793
        return this.equals((getAllWarehouses_args)that);
9794
      return false;
9795
    }
9796
 
9797
    public boolean equals(getAllWarehouses_args that) {
9798
      if (that == null)
9799
        return false;
9800
 
9801
      boolean this_present_isActive = true;
9802
      boolean that_present_isActive = true;
9803
      if (this_present_isActive || that_present_isActive) {
9804
        if (!(this_present_isActive && that_present_isActive))
9805
          return false;
9806
        if (this.isActive != that.isActive)
9807
          return false;
9808
      }
9809
 
9810
      return true;
9811
    }
9812
 
9813
    @Override
9814
    public int hashCode() {
9815
      return 0;
9816
    }
9817
 
9818
    public int compareTo(getAllWarehouses_args other) {
9819
      if (!getClass().equals(other.getClass())) {
9820
        return getClass().getName().compareTo(other.getClass().getName());
9821
      }
9822
 
9823
      int lastComparison = 0;
9824
      getAllWarehouses_args typedOther = (getAllWarehouses_args)other;
9825
 
9826
      lastComparison = Boolean.valueOf(isSetIsActive()).compareTo(typedOther.isSetIsActive());
9827
      if (lastComparison != 0) {
9828
        return lastComparison;
9829
      }
9830
      if (isSetIsActive()) {
9831
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.isActive, typedOther.isActive);
9832
        if (lastComparison != 0) {
9833
          return lastComparison;
9834
        }
9835
      }
9836
      return 0;
9837
    }
9838
 
9839
    public _Fields fieldForId(int fieldId) {
9840
      return _Fields.findByThriftId(fieldId);
9841
    }
9842
 
9843
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
9844
      org.apache.thrift.protocol.TField field;
9845
      iprot.readStructBegin();
9846
      while (true)
9847
      {
9848
        field = iprot.readFieldBegin();
9849
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
9850
          break;
9851
        }
9852
        switch (field.id) {
9853
          case 1: // IS_ACTIVE
9854
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
9855
              this.isActive = iprot.readBool();
9856
              setIsActiveIsSet(true);
9857
            } else { 
9858
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9859
            }
9860
            break;
9861
          default:
9862
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
9863
        }
9864
        iprot.readFieldEnd();
9865
      }
9866
      iprot.readStructEnd();
9867
      validate();
9868
    }
9869
 
9870
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
9871
      validate();
9872
 
9873
      oprot.writeStructBegin(STRUCT_DESC);
9874
      oprot.writeFieldBegin(IS_ACTIVE_FIELD_DESC);
9875
      oprot.writeBool(this.isActive);
9876
      oprot.writeFieldEnd();
9877
      oprot.writeFieldStop();
9878
      oprot.writeStructEnd();
9879
    }
9880
 
9881
    @Override
9882
    public String toString() {
9883
      StringBuilder sb = new StringBuilder("getAllWarehouses_args(");
9884
      boolean first = true;
9885
 
9886
      sb.append("isActive:");
9887
      sb.append(this.isActive);
9888
      first = false;
9889
      sb.append(")");
9890
      return sb.toString();
9891
    }
9892
 
9893
    public void validate() throws org.apache.thrift.TException {
9894
      // check for required fields
9895
    }
9896
 
9897
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
9898
      try {
9899
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
9900
      } catch (org.apache.thrift.TException te) {
9901
        throw new java.io.IOException(te);
9902
      }
9903
    }
9904
 
9905
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
9906
      try {
9907
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
9908
        __isset_bit_vector = new BitSet(1);
9909
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
9910
      } catch (org.apache.thrift.TException te) {
9911
        throw new java.io.IOException(te);
9912
      }
9913
    }
9914
 
9915
  }
9916
 
9917
  public static class getAllWarehouses_result implements org.apache.thrift.TBase<getAllWarehouses_result, getAllWarehouses_result._Fields>, java.io.Serializable, Cloneable   {
9918
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllWarehouses_result");
9919
 
9920
    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);
9921
    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);
9922
 
9923
    private List<Warehouse> success; // required
9924
    private InventoryServiceException cex; // required
9925
 
9926
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
9927
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
9928
      SUCCESS((short)0, "success"),
9929
      CEX((short)1, "cex");
9930
 
9931
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
9932
 
9933
      static {
9934
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
9935
          byName.put(field.getFieldName(), field);
9936
        }
9937
      }
9938
 
9939
      /**
9940
       * Find the _Fields constant that matches fieldId, or null if its not found.
9941
       */
9942
      public static _Fields findByThriftId(int fieldId) {
9943
        switch(fieldId) {
9944
          case 0: // SUCCESS
9945
            return SUCCESS;
9946
          case 1: // CEX
9947
            return CEX;
9948
          default:
9949
            return null;
9950
        }
9951
      }
9952
 
9953
      /**
9954
       * Find the _Fields constant that matches fieldId, throwing an exception
9955
       * if it is not found.
9956
       */
9957
      public static _Fields findByThriftIdOrThrow(int fieldId) {
9958
        _Fields fields = findByThriftId(fieldId);
9959
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
9960
        return fields;
9961
      }
9962
 
9963
      /**
9964
       * Find the _Fields constant that matches name, or null if its not found.
9965
       */
9966
      public static _Fields findByName(String name) {
9967
        return byName.get(name);
9968
      }
9969
 
9970
      private final short _thriftId;
9971
      private final String _fieldName;
9972
 
9973
      _Fields(short thriftId, String fieldName) {
9974
        _thriftId = thriftId;
9975
        _fieldName = fieldName;
9976
      }
9977
 
9978
      public short getThriftFieldId() {
9979
        return _thriftId;
9980
      }
9981
 
9982
      public String getFieldName() {
9983
        return _fieldName;
9984
      }
9985
    }
9986
 
9987
    // isset id assignments
9988
 
9989
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
9990
    static {
9991
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
9992
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9993
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
9994
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
9995
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
9996
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
9997
      metaDataMap = Collections.unmodifiableMap(tmpMap);
9998
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllWarehouses_result.class, metaDataMap);
9999
    }
10000
 
10001
    public getAllWarehouses_result() {
10002
    }
10003
 
10004
    public getAllWarehouses_result(
10005
      List<Warehouse> success,
10006
      InventoryServiceException cex)
10007
    {
10008
      this();
10009
      this.success = success;
10010
      this.cex = cex;
10011
    }
10012
 
10013
    /**
10014
     * Performs a deep copy on <i>other</i>.
10015
     */
10016
    public getAllWarehouses_result(getAllWarehouses_result other) {
10017
      if (other.isSetSuccess()) {
10018
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
10019
        for (Warehouse other_element : other.success) {
10020
          __this__success.add(new Warehouse(other_element));
10021
        }
10022
        this.success = __this__success;
10023
      }
10024
      if (other.isSetCex()) {
10025
        this.cex = new InventoryServiceException(other.cex);
10026
      }
10027
    }
10028
 
10029
    public getAllWarehouses_result deepCopy() {
10030
      return new getAllWarehouses_result(this);
10031
    }
10032
 
10033
    @Override
10034
    public void clear() {
10035
      this.success = null;
10036
      this.cex = null;
10037
    }
10038
 
10039
    public int getSuccessSize() {
10040
      return (this.success == null) ? 0 : this.success.size();
10041
    }
10042
 
10043
    public java.util.Iterator<Warehouse> getSuccessIterator() {
10044
      return (this.success == null) ? null : this.success.iterator();
10045
    }
10046
 
10047
    public void addToSuccess(Warehouse elem) {
10048
      if (this.success == null) {
10049
        this.success = new ArrayList<Warehouse>();
10050
      }
10051
      this.success.add(elem);
10052
    }
10053
 
10054
    public List<Warehouse> getSuccess() {
10055
      return this.success;
10056
    }
10057
 
10058
    public void setSuccess(List<Warehouse> success) {
10059
      this.success = success;
10060
    }
10061
 
10062
    public void unsetSuccess() {
10063
      this.success = null;
10064
    }
10065
 
10066
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
10067
    public boolean isSetSuccess() {
10068
      return this.success != null;
10069
    }
10070
 
10071
    public void setSuccessIsSet(boolean value) {
10072
      if (!value) {
10073
        this.success = null;
10074
      }
10075
    }
10076
 
10077
    public InventoryServiceException getCex() {
10078
      return this.cex;
10079
    }
10080
 
10081
    public void setCex(InventoryServiceException cex) {
10082
      this.cex = cex;
10083
    }
10084
 
10085
    public void unsetCex() {
10086
      this.cex = null;
10087
    }
10088
 
10089
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
10090
    public boolean isSetCex() {
10091
      return this.cex != null;
10092
    }
10093
 
10094
    public void setCexIsSet(boolean value) {
10095
      if (!value) {
10096
        this.cex = null;
10097
      }
10098
    }
10099
 
10100
    public void setFieldValue(_Fields field, Object value) {
10101
      switch (field) {
10102
      case SUCCESS:
10103
        if (value == null) {
10104
          unsetSuccess();
10105
        } else {
10106
          setSuccess((List<Warehouse>)value);
10107
        }
10108
        break;
10109
 
10110
      case CEX:
10111
        if (value == null) {
10112
          unsetCex();
10113
        } else {
10114
          setCex((InventoryServiceException)value);
10115
        }
10116
        break;
10117
 
10118
      }
10119
    }
10120
 
10121
    public Object getFieldValue(_Fields field) {
10122
      switch (field) {
10123
      case SUCCESS:
10124
        return getSuccess();
10125
 
10126
      case CEX:
10127
        return getCex();
10128
 
10129
      }
10130
      throw new IllegalStateException();
10131
    }
10132
 
10133
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10134
    public boolean isSet(_Fields field) {
10135
      if (field == null) {
10136
        throw new IllegalArgumentException();
10137
      }
10138
 
10139
      switch (field) {
10140
      case SUCCESS:
10141
        return isSetSuccess();
10142
      case CEX:
10143
        return isSetCex();
10144
      }
10145
      throw new IllegalStateException();
10146
    }
10147
 
10148
    @Override
10149
    public boolean equals(Object that) {
10150
      if (that == null)
10151
        return false;
10152
      if (that instanceof getAllWarehouses_result)
10153
        return this.equals((getAllWarehouses_result)that);
10154
      return false;
10155
    }
10156
 
10157
    public boolean equals(getAllWarehouses_result that) {
10158
      if (that == null)
10159
        return false;
10160
 
10161
      boolean this_present_success = true && this.isSetSuccess();
10162
      boolean that_present_success = true && that.isSetSuccess();
10163
      if (this_present_success || that_present_success) {
10164
        if (!(this_present_success && that_present_success))
10165
          return false;
10166
        if (!this.success.equals(that.success))
10167
          return false;
10168
      }
10169
 
10170
      boolean this_present_cex = true && this.isSetCex();
10171
      boolean that_present_cex = true && that.isSetCex();
10172
      if (this_present_cex || that_present_cex) {
10173
        if (!(this_present_cex && that_present_cex))
10174
          return false;
10175
        if (!this.cex.equals(that.cex))
10176
          return false;
10177
      }
10178
 
10179
      return true;
10180
    }
10181
 
10182
    @Override
10183
    public int hashCode() {
10184
      return 0;
10185
    }
10186
 
10187
    public int compareTo(getAllWarehouses_result other) {
10188
      if (!getClass().equals(other.getClass())) {
10189
        return getClass().getName().compareTo(other.getClass().getName());
10190
      }
10191
 
10192
      int lastComparison = 0;
10193
      getAllWarehouses_result typedOther = (getAllWarehouses_result)other;
10194
 
10195
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10196
      if (lastComparison != 0) {
10197
        return lastComparison;
10198
      }
10199
      if (isSetSuccess()) {
10200
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10201
        if (lastComparison != 0) {
10202
          return lastComparison;
10203
        }
10204
      }
10205
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
10206
      if (lastComparison != 0) {
10207
        return lastComparison;
10208
      }
10209
      if (isSetCex()) {
10210
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
10211
        if (lastComparison != 0) {
10212
          return lastComparison;
10213
        }
10214
      }
10215
      return 0;
10216
    }
10217
 
10218
    public _Fields fieldForId(int fieldId) {
10219
      return _Fields.findByThriftId(fieldId);
10220
    }
10221
 
10222
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10223
      org.apache.thrift.protocol.TField field;
10224
      iprot.readStructBegin();
10225
      while (true)
10226
      {
10227
        field = iprot.readFieldBegin();
10228
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10229
          break;
10230
        }
10231
        switch (field.id) {
10232
          case 0: // SUCCESS
10233
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
10234
              {
10235
                org.apache.thrift.protocol.TList _list24 = iprot.readListBegin();
10236
                this.success = new ArrayList<Warehouse>(_list24.size);
10237
                for (int _i25 = 0; _i25 < _list24.size; ++_i25)
10238
                {
10239
                  Warehouse _elem26; // required
10240
                  _elem26 = new Warehouse();
10241
                  _elem26.read(iprot);
10242
                  this.success.add(_elem26);
10243
                }
10244
                iprot.readListEnd();
10245
              }
10246
            } else { 
10247
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10248
            }
10249
            break;
10250
          case 1: // CEX
10251
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10252
              this.cex = new InventoryServiceException();
10253
              this.cex.read(iprot);
10254
            } else { 
10255
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10256
            }
10257
            break;
10258
          default:
10259
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10260
        }
10261
        iprot.readFieldEnd();
10262
      }
10263
      iprot.readStructEnd();
10264
      validate();
10265
    }
10266
 
10267
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10268
      oprot.writeStructBegin(STRUCT_DESC);
10269
 
10270
      if (this.isSetSuccess()) {
10271
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10272
        {
10273
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
10274
          for (Warehouse _iter27 : this.success)
10275
          {
10276
            _iter27.write(oprot);
10277
          }
10278
          oprot.writeListEnd();
10279
        }
10280
        oprot.writeFieldEnd();
10281
      } else if (this.isSetCex()) {
10282
        oprot.writeFieldBegin(CEX_FIELD_DESC);
10283
        this.cex.write(oprot);
10284
        oprot.writeFieldEnd();
10285
      }
10286
      oprot.writeFieldStop();
10287
      oprot.writeStructEnd();
10288
    }
10289
 
10290
    @Override
10291
    public String toString() {
10292
      StringBuilder sb = new StringBuilder("getAllWarehouses_result(");
10293
      boolean first = true;
10294
 
10295
      sb.append("success:");
10296
      if (this.success == null) {
10297
        sb.append("null");
10298
      } else {
10299
        sb.append(this.success);
10300
      }
10301
      first = false;
10302
      if (!first) sb.append(", ");
10303
      sb.append("cex:");
10304
      if (this.cex == null) {
10305
        sb.append("null");
10306
      } else {
10307
        sb.append(this.cex);
10308
      }
10309
      first = false;
10310
      sb.append(")");
10311
      return sb.toString();
10312
    }
10313
 
10314
    public void validate() throws org.apache.thrift.TException {
10315
      // check for required fields
10316
    }
10317
 
10318
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10319
      try {
10320
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10321
      } catch (org.apache.thrift.TException te) {
10322
        throw new java.io.IOException(te);
10323
      }
10324
    }
10325
 
10326
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10327
      try {
10328
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10329
      } catch (org.apache.thrift.TException te) {
10330
        throw new java.io.IOException(te);
10331
      }
10332
    }
10333
 
10334
  }
10335
 
10336
  public static class getWarehouse_args implements org.apache.thrift.TBase<getWarehouse_args, getWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
10337
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouse_args");
10338
 
10339
    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);
10340
 
10341
    private long warehouse_id; // required
10342
 
10343
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10344
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10345
      WAREHOUSE_ID((short)1, "warehouse_id");
10346
 
10347
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10348
 
10349
      static {
10350
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10351
          byName.put(field.getFieldName(), field);
10352
        }
10353
      }
10354
 
10355
      /**
10356
       * Find the _Fields constant that matches fieldId, or null if its not found.
10357
       */
10358
      public static _Fields findByThriftId(int fieldId) {
10359
        switch(fieldId) {
10360
          case 1: // WAREHOUSE_ID
10361
            return WAREHOUSE_ID;
10362
          default:
10363
            return null;
10364
        }
10365
      }
10366
 
10367
      /**
10368
       * Find the _Fields constant that matches fieldId, throwing an exception
10369
       * if it is not found.
10370
       */
10371
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10372
        _Fields fields = findByThriftId(fieldId);
10373
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10374
        return fields;
10375
      }
10376
 
10377
      /**
10378
       * Find the _Fields constant that matches name, or null if its not found.
10379
       */
10380
      public static _Fields findByName(String name) {
10381
        return byName.get(name);
10382
      }
10383
 
10384
      private final short _thriftId;
10385
      private final String _fieldName;
10386
 
10387
      _Fields(short thriftId, String fieldName) {
10388
        _thriftId = thriftId;
10389
        _fieldName = fieldName;
10390
      }
10391
 
10392
      public short getThriftFieldId() {
10393
        return _thriftId;
10394
      }
10395
 
10396
      public String getFieldName() {
10397
        return _fieldName;
10398
      }
10399
    }
10400
 
10401
    // isset id assignments
10402
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
10403
    private BitSet __isset_bit_vector = new BitSet(1);
10404
 
10405
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10406
    static {
10407
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10408
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10409
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
10410
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10411
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouse_args.class, metaDataMap);
10412
    }
10413
 
10414
    public getWarehouse_args() {
10415
    }
10416
 
10417
    public getWarehouse_args(
10418
      long warehouse_id)
10419
    {
10420
      this();
10421
      this.warehouse_id = warehouse_id;
10422
      setWarehouse_idIsSet(true);
10423
    }
10424
 
10425
    /**
10426
     * Performs a deep copy on <i>other</i>.
10427
     */
10428
    public getWarehouse_args(getWarehouse_args other) {
10429
      __isset_bit_vector.clear();
10430
      __isset_bit_vector.or(other.__isset_bit_vector);
10431
      this.warehouse_id = other.warehouse_id;
10432
    }
10433
 
10434
    public getWarehouse_args deepCopy() {
10435
      return new getWarehouse_args(this);
10436
    }
10437
 
10438
    @Override
10439
    public void clear() {
10440
      setWarehouse_idIsSet(false);
10441
      this.warehouse_id = 0;
10442
    }
10443
 
10444
    public long getWarehouse_id() {
10445
      return this.warehouse_id;
10446
    }
10447
 
10448
    public void setWarehouse_id(long warehouse_id) {
10449
      this.warehouse_id = warehouse_id;
10450
      setWarehouse_idIsSet(true);
10451
    }
10452
 
10453
    public void unsetWarehouse_id() {
10454
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
10455
    }
10456
 
10457
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
10458
    public boolean isSetWarehouse_id() {
10459
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
10460
    }
10461
 
10462
    public void setWarehouse_idIsSet(boolean value) {
10463
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
10464
    }
10465
 
10466
    public void setFieldValue(_Fields field, Object value) {
10467
      switch (field) {
10468
      case WAREHOUSE_ID:
10469
        if (value == null) {
10470
          unsetWarehouse_id();
10471
        } else {
10472
          setWarehouse_id((Long)value);
10473
        }
10474
        break;
10475
 
10476
      }
10477
    }
10478
 
10479
    public Object getFieldValue(_Fields field) {
10480
      switch (field) {
10481
      case WAREHOUSE_ID:
10482
        return Long.valueOf(getWarehouse_id());
10483
 
10484
      }
10485
      throw new IllegalStateException();
10486
    }
10487
 
10488
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10489
    public boolean isSet(_Fields field) {
10490
      if (field == null) {
10491
        throw new IllegalArgumentException();
10492
      }
10493
 
10494
      switch (field) {
10495
      case WAREHOUSE_ID:
10496
        return isSetWarehouse_id();
10497
      }
10498
      throw new IllegalStateException();
10499
    }
10500
 
10501
    @Override
10502
    public boolean equals(Object that) {
10503
      if (that == null)
10504
        return false;
10505
      if (that instanceof getWarehouse_args)
10506
        return this.equals((getWarehouse_args)that);
10507
      return false;
10508
    }
10509
 
10510
    public boolean equals(getWarehouse_args that) {
10511
      if (that == null)
10512
        return false;
10513
 
10514
      boolean this_present_warehouse_id = true;
10515
      boolean that_present_warehouse_id = true;
10516
      if (this_present_warehouse_id || that_present_warehouse_id) {
10517
        if (!(this_present_warehouse_id && that_present_warehouse_id))
10518
          return false;
10519
        if (this.warehouse_id != that.warehouse_id)
10520
          return false;
10521
      }
10522
 
10523
      return true;
10524
    }
10525
 
10526
    @Override
10527
    public int hashCode() {
10528
      return 0;
10529
    }
10530
 
10531
    public int compareTo(getWarehouse_args other) {
10532
      if (!getClass().equals(other.getClass())) {
10533
        return getClass().getName().compareTo(other.getClass().getName());
10534
      }
10535
 
10536
      int lastComparison = 0;
10537
      getWarehouse_args typedOther = (getWarehouse_args)other;
10538
 
10539
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
10540
      if (lastComparison != 0) {
10541
        return lastComparison;
10542
      }
10543
      if (isSetWarehouse_id()) {
10544
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
10545
        if (lastComparison != 0) {
10546
          return lastComparison;
10547
        }
10548
      }
10549
      return 0;
10550
    }
10551
 
10552
    public _Fields fieldForId(int fieldId) {
10553
      return _Fields.findByThriftId(fieldId);
10554
    }
10555
 
10556
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10557
      org.apache.thrift.protocol.TField field;
10558
      iprot.readStructBegin();
10559
      while (true)
10560
      {
10561
        field = iprot.readFieldBegin();
10562
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10563
          break;
10564
        }
10565
        switch (field.id) {
10566
          case 1: // WAREHOUSE_ID
10567
            if (field.type == org.apache.thrift.protocol.TType.I64) {
10568
              this.warehouse_id = iprot.readI64();
10569
              setWarehouse_idIsSet(true);
10570
            } else { 
10571
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10572
            }
10573
            break;
10574
          default:
10575
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10576
        }
10577
        iprot.readFieldEnd();
10578
      }
10579
      iprot.readStructEnd();
10580
      validate();
10581
    }
10582
 
10583
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10584
      validate();
10585
 
10586
      oprot.writeStructBegin(STRUCT_DESC);
10587
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
10588
      oprot.writeI64(this.warehouse_id);
10589
      oprot.writeFieldEnd();
10590
      oprot.writeFieldStop();
10591
      oprot.writeStructEnd();
10592
    }
10593
 
10594
    @Override
10595
    public String toString() {
10596
      StringBuilder sb = new StringBuilder("getWarehouse_args(");
10597
      boolean first = true;
10598
 
10599
      sb.append("warehouse_id:");
10600
      sb.append(this.warehouse_id);
10601
      first = false;
10602
      sb.append(")");
10603
      return sb.toString();
10604
    }
10605
 
10606
    public void validate() throws org.apache.thrift.TException {
10607
      // check for required fields
10608
    }
10609
 
10610
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10611
      try {
10612
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10613
      } catch (org.apache.thrift.TException te) {
10614
        throw new java.io.IOException(te);
10615
      }
10616
    }
10617
 
10618
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
10619
      try {
10620
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
10621
        __isset_bit_vector = new BitSet(1);
10622
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
10623
      } catch (org.apache.thrift.TException te) {
10624
        throw new java.io.IOException(te);
10625
      }
10626
    }
10627
 
10628
  }
10629
 
10630
  public static class getWarehouse_result implements org.apache.thrift.TBase<getWarehouse_result, getWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
10631
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouse_result");
10632
 
10633
    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);
10634
    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);
10635
 
10636
    private Warehouse success; // required
10637
    private InventoryServiceException cex; // required
10638
 
10639
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
10640
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
10641
      SUCCESS((short)0, "success"),
10642
      CEX((short)1, "cex");
10643
 
10644
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
10645
 
10646
      static {
10647
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
10648
          byName.put(field.getFieldName(), field);
10649
        }
10650
      }
10651
 
10652
      /**
10653
       * Find the _Fields constant that matches fieldId, or null if its not found.
10654
       */
10655
      public static _Fields findByThriftId(int fieldId) {
10656
        switch(fieldId) {
10657
          case 0: // SUCCESS
10658
            return SUCCESS;
10659
          case 1: // CEX
10660
            return CEX;
10661
          default:
10662
            return null;
10663
        }
10664
      }
10665
 
10666
      /**
10667
       * Find the _Fields constant that matches fieldId, throwing an exception
10668
       * if it is not found.
10669
       */
10670
      public static _Fields findByThriftIdOrThrow(int fieldId) {
10671
        _Fields fields = findByThriftId(fieldId);
10672
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
10673
        return fields;
10674
      }
10675
 
10676
      /**
10677
       * Find the _Fields constant that matches name, or null if its not found.
10678
       */
10679
      public static _Fields findByName(String name) {
10680
        return byName.get(name);
10681
      }
10682
 
10683
      private final short _thriftId;
10684
      private final String _fieldName;
10685
 
10686
      _Fields(short thriftId, String fieldName) {
10687
        _thriftId = thriftId;
10688
        _fieldName = fieldName;
10689
      }
10690
 
10691
      public short getThriftFieldId() {
10692
        return _thriftId;
10693
      }
10694
 
10695
      public String getFieldName() {
10696
        return _fieldName;
10697
      }
10698
    }
10699
 
10700
    // isset id assignments
10701
 
10702
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
10703
    static {
10704
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
10705
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10706
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class)));
10707
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
10708
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
10709
      metaDataMap = Collections.unmodifiableMap(tmpMap);
10710
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouse_result.class, metaDataMap);
10711
    }
10712
 
10713
    public getWarehouse_result() {
10714
    }
10715
 
10716
    public getWarehouse_result(
10717
      Warehouse success,
10718
      InventoryServiceException cex)
10719
    {
10720
      this();
10721
      this.success = success;
10722
      this.cex = cex;
10723
    }
10724
 
10725
    /**
10726
     * Performs a deep copy on <i>other</i>.
10727
     */
10728
    public getWarehouse_result(getWarehouse_result other) {
10729
      if (other.isSetSuccess()) {
10730
        this.success = new Warehouse(other.success);
10731
      }
10732
      if (other.isSetCex()) {
10733
        this.cex = new InventoryServiceException(other.cex);
10734
      }
10735
    }
10736
 
10737
    public getWarehouse_result deepCopy() {
10738
      return new getWarehouse_result(this);
10739
    }
10740
 
10741
    @Override
10742
    public void clear() {
10743
      this.success = null;
10744
      this.cex = null;
10745
    }
10746
 
10747
    public Warehouse getSuccess() {
10748
      return this.success;
10749
    }
10750
 
10751
    public void setSuccess(Warehouse success) {
10752
      this.success = success;
10753
    }
10754
 
10755
    public void unsetSuccess() {
10756
      this.success = null;
10757
    }
10758
 
10759
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
10760
    public boolean isSetSuccess() {
10761
      return this.success != null;
10762
    }
10763
 
10764
    public void setSuccessIsSet(boolean value) {
10765
      if (!value) {
10766
        this.success = null;
10767
      }
10768
    }
10769
 
10770
    public InventoryServiceException getCex() {
10771
      return this.cex;
10772
    }
10773
 
10774
    public void setCex(InventoryServiceException cex) {
10775
      this.cex = cex;
10776
    }
10777
 
10778
    public void unsetCex() {
10779
      this.cex = null;
10780
    }
10781
 
10782
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
10783
    public boolean isSetCex() {
10784
      return this.cex != null;
10785
    }
10786
 
10787
    public void setCexIsSet(boolean value) {
10788
      if (!value) {
10789
        this.cex = null;
10790
      }
10791
    }
10792
 
10793
    public void setFieldValue(_Fields field, Object value) {
10794
      switch (field) {
10795
      case SUCCESS:
10796
        if (value == null) {
10797
          unsetSuccess();
10798
        } else {
10799
          setSuccess((Warehouse)value);
10800
        }
10801
        break;
10802
 
10803
      case CEX:
10804
        if (value == null) {
10805
          unsetCex();
10806
        } else {
10807
          setCex((InventoryServiceException)value);
10808
        }
10809
        break;
10810
 
10811
      }
10812
    }
10813
 
10814
    public Object getFieldValue(_Fields field) {
10815
      switch (field) {
10816
      case SUCCESS:
10817
        return getSuccess();
10818
 
10819
      case CEX:
10820
        return getCex();
10821
 
10822
      }
10823
      throw new IllegalStateException();
10824
    }
10825
 
10826
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
10827
    public boolean isSet(_Fields field) {
10828
      if (field == null) {
10829
        throw new IllegalArgumentException();
10830
      }
10831
 
10832
      switch (field) {
10833
      case SUCCESS:
10834
        return isSetSuccess();
10835
      case CEX:
10836
        return isSetCex();
10837
      }
10838
      throw new IllegalStateException();
10839
    }
10840
 
10841
    @Override
10842
    public boolean equals(Object that) {
10843
      if (that == null)
10844
        return false;
10845
      if (that instanceof getWarehouse_result)
10846
        return this.equals((getWarehouse_result)that);
10847
      return false;
10848
    }
10849
 
10850
    public boolean equals(getWarehouse_result that) {
10851
      if (that == null)
10852
        return false;
10853
 
10854
      boolean this_present_success = true && this.isSetSuccess();
10855
      boolean that_present_success = true && that.isSetSuccess();
10856
      if (this_present_success || that_present_success) {
10857
        if (!(this_present_success && that_present_success))
10858
          return false;
10859
        if (!this.success.equals(that.success))
10860
          return false;
10861
      }
10862
 
10863
      boolean this_present_cex = true && this.isSetCex();
10864
      boolean that_present_cex = true && that.isSetCex();
10865
      if (this_present_cex || that_present_cex) {
10866
        if (!(this_present_cex && that_present_cex))
10867
          return false;
10868
        if (!this.cex.equals(that.cex))
10869
          return false;
10870
      }
10871
 
10872
      return true;
10873
    }
10874
 
10875
    @Override
10876
    public int hashCode() {
10877
      return 0;
10878
    }
10879
 
10880
    public int compareTo(getWarehouse_result other) {
10881
      if (!getClass().equals(other.getClass())) {
10882
        return getClass().getName().compareTo(other.getClass().getName());
10883
      }
10884
 
10885
      int lastComparison = 0;
10886
      getWarehouse_result typedOther = (getWarehouse_result)other;
10887
 
10888
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
10889
      if (lastComparison != 0) {
10890
        return lastComparison;
10891
      }
10892
      if (isSetSuccess()) {
10893
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
10894
        if (lastComparison != 0) {
10895
          return lastComparison;
10896
        }
10897
      }
10898
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
10899
      if (lastComparison != 0) {
10900
        return lastComparison;
10901
      }
10902
      if (isSetCex()) {
10903
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
10904
        if (lastComparison != 0) {
10905
          return lastComparison;
10906
        }
10907
      }
10908
      return 0;
10909
    }
10910
 
10911
    public _Fields fieldForId(int fieldId) {
10912
      return _Fields.findByThriftId(fieldId);
10913
    }
10914
 
10915
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
10916
      org.apache.thrift.protocol.TField field;
10917
      iprot.readStructBegin();
10918
      while (true)
10919
      {
10920
        field = iprot.readFieldBegin();
10921
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
10922
          break;
10923
        }
10924
        switch (field.id) {
10925
          case 0: // SUCCESS
10926
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10927
              this.success = new Warehouse();
10928
              this.success.read(iprot);
10929
            } else { 
10930
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10931
            }
10932
            break;
10933
          case 1: // CEX
10934
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
10935
              this.cex = new InventoryServiceException();
10936
              this.cex.read(iprot);
10937
            } else { 
10938
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10939
            }
10940
            break;
10941
          default:
10942
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
10943
        }
10944
        iprot.readFieldEnd();
10945
      }
10946
      iprot.readStructEnd();
10947
      validate();
10948
    }
10949
 
10950
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
10951
      oprot.writeStructBegin(STRUCT_DESC);
10952
 
10953
      if (this.isSetSuccess()) {
10954
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
10955
        this.success.write(oprot);
10956
        oprot.writeFieldEnd();
10957
      } else if (this.isSetCex()) {
10958
        oprot.writeFieldBegin(CEX_FIELD_DESC);
10959
        this.cex.write(oprot);
10960
        oprot.writeFieldEnd();
10961
      }
10962
      oprot.writeFieldStop();
10963
      oprot.writeStructEnd();
10964
    }
10965
 
10966
    @Override
10967
    public String toString() {
10968
      StringBuilder sb = new StringBuilder("getWarehouse_result(");
10969
      boolean first = true;
10970
 
10971
      sb.append("success:");
10972
      if (this.success == null) {
10973
        sb.append("null");
10974
      } else {
10975
        sb.append(this.success);
10976
      }
10977
      first = false;
10978
      if (!first) sb.append(", ");
10979
      sb.append("cex:");
10980
      if (this.cex == null) {
10981
        sb.append("null");
10982
      } else {
10983
        sb.append(this.cex);
10984
      }
10985
      first = false;
10986
      sb.append(")");
10987
      return sb.toString();
10988
    }
10989
 
10990
    public void validate() throws org.apache.thrift.TException {
10991
      // check for required fields
10992
    }
10993
 
10994
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
10995
      try {
10996
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
10997
      } catch (org.apache.thrift.TException te) {
10998
        throw new java.io.IOException(te);
10999
      }
11000
    }
11001
 
11002
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11003
      try {
11004
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11005
      } catch (org.apache.thrift.TException te) {
11006
        throw new java.io.IOException(te);
11007
      }
11008
    }
11009
 
11010
  }
11011
 
11012
  public static class getAllItemsForWarehouse_args implements org.apache.thrift.TBase<getAllItemsForWarehouse_args, getAllItemsForWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
11013
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemsForWarehouse_args");
11014
 
11015
    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);
11016
 
11017
    private long warehouse_id; // required
11018
 
11019
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11020
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11021
      WAREHOUSE_ID((short)1, "warehouse_id");
11022
 
11023
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11024
 
11025
      static {
11026
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11027
          byName.put(field.getFieldName(), field);
11028
        }
11029
      }
11030
 
11031
      /**
11032
       * Find the _Fields constant that matches fieldId, or null if its not found.
11033
       */
11034
      public static _Fields findByThriftId(int fieldId) {
11035
        switch(fieldId) {
11036
          case 1: // WAREHOUSE_ID
11037
            return WAREHOUSE_ID;
11038
          default:
11039
            return null;
11040
        }
11041
      }
11042
 
11043
      /**
11044
       * Find the _Fields constant that matches fieldId, throwing an exception
11045
       * if it is not found.
11046
       */
11047
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11048
        _Fields fields = findByThriftId(fieldId);
11049
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11050
        return fields;
11051
      }
11052
 
11053
      /**
11054
       * Find the _Fields constant that matches name, or null if its not found.
11055
       */
11056
      public static _Fields findByName(String name) {
11057
        return byName.get(name);
11058
      }
11059
 
11060
      private final short _thriftId;
11061
      private final String _fieldName;
11062
 
11063
      _Fields(short thriftId, String fieldName) {
11064
        _thriftId = thriftId;
11065
        _fieldName = fieldName;
11066
      }
11067
 
11068
      public short getThriftFieldId() {
11069
        return _thriftId;
11070
      }
11071
 
11072
      public String getFieldName() {
11073
        return _fieldName;
11074
      }
11075
    }
11076
 
11077
    // isset id assignments
11078
    private static final int __WAREHOUSE_ID_ISSET_ID = 0;
11079
    private BitSet __isset_bit_vector = new BitSet(1);
11080
 
11081
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11082
    static {
11083
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11084
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouse_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11085
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11086
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11087
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemsForWarehouse_args.class, metaDataMap);
11088
    }
11089
 
11090
    public getAllItemsForWarehouse_args() {
11091
    }
11092
 
11093
    public getAllItemsForWarehouse_args(
11094
      long warehouse_id)
11095
    {
11096
      this();
11097
      this.warehouse_id = warehouse_id;
11098
      setWarehouse_idIsSet(true);
11099
    }
11100
 
11101
    /**
11102
     * Performs a deep copy on <i>other</i>.
11103
     */
11104
    public getAllItemsForWarehouse_args(getAllItemsForWarehouse_args other) {
11105
      __isset_bit_vector.clear();
11106
      __isset_bit_vector.or(other.__isset_bit_vector);
11107
      this.warehouse_id = other.warehouse_id;
11108
    }
11109
 
11110
    public getAllItemsForWarehouse_args deepCopy() {
11111
      return new getAllItemsForWarehouse_args(this);
11112
    }
11113
 
11114
    @Override
11115
    public void clear() {
11116
      setWarehouse_idIsSet(false);
11117
      this.warehouse_id = 0;
11118
    }
11119
 
11120
    public long getWarehouse_id() {
11121
      return this.warehouse_id;
11122
    }
11123
 
11124
    public void setWarehouse_id(long warehouse_id) {
11125
      this.warehouse_id = warehouse_id;
11126
      setWarehouse_idIsSet(true);
11127
    }
11128
 
11129
    public void unsetWarehouse_id() {
11130
      __isset_bit_vector.clear(__WAREHOUSE_ID_ISSET_ID);
11131
    }
11132
 
11133
    /** Returns true if field warehouse_id is set (has been assigned a value) and false otherwise */
11134
    public boolean isSetWarehouse_id() {
11135
      return __isset_bit_vector.get(__WAREHOUSE_ID_ISSET_ID);
11136
    }
11137
 
11138
    public void setWarehouse_idIsSet(boolean value) {
11139
      __isset_bit_vector.set(__WAREHOUSE_ID_ISSET_ID, value);
11140
    }
11141
 
11142
    public void setFieldValue(_Fields field, Object value) {
11143
      switch (field) {
11144
      case WAREHOUSE_ID:
11145
        if (value == null) {
11146
          unsetWarehouse_id();
11147
        } else {
11148
          setWarehouse_id((Long)value);
11149
        }
11150
        break;
11151
 
11152
      }
11153
    }
11154
 
11155
    public Object getFieldValue(_Fields field) {
11156
      switch (field) {
11157
      case WAREHOUSE_ID:
11158
        return Long.valueOf(getWarehouse_id());
11159
 
11160
      }
11161
      throw new IllegalStateException();
11162
    }
11163
 
11164
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11165
    public boolean isSet(_Fields field) {
11166
      if (field == null) {
11167
        throw new IllegalArgumentException();
11168
      }
11169
 
11170
      switch (field) {
11171
      case WAREHOUSE_ID:
11172
        return isSetWarehouse_id();
11173
      }
11174
      throw new IllegalStateException();
11175
    }
11176
 
11177
    @Override
11178
    public boolean equals(Object that) {
11179
      if (that == null)
11180
        return false;
11181
      if (that instanceof getAllItemsForWarehouse_args)
11182
        return this.equals((getAllItemsForWarehouse_args)that);
11183
      return false;
11184
    }
11185
 
11186
    public boolean equals(getAllItemsForWarehouse_args that) {
11187
      if (that == null)
11188
        return false;
11189
 
11190
      boolean this_present_warehouse_id = true;
11191
      boolean that_present_warehouse_id = true;
11192
      if (this_present_warehouse_id || that_present_warehouse_id) {
11193
        if (!(this_present_warehouse_id && that_present_warehouse_id))
11194
          return false;
11195
        if (this.warehouse_id != that.warehouse_id)
11196
          return false;
11197
      }
11198
 
11199
      return true;
11200
    }
11201
 
11202
    @Override
11203
    public int hashCode() {
11204
      return 0;
11205
    }
11206
 
11207
    public int compareTo(getAllItemsForWarehouse_args other) {
11208
      if (!getClass().equals(other.getClass())) {
11209
        return getClass().getName().compareTo(other.getClass().getName());
11210
      }
11211
 
11212
      int lastComparison = 0;
11213
      getAllItemsForWarehouse_args typedOther = (getAllItemsForWarehouse_args)other;
11214
 
11215
      lastComparison = Boolean.valueOf(isSetWarehouse_id()).compareTo(typedOther.isSetWarehouse_id());
11216
      if (lastComparison != 0) {
11217
        return lastComparison;
11218
      }
11219
      if (isSetWarehouse_id()) {
11220
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouse_id, typedOther.warehouse_id);
11221
        if (lastComparison != 0) {
11222
          return lastComparison;
11223
        }
11224
      }
11225
      return 0;
11226
    }
11227
 
11228
    public _Fields fieldForId(int fieldId) {
11229
      return _Fields.findByThriftId(fieldId);
11230
    }
11231
 
11232
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11233
      org.apache.thrift.protocol.TField field;
11234
      iprot.readStructBegin();
11235
      while (true)
11236
      {
11237
        field = iprot.readFieldBegin();
11238
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11239
          break;
11240
        }
11241
        switch (field.id) {
11242
          case 1: // WAREHOUSE_ID
11243
            if (field.type == org.apache.thrift.protocol.TType.I64) {
11244
              this.warehouse_id = iprot.readI64();
11245
              setWarehouse_idIsSet(true);
11246
            } else { 
11247
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11248
            }
11249
            break;
11250
          default:
11251
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11252
        }
11253
        iprot.readFieldEnd();
11254
      }
11255
      iprot.readStructEnd();
11256
      validate();
11257
    }
11258
 
11259
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11260
      validate();
11261
 
11262
      oprot.writeStructBegin(STRUCT_DESC);
11263
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
11264
      oprot.writeI64(this.warehouse_id);
11265
      oprot.writeFieldEnd();
11266
      oprot.writeFieldStop();
11267
      oprot.writeStructEnd();
11268
    }
11269
 
11270
    @Override
11271
    public String toString() {
11272
      StringBuilder sb = new StringBuilder("getAllItemsForWarehouse_args(");
11273
      boolean first = true;
11274
 
11275
      sb.append("warehouse_id:");
11276
      sb.append(this.warehouse_id);
11277
      first = false;
11278
      sb.append(")");
11279
      return sb.toString();
11280
    }
11281
 
11282
    public void validate() throws org.apache.thrift.TException {
11283
      // check for required fields
11284
    }
11285
 
11286
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11287
      try {
11288
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11289
      } catch (org.apache.thrift.TException te) {
11290
        throw new java.io.IOException(te);
11291
      }
11292
    }
11293
 
11294
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11295
      try {
11296
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
11297
        __isset_bit_vector = new BitSet(1);
11298
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11299
      } catch (org.apache.thrift.TException te) {
11300
        throw new java.io.IOException(te);
11301
      }
11302
    }
11303
 
11304
  }
11305
 
11306
  public static class getAllItemsForWarehouse_result implements org.apache.thrift.TBase<getAllItemsForWarehouse_result, getAllItemsForWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
11307
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemsForWarehouse_result");
11308
 
11309
    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);
11310
    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);
11311
 
11312
    private List<Long> success; // required
11313
    private InventoryServiceException cex; // required
11314
 
11315
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11316
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11317
      SUCCESS((short)0, "success"),
11318
      CEX((short)1, "cex");
11319
 
11320
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11321
 
11322
      static {
11323
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11324
          byName.put(field.getFieldName(), field);
11325
        }
11326
      }
11327
 
11328
      /**
11329
       * Find the _Fields constant that matches fieldId, or null if its not found.
11330
       */
11331
      public static _Fields findByThriftId(int fieldId) {
11332
        switch(fieldId) {
11333
          case 0: // SUCCESS
11334
            return SUCCESS;
11335
          case 1: // CEX
11336
            return CEX;
11337
          default:
11338
            return null;
11339
        }
11340
      }
11341
 
11342
      /**
11343
       * Find the _Fields constant that matches fieldId, throwing an exception
11344
       * if it is not found.
11345
       */
11346
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11347
        _Fields fields = findByThriftId(fieldId);
11348
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11349
        return fields;
11350
      }
11351
 
11352
      /**
11353
       * Find the _Fields constant that matches name, or null if its not found.
11354
       */
11355
      public static _Fields findByName(String name) {
11356
        return byName.get(name);
11357
      }
11358
 
11359
      private final short _thriftId;
11360
      private final String _fieldName;
11361
 
11362
      _Fields(short thriftId, String fieldName) {
11363
        _thriftId = thriftId;
11364
        _fieldName = fieldName;
11365
      }
11366
 
11367
      public short getThriftFieldId() {
11368
        return _thriftId;
11369
      }
11370
 
11371
      public String getFieldName() {
11372
        return _fieldName;
11373
      }
11374
    }
11375
 
11376
    // isset id assignments
11377
 
11378
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11379
    static {
11380
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11381
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11382
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
11383
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
11384
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11385
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
11386
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11387
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemsForWarehouse_result.class, metaDataMap);
11388
    }
11389
 
11390
    public getAllItemsForWarehouse_result() {
11391
    }
11392
 
11393
    public getAllItemsForWarehouse_result(
11394
      List<Long> success,
11395
      InventoryServiceException cex)
11396
    {
11397
      this();
11398
      this.success = success;
11399
      this.cex = cex;
11400
    }
11401
 
11402
    /**
11403
     * Performs a deep copy on <i>other</i>.
11404
     */
11405
    public getAllItemsForWarehouse_result(getAllItemsForWarehouse_result other) {
11406
      if (other.isSetSuccess()) {
11407
        List<Long> __this__success = new ArrayList<Long>();
11408
        for (Long other_element : other.success) {
11409
          __this__success.add(other_element);
11410
        }
11411
        this.success = __this__success;
11412
      }
11413
      if (other.isSetCex()) {
11414
        this.cex = new InventoryServiceException(other.cex);
11415
      }
11416
    }
11417
 
11418
    public getAllItemsForWarehouse_result deepCopy() {
11419
      return new getAllItemsForWarehouse_result(this);
11420
    }
11421
 
11422
    @Override
11423
    public void clear() {
11424
      this.success = null;
11425
      this.cex = null;
11426
    }
11427
 
11428
    public int getSuccessSize() {
11429
      return (this.success == null) ? 0 : this.success.size();
11430
    }
11431
 
11432
    public java.util.Iterator<Long> getSuccessIterator() {
11433
      return (this.success == null) ? null : this.success.iterator();
11434
    }
11435
 
11436
    public void addToSuccess(long elem) {
11437
      if (this.success == null) {
11438
        this.success = new ArrayList<Long>();
11439
      }
11440
      this.success.add(elem);
11441
    }
11442
 
11443
    public List<Long> getSuccess() {
11444
      return this.success;
11445
    }
11446
 
11447
    public void setSuccess(List<Long> success) {
11448
      this.success = success;
11449
    }
11450
 
11451
    public void unsetSuccess() {
11452
      this.success = null;
11453
    }
11454
 
11455
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
11456
    public boolean isSetSuccess() {
11457
      return this.success != null;
11458
    }
11459
 
11460
    public void setSuccessIsSet(boolean value) {
11461
      if (!value) {
11462
        this.success = null;
11463
      }
11464
    }
11465
 
11466
    public InventoryServiceException getCex() {
11467
      return this.cex;
11468
    }
11469
 
11470
    public void setCex(InventoryServiceException cex) {
11471
      this.cex = cex;
11472
    }
11473
 
11474
    public void unsetCex() {
11475
      this.cex = null;
11476
    }
11477
 
11478
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
11479
    public boolean isSetCex() {
11480
      return this.cex != null;
11481
    }
11482
 
11483
    public void setCexIsSet(boolean value) {
11484
      if (!value) {
11485
        this.cex = null;
11486
      }
11487
    }
11488
 
11489
    public void setFieldValue(_Fields field, Object value) {
11490
      switch (field) {
11491
      case SUCCESS:
11492
        if (value == null) {
11493
          unsetSuccess();
11494
        } else {
11495
          setSuccess((List<Long>)value);
11496
        }
11497
        break;
11498
 
11499
      case CEX:
11500
        if (value == null) {
11501
          unsetCex();
11502
        } else {
11503
          setCex((InventoryServiceException)value);
11504
        }
11505
        break;
11506
 
11507
      }
11508
    }
11509
 
11510
    public Object getFieldValue(_Fields field) {
11511
      switch (field) {
11512
      case SUCCESS:
11513
        return getSuccess();
11514
 
11515
      case CEX:
11516
        return getCex();
11517
 
11518
      }
11519
      throw new IllegalStateException();
11520
    }
11521
 
11522
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
11523
    public boolean isSet(_Fields field) {
11524
      if (field == null) {
11525
        throw new IllegalArgumentException();
11526
      }
11527
 
11528
      switch (field) {
11529
      case SUCCESS:
11530
        return isSetSuccess();
11531
      case CEX:
11532
        return isSetCex();
11533
      }
11534
      throw new IllegalStateException();
11535
    }
11536
 
11537
    @Override
11538
    public boolean equals(Object that) {
11539
      if (that == null)
11540
        return false;
11541
      if (that instanceof getAllItemsForWarehouse_result)
11542
        return this.equals((getAllItemsForWarehouse_result)that);
11543
      return false;
11544
    }
11545
 
11546
    public boolean equals(getAllItemsForWarehouse_result that) {
11547
      if (that == null)
11548
        return false;
11549
 
11550
      boolean this_present_success = true && this.isSetSuccess();
11551
      boolean that_present_success = true && that.isSetSuccess();
11552
      if (this_present_success || that_present_success) {
11553
        if (!(this_present_success && that_present_success))
11554
          return false;
11555
        if (!this.success.equals(that.success))
11556
          return false;
11557
      }
11558
 
11559
      boolean this_present_cex = true && this.isSetCex();
11560
      boolean that_present_cex = true && that.isSetCex();
11561
      if (this_present_cex || that_present_cex) {
11562
        if (!(this_present_cex && that_present_cex))
11563
          return false;
11564
        if (!this.cex.equals(that.cex))
11565
          return false;
11566
      }
11567
 
11568
      return true;
11569
    }
11570
 
11571
    @Override
11572
    public int hashCode() {
11573
      return 0;
11574
    }
11575
 
11576
    public int compareTo(getAllItemsForWarehouse_result other) {
11577
      if (!getClass().equals(other.getClass())) {
11578
        return getClass().getName().compareTo(other.getClass().getName());
11579
      }
11580
 
11581
      int lastComparison = 0;
11582
      getAllItemsForWarehouse_result typedOther = (getAllItemsForWarehouse_result)other;
11583
 
11584
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
11585
      if (lastComparison != 0) {
11586
        return lastComparison;
11587
      }
11588
      if (isSetSuccess()) {
11589
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
11590
        if (lastComparison != 0) {
11591
          return lastComparison;
11592
        }
11593
      }
11594
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
11595
      if (lastComparison != 0) {
11596
        return lastComparison;
11597
      }
11598
      if (isSetCex()) {
11599
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
11600
        if (lastComparison != 0) {
11601
          return lastComparison;
11602
        }
11603
      }
11604
      return 0;
11605
    }
11606
 
11607
    public _Fields fieldForId(int fieldId) {
11608
      return _Fields.findByThriftId(fieldId);
11609
    }
11610
 
11611
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
11612
      org.apache.thrift.protocol.TField field;
11613
      iprot.readStructBegin();
11614
      while (true)
11615
      {
11616
        field = iprot.readFieldBegin();
11617
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
11618
          break;
11619
        }
11620
        switch (field.id) {
11621
          case 0: // SUCCESS
11622
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
11623
              {
11624
                org.apache.thrift.protocol.TList _list28 = iprot.readListBegin();
11625
                this.success = new ArrayList<Long>(_list28.size);
11626
                for (int _i29 = 0; _i29 < _list28.size; ++_i29)
11627
                {
11628
                  long _elem30; // required
11629
                  _elem30 = iprot.readI64();
11630
                  this.success.add(_elem30);
11631
                }
11632
                iprot.readListEnd();
11633
              }
11634
            } else { 
11635
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11636
            }
11637
            break;
11638
          case 1: // CEX
11639
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
11640
              this.cex = new InventoryServiceException();
11641
              this.cex.read(iprot);
11642
            } else { 
11643
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11644
            }
11645
            break;
11646
          default:
11647
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
11648
        }
11649
        iprot.readFieldEnd();
11650
      }
11651
      iprot.readStructEnd();
11652
      validate();
11653
    }
11654
 
11655
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
11656
      oprot.writeStructBegin(STRUCT_DESC);
11657
 
11658
      if (this.isSetSuccess()) {
11659
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
11660
        {
11661
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
11662
          for (long _iter31 : this.success)
11663
          {
11664
            oprot.writeI64(_iter31);
11665
          }
11666
          oprot.writeListEnd();
11667
        }
11668
        oprot.writeFieldEnd();
11669
      } else if (this.isSetCex()) {
11670
        oprot.writeFieldBegin(CEX_FIELD_DESC);
11671
        this.cex.write(oprot);
11672
        oprot.writeFieldEnd();
11673
      }
11674
      oprot.writeFieldStop();
11675
      oprot.writeStructEnd();
11676
    }
11677
 
11678
    @Override
11679
    public String toString() {
11680
      StringBuilder sb = new StringBuilder("getAllItemsForWarehouse_result(");
11681
      boolean first = true;
11682
 
11683
      sb.append("success:");
11684
      if (this.success == null) {
11685
        sb.append("null");
11686
      } else {
11687
        sb.append(this.success);
11688
      }
11689
      first = false;
11690
      if (!first) sb.append(", ");
11691
      sb.append("cex:");
11692
      if (this.cex == null) {
11693
        sb.append("null");
11694
      } else {
11695
        sb.append(this.cex);
11696
      }
11697
      first = false;
11698
      sb.append(")");
11699
      return sb.toString();
11700
    }
11701
 
11702
    public void validate() throws org.apache.thrift.TException {
11703
      // check for required fields
11704
    }
11705
 
11706
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
11707
      try {
11708
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
11709
      } catch (org.apache.thrift.TException te) {
11710
        throw new java.io.IOException(te);
11711
      }
11712
    }
11713
 
11714
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
11715
      try {
11716
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
11717
      } catch (org.apache.thrift.TException te) {
11718
        throw new java.io.IOException(te);
11719
      }
11720
    }
11721
 
11722
  }
11723
 
5967 rajveer 11724
  public static class isOrderBillable_args implements org.apache.thrift.TBase<isOrderBillable_args, isOrderBillable_args._Fields>, java.io.Serializable, Cloneable   {
11725
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("isOrderBillable_args");
11726
 
11727
    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);
11728
    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);
11729
    private static final org.apache.thrift.protocol.TField SOURCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sourceId", org.apache.thrift.protocol.TType.I64, (short)3);
11730
    private static final org.apache.thrift.protocol.TField ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("orderId", org.apache.thrift.protocol.TType.I64, (short)4);
11731
 
11732
    private long itemId; // required
11733
    private long warehouseId; // required
11734
    private long sourceId; // required
11735
    private long orderId; // required
11736
 
11737
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
11738
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
11739
      ITEM_ID((short)1, "itemId"),
11740
      WAREHOUSE_ID((short)2, "warehouseId"),
11741
      SOURCE_ID((short)3, "sourceId"),
11742
      ORDER_ID((short)4, "orderId");
11743
 
11744
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
11745
 
11746
      static {
11747
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
11748
          byName.put(field.getFieldName(), field);
11749
        }
11750
      }
11751
 
11752
      /**
11753
       * Find the _Fields constant that matches fieldId, or null if its not found.
11754
       */
11755
      public static _Fields findByThriftId(int fieldId) {
11756
        switch(fieldId) {
11757
          case 1: // ITEM_ID
11758
            return ITEM_ID;
11759
          case 2: // WAREHOUSE_ID
11760
            return WAREHOUSE_ID;
11761
          case 3: // SOURCE_ID
11762
            return SOURCE_ID;
11763
          case 4: // ORDER_ID
11764
            return ORDER_ID;
11765
          default:
11766
            return null;
11767
        }
11768
      }
11769
 
11770
      /**
11771
       * Find the _Fields constant that matches fieldId, throwing an exception
11772
       * if it is not found.
11773
       */
11774
      public static _Fields findByThriftIdOrThrow(int fieldId) {
11775
        _Fields fields = findByThriftId(fieldId);
11776
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
11777
        return fields;
11778
      }
11779
 
11780
      /**
11781
       * Find the _Fields constant that matches name, or null if its not found.
11782
       */
11783
      public static _Fields findByName(String name) {
11784
        return byName.get(name);
11785
      }
11786
 
11787
      private final short _thriftId;
11788
      private final String _fieldName;
11789
 
11790
      _Fields(short thriftId, String fieldName) {
11791
        _thriftId = thriftId;
11792
        _fieldName = fieldName;
11793
      }
11794
 
11795
      public short getThriftFieldId() {
11796
        return _thriftId;
11797
      }
11798
 
11799
      public String getFieldName() {
11800
        return _fieldName;
11801
      }
11802
    }
11803
 
11804
    // isset id assignments
11805
    private static final int __ITEMID_ISSET_ID = 0;
11806
    private static final int __WAREHOUSEID_ISSET_ID = 1;
11807
    private static final int __SOURCEID_ISSET_ID = 2;
11808
    private static final int __ORDERID_ISSET_ID = 3;
11809
    private BitSet __isset_bit_vector = new BitSet(4);
11810
 
11811
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
11812
    static {
11813
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
11814
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11815
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11816
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11817
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11818
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11819
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11820
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
11821
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
11822
      metaDataMap = Collections.unmodifiableMap(tmpMap);
11823
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(isOrderBillable_args.class, metaDataMap);
11824
    }
11825
 
11826
    public isOrderBillable_args() {
11827
    }
11828
 
11829
    public isOrderBillable_args(
11830
      long itemId,
11831
      long warehouseId,
11832
      long sourceId,
11833
      long orderId)
11834
    {
11835
      this();
11836
      this.itemId = itemId;
11837
      setItemIdIsSet(true);
11838
      this.warehouseId = warehouseId;
11839
      setWarehouseIdIsSet(true);
11840
      this.sourceId = sourceId;
11841
      setSourceIdIsSet(true);
11842
      this.orderId = orderId;
11843
      setOrderIdIsSet(true);
11844
    }
11845
 
11846
    /**
11847
     * Performs a deep copy on <i>other</i>.
11848
     */
11849
    public isOrderBillable_args(isOrderBillable_args other) {
11850
      __isset_bit_vector.clear();
11851
      __isset_bit_vector.or(other.__isset_bit_vector);
11852
      this.itemId = other.itemId;
11853
      this.warehouseId = other.warehouseId;
11854
      this.sourceId = other.sourceId;
11855
      this.orderId = other.orderId;
11856
    }
11857
 
11858
    public isOrderBillable_args deepCopy() {
11859
      return new isOrderBillable_args(this);
11860
    }
11861
 
11862
    @Override
11863
    public void clear() {
11864
      setItemIdIsSet(false);
11865
      this.itemId = 0;
11866
      setWarehouseIdIsSet(false);
11867
      this.warehouseId = 0;
11868
      setSourceIdIsSet(false);
11869
      this.sourceId = 0;
11870
      setOrderIdIsSet(false);
11871
      this.orderId = 0;
11872
    }
11873
 
11874
    public long getItemId() {
11875
      return this.itemId;
11876
    }
11877
 
11878
    public void setItemId(long itemId) {
11879
      this.itemId = itemId;
11880
      setItemIdIsSet(true);
11881
    }
11882
 
11883
    public void unsetItemId() {
11884
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
11885
    }
11886
 
11887
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
11888
    public boolean isSetItemId() {
11889
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
11890
    }
11891
 
11892
    public void setItemIdIsSet(boolean value) {
11893
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
11894
    }
11895
 
11896
    public long getWarehouseId() {
11897
      return this.warehouseId;
11898
    }
11899
 
11900
    public void setWarehouseId(long warehouseId) {
11901
      this.warehouseId = warehouseId;
11902
      setWarehouseIdIsSet(true);
11903
    }
11904
 
11905
    public void unsetWarehouseId() {
11906
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
11907
    }
11908
 
11909
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
11910
    public boolean isSetWarehouseId() {
11911
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
11912
    }
11913
 
11914
    public void setWarehouseIdIsSet(boolean value) {
11915
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
11916
    }
11917
 
11918
    public long getSourceId() {
11919
      return this.sourceId;
11920
    }
11921
 
11922
    public void setSourceId(long sourceId) {
11923
      this.sourceId = sourceId;
11924
      setSourceIdIsSet(true);
11925
    }
11926
 
11927
    public void unsetSourceId() {
11928
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
11929
    }
11930
 
11931
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
11932
    public boolean isSetSourceId() {
11933
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
11934
    }
11935
 
11936
    public void setSourceIdIsSet(boolean value) {
11937
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
11938
    }
11939
 
11940
    public long getOrderId() {
11941
      return this.orderId;
11942
    }
11943
 
11944
    public void setOrderId(long orderId) {
11945
      this.orderId = orderId;
11946
      setOrderIdIsSet(true);
11947
    }
11948
 
11949
    public void unsetOrderId() {
11950
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
11951
    }
11952
 
11953
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
11954
    public boolean isSetOrderId() {
11955
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
11956
    }
11957
 
11958
    public void setOrderIdIsSet(boolean value) {
11959
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
11960
    }
11961
 
11962
    public void setFieldValue(_Fields field, Object value) {
11963
      switch (field) {
11964
      case ITEM_ID:
11965
        if (value == null) {
11966
          unsetItemId();
11967
        } else {
11968
          setItemId((Long)value);
11969
        }
11970
        break;
11971
 
11972
      case WAREHOUSE_ID:
11973
        if (value == null) {
11974
          unsetWarehouseId();
11975
        } else {
11976
          setWarehouseId((Long)value);
11977
        }
11978
        break;
11979
 
11980
      case SOURCE_ID:
11981
        if (value == null) {
11982
          unsetSourceId();
11983
        } else {
11984
          setSourceId((Long)value);
11985
        }
11986
        break;
11987
 
11988
      case ORDER_ID:
11989
        if (value == null) {
11990
          unsetOrderId();
11991
        } else {
11992
          setOrderId((Long)value);
11993
        }
11994
        break;
11995
 
11996
      }
11997
    }
11998
 
11999
    public Object getFieldValue(_Fields field) {
12000
      switch (field) {
12001
      case ITEM_ID:
12002
        return Long.valueOf(getItemId());
12003
 
12004
      case WAREHOUSE_ID:
12005
        return Long.valueOf(getWarehouseId());
12006
 
12007
      case SOURCE_ID:
12008
        return Long.valueOf(getSourceId());
12009
 
12010
      case ORDER_ID:
12011
        return Long.valueOf(getOrderId());
12012
 
12013
      }
12014
      throw new IllegalStateException();
12015
    }
12016
 
12017
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12018
    public boolean isSet(_Fields field) {
12019
      if (field == null) {
12020
        throw new IllegalArgumentException();
12021
      }
12022
 
12023
      switch (field) {
12024
      case ITEM_ID:
12025
        return isSetItemId();
12026
      case WAREHOUSE_ID:
12027
        return isSetWarehouseId();
12028
      case SOURCE_ID:
12029
        return isSetSourceId();
12030
      case ORDER_ID:
12031
        return isSetOrderId();
12032
      }
12033
      throw new IllegalStateException();
12034
    }
12035
 
12036
    @Override
12037
    public boolean equals(Object that) {
12038
      if (that == null)
12039
        return false;
12040
      if (that instanceof isOrderBillable_args)
12041
        return this.equals((isOrderBillable_args)that);
12042
      return false;
12043
    }
12044
 
12045
    public boolean equals(isOrderBillable_args that) {
12046
      if (that == null)
12047
        return false;
12048
 
12049
      boolean this_present_itemId = true;
12050
      boolean that_present_itemId = true;
12051
      if (this_present_itemId || that_present_itemId) {
12052
        if (!(this_present_itemId && that_present_itemId))
12053
          return false;
12054
        if (this.itemId != that.itemId)
12055
          return false;
12056
      }
12057
 
12058
      boolean this_present_warehouseId = true;
12059
      boolean that_present_warehouseId = true;
12060
      if (this_present_warehouseId || that_present_warehouseId) {
12061
        if (!(this_present_warehouseId && that_present_warehouseId))
12062
          return false;
12063
        if (this.warehouseId != that.warehouseId)
12064
          return false;
12065
      }
12066
 
12067
      boolean this_present_sourceId = true;
12068
      boolean that_present_sourceId = true;
12069
      if (this_present_sourceId || that_present_sourceId) {
12070
        if (!(this_present_sourceId && that_present_sourceId))
12071
          return false;
12072
        if (this.sourceId != that.sourceId)
12073
          return false;
12074
      }
12075
 
12076
      boolean this_present_orderId = true;
12077
      boolean that_present_orderId = true;
12078
      if (this_present_orderId || that_present_orderId) {
12079
        if (!(this_present_orderId && that_present_orderId))
12080
          return false;
12081
        if (this.orderId != that.orderId)
12082
          return false;
12083
      }
12084
 
12085
      return true;
12086
    }
12087
 
12088
    @Override
12089
    public int hashCode() {
12090
      return 0;
12091
    }
12092
 
12093
    public int compareTo(isOrderBillable_args other) {
12094
      if (!getClass().equals(other.getClass())) {
12095
        return getClass().getName().compareTo(other.getClass().getName());
12096
      }
12097
 
12098
      int lastComparison = 0;
12099
      isOrderBillable_args typedOther = (isOrderBillable_args)other;
12100
 
12101
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
12102
      if (lastComparison != 0) {
12103
        return lastComparison;
12104
      }
12105
      if (isSetItemId()) {
12106
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
12107
        if (lastComparison != 0) {
12108
          return lastComparison;
12109
        }
12110
      }
12111
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
12112
      if (lastComparison != 0) {
12113
        return lastComparison;
12114
      }
12115
      if (isSetWarehouseId()) {
12116
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
12117
        if (lastComparison != 0) {
12118
          return lastComparison;
12119
        }
12120
      }
12121
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
12122
      if (lastComparison != 0) {
12123
        return lastComparison;
12124
      }
12125
      if (isSetSourceId()) {
12126
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
12127
        if (lastComparison != 0) {
12128
          return lastComparison;
12129
        }
12130
      }
12131
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
12132
      if (lastComparison != 0) {
12133
        return lastComparison;
12134
      }
12135
      if (isSetOrderId()) {
12136
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
12137
        if (lastComparison != 0) {
12138
          return lastComparison;
12139
        }
12140
      }
12141
      return 0;
12142
    }
12143
 
12144
    public _Fields fieldForId(int fieldId) {
12145
      return _Fields.findByThriftId(fieldId);
12146
    }
12147
 
12148
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12149
      org.apache.thrift.protocol.TField field;
12150
      iprot.readStructBegin();
12151
      while (true)
12152
      {
12153
        field = iprot.readFieldBegin();
12154
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12155
          break;
12156
        }
12157
        switch (field.id) {
12158
          case 1: // ITEM_ID
12159
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12160
              this.itemId = iprot.readI64();
12161
              setItemIdIsSet(true);
12162
            } else { 
12163
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12164
            }
12165
            break;
12166
          case 2: // WAREHOUSE_ID
12167
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12168
              this.warehouseId = iprot.readI64();
12169
              setWarehouseIdIsSet(true);
12170
            } else { 
12171
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12172
            }
12173
            break;
12174
          case 3: // SOURCE_ID
12175
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12176
              this.sourceId = iprot.readI64();
12177
              setSourceIdIsSet(true);
12178
            } else { 
12179
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12180
            }
12181
            break;
12182
          case 4: // ORDER_ID
12183
            if (field.type == org.apache.thrift.protocol.TType.I64) {
12184
              this.orderId = iprot.readI64();
12185
              setOrderIdIsSet(true);
12186
            } else { 
12187
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12188
            }
12189
            break;
12190
          default:
12191
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12192
        }
12193
        iprot.readFieldEnd();
12194
      }
12195
      iprot.readStructEnd();
12196
      validate();
12197
    }
12198
 
12199
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12200
      validate();
12201
 
12202
      oprot.writeStructBegin(STRUCT_DESC);
12203
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
12204
      oprot.writeI64(this.itemId);
12205
      oprot.writeFieldEnd();
12206
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
12207
      oprot.writeI64(this.warehouseId);
12208
      oprot.writeFieldEnd();
12209
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
12210
      oprot.writeI64(this.sourceId);
12211
      oprot.writeFieldEnd();
12212
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
12213
      oprot.writeI64(this.orderId);
12214
      oprot.writeFieldEnd();
12215
      oprot.writeFieldStop();
12216
      oprot.writeStructEnd();
12217
    }
12218
 
12219
    @Override
12220
    public String toString() {
12221
      StringBuilder sb = new StringBuilder("isOrderBillable_args(");
12222
      boolean first = true;
12223
 
12224
      sb.append("itemId:");
12225
      sb.append(this.itemId);
12226
      first = false;
12227
      if (!first) sb.append(", ");
12228
      sb.append("warehouseId:");
12229
      sb.append(this.warehouseId);
12230
      first = false;
12231
      if (!first) sb.append(", ");
12232
      sb.append("sourceId:");
12233
      sb.append(this.sourceId);
12234
      first = false;
12235
      if (!first) sb.append(", ");
12236
      sb.append("orderId:");
12237
      sb.append(this.orderId);
12238
      first = false;
12239
      sb.append(")");
12240
      return sb.toString();
12241
    }
12242
 
12243
    public void validate() throws org.apache.thrift.TException {
12244
      // check for required fields
12245
    }
12246
 
12247
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12248
      try {
12249
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12250
      } catch (org.apache.thrift.TException te) {
12251
        throw new java.io.IOException(te);
12252
      }
12253
    }
12254
 
12255
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12256
      try {
12257
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12258
      } catch (org.apache.thrift.TException te) {
12259
        throw new java.io.IOException(te);
12260
      }
12261
    }
12262
 
12263
  }
12264
 
12265
  public static class isOrderBillable_result implements org.apache.thrift.TBase<isOrderBillable_result, isOrderBillable_result._Fields>, java.io.Serializable, Cloneable   {
12266
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("isOrderBillable_result");
12267
 
12268
    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);
12269
 
12270
    private boolean success; // required
12271
 
12272
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12273
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12274
      SUCCESS((short)0, "success");
12275
 
12276
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12277
 
12278
      static {
12279
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12280
          byName.put(field.getFieldName(), field);
12281
        }
12282
      }
12283
 
12284
      /**
12285
       * Find the _Fields constant that matches fieldId, or null if its not found.
12286
       */
12287
      public static _Fields findByThriftId(int fieldId) {
12288
        switch(fieldId) {
12289
          case 0: // SUCCESS
12290
            return SUCCESS;
12291
          default:
12292
            return null;
12293
        }
12294
      }
12295
 
12296
      /**
12297
       * Find the _Fields constant that matches fieldId, throwing an exception
12298
       * if it is not found.
12299
       */
12300
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12301
        _Fields fields = findByThriftId(fieldId);
12302
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12303
        return fields;
12304
      }
12305
 
12306
      /**
12307
       * Find the _Fields constant that matches name, or null if its not found.
12308
       */
12309
      public static _Fields findByName(String name) {
12310
        return byName.get(name);
12311
      }
12312
 
12313
      private final short _thriftId;
12314
      private final String _fieldName;
12315
 
12316
      _Fields(short thriftId, String fieldName) {
12317
        _thriftId = thriftId;
12318
        _fieldName = fieldName;
12319
      }
12320
 
12321
      public short getThriftFieldId() {
12322
        return _thriftId;
12323
      }
12324
 
12325
      public String getFieldName() {
12326
        return _fieldName;
12327
      }
12328
    }
12329
 
12330
    // isset id assignments
12331
    private static final int __SUCCESS_ISSET_ID = 0;
12332
    private BitSet __isset_bit_vector = new BitSet(1);
12333
 
12334
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12335
    static {
12336
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12337
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12338
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
12339
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12340
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(isOrderBillable_result.class, metaDataMap);
12341
    }
12342
 
12343
    public isOrderBillable_result() {
12344
    }
12345
 
12346
    public isOrderBillable_result(
12347
      boolean success)
12348
    {
12349
      this();
12350
      this.success = success;
12351
      setSuccessIsSet(true);
12352
    }
12353
 
12354
    /**
12355
     * Performs a deep copy on <i>other</i>.
12356
     */
12357
    public isOrderBillable_result(isOrderBillable_result other) {
12358
      __isset_bit_vector.clear();
12359
      __isset_bit_vector.or(other.__isset_bit_vector);
12360
      this.success = other.success;
12361
    }
12362
 
12363
    public isOrderBillable_result deepCopy() {
12364
      return new isOrderBillable_result(this);
12365
    }
12366
 
12367
    @Override
12368
    public void clear() {
12369
      setSuccessIsSet(false);
12370
      this.success = false;
12371
    }
12372
 
12373
    public boolean isSuccess() {
12374
      return this.success;
12375
    }
12376
 
12377
    public void setSuccess(boolean success) {
12378
      this.success = success;
12379
      setSuccessIsSet(true);
12380
    }
12381
 
12382
    public void unsetSuccess() {
12383
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
12384
    }
12385
 
12386
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
12387
    public boolean isSetSuccess() {
12388
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
12389
    }
12390
 
12391
    public void setSuccessIsSet(boolean value) {
12392
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
12393
    }
12394
 
12395
    public void setFieldValue(_Fields field, Object value) {
12396
      switch (field) {
12397
      case SUCCESS:
12398
        if (value == null) {
12399
          unsetSuccess();
12400
        } else {
12401
          setSuccess((Boolean)value);
12402
        }
12403
        break;
12404
 
12405
      }
12406
    }
12407
 
12408
    public Object getFieldValue(_Fields field) {
12409
      switch (field) {
12410
      case SUCCESS:
12411
        return Boolean.valueOf(isSuccess());
12412
 
12413
      }
12414
      throw new IllegalStateException();
12415
    }
12416
 
12417
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12418
    public boolean isSet(_Fields field) {
12419
      if (field == null) {
12420
        throw new IllegalArgumentException();
12421
      }
12422
 
12423
      switch (field) {
12424
      case SUCCESS:
12425
        return isSetSuccess();
12426
      }
12427
      throw new IllegalStateException();
12428
    }
12429
 
12430
    @Override
12431
    public boolean equals(Object that) {
12432
      if (that == null)
12433
        return false;
12434
      if (that instanceof isOrderBillable_result)
12435
        return this.equals((isOrderBillable_result)that);
12436
      return false;
12437
    }
12438
 
12439
    public boolean equals(isOrderBillable_result that) {
12440
      if (that == null)
12441
        return false;
12442
 
12443
      boolean this_present_success = true;
12444
      boolean that_present_success = true;
12445
      if (this_present_success || that_present_success) {
12446
        if (!(this_present_success && that_present_success))
12447
          return false;
12448
        if (this.success != that.success)
12449
          return false;
12450
      }
12451
 
12452
      return true;
12453
    }
12454
 
12455
    @Override
12456
    public int hashCode() {
12457
      return 0;
12458
    }
12459
 
12460
    public int compareTo(isOrderBillable_result other) {
12461
      if (!getClass().equals(other.getClass())) {
12462
        return getClass().getName().compareTo(other.getClass().getName());
12463
      }
12464
 
12465
      int lastComparison = 0;
12466
      isOrderBillable_result typedOther = (isOrderBillable_result)other;
12467
 
12468
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
12469
      if (lastComparison != 0) {
12470
        return lastComparison;
12471
      }
12472
      if (isSetSuccess()) {
12473
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
12474
        if (lastComparison != 0) {
12475
          return lastComparison;
12476
        }
12477
      }
12478
      return 0;
12479
    }
12480
 
12481
    public _Fields fieldForId(int fieldId) {
12482
      return _Fields.findByThriftId(fieldId);
12483
    }
12484
 
12485
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
12486
      org.apache.thrift.protocol.TField field;
12487
      iprot.readStructBegin();
12488
      while (true)
12489
      {
12490
        field = iprot.readFieldBegin();
12491
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
12492
          break;
12493
        }
12494
        switch (field.id) {
12495
          case 0: // SUCCESS
12496
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
12497
              this.success = iprot.readBool();
12498
              setSuccessIsSet(true);
12499
            } else { 
12500
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12501
            }
12502
            break;
12503
          default:
12504
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
12505
        }
12506
        iprot.readFieldEnd();
12507
      }
12508
      iprot.readStructEnd();
12509
      validate();
12510
    }
12511
 
12512
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
12513
      oprot.writeStructBegin(STRUCT_DESC);
12514
 
12515
      if (this.isSetSuccess()) {
12516
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
12517
        oprot.writeBool(this.success);
12518
        oprot.writeFieldEnd();
12519
      }
12520
      oprot.writeFieldStop();
12521
      oprot.writeStructEnd();
12522
    }
12523
 
12524
    @Override
12525
    public String toString() {
12526
      StringBuilder sb = new StringBuilder("isOrderBillable_result(");
12527
      boolean first = true;
12528
 
12529
      sb.append("success:");
12530
      sb.append(this.success);
12531
      first = false;
12532
      sb.append(")");
12533
      return sb.toString();
12534
    }
12535
 
12536
    public void validate() throws org.apache.thrift.TException {
12537
      // check for required fields
12538
    }
12539
 
12540
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
12541
      try {
12542
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
12543
      } catch (org.apache.thrift.TException te) {
12544
        throw new java.io.IOException(te);
12545
      }
12546
    }
12547
 
12548
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
12549
      try {
12550
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
12551
      } catch (org.apache.thrift.TException te) {
12552
        throw new java.io.IOException(te);
12553
      }
12554
    }
12555
 
12556
  }
12557
 
5945 mandeep.dh 12558
  public static class reserveItemInWarehouse_args implements org.apache.thrift.TBase<reserveItemInWarehouse_args, reserveItemInWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
12559
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reserveItemInWarehouse_args");
12560
 
12561
    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);
12562
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouseId", org.apache.thrift.protocol.TType.I64, (short)2);
5967 rajveer 12563
    private static final org.apache.thrift.protocol.TField SOURCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sourceId", org.apache.thrift.protocol.TType.I64, (short)3);
12564
    private static final org.apache.thrift.protocol.TField ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("orderId", org.apache.thrift.protocol.TType.I64, (short)4);
12565
    private static final org.apache.thrift.protocol.TField CREATED_TIMESTAMP_FIELD_DESC = new org.apache.thrift.protocol.TField("createdTimestamp", org.apache.thrift.protocol.TType.I64, (short)5);
12566
    private static final org.apache.thrift.protocol.TField PROMISED_SHIPPING_TIMESTAMP_FIELD_DESC = new org.apache.thrift.protocol.TField("promisedShippingTimestamp", org.apache.thrift.protocol.TType.I64, (short)6);
12567
    private static final org.apache.thrift.protocol.TField QUANTITY_FIELD_DESC = new org.apache.thrift.protocol.TField("quantity", org.apache.thrift.protocol.TType.DOUBLE, (short)7);
5945 mandeep.dh 12568
 
12569
    private long itemId; // required
12570
    private long warehouseId; // required
5967 rajveer 12571
    private long sourceId; // required
12572
    private long orderId; // required
12573
    private long createdTimestamp; // required
12574
    private long promisedShippingTimestamp; // required
5945 mandeep.dh 12575
    private double quantity; // required
12576
 
12577
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
12578
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
12579
      ITEM_ID((short)1, "itemId"),
12580
      WAREHOUSE_ID((short)2, "warehouseId"),
5967 rajveer 12581
      SOURCE_ID((short)3, "sourceId"),
12582
      ORDER_ID((short)4, "orderId"),
12583
      CREATED_TIMESTAMP((short)5, "createdTimestamp"),
12584
      PROMISED_SHIPPING_TIMESTAMP((short)6, "promisedShippingTimestamp"),
12585
      QUANTITY((short)7, "quantity");
5945 mandeep.dh 12586
 
12587
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
12588
 
12589
      static {
12590
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
12591
          byName.put(field.getFieldName(), field);
12592
        }
12593
      }
12594
 
12595
      /**
12596
       * Find the _Fields constant that matches fieldId, or null if its not found.
12597
       */
12598
      public static _Fields findByThriftId(int fieldId) {
12599
        switch(fieldId) {
12600
          case 1: // ITEM_ID
12601
            return ITEM_ID;
12602
          case 2: // WAREHOUSE_ID
12603
            return WAREHOUSE_ID;
5967 rajveer 12604
          case 3: // SOURCE_ID
12605
            return SOURCE_ID;
12606
          case 4: // ORDER_ID
12607
            return ORDER_ID;
12608
          case 5: // CREATED_TIMESTAMP
12609
            return CREATED_TIMESTAMP;
12610
          case 6: // PROMISED_SHIPPING_TIMESTAMP
12611
            return PROMISED_SHIPPING_TIMESTAMP;
12612
          case 7: // QUANTITY
5945 mandeep.dh 12613
            return QUANTITY;
12614
          default:
12615
            return null;
12616
        }
12617
      }
12618
 
12619
      /**
12620
       * Find the _Fields constant that matches fieldId, throwing an exception
12621
       * if it is not found.
12622
       */
12623
      public static _Fields findByThriftIdOrThrow(int fieldId) {
12624
        _Fields fields = findByThriftId(fieldId);
12625
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
12626
        return fields;
12627
      }
12628
 
12629
      /**
12630
       * Find the _Fields constant that matches name, or null if its not found.
12631
       */
12632
      public static _Fields findByName(String name) {
12633
        return byName.get(name);
12634
      }
12635
 
12636
      private final short _thriftId;
12637
      private final String _fieldName;
12638
 
12639
      _Fields(short thriftId, String fieldName) {
12640
        _thriftId = thriftId;
12641
        _fieldName = fieldName;
12642
      }
12643
 
12644
      public short getThriftFieldId() {
12645
        return _thriftId;
12646
      }
12647
 
12648
      public String getFieldName() {
12649
        return _fieldName;
12650
      }
12651
    }
12652
 
12653
    // isset id assignments
12654
    private static final int __ITEMID_ISSET_ID = 0;
12655
    private static final int __WAREHOUSEID_ISSET_ID = 1;
5967 rajveer 12656
    private static final int __SOURCEID_ISSET_ID = 2;
12657
    private static final int __ORDERID_ISSET_ID = 3;
12658
    private static final int __CREATEDTIMESTAMP_ISSET_ID = 4;
12659
    private static final int __PROMISEDSHIPPINGTIMESTAMP_ISSET_ID = 5;
12660
    private static final int __QUANTITY_ISSET_ID = 6;
12661
    private BitSet __isset_bit_vector = new BitSet(7);
5945 mandeep.dh 12662
 
12663
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
12664
    static {
12665
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
12666
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12667
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12668
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12669
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5967 rajveer 12670
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12671
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12672
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12673
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12674
      tmpMap.put(_Fields.CREATED_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("createdTimestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12675
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
12676
      tmpMap.put(_Fields.PROMISED_SHIPPING_TIMESTAMP, new org.apache.thrift.meta_data.FieldMetaData("promisedShippingTimestamp", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12677
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5945 mandeep.dh 12678
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
12679
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
12680
      metaDataMap = Collections.unmodifiableMap(tmpMap);
12681
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reserveItemInWarehouse_args.class, metaDataMap);
12682
    }
12683
 
12684
    public reserveItemInWarehouse_args() {
12685
    }
12686
 
12687
    public reserveItemInWarehouse_args(
12688
      long itemId,
12689
      long warehouseId,
5967 rajveer 12690
      long sourceId,
12691
      long orderId,
12692
      long createdTimestamp,
12693
      long promisedShippingTimestamp,
5945 mandeep.dh 12694
      double quantity)
12695
    {
12696
      this();
12697
      this.itemId = itemId;
12698
      setItemIdIsSet(true);
12699
      this.warehouseId = warehouseId;
12700
      setWarehouseIdIsSet(true);
5967 rajveer 12701
      this.sourceId = sourceId;
12702
      setSourceIdIsSet(true);
12703
      this.orderId = orderId;
12704
      setOrderIdIsSet(true);
12705
      this.createdTimestamp = createdTimestamp;
12706
      setCreatedTimestampIsSet(true);
12707
      this.promisedShippingTimestamp = promisedShippingTimestamp;
12708
      setPromisedShippingTimestampIsSet(true);
5945 mandeep.dh 12709
      this.quantity = quantity;
12710
      setQuantityIsSet(true);
12711
    }
12712
 
12713
    /**
12714
     * Performs a deep copy on <i>other</i>.
12715
     */
12716
    public reserveItemInWarehouse_args(reserveItemInWarehouse_args other) {
12717
      __isset_bit_vector.clear();
12718
      __isset_bit_vector.or(other.__isset_bit_vector);
12719
      this.itemId = other.itemId;
12720
      this.warehouseId = other.warehouseId;
5967 rajveer 12721
      this.sourceId = other.sourceId;
12722
      this.orderId = other.orderId;
12723
      this.createdTimestamp = other.createdTimestamp;
12724
      this.promisedShippingTimestamp = other.promisedShippingTimestamp;
5945 mandeep.dh 12725
      this.quantity = other.quantity;
12726
    }
12727
 
12728
    public reserveItemInWarehouse_args deepCopy() {
12729
      return new reserveItemInWarehouse_args(this);
12730
    }
12731
 
12732
    @Override
12733
    public void clear() {
12734
      setItemIdIsSet(false);
12735
      this.itemId = 0;
12736
      setWarehouseIdIsSet(false);
12737
      this.warehouseId = 0;
5967 rajveer 12738
      setSourceIdIsSet(false);
12739
      this.sourceId = 0;
12740
      setOrderIdIsSet(false);
12741
      this.orderId = 0;
12742
      setCreatedTimestampIsSet(false);
12743
      this.createdTimestamp = 0;
12744
      setPromisedShippingTimestampIsSet(false);
12745
      this.promisedShippingTimestamp = 0;
5945 mandeep.dh 12746
      setQuantityIsSet(false);
12747
      this.quantity = 0.0;
12748
    }
12749
 
12750
    public long getItemId() {
12751
      return this.itemId;
12752
    }
12753
 
12754
    public void setItemId(long itemId) {
12755
      this.itemId = itemId;
12756
      setItemIdIsSet(true);
12757
    }
12758
 
12759
    public void unsetItemId() {
12760
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
12761
    }
12762
 
12763
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
12764
    public boolean isSetItemId() {
12765
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
12766
    }
12767
 
12768
    public void setItemIdIsSet(boolean value) {
12769
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
12770
    }
12771
 
12772
    public long getWarehouseId() {
12773
      return this.warehouseId;
12774
    }
12775
 
12776
    public void setWarehouseId(long warehouseId) {
12777
      this.warehouseId = warehouseId;
12778
      setWarehouseIdIsSet(true);
12779
    }
12780
 
12781
    public void unsetWarehouseId() {
12782
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
12783
    }
12784
 
12785
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
12786
    public boolean isSetWarehouseId() {
12787
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
12788
    }
12789
 
12790
    public void setWarehouseIdIsSet(boolean value) {
12791
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
12792
    }
12793
 
5967 rajveer 12794
    public long getSourceId() {
12795
      return this.sourceId;
12796
    }
12797
 
12798
    public void setSourceId(long sourceId) {
12799
      this.sourceId = sourceId;
12800
      setSourceIdIsSet(true);
12801
    }
12802
 
12803
    public void unsetSourceId() {
12804
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
12805
    }
12806
 
12807
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
12808
    public boolean isSetSourceId() {
12809
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
12810
    }
12811
 
12812
    public void setSourceIdIsSet(boolean value) {
12813
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
12814
    }
12815
 
12816
    public long getOrderId() {
12817
      return this.orderId;
12818
    }
12819
 
12820
    public void setOrderId(long orderId) {
12821
      this.orderId = orderId;
12822
      setOrderIdIsSet(true);
12823
    }
12824
 
12825
    public void unsetOrderId() {
12826
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
12827
    }
12828
 
12829
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
12830
    public boolean isSetOrderId() {
12831
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
12832
    }
12833
 
12834
    public void setOrderIdIsSet(boolean value) {
12835
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
12836
    }
12837
 
12838
    public long getCreatedTimestamp() {
12839
      return this.createdTimestamp;
12840
    }
12841
 
12842
    public void setCreatedTimestamp(long createdTimestamp) {
12843
      this.createdTimestamp = createdTimestamp;
12844
      setCreatedTimestampIsSet(true);
12845
    }
12846
 
12847
    public void unsetCreatedTimestamp() {
12848
      __isset_bit_vector.clear(__CREATEDTIMESTAMP_ISSET_ID);
12849
    }
12850
 
12851
    /** Returns true if field createdTimestamp is set (has been assigned a value) and false otherwise */
12852
    public boolean isSetCreatedTimestamp() {
12853
      return __isset_bit_vector.get(__CREATEDTIMESTAMP_ISSET_ID);
12854
    }
12855
 
12856
    public void setCreatedTimestampIsSet(boolean value) {
12857
      __isset_bit_vector.set(__CREATEDTIMESTAMP_ISSET_ID, value);
12858
    }
12859
 
12860
    public long getPromisedShippingTimestamp() {
12861
      return this.promisedShippingTimestamp;
12862
    }
12863
 
12864
    public void setPromisedShippingTimestamp(long promisedShippingTimestamp) {
12865
      this.promisedShippingTimestamp = promisedShippingTimestamp;
12866
      setPromisedShippingTimestampIsSet(true);
12867
    }
12868
 
12869
    public void unsetPromisedShippingTimestamp() {
12870
      __isset_bit_vector.clear(__PROMISEDSHIPPINGTIMESTAMP_ISSET_ID);
12871
    }
12872
 
12873
    /** Returns true if field promisedShippingTimestamp is set (has been assigned a value) and false otherwise */
12874
    public boolean isSetPromisedShippingTimestamp() {
12875
      return __isset_bit_vector.get(__PROMISEDSHIPPINGTIMESTAMP_ISSET_ID);
12876
    }
12877
 
12878
    public void setPromisedShippingTimestampIsSet(boolean value) {
12879
      __isset_bit_vector.set(__PROMISEDSHIPPINGTIMESTAMP_ISSET_ID, value);
12880
    }
12881
 
5945 mandeep.dh 12882
    public double getQuantity() {
12883
      return this.quantity;
12884
    }
12885
 
12886
    public void setQuantity(double quantity) {
12887
      this.quantity = quantity;
12888
      setQuantityIsSet(true);
12889
    }
12890
 
12891
    public void unsetQuantity() {
12892
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
12893
    }
12894
 
12895
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
12896
    public boolean isSetQuantity() {
12897
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
12898
    }
12899
 
12900
    public void setQuantityIsSet(boolean value) {
12901
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
12902
    }
12903
 
12904
    public void setFieldValue(_Fields field, Object value) {
12905
      switch (field) {
12906
      case ITEM_ID:
12907
        if (value == null) {
12908
          unsetItemId();
12909
        } else {
12910
          setItemId((Long)value);
12911
        }
12912
        break;
12913
 
12914
      case WAREHOUSE_ID:
12915
        if (value == null) {
12916
          unsetWarehouseId();
12917
        } else {
12918
          setWarehouseId((Long)value);
12919
        }
12920
        break;
12921
 
5967 rajveer 12922
      case SOURCE_ID:
12923
        if (value == null) {
12924
          unsetSourceId();
12925
        } else {
12926
          setSourceId((Long)value);
12927
        }
12928
        break;
12929
 
12930
      case ORDER_ID:
12931
        if (value == null) {
12932
          unsetOrderId();
12933
        } else {
12934
          setOrderId((Long)value);
12935
        }
12936
        break;
12937
 
12938
      case CREATED_TIMESTAMP:
12939
        if (value == null) {
12940
          unsetCreatedTimestamp();
12941
        } else {
12942
          setCreatedTimestamp((Long)value);
12943
        }
12944
        break;
12945
 
12946
      case PROMISED_SHIPPING_TIMESTAMP:
12947
        if (value == null) {
12948
          unsetPromisedShippingTimestamp();
12949
        } else {
12950
          setPromisedShippingTimestamp((Long)value);
12951
        }
12952
        break;
12953
 
5945 mandeep.dh 12954
      case QUANTITY:
12955
        if (value == null) {
12956
          unsetQuantity();
12957
        } else {
12958
          setQuantity((Double)value);
12959
        }
12960
        break;
12961
 
12962
      }
12963
    }
12964
 
12965
    public Object getFieldValue(_Fields field) {
12966
      switch (field) {
12967
      case ITEM_ID:
12968
        return Long.valueOf(getItemId());
12969
 
12970
      case WAREHOUSE_ID:
12971
        return Long.valueOf(getWarehouseId());
12972
 
5967 rajveer 12973
      case SOURCE_ID:
12974
        return Long.valueOf(getSourceId());
12975
 
12976
      case ORDER_ID:
12977
        return Long.valueOf(getOrderId());
12978
 
12979
      case CREATED_TIMESTAMP:
12980
        return Long.valueOf(getCreatedTimestamp());
12981
 
12982
      case PROMISED_SHIPPING_TIMESTAMP:
12983
        return Long.valueOf(getPromisedShippingTimestamp());
12984
 
5945 mandeep.dh 12985
      case QUANTITY:
12986
        return Double.valueOf(getQuantity());
12987
 
12988
      }
12989
      throw new IllegalStateException();
12990
    }
12991
 
12992
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
12993
    public boolean isSet(_Fields field) {
12994
      if (field == null) {
12995
        throw new IllegalArgumentException();
12996
      }
12997
 
12998
      switch (field) {
12999
      case ITEM_ID:
13000
        return isSetItemId();
13001
      case WAREHOUSE_ID:
13002
        return isSetWarehouseId();
5967 rajveer 13003
      case SOURCE_ID:
13004
        return isSetSourceId();
13005
      case ORDER_ID:
13006
        return isSetOrderId();
13007
      case CREATED_TIMESTAMP:
13008
        return isSetCreatedTimestamp();
13009
      case PROMISED_SHIPPING_TIMESTAMP:
13010
        return isSetPromisedShippingTimestamp();
5945 mandeep.dh 13011
      case QUANTITY:
13012
        return isSetQuantity();
13013
      }
13014
      throw new IllegalStateException();
13015
    }
13016
 
13017
    @Override
13018
    public boolean equals(Object that) {
13019
      if (that == null)
13020
        return false;
13021
      if (that instanceof reserveItemInWarehouse_args)
13022
        return this.equals((reserveItemInWarehouse_args)that);
13023
      return false;
13024
    }
13025
 
13026
    public boolean equals(reserveItemInWarehouse_args that) {
13027
      if (that == null)
13028
        return false;
13029
 
13030
      boolean this_present_itemId = true;
13031
      boolean that_present_itemId = true;
13032
      if (this_present_itemId || that_present_itemId) {
13033
        if (!(this_present_itemId && that_present_itemId))
13034
          return false;
13035
        if (this.itemId != that.itemId)
13036
          return false;
13037
      }
13038
 
13039
      boolean this_present_warehouseId = true;
13040
      boolean that_present_warehouseId = true;
13041
      if (this_present_warehouseId || that_present_warehouseId) {
13042
        if (!(this_present_warehouseId && that_present_warehouseId))
13043
          return false;
13044
        if (this.warehouseId != that.warehouseId)
13045
          return false;
13046
      }
13047
 
5967 rajveer 13048
      boolean this_present_sourceId = true;
13049
      boolean that_present_sourceId = true;
13050
      if (this_present_sourceId || that_present_sourceId) {
13051
        if (!(this_present_sourceId && that_present_sourceId))
13052
          return false;
13053
        if (this.sourceId != that.sourceId)
13054
          return false;
13055
      }
13056
 
13057
      boolean this_present_orderId = true;
13058
      boolean that_present_orderId = true;
13059
      if (this_present_orderId || that_present_orderId) {
13060
        if (!(this_present_orderId && that_present_orderId))
13061
          return false;
13062
        if (this.orderId != that.orderId)
13063
          return false;
13064
      }
13065
 
13066
      boolean this_present_createdTimestamp = true;
13067
      boolean that_present_createdTimestamp = true;
13068
      if (this_present_createdTimestamp || that_present_createdTimestamp) {
13069
        if (!(this_present_createdTimestamp && that_present_createdTimestamp))
13070
          return false;
13071
        if (this.createdTimestamp != that.createdTimestamp)
13072
          return false;
13073
      }
13074
 
13075
      boolean this_present_promisedShippingTimestamp = true;
13076
      boolean that_present_promisedShippingTimestamp = true;
13077
      if (this_present_promisedShippingTimestamp || that_present_promisedShippingTimestamp) {
13078
        if (!(this_present_promisedShippingTimestamp && that_present_promisedShippingTimestamp))
13079
          return false;
13080
        if (this.promisedShippingTimestamp != that.promisedShippingTimestamp)
13081
          return false;
13082
      }
13083
 
5945 mandeep.dh 13084
      boolean this_present_quantity = true;
13085
      boolean that_present_quantity = true;
13086
      if (this_present_quantity || that_present_quantity) {
13087
        if (!(this_present_quantity && that_present_quantity))
13088
          return false;
13089
        if (this.quantity != that.quantity)
13090
          return false;
13091
      }
13092
 
13093
      return true;
13094
    }
13095
 
13096
    @Override
13097
    public int hashCode() {
13098
      return 0;
13099
    }
13100
 
13101
    public int compareTo(reserveItemInWarehouse_args other) {
13102
      if (!getClass().equals(other.getClass())) {
13103
        return getClass().getName().compareTo(other.getClass().getName());
13104
      }
13105
 
13106
      int lastComparison = 0;
13107
      reserveItemInWarehouse_args typedOther = (reserveItemInWarehouse_args)other;
13108
 
13109
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
13110
      if (lastComparison != 0) {
13111
        return lastComparison;
13112
      }
13113
      if (isSetItemId()) {
13114
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
13115
        if (lastComparison != 0) {
13116
          return lastComparison;
13117
        }
13118
      }
13119
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
13120
      if (lastComparison != 0) {
13121
        return lastComparison;
13122
      }
13123
      if (isSetWarehouseId()) {
13124
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
13125
        if (lastComparison != 0) {
13126
          return lastComparison;
13127
        }
13128
      }
5967 rajveer 13129
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
13130
      if (lastComparison != 0) {
13131
        return lastComparison;
13132
      }
13133
      if (isSetSourceId()) {
13134
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
13135
        if (lastComparison != 0) {
13136
          return lastComparison;
13137
        }
13138
      }
13139
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
13140
      if (lastComparison != 0) {
13141
        return lastComparison;
13142
      }
13143
      if (isSetOrderId()) {
13144
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
13145
        if (lastComparison != 0) {
13146
          return lastComparison;
13147
        }
13148
      }
13149
      lastComparison = Boolean.valueOf(isSetCreatedTimestamp()).compareTo(typedOther.isSetCreatedTimestamp());
13150
      if (lastComparison != 0) {
13151
        return lastComparison;
13152
      }
13153
      if (isSetCreatedTimestamp()) {
13154
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.createdTimestamp, typedOther.createdTimestamp);
13155
        if (lastComparison != 0) {
13156
          return lastComparison;
13157
        }
13158
      }
13159
      lastComparison = Boolean.valueOf(isSetPromisedShippingTimestamp()).compareTo(typedOther.isSetPromisedShippingTimestamp());
13160
      if (lastComparison != 0) {
13161
        return lastComparison;
13162
      }
13163
      if (isSetPromisedShippingTimestamp()) {
13164
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.promisedShippingTimestamp, typedOther.promisedShippingTimestamp);
13165
        if (lastComparison != 0) {
13166
          return lastComparison;
13167
        }
13168
      }
5945 mandeep.dh 13169
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
13170
      if (lastComparison != 0) {
13171
        return lastComparison;
13172
      }
13173
      if (isSetQuantity()) {
13174
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
13175
        if (lastComparison != 0) {
13176
          return lastComparison;
13177
        }
13178
      }
13179
      return 0;
13180
    }
13181
 
13182
    public _Fields fieldForId(int fieldId) {
13183
      return _Fields.findByThriftId(fieldId);
13184
    }
13185
 
13186
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13187
      org.apache.thrift.protocol.TField field;
13188
      iprot.readStructBegin();
13189
      while (true)
13190
      {
13191
        field = iprot.readFieldBegin();
13192
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13193
          break;
13194
        }
13195
        switch (field.id) {
13196
          case 1: // ITEM_ID
13197
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13198
              this.itemId = iprot.readI64();
13199
              setItemIdIsSet(true);
13200
            } else { 
13201
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13202
            }
13203
            break;
13204
          case 2: // WAREHOUSE_ID
13205
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13206
              this.warehouseId = iprot.readI64();
13207
              setWarehouseIdIsSet(true);
13208
            } else { 
13209
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13210
            }
13211
            break;
5967 rajveer 13212
          case 3: // SOURCE_ID
13213
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13214
              this.sourceId = iprot.readI64();
13215
              setSourceIdIsSet(true);
13216
            } else { 
13217
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13218
            }
13219
            break;
13220
          case 4: // ORDER_ID
13221
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13222
              this.orderId = iprot.readI64();
13223
              setOrderIdIsSet(true);
13224
            } else { 
13225
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13226
            }
13227
            break;
13228
          case 5: // CREATED_TIMESTAMP
13229
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13230
              this.createdTimestamp = iprot.readI64();
13231
              setCreatedTimestampIsSet(true);
13232
            } else { 
13233
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13234
            }
13235
            break;
13236
          case 6: // PROMISED_SHIPPING_TIMESTAMP
13237
            if (field.type == org.apache.thrift.protocol.TType.I64) {
13238
              this.promisedShippingTimestamp = iprot.readI64();
13239
              setPromisedShippingTimestampIsSet(true);
13240
            } else { 
13241
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13242
            }
13243
            break;
13244
          case 7: // QUANTITY
5945 mandeep.dh 13245
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
13246
              this.quantity = iprot.readDouble();
13247
              setQuantityIsSet(true);
13248
            } else { 
13249
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13250
            }
13251
            break;
13252
          default:
13253
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13254
        }
13255
        iprot.readFieldEnd();
13256
      }
13257
      iprot.readStructEnd();
13258
      validate();
13259
    }
13260
 
13261
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13262
      validate();
13263
 
13264
      oprot.writeStructBegin(STRUCT_DESC);
13265
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
13266
      oprot.writeI64(this.itemId);
13267
      oprot.writeFieldEnd();
13268
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
13269
      oprot.writeI64(this.warehouseId);
13270
      oprot.writeFieldEnd();
5967 rajveer 13271
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
13272
      oprot.writeI64(this.sourceId);
13273
      oprot.writeFieldEnd();
13274
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
13275
      oprot.writeI64(this.orderId);
13276
      oprot.writeFieldEnd();
13277
      oprot.writeFieldBegin(CREATED_TIMESTAMP_FIELD_DESC);
13278
      oprot.writeI64(this.createdTimestamp);
13279
      oprot.writeFieldEnd();
13280
      oprot.writeFieldBegin(PROMISED_SHIPPING_TIMESTAMP_FIELD_DESC);
13281
      oprot.writeI64(this.promisedShippingTimestamp);
13282
      oprot.writeFieldEnd();
5945 mandeep.dh 13283
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
13284
      oprot.writeDouble(this.quantity);
13285
      oprot.writeFieldEnd();
13286
      oprot.writeFieldStop();
13287
      oprot.writeStructEnd();
13288
    }
13289
 
13290
    @Override
13291
    public String toString() {
13292
      StringBuilder sb = new StringBuilder("reserveItemInWarehouse_args(");
13293
      boolean first = true;
13294
 
13295
      sb.append("itemId:");
13296
      sb.append(this.itemId);
13297
      first = false;
13298
      if (!first) sb.append(", ");
13299
      sb.append("warehouseId:");
13300
      sb.append(this.warehouseId);
13301
      first = false;
13302
      if (!first) sb.append(", ");
5967 rajveer 13303
      sb.append("sourceId:");
13304
      sb.append(this.sourceId);
13305
      first = false;
13306
      if (!first) sb.append(", ");
13307
      sb.append("orderId:");
13308
      sb.append(this.orderId);
13309
      first = false;
13310
      if (!first) sb.append(", ");
13311
      sb.append("createdTimestamp:");
13312
      sb.append(this.createdTimestamp);
13313
      first = false;
13314
      if (!first) sb.append(", ");
13315
      sb.append("promisedShippingTimestamp:");
13316
      sb.append(this.promisedShippingTimestamp);
13317
      first = false;
13318
      if (!first) sb.append(", ");
5945 mandeep.dh 13319
      sb.append("quantity:");
13320
      sb.append(this.quantity);
13321
      first = false;
13322
      sb.append(")");
13323
      return sb.toString();
13324
    }
13325
 
13326
    public void validate() throws org.apache.thrift.TException {
13327
      // check for required fields
13328
    }
13329
 
13330
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13331
      try {
13332
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13333
      } catch (org.apache.thrift.TException te) {
13334
        throw new java.io.IOException(te);
13335
      }
13336
    }
13337
 
13338
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13339
      try {
13340
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13341
      } catch (org.apache.thrift.TException te) {
13342
        throw new java.io.IOException(te);
13343
      }
13344
    }
13345
 
13346
  }
13347
 
13348
  public static class reserveItemInWarehouse_result implements org.apache.thrift.TBase<reserveItemInWarehouse_result, reserveItemInWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
13349
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reserveItemInWarehouse_result");
13350
 
13351
    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);
13352
    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);
13353
 
13354
    private boolean success; // required
13355
    private InventoryServiceException cex; // required
13356
 
13357
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13358
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13359
      SUCCESS((short)0, "success"),
13360
      CEX((short)1, "cex");
13361
 
13362
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13363
 
13364
      static {
13365
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13366
          byName.put(field.getFieldName(), field);
13367
        }
13368
      }
13369
 
13370
      /**
13371
       * Find the _Fields constant that matches fieldId, or null if its not found.
13372
       */
13373
      public static _Fields findByThriftId(int fieldId) {
13374
        switch(fieldId) {
13375
          case 0: // SUCCESS
13376
            return SUCCESS;
13377
          case 1: // CEX
13378
            return CEX;
13379
          default:
13380
            return null;
13381
        }
13382
      }
13383
 
13384
      /**
13385
       * Find the _Fields constant that matches fieldId, throwing an exception
13386
       * if it is not found.
13387
       */
13388
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13389
        _Fields fields = findByThriftId(fieldId);
13390
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13391
        return fields;
13392
      }
13393
 
13394
      /**
13395
       * Find the _Fields constant that matches name, or null if its not found.
13396
       */
13397
      public static _Fields findByName(String name) {
13398
        return byName.get(name);
13399
      }
13400
 
13401
      private final short _thriftId;
13402
      private final String _fieldName;
13403
 
13404
      _Fields(short thriftId, String fieldName) {
13405
        _thriftId = thriftId;
13406
        _fieldName = fieldName;
13407
      }
13408
 
13409
      public short getThriftFieldId() {
13410
        return _thriftId;
13411
      }
13412
 
13413
      public String getFieldName() {
13414
        return _fieldName;
13415
      }
13416
    }
13417
 
13418
    // isset id assignments
13419
    private static final int __SUCCESS_ISSET_ID = 0;
13420
    private BitSet __isset_bit_vector = new BitSet(1);
13421
 
13422
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13423
    static {
13424
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13425
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13426
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
13427
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13428
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
13429
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13430
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reserveItemInWarehouse_result.class, metaDataMap);
13431
    }
13432
 
13433
    public reserveItemInWarehouse_result() {
13434
    }
13435
 
13436
    public reserveItemInWarehouse_result(
13437
      boolean success,
13438
      InventoryServiceException cex)
13439
    {
13440
      this();
13441
      this.success = success;
13442
      setSuccessIsSet(true);
13443
      this.cex = cex;
13444
    }
13445
 
13446
    /**
13447
     * Performs a deep copy on <i>other</i>.
13448
     */
13449
    public reserveItemInWarehouse_result(reserveItemInWarehouse_result other) {
13450
      __isset_bit_vector.clear();
13451
      __isset_bit_vector.or(other.__isset_bit_vector);
13452
      this.success = other.success;
13453
      if (other.isSetCex()) {
13454
        this.cex = new InventoryServiceException(other.cex);
13455
      }
13456
    }
13457
 
13458
    public reserveItemInWarehouse_result deepCopy() {
13459
      return new reserveItemInWarehouse_result(this);
13460
    }
13461
 
13462
    @Override
13463
    public void clear() {
13464
      setSuccessIsSet(false);
13465
      this.success = false;
13466
      this.cex = null;
13467
    }
13468
 
13469
    public boolean isSuccess() {
13470
      return this.success;
13471
    }
13472
 
13473
    public void setSuccess(boolean success) {
13474
      this.success = success;
13475
      setSuccessIsSet(true);
13476
    }
13477
 
13478
    public void unsetSuccess() {
13479
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
13480
    }
13481
 
13482
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
13483
    public boolean isSetSuccess() {
13484
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
13485
    }
13486
 
13487
    public void setSuccessIsSet(boolean value) {
13488
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
13489
    }
13490
 
13491
    public InventoryServiceException getCex() {
13492
      return this.cex;
13493
    }
13494
 
13495
    public void setCex(InventoryServiceException cex) {
13496
      this.cex = cex;
13497
    }
13498
 
13499
    public void unsetCex() {
13500
      this.cex = null;
13501
    }
13502
 
13503
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
13504
    public boolean isSetCex() {
13505
      return this.cex != null;
13506
    }
13507
 
13508
    public void setCexIsSet(boolean value) {
13509
      if (!value) {
13510
        this.cex = null;
13511
      }
13512
    }
13513
 
13514
    public void setFieldValue(_Fields field, Object value) {
13515
      switch (field) {
13516
      case SUCCESS:
13517
        if (value == null) {
13518
          unsetSuccess();
13519
        } else {
13520
          setSuccess((Boolean)value);
13521
        }
13522
        break;
13523
 
13524
      case CEX:
13525
        if (value == null) {
13526
          unsetCex();
13527
        } else {
13528
          setCex((InventoryServiceException)value);
13529
        }
13530
        break;
13531
 
13532
      }
13533
    }
13534
 
13535
    public Object getFieldValue(_Fields field) {
13536
      switch (field) {
13537
      case SUCCESS:
13538
        return Boolean.valueOf(isSuccess());
13539
 
13540
      case CEX:
13541
        return getCex();
13542
 
13543
      }
13544
      throw new IllegalStateException();
13545
    }
13546
 
13547
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
13548
    public boolean isSet(_Fields field) {
13549
      if (field == null) {
13550
        throw new IllegalArgumentException();
13551
      }
13552
 
13553
      switch (field) {
13554
      case SUCCESS:
13555
        return isSetSuccess();
13556
      case CEX:
13557
        return isSetCex();
13558
      }
13559
      throw new IllegalStateException();
13560
    }
13561
 
13562
    @Override
13563
    public boolean equals(Object that) {
13564
      if (that == null)
13565
        return false;
13566
      if (that instanceof reserveItemInWarehouse_result)
13567
        return this.equals((reserveItemInWarehouse_result)that);
13568
      return false;
13569
    }
13570
 
13571
    public boolean equals(reserveItemInWarehouse_result that) {
13572
      if (that == null)
13573
        return false;
13574
 
13575
      boolean this_present_success = true;
13576
      boolean that_present_success = true;
13577
      if (this_present_success || that_present_success) {
13578
        if (!(this_present_success && that_present_success))
13579
          return false;
13580
        if (this.success != that.success)
13581
          return false;
13582
      }
13583
 
13584
      boolean this_present_cex = true && this.isSetCex();
13585
      boolean that_present_cex = true && that.isSetCex();
13586
      if (this_present_cex || that_present_cex) {
13587
        if (!(this_present_cex && that_present_cex))
13588
          return false;
13589
        if (!this.cex.equals(that.cex))
13590
          return false;
13591
      }
13592
 
13593
      return true;
13594
    }
13595
 
13596
    @Override
13597
    public int hashCode() {
13598
      return 0;
13599
    }
13600
 
13601
    public int compareTo(reserveItemInWarehouse_result other) {
13602
      if (!getClass().equals(other.getClass())) {
13603
        return getClass().getName().compareTo(other.getClass().getName());
13604
      }
13605
 
13606
      int lastComparison = 0;
13607
      reserveItemInWarehouse_result typedOther = (reserveItemInWarehouse_result)other;
13608
 
13609
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
13610
      if (lastComparison != 0) {
13611
        return lastComparison;
13612
      }
13613
      if (isSetSuccess()) {
13614
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
13615
        if (lastComparison != 0) {
13616
          return lastComparison;
13617
        }
13618
      }
13619
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
13620
      if (lastComparison != 0) {
13621
        return lastComparison;
13622
      }
13623
      if (isSetCex()) {
13624
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
13625
        if (lastComparison != 0) {
13626
          return lastComparison;
13627
        }
13628
      }
13629
      return 0;
13630
    }
13631
 
13632
    public _Fields fieldForId(int fieldId) {
13633
      return _Fields.findByThriftId(fieldId);
13634
    }
13635
 
13636
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
13637
      org.apache.thrift.protocol.TField field;
13638
      iprot.readStructBegin();
13639
      while (true)
13640
      {
13641
        field = iprot.readFieldBegin();
13642
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
13643
          break;
13644
        }
13645
        switch (field.id) {
13646
          case 0: // SUCCESS
13647
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
13648
              this.success = iprot.readBool();
13649
              setSuccessIsSet(true);
13650
            } else { 
13651
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13652
            }
13653
            break;
13654
          case 1: // CEX
13655
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
13656
              this.cex = new InventoryServiceException();
13657
              this.cex.read(iprot);
13658
            } else { 
13659
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13660
            }
13661
            break;
13662
          default:
13663
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
13664
        }
13665
        iprot.readFieldEnd();
13666
      }
13667
      iprot.readStructEnd();
13668
      validate();
13669
    }
13670
 
13671
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
13672
      oprot.writeStructBegin(STRUCT_DESC);
13673
 
13674
      if (this.isSetSuccess()) {
13675
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
13676
        oprot.writeBool(this.success);
13677
        oprot.writeFieldEnd();
13678
      } else if (this.isSetCex()) {
13679
        oprot.writeFieldBegin(CEX_FIELD_DESC);
13680
        this.cex.write(oprot);
13681
        oprot.writeFieldEnd();
13682
      }
13683
      oprot.writeFieldStop();
13684
      oprot.writeStructEnd();
13685
    }
13686
 
13687
    @Override
13688
    public String toString() {
13689
      StringBuilder sb = new StringBuilder("reserveItemInWarehouse_result(");
13690
      boolean first = true;
13691
 
13692
      sb.append("success:");
13693
      sb.append(this.success);
13694
      first = false;
13695
      if (!first) sb.append(", ");
13696
      sb.append("cex:");
13697
      if (this.cex == null) {
13698
        sb.append("null");
13699
      } else {
13700
        sb.append(this.cex);
13701
      }
13702
      first = false;
13703
      sb.append(")");
13704
      return sb.toString();
13705
    }
13706
 
13707
    public void validate() throws org.apache.thrift.TException {
13708
      // check for required fields
13709
    }
13710
 
13711
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
13712
      try {
13713
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
13714
      } catch (org.apache.thrift.TException te) {
13715
        throw new java.io.IOException(te);
13716
      }
13717
    }
13718
 
13719
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
13720
      try {
13721
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
13722
      } catch (org.apache.thrift.TException te) {
13723
        throw new java.io.IOException(te);
13724
      }
13725
    }
13726
 
13727
  }
13728
 
13729
  public static class reduceReservationCount_args implements org.apache.thrift.TBase<reduceReservationCount_args, reduceReservationCount_args._Fields>, java.io.Serializable, Cloneable   {
13730
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reduceReservationCount_args");
13731
 
13732
    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);
13733
    private static final org.apache.thrift.protocol.TField WAREHOUSE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("warehouseId", org.apache.thrift.protocol.TType.I64, (short)2);
5967 rajveer 13734
    private static final org.apache.thrift.protocol.TField SOURCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("sourceId", org.apache.thrift.protocol.TType.I64, (short)3);
13735
    private static final org.apache.thrift.protocol.TField ORDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("orderId", org.apache.thrift.protocol.TType.I64, (short)4);
13736
    private static final org.apache.thrift.protocol.TField QUANTITY_FIELD_DESC = new org.apache.thrift.protocol.TField("quantity", org.apache.thrift.protocol.TType.DOUBLE, (short)5);
5945 mandeep.dh 13737
 
13738
    private long itemId; // required
13739
    private long warehouseId; // required
5967 rajveer 13740
    private long sourceId; // required
13741
    private long orderId; // required
5945 mandeep.dh 13742
    private double quantity; // required
13743
 
13744
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
13745
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
13746
      ITEM_ID((short)1, "itemId"),
13747
      WAREHOUSE_ID((short)2, "warehouseId"),
5967 rajveer 13748
      SOURCE_ID((short)3, "sourceId"),
13749
      ORDER_ID((short)4, "orderId"),
13750
      QUANTITY((short)5, "quantity");
5945 mandeep.dh 13751
 
13752
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
13753
 
13754
      static {
13755
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
13756
          byName.put(field.getFieldName(), field);
13757
        }
13758
      }
13759
 
13760
      /**
13761
       * Find the _Fields constant that matches fieldId, or null if its not found.
13762
       */
13763
      public static _Fields findByThriftId(int fieldId) {
13764
        switch(fieldId) {
13765
          case 1: // ITEM_ID
13766
            return ITEM_ID;
13767
          case 2: // WAREHOUSE_ID
13768
            return WAREHOUSE_ID;
5967 rajveer 13769
          case 3: // SOURCE_ID
13770
            return SOURCE_ID;
13771
          case 4: // ORDER_ID
13772
            return ORDER_ID;
13773
          case 5: // QUANTITY
5945 mandeep.dh 13774
            return QUANTITY;
13775
          default:
13776
            return null;
13777
        }
13778
      }
13779
 
13780
      /**
13781
       * Find the _Fields constant that matches fieldId, throwing an exception
13782
       * if it is not found.
13783
       */
13784
      public static _Fields findByThriftIdOrThrow(int fieldId) {
13785
        _Fields fields = findByThriftId(fieldId);
13786
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
13787
        return fields;
13788
      }
13789
 
13790
      /**
13791
       * Find the _Fields constant that matches name, or null if its not found.
13792
       */
13793
      public static _Fields findByName(String name) {
13794
        return byName.get(name);
13795
      }
13796
 
13797
      private final short _thriftId;
13798
      private final String _fieldName;
13799
 
13800
      _Fields(short thriftId, String fieldName) {
13801
        _thriftId = thriftId;
13802
        _fieldName = fieldName;
13803
      }
13804
 
13805
      public short getThriftFieldId() {
13806
        return _thriftId;
13807
      }
13808
 
13809
      public String getFieldName() {
13810
        return _fieldName;
13811
      }
13812
    }
13813
 
13814
    // isset id assignments
13815
    private static final int __ITEMID_ISSET_ID = 0;
13816
    private static final int __WAREHOUSEID_ISSET_ID = 1;
5967 rajveer 13817
    private static final int __SOURCEID_ISSET_ID = 2;
13818
    private static final int __ORDERID_ISSET_ID = 3;
13819
    private static final int __QUANTITY_ISSET_ID = 4;
13820
    private BitSet __isset_bit_vector = new BitSet(5);
5945 mandeep.dh 13821
 
13822
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
13823
    static {
13824
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
13825
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13826
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13827
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13828
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5967 rajveer 13829
      tmpMap.put(_Fields.SOURCE_ID, new org.apache.thrift.meta_data.FieldMetaData("sourceId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13830
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
13831
      tmpMap.put(_Fields.ORDER_ID, new org.apache.thrift.meta_data.FieldMetaData("orderId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13832
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5945 mandeep.dh 13833
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
13834
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.DOUBLE)));
13835
      metaDataMap = Collections.unmodifiableMap(tmpMap);
13836
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reduceReservationCount_args.class, metaDataMap);
13837
    }
13838
 
13839
    public reduceReservationCount_args() {
13840
    }
13841
 
13842
    public reduceReservationCount_args(
13843
      long itemId,
13844
      long warehouseId,
5967 rajveer 13845
      long sourceId,
13846
      long orderId,
5945 mandeep.dh 13847
      double quantity)
13848
    {
13849
      this();
13850
      this.itemId = itemId;
13851
      setItemIdIsSet(true);
13852
      this.warehouseId = warehouseId;
13853
      setWarehouseIdIsSet(true);
5967 rajveer 13854
      this.sourceId = sourceId;
13855
      setSourceIdIsSet(true);
13856
      this.orderId = orderId;
13857
      setOrderIdIsSet(true);
5945 mandeep.dh 13858
      this.quantity = quantity;
13859
      setQuantityIsSet(true);
13860
    }
13861
 
13862
    /**
13863
     * Performs a deep copy on <i>other</i>.
13864
     */
13865
    public reduceReservationCount_args(reduceReservationCount_args other) {
13866
      __isset_bit_vector.clear();
13867
      __isset_bit_vector.or(other.__isset_bit_vector);
13868
      this.itemId = other.itemId;
13869
      this.warehouseId = other.warehouseId;
5967 rajveer 13870
      this.sourceId = other.sourceId;
13871
      this.orderId = other.orderId;
5945 mandeep.dh 13872
      this.quantity = other.quantity;
13873
    }
13874
 
13875
    public reduceReservationCount_args deepCopy() {
13876
      return new reduceReservationCount_args(this);
13877
    }
13878
 
13879
    @Override
13880
    public void clear() {
13881
      setItemIdIsSet(false);
13882
      this.itemId = 0;
13883
      setWarehouseIdIsSet(false);
13884
      this.warehouseId = 0;
5967 rajveer 13885
      setSourceIdIsSet(false);
13886
      this.sourceId = 0;
13887
      setOrderIdIsSet(false);
13888
      this.orderId = 0;
5945 mandeep.dh 13889
      setQuantityIsSet(false);
13890
      this.quantity = 0.0;
13891
    }
13892
 
13893
    public long getItemId() {
13894
      return this.itemId;
13895
    }
13896
 
13897
    public void setItemId(long itemId) {
13898
      this.itemId = itemId;
13899
      setItemIdIsSet(true);
13900
    }
13901
 
13902
    public void unsetItemId() {
13903
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
13904
    }
13905
 
13906
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
13907
    public boolean isSetItemId() {
13908
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
13909
    }
13910
 
13911
    public void setItemIdIsSet(boolean value) {
13912
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
13913
    }
13914
 
13915
    public long getWarehouseId() {
13916
      return this.warehouseId;
13917
    }
13918
 
13919
    public void setWarehouseId(long warehouseId) {
13920
      this.warehouseId = warehouseId;
13921
      setWarehouseIdIsSet(true);
13922
    }
13923
 
13924
    public void unsetWarehouseId() {
13925
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
13926
    }
13927
 
13928
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
13929
    public boolean isSetWarehouseId() {
13930
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
13931
    }
13932
 
13933
    public void setWarehouseIdIsSet(boolean value) {
13934
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
13935
    }
13936
 
5967 rajveer 13937
    public long getSourceId() {
13938
      return this.sourceId;
13939
    }
13940
 
13941
    public void setSourceId(long sourceId) {
13942
      this.sourceId = sourceId;
13943
      setSourceIdIsSet(true);
13944
    }
13945
 
13946
    public void unsetSourceId() {
13947
      __isset_bit_vector.clear(__SOURCEID_ISSET_ID);
13948
    }
13949
 
13950
    /** Returns true if field sourceId is set (has been assigned a value) and false otherwise */
13951
    public boolean isSetSourceId() {
13952
      return __isset_bit_vector.get(__SOURCEID_ISSET_ID);
13953
    }
13954
 
13955
    public void setSourceIdIsSet(boolean value) {
13956
      __isset_bit_vector.set(__SOURCEID_ISSET_ID, value);
13957
    }
13958
 
13959
    public long getOrderId() {
13960
      return this.orderId;
13961
    }
13962
 
13963
    public void setOrderId(long orderId) {
13964
      this.orderId = orderId;
13965
      setOrderIdIsSet(true);
13966
    }
13967
 
13968
    public void unsetOrderId() {
13969
      __isset_bit_vector.clear(__ORDERID_ISSET_ID);
13970
    }
13971
 
13972
    /** Returns true if field orderId is set (has been assigned a value) and false otherwise */
13973
    public boolean isSetOrderId() {
13974
      return __isset_bit_vector.get(__ORDERID_ISSET_ID);
13975
    }
13976
 
13977
    public void setOrderIdIsSet(boolean value) {
13978
      __isset_bit_vector.set(__ORDERID_ISSET_ID, value);
13979
    }
13980
 
5945 mandeep.dh 13981
    public double getQuantity() {
13982
      return this.quantity;
13983
    }
13984
 
13985
    public void setQuantity(double quantity) {
13986
      this.quantity = quantity;
13987
      setQuantityIsSet(true);
13988
    }
13989
 
13990
    public void unsetQuantity() {
13991
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
13992
    }
13993
 
13994
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
13995
    public boolean isSetQuantity() {
13996
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
13997
    }
13998
 
13999
    public void setQuantityIsSet(boolean value) {
14000
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
14001
    }
14002
 
14003
    public void setFieldValue(_Fields field, Object value) {
14004
      switch (field) {
14005
      case ITEM_ID:
14006
        if (value == null) {
14007
          unsetItemId();
14008
        } else {
14009
          setItemId((Long)value);
14010
        }
14011
        break;
14012
 
14013
      case WAREHOUSE_ID:
14014
        if (value == null) {
14015
          unsetWarehouseId();
14016
        } else {
14017
          setWarehouseId((Long)value);
14018
        }
14019
        break;
14020
 
5967 rajveer 14021
      case SOURCE_ID:
14022
        if (value == null) {
14023
          unsetSourceId();
14024
        } else {
14025
          setSourceId((Long)value);
14026
        }
14027
        break;
14028
 
14029
      case ORDER_ID:
14030
        if (value == null) {
14031
          unsetOrderId();
14032
        } else {
14033
          setOrderId((Long)value);
14034
        }
14035
        break;
14036
 
5945 mandeep.dh 14037
      case QUANTITY:
14038
        if (value == null) {
14039
          unsetQuantity();
14040
        } else {
14041
          setQuantity((Double)value);
14042
        }
14043
        break;
14044
 
14045
      }
14046
    }
14047
 
14048
    public Object getFieldValue(_Fields field) {
14049
      switch (field) {
14050
      case ITEM_ID:
14051
        return Long.valueOf(getItemId());
14052
 
14053
      case WAREHOUSE_ID:
14054
        return Long.valueOf(getWarehouseId());
14055
 
5967 rajveer 14056
      case SOURCE_ID:
14057
        return Long.valueOf(getSourceId());
14058
 
14059
      case ORDER_ID:
14060
        return Long.valueOf(getOrderId());
14061
 
5945 mandeep.dh 14062
      case QUANTITY:
14063
        return Double.valueOf(getQuantity());
14064
 
14065
      }
14066
      throw new IllegalStateException();
14067
    }
14068
 
14069
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14070
    public boolean isSet(_Fields field) {
14071
      if (field == null) {
14072
        throw new IllegalArgumentException();
14073
      }
14074
 
14075
      switch (field) {
14076
      case ITEM_ID:
14077
        return isSetItemId();
14078
      case WAREHOUSE_ID:
14079
        return isSetWarehouseId();
5967 rajveer 14080
      case SOURCE_ID:
14081
        return isSetSourceId();
14082
      case ORDER_ID:
14083
        return isSetOrderId();
5945 mandeep.dh 14084
      case QUANTITY:
14085
        return isSetQuantity();
14086
      }
14087
      throw new IllegalStateException();
14088
    }
14089
 
14090
    @Override
14091
    public boolean equals(Object that) {
14092
      if (that == null)
14093
        return false;
14094
      if (that instanceof reduceReservationCount_args)
14095
        return this.equals((reduceReservationCount_args)that);
14096
      return false;
14097
    }
14098
 
14099
    public boolean equals(reduceReservationCount_args that) {
14100
      if (that == null)
14101
        return false;
14102
 
14103
      boolean this_present_itemId = true;
14104
      boolean that_present_itemId = true;
14105
      if (this_present_itemId || that_present_itemId) {
14106
        if (!(this_present_itemId && that_present_itemId))
14107
          return false;
14108
        if (this.itemId != that.itemId)
14109
          return false;
14110
      }
14111
 
14112
      boolean this_present_warehouseId = true;
14113
      boolean that_present_warehouseId = true;
14114
      if (this_present_warehouseId || that_present_warehouseId) {
14115
        if (!(this_present_warehouseId && that_present_warehouseId))
14116
          return false;
14117
        if (this.warehouseId != that.warehouseId)
14118
          return false;
14119
      }
14120
 
5967 rajveer 14121
      boolean this_present_sourceId = true;
14122
      boolean that_present_sourceId = true;
14123
      if (this_present_sourceId || that_present_sourceId) {
14124
        if (!(this_present_sourceId && that_present_sourceId))
14125
          return false;
14126
        if (this.sourceId != that.sourceId)
14127
          return false;
14128
      }
14129
 
14130
      boolean this_present_orderId = true;
14131
      boolean that_present_orderId = true;
14132
      if (this_present_orderId || that_present_orderId) {
14133
        if (!(this_present_orderId && that_present_orderId))
14134
          return false;
14135
        if (this.orderId != that.orderId)
14136
          return false;
14137
      }
14138
 
5945 mandeep.dh 14139
      boolean this_present_quantity = true;
14140
      boolean that_present_quantity = true;
14141
      if (this_present_quantity || that_present_quantity) {
14142
        if (!(this_present_quantity && that_present_quantity))
14143
          return false;
14144
        if (this.quantity != that.quantity)
14145
          return false;
14146
      }
14147
 
14148
      return true;
14149
    }
14150
 
14151
    @Override
14152
    public int hashCode() {
14153
      return 0;
14154
    }
14155
 
14156
    public int compareTo(reduceReservationCount_args other) {
14157
      if (!getClass().equals(other.getClass())) {
14158
        return getClass().getName().compareTo(other.getClass().getName());
14159
      }
14160
 
14161
      int lastComparison = 0;
14162
      reduceReservationCount_args typedOther = (reduceReservationCount_args)other;
14163
 
14164
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
14165
      if (lastComparison != 0) {
14166
        return lastComparison;
14167
      }
14168
      if (isSetItemId()) {
14169
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
14170
        if (lastComparison != 0) {
14171
          return lastComparison;
14172
        }
14173
      }
14174
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
14175
      if (lastComparison != 0) {
14176
        return lastComparison;
14177
      }
14178
      if (isSetWarehouseId()) {
14179
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
14180
        if (lastComparison != 0) {
14181
          return lastComparison;
14182
        }
14183
      }
5967 rajveer 14184
      lastComparison = Boolean.valueOf(isSetSourceId()).compareTo(typedOther.isSetSourceId());
14185
      if (lastComparison != 0) {
14186
        return lastComparison;
14187
      }
14188
      if (isSetSourceId()) {
14189
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.sourceId, typedOther.sourceId);
14190
        if (lastComparison != 0) {
14191
          return lastComparison;
14192
        }
14193
      }
14194
      lastComparison = Boolean.valueOf(isSetOrderId()).compareTo(typedOther.isSetOrderId());
14195
      if (lastComparison != 0) {
14196
        return lastComparison;
14197
      }
14198
      if (isSetOrderId()) {
14199
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.orderId, typedOther.orderId);
14200
        if (lastComparison != 0) {
14201
          return lastComparison;
14202
        }
14203
      }
5945 mandeep.dh 14204
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
14205
      if (lastComparison != 0) {
14206
        return lastComparison;
14207
      }
14208
      if (isSetQuantity()) {
14209
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
14210
        if (lastComparison != 0) {
14211
          return lastComparison;
14212
        }
14213
      }
14214
      return 0;
14215
    }
14216
 
14217
    public _Fields fieldForId(int fieldId) {
14218
      return _Fields.findByThriftId(fieldId);
14219
    }
14220
 
14221
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14222
      org.apache.thrift.protocol.TField field;
14223
      iprot.readStructBegin();
14224
      while (true)
14225
      {
14226
        field = iprot.readFieldBegin();
14227
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14228
          break;
14229
        }
14230
        switch (field.id) {
14231
          case 1: // ITEM_ID
14232
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14233
              this.itemId = iprot.readI64();
14234
              setItemIdIsSet(true);
14235
            } else { 
14236
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14237
            }
14238
            break;
14239
          case 2: // WAREHOUSE_ID
14240
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14241
              this.warehouseId = iprot.readI64();
14242
              setWarehouseIdIsSet(true);
14243
            } else { 
14244
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14245
            }
14246
            break;
5967 rajveer 14247
          case 3: // SOURCE_ID
14248
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14249
              this.sourceId = iprot.readI64();
14250
              setSourceIdIsSet(true);
14251
            } else { 
14252
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14253
            }
14254
            break;
14255
          case 4: // ORDER_ID
14256
            if (field.type == org.apache.thrift.protocol.TType.I64) {
14257
              this.orderId = iprot.readI64();
14258
              setOrderIdIsSet(true);
14259
            } else { 
14260
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14261
            }
14262
            break;
14263
          case 5: // QUANTITY
5945 mandeep.dh 14264
            if (field.type == org.apache.thrift.protocol.TType.DOUBLE) {
14265
              this.quantity = iprot.readDouble();
14266
              setQuantityIsSet(true);
14267
            } else { 
14268
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14269
            }
14270
            break;
14271
          default:
14272
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14273
        }
14274
        iprot.readFieldEnd();
14275
      }
14276
      iprot.readStructEnd();
14277
      validate();
14278
    }
14279
 
14280
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14281
      validate();
14282
 
14283
      oprot.writeStructBegin(STRUCT_DESC);
14284
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
14285
      oprot.writeI64(this.itemId);
14286
      oprot.writeFieldEnd();
14287
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
14288
      oprot.writeI64(this.warehouseId);
14289
      oprot.writeFieldEnd();
5967 rajveer 14290
      oprot.writeFieldBegin(SOURCE_ID_FIELD_DESC);
14291
      oprot.writeI64(this.sourceId);
14292
      oprot.writeFieldEnd();
14293
      oprot.writeFieldBegin(ORDER_ID_FIELD_DESC);
14294
      oprot.writeI64(this.orderId);
14295
      oprot.writeFieldEnd();
5945 mandeep.dh 14296
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
14297
      oprot.writeDouble(this.quantity);
14298
      oprot.writeFieldEnd();
14299
      oprot.writeFieldStop();
14300
      oprot.writeStructEnd();
14301
    }
14302
 
14303
    @Override
14304
    public String toString() {
14305
      StringBuilder sb = new StringBuilder("reduceReservationCount_args(");
14306
      boolean first = true;
14307
 
14308
      sb.append("itemId:");
14309
      sb.append(this.itemId);
14310
      first = false;
14311
      if (!first) sb.append(", ");
14312
      sb.append("warehouseId:");
14313
      sb.append(this.warehouseId);
14314
      first = false;
14315
      if (!first) sb.append(", ");
5967 rajveer 14316
      sb.append("sourceId:");
14317
      sb.append(this.sourceId);
14318
      first = false;
14319
      if (!first) sb.append(", ");
14320
      sb.append("orderId:");
14321
      sb.append(this.orderId);
14322
      first = false;
14323
      if (!first) sb.append(", ");
5945 mandeep.dh 14324
      sb.append("quantity:");
14325
      sb.append(this.quantity);
14326
      first = false;
14327
      sb.append(")");
14328
      return sb.toString();
14329
    }
14330
 
14331
    public void validate() throws org.apache.thrift.TException {
14332
      // check for required fields
14333
    }
14334
 
14335
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14336
      try {
14337
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14338
      } catch (org.apache.thrift.TException te) {
14339
        throw new java.io.IOException(te);
14340
      }
14341
    }
14342
 
14343
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14344
      try {
14345
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14346
      } catch (org.apache.thrift.TException te) {
14347
        throw new java.io.IOException(te);
14348
      }
14349
    }
14350
 
14351
  }
14352
 
14353
  public static class reduceReservationCount_result implements org.apache.thrift.TBase<reduceReservationCount_result, reduceReservationCount_result._Fields>, java.io.Serializable, Cloneable   {
14354
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("reduceReservationCount_result");
14355
 
14356
    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);
14357
    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);
14358
 
14359
    private boolean success; // required
14360
    private InventoryServiceException cex; // required
14361
 
14362
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14363
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14364
      SUCCESS((short)0, "success"),
14365
      CEX((short)1, "cex");
14366
 
14367
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14368
 
14369
      static {
14370
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14371
          byName.put(field.getFieldName(), field);
14372
        }
14373
      }
14374
 
14375
      /**
14376
       * Find the _Fields constant that matches fieldId, or null if its not found.
14377
       */
14378
      public static _Fields findByThriftId(int fieldId) {
14379
        switch(fieldId) {
14380
          case 0: // SUCCESS
14381
            return SUCCESS;
14382
          case 1: // CEX
14383
            return CEX;
14384
          default:
14385
            return null;
14386
        }
14387
      }
14388
 
14389
      /**
14390
       * Find the _Fields constant that matches fieldId, throwing an exception
14391
       * if it is not found.
14392
       */
14393
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14394
        _Fields fields = findByThriftId(fieldId);
14395
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14396
        return fields;
14397
      }
14398
 
14399
      /**
14400
       * Find the _Fields constant that matches name, or null if its not found.
14401
       */
14402
      public static _Fields findByName(String name) {
14403
        return byName.get(name);
14404
      }
14405
 
14406
      private final short _thriftId;
14407
      private final String _fieldName;
14408
 
14409
      _Fields(short thriftId, String fieldName) {
14410
        _thriftId = thriftId;
14411
        _fieldName = fieldName;
14412
      }
14413
 
14414
      public short getThriftFieldId() {
14415
        return _thriftId;
14416
      }
14417
 
14418
      public String getFieldName() {
14419
        return _fieldName;
14420
      }
14421
    }
14422
 
14423
    // isset id assignments
14424
    private static final int __SUCCESS_ISSET_ID = 0;
14425
    private BitSet __isset_bit_vector = new BitSet(1);
14426
 
14427
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14428
    static {
14429
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14430
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14431
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.BOOL)));
14432
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14433
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
14434
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14435
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(reduceReservationCount_result.class, metaDataMap);
14436
    }
14437
 
14438
    public reduceReservationCount_result() {
14439
    }
14440
 
14441
    public reduceReservationCount_result(
14442
      boolean success,
14443
      InventoryServiceException cex)
14444
    {
14445
      this();
14446
      this.success = success;
14447
      setSuccessIsSet(true);
14448
      this.cex = cex;
14449
    }
14450
 
14451
    /**
14452
     * Performs a deep copy on <i>other</i>.
14453
     */
14454
    public reduceReservationCount_result(reduceReservationCount_result other) {
14455
      __isset_bit_vector.clear();
14456
      __isset_bit_vector.or(other.__isset_bit_vector);
14457
      this.success = other.success;
14458
      if (other.isSetCex()) {
14459
        this.cex = new InventoryServiceException(other.cex);
14460
      }
14461
    }
14462
 
14463
    public reduceReservationCount_result deepCopy() {
14464
      return new reduceReservationCount_result(this);
14465
    }
14466
 
14467
    @Override
14468
    public void clear() {
14469
      setSuccessIsSet(false);
14470
      this.success = false;
14471
      this.cex = null;
14472
    }
14473
 
14474
    public boolean isSuccess() {
14475
      return this.success;
14476
    }
14477
 
14478
    public void setSuccess(boolean success) {
14479
      this.success = success;
14480
      setSuccessIsSet(true);
14481
    }
14482
 
14483
    public void unsetSuccess() {
14484
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
14485
    }
14486
 
14487
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
14488
    public boolean isSetSuccess() {
14489
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
14490
    }
14491
 
14492
    public void setSuccessIsSet(boolean value) {
14493
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
14494
    }
14495
 
14496
    public InventoryServiceException getCex() {
14497
      return this.cex;
14498
    }
14499
 
14500
    public void setCex(InventoryServiceException cex) {
14501
      this.cex = cex;
14502
    }
14503
 
14504
    public void unsetCex() {
14505
      this.cex = null;
14506
    }
14507
 
14508
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
14509
    public boolean isSetCex() {
14510
      return this.cex != null;
14511
    }
14512
 
14513
    public void setCexIsSet(boolean value) {
14514
      if (!value) {
14515
        this.cex = null;
14516
      }
14517
    }
14518
 
14519
    public void setFieldValue(_Fields field, Object value) {
14520
      switch (field) {
14521
      case SUCCESS:
14522
        if (value == null) {
14523
          unsetSuccess();
14524
        } else {
14525
          setSuccess((Boolean)value);
14526
        }
14527
        break;
14528
 
14529
      case CEX:
14530
        if (value == null) {
14531
          unsetCex();
14532
        } else {
14533
          setCex((InventoryServiceException)value);
14534
        }
14535
        break;
14536
 
14537
      }
14538
    }
14539
 
14540
    public Object getFieldValue(_Fields field) {
14541
      switch (field) {
14542
      case SUCCESS:
14543
        return Boolean.valueOf(isSuccess());
14544
 
14545
      case CEX:
14546
        return getCex();
14547
 
14548
      }
14549
      throw new IllegalStateException();
14550
    }
14551
 
14552
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14553
    public boolean isSet(_Fields field) {
14554
      if (field == null) {
14555
        throw new IllegalArgumentException();
14556
      }
14557
 
14558
      switch (field) {
14559
      case SUCCESS:
14560
        return isSetSuccess();
14561
      case CEX:
14562
        return isSetCex();
14563
      }
14564
      throw new IllegalStateException();
14565
    }
14566
 
14567
    @Override
14568
    public boolean equals(Object that) {
14569
      if (that == null)
14570
        return false;
14571
      if (that instanceof reduceReservationCount_result)
14572
        return this.equals((reduceReservationCount_result)that);
14573
      return false;
14574
    }
14575
 
14576
    public boolean equals(reduceReservationCount_result that) {
14577
      if (that == null)
14578
        return false;
14579
 
14580
      boolean this_present_success = true;
14581
      boolean that_present_success = true;
14582
      if (this_present_success || that_present_success) {
14583
        if (!(this_present_success && that_present_success))
14584
          return false;
14585
        if (this.success != that.success)
14586
          return false;
14587
      }
14588
 
14589
      boolean this_present_cex = true && this.isSetCex();
14590
      boolean that_present_cex = true && that.isSetCex();
14591
      if (this_present_cex || that_present_cex) {
14592
        if (!(this_present_cex && that_present_cex))
14593
          return false;
14594
        if (!this.cex.equals(that.cex))
14595
          return false;
14596
      }
14597
 
14598
      return true;
14599
    }
14600
 
14601
    @Override
14602
    public int hashCode() {
14603
      return 0;
14604
    }
14605
 
14606
    public int compareTo(reduceReservationCount_result other) {
14607
      if (!getClass().equals(other.getClass())) {
14608
        return getClass().getName().compareTo(other.getClass().getName());
14609
      }
14610
 
14611
      int lastComparison = 0;
14612
      reduceReservationCount_result typedOther = (reduceReservationCount_result)other;
14613
 
14614
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
14615
      if (lastComparison != 0) {
14616
        return lastComparison;
14617
      }
14618
      if (isSetSuccess()) {
14619
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
14620
        if (lastComparison != 0) {
14621
          return lastComparison;
14622
        }
14623
      }
14624
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
14625
      if (lastComparison != 0) {
14626
        return lastComparison;
14627
      }
14628
      if (isSetCex()) {
14629
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
14630
        if (lastComparison != 0) {
14631
          return lastComparison;
14632
        }
14633
      }
14634
      return 0;
14635
    }
14636
 
14637
    public _Fields fieldForId(int fieldId) {
14638
      return _Fields.findByThriftId(fieldId);
14639
    }
14640
 
14641
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
14642
      org.apache.thrift.protocol.TField field;
14643
      iprot.readStructBegin();
14644
      while (true)
14645
      {
14646
        field = iprot.readFieldBegin();
14647
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
14648
          break;
14649
        }
14650
        switch (field.id) {
14651
          case 0: // SUCCESS
14652
            if (field.type == org.apache.thrift.protocol.TType.BOOL) {
14653
              this.success = iprot.readBool();
14654
              setSuccessIsSet(true);
14655
            } else { 
14656
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14657
            }
14658
            break;
14659
          case 1: // CEX
14660
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
14661
              this.cex = new InventoryServiceException();
14662
              this.cex.read(iprot);
14663
            } else { 
14664
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14665
            }
14666
            break;
14667
          default:
14668
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
14669
        }
14670
        iprot.readFieldEnd();
14671
      }
14672
      iprot.readStructEnd();
14673
      validate();
14674
    }
14675
 
14676
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
14677
      oprot.writeStructBegin(STRUCT_DESC);
14678
 
14679
      if (this.isSetSuccess()) {
14680
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
14681
        oprot.writeBool(this.success);
14682
        oprot.writeFieldEnd();
14683
      } else if (this.isSetCex()) {
14684
        oprot.writeFieldBegin(CEX_FIELD_DESC);
14685
        this.cex.write(oprot);
14686
        oprot.writeFieldEnd();
14687
      }
14688
      oprot.writeFieldStop();
14689
      oprot.writeStructEnd();
14690
    }
14691
 
14692
    @Override
14693
    public String toString() {
14694
      StringBuilder sb = new StringBuilder("reduceReservationCount_result(");
14695
      boolean first = true;
14696
 
14697
      sb.append("success:");
14698
      sb.append(this.success);
14699
      first = false;
14700
      if (!first) sb.append(", ");
14701
      sb.append("cex:");
14702
      if (this.cex == null) {
14703
        sb.append("null");
14704
      } else {
14705
        sb.append(this.cex);
14706
      }
14707
      first = false;
14708
      sb.append(")");
14709
      return sb.toString();
14710
    }
14711
 
14712
    public void validate() throws org.apache.thrift.TException {
14713
      // check for required fields
14714
    }
14715
 
14716
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
14717
      try {
14718
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
14719
      } catch (org.apache.thrift.TException te) {
14720
        throw new java.io.IOException(te);
14721
      }
14722
    }
14723
 
14724
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
14725
      try {
14726
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
14727
      } catch (org.apache.thrift.TException te) {
14728
        throw new java.io.IOException(te);
14729
      }
14730
    }
14731
 
14732
  }
14733
 
14734
  public static class getItemPricing_args implements org.apache.thrift.TBase<getItemPricing_args, getItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
14735
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemPricing_args");
14736
 
14737
    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);
14738
    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);
14739
 
14740
    private long itemId; // required
14741
    private long vendorId; // required
14742
 
14743
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
14744
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
14745
      ITEM_ID((short)1, "itemId"),
14746
      VENDOR_ID((short)2, "vendorId");
14747
 
14748
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
14749
 
14750
      static {
14751
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
14752
          byName.put(field.getFieldName(), field);
14753
        }
14754
      }
14755
 
14756
      /**
14757
       * Find the _Fields constant that matches fieldId, or null if its not found.
14758
       */
14759
      public static _Fields findByThriftId(int fieldId) {
14760
        switch(fieldId) {
14761
          case 1: // ITEM_ID
14762
            return ITEM_ID;
14763
          case 2: // VENDOR_ID
14764
            return VENDOR_ID;
14765
          default:
14766
            return null;
14767
        }
14768
      }
14769
 
14770
      /**
14771
       * Find the _Fields constant that matches fieldId, throwing an exception
14772
       * if it is not found.
14773
       */
14774
      public static _Fields findByThriftIdOrThrow(int fieldId) {
14775
        _Fields fields = findByThriftId(fieldId);
14776
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
14777
        return fields;
14778
      }
14779
 
14780
      /**
14781
       * Find the _Fields constant that matches name, or null if its not found.
14782
       */
14783
      public static _Fields findByName(String name) {
14784
        return byName.get(name);
14785
      }
14786
 
14787
      private final short _thriftId;
14788
      private final String _fieldName;
14789
 
14790
      _Fields(short thriftId, String fieldName) {
14791
        _thriftId = thriftId;
14792
        _fieldName = fieldName;
14793
      }
14794
 
14795
      public short getThriftFieldId() {
14796
        return _thriftId;
14797
      }
14798
 
14799
      public String getFieldName() {
14800
        return _fieldName;
14801
      }
14802
    }
14803
 
14804
    // isset id assignments
14805
    private static final int __ITEMID_ISSET_ID = 0;
14806
    private static final int __VENDORID_ISSET_ID = 1;
14807
    private BitSet __isset_bit_vector = new BitSet(2);
14808
 
14809
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
14810
    static {
14811
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
14812
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14813
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14814
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
14815
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
14816
      metaDataMap = Collections.unmodifiableMap(tmpMap);
14817
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemPricing_args.class, metaDataMap);
14818
    }
14819
 
14820
    public getItemPricing_args() {
14821
    }
14822
 
14823
    public getItemPricing_args(
14824
      long itemId,
14825
      long vendorId)
14826
    {
14827
      this();
14828
      this.itemId = itemId;
14829
      setItemIdIsSet(true);
14830
      this.vendorId = vendorId;
14831
      setVendorIdIsSet(true);
14832
    }
14833
 
14834
    /**
14835
     * Performs a deep copy on <i>other</i>.
14836
     */
14837
    public getItemPricing_args(getItemPricing_args other) {
14838
      __isset_bit_vector.clear();
14839
      __isset_bit_vector.or(other.__isset_bit_vector);
14840
      this.itemId = other.itemId;
14841
      this.vendorId = other.vendorId;
14842
    }
14843
 
14844
    public getItemPricing_args deepCopy() {
14845
      return new getItemPricing_args(this);
14846
    }
14847
 
14848
    @Override
14849
    public void clear() {
14850
      setItemIdIsSet(false);
14851
      this.itemId = 0;
14852
      setVendorIdIsSet(false);
14853
      this.vendorId = 0;
14854
    }
14855
 
14856
    public long getItemId() {
14857
      return this.itemId;
14858
    }
14859
 
14860
    public void setItemId(long itemId) {
14861
      this.itemId = itemId;
14862
      setItemIdIsSet(true);
14863
    }
14864
 
14865
    public void unsetItemId() {
14866
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
14867
    }
14868
 
14869
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
14870
    public boolean isSetItemId() {
14871
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
14872
    }
14873
 
14874
    public void setItemIdIsSet(boolean value) {
14875
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
14876
    }
14877
 
14878
    public long getVendorId() {
14879
      return this.vendorId;
14880
    }
14881
 
14882
    public void setVendorId(long vendorId) {
14883
      this.vendorId = vendorId;
14884
      setVendorIdIsSet(true);
14885
    }
14886
 
14887
    public void unsetVendorId() {
14888
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
14889
    }
14890
 
14891
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
14892
    public boolean isSetVendorId() {
14893
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
14894
    }
14895
 
14896
    public void setVendorIdIsSet(boolean value) {
14897
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
14898
    }
14899
 
14900
    public void setFieldValue(_Fields field, Object value) {
14901
      switch (field) {
14902
      case ITEM_ID:
14903
        if (value == null) {
14904
          unsetItemId();
14905
        } else {
14906
          setItemId((Long)value);
14907
        }
14908
        break;
14909
 
14910
      case VENDOR_ID:
14911
        if (value == null) {
14912
          unsetVendorId();
14913
        } else {
14914
          setVendorId((Long)value);
14915
        }
14916
        break;
14917
 
14918
      }
14919
    }
14920
 
14921
    public Object getFieldValue(_Fields field) {
14922
      switch (field) {
14923
      case ITEM_ID:
14924
        return Long.valueOf(getItemId());
14925
 
14926
      case VENDOR_ID:
14927
        return Long.valueOf(getVendorId());
14928
 
14929
      }
14930
      throw new IllegalStateException();
14931
    }
14932
 
14933
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
14934
    public boolean isSet(_Fields field) {
14935
      if (field == null) {
14936
        throw new IllegalArgumentException();
14937
      }
14938
 
14939
      switch (field) {
14940
      case ITEM_ID:
14941
        return isSetItemId();
14942
      case VENDOR_ID:
14943
        return isSetVendorId();
14944
      }
14945
      throw new IllegalStateException();
14946
    }
14947
 
14948
    @Override
14949
    public boolean equals(Object that) {
14950
      if (that == null)
14951
        return false;
14952
      if (that instanceof getItemPricing_args)
14953
        return this.equals((getItemPricing_args)that);
14954
      return false;
14955
    }
14956
 
14957
    public boolean equals(getItemPricing_args that) {
14958
      if (that == null)
14959
        return false;
14960
 
14961
      boolean this_present_itemId = true;
14962
      boolean that_present_itemId = true;
14963
      if (this_present_itemId || that_present_itemId) {
14964
        if (!(this_present_itemId && that_present_itemId))
14965
          return false;
14966
        if (this.itemId != that.itemId)
14967
          return false;
14968
      }
14969
 
14970
      boolean this_present_vendorId = true;
14971
      boolean that_present_vendorId = true;
14972
      if (this_present_vendorId || that_present_vendorId) {
14973
        if (!(this_present_vendorId && that_present_vendorId))
14974
          return false;
14975
        if (this.vendorId != that.vendorId)
14976
          return false;
14977
      }
14978
 
14979
      return true;
14980
    }
14981
 
14982
    @Override
14983
    public int hashCode() {
14984
      return 0;
14985
    }
14986
 
14987
    public int compareTo(getItemPricing_args other) {
14988
      if (!getClass().equals(other.getClass())) {
14989
        return getClass().getName().compareTo(other.getClass().getName());
14990
      }
14991
 
14992
      int lastComparison = 0;
14993
      getItemPricing_args typedOther = (getItemPricing_args)other;
14994
 
14995
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
14996
      if (lastComparison != 0) {
14997
        return lastComparison;
14998
      }
14999
      if (isSetItemId()) {
15000
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
15001
        if (lastComparison != 0) {
15002
          return lastComparison;
15003
        }
15004
      }
15005
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
15006
      if (lastComparison != 0) {
15007
        return lastComparison;
15008
      }
15009
      if (isSetVendorId()) {
15010
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
15011
        if (lastComparison != 0) {
15012
          return lastComparison;
15013
        }
15014
      }
15015
      return 0;
15016
    }
15017
 
15018
    public _Fields fieldForId(int fieldId) {
15019
      return _Fields.findByThriftId(fieldId);
15020
    }
15021
 
15022
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15023
      org.apache.thrift.protocol.TField field;
15024
      iprot.readStructBegin();
15025
      while (true)
15026
      {
15027
        field = iprot.readFieldBegin();
15028
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15029
          break;
15030
        }
15031
        switch (field.id) {
15032
          case 1: // ITEM_ID
15033
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15034
              this.itemId = iprot.readI64();
15035
              setItemIdIsSet(true);
15036
            } else { 
15037
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15038
            }
15039
            break;
15040
          case 2: // VENDOR_ID
15041
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15042
              this.vendorId = iprot.readI64();
15043
              setVendorIdIsSet(true);
15044
            } else { 
15045
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15046
            }
15047
            break;
15048
          default:
15049
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15050
        }
15051
        iprot.readFieldEnd();
15052
      }
15053
      iprot.readStructEnd();
15054
      validate();
15055
    }
15056
 
15057
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15058
      validate();
15059
 
15060
      oprot.writeStructBegin(STRUCT_DESC);
15061
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
15062
      oprot.writeI64(this.itemId);
15063
      oprot.writeFieldEnd();
15064
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
15065
      oprot.writeI64(this.vendorId);
15066
      oprot.writeFieldEnd();
15067
      oprot.writeFieldStop();
15068
      oprot.writeStructEnd();
15069
    }
15070
 
15071
    @Override
15072
    public String toString() {
15073
      StringBuilder sb = new StringBuilder("getItemPricing_args(");
15074
      boolean first = true;
15075
 
15076
      sb.append("itemId:");
15077
      sb.append(this.itemId);
15078
      first = false;
15079
      if (!first) sb.append(", ");
15080
      sb.append("vendorId:");
15081
      sb.append(this.vendorId);
15082
      first = false;
15083
      sb.append(")");
15084
      return sb.toString();
15085
    }
15086
 
15087
    public void validate() throws org.apache.thrift.TException {
15088
      // check for required fields
15089
    }
15090
 
15091
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15092
      try {
15093
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15094
      } catch (org.apache.thrift.TException te) {
15095
        throw new java.io.IOException(te);
15096
      }
15097
    }
15098
 
15099
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15100
      try {
15101
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15102
      } catch (org.apache.thrift.TException te) {
15103
        throw new java.io.IOException(te);
15104
      }
15105
    }
15106
 
15107
  }
15108
 
15109
  public static class getItemPricing_result implements org.apache.thrift.TBase<getItemPricing_result, getItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
15110
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemPricing_result");
15111
 
15112
    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);
15113
    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);
15114
 
15115
    private VendorItemPricing success; // required
15116
    private InventoryServiceException cex; // required
15117
 
15118
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15119
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15120
      SUCCESS((short)0, "success"),
15121
      CEX((short)1, "cex");
15122
 
15123
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15124
 
15125
      static {
15126
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15127
          byName.put(field.getFieldName(), field);
15128
        }
15129
      }
15130
 
15131
      /**
15132
       * Find the _Fields constant that matches fieldId, or null if its not found.
15133
       */
15134
      public static _Fields findByThriftId(int fieldId) {
15135
        switch(fieldId) {
15136
          case 0: // SUCCESS
15137
            return SUCCESS;
15138
          case 1: // CEX
15139
            return CEX;
15140
          default:
15141
            return null;
15142
        }
15143
      }
15144
 
15145
      /**
15146
       * Find the _Fields constant that matches fieldId, throwing an exception
15147
       * if it is not found.
15148
       */
15149
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15150
        _Fields fields = findByThriftId(fieldId);
15151
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15152
        return fields;
15153
      }
15154
 
15155
      /**
15156
       * Find the _Fields constant that matches name, or null if its not found.
15157
       */
15158
      public static _Fields findByName(String name) {
15159
        return byName.get(name);
15160
      }
15161
 
15162
      private final short _thriftId;
15163
      private final String _fieldName;
15164
 
15165
      _Fields(short thriftId, String fieldName) {
15166
        _thriftId = thriftId;
15167
        _fieldName = fieldName;
15168
      }
15169
 
15170
      public short getThriftFieldId() {
15171
        return _thriftId;
15172
      }
15173
 
15174
      public String getFieldName() {
15175
        return _fieldName;
15176
      }
15177
    }
15178
 
15179
    // isset id assignments
15180
 
15181
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15182
    static {
15183
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15184
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15185
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class)));
15186
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15187
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
15188
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15189
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemPricing_result.class, metaDataMap);
15190
    }
15191
 
15192
    public getItemPricing_result() {
15193
    }
15194
 
15195
    public getItemPricing_result(
15196
      VendorItemPricing success,
15197
      InventoryServiceException cex)
15198
    {
15199
      this();
15200
      this.success = success;
15201
      this.cex = cex;
15202
    }
15203
 
15204
    /**
15205
     * Performs a deep copy on <i>other</i>.
15206
     */
15207
    public getItemPricing_result(getItemPricing_result other) {
15208
      if (other.isSetSuccess()) {
15209
        this.success = new VendorItemPricing(other.success);
15210
      }
15211
      if (other.isSetCex()) {
15212
        this.cex = new InventoryServiceException(other.cex);
15213
      }
15214
    }
15215
 
15216
    public getItemPricing_result deepCopy() {
15217
      return new getItemPricing_result(this);
15218
    }
15219
 
15220
    @Override
15221
    public void clear() {
15222
      this.success = null;
15223
      this.cex = null;
15224
    }
15225
 
15226
    public VendorItemPricing getSuccess() {
15227
      return this.success;
15228
    }
15229
 
15230
    public void setSuccess(VendorItemPricing success) {
15231
      this.success = success;
15232
    }
15233
 
15234
    public void unsetSuccess() {
15235
      this.success = null;
15236
    }
15237
 
15238
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
15239
    public boolean isSetSuccess() {
15240
      return this.success != null;
15241
    }
15242
 
15243
    public void setSuccessIsSet(boolean value) {
15244
      if (!value) {
15245
        this.success = null;
15246
      }
15247
    }
15248
 
15249
    public InventoryServiceException getCex() {
15250
      return this.cex;
15251
    }
15252
 
15253
    public void setCex(InventoryServiceException cex) {
15254
      this.cex = cex;
15255
    }
15256
 
15257
    public void unsetCex() {
15258
      this.cex = null;
15259
    }
15260
 
15261
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
15262
    public boolean isSetCex() {
15263
      return this.cex != null;
15264
    }
15265
 
15266
    public void setCexIsSet(boolean value) {
15267
      if (!value) {
15268
        this.cex = null;
15269
      }
15270
    }
15271
 
15272
    public void setFieldValue(_Fields field, Object value) {
15273
      switch (field) {
15274
      case SUCCESS:
15275
        if (value == null) {
15276
          unsetSuccess();
15277
        } else {
15278
          setSuccess((VendorItemPricing)value);
15279
        }
15280
        break;
15281
 
15282
      case CEX:
15283
        if (value == null) {
15284
          unsetCex();
15285
        } else {
15286
          setCex((InventoryServiceException)value);
15287
        }
15288
        break;
15289
 
15290
      }
15291
    }
15292
 
15293
    public Object getFieldValue(_Fields field) {
15294
      switch (field) {
15295
      case SUCCESS:
15296
        return getSuccess();
15297
 
15298
      case CEX:
15299
        return getCex();
15300
 
15301
      }
15302
      throw new IllegalStateException();
15303
    }
15304
 
15305
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15306
    public boolean isSet(_Fields field) {
15307
      if (field == null) {
15308
        throw new IllegalArgumentException();
15309
      }
15310
 
15311
      switch (field) {
15312
      case SUCCESS:
15313
        return isSetSuccess();
15314
      case CEX:
15315
        return isSetCex();
15316
      }
15317
      throw new IllegalStateException();
15318
    }
15319
 
15320
    @Override
15321
    public boolean equals(Object that) {
15322
      if (that == null)
15323
        return false;
15324
      if (that instanceof getItemPricing_result)
15325
        return this.equals((getItemPricing_result)that);
15326
      return false;
15327
    }
15328
 
15329
    public boolean equals(getItemPricing_result that) {
15330
      if (that == null)
15331
        return false;
15332
 
15333
      boolean this_present_success = true && this.isSetSuccess();
15334
      boolean that_present_success = true && that.isSetSuccess();
15335
      if (this_present_success || that_present_success) {
15336
        if (!(this_present_success && that_present_success))
15337
          return false;
15338
        if (!this.success.equals(that.success))
15339
          return false;
15340
      }
15341
 
15342
      boolean this_present_cex = true && this.isSetCex();
15343
      boolean that_present_cex = true && that.isSetCex();
15344
      if (this_present_cex || that_present_cex) {
15345
        if (!(this_present_cex && that_present_cex))
15346
          return false;
15347
        if (!this.cex.equals(that.cex))
15348
          return false;
15349
      }
15350
 
15351
      return true;
15352
    }
15353
 
15354
    @Override
15355
    public int hashCode() {
15356
      return 0;
15357
    }
15358
 
15359
    public int compareTo(getItemPricing_result other) {
15360
      if (!getClass().equals(other.getClass())) {
15361
        return getClass().getName().compareTo(other.getClass().getName());
15362
      }
15363
 
15364
      int lastComparison = 0;
15365
      getItemPricing_result typedOther = (getItemPricing_result)other;
15366
 
15367
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
15368
      if (lastComparison != 0) {
15369
        return lastComparison;
15370
      }
15371
      if (isSetSuccess()) {
15372
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
15373
        if (lastComparison != 0) {
15374
          return lastComparison;
15375
        }
15376
      }
15377
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
15378
      if (lastComparison != 0) {
15379
        return lastComparison;
15380
      }
15381
      if (isSetCex()) {
15382
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
15383
        if (lastComparison != 0) {
15384
          return lastComparison;
15385
        }
15386
      }
15387
      return 0;
15388
    }
15389
 
15390
    public _Fields fieldForId(int fieldId) {
15391
      return _Fields.findByThriftId(fieldId);
15392
    }
15393
 
15394
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15395
      org.apache.thrift.protocol.TField field;
15396
      iprot.readStructBegin();
15397
      while (true)
15398
      {
15399
        field = iprot.readFieldBegin();
15400
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15401
          break;
15402
        }
15403
        switch (field.id) {
15404
          case 0: // SUCCESS
15405
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15406
              this.success = new VendorItemPricing();
15407
              this.success.read(iprot);
15408
            } else { 
15409
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15410
            }
15411
            break;
15412
          case 1: // CEX
15413
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
15414
              this.cex = new InventoryServiceException();
15415
              this.cex.read(iprot);
15416
            } else { 
15417
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15418
            }
15419
            break;
15420
          default:
15421
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15422
        }
15423
        iprot.readFieldEnd();
15424
      }
15425
      iprot.readStructEnd();
15426
      validate();
15427
    }
15428
 
15429
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15430
      oprot.writeStructBegin(STRUCT_DESC);
15431
 
15432
      if (this.isSetSuccess()) {
15433
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
15434
        this.success.write(oprot);
15435
        oprot.writeFieldEnd();
15436
      } else if (this.isSetCex()) {
15437
        oprot.writeFieldBegin(CEX_FIELD_DESC);
15438
        this.cex.write(oprot);
15439
        oprot.writeFieldEnd();
15440
      }
15441
      oprot.writeFieldStop();
15442
      oprot.writeStructEnd();
15443
    }
15444
 
15445
    @Override
15446
    public String toString() {
15447
      StringBuilder sb = new StringBuilder("getItemPricing_result(");
15448
      boolean first = true;
15449
 
15450
      sb.append("success:");
15451
      if (this.success == null) {
15452
        sb.append("null");
15453
      } else {
15454
        sb.append(this.success);
15455
      }
15456
      first = false;
15457
      if (!first) sb.append(", ");
15458
      sb.append("cex:");
15459
      if (this.cex == null) {
15460
        sb.append("null");
15461
      } else {
15462
        sb.append(this.cex);
15463
      }
15464
      first = false;
15465
      sb.append(")");
15466
      return sb.toString();
15467
    }
15468
 
15469
    public void validate() throws org.apache.thrift.TException {
15470
      // check for required fields
15471
    }
15472
 
15473
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15474
      try {
15475
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15476
      } catch (org.apache.thrift.TException te) {
15477
        throw new java.io.IOException(te);
15478
      }
15479
    }
15480
 
15481
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15482
      try {
15483
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15484
      } catch (org.apache.thrift.TException te) {
15485
        throw new java.io.IOException(te);
15486
      }
15487
    }
15488
 
15489
  }
15490
 
15491
  public static class getAllItemPricing_args implements org.apache.thrift.TBase<getAllItemPricing_args, getAllItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
15492
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemPricing_args");
15493
 
15494
    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);
15495
 
15496
    private long itemId; // required
15497
 
15498
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15499
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15500
      ITEM_ID((short)1, "itemId");
15501
 
15502
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15503
 
15504
      static {
15505
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15506
          byName.put(field.getFieldName(), field);
15507
        }
15508
      }
15509
 
15510
      /**
15511
       * Find the _Fields constant that matches fieldId, or null if its not found.
15512
       */
15513
      public static _Fields findByThriftId(int fieldId) {
15514
        switch(fieldId) {
15515
          case 1: // ITEM_ID
15516
            return ITEM_ID;
15517
          default:
15518
            return null;
15519
        }
15520
      }
15521
 
15522
      /**
15523
       * Find the _Fields constant that matches fieldId, throwing an exception
15524
       * if it is not found.
15525
       */
15526
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15527
        _Fields fields = findByThriftId(fieldId);
15528
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15529
        return fields;
15530
      }
15531
 
15532
      /**
15533
       * Find the _Fields constant that matches name, or null if its not found.
15534
       */
15535
      public static _Fields findByName(String name) {
15536
        return byName.get(name);
15537
      }
15538
 
15539
      private final short _thriftId;
15540
      private final String _fieldName;
15541
 
15542
      _Fields(short thriftId, String fieldName) {
15543
        _thriftId = thriftId;
15544
        _fieldName = fieldName;
15545
      }
15546
 
15547
      public short getThriftFieldId() {
15548
        return _thriftId;
15549
      }
15550
 
15551
      public String getFieldName() {
15552
        return _fieldName;
15553
      }
15554
    }
15555
 
15556
    // isset id assignments
15557
    private static final int __ITEMID_ISSET_ID = 0;
15558
    private BitSet __isset_bit_vector = new BitSet(1);
15559
 
15560
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15561
    static {
15562
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15563
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15564
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
15565
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15566
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemPricing_args.class, metaDataMap);
15567
    }
15568
 
15569
    public getAllItemPricing_args() {
15570
    }
15571
 
15572
    public getAllItemPricing_args(
15573
      long itemId)
15574
    {
15575
      this();
15576
      this.itemId = itemId;
15577
      setItemIdIsSet(true);
15578
    }
15579
 
15580
    /**
15581
     * Performs a deep copy on <i>other</i>.
15582
     */
15583
    public getAllItemPricing_args(getAllItemPricing_args other) {
15584
      __isset_bit_vector.clear();
15585
      __isset_bit_vector.or(other.__isset_bit_vector);
15586
      this.itemId = other.itemId;
15587
    }
15588
 
15589
    public getAllItemPricing_args deepCopy() {
15590
      return new getAllItemPricing_args(this);
15591
    }
15592
 
15593
    @Override
15594
    public void clear() {
15595
      setItemIdIsSet(false);
15596
      this.itemId = 0;
15597
    }
15598
 
15599
    public long getItemId() {
15600
      return this.itemId;
15601
    }
15602
 
15603
    public void setItemId(long itemId) {
15604
      this.itemId = itemId;
15605
      setItemIdIsSet(true);
15606
    }
15607
 
15608
    public void unsetItemId() {
15609
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
15610
    }
15611
 
15612
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
15613
    public boolean isSetItemId() {
15614
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
15615
    }
15616
 
15617
    public void setItemIdIsSet(boolean value) {
15618
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
15619
    }
15620
 
15621
    public void setFieldValue(_Fields field, Object value) {
15622
      switch (field) {
15623
      case ITEM_ID:
15624
        if (value == null) {
15625
          unsetItemId();
15626
        } else {
15627
          setItemId((Long)value);
15628
        }
15629
        break;
15630
 
15631
      }
15632
    }
15633
 
15634
    public Object getFieldValue(_Fields field) {
15635
      switch (field) {
15636
      case ITEM_ID:
15637
        return Long.valueOf(getItemId());
15638
 
15639
      }
15640
      throw new IllegalStateException();
15641
    }
15642
 
15643
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
15644
    public boolean isSet(_Fields field) {
15645
      if (field == null) {
15646
        throw new IllegalArgumentException();
15647
      }
15648
 
15649
      switch (field) {
15650
      case ITEM_ID:
15651
        return isSetItemId();
15652
      }
15653
      throw new IllegalStateException();
15654
    }
15655
 
15656
    @Override
15657
    public boolean equals(Object that) {
15658
      if (that == null)
15659
        return false;
15660
      if (that instanceof getAllItemPricing_args)
15661
        return this.equals((getAllItemPricing_args)that);
15662
      return false;
15663
    }
15664
 
15665
    public boolean equals(getAllItemPricing_args that) {
15666
      if (that == null)
15667
        return false;
15668
 
15669
      boolean this_present_itemId = true;
15670
      boolean that_present_itemId = true;
15671
      if (this_present_itemId || that_present_itemId) {
15672
        if (!(this_present_itemId && that_present_itemId))
15673
          return false;
15674
        if (this.itemId != that.itemId)
15675
          return false;
15676
      }
15677
 
15678
      return true;
15679
    }
15680
 
15681
    @Override
15682
    public int hashCode() {
15683
      return 0;
15684
    }
15685
 
15686
    public int compareTo(getAllItemPricing_args other) {
15687
      if (!getClass().equals(other.getClass())) {
15688
        return getClass().getName().compareTo(other.getClass().getName());
15689
      }
15690
 
15691
      int lastComparison = 0;
15692
      getAllItemPricing_args typedOther = (getAllItemPricing_args)other;
15693
 
15694
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
15695
      if (lastComparison != 0) {
15696
        return lastComparison;
15697
      }
15698
      if (isSetItemId()) {
15699
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
15700
        if (lastComparison != 0) {
15701
          return lastComparison;
15702
        }
15703
      }
15704
      return 0;
15705
    }
15706
 
15707
    public _Fields fieldForId(int fieldId) {
15708
      return _Fields.findByThriftId(fieldId);
15709
    }
15710
 
15711
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
15712
      org.apache.thrift.protocol.TField field;
15713
      iprot.readStructBegin();
15714
      while (true)
15715
      {
15716
        field = iprot.readFieldBegin();
15717
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
15718
          break;
15719
        }
15720
        switch (field.id) {
15721
          case 1: // ITEM_ID
15722
            if (field.type == org.apache.thrift.protocol.TType.I64) {
15723
              this.itemId = iprot.readI64();
15724
              setItemIdIsSet(true);
15725
            } else { 
15726
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15727
            }
15728
            break;
15729
          default:
15730
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
15731
        }
15732
        iprot.readFieldEnd();
15733
      }
15734
      iprot.readStructEnd();
15735
      validate();
15736
    }
15737
 
15738
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
15739
      validate();
15740
 
15741
      oprot.writeStructBegin(STRUCT_DESC);
15742
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
15743
      oprot.writeI64(this.itemId);
15744
      oprot.writeFieldEnd();
15745
      oprot.writeFieldStop();
15746
      oprot.writeStructEnd();
15747
    }
15748
 
15749
    @Override
15750
    public String toString() {
15751
      StringBuilder sb = new StringBuilder("getAllItemPricing_args(");
15752
      boolean first = true;
15753
 
15754
      sb.append("itemId:");
15755
      sb.append(this.itemId);
15756
      first = false;
15757
      sb.append(")");
15758
      return sb.toString();
15759
    }
15760
 
15761
    public void validate() throws org.apache.thrift.TException {
15762
      // check for required fields
15763
    }
15764
 
15765
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
15766
      try {
15767
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
15768
      } catch (org.apache.thrift.TException te) {
15769
        throw new java.io.IOException(te);
15770
      }
15771
    }
15772
 
15773
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
15774
      try {
15775
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
15776
      } catch (org.apache.thrift.TException te) {
15777
        throw new java.io.IOException(te);
15778
      }
15779
    }
15780
 
15781
  }
15782
 
15783
  public static class getAllItemPricing_result implements org.apache.thrift.TBase<getAllItemPricing_result, getAllItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
15784
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllItemPricing_result");
15785
 
15786
    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);
15787
    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);
15788
 
15789
    private List<VendorItemPricing> success; // required
15790
    private InventoryServiceException cex; // required
15791
 
15792
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
15793
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
15794
      SUCCESS((short)0, "success"),
15795
      CEX((short)1, "cex");
15796
 
15797
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
15798
 
15799
      static {
15800
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
15801
          byName.put(field.getFieldName(), field);
15802
        }
15803
      }
15804
 
15805
      /**
15806
       * Find the _Fields constant that matches fieldId, or null if its not found.
15807
       */
15808
      public static _Fields findByThriftId(int fieldId) {
15809
        switch(fieldId) {
15810
          case 0: // SUCCESS
15811
            return SUCCESS;
15812
          case 1: // CEX
15813
            return CEX;
15814
          default:
15815
            return null;
15816
        }
15817
      }
15818
 
15819
      /**
15820
       * Find the _Fields constant that matches fieldId, throwing an exception
15821
       * if it is not found.
15822
       */
15823
      public static _Fields findByThriftIdOrThrow(int fieldId) {
15824
        _Fields fields = findByThriftId(fieldId);
15825
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
15826
        return fields;
15827
      }
15828
 
15829
      /**
15830
       * Find the _Fields constant that matches name, or null if its not found.
15831
       */
15832
      public static _Fields findByName(String name) {
15833
        return byName.get(name);
15834
      }
15835
 
15836
      private final short _thriftId;
15837
      private final String _fieldName;
15838
 
15839
      _Fields(short thriftId, String fieldName) {
15840
        _thriftId = thriftId;
15841
        _fieldName = fieldName;
15842
      }
15843
 
15844
      public short getThriftFieldId() {
15845
        return _thriftId;
15846
      }
15847
 
15848
      public String getFieldName() {
15849
        return _fieldName;
15850
      }
15851
    }
15852
 
15853
    // isset id assignments
15854
 
15855
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
15856
    static {
15857
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
15858
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15859
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
15860
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class))));
15861
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
15862
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
15863
      metaDataMap = Collections.unmodifiableMap(tmpMap);
15864
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllItemPricing_result.class, metaDataMap);
15865
    }
15866
 
15867
    public getAllItemPricing_result() {
15868
    }
15869
 
15870
    public getAllItemPricing_result(
15871
      List<VendorItemPricing> success,
15872
      InventoryServiceException cex)
15873
    {
15874
      this();
15875
      this.success = success;
15876
      this.cex = cex;
15877
    }
15878
 
15879
    /**
15880
     * Performs a deep copy on <i>other</i>.
15881
     */
15882
    public getAllItemPricing_result(getAllItemPricing_result other) {
15883
      if (other.isSetSuccess()) {
15884
        List<VendorItemPricing> __this__success = new ArrayList<VendorItemPricing>();
15885
        for (VendorItemPricing other_element : other.success) {
15886
          __this__success.add(new VendorItemPricing(other_element));
15887
        }
15888
        this.success = __this__success;
15889
      }
15890
      if (other.isSetCex()) {
15891
        this.cex = new InventoryServiceException(other.cex);
15892
      }
15893
    }
15894
 
15895
    public getAllItemPricing_result deepCopy() {
15896
      return new getAllItemPricing_result(this);
15897
    }
15898
 
15899
    @Override
15900
    public void clear() {
15901
      this.success = null;
15902
      this.cex = null;
15903
    }
15904
 
15905
    public int getSuccessSize() {
15906
      return (this.success == null) ? 0 : this.success.size();
15907
    }
15908
 
15909
    public java.util.Iterator<VendorItemPricing> getSuccessIterator() {
15910
      return (this.success == null) ? null : this.success.iterator();
15911
    }
15912
 
15913
    public void addToSuccess(VendorItemPricing elem) {
15914
      if (this.success == null) {
15915
        this.success = new ArrayList<VendorItemPricing>();
15916
      }
15917
      this.success.add(elem);
15918
    }
15919
 
15920
    public List<VendorItemPricing> getSuccess() {
15921
      return this.success;
15922
    }
15923
 
15924
    public void setSuccess(List<VendorItemPricing> success) {
15925
      this.success = success;
15926
    }
15927
 
15928
    public void unsetSuccess() {
15929
      this.success = null;
15930
    }
15931
 
15932
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
15933
    public boolean isSetSuccess() {
15934
      return this.success != null;
15935
    }
15936
 
15937
    public void setSuccessIsSet(boolean value) {
15938
      if (!value) {
15939
        this.success = null;
15940
      }
15941
    }
15942
 
15943
    public InventoryServiceException getCex() {
15944
      return this.cex;
15945
    }
15946
 
15947
    public void setCex(InventoryServiceException cex) {
15948
      this.cex = cex;
15949
    }
15950
 
15951
    public void unsetCex() {
15952
      this.cex = null;
15953
    }
15954
 
15955
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
15956
    public boolean isSetCex() {
15957
      return this.cex != null;
15958
    }
15959
 
15960
    public void setCexIsSet(boolean value) {
15961
      if (!value) {
15962
        this.cex = null;
15963
      }
15964
    }
15965
 
15966
    public void setFieldValue(_Fields field, Object value) {
15967
      switch (field) {
15968
      case SUCCESS:
15969
        if (value == null) {
15970
          unsetSuccess();
15971
        } else {
15972
          setSuccess((List<VendorItemPricing>)value);
15973
        }
15974
        break;
15975
 
15976
      case CEX:
15977
        if (value == null) {
15978
          unsetCex();
15979
        } else {
15980
          setCex((InventoryServiceException)value);
15981
        }
15982
        break;
15983
 
15984
      }
15985
    }
15986
 
15987
    public Object getFieldValue(_Fields field) {
15988
      switch (field) {
15989
      case SUCCESS:
15990
        return getSuccess();
15991
 
15992
      case CEX:
15993
        return getCex();
15994
 
15995
      }
15996
      throw new IllegalStateException();
15997
    }
15998
 
15999
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16000
    public boolean isSet(_Fields field) {
16001
      if (field == null) {
16002
        throw new IllegalArgumentException();
16003
      }
16004
 
16005
      switch (field) {
16006
      case SUCCESS:
16007
        return isSetSuccess();
16008
      case CEX:
16009
        return isSetCex();
16010
      }
16011
      throw new IllegalStateException();
16012
    }
16013
 
16014
    @Override
16015
    public boolean equals(Object that) {
16016
      if (that == null)
16017
        return false;
16018
      if (that instanceof getAllItemPricing_result)
16019
        return this.equals((getAllItemPricing_result)that);
16020
      return false;
16021
    }
16022
 
16023
    public boolean equals(getAllItemPricing_result that) {
16024
      if (that == null)
16025
        return false;
16026
 
16027
      boolean this_present_success = true && this.isSetSuccess();
16028
      boolean that_present_success = true && that.isSetSuccess();
16029
      if (this_present_success || that_present_success) {
16030
        if (!(this_present_success && that_present_success))
16031
          return false;
16032
        if (!this.success.equals(that.success))
16033
          return false;
16034
      }
16035
 
16036
      boolean this_present_cex = true && this.isSetCex();
16037
      boolean that_present_cex = true && that.isSetCex();
16038
      if (this_present_cex || that_present_cex) {
16039
        if (!(this_present_cex && that_present_cex))
16040
          return false;
16041
        if (!this.cex.equals(that.cex))
16042
          return false;
16043
      }
16044
 
16045
      return true;
16046
    }
16047
 
16048
    @Override
16049
    public int hashCode() {
16050
      return 0;
16051
    }
16052
 
16053
    public int compareTo(getAllItemPricing_result other) {
16054
      if (!getClass().equals(other.getClass())) {
16055
        return getClass().getName().compareTo(other.getClass().getName());
16056
      }
16057
 
16058
      int lastComparison = 0;
16059
      getAllItemPricing_result typedOther = (getAllItemPricing_result)other;
16060
 
16061
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
16062
      if (lastComparison != 0) {
16063
        return lastComparison;
16064
      }
16065
      if (isSetSuccess()) {
16066
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
16067
        if (lastComparison != 0) {
16068
          return lastComparison;
16069
        }
16070
      }
16071
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
16072
      if (lastComparison != 0) {
16073
        return lastComparison;
16074
      }
16075
      if (isSetCex()) {
16076
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
16077
        if (lastComparison != 0) {
16078
          return lastComparison;
16079
        }
16080
      }
16081
      return 0;
16082
    }
16083
 
16084
    public _Fields fieldForId(int fieldId) {
16085
      return _Fields.findByThriftId(fieldId);
16086
    }
16087
 
16088
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16089
      org.apache.thrift.protocol.TField field;
16090
      iprot.readStructBegin();
16091
      while (true)
16092
      {
16093
        field = iprot.readFieldBegin();
16094
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16095
          break;
16096
        }
16097
        switch (field.id) {
16098
          case 0: // SUCCESS
16099
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
16100
              {
16101
                org.apache.thrift.protocol.TList _list32 = iprot.readListBegin();
16102
                this.success = new ArrayList<VendorItemPricing>(_list32.size);
16103
                for (int _i33 = 0; _i33 < _list32.size; ++_i33)
16104
                {
16105
                  VendorItemPricing _elem34; // required
16106
                  _elem34 = new VendorItemPricing();
16107
                  _elem34.read(iprot);
16108
                  this.success.add(_elem34);
16109
                }
16110
                iprot.readListEnd();
16111
              }
16112
            } else { 
16113
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16114
            }
16115
            break;
16116
          case 1: // CEX
16117
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16118
              this.cex = new InventoryServiceException();
16119
              this.cex.read(iprot);
16120
            } else { 
16121
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16122
            }
16123
            break;
16124
          default:
16125
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16126
        }
16127
        iprot.readFieldEnd();
16128
      }
16129
      iprot.readStructEnd();
16130
      validate();
16131
    }
16132
 
16133
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16134
      oprot.writeStructBegin(STRUCT_DESC);
16135
 
16136
      if (this.isSetSuccess()) {
16137
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
16138
        {
16139
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
16140
          for (VendorItemPricing _iter35 : this.success)
16141
          {
16142
            _iter35.write(oprot);
16143
          }
16144
          oprot.writeListEnd();
16145
        }
16146
        oprot.writeFieldEnd();
16147
      } else if (this.isSetCex()) {
16148
        oprot.writeFieldBegin(CEX_FIELD_DESC);
16149
        this.cex.write(oprot);
16150
        oprot.writeFieldEnd();
16151
      }
16152
      oprot.writeFieldStop();
16153
      oprot.writeStructEnd();
16154
    }
16155
 
16156
    @Override
16157
    public String toString() {
16158
      StringBuilder sb = new StringBuilder("getAllItemPricing_result(");
16159
      boolean first = true;
16160
 
16161
      sb.append("success:");
16162
      if (this.success == null) {
16163
        sb.append("null");
16164
      } else {
16165
        sb.append(this.success);
16166
      }
16167
      first = false;
16168
      if (!first) sb.append(", ");
16169
      sb.append("cex:");
16170
      if (this.cex == null) {
16171
        sb.append("null");
16172
      } else {
16173
        sb.append(this.cex);
16174
      }
16175
      first = false;
16176
      sb.append(")");
16177
      return sb.toString();
16178
    }
16179
 
16180
    public void validate() throws org.apache.thrift.TException {
16181
      // check for required fields
16182
    }
16183
 
16184
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16185
      try {
16186
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16187
      } catch (org.apache.thrift.TException te) {
16188
        throw new java.io.IOException(te);
16189
      }
16190
    }
16191
 
16192
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16193
      try {
16194
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16195
      } catch (org.apache.thrift.TException te) {
16196
        throw new java.io.IOException(te);
16197
      }
16198
    }
16199
 
16200
  }
16201
 
16202
  public static class addVendorItemPricing_args implements org.apache.thrift.TBase<addVendorItemPricing_args, addVendorItemPricing_args._Fields>, java.io.Serializable, Cloneable   {
16203
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemPricing_args");
16204
 
16205
    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);
16206
 
16207
    private VendorItemPricing vendorItemPricing; // required
16208
 
16209
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16210
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16211
      VENDOR_ITEM_PRICING((short)1, "vendorItemPricing");
16212
 
16213
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16214
 
16215
      static {
16216
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16217
          byName.put(field.getFieldName(), field);
16218
        }
16219
      }
16220
 
16221
      /**
16222
       * Find the _Fields constant that matches fieldId, or null if its not found.
16223
       */
16224
      public static _Fields findByThriftId(int fieldId) {
16225
        switch(fieldId) {
16226
          case 1: // VENDOR_ITEM_PRICING
16227
            return VENDOR_ITEM_PRICING;
16228
          default:
16229
            return null;
16230
        }
16231
      }
16232
 
16233
      /**
16234
       * Find the _Fields constant that matches fieldId, throwing an exception
16235
       * if it is not found.
16236
       */
16237
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16238
        _Fields fields = findByThriftId(fieldId);
16239
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16240
        return fields;
16241
      }
16242
 
16243
      /**
16244
       * Find the _Fields constant that matches name, or null if its not found.
16245
       */
16246
      public static _Fields findByName(String name) {
16247
        return byName.get(name);
16248
      }
16249
 
16250
      private final short _thriftId;
16251
      private final String _fieldName;
16252
 
16253
      _Fields(short thriftId, String fieldName) {
16254
        _thriftId = thriftId;
16255
        _fieldName = fieldName;
16256
      }
16257
 
16258
      public short getThriftFieldId() {
16259
        return _thriftId;
16260
      }
16261
 
16262
      public String getFieldName() {
16263
        return _fieldName;
16264
      }
16265
    }
16266
 
16267
    // isset id assignments
16268
 
16269
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16270
    static {
16271
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16272
      tmpMap.put(_Fields.VENDOR_ITEM_PRICING, new org.apache.thrift.meta_data.FieldMetaData("vendorItemPricing", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16273
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemPricing.class)));
16274
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16275
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemPricing_args.class, metaDataMap);
16276
    }
16277
 
16278
    public addVendorItemPricing_args() {
16279
    }
16280
 
16281
    public addVendorItemPricing_args(
16282
      VendorItemPricing vendorItemPricing)
16283
    {
16284
      this();
16285
      this.vendorItemPricing = vendorItemPricing;
16286
    }
16287
 
16288
    /**
16289
     * Performs a deep copy on <i>other</i>.
16290
     */
16291
    public addVendorItemPricing_args(addVendorItemPricing_args other) {
16292
      if (other.isSetVendorItemPricing()) {
16293
        this.vendorItemPricing = new VendorItemPricing(other.vendorItemPricing);
16294
      }
16295
    }
16296
 
16297
    public addVendorItemPricing_args deepCopy() {
16298
      return new addVendorItemPricing_args(this);
16299
    }
16300
 
16301
    @Override
16302
    public void clear() {
16303
      this.vendorItemPricing = null;
16304
    }
16305
 
16306
    public VendorItemPricing getVendorItemPricing() {
16307
      return this.vendorItemPricing;
16308
    }
16309
 
16310
    public void setVendorItemPricing(VendorItemPricing vendorItemPricing) {
16311
      this.vendorItemPricing = vendorItemPricing;
16312
    }
16313
 
16314
    public void unsetVendorItemPricing() {
16315
      this.vendorItemPricing = null;
16316
    }
16317
 
16318
    /** Returns true if field vendorItemPricing is set (has been assigned a value) and false otherwise */
16319
    public boolean isSetVendorItemPricing() {
16320
      return this.vendorItemPricing != null;
16321
    }
16322
 
16323
    public void setVendorItemPricingIsSet(boolean value) {
16324
      if (!value) {
16325
        this.vendorItemPricing = null;
16326
      }
16327
    }
16328
 
16329
    public void setFieldValue(_Fields field, Object value) {
16330
      switch (field) {
16331
      case VENDOR_ITEM_PRICING:
16332
        if (value == null) {
16333
          unsetVendorItemPricing();
16334
        } else {
16335
          setVendorItemPricing((VendorItemPricing)value);
16336
        }
16337
        break;
16338
 
16339
      }
16340
    }
16341
 
16342
    public Object getFieldValue(_Fields field) {
16343
      switch (field) {
16344
      case VENDOR_ITEM_PRICING:
16345
        return getVendorItemPricing();
16346
 
16347
      }
16348
      throw new IllegalStateException();
16349
    }
16350
 
16351
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16352
    public boolean isSet(_Fields field) {
16353
      if (field == null) {
16354
        throw new IllegalArgumentException();
16355
      }
16356
 
16357
      switch (field) {
16358
      case VENDOR_ITEM_PRICING:
16359
        return isSetVendorItemPricing();
16360
      }
16361
      throw new IllegalStateException();
16362
    }
16363
 
16364
    @Override
16365
    public boolean equals(Object that) {
16366
      if (that == null)
16367
        return false;
16368
      if (that instanceof addVendorItemPricing_args)
16369
        return this.equals((addVendorItemPricing_args)that);
16370
      return false;
16371
    }
16372
 
16373
    public boolean equals(addVendorItemPricing_args that) {
16374
      if (that == null)
16375
        return false;
16376
 
16377
      boolean this_present_vendorItemPricing = true && this.isSetVendorItemPricing();
16378
      boolean that_present_vendorItemPricing = true && that.isSetVendorItemPricing();
16379
      if (this_present_vendorItemPricing || that_present_vendorItemPricing) {
16380
        if (!(this_present_vendorItemPricing && that_present_vendorItemPricing))
16381
          return false;
16382
        if (!this.vendorItemPricing.equals(that.vendorItemPricing))
16383
          return false;
16384
      }
16385
 
16386
      return true;
16387
    }
16388
 
16389
    @Override
16390
    public int hashCode() {
16391
      return 0;
16392
    }
16393
 
16394
    public int compareTo(addVendorItemPricing_args other) {
16395
      if (!getClass().equals(other.getClass())) {
16396
        return getClass().getName().compareTo(other.getClass().getName());
16397
      }
16398
 
16399
      int lastComparison = 0;
16400
      addVendorItemPricing_args typedOther = (addVendorItemPricing_args)other;
16401
 
16402
      lastComparison = Boolean.valueOf(isSetVendorItemPricing()).compareTo(typedOther.isSetVendorItemPricing());
16403
      if (lastComparison != 0) {
16404
        return lastComparison;
16405
      }
16406
      if (isSetVendorItemPricing()) {
16407
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorItemPricing, typedOther.vendorItemPricing);
16408
        if (lastComparison != 0) {
16409
          return lastComparison;
16410
        }
16411
      }
16412
      return 0;
16413
    }
16414
 
16415
    public _Fields fieldForId(int fieldId) {
16416
      return _Fields.findByThriftId(fieldId);
16417
    }
16418
 
16419
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16420
      org.apache.thrift.protocol.TField field;
16421
      iprot.readStructBegin();
16422
      while (true)
16423
      {
16424
        field = iprot.readFieldBegin();
16425
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16426
          break;
16427
        }
16428
        switch (field.id) {
16429
          case 1: // VENDOR_ITEM_PRICING
16430
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16431
              this.vendorItemPricing = new VendorItemPricing();
16432
              this.vendorItemPricing.read(iprot);
16433
            } else { 
16434
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16435
            }
16436
            break;
16437
          default:
16438
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16439
        }
16440
        iprot.readFieldEnd();
16441
      }
16442
      iprot.readStructEnd();
16443
      validate();
16444
    }
16445
 
16446
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16447
      validate();
16448
 
16449
      oprot.writeStructBegin(STRUCT_DESC);
16450
      if (this.vendorItemPricing != null) {
16451
        oprot.writeFieldBegin(VENDOR_ITEM_PRICING_FIELD_DESC);
16452
        this.vendorItemPricing.write(oprot);
16453
        oprot.writeFieldEnd();
16454
      }
16455
      oprot.writeFieldStop();
16456
      oprot.writeStructEnd();
16457
    }
16458
 
16459
    @Override
16460
    public String toString() {
16461
      StringBuilder sb = new StringBuilder("addVendorItemPricing_args(");
16462
      boolean first = true;
16463
 
16464
      sb.append("vendorItemPricing:");
16465
      if (this.vendorItemPricing == null) {
16466
        sb.append("null");
16467
      } else {
16468
        sb.append(this.vendorItemPricing);
16469
      }
16470
      first = false;
16471
      sb.append(")");
16472
      return sb.toString();
16473
    }
16474
 
16475
    public void validate() throws org.apache.thrift.TException {
16476
      // check for required fields
16477
    }
16478
 
16479
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16480
      try {
16481
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16482
      } catch (org.apache.thrift.TException te) {
16483
        throw new java.io.IOException(te);
16484
      }
16485
    }
16486
 
16487
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16488
      try {
16489
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16490
      } catch (org.apache.thrift.TException te) {
16491
        throw new java.io.IOException(te);
16492
      }
16493
    }
16494
 
16495
  }
16496
 
16497
  public static class addVendorItemPricing_result implements org.apache.thrift.TBase<addVendorItemPricing_result, addVendorItemPricing_result._Fields>, java.io.Serializable, Cloneable   {
16498
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemPricing_result");
16499
 
16500
    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);
16501
 
16502
    private InventoryServiceException cex; // required
16503
 
16504
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16505
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16506
      CEX((short)1, "cex");
16507
 
16508
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16509
 
16510
      static {
16511
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16512
          byName.put(field.getFieldName(), field);
16513
        }
16514
      }
16515
 
16516
      /**
16517
       * Find the _Fields constant that matches fieldId, or null if its not found.
16518
       */
16519
      public static _Fields findByThriftId(int fieldId) {
16520
        switch(fieldId) {
16521
          case 1: // CEX
16522
            return CEX;
16523
          default:
16524
            return null;
16525
        }
16526
      }
16527
 
16528
      /**
16529
       * Find the _Fields constant that matches fieldId, throwing an exception
16530
       * if it is not found.
16531
       */
16532
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16533
        _Fields fields = findByThriftId(fieldId);
16534
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16535
        return fields;
16536
      }
16537
 
16538
      /**
16539
       * Find the _Fields constant that matches name, or null if its not found.
16540
       */
16541
      public static _Fields findByName(String name) {
16542
        return byName.get(name);
16543
      }
16544
 
16545
      private final short _thriftId;
16546
      private final String _fieldName;
16547
 
16548
      _Fields(short thriftId, String fieldName) {
16549
        _thriftId = thriftId;
16550
        _fieldName = fieldName;
16551
      }
16552
 
16553
      public short getThriftFieldId() {
16554
        return _thriftId;
16555
      }
16556
 
16557
      public String getFieldName() {
16558
        return _fieldName;
16559
      }
16560
    }
16561
 
16562
    // isset id assignments
16563
 
16564
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16565
    static {
16566
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16567
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16568
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
16569
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16570
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemPricing_result.class, metaDataMap);
16571
    }
16572
 
16573
    public addVendorItemPricing_result() {
16574
    }
16575
 
16576
    public addVendorItemPricing_result(
16577
      InventoryServiceException cex)
16578
    {
16579
      this();
16580
      this.cex = cex;
16581
    }
16582
 
16583
    /**
16584
     * Performs a deep copy on <i>other</i>.
16585
     */
16586
    public addVendorItemPricing_result(addVendorItemPricing_result other) {
16587
      if (other.isSetCex()) {
16588
        this.cex = new InventoryServiceException(other.cex);
16589
      }
16590
    }
16591
 
16592
    public addVendorItemPricing_result deepCopy() {
16593
      return new addVendorItemPricing_result(this);
16594
    }
16595
 
16596
    @Override
16597
    public void clear() {
16598
      this.cex = null;
16599
    }
16600
 
16601
    public InventoryServiceException getCex() {
16602
      return this.cex;
16603
    }
16604
 
16605
    public void setCex(InventoryServiceException cex) {
16606
      this.cex = cex;
16607
    }
16608
 
16609
    public void unsetCex() {
16610
      this.cex = null;
16611
    }
16612
 
16613
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
16614
    public boolean isSetCex() {
16615
      return this.cex != null;
16616
    }
16617
 
16618
    public void setCexIsSet(boolean value) {
16619
      if (!value) {
16620
        this.cex = null;
16621
      }
16622
    }
16623
 
16624
    public void setFieldValue(_Fields field, Object value) {
16625
      switch (field) {
16626
      case CEX:
16627
        if (value == null) {
16628
          unsetCex();
16629
        } else {
16630
          setCex((InventoryServiceException)value);
16631
        }
16632
        break;
16633
 
16634
      }
16635
    }
16636
 
16637
    public Object getFieldValue(_Fields field) {
16638
      switch (field) {
16639
      case CEX:
16640
        return getCex();
16641
 
16642
      }
16643
      throw new IllegalStateException();
16644
    }
16645
 
16646
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16647
    public boolean isSet(_Fields field) {
16648
      if (field == null) {
16649
        throw new IllegalArgumentException();
16650
      }
16651
 
16652
      switch (field) {
16653
      case CEX:
16654
        return isSetCex();
16655
      }
16656
      throw new IllegalStateException();
16657
    }
16658
 
16659
    @Override
16660
    public boolean equals(Object that) {
16661
      if (that == null)
16662
        return false;
16663
      if (that instanceof addVendorItemPricing_result)
16664
        return this.equals((addVendorItemPricing_result)that);
16665
      return false;
16666
    }
16667
 
16668
    public boolean equals(addVendorItemPricing_result that) {
16669
      if (that == null)
16670
        return false;
16671
 
16672
      boolean this_present_cex = true && this.isSetCex();
16673
      boolean that_present_cex = true && that.isSetCex();
16674
      if (this_present_cex || that_present_cex) {
16675
        if (!(this_present_cex && that_present_cex))
16676
          return false;
16677
        if (!this.cex.equals(that.cex))
16678
          return false;
16679
      }
16680
 
16681
      return true;
16682
    }
16683
 
16684
    @Override
16685
    public int hashCode() {
16686
      return 0;
16687
    }
16688
 
16689
    public int compareTo(addVendorItemPricing_result other) {
16690
      if (!getClass().equals(other.getClass())) {
16691
        return getClass().getName().compareTo(other.getClass().getName());
16692
      }
16693
 
16694
      int lastComparison = 0;
16695
      addVendorItemPricing_result typedOther = (addVendorItemPricing_result)other;
16696
 
16697
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
16698
      if (lastComparison != 0) {
16699
        return lastComparison;
16700
      }
16701
      if (isSetCex()) {
16702
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
16703
        if (lastComparison != 0) {
16704
          return lastComparison;
16705
        }
16706
      }
16707
      return 0;
16708
    }
16709
 
16710
    public _Fields fieldForId(int fieldId) {
16711
      return _Fields.findByThriftId(fieldId);
16712
    }
16713
 
16714
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
16715
      org.apache.thrift.protocol.TField field;
16716
      iprot.readStructBegin();
16717
      while (true)
16718
      {
16719
        field = iprot.readFieldBegin();
16720
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
16721
          break;
16722
        }
16723
        switch (field.id) {
16724
          case 1: // CEX
16725
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
16726
              this.cex = new InventoryServiceException();
16727
              this.cex.read(iprot);
16728
            } else { 
16729
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16730
            }
16731
            break;
16732
          default:
16733
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
16734
        }
16735
        iprot.readFieldEnd();
16736
      }
16737
      iprot.readStructEnd();
16738
      validate();
16739
    }
16740
 
16741
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
16742
      oprot.writeStructBegin(STRUCT_DESC);
16743
 
16744
      if (this.isSetCex()) {
16745
        oprot.writeFieldBegin(CEX_FIELD_DESC);
16746
        this.cex.write(oprot);
16747
        oprot.writeFieldEnd();
16748
      }
16749
      oprot.writeFieldStop();
16750
      oprot.writeStructEnd();
16751
    }
16752
 
16753
    @Override
16754
    public String toString() {
16755
      StringBuilder sb = new StringBuilder("addVendorItemPricing_result(");
16756
      boolean first = true;
16757
 
16758
      sb.append("cex:");
16759
      if (this.cex == null) {
16760
        sb.append("null");
16761
      } else {
16762
        sb.append(this.cex);
16763
      }
16764
      first = false;
16765
      sb.append(")");
16766
      return sb.toString();
16767
    }
16768
 
16769
    public void validate() throws org.apache.thrift.TException {
16770
      // check for required fields
16771
    }
16772
 
16773
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
16774
      try {
16775
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
16776
      } catch (org.apache.thrift.TException te) {
16777
        throw new java.io.IOException(te);
16778
      }
16779
    }
16780
 
16781
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
16782
      try {
16783
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
16784
      } catch (org.apache.thrift.TException te) {
16785
        throw new java.io.IOException(te);
16786
      }
16787
    }
16788
 
16789
  }
16790
 
16791
  public static class getVendor_args implements org.apache.thrift.TBase<getVendor_args, getVendor_args._Fields>, java.io.Serializable, Cloneable   {
16792
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendor_args");
16793
 
16794
    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);
16795
 
16796
    private long vendorId; // required
16797
 
16798
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
16799
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
16800
      VENDOR_ID((short)1, "vendorId");
16801
 
16802
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
16803
 
16804
      static {
16805
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
16806
          byName.put(field.getFieldName(), field);
16807
        }
16808
      }
16809
 
16810
      /**
16811
       * Find the _Fields constant that matches fieldId, or null if its not found.
16812
       */
16813
      public static _Fields findByThriftId(int fieldId) {
16814
        switch(fieldId) {
16815
          case 1: // VENDOR_ID
16816
            return VENDOR_ID;
16817
          default:
16818
            return null;
16819
        }
16820
      }
16821
 
16822
      /**
16823
       * Find the _Fields constant that matches fieldId, throwing an exception
16824
       * if it is not found.
16825
       */
16826
      public static _Fields findByThriftIdOrThrow(int fieldId) {
16827
        _Fields fields = findByThriftId(fieldId);
16828
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
16829
        return fields;
16830
      }
16831
 
16832
      /**
16833
       * Find the _Fields constant that matches name, or null if its not found.
16834
       */
16835
      public static _Fields findByName(String name) {
16836
        return byName.get(name);
16837
      }
16838
 
16839
      private final short _thriftId;
16840
      private final String _fieldName;
16841
 
16842
      _Fields(short thriftId, String fieldName) {
16843
        _thriftId = thriftId;
16844
        _fieldName = fieldName;
16845
      }
16846
 
16847
      public short getThriftFieldId() {
16848
        return _thriftId;
16849
      }
16850
 
16851
      public String getFieldName() {
16852
        return _fieldName;
16853
      }
16854
    }
16855
 
16856
    // isset id assignments
16857
    private static final int __VENDORID_ISSET_ID = 0;
16858
    private BitSet __isset_bit_vector = new BitSet(1);
16859
 
16860
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
16861
    static {
16862
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
16863
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
16864
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
16865
      metaDataMap = Collections.unmodifiableMap(tmpMap);
16866
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendor_args.class, metaDataMap);
16867
    }
16868
 
16869
    public getVendor_args() {
16870
    }
16871
 
16872
    public getVendor_args(
16873
      long vendorId)
16874
    {
16875
      this();
16876
      this.vendorId = vendorId;
16877
      setVendorIdIsSet(true);
16878
    }
16879
 
16880
    /**
16881
     * Performs a deep copy on <i>other</i>.
16882
     */
16883
    public getVendor_args(getVendor_args other) {
16884
      __isset_bit_vector.clear();
16885
      __isset_bit_vector.or(other.__isset_bit_vector);
16886
      this.vendorId = other.vendorId;
16887
    }
16888
 
16889
    public getVendor_args deepCopy() {
16890
      return new getVendor_args(this);
16891
    }
16892
 
16893
    @Override
16894
    public void clear() {
16895
      setVendorIdIsSet(false);
16896
      this.vendorId = 0;
16897
    }
16898
 
16899
    public long getVendorId() {
16900
      return this.vendorId;
16901
    }
16902
 
16903
    public void setVendorId(long vendorId) {
16904
      this.vendorId = vendorId;
16905
      setVendorIdIsSet(true);
16906
    }
16907
 
16908
    public void unsetVendorId() {
16909
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
16910
    }
16911
 
16912
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
16913
    public boolean isSetVendorId() {
16914
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
16915
    }
16916
 
16917
    public void setVendorIdIsSet(boolean value) {
16918
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
16919
    }
16920
 
16921
    public void setFieldValue(_Fields field, Object value) {
16922
      switch (field) {
16923
      case VENDOR_ID:
16924
        if (value == null) {
16925
          unsetVendorId();
16926
        } else {
16927
          setVendorId((Long)value);
16928
        }
16929
        break;
16930
 
16931
      }
16932
    }
16933
 
16934
    public Object getFieldValue(_Fields field) {
16935
      switch (field) {
16936
      case VENDOR_ID:
16937
        return Long.valueOf(getVendorId());
16938
 
16939
      }
16940
      throw new IllegalStateException();
16941
    }
16942
 
16943
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
16944
    public boolean isSet(_Fields field) {
16945
      if (field == null) {
16946
        throw new IllegalArgumentException();
16947
      }
16948
 
16949
      switch (field) {
16950
      case VENDOR_ID:
16951
        return isSetVendorId();
16952
      }
16953
      throw new IllegalStateException();
16954
    }
16955
 
16956
    @Override
16957
    public boolean equals(Object that) {
16958
      if (that == null)
16959
        return false;
16960
      if (that instanceof getVendor_args)
16961
        return this.equals((getVendor_args)that);
16962
      return false;
16963
    }
16964
 
16965
    public boolean equals(getVendor_args that) {
16966
      if (that == null)
16967
        return false;
16968
 
16969
      boolean this_present_vendorId = true;
16970
      boolean that_present_vendorId = true;
16971
      if (this_present_vendorId || that_present_vendorId) {
16972
        if (!(this_present_vendorId && that_present_vendorId))
16973
          return false;
16974
        if (this.vendorId != that.vendorId)
16975
          return false;
16976
      }
16977
 
16978
      return true;
16979
    }
16980
 
16981
    @Override
16982
    public int hashCode() {
16983
      return 0;
16984
    }
16985
 
16986
    public int compareTo(getVendor_args other) {
16987
      if (!getClass().equals(other.getClass())) {
16988
        return getClass().getName().compareTo(other.getClass().getName());
16989
      }
16990
 
16991
      int lastComparison = 0;
16992
      getVendor_args typedOther = (getVendor_args)other;
16993
 
16994
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
16995
      if (lastComparison != 0) {
16996
        return lastComparison;
16997
      }
16998
      if (isSetVendorId()) {
16999
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
17000
        if (lastComparison != 0) {
17001
          return lastComparison;
17002
        }
17003
      }
17004
      return 0;
17005
    }
17006
 
17007
    public _Fields fieldForId(int fieldId) {
17008
      return _Fields.findByThriftId(fieldId);
17009
    }
17010
 
17011
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17012
      org.apache.thrift.protocol.TField field;
17013
      iprot.readStructBegin();
17014
      while (true)
17015
      {
17016
        field = iprot.readFieldBegin();
17017
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17018
          break;
17019
        }
17020
        switch (field.id) {
17021
          case 1: // VENDOR_ID
17022
            if (field.type == org.apache.thrift.protocol.TType.I64) {
17023
              this.vendorId = iprot.readI64();
17024
              setVendorIdIsSet(true);
17025
            } else { 
17026
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17027
            }
17028
            break;
17029
          default:
17030
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17031
        }
17032
        iprot.readFieldEnd();
17033
      }
17034
      iprot.readStructEnd();
17035
      validate();
17036
    }
17037
 
17038
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17039
      validate();
17040
 
17041
      oprot.writeStructBegin(STRUCT_DESC);
17042
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
17043
      oprot.writeI64(this.vendorId);
17044
      oprot.writeFieldEnd();
17045
      oprot.writeFieldStop();
17046
      oprot.writeStructEnd();
17047
    }
17048
 
17049
    @Override
17050
    public String toString() {
17051
      StringBuilder sb = new StringBuilder("getVendor_args(");
17052
      boolean first = true;
17053
 
17054
      sb.append("vendorId:");
17055
      sb.append(this.vendorId);
17056
      first = false;
17057
      sb.append(")");
17058
      return sb.toString();
17059
    }
17060
 
17061
    public void validate() throws org.apache.thrift.TException {
17062
      // check for required fields
17063
    }
17064
 
17065
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17066
      try {
17067
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17068
      } catch (org.apache.thrift.TException te) {
17069
        throw new java.io.IOException(te);
17070
      }
17071
    }
17072
 
17073
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17074
      try {
17075
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
17076
        __isset_bit_vector = new BitSet(1);
17077
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17078
      } catch (org.apache.thrift.TException te) {
17079
        throw new java.io.IOException(te);
17080
      }
17081
    }
17082
 
17083
  }
17084
 
17085
  public static class getVendor_result implements org.apache.thrift.TBase<getVendor_result, getVendor_result._Fields>, java.io.Serializable, Cloneable   {
17086
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendor_result");
17087
 
17088
    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);
17089
 
17090
    private Vendor success; // required
17091
 
17092
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17093
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17094
      SUCCESS((short)0, "success");
17095
 
17096
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17097
 
17098
      static {
17099
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17100
          byName.put(field.getFieldName(), field);
17101
        }
17102
      }
17103
 
17104
      /**
17105
       * Find the _Fields constant that matches fieldId, or null if its not found.
17106
       */
17107
      public static _Fields findByThriftId(int fieldId) {
17108
        switch(fieldId) {
17109
          case 0: // SUCCESS
17110
            return SUCCESS;
17111
          default:
17112
            return null;
17113
        }
17114
      }
17115
 
17116
      /**
17117
       * Find the _Fields constant that matches fieldId, throwing an exception
17118
       * if it is not found.
17119
       */
17120
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17121
        _Fields fields = findByThriftId(fieldId);
17122
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17123
        return fields;
17124
      }
17125
 
17126
      /**
17127
       * Find the _Fields constant that matches name, or null if its not found.
17128
       */
17129
      public static _Fields findByName(String name) {
17130
        return byName.get(name);
17131
      }
17132
 
17133
      private final short _thriftId;
17134
      private final String _fieldName;
17135
 
17136
      _Fields(short thriftId, String fieldName) {
17137
        _thriftId = thriftId;
17138
        _fieldName = fieldName;
17139
      }
17140
 
17141
      public short getThriftFieldId() {
17142
        return _thriftId;
17143
      }
17144
 
17145
      public String getFieldName() {
17146
        return _fieldName;
17147
      }
17148
    }
17149
 
17150
    // isset id assignments
17151
 
17152
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17153
    static {
17154
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17155
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17156
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class)));
17157
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17158
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendor_result.class, metaDataMap);
17159
    }
17160
 
17161
    public getVendor_result() {
17162
    }
17163
 
17164
    public getVendor_result(
17165
      Vendor success)
17166
    {
17167
      this();
17168
      this.success = success;
17169
    }
17170
 
17171
    /**
17172
     * Performs a deep copy on <i>other</i>.
17173
     */
17174
    public getVendor_result(getVendor_result other) {
17175
      if (other.isSetSuccess()) {
17176
        this.success = new Vendor(other.success);
17177
      }
17178
    }
17179
 
17180
    public getVendor_result deepCopy() {
17181
      return new getVendor_result(this);
17182
    }
17183
 
17184
    @Override
17185
    public void clear() {
17186
      this.success = null;
17187
    }
17188
 
17189
    public Vendor getSuccess() {
17190
      return this.success;
17191
    }
17192
 
17193
    public void setSuccess(Vendor success) {
17194
      this.success = success;
17195
    }
17196
 
17197
    public void unsetSuccess() {
17198
      this.success = null;
17199
    }
17200
 
17201
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17202
    public boolean isSetSuccess() {
17203
      return this.success != null;
17204
    }
17205
 
17206
    public void setSuccessIsSet(boolean value) {
17207
      if (!value) {
17208
        this.success = null;
17209
      }
17210
    }
17211
 
17212
    public void setFieldValue(_Fields field, Object value) {
17213
      switch (field) {
17214
      case SUCCESS:
17215
        if (value == null) {
17216
          unsetSuccess();
17217
        } else {
17218
          setSuccess((Vendor)value);
17219
        }
17220
        break;
17221
 
17222
      }
17223
    }
17224
 
17225
    public Object getFieldValue(_Fields field) {
17226
      switch (field) {
17227
      case SUCCESS:
17228
        return getSuccess();
17229
 
17230
      }
17231
      throw new IllegalStateException();
17232
    }
17233
 
17234
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17235
    public boolean isSet(_Fields field) {
17236
      if (field == null) {
17237
        throw new IllegalArgumentException();
17238
      }
17239
 
17240
      switch (field) {
17241
      case SUCCESS:
17242
        return isSetSuccess();
17243
      }
17244
      throw new IllegalStateException();
17245
    }
17246
 
17247
    @Override
17248
    public boolean equals(Object that) {
17249
      if (that == null)
17250
        return false;
17251
      if (that instanceof getVendor_result)
17252
        return this.equals((getVendor_result)that);
17253
      return false;
17254
    }
17255
 
17256
    public boolean equals(getVendor_result that) {
17257
      if (that == null)
17258
        return false;
17259
 
17260
      boolean this_present_success = true && this.isSetSuccess();
17261
      boolean that_present_success = true && that.isSetSuccess();
17262
      if (this_present_success || that_present_success) {
17263
        if (!(this_present_success && that_present_success))
17264
          return false;
17265
        if (!this.success.equals(that.success))
17266
          return false;
17267
      }
17268
 
17269
      return true;
17270
    }
17271
 
17272
    @Override
17273
    public int hashCode() {
17274
      return 0;
17275
    }
17276
 
17277
    public int compareTo(getVendor_result other) {
17278
      if (!getClass().equals(other.getClass())) {
17279
        return getClass().getName().compareTo(other.getClass().getName());
17280
      }
17281
 
17282
      int lastComparison = 0;
17283
      getVendor_result typedOther = (getVendor_result)other;
17284
 
17285
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17286
      if (lastComparison != 0) {
17287
        return lastComparison;
17288
      }
17289
      if (isSetSuccess()) {
17290
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17291
        if (lastComparison != 0) {
17292
          return lastComparison;
17293
        }
17294
      }
17295
      return 0;
17296
    }
17297
 
17298
    public _Fields fieldForId(int fieldId) {
17299
      return _Fields.findByThriftId(fieldId);
17300
    }
17301
 
17302
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17303
      org.apache.thrift.protocol.TField field;
17304
      iprot.readStructBegin();
17305
      while (true)
17306
      {
17307
        field = iprot.readFieldBegin();
17308
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17309
          break;
17310
        }
17311
        switch (field.id) {
17312
          case 0: // SUCCESS
17313
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
17314
              this.success = new Vendor();
17315
              this.success.read(iprot);
17316
            } else { 
17317
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17318
            }
17319
            break;
17320
          default:
17321
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17322
        }
17323
        iprot.readFieldEnd();
17324
      }
17325
      iprot.readStructEnd();
17326
      validate();
17327
    }
17328
 
17329
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17330
      oprot.writeStructBegin(STRUCT_DESC);
17331
 
17332
      if (this.isSetSuccess()) {
17333
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17334
        this.success.write(oprot);
17335
        oprot.writeFieldEnd();
17336
      }
17337
      oprot.writeFieldStop();
17338
      oprot.writeStructEnd();
17339
    }
17340
 
17341
    @Override
17342
    public String toString() {
17343
      StringBuilder sb = new StringBuilder("getVendor_result(");
17344
      boolean first = true;
17345
 
17346
      sb.append("success:");
17347
      if (this.success == null) {
17348
        sb.append("null");
17349
      } else {
17350
        sb.append(this.success);
17351
      }
17352
      first = false;
17353
      sb.append(")");
17354
      return sb.toString();
17355
    }
17356
 
17357
    public void validate() throws org.apache.thrift.TException {
17358
      // check for required fields
17359
    }
17360
 
17361
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17362
      try {
17363
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17364
      } catch (org.apache.thrift.TException te) {
17365
        throw new java.io.IOException(te);
17366
      }
17367
    }
17368
 
17369
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17370
      try {
17371
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17372
      } catch (org.apache.thrift.TException te) {
17373
        throw new java.io.IOException(te);
17374
      }
17375
    }
17376
 
17377
  }
17378
 
17379
  public static class getAllVendors_args implements org.apache.thrift.TBase<getAllVendors_args, getAllVendors_args._Fields>, java.io.Serializable, Cloneable   {
17380
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendors_args");
17381
 
17382
 
17383
 
17384
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17385
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17386
;
17387
 
17388
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17389
 
17390
      static {
17391
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17392
          byName.put(field.getFieldName(), field);
17393
        }
17394
      }
17395
 
17396
      /**
17397
       * Find the _Fields constant that matches fieldId, or null if its not found.
17398
       */
17399
      public static _Fields findByThriftId(int fieldId) {
17400
        switch(fieldId) {
17401
          default:
17402
            return null;
17403
        }
17404
      }
17405
 
17406
      /**
17407
       * Find the _Fields constant that matches fieldId, throwing an exception
17408
       * if it is not found.
17409
       */
17410
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17411
        _Fields fields = findByThriftId(fieldId);
17412
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17413
        return fields;
17414
      }
17415
 
17416
      /**
17417
       * Find the _Fields constant that matches name, or null if its not found.
17418
       */
17419
      public static _Fields findByName(String name) {
17420
        return byName.get(name);
17421
      }
17422
 
17423
      private final short _thriftId;
17424
      private final String _fieldName;
17425
 
17426
      _Fields(short thriftId, String fieldName) {
17427
        _thriftId = thriftId;
17428
        _fieldName = fieldName;
17429
      }
17430
 
17431
      public short getThriftFieldId() {
17432
        return _thriftId;
17433
      }
17434
 
17435
      public String getFieldName() {
17436
        return _fieldName;
17437
      }
17438
    }
17439
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17440
    static {
17441
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17442
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17443
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendors_args.class, metaDataMap);
17444
    }
17445
 
17446
    public getAllVendors_args() {
17447
    }
17448
 
17449
    /**
17450
     * Performs a deep copy on <i>other</i>.
17451
     */
17452
    public getAllVendors_args(getAllVendors_args other) {
17453
    }
17454
 
17455
    public getAllVendors_args deepCopy() {
17456
      return new getAllVendors_args(this);
17457
    }
17458
 
17459
    @Override
17460
    public void clear() {
17461
    }
17462
 
17463
    public void setFieldValue(_Fields field, Object value) {
17464
      switch (field) {
17465
      }
17466
    }
17467
 
17468
    public Object getFieldValue(_Fields field) {
17469
      switch (field) {
17470
      }
17471
      throw new IllegalStateException();
17472
    }
17473
 
17474
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17475
    public boolean isSet(_Fields field) {
17476
      if (field == null) {
17477
        throw new IllegalArgumentException();
17478
      }
17479
 
17480
      switch (field) {
17481
      }
17482
      throw new IllegalStateException();
17483
    }
17484
 
17485
    @Override
17486
    public boolean equals(Object that) {
17487
      if (that == null)
17488
        return false;
17489
      if (that instanceof getAllVendors_args)
17490
        return this.equals((getAllVendors_args)that);
17491
      return false;
17492
    }
17493
 
17494
    public boolean equals(getAllVendors_args that) {
17495
      if (that == null)
17496
        return false;
17497
 
17498
      return true;
17499
    }
17500
 
17501
    @Override
17502
    public int hashCode() {
17503
      return 0;
17504
    }
17505
 
17506
    public int compareTo(getAllVendors_args other) {
17507
      if (!getClass().equals(other.getClass())) {
17508
        return getClass().getName().compareTo(other.getClass().getName());
17509
      }
17510
 
17511
      int lastComparison = 0;
17512
      getAllVendors_args typedOther = (getAllVendors_args)other;
17513
 
17514
      return 0;
17515
    }
17516
 
17517
    public _Fields fieldForId(int fieldId) {
17518
      return _Fields.findByThriftId(fieldId);
17519
    }
17520
 
17521
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17522
      org.apache.thrift.protocol.TField field;
17523
      iprot.readStructBegin();
17524
      while (true)
17525
      {
17526
        field = iprot.readFieldBegin();
17527
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17528
          break;
17529
        }
17530
        switch (field.id) {
17531
          default:
17532
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17533
        }
17534
        iprot.readFieldEnd();
17535
      }
17536
      iprot.readStructEnd();
17537
      validate();
17538
    }
17539
 
17540
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17541
      validate();
17542
 
17543
      oprot.writeStructBegin(STRUCT_DESC);
17544
      oprot.writeFieldStop();
17545
      oprot.writeStructEnd();
17546
    }
17547
 
17548
    @Override
17549
    public String toString() {
17550
      StringBuilder sb = new StringBuilder("getAllVendors_args(");
17551
      boolean first = true;
17552
 
17553
      sb.append(")");
17554
      return sb.toString();
17555
    }
17556
 
17557
    public void validate() throws org.apache.thrift.TException {
17558
      // check for required fields
17559
    }
17560
 
17561
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17562
      try {
17563
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17564
      } catch (org.apache.thrift.TException te) {
17565
        throw new java.io.IOException(te);
17566
      }
17567
    }
17568
 
17569
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17570
      try {
17571
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17572
      } catch (org.apache.thrift.TException te) {
17573
        throw new java.io.IOException(te);
17574
      }
17575
    }
17576
 
17577
  }
17578
 
17579
  public static class getAllVendors_result implements org.apache.thrift.TBase<getAllVendors_result, getAllVendors_result._Fields>, java.io.Serializable, Cloneable   {
17580
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendors_result");
17581
 
17582
    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);
17583
 
17584
    private List<Vendor> success; // required
17585
 
17586
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17587
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17588
      SUCCESS((short)0, "success");
17589
 
17590
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17591
 
17592
      static {
17593
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17594
          byName.put(field.getFieldName(), field);
17595
        }
17596
      }
17597
 
17598
      /**
17599
       * Find the _Fields constant that matches fieldId, or null if its not found.
17600
       */
17601
      public static _Fields findByThriftId(int fieldId) {
17602
        switch(fieldId) {
17603
          case 0: // SUCCESS
17604
            return SUCCESS;
17605
          default:
17606
            return null;
17607
        }
17608
      }
17609
 
17610
      /**
17611
       * Find the _Fields constant that matches fieldId, throwing an exception
17612
       * if it is not found.
17613
       */
17614
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17615
        _Fields fields = findByThriftId(fieldId);
17616
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17617
        return fields;
17618
      }
17619
 
17620
      /**
17621
       * Find the _Fields constant that matches name, or null if its not found.
17622
       */
17623
      public static _Fields findByName(String name) {
17624
        return byName.get(name);
17625
      }
17626
 
17627
      private final short _thriftId;
17628
      private final String _fieldName;
17629
 
17630
      _Fields(short thriftId, String fieldName) {
17631
        _thriftId = thriftId;
17632
        _fieldName = fieldName;
17633
      }
17634
 
17635
      public short getThriftFieldId() {
17636
        return _thriftId;
17637
      }
17638
 
17639
      public String getFieldName() {
17640
        return _fieldName;
17641
      }
17642
    }
17643
 
17644
    // isset id assignments
17645
 
17646
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17647
    static {
17648
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17649
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17650
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
17651
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Vendor.class))));
17652
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17653
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendors_result.class, metaDataMap);
17654
    }
17655
 
17656
    public getAllVendors_result() {
17657
    }
17658
 
17659
    public getAllVendors_result(
17660
      List<Vendor> success)
17661
    {
17662
      this();
17663
      this.success = success;
17664
    }
17665
 
17666
    /**
17667
     * Performs a deep copy on <i>other</i>.
17668
     */
17669
    public getAllVendors_result(getAllVendors_result other) {
17670
      if (other.isSetSuccess()) {
17671
        List<Vendor> __this__success = new ArrayList<Vendor>();
17672
        for (Vendor other_element : other.success) {
17673
          __this__success.add(new Vendor(other_element));
17674
        }
17675
        this.success = __this__success;
17676
      }
17677
    }
17678
 
17679
    public getAllVendors_result deepCopy() {
17680
      return new getAllVendors_result(this);
17681
    }
17682
 
17683
    @Override
17684
    public void clear() {
17685
      this.success = null;
17686
    }
17687
 
17688
    public int getSuccessSize() {
17689
      return (this.success == null) ? 0 : this.success.size();
17690
    }
17691
 
17692
    public java.util.Iterator<Vendor> getSuccessIterator() {
17693
      return (this.success == null) ? null : this.success.iterator();
17694
    }
17695
 
17696
    public void addToSuccess(Vendor elem) {
17697
      if (this.success == null) {
17698
        this.success = new ArrayList<Vendor>();
17699
      }
17700
      this.success.add(elem);
17701
    }
17702
 
17703
    public List<Vendor> getSuccess() {
17704
      return this.success;
17705
    }
17706
 
17707
    public void setSuccess(List<Vendor> success) {
17708
      this.success = success;
17709
    }
17710
 
17711
    public void unsetSuccess() {
17712
      this.success = null;
17713
    }
17714
 
17715
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
17716
    public boolean isSetSuccess() {
17717
      return this.success != null;
17718
    }
17719
 
17720
    public void setSuccessIsSet(boolean value) {
17721
      if (!value) {
17722
        this.success = null;
17723
      }
17724
    }
17725
 
17726
    public void setFieldValue(_Fields field, Object value) {
17727
      switch (field) {
17728
      case SUCCESS:
17729
        if (value == null) {
17730
          unsetSuccess();
17731
        } else {
17732
          setSuccess((List<Vendor>)value);
17733
        }
17734
        break;
17735
 
17736
      }
17737
    }
17738
 
17739
    public Object getFieldValue(_Fields field) {
17740
      switch (field) {
17741
      case SUCCESS:
17742
        return getSuccess();
17743
 
17744
      }
17745
      throw new IllegalStateException();
17746
    }
17747
 
17748
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
17749
    public boolean isSet(_Fields field) {
17750
      if (field == null) {
17751
        throw new IllegalArgumentException();
17752
      }
17753
 
17754
      switch (field) {
17755
      case SUCCESS:
17756
        return isSetSuccess();
17757
      }
17758
      throw new IllegalStateException();
17759
    }
17760
 
17761
    @Override
17762
    public boolean equals(Object that) {
17763
      if (that == null)
17764
        return false;
17765
      if (that instanceof getAllVendors_result)
17766
        return this.equals((getAllVendors_result)that);
17767
      return false;
17768
    }
17769
 
17770
    public boolean equals(getAllVendors_result that) {
17771
      if (that == null)
17772
        return false;
17773
 
17774
      boolean this_present_success = true && this.isSetSuccess();
17775
      boolean that_present_success = true && that.isSetSuccess();
17776
      if (this_present_success || that_present_success) {
17777
        if (!(this_present_success && that_present_success))
17778
          return false;
17779
        if (!this.success.equals(that.success))
17780
          return false;
17781
      }
17782
 
17783
      return true;
17784
    }
17785
 
17786
    @Override
17787
    public int hashCode() {
17788
      return 0;
17789
    }
17790
 
17791
    public int compareTo(getAllVendors_result other) {
17792
      if (!getClass().equals(other.getClass())) {
17793
        return getClass().getName().compareTo(other.getClass().getName());
17794
      }
17795
 
17796
      int lastComparison = 0;
17797
      getAllVendors_result typedOther = (getAllVendors_result)other;
17798
 
17799
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
17800
      if (lastComparison != 0) {
17801
        return lastComparison;
17802
      }
17803
      if (isSetSuccess()) {
17804
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
17805
        if (lastComparison != 0) {
17806
          return lastComparison;
17807
        }
17808
      }
17809
      return 0;
17810
    }
17811
 
17812
    public _Fields fieldForId(int fieldId) {
17813
      return _Fields.findByThriftId(fieldId);
17814
    }
17815
 
17816
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
17817
      org.apache.thrift.protocol.TField field;
17818
      iprot.readStructBegin();
17819
      while (true)
17820
      {
17821
        field = iprot.readFieldBegin();
17822
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
17823
          break;
17824
        }
17825
        switch (field.id) {
17826
          case 0: // SUCCESS
17827
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
17828
              {
17829
                org.apache.thrift.protocol.TList _list36 = iprot.readListBegin();
17830
                this.success = new ArrayList<Vendor>(_list36.size);
17831
                for (int _i37 = 0; _i37 < _list36.size; ++_i37)
17832
                {
17833
                  Vendor _elem38; // required
17834
                  _elem38 = new Vendor();
17835
                  _elem38.read(iprot);
17836
                  this.success.add(_elem38);
17837
                }
17838
                iprot.readListEnd();
17839
              }
17840
            } else { 
17841
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17842
            }
17843
            break;
17844
          default:
17845
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
17846
        }
17847
        iprot.readFieldEnd();
17848
      }
17849
      iprot.readStructEnd();
17850
      validate();
17851
    }
17852
 
17853
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
17854
      oprot.writeStructBegin(STRUCT_DESC);
17855
 
17856
      if (this.isSetSuccess()) {
17857
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
17858
        {
17859
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
17860
          for (Vendor _iter39 : this.success)
17861
          {
17862
            _iter39.write(oprot);
17863
          }
17864
          oprot.writeListEnd();
17865
        }
17866
        oprot.writeFieldEnd();
17867
      }
17868
      oprot.writeFieldStop();
17869
      oprot.writeStructEnd();
17870
    }
17871
 
17872
    @Override
17873
    public String toString() {
17874
      StringBuilder sb = new StringBuilder("getAllVendors_result(");
17875
      boolean first = true;
17876
 
17877
      sb.append("success:");
17878
      if (this.success == null) {
17879
        sb.append("null");
17880
      } else {
17881
        sb.append(this.success);
17882
      }
17883
      first = false;
17884
      sb.append(")");
17885
      return sb.toString();
17886
    }
17887
 
17888
    public void validate() throws org.apache.thrift.TException {
17889
      // check for required fields
17890
    }
17891
 
17892
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
17893
      try {
17894
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
17895
      } catch (org.apache.thrift.TException te) {
17896
        throw new java.io.IOException(te);
17897
      }
17898
    }
17899
 
17900
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
17901
      try {
17902
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
17903
      } catch (org.apache.thrift.TException te) {
17904
        throw new java.io.IOException(te);
17905
      }
17906
    }
17907
 
17908
  }
17909
 
17910
  public static class addVendorItemMapping_args implements org.apache.thrift.TBase<addVendorItemMapping_args, addVendorItemMapping_args._Fields>, java.io.Serializable, Cloneable   {
17911
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemMapping_args");
17912
 
17913
    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);
17914
    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);
17915
 
17916
    private String key; // required
17917
    private VendorItemMapping vendorItemMapping; // required
17918
 
17919
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
17920
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
17921
      KEY((short)1, "key"),
17922
      VENDOR_ITEM_MAPPING((short)2, "vendorItemMapping");
17923
 
17924
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
17925
 
17926
      static {
17927
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
17928
          byName.put(field.getFieldName(), field);
17929
        }
17930
      }
17931
 
17932
      /**
17933
       * Find the _Fields constant that matches fieldId, or null if its not found.
17934
       */
17935
      public static _Fields findByThriftId(int fieldId) {
17936
        switch(fieldId) {
17937
          case 1: // KEY
17938
            return KEY;
17939
          case 2: // VENDOR_ITEM_MAPPING
17940
            return VENDOR_ITEM_MAPPING;
17941
          default:
17942
            return null;
17943
        }
17944
      }
17945
 
17946
      /**
17947
       * Find the _Fields constant that matches fieldId, throwing an exception
17948
       * if it is not found.
17949
       */
17950
      public static _Fields findByThriftIdOrThrow(int fieldId) {
17951
        _Fields fields = findByThriftId(fieldId);
17952
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
17953
        return fields;
17954
      }
17955
 
17956
      /**
17957
       * Find the _Fields constant that matches name, or null if its not found.
17958
       */
17959
      public static _Fields findByName(String name) {
17960
        return byName.get(name);
17961
      }
17962
 
17963
      private final short _thriftId;
17964
      private final String _fieldName;
17965
 
17966
      _Fields(short thriftId, String fieldName) {
17967
        _thriftId = thriftId;
17968
        _fieldName = fieldName;
17969
      }
17970
 
17971
      public short getThriftFieldId() {
17972
        return _thriftId;
17973
      }
17974
 
17975
      public String getFieldName() {
17976
        return _fieldName;
17977
      }
17978
    }
17979
 
17980
    // isset id assignments
17981
 
17982
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
17983
    static {
17984
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
17985
      tmpMap.put(_Fields.KEY, new org.apache.thrift.meta_data.FieldMetaData("key", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17986
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
17987
      tmpMap.put(_Fields.VENDOR_ITEM_MAPPING, new org.apache.thrift.meta_data.FieldMetaData("vendorItemMapping", org.apache.thrift.TFieldRequirementType.DEFAULT, 
17988
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class)));
17989
      metaDataMap = Collections.unmodifiableMap(tmpMap);
17990
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemMapping_args.class, metaDataMap);
17991
    }
17992
 
17993
    public addVendorItemMapping_args() {
17994
    }
17995
 
17996
    public addVendorItemMapping_args(
17997
      String key,
17998
      VendorItemMapping vendorItemMapping)
17999
    {
18000
      this();
18001
      this.key = key;
18002
      this.vendorItemMapping = vendorItemMapping;
18003
    }
18004
 
18005
    /**
18006
     * Performs a deep copy on <i>other</i>.
18007
     */
18008
    public addVendorItemMapping_args(addVendorItemMapping_args other) {
18009
      if (other.isSetKey()) {
18010
        this.key = other.key;
18011
      }
18012
      if (other.isSetVendorItemMapping()) {
18013
        this.vendorItemMapping = new VendorItemMapping(other.vendorItemMapping);
18014
      }
18015
    }
18016
 
18017
    public addVendorItemMapping_args deepCopy() {
18018
      return new addVendorItemMapping_args(this);
18019
    }
18020
 
18021
    @Override
18022
    public void clear() {
18023
      this.key = null;
18024
      this.vendorItemMapping = null;
18025
    }
18026
 
18027
    public String getKey() {
18028
      return this.key;
18029
    }
18030
 
18031
    public void setKey(String key) {
18032
      this.key = key;
18033
    }
18034
 
18035
    public void unsetKey() {
18036
      this.key = null;
18037
    }
18038
 
18039
    /** Returns true if field key is set (has been assigned a value) and false otherwise */
18040
    public boolean isSetKey() {
18041
      return this.key != null;
18042
    }
18043
 
18044
    public void setKeyIsSet(boolean value) {
18045
      if (!value) {
18046
        this.key = null;
18047
      }
18048
    }
18049
 
18050
    public VendorItemMapping getVendorItemMapping() {
18051
      return this.vendorItemMapping;
18052
    }
18053
 
18054
    public void setVendorItemMapping(VendorItemMapping vendorItemMapping) {
18055
      this.vendorItemMapping = vendorItemMapping;
18056
    }
18057
 
18058
    public void unsetVendorItemMapping() {
18059
      this.vendorItemMapping = null;
18060
    }
18061
 
18062
    /** Returns true if field vendorItemMapping is set (has been assigned a value) and false otherwise */
18063
    public boolean isSetVendorItemMapping() {
18064
      return this.vendorItemMapping != null;
18065
    }
18066
 
18067
    public void setVendorItemMappingIsSet(boolean value) {
18068
      if (!value) {
18069
        this.vendorItemMapping = null;
18070
      }
18071
    }
18072
 
18073
    public void setFieldValue(_Fields field, Object value) {
18074
      switch (field) {
18075
      case KEY:
18076
        if (value == null) {
18077
          unsetKey();
18078
        } else {
18079
          setKey((String)value);
18080
        }
18081
        break;
18082
 
18083
      case VENDOR_ITEM_MAPPING:
18084
        if (value == null) {
18085
          unsetVendorItemMapping();
18086
        } else {
18087
          setVendorItemMapping((VendorItemMapping)value);
18088
        }
18089
        break;
18090
 
18091
      }
18092
    }
18093
 
18094
    public Object getFieldValue(_Fields field) {
18095
      switch (field) {
18096
      case KEY:
18097
        return getKey();
18098
 
18099
      case VENDOR_ITEM_MAPPING:
18100
        return getVendorItemMapping();
18101
 
18102
      }
18103
      throw new IllegalStateException();
18104
    }
18105
 
18106
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18107
    public boolean isSet(_Fields field) {
18108
      if (field == null) {
18109
        throw new IllegalArgumentException();
18110
      }
18111
 
18112
      switch (field) {
18113
      case KEY:
18114
        return isSetKey();
18115
      case VENDOR_ITEM_MAPPING:
18116
        return isSetVendorItemMapping();
18117
      }
18118
      throw new IllegalStateException();
18119
    }
18120
 
18121
    @Override
18122
    public boolean equals(Object that) {
18123
      if (that == null)
18124
        return false;
18125
      if (that instanceof addVendorItemMapping_args)
18126
        return this.equals((addVendorItemMapping_args)that);
18127
      return false;
18128
    }
18129
 
18130
    public boolean equals(addVendorItemMapping_args that) {
18131
      if (that == null)
18132
        return false;
18133
 
18134
      boolean this_present_key = true && this.isSetKey();
18135
      boolean that_present_key = true && that.isSetKey();
18136
      if (this_present_key || that_present_key) {
18137
        if (!(this_present_key && that_present_key))
18138
          return false;
18139
        if (!this.key.equals(that.key))
18140
          return false;
18141
      }
18142
 
18143
      boolean this_present_vendorItemMapping = true && this.isSetVendorItemMapping();
18144
      boolean that_present_vendorItemMapping = true && that.isSetVendorItemMapping();
18145
      if (this_present_vendorItemMapping || that_present_vendorItemMapping) {
18146
        if (!(this_present_vendorItemMapping && that_present_vendorItemMapping))
18147
          return false;
18148
        if (!this.vendorItemMapping.equals(that.vendorItemMapping))
18149
          return false;
18150
      }
18151
 
18152
      return true;
18153
    }
18154
 
18155
    @Override
18156
    public int hashCode() {
18157
      return 0;
18158
    }
18159
 
18160
    public int compareTo(addVendorItemMapping_args other) {
18161
      if (!getClass().equals(other.getClass())) {
18162
        return getClass().getName().compareTo(other.getClass().getName());
18163
      }
18164
 
18165
      int lastComparison = 0;
18166
      addVendorItemMapping_args typedOther = (addVendorItemMapping_args)other;
18167
 
18168
      lastComparison = Boolean.valueOf(isSetKey()).compareTo(typedOther.isSetKey());
18169
      if (lastComparison != 0) {
18170
        return lastComparison;
18171
      }
18172
      if (isSetKey()) {
18173
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.key, typedOther.key);
18174
        if (lastComparison != 0) {
18175
          return lastComparison;
18176
        }
18177
      }
18178
      lastComparison = Boolean.valueOf(isSetVendorItemMapping()).compareTo(typedOther.isSetVendorItemMapping());
18179
      if (lastComparison != 0) {
18180
        return lastComparison;
18181
      }
18182
      if (isSetVendorItemMapping()) {
18183
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorItemMapping, typedOther.vendorItemMapping);
18184
        if (lastComparison != 0) {
18185
          return lastComparison;
18186
        }
18187
      }
18188
      return 0;
18189
    }
18190
 
18191
    public _Fields fieldForId(int fieldId) {
18192
      return _Fields.findByThriftId(fieldId);
18193
    }
18194
 
18195
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18196
      org.apache.thrift.protocol.TField field;
18197
      iprot.readStructBegin();
18198
      while (true)
18199
      {
18200
        field = iprot.readFieldBegin();
18201
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18202
          break;
18203
        }
18204
        switch (field.id) {
18205
          case 1: // KEY
18206
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
18207
              this.key = iprot.readString();
18208
            } else { 
18209
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18210
            }
18211
            break;
18212
          case 2: // VENDOR_ITEM_MAPPING
18213
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
18214
              this.vendorItemMapping = new VendorItemMapping();
18215
              this.vendorItemMapping.read(iprot);
18216
            } else { 
18217
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18218
            }
18219
            break;
18220
          default:
18221
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18222
        }
18223
        iprot.readFieldEnd();
18224
      }
18225
      iprot.readStructEnd();
18226
      validate();
18227
    }
18228
 
18229
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18230
      validate();
18231
 
18232
      oprot.writeStructBegin(STRUCT_DESC);
18233
      if (this.key != null) {
18234
        oprot.writeFieldBegin(KEY_FIELD_DESC);
18235
        oprot.writeString(this.key);
18236
        oprot.writeFieldEnd();
18237
      }
18238
      if (this.vendorItemMapping != null) {
18239
        oprot.writeFieldBegin(VENDOR_ITEM_MAPPING_FIELD_DESC);
18240
        this.vendorItemMapping.write(oprot);
18241
        oprot.writeFieldEnd();
18242
      }
18243
      oprot.writeFieldStop();
18244
      oprot.writeStructEnd();
18245
    }
18246
 
18247
    @Override
18248
    public String toString() {
18249
      StringBuilder sb = new StringBuilder("addVendorItemMapping_args(");
18250
      boolean first = true;
18251
 
18252
      sb.append("key:");
18253
      if (this.key == null) {
18254
        sb.append("null");
18255
      } else {
18256
        sb.append(this.key);
18257
      }
18258
      first = false;
18259
      if (!first) sb.append(", ");
18260
      sb.append("vendorItemMapping:");
18261
      if (this.vendorItemMapping == null) {
18262
        sb.append("null");
18263
      } else {
18264
        sb.append(this.vendorItemMapping);
18265
      }
18266
      first = false;
18267
      sb.append(")");
18268
      return sb.toString();
18269
    }
18270
 
18271
    public void validate() throws org.apache.thrift.TException {
18272
      // check for required fields
18273
    }
18274
 
18275
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18276
      try {
18277
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18278
      } catch (org.apache.thrift.TException te) {
18279
        throw new java.io.IOException(te);
18280
      }
18281
    }
18282
 
18283
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18284
      try {
18285
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18286
      } catch (org.apache.thrift.TException te) {
18287
        throw new java.io.IOException(te);
18288
      }
18289
    }
18290
 
18291
  }
18292
 
18293
  public static class addVendorItemMapping_result implements org.apache.thrift.TBase<addVendorItemMapping_result, addVendorItemMapping_result._Fields>, java.io.Serializable, Cloneable   {
18294
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addVendorItemMapping_result");
18295
 
18296
    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);
18297
 
18298
    private InventoryServiceException cex; // required
18299
 
18300
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18301
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18302
      CEX((short)1, "cex");
18303
 
18304
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18305
 
18306
      static {
18307
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18308
          byName.put(field.getFieldName(), field);
18309
        }
18310
      }
18311
 
18312
      /**
18313
       * Find the _Fields constant that matches fieldId, or null if its not found.
18314
       */
18315
      public static _Fields findByThriftId(int fieldId) {
18316
        switch(fieldId) {
18317
          case 1: // CEX
18318
            return CEX;
18319
          default:
18320
            return null;
18321
        }
18322
      }
18323
 
18324
      /**
18325
       * Find the _Fields constant that matches fieldId, throwing an exception
18326
       * if it is not found.
18327
       */
18328
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18329
        _Fields fields = findByThriftId(fieldId);
18330
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18331
        return fields;
18332
      }
18333
 
18334
      /**
18335
       * Find the _Fields constant that matches name, or null if its not found.
18336
       */
18337
      public static _Fields findByName(String name) {
18338
        return byName.get(name);
18339
      }
18340
 
18341
      private final short _thriftId;
18342
      private final String _fieldName;
18343
 
18344
      _Fields(short thriftId, String fieldName) {
18345
        _thriftId = thriftId;
18346
        _fieldName = fieldName;
18347
      }
18348
 
18349
      public short getThriftFieldId() {
18350
        return _thriftId;
18351
      }
18352
 
18353
      public String getFieldName() {
18354
        return _fieldName;
18355
      }
18356
    }
18357
 
18358
    // isset id assignments
18359
 
18360
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18361
    static {
18362
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18363
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18364
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
18365
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18366
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addVendorItemMapping_result.class, metaDataMap);
18367
    }
18368
 
18369
    public addVendorItemMapping_result() {
18370
    }
18371
 
18372
    public addVendorItemMapping_result(
18373
      InventoryServiceException cex)
18374
    {
18375
      this();
18376
      this.cex = cex;
18377
    }
18378
 
18379
    /**
18380
     * Performs a deep copy on <i>other</i>.
18381
     */
18382
    public addVendorItemMapping_result(addVendorItemMapping_result other) {
18383
      if (other.isSetCex()) {
18384
        this.cex = new InventoryServiceException(other.cex);
18385
      }
18386
    }
18387
 
18388
    public addVendorItemMapping_result deepCopy() {
18389
      return new addVendorItemMapping_result(this);
18390
    }
18391
 
18392
    @Override
18393
    public void clear() {
18394
      this.cex = null;
18395
    }
18396
 
18397
    public InventoryServiceException getCex() {
18398
      return this.cex;
18399
    }
18400
 
18401
    public void setCex(InventoryServiceException cex) {
18402
      this.cex = cex;
18403
    }
18404
 
18405
    public void unsetCex() {
18406
      this.cex = null;
18407
    }
18408
 
18409
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
18410
    public boolean isSetCex() {
18411
      return this.cex != null;
18412
    }
18413
 
18414
    public void setCexIsSet(boolean value) {
18415
      if (!value) {
18416
        this.cex = null;
18417
      }
18418
    }
18419
 
18420
    public void setFieldValue(_Fields field, Object value) {
18421
      switch (field) {
18422
      case CEX:
18423
        if (value == null) {
18424
          unsetCex();
18425
        } else {
18426
          setCex((InventoryServiceException)value);
18427
        }
18428
        break;
18429
 
18430
      }
18431
    }
18432
 
18433
    public Object getFieldValue(_Fields field) {
18434
      switch (field) {
18435
      case CEX:
18436
        return getCex();
18437
 
18438
      }
18439
      throw new IllegalStateException();
18440
    }
18441
 
18442
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18443
    public boolean isSet(_Fields field) {
18444
      if (field == null) {
18445
        throw new IllegalArgumentException();
18446
      }
18447
 
18448
      switch (field) {
18449
      case CEX:
18450
        return isSetCex();
18451
      }
18452
      throw new IllegalStateException();
18453
    }
18454
 
18455
    @Override
18456
    public boolean equals(Object that) {
18457
      if (that == null)
18458
        return false;
18459
      if (that instanceof addVendorItemMapping_result)
18460
        return this.equals((addVendorItemMapping_result)that);
18461
      return false;
18462
    }
18463
 
18464
    public boolean equals(addVendorItemMapping_result that) {
18465
      if (that == null)
18466
        return false;
18467
 
18468
      boolean this_present_cex = true && this.isSetCex();
18469
      boolean that_present_cex = true && that.isSetCex();
18470
      if (this_present_cex || that_present_cex) {
18471
        if (!(this_present_cex && that_present_cex))
18472
          return false;
18473
        if (!this.cex.equals(that.cex))
18474
          return false;
18475
      }
18476
 
18477
      return true;
18478
    }
18479
 
18480
    @Override
18481
    public int hashCode() {
18482
      return 0;
18483
    }
18484
 
18485
    public int compareTo(addVendorItemMapping_result other) {
18486
      if (!getClass().equals(other.getClass())) {
18487
        return getClass().getName().compareTo(other.getClass().getName());
18488
      }
18489
 
18490
      int lastComparison = 0;
18491
      addVendorItemMapping_result typedOther = (addVendorItemMapping_result)other;
18492
 
18493
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
18494
      if (lastComparison != 0) {
18495
        return lastComparison;
18496
      }
18497
      if (isSetCex()) {
18498
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
18499
        if (lastComparison != 0) {
18500
          return lastComparison;
18501
        }
18502
      }
18503
      return 0;
18504
    }
18505
 
18506
    public _Fields fieldForId(int fieldId) {
18507
      return _Fields.findByThriftId(fieldId);
18508
    }
18509
 
18510
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18511
      org.apache.thrift.protocol.TField field;
18512
      iprot.readStructBegin();
18513
      while (true)
18514
      {
18515
        field = iprot.readFieldBegin();
18516
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18517
          break;
18518
        }
18519
        switch (field.id) {
18520
          case 1: // CEX
18521
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
18522
              this.cex = new InventoryServiceException();
18523
              this.cex.read(iprot);
18524
            } else { 
18525
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18526
            }
18527
            break;
18528
          default:
18529
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18530
        }
18531
        iprot.readFieldEnd();
18532
      }
18533
      iprot.readStructEnd();
18534
      validate();
18535
    }
18536
 
18537
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18538
      oprot.writeStructBegin(STRUCT_DESC);
18539
 
18540
      if (this.isSetCex()) {
18541
        oprot.writeFieldBegin(CEX_FIELD_DESC);
18542
        this.cex.write(oprot);
18543
        oprot.writeFieldEnd();
18544
      }
18545
      oprot.writeFieldStop();
18546
      oprot.writeStructEnd();
18547
    }
18548
 
18549
    @Override
18550
    public String toString() {
18551
      StringBuilder sb = new StringBuilder("addVendorItemMapping_result(");
18552
      boolean first = true;
18553
 
18554
      sb.append("cex:");
18555
      if (this.cex == null) {
18556
        sb.append("null");
18557
      } else {
18558
        sb.append(this.cex);
18559
      }
18560
      first = false;
18561
      sb.append(")");
18562
      return sb.toString();
18563
    }
18564
 
18565
    public void validate() throws org.apache.thrift.TException {
18566
      // check for required fields
18567
    }
18568
 
18569
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18570
      try {
18571
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18572
      } catch (org.apache.thrift.TException te) {
18573
        throw new java.io.IOException(te);
18574
      }
18575
    }
18576
 
18577
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18578
      try {
18579
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18580
      } catch (org.apache.thrift.TException te) {
18581
        throw new java.io.IOException(te);
18582
      }
18583
    }
18584
 
18585
  }
18586
 
18587
  public static class getVendorItemMappings_args implements org.apache.thrift.TBase<getVendorItemMappings_args, getVendorItemMappings_args._Fields>, java.io.Serializable, Cloneable   {
18588
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendorItemMappings_args");
18589
 
18590
    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);
18591
 
18592
    private long itemId; // required
18593
 
18594
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18595
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18596
      ITEM_ID((short)1, "itemId");
18597
 
18598
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18599
 
18600
      static {
18601
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18602
          byName.put(field.getFieldName(), field);
18603
        }
18604
      }
18605
 
18606
      /**
18607
       * Find the _Fields constant that matches fieldId, or null if its not found.
18608
       */
18609
      public static _Fields findByThriftId(int fieldId) {
18610
        switch(fieldId) {
18611
          case 1: // ITEM_ID
18612
            return ITEM_ID;
18613
          default:
18614
            return null;
18615
        }
18616
      }
18617
 
18618
      /**
18619
       * Find the _Fields constant that matches fieldId, throwing an exception
18620
       * if it is not found.
18621
       */
18622
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18623
        _Fields fields = findByThriftId(fieldId);
18624
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18625
        return fields;
18626
      }
18627
 
18628
      /**
18629
       * Find the _Fields constant that matches name, or null if its not found.
18630
       */
18631
      public static _Fields findByName(String name) {
18632
        return byName.get(name);
18633
      }
18634
 
18635
      private final short _thriftId;
18636
      private final String _fieldName;
18637
 
18638
      _Fields(short thriftId, String fieldName) {
18639
        _thriftId = thriftId;
18640
        _fieldName = fieldName;
18641
      }
18642
 
18643
      public short getThriftFieldId() {
18644
        return _thriftId;
18645
      }
18646
 
18647
      public String getFieldName() {
18648
        return _fieldName;
18649
      }
18650
    }
18651
 
18652
    // isset id assignments
18653
    private static final int __ITEMID_ISSET_ID = 0;
18654
    private BitSet __isset_bit_vector = new BitSet(1);
18655
 
18656
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18657
    static {
18658
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18659
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18660
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
18661
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18662
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendorItemMappings_args.class, metaDataMap);
18663
    }
18664
 
18665
    public getVendorItemMappings_args() {
18666
    }
18667
 
18668
    public getVendorItemMappings_args(
18669
      long itemId)
18670
    {
18671
      this();
18672
      this.itemId = itemId;
18673
      setItemIdIsSet(true);
18674
    }
18675
 
18676
    /**
18677
     * Performs a deep copy on <i>other</i>.
18678
     */
18679
    public getVendorItemMappings_args(getVendorItemMappings_args other) {
18680
      __isset_bit_vector.clear();
18681
      __isset_bit_vector.or(other.__isset_bit_vector);
18682
      this.itemId = other.itemId;
18683
    }
18684
 
18685
    public getVendorItemMappings_args deepCopy() {
18686
      return new getVendorItemMappings_args(this);
18687
    }
18688
 
18689
    @Override
18690
    public void clear() {
18691
      setItemIdIsSet(false);
18692
      this.itemId = 0;
18693
    }
18694
 
18695
    public long getItemId() {
18696
      return this.itemId;
18697
    }
18698
 
18699
    public void setItemId(long itemId) {
18700
      this.itemId = itemId;
18701
      setItemIdIsSet(true);
18702
    }
18703
 
18704
    public void unsetItemId() {
18705
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
18706
    }
18707
 
18708
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
18709
    public boolean isSetItemId() {
18710
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
18711
    }
18712
 
18713
    public void setItemIdIsSet(boolean value) {
18714
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
18715
    }
18716
 
18717
    public void setFieldValue(_Fields field, Object value) {
18718
      switch (field) {
18719
      case ITEM_ID:
18720
        if (value == null) {
18721
          unsetItemId();
18722
        } else {
18723
          setItemId((Long)value);
18724
        }
18725
        break;
18726
 
18727
      }
18728
    }
18729
 
18730
    public Object getFieldValue(_Fields field) {
18731
      switch (field) {
18732
      case ITEM_ID:
18733
        return Long.valueOf(getItemId());
18734
 
18735
      }
18736
      throw new IllegalStateException();
18737
    }
18738
 
18739
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
18740
    public boolean isSet(_Fields field) {
18741
      if (field == null) {
18742
        throw new IllegalArgumentException();
18743
      }
18744
 
18745
      switch (field) {
18746
      case ITEM_ID:
18747
        return isSetItemId();
18748
      }
18749
      throw new IllegalStateException();
18750
    }
18751
 
18752
    @Override
18753
    public boolean equals(Object that) {
18754
      if (that == null)
18755
        return false;
18756
      if (that instanceof getVendorItemMappings_args)
18757
        return this.equals((getVendorItemMappings_args)that);
18758
      return false;
18759
    }
18760
 
18761
    public boolean equals(getVendorItemMappings_args that) {
18762
      if (that == null)
18763
        return false;
18764
 
18765
      boolean this_present_itemId = true;
18766
      boolean that_present_itemId = true;
18767
      if (this_present_itemId || that_present_itemId) {
18768
        if (!(this_present_itemId && that_present_itemId))
18769
          return false;
18770
        if (this.itemId != that.itemId)
18771
          return false;
18772
      }
18773
 
18774
      return true;
18775
    }
18776
 
18777
    @Override
18778
    public int hashCode() {
18779
      return 0;
18780
    }
18781
 
18782
    public int compareTo(getVendorItemMappings_args other) {
18783
      if (!getClass().equals(other.getClass())) {
18784
        return getClass().getName().compareTo(other.getClass().getName());
18785
      }
18786
 
18787
      int lastComparison = 0;
18788
      getVendorItemMappings_args typedOther = (getVendorItemMappings_args)other;
18789
 
18790
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
18791
      if (lastComparison != 0) {
18792
        return lastComparison;
18793
      }
18794
      if (isSetItemId()) {
18795
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
18796
        if (lastComparison != 0) {
18797
          return lastComparison;
18798
        }
18799
      }
18800
      return 0;
18801
    }
18802
 
18803
    public _Fields fieldForId(int fieldId) {
18804
      return _Fields.findByThriftId(fieldId);
18805
    }
18806
 
18807
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
18808
      org.apache.thrift.protocol.TField field;
18809
      iprot.readStructBegin();
18810
      while (true)
18811
      {
18812
        field = iprot.readFieldBegin();
18813
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
18814
          break;
18815
        }
18816
        switch (field.id) {
18817
          case 1: // ITEM_ID
18818
            if (field.type == org.apache.thrift.protocol.TType.I64) {
18819
              this.itemId = iprot.readI64();
18820
              setItemIdIsSet(true);
18821
            } else { 
18822
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18823
            }
18824
            break;
18825
          default:
18826
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
18827
        }
18828
        iprot.readFieldEnd();
18829
      }
18830
      iprot.readStructEnd();
18831
      validate();
18832
    }
18833
 
18834
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
18835
      validate();
18836
 
18837
      oprot.writeStructBegin(STRUCT_DESC);
18838
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
18839
      oprot.writeI64(this.itemId);
18840
      oprot.writeFieldEnd();
18841
      oprot.writeFieldStop();
18842
      oprot.writeStructEnd();
18843
    }
18844
 
18845
    @Override
18846
    public String toString() {
18847
      StringBuilder sb = new StringBuilder("getVendorItemMappings_args(");
18848
      boolean first = true;
18849
 
18850
      sb.append("itemId:");
18851
      sb.append(this.itemId);
18852
      first = false;
18853
      sb.append(")");
18854
      return sb.toString();
18855
    }
18856
 
18857
    public void validate() throws org.apache.thrift.TException {
18858
      // check for required fields
18859
    }
18860
 
18861
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
18862
      try {
18863
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
18864
      } catch (org.apache.thrift.TException te) {
18865
        throw new java.io.IOException(te);
18866
      }
18867
    }
18868
 
18869
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
18870
      try {
18871
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
18872
      } catch (org.apache.thrift.TException te) {
18873
        throw new java.io.IOException(te);
18874
      }
18875
    }
18876
 
18877
  }
18878
 
18879
  public static class getVendorItemMappings_result implements org.apache.thrift.TBase<getVendorItemMappings_result, getVendorItemMappings_result._Fields>, java.io.Serializable, Cloneable   {
18880
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getVendorItemMappings_result");
18881
 
18882
    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);
18883
    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);
18884
 
18885
    private List<VendorItemMapping> success; // required
18886
    private InventoryServiceException cex; // required
18887
 
18888
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
18889
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
18890
      SUCCESS((short)0, "success"),
18891
      CEX((short)1, "cex");
18892
 
18893
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
18894
 
18895
      static {
18896
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
18897
          byName.put(field.getFieldName(), field);
18898
        }
18899
      }
18900
 
18901
      /**
18902
       * Find the _Fields constant that matches fieldId, or null if its not found.
18903
       */
18904
      public static _Fields findByThriftId(int fieldId) {
18905
        switch(fieldId) {
18906
          case 0: // SUCCESS
18907
            return SUCCESS;
18908
          case 1: // CEX
18909
            return CEX;
18910
          default:
18911
            return null;
18912
        }
18913
      }
18914
 
18915
      /**
18916
       * Find the _Fields constant that matches fieldId, throwing an exception
18917
       * if it is not found.
18918
       */
18919
      public static _Fields findByThriftIdOrThrow(int fieldId) {
18920
        _Fields fields = findByThriftId(fieldId);
18921
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
18922
        return fields;
18923
      }
18924
 
18925
      /**
18926
       * Find the _Fields constant that matches name, or null if its not found.
18927
       */
18928
      public static _Fields findByName(String name) {
18929
        return byName.get(name);
18930
      }
18931
 
18932
      private final short _thriftId;
18933
      private final String _fieldName;
18934
 
18935
      _Fields(short thriftId, String fieldName) {
18936
        _thriftId = thriftId;
18937
        _fieldName = fieldName;
18938
      }
18939
 
18940
      public short getThriftFieldId() {
18941
        return _thriftId;
18942
      }
18943
 
18944
      public String getFieldName() {
18945
        return _fieldName;
18946
      }
18947
    }
18948
 
18949
    // isset id assignments
18950
 
18951
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
18952
    static {
18953
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
18954
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18955
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
18956
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class))));
18957
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
18958
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
18959
      metaDataMap = Collections.unmodifiableMap(tmpMap);
18960
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getVendorItemMappings_result.class, metaDataMap);
18961
    }
18962
 
18963
    public getVendorItemMappings_result() {
18964
    }
18965
 
18966
    public getVendorItemMappings_result(
18967
      List<VendorItemMapping> success,
18968
      InventoryServiceException cex)
18969
    {
18970
      this();
18971
      this.success = success;
18972
      this.cex = cex;
18973
    }
18974
 
18975
    /**
18976
     * Performs a deep copy on <i>other</i>.
18977
     */
18978
    public getVendorItemMappings_result(getVendorItemMappings_result other) {
18979
      if (other.isSetSuccess()) {
18980
        List<VendorItemMapping> __this__success = new ArrayList<VendorItemMapping>();
18981
        for (VendorItemMapping other_element : other.success) {
18982
          __this__success.add(new VendorItemMapping(other_element));
18983
        }
18984
        this.success = __this__success;
18985
      }
18986
      if (other.isSetCex()) {
18987
        this.cex = new InventoryServiceException(other.cex);
18988
      }
18989
    }
18990
 
18991
    public getVendorItemMappings_result deepCopy() {
18992
      return new getVendorItemMappings_result(this);
18993
    }
18994
 
18995
    @Override
18996
    public void clear() {
18997
      this.success = null;
18998
      this.cex = null;
18999
    }
19000
 
19001
    public int getSuccessSize() {
19002
      return (this.success == null) ? 0 : this.success.size();
19003
    }
19004
 
19005
    public java.util.Iterator<VendorItemMapping> getSuccessIterator() {
19006
      return (this.success == null) ? null : this.success.iterator();
19007
    }
19008
 
19009
    public void addToSuccess(VendorItemMapping elem) {
19010
      if (this.success == null) {
19011
        this.success = new ArrayList<VendorItemMapping>();
19012
      }
19013
      this.success.add(elem);
19014
    }
19015
 
19016
    public List<VendorItemMapping> getSuccess() {
19017
      return this.success;
19018
    }
19019
 
19020
    public void setSuccess(List<VendorItemMapping> success) {
19021
      this.success = success;
19022
    }
19023
 
19024
    public void unsetSuccess() {
19025
      this.success = null;
19026
    }
19027
 
19028
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
19029
    public boolean isSetSuccess() {
19030
      return this.success != null;
19031
    }
19032
 
19033
    public void setSuccessIsSet(boolean value) {
19034
      if (!value) {
19035
        this.success = null;
19036
      }
19037
    }
19038
 
19039
    public InventoryServiceException getCex() {
19040
      return this.cex;
19041
    }
19042
 
19043
    public void setCex(InventoryServiceException cex) {
19044
      this.cex = cex;
19045
    }
19046
 
19047
    public void unsetCex() {
19048
      this.cex = null;
19049
    }
19050
 
19051
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
19052
    public boolean isSetCex() {
19053
      return this.cex != null;
19054
    }
19055
 
19056
    public void setCexIsSet(boolean value) {
19057
      if (!value) {
19058
        this.cex = null;
19059
      }
19060
    }
19061
 
19062
    public void setFieldValue(_Fields field, Object value) {
19063
      switch (field) {
19064
      case SUCCESS:
19065
        if (value == null) {
19066
          unsetSuccess();
19067
        } else {
19068
          setSuccess((List<VendorItemMapping>)value);
19069
        }
19070
        break;
19071
 
19072
      case CEX:
19073
        if (value == null) {
19074
          unsetCex();
19075
        } else {
19076
          setCex((InventoryServiceException)value);
19077
        }
19078
        break;
19079
 
19080
      }
19081
    }
19082
 
19083
    public Object getFieldValue(_Fields field) {
19084
      switch (field) {
19085
      case SUCCESS:
19086
        return getSuccess();
19087
 
19088
      case CEX:
19089
        return getCex();
19090
 
19091
      }
19092
      throw new IllegalStateException();
19093
    }
19094
 
19095
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19096
    public boolean isSet(_Fields field) {
19097
      if (field == null) {
19098
        throw new IllegalArgumentException();
19099
      }
19100
 
19101
      switch (field) {
19102
      case SUCCESS:
19103
        return isSetSuccess();
19104
      case CEX:
19105
        return isSetCex();
19106
      }
19107
      throw new IllegalStateException();
19108
    }
19109
 
19110
    @Override
19111
    public boolean equals(Object that) {
19112
      if (that == null)
19113
        return false;
19114
      if (that instanceof getVendorItemMappings_result)
19115
        return this.equals((getVendorItemMappings_result)that);
19116
      return false;
19117
    }
19118
 
19119
    public boolean equals(getVendorItemMappings_result that) {
19120
      if (that == null)
19121
        return false;
19122
 
19123
      boolean this_present_success = true && this.isSetSuccess();
19124
      boolean that_present_success = true && that.isSetSuccess();
19125
      if (this_present_success || that_present_success) {
19126
        if (!(this_present_success && that_present_success))
19127
          return false;
19128
        if (!this.success.equals(that.success))
19129
          return false;
19130
      }
19131
 
19132
      boolean this_present_cex = true && this.isSetCex();
19133
      boolean that_present_cex = true && that.isSetCex();
19134
      if (this_present_cex || that_present_cex) {
19135
        if (!(this_present_cex && that_present_cex))
19136
          return false;
19137
        if (!this.cex.equals(that.cex))
19138
          return false;
19139
      }
19140
 
19141
      return true;
19142
    }
19143
 
19144
    @Override
19145
    public int hashCode() {
19146
      return 0;
19147
    }
19148
 
19149
    public int compareTo(getVendorItemMappings_result other) {
19150
      if (!getClass().equals(other.getClass())) {
19151
        return getClass().getName().compareTo(other.getClass().getName());
19152
      }
19153
 
19154
      int lastComparison = 0;
19155
      getVendorItemMappings_result typedOther = (getVendorItemMappings_result)other;
19156
 
19157
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
19158
      if (lastComparison != 0) {
19159
        return lastComparison;
19160
      }
19161
      if (isSetSuccess()) {
19162
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
19163
        if (lastComparison != 0) {
19164
          return lastComparison;
19165
        }
19166
      }
19167
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
19168
      if (lastComparison != 0) {
19169
        return lastComparison;
19170
      }
19171
      if (isSetCex()) {
19172
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
19173
        if (lastComparison != 0) {
19174
          return lastComparison;
19175
        }
19176
      }
19177
      return 0;
19178
    }
19179
 
19180
    public _Fields fieldForId(int fieldId) {
19181
      return _Fields.findByThriftId(fieldId);
19182
    }
19183
 
19184
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19185
      org.apache.thrift.protocol.TField field;
19186
      iprot.readStructBegin();
19187
      while (true)
19188
      {
19189
        field = iprot.readFieldBegin();
19190
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19191
          break;
19192
        }
19193
        switch (field.id) {
19194
          case 0: // SUCCESS
19195
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
19196
              {
19197
                org.apache.thrift.protocol.TList _list40 = iprot.readListBegin();
19198
                this.success = new ArrayList<VendorItemMapping>(_list40.size);
19199
                for (int _i41 = 0; _i41 < _list40.size; ++_i41)
19200
                {
19201
                  VendorItemMapping _elem42; // required
19202
                  _elem42 = new VendorItemMapping();
19203
                  _elem42.read(iprot);
19204
                  this.success.add(_elem42);
19205
                }
19206
                iprot.readListEnd();
19207
              }
19208
            } else { 
19209
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19210
            }
19211
            break;
19212
          case 1: // CEX
19213
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
19214
              this.cex = new InventoryServiceException();
19215
              this.cex.read(iprot);
19216
            } else { 
19217
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19218
            }
19219
            break;
19220
          default:
19221
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19222
        }
19223
        iprot.readFieldEnd();
19224
      }
19225
      iprot.readStructEnd();
19226
      validate();
19227
    }
19228
 
19229
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19230
      oprot.writeStructBegin(STRUCT_DESC);
19231
 
19232
      if (this.isSetSuccess()) {
19233
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
19234
        {
19235
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
19236
          for (VendorItemMapping _iter43 : this.success)
19237
          {
19238
            _iter43.write(oprot);
19239
          }
19240
          oprot.writeListEnd();
19241
        }
19242
        oprot.writeFieldEnd();
19243
      } else if (this.isSetCex()) {
19244
        oprot.writeFieldBegin(CEX_FIELD_DESC);
19245
        this.cex.write(oprot);
19246
        oprot.writeFieldEnd();
19247
      }
19248
      oprot.writeFieldStop();
19249
      oprot.writeStructEnd();
19250
    }
19251
 
19252
    @Override
19253
    public String toString() {
19254
      StringBuilder sb = new StringBuilder("getVendorItemMappings_result(");
19255
      boolean first = true;
19256
 
19257
      sb.append("success:");
19258
      if (this.success == null) {
19259
        sb.append("null");
19260
      } else {
19261
        sb.append(this.success);
19262
      }
19263
      first = false;
19264
      if (!first) sb.append(", ");
19265
      sb.append("cex:");
19266
      if (this.cex == null) {
19267
        sb.append("null");
19268
      } else {
19269
        sb.append(this.cex);
19270
      }
19271
      first = false;
19272
      sb.append(")");
19273
      return sb.toString();
19274
    }
19275
 
19276
    public void validate() throws org.apache.thrift.TException {
19277
      // check for required fields
19278
    }
19279
 
19280
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19281
      try {
19282
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19283
      } catch (org.apache.thrift.TException te) {
19284
        throw new java.io.IOException(te);
19285
      }
19286
    }
19287
 
19288
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19289
      try {
19290
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19291
      } catch (org.apache.thrift.TException te) {
19292
        throw new java.io.IOException(te);
19293
      }
19294
    }
19295
 
19296
  }
19297
 
19298
  public static class getPendingOrdersInventory_args implements org.apache.thrift.TBase<getPendingOrdersInventory_args, getPendingOrdersInventory_args._Fields>, java.io.Serializable, Cloneable   {
19299
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPendingOrdersInventory_args");
19300
 
19301
    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);
19302
 
19303
    private long vendorid; // required
19304
 
19305
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19306
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19307
      VENDORID((short)1, "vendorid");
19308
 
19309
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19310
 
19311
      static {
19312
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19313
          byName.put(field.getFieldName(), field);
19314
        }
19315
      }
19316
 
19317
      /**
19318
       * Find the _Fields constant that matches fieldId, or null if its not found.
19319
       */
19320
      public static _Fields findByThriftId(int fieldId) {
19321
        switch(fieldId) {
19322
          case 1: // VENDORID
19323
            return VENDORID;
19324
          default:
19325
            return null;
19326
        }
19327
      }
19328
 
19329
      /**
19330
       * Find the _Fields constant that matches fieldId, throwing an exception
19331
       * if it is not found.
19332
       */
19333
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19334
        _Fields fields = findByThriftId(fieldId);
19335
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19336
        return fields;
19337
      }
19338
 
19339
      /**
19340
       * Find the _Fields constant that matches name, or null if its not found.
19341
       */
19342
      public static _Fields findByName(String name) {
19343
        return byName.get(name);
19344
      }
19345
 
19346
      private final short _thriftId;
19347
      private final String _fieldName;
19348
 
19349
      _Fields(short thriftId, String fieldName) {
19350
        _thriftId = thriftId;
19351
        _fieldName = fieldName;
19352
      }
19353
 
19354
      public short getThriftFieldId() {
19355
        return _thriftId;
19356
      }
19357
 
19358
      public String getFieldName() {
19359
        return _fieldName;
19360
      }
19361
    }
19362
 
19363
    // isset id assignments
19364
    private static final int __VENDORID_ISSET_ID = 0;
19365
    private BitSet __isset_bit_vector = new BitSet(1);
19366
 
19367
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19368
    static {
19369
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19370
      tmpMap.put(_Fields.VENDORID, new org.apache.thrift.meta_data.FieldMetaData("vendorid", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19371
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
19372
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19373
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPendingOrdersInventory_args.class, metaDataMap);
19374
    }
19375
 
19376
    public getPendingOrdersInventory_args() {
19377
    }
19378
 
19379
    public getPendingOrdersInventory_args(
19380
      long vendorid)
19381
    {
19382
      this();
19383
      this.vendorid = vendorid;
19384
      setVendoridIsSet(true);
19385
    }
19386
 
19387
    /**
19388
     * Performs a deep copy on <i>other</i>.
19389
     */
19390
    public getPendingOrdersInventory_args(getPendingOrdersInventory_args other) {
19391
      __isset_bit_vector.clear();
19392
      __isset_bit_vector.or(other.__isset_bit_vector);
19393
      this.vendorid = other.vendorid;
19394
    }
19395
 
19396
    public getPendingOrdersInventory_args deepCopy() {
19397
      return new getPendingOrdersInventory_args(this);
19398
    }
19399
 
19400
    @Override
19401
    public void clear() {
19402
      setVendoridIsSet(false);
19403
      this.vendorid = 0;
19404
    }
19405
 
19406
    public long getVendorid() {
19407
      return this.vendorid;
19408
    }
19409
 
19410
    public void setVendorid(long vendorid) {
19411
      this.vendorid = vendorid;
19412
      setVendoridIsSet(true);
19413
    }
19414
 
19415
    public void unsetVendorid() {
19416
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
19417
    }
19418
 
19419
    /** Returns true if field vendorid is set (has been assigned a value) and false otherwise */
19420
    public boolean isSetVendorid() {
19421
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
19422
    }
19423
 
19424
    public void setVendoridIsSet(boolean value) {
19425
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
19426
    }
19427
 
19428
    public void setFieldValue(_Fields field, Object value) {
19429
      switch (field) {
19430
      case VENDORID:
19431
        if (value == null) {
19432
          unsetVendorid();
19433
        } else {
19434
          setVendorid((Long)value);
19435
        }
19436
        break;
19437
 
19438
      }
19439
    }
19440
 
19441
    public Object getFieldValue(_Fields field) {
19442
      switch (field) {
19443
      case VENDORID:
19444
        return Long.valueOf(getVendorid());
19445
 
19446
      }
19447
      throw new IllegalStateException();
19448
    }
19449
 
19450
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19451
    public boolean isSet(_Fields field) {
19452
      if (field == null) {
19453
        throw new IllegalArgumentException();
19454
      }
19455
 
19456
      switch (field) {
19457
      case VENDORID:
19458
        return isSetVendorid();
19459
      }
19460
      throw new IllegalStateException();
19461
    }
19462
 
19463
    @Override
19464
    public boolean equals(Object that) {
19465
      if (that == null)
19466
        return false;
19467
      if (that instanceof getPendingOrdersInventory_args)
19468
        return this.equals((getPendingOrdersInventory_args)that);
19469
      return false;
19470
    }
19471
 
19472
    public boolean equals(getPendingOrdersInventory_args that) {
19473
      if (that == null)
19474
        return false;
19475
 
19476
      boolean this_present_vendorid = true;
19477
      boolean that_present_vendorid = true;
19478
      if (this_present_vendorid || that_present_vendorid) {
19479
        if (!(this_present_vendorid && that_present_vendorid))
19480
          return false;
19481
        if (this.vendorid != that.vendorid)
19482
          return false;
19483
      }
19484
 
19485
      return true;
19486
    }
19487
 
19488
    @Override
19489
    public int hashCode() {
19490
      return 0;
19491
    }
19492
 
19493
    public int compareTo(getPendingOrdersInventory_args other) {
19494
      if (!getClass().equals(other.getClass())) {
19495
        return getClass().getName().compareTo(other.getClass().getName());
19496
      }
19497
 
19498
      int lastComparison = 0;
19499
      getPendingOrdersInventory_args typedOther = (getPendingOrdersInventory_args)other;
19500
 
19501
      lastComparison = Boolean.valueOf(isSetVendorid()).compareTo(typedOther.isSetVendorid());
19502
      if (lastComparison != 0) {
19503
        return lastComparison;
19504
      }
19505
      if (isSetVendorid()) {
19506
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorid, typedOther.vendorid);
19507
        if (lastComparison != 0) {
19508
          return lastComparison;
19509
        }
19510
      }
19511
      return 0;
19512
    }
19513
 
19514
    public _Fields fieldForId(int fieldId) {
19515
      return _Fields.findByThriftId(fieldId);
19516
    }
19517
 
19518
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19519
      org.apache.thrift.protocol.TField field;
19520
      iprot.readStructBegin();
19521
      while (true)
19522
      {
19523
        field = iprot.readFieldBegin();
19524
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19525
          break;
19526
        }
19527
        switch (field.id) {
19528
          case 1: // VENDORID
19529
            if (field.type == org.apache.thrift.protocol.TType.I64) {
19530
              this.vendorid = iprot.readI64();
19531
              setVendoridIsSet(true);
19532
            } else { 
19533
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19534
            }
19535
            break;
19536
          default:
19537
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19538
        }
19539
        iprot.readFieldEnd();
19540
      }
19541
      iprot.readStructEnd();
19542
      validate();
19543
    }
19544
 
19545
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19546
      validate();
19547
 
19548
      oprot.writeStructBegin(STRUCT_DESC);
19549
      oprot.writeFieldBegin(VENDORID_FIELD_DESC);
19550
      oprot.writeI64(this.vendorid);
19551
      oprot.writeFieldEnd();
19552
      oprot.writeFieldStop();
19553
      oprot.writeStructEnd();
19554
    }
19555
 
19556
    @Override
19557
    public String toString() {
19558
      StringBuilder sb = new StringBuilder("getPendingOrdersInventory_args(");
19559
      boolean first = true;
19560
 
19561
      sb.append("vendorid:");
19562
      sb.append(this.vendorid);
19563
      first = false;
19564
      sb.append(")");
19565
      return sb.toString();
19566
    }
19567
 
19568
    public void validate() throws org.apache.thrift.TException {
19569
      // check for required fields
19570
    }
19571
 
19572
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19573
      try {
19574
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19575
      } catch (org.apache.thrift.TException te) {
19576
        throw new java.io.IOException(te);
19577
      }
19578
    }
19579
 
19580
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19581
      try {
19582
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
19583
        __isset_bit_vector = new BitSet(1);
19584
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19585
      } catch (org.apache.thrift.TException te) {
19586
        throw new java.io.IOException(te);
19587
      }
19588
    }
19589
 
19590
  }
19591
 
19592
  public static class getPendingOrdersInventory_result implements org.apache.thrift.TBase<getPendingOrdersInventory_result, getPendingOrdersInventory_result._Fields>, java.io.Serializable, Cloneable   {
19593
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getPendingOrdersInventory_result");
19594
 
19595
    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);
19596
 
19597
    private List<AvailableAndReservedStock> success; // required
19598
 
19599
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19600
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19601
      SUCCESS((short)0, "success");
19602
 
19603
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19604
 
19605
      static {
19606
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19607
          byName.put(field.getFieldName(), field);
19608
        }
19609
      }
19610
 
19611
      /**
19612
       * Find the _Fields constant that matches fieldId, or null if its not found.
19613
       */
19614
      public static _Fields findByThriftId(int fieldId) {
19615
        switch(fieldId) {
19616
          case 0: // SUCCESS
19617
            return SUCCESS;
19618
          default:
19619
            return null;
19620
        }
19621
      }
19622
 
19623
      /**
19624
       * Find the _Fields constant that matches fieldId, throwing an exception
19625
       * if it is not found.
19626
       */
19627
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19628
        _Fields fields = findByThriftId(fieldId);
19629
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19630
        return fields;
19631
      }
19632
 
19633
      /**
19634
       * Find the _Fields constant that matches name, or null if its not found.
19635
       */
19636
      public static _Fields findByName(String name) {
19637
        return byName.get(name);
19638
      }
19639
 
19640
      private final short _thriftId;
19641
      private final String _fieldName;
19642
 
19643
      _Fields(short thriftId, String fieldName) {
19644
        _thriftId = thriftId;
19645
        _fieldName = fieldName;
19646
      }
19647
 
19648
      public short getThriftFieldId() {
19649
        return _thriftId;
19650
      }
19651
 
19652
      public String getFieldName() {
19653
        return _fieldName;
19654
      }
19655
    }
19656
 
19657
    // isset id assignments
19658
 
19659
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
19660
    static {
19661
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
19662
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
19663
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
19664
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, AvailableAndReservedStock.class))));
19665
      metaDataMap = Collections.unmodifiableMap(tmpMap);
19666
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getPendingOrdersInventory_result.class, metaDataMap);
19667
    }
19668
 
19669
    public getPendingOrdersInventory_result() {
19670
    }
19671
 
19672
    public getPendingOrdersInventory_result(
19673
      List<AvailableAndReservedStock> success)
19674
    {
19675
      this();
19676
      this.success = success;
19677
    }
19678
 
19679
    /**
19680
     * Performs a deep copy on <i>other</i>.
19681
     */
19682
    public getPendingOrdersInventory_result(getPendingOrdersInventory_result other) {
19683
      if (other.isSetSuccess()) {
19684
        List<AvailableAndReservedStock> __this__success = new ArrayList<AvailableAndReservedStock>();
19685
        for (AvailableAndReservedStock other_element : other.success) {
19686
          __this__success.add(new AvailableAndReservedStock(other_element));
19687
        }
19688
        this.success = __this__success;
19689
      }
19690
    }
19691
 
19692
    public getPendingOrdersInventory_result deepCopy() {
19693
      return new getPendingOrdersInventory_result(this);
19694
    }
19695
 
19696
    @Override
19697
    public void clear() {
19698
      this.success = null;
19699
    }
19700
 
19701
    public int getSuccessSize() {
19702
      return (this.success == null) ? 0 : this.success.size();
19703
    }
19704
 
19705
    public java.util.Iterator<AvailableAndReservedStock> getSuccessIterator() {
19706
      return (this.success == null) ? null : this.success.iterator();
19707
    }
19708
 
19709
    public void addToSuccess(AvailableAndReservedStock elem) {
19710
      if (this.success == null) {
19711
        this.success = new ArrayList<AvailableAndReservedStock>();
19712
      }
19713
      this.success.add(elem);
19714
    }
19715
 
19716
    public List<AvailableAndReservedStock> getSuccess() {
19717
      return this.success;
19718
    }
19719
 
19720
    public void setSuccess(List<AvailableAndReservedStock> success) {
19721
      this.success = success;
19722
    }
19723
 
19724
    public void unsetSuccess() {
19725
      this.success = null;
19726
    }
19727
 
19728
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
19729
    public boolean isSetSuccess() {
19730
      return this.success != null;
19731
    }
19732
 
19733
    public void setSuccessIsSet(boolean value) {
19734
      if (!value) {
19735
        this.success = null;
19736
      }
19737
    }
19738
 
19739
    public void setFieldValue(_Fields field, Object value) {
19740
      switch (field) {
19741
      case SUCCESS:
19742
        if (value == null) {
19743
          unsetSuccess();
19744
        } else {
19745
          setSuccess((List<AvailableAndReservedStock>)value);
19746
        }
19747
        break;
19748
 
19749
      }
19750
    }
19751
 
19752
    public Object getFieldValue(_Fields field) {
19753
      switch (field) {
19754
      case SUCCESS:
19755
        return getSuccess();
19756
 
19757
      }
19758
      throw new IllegalStateException();
19759
    }
19760
 
19761
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
19762
    public boolean isSet(_Fields field) {
19763
      if (field == null) {
19764
        throw new IllegalArgumentException();
19765
      }
19766
 
19767
      switch (field) {
19768
      case SUCCESS:
19769
        return isSetSuccess();
19770
      }
19771
      throw new IllegalStateException();
19772
    }
19773
 
19774
    @Override
19775
    public boolean equals(Object that) {
19776
      if (that == null)
19777
        return false;
19778
      if (that instanceof getPendingOrdersInventory_result)
19779
        return this.equals((getPendingOrdersInventory_result)that);
19780
      return false;
19781
    }
19782
 
19783
    public boolean equals(getPendingOrdersInventory_result that) {
19784
      if (that == null)
19785
        return false;
19786
 
19787
      boolean this_present_success = true && this.isSetSuccess();
19788
      boolean that_present_success = true && that.isSetSuccess();
19789
      if (this_present_success || that_present_success) {
19790
        if (!(this_present_success && that_present_success))
19791
          return false;
19792
        if (!this.success.equals(that.success))
19793
          return false;
19794
      }
19795
 
19796
      return true;
19797
    }
19798
 
19799
    @Override
19800
    public int hashCode() {
19801
      return 0;
19802
    }
19803
 
19804
    public int compareTo(getPendingOrdersInventory_result other) {
19805
      if (!getClass().equals(other.getClass())) {
19806
        return getClass().getName().compareTo(other.getClass().getName());
19807
      }
19808
 
19809
      int lastComparison = 0;
19810
      getPendingOrdersInventory_result typedOther = (getPendingOrdersInventory_result)other;
19811
 
19812
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
19813
      if (lastComparison != 0) {
19814
        return lastComparison;
19815
      }
19816
      if (isSetSuccess()) {
19817
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
19818
        if (lastComparison != 0) {
19819
          return lastComparison;
19820
        }
19821
      }
19822
      return 0;
19823
    }
19824
 
19825
    public _Fields fieldForId(int fieldId) {
19826
      return _Fields.findByThriftId(fieldId);
19827
    }
19828
 
19829
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
19830
      org.apache.thrift.protocol.TField field;
19831
      iprot.readStructBegin();
19832
      while (true)
19833
      {
19834
        field = iprot.readFieldBegin();
19835
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
19836
          break;
19837
        }
19838
        switch (field.id) {
19839
          case 0: // SUCCESS
19840
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
19841
              {
19842
                org.apache.thrift.protocol.TList _list44 = iprot.readListBegin();
19843
                this.success = new ArrayList<AvailableAndReservedStock>(_list44.size);
19844
                for (int _i45 = 0; _i45 < _list44.size; ++_i45)
19845
                {
19846
                  AvailableAndReservedStock _elem46; // required
19847
                  _elem46 = new AvailableAndReservedStock();
19848
                  _elem46.read(iprot);
19849
                  this.success.add(_elem46);
19850
                }
19851
                iprot.readListEnd();
19852
              }
19853
            } else { 
19854
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19855
            }
19856
            break;
19857
          default:
19858
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
19859
        }
19860
        iprot.readFieldEnd();
19861
      }
19862
      iprot.readStructEnd();
19863
      validate();
19864
    }
19865
 
19866
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
19867
      oprot.writeStructBegin(STRUCT_DESC);
19868
 
19869
      if (this.isSetSuccess()) {
19870
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
19871
        {
19872
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
19873
          for (AvailableAndReservedStock _iter47 : this.success)
19874
          {
19875
            _iter47.write(oprot);
19876
          }
19877
          oprot.writeListEnd();
19878
        }
19879
        oprot.writeFieldEnd();
19880
      }
19881
      oprot.writeFieldStop();
19882
      oprot.writeStructEnd();
19883
    }
19884
 
19885
    @Override
19886
    public String toString() {
19887
      StringBuilder sb = new StringBuilder("getPendingOrdersInventory_result(");
19888
      boolean first = true;
19889
 
19890
      sb.append("success:");
19891
      if (this.success == null) {
19892
        sb.append("null");
19893
      } else {
19894
        sb.append(this.success);
19895
      }
19896
      first = false;
19897
      sb.append(")");
19898
      return sb.toString();
19899
    }
19900
 
19901
    public void validate() throws org.apache.thrift.TException {
19902
      // check for required fields
19903
    }
19904
 
19905
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
19906
      try {
19907
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
19908
      } catch (org.apache.thrift.TException te) {
19909
        throw new java.io.IOException(te);
19910
      }
19911
    }
19912
 
19913
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
19914
      try {
19915
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
19916
      } catch (org.apache.thrift.TException te) {
19917
        throw new java.io.IOException(te);
19918
      }
19919
    }
19920
 
19921
  }
19922
 
19923
  public static class getWarehouses_args implements org.apache.thrift.TBase<getWarehouses_args, getWarehouses_args._Fields>, java.io.Serializable, Cloneable   {
19924
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouses_args");
19925
 
19926
    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);
19927
    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);
19928
    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);
19929
    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);
19930
    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);
19931
 
19932
    private WarehouseType warehouseType; // required
19933
    private InventoryType inventoryType; // required
19934
    private long vendorId; // required
19935
    private long billingWarehouseId; // required
19936
    private long shippingWarehouseId; // required
19937
 
19938
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
19939
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
19940
      /**
19941
       * 
19942
       * @see WarehouseType
19943
       */
19944
      WAREHOUSE_TYPE((short)1, "warehouseType"),
19945
      /**
19946
       * 
19947
       * @see InventoryType
19948
       */
19949
      INVENTORY_TYPE((short)2, "inventoryType"),
19950
      VENDOR_ID((short)3, "vendorId"),
19951
      BILLING_WAREHOUSE_ID((short)4, "billingWarehouseId"),
19952
      SHIPPING_WAREHOUSE_ID((short)5, "shippingWarehouseId");
19953
 
19954
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
19955
 
19956
      static {
19957
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
19958
          byName.put(field.getFieldName(), field);
19959
        }
19960
      }
19961
 
19962
      /**
19963
       * Find the _Fields constant that matches fieldId, or null if its not found.
19964
       */
19965
      public static _Fields findByThriftId(int fieldId) {
19966
        switch(fieldId) {
19967
          case 1: // WAREHOUSE_TYPE
19968
            return WAREHOUSE_TYPE;
19969
          case 2: // INVENTORY_TYPE
19970
            return INVENTORY_TYPE;
19971
          case 3: // VENDOR_ID
19972
            return VENDOR_ID;
19973
          case 4: // BILLING_WAREHOUSE_ID
19974
            return BILLING_WAREHOUSE_ID;
19975
          case 5: // SHIPPING_WAREHOUSE_ID
19976
            return SHIPPING_WAREHOUSE_ID;
19977
          default:
19978
            return null;
19979
        }
19980
      }
19981
 
19982
      /**
19983
       * Find the _Fields constant that matches fieldId, throwing an exception
19984
       * if it is not found.
19985
       */
19986
      public static _Fields findByThriftIdOrThrow(int fieldId) {
19987
        _Fields fields = findByThriftId(fieldId);
19988
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
19989
        return fields;
19990
      }
19991
 
19992
      /**
19993
       * Find the _Fields constant that matches name, or null if its not found.
19994
       */
19995
      public static _Fields findByName(String name) {
19996
        return byName.get(name);
19997
      }
19998
 
19999
      private final short _thriftId;
20000
      private final String _fieldName;
20001
 
20002
      _Fields(short thriftId, String fieldName) {
20003
        _thriftId = thriftId;
20004
        _fieldName = fieldName;
20005
      }
20006
 
20007
      public short getThriftFieldId() {
20008
        return _thriftId;
20009
      }
20010
 
20011
      public String getFieldName() {
20012
        return _fieldName;
20013
      }
20014
    }
20015
 
20016
    // isset id assignments
20017
    private static final int __VENDORID_ISSET_ID = 0;
20018
    private static final int __BILLINGWAREHOUSEID_ISSET_ID = 1;
20019
    private static final int __SHIPPINGWAREHOUSEID_ISSET_ID = 2;
20020
    private BitSet __isset_bit_vector = new BitSet(3);
20021
 
20022
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20023
    static {
20024
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20025
      tmpMap.put(_Fields.WAREHOUSE_TYPE, new org.apache.thrift.meta_data.FieldMetaData("warehouseType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20026
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, WarehouseType.class)));
20027
      tmpMap.put(_Fields.INVENTORY_TYPE, new org.apache.thrift.meta_data.FieldMetaData("inventoryType", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20028
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, InventoryType.class)));
20029
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20030
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20031
      tmpMap.put(_Fields.BILLING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("billingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20032
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20033
      tmpMap.put(_Fields.SHIPPING_WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("shippingWarehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20034
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
20035
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20036
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouses_args.class, metaDataMap);
20037
    }
20038
 
20039
    public getWarehouses_args() {
20040
    }
20041
 
20042
    public getWarehouses_args(
20043
      WarehouseType warehouseType,
20044
      InventoryType inventoryType,
20045
      long vendorId,
20046
      long billingWarehouseId,
20047
      long shippingWarehouseId)
20048
    {
20049
      this();
20050
      this.warehouseType = warehouseType;
20051
      this.inventoryType = inventoryType;
20052
      this.vendorId = vendorId;
20053
      setVendorIdIsSet(true);
20054
      this.billingWarehouseId = billingWarehouseId;
20055
      setBillingWarehouseIdIsSet(true);
20056
      this.shippingWarehouseId = shippingWarehouseId;
20057
      setShippingWarehouseIdIsSet(true);
20058
    }
20059
 
20060
    /**
20061
     * Performs a deep copy on <i>other</i>.
20062
     */
20063
    public getWarehouses_args(getWarehouses_args other) {
20064
      __isset_bit_vector.clear();
20065
      __isset_bit_vector.or(other.__isset_bit_vector);
20066
      if (other.isSetWarehouseType()) {
20067
        this.warehouseType = other.warehouseType;
20068
      }
20069
      if (other.isSetInventoryType()) {
20070
        this.inventoryType = other.inventoryType;
20071
      }
20072
      this.vendorId = other.vendorId;
20073
      this.billingWarehouseId = other.billingWarehouseId;
20074
      this.shippingWarehouseId = other.shippingWarehouseId;
20075
    }
20076
 
20077
    public getWarehouses_args deepCopy() {
20078
      return new getWarehouses_args(this);
20079
    }
20080
 
20081
    @Override
20082
    public void clear() {
20083
      this.warehouseType = null;
20084
      this.inventoryType = null;
20085
      setVendorIdIsSet(false);
20086
      this.vendorId = 0;
20087
      setBillingWarehouseIdIsSet(false);
20088
      this.billingWarehouseId = 0;
20089
      setShippingWarehouseIdIsSet(false);
20090
      this.shippingWarehouseId = 0;
20091
    }
20092
 
20093
    /**
20094
     * 
20095
     * @see WarehouseType
20096
     */
20097
    public WarehouseType getWarehouseType() {
20098
      return this.warehouseType;
20099
    }
20100
 
20101
    /**
20102
     * 
20103
     * @see WarehouseType
20104
     */
20105
    public void setWarehouseType(WarehouseType warehouseType) {
20106
      this.warehouseType = warehouseType;
20107
    }
20108
 
20109
    public void unsetWarehouseType() {
20110
      this.warehouseType = null;
20111
    }
20112
 
20113
    /** Returns true if field warehouseType is set (has been assigned a value) and false otherwise */
20114
    public boolean isSetWarehouseType() {
20115
      return this.warehouseType != null;
20116
    }
20117
 
20118
    public void setWarehouseTypeIsSet(boolean value) {
20119
      if (!value) {
20120
        this.warehouseType = null;
20121
      }
20122
    }
20123
 
20124
    /**
20125
     * 
20126
     * @see InventoryType
20127
     */
20128
    public InventoryType getInventoryType() {
20129
      return this.inventoryType;
20130
    }
20131
 
20132
    /**
20133
     * 
20134
     * @see InventoryType
20135
     */
20136
    public void setInventoryType(InventoryType inventoryType) {
20137
      this.inventoryType = inventoryType;
20138
    }
20139
 
20140
    public void unsetInventoryType() {
20141
      this.inventoryType = null;
20142
    }
20143
 
20144
    /** Returns true if field inventoryType is set (has been assigned a value) and false otherwise */
20145
    public boolean isSetInventoryType() {
20146
      return this.inventoryType != null;
20147
    }
20148
 
20149
    public void setInventoryTypeIsSet(boolean value) {
20150
      if (!value) {
20151
        this.inventoryType = null;
20152
      }
20153
    }
20154
 
20155
    public long getVendorId() {
20156
      return this.vendorId;
20157
    }
20158
 
20159
    public void setVendorId(long vendorId) {
20160
      this.vendorId = vendorId;
20161
      setVendorIdIsSet(true);
20162
    }
20163
 
20164
    public void unsetVendorId() {
20165
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
20166
    }
20167
 
20168
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
20169
    public boolean isSetVendorId() {
20170
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
20171
    }
20172
 
20173
    public void setVendorIdIsSet(boolean value) {
20174
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
20175
    }
20176
 
20177
    public long getBillingWarehouseId() {
20178
      return this.billingWarehouseId;
20179
    }
20180
 
20181
    public void setBillingWarehouseId(long billingWarehouseId) {
20182
      this.billingWarehouseId = billingWarehouseId;
20183
      setBillingWarehouseIdIsSet(true);
20184
    }
20185
 
20186
    public void unsetBillingWarehouseId() {
20187
      __isset_bit_vector.clear(__BILLINGWAREHOUSEID_ISSET_ID);
20188
    }
20189
 
20190
    /** Returns true if field billingWarehouseId is set (has been assigned a value) and false otherwise */
20191
    public boolean isSetBillingWarehouseId() {
20192
      return __isset_bit_vector.get(__BILLINGWAREHOUSEID_ISSET_ID);
20193
    }
20194
 
20195
    public void setBillingWarehouseIdIsSet(boolean value) {
20196
      __isset_bit_vector.set(__BILLINGWAREHOUSEID_ISSET_ID, value);
20197
    }
20198
 
20199
    public long getShippingWarehouseId() {
20200
      return this.shippingWarehouseId;
20201
    }
20202
 
20203
    public void setShippingWarehouseId(long shippingWarehouseId) {
20204
      this.shippingWarehouseId = shippingWarehouseId;
20205
      setShippingWarehouseIdIsSet(true);
20206
    }
20207
 
20208
    public void unsetShippingWarehouseId() {
20209
      __isset_bit_vector.clear(__SHIPPINGWAREHOUSEID_ISSET_ID);
20210
    }
20211
 
20212
    /** Returns true if field shippingWarehouseId is set (has been assigned a value) and false otherwise */
20213
    public boolean isSetShippingWarehouseId() {
20214
      return __isset_bit_vector.get(__SHIPPINGWAREHOUSEID_ISSET_ID);
20215
    }
20216
 
20217
    public void setShippingWarehouseIdIsSet(boolean value) {
20218
      __isset_bit_vector.set(__SHIPPINGWAREHOUSEID_ISSET_ID, value);
20219
    }
20220
 
20221
    public void setFieldValue(_Fields field, Object value) {
20222
      switch (field) {
20223
      case WAREHOUSE_TYPE:
20224
        if (value == null) {
20225
          unsetWarehouseType();
20226
        } else {
20227
          setWarehouseType((WarehouseType)value);
20228
        }
20229
        break;
20230
 
20231
      case INVENTORY_TYPE:
20232
        if (value == null) {
20233
          unsetInventoryType();
20234
        } else {
20235
          setInventoryType((InventoryType)value);
20236
        }
20237
        break;
20238
 
20239
      case VENDOR_ID:
20240
        if (value == null) {
20241
          unsetVendorId();
20242
        } else {
20243
          setVendorId((Long)value);
20244
        }
20245
        break;
20246
 
20247
      case BILLING_WAREHOUSE_ID:
20248
        if (value == null) {
20249
          unsetBillingWarehouseId();
20250
        } else {
20251
          setBillingWarehouseId((Long)value);
20252
        }
20253
        break;
20254
 
20255
      case SHIPPING_WAREHOUSE_ID:
20256
        if (value == null) {
20257
          unsetShippingWarehouseId();
20258
        } else {
20259
          setShippingWarehouseId((Long)value);
20260
        }
20261
        break;
20262
 
20263
      }
20264
    }
20265
 
20266
    public Object getFieldValue(_Fields field) {
20267
      switch (field) {
20268
      case WAREHOUSE_TYPE:
20269
        return getWarehouseType();
20270
 
20271
      case INVENTORY_TYPE:
20272
        return getInventoryType();
20273
 
20274
      case VENDOR_ID:
20275
        return Long.valueOf(getVendorId());
20276
 
20277
      case BILLING_WAREHOUSE_ID:
20278
        return Long.valueOf(getBillingWarehouseId());
20279
 
20280
      case SHIPPING_WAREHOUSE_ID:
20281
        return Long.valueOf(getShippingWarehouseId());
20282
 
20283
      }
20284
      throw new IllegalStateException();
20285
    }
20286
 
20287
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20288
    public boolean isSet(_Fields field) {
20289
      if (field == null) {
20290
        throw new IllegalArgumentException();
20291
      }
20292
 
20293
      switch (field) {
20294
      case WAREHOUSE_TYPE:
20295
        return isSetWarehouseType();
20296
      case INVENTORY_TYPE:
20297
        return isSetInventoryType();
20298
      case VENDOR_ID:
20299
        return isSetVendorId();
20300
      case BILLING_WAREHOUSE_ID:
20301
        return isSetBillingWarehouseId();
20302
      case SHIPPING_WAREHOUSE_ID:
20303
        return isSetShippingWarehouseId();
20304
      }
20305
      throw new IllegalStateException();
20306
    }
20307
 
20308
    @Override
20309
    public boolean equals(Object that) {
20310
      if (that == null)
20311
        return false;
20312
      if (that instanceof getWarehouses_args)
20313
        return this.equals((getWarehouses_args)that);
20314
      return false;
20315
    }
20316
 
20317
    public boolean equals(getWarehouses_args that) {
20318
      if (that == null)
20319
        return false;
20320
 
20321
      boolean this_present_warehouseType = true && this.isSetWarehouseType();
20322
      boolean that_present_warehouseType = true && that.isSetWarehouseType();
20323
      if (this_present_warehouseType || that_present_warehouseType) {
20324
        if (!(this_present_warehouseType && that_present_warehouseType))
20325
          return false;
20326
        if (!this.warehouseType.equals(that.warehouseType))
20327
          return false;
20328
      }
20329
 
20330
      boolean this_present_inventoryType = true && this.isSetInventoryType();
20331
      boolean that_present_inventoryType = true && that.isSetInventoryType();
20332
      if (this_present_inventoryType || that_present_inventoryType) {
20333
        if (!(this_present_inventoryType && that_present_inventoryType))
20334
          return false;
20335
        if (!this.inventoryType.equals(that.inventoryType))
20336
          return false;
20337
      }
20338
 
20339
      boolean this_present_vendorId = true;
20340
      boolean that_present_vendorId = true;
20341
      if (this_present_vendorId || that_present_vendorId) {
20342
        if (!(this_present_vendorId && that_present_vendorId))
20343
          return false;
20344
        if (this.vendorId != that.vendorId)
20345
          return false;
20346
      }
20347
 
20348
      boolean this_present_billingWarehouseId = true;
20349
      boolean that_present_billingWarehouseId = true;
20350
      if (this_present_billingWarehouseId || that_present_billingWarehouseId) {
20351
        if (!(this_present_billingWarehouseId && that_present_billingWarehouseId))
20352
          return false;
20353
        if (this.billingWarehouseId != that.billingWarehouseId)
20354
          return false;
20355
      }
20356
 
20357
      boolean this_present_shippingWarehouseId = true;
20358
      boolean that_present_shippingWarehouseId = true;
20359
      if (this_present_shippingWarehouseId || that_present_shippingWarehouseId) {
20360
        if (!(this_present_shippingWarehouseId && that_present_shippingWarehouseId))
20361
          return false;
20362
        if (this.shippingWarehouseId != that.shippingWarehouseId)
20363
          return false;
20364
      }
20365
 
20366
      return true;
20367
    }
20368
 
20369
    @Override
20370
    public int hashCode() {
20371
      return 0;
20372
    }
20373
 
20374
    public int compareTo(getWarehouses_args other) {
20375
      if (!getClass().equals(other.getClass())) {
20376
        return getClass().getName().compareTo(other.getClass().getName());
20377
      }
20378
 
20379
      int lastComparison = 0;
20380
      getWarehouses_args typedOther = (getWarehouses_args)other;
20381
 
20382
      lastComparison = Boolean.valueOf(isSetWarehouseType()).compareTo(typedOther.isSetWarehouseType());
20383
      if (lastComparison != 0) {
20384
        return lastComparison;
20385
      }
20386
      if (isSetWarehouseType()) {
20387
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseType, typedOther.warehouseType);
20388
        if (lastComparison != 0) {
20389
          return lastComparison;
20390
        }
20391
      }
20392
      lastComparison = Boolean.valueOf(isSetInventoryType()).compareTo(typedOther.isSetInventoryType());
20393
      if (lastComparison != 0) {
20394
        return lastComparison;
20395
      }
20396
      if (isSetInventoryType()) {
20397
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.inventoryType, typedOther.inventoryType);
20398
        if (lastComparison != 0) {
20399
          return lastComparison;
20400
        }
20401
      }
20402
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
20403
      if (lastComparison != 0) {
20404
        return lastComparison;
20405
      }
20406
      if (isSetVendorId()) {
20407
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
20408
        if (lastComparison != 0) {
20409
          return lastComparison;
20410
        }
20411
      }
20412
      lastComparison = Boolean.valueOf(isSetBillingWarehouseId()).compareTo(typedOther.isSetBillingWarehouseId());
20413
      if (lastComparison != 0) {
20414
        return lastComparison;
20415
      }
20416
      if (isSetBillingWarehouseId()) {
20417
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.billingWarehouseId, typedOther.billingWarehouseId);
20418
        if (lastComparison != 0) {
20419
          return lastComparison;
20420
        }
20421
      }
20422
      lastComparison = Boolean.valueOf(isSetShippingWarehouseId()).compareTo(typedOther.isSetShippingWarehouseId());
20423
      if (lastComparison != 0) {
20424
        return lastComparison;
20425
      }
20426
      if (isSetShippingWarehouseId()) {
20427
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.shippingWarehouseId, typedOther.shippingWarehouseId);
20428
        if (lastComparison != 0) {
20429
          return lastComparison;
20430
        }
20431
      }
20432
      return 0;
20433
    }
20434
 
20435
    public _Fields fieldForId(int fieldId) {
20436
      return _Fields.findByThriftId(fieldId);
20437
    }
20438
 
20439
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20440
      org.apache.thrift.protocol.TField field;
20441
      iprot.readStructBegin();
20442
      while (true)
20443
      {
20444
        field = iprot.readFieldBegin();
20445
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20446
          break;
20447
        }
20448
        switch (field.id) {
20449
          case 1: // WAREHOUSE_TYPE
20450
            if (field.type == org.apache.thrift.protocol.TType.I32) {
20451
              this.warehouseType = WarehouseType.findByValue(iprot.readI32());
20452
            } else { 
20453
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20454
            }
20455
            break;
20456
          case 2: // INVENTORY_TYPE
20457
            if (field.type == org.apache.thrift.protocol.TType.I32) {
20458
              this.inventoryType = InventoryType.findByValue(iprot.readI32());
20459
            } else { 
20460
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20461
            }
20462
            break;
20463
          case 3: // VENDOR_ID
20464
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20465
              this.vendorId = iprot.readI64();
20466
              setVendorIdIsSet(true);
20467
            } else { 
20468
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20469
            }
20470
            break;
20471
          case 4: // BILLING_WAREHOUSE_ID
20472
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20473
              this.billingWarehouseId = iprot.readI64();
20474
              setBillingWarehouseIdIsSet(true);
20475
            } else { 
20476
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20477
            }
20478
            break;
20479
          case 5: // SHIPPING_WAREHOUSE_ID
20480
            if (field.type == org.apache.thrift.protocol.TType.I64) {
20481
              this.shippingWarehouseId = iprot.readI64();
20482
              setShippingWarehouseIdIsSet(true);
20483
            } else { 
20484
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20485
            }
20486
            break;
20487
          default:
20488
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20489
        }
20490
        iprot.readFieldEnd();
20491
      }
20492
      iprot.readStructEnd();
20493
      validate();
20494
    }
20495
 
20496
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20497
      validate();
20498
 
20499
      oprot.writeStructBegin(STRUCT_DESC);
20500
      if (this.warehouseType != null) {
20501
        oprot.writeFieldBegin(WAREHOUSE_TYPE_FIELD_DESC);
20502
        oprot.writeI32(this.warehouseType.getValue());
20503
        oprot.writeFieldEnd();
20504
      }
20505
      if (this.inventoryType != null) {
20506
        oprot.writeFieldBegin(INVENTORY_TYPE_FIELD_DESC);
20507
        oprot.writeI32(this.inventoryType.getValue());
20508
        oprot.writeFieldEnd();
20509
      }
20510
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
20511
      oprot.writeI64(this.vendorId);
20512
      oprot.writeFieldEnd();
20513
      oprot.writeFieldBegin(BILLING_WAREHOUSE_ID_FIELD_DESC);
20514
      oprot.writeI64(this.billingWarehouseId);
20515
      oprot.writeFieldEnd();
20516
      oprot.writeFieldBegin(SHIPPING_WAREHOUSE_ID_FIELD_DESC);
20517
      oprot.writeI64(this.shippingWarehouseId);
20518
      oprot.writeFieldEnd();
20519
      oprot.writeFieldStop();
20520
      oprot.writeStructEnd();
20521
    }
20522
 
20523
    @Override
20524
    public String toString() {
20525
      StringBuilder sb = new StringBuilder("getWarehouses_args(");
20526
      boolean first = true;
20527
 
20528
      sb.append("warehouseType:");
20529
      if (this.warehouseType == null) {
20530
        sb.append("null");
20531
      } else {
20532
        sb.append(this.warehouseType);
20533
      }
20534
      first = false;
20535
      if (!first) sb.append(", ");
20536
      sb.append("inventoryType:");
20537
      if (this.inventoryType == null) {
20538
        sb.append("null");
20539
      } else {
20540
        sb.append(this.inventoryType);
20541
      }
20542
      first = false;
20543
      if (!first) sb.append(", ");
20544
      sb.append("vendorId:");
20545
      sb.append(this.vendorId);
20546
      first = false;
20547
      if (!first) sb.append(", ");
20548
      sb.append("billingWarehouseId:");
20549
      sb.append(this.billingWarehouseId);
20550
      first = false;
20551
      if (!first) sb.append(", ");
20552
      sb.append("shippingWarehouseId:");
20553
      sb.append(this.shippingWarehouseId);
20554
      first = false;
20555
      sb.append(")");
20556
      return sb.toString();
20557
    }
20558
 
20559
    public void validate() throws org.apache.thrift.TException {
20560
      // check for required fields
20561
    }
20562
 
20563
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20564
      try {
20565
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20566
      } catch (org.apache.thrift.TException te) {
20567
        throw new java.io.IOException(te);
20568
      }
20569
    }
20570
 
20571
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20572
      try {
20573
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20574
      } catch (org.apache.thrift.TException te) {
20575
        throw new java.io.IOException(te);
20576
      }
20577
    }
20578
 
20579
  }
20580
 
20581
  public static class getWarehouses_result implements org.apache.thrift.TBase<getWarehouses_result, getWarehouses_result._Fields>, java.io.Serializable, Cloneable   {
20582
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getWarehouses_result");
20583
 
20584
    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);
20585
 
20586
    private List<Warehouse> success; // required
20587
 
20588
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20589
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20590
      SUCCESS((short)0, "success");
20591
 
20592
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20593
 
20594
      static {
20595
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20596
          byName.put(field.getFieldName(), field);
20597
        }
20598
      }
20599
 
20600
      /**
20601
       * Find the _Fields constant that matches fieldId, or null if its not found.
20602
       */
20603
      public static _Fields findByThriftId(int fieldId) {
20604
        switch(fieldId) {
20605
          case 0: // SUCCESS
20606
            return SUCCESS;
20607
          default:
20608
            return null;
20609
        }
20610
      }
20611
 
20612
      /**
20613
       * Find the _Fields constant that matches fieldId, throwing an exception
20614
       * if it is not found.
20615
       */
20616
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20617
        _Fields fields = findByThriftId(fieldId);
20618
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20619
        return fields;
20620
      }
20621
 
20622
      /**
20623
       * Find the _Fields constant that matches name, or null if its not found.
20624
       */
20625
      public static _Fields findByName(String name) {
20626
        return byName.get(name);
20627
      }
20628
 
20629
      private final short _thriftId;
20630
      private final String _fieldName;
20631
 
20632
      _Fields(short thriftId, String fieldName) {
20633
        _thriftId = thriftId;
20634
        _fieldName = fieldName;
20635
      }
20636
 
20637
      public short getThriftFieldId() {
20638
        return _thriftId;
20639
      }
20640
 
20641
      public String getFieldName() {
20642
        return _fieldName;
20643
      }
20644
    }
20645
 
20646
    // isset id assignments
20647
 
20648
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20649
    static {
20650
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
20651
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
20652
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
20653
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
20654
      metaDataMap = Collections.unmodifiableMap(tmpMap);
20655
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getWarehouses_result.class, metaDataMap);
20656
    }
20657
 
20658
    public getWarehouses_result() {
20659
    }
20660
 
20661
    public getWarehouses_result(
20662
      List<Warehouse> success)
20663
    {
20664
      this();
20665
      this.success = success;
20666
    }
20667
 
20668
    /**
20669
     * Performs a deep copy on <i>other</i>.
20670
     */
20671
    public getWarehouses_result(getWarehouses_result other) {
20672
      if (other.isSetSuccess()) {
20673
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
20674
        for (Warehouse other_element : other.success) {
20675
          __this__success.add(new Warehouse(other_element));
20676
        }
20677
        this.success = __this__success;
20678
      }
20679
    }
20680
 
20681
    public getWarehouses_result deepCopy() {
20682
      return new getWarehouses_result(this);
20683
    }
20684
 
20685
    @Override
20686
    public void clear() {
20687
      this.success = null;
20688
    }
20689
 
20690
    public int getSuccessSize() {
20691
      return (this.success == null) ? 0 : this.success.size();
20692
    }
20693
 
20694
    public java.util.Iterator<Warehouse> getSuccessIterator() {
20695
      return (this.success == null) ? null : this.success.iterator();
20696
    }
20697
 
20698
    public void addToSuccess(Warehouse elem) {
20699
      if (this.success == null) {
20700
        this.success = new ArrayList<Warehouse>();
20701
      }
20702
      this.success.add(elem);
20703
    }
20704
 
20705
    public List<Warehouse> getSuccess() {
20706
      return this.success;
20707
    }
20708
 
20709
    public void setSuccess(List<Warehouse> success) {
20710
      this.success = success;
20711
    }
20712
 
20713
    public void unsetSuccess() {
20714
      this.success = null;
20715
    }
20716
 
20717
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
20718
    public boolean isSetSuccess() {
20719
      return this.success != null;
20720
    }
20721
 
20722
    public void setSuccessIsSet(boolean value) {
20723
      if (!value) {
20724
        this.success = null;
20725
      }
20726
    }
20727
 
20728
    public void setFieldValue(_Fields field, Object value) {
20729
      switch (field) {
20730
      case SUCCESS:
20731
        if (value == null) {
20732
          unsetSuccess();
20733
        } else {
20734
          setSuccess((List<Warehouse>)value);
20735
        }
20736
        break;
20737
 
20738
      }
20739
    }
20740
 
20741
    public Object getFieldValue(_Fields field) {
20742
      switch (field) {
20743
      case SUCCESS:
20744
        return getSuccess();
20745
 
20746
      }
20747
      throw new IllegalStateException();
20748
    }
20749
 
20750
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
20751
    public boolean isSet(_Fields field) {
20752
      if (field == null) {
20753
        throw new IllegalArgumentException();
20754
      }
20755
 
20756
      switch (field) {
20757
      case SUCCESS:
20758
        return isSetSuccess();
20759
      }
20760
      throw new IllegalStateException();
20761
    }
20762
 
20763
    @Override
20764
    public boolean equals(Object that) {
20765
      if (that == null)
20766
        return false;
20767
      if (that instanceof getWarehouses_result)
20768
        return this.equals((getWarehouses_result)that);
20769
      return false;
20770
    }
20771
 
20772
    public boolean equals(getWarehouses_result that) {
20773
      if (that == null)
20774
        return false;
20775
 
20776
      boolean this_present_success = true && this.isSetSuccess();
20777
      boolean that_present_success = true && that.isSetSuccess();
20778
      if (this_present_success || that_present_success) {
20779
        if (!(this_present_success && that_present_success))
20780
          return false;
20781
        if (!this.success.equals(that.success))
20782
          return false;
20783
      }
20784
 
20785
      return true;
20786
    }
20787
 
20788
    @Override
20789
    public int hashCode() {
20790
      return 0;
20791
    }
20792
 
20793
    public int compareTo(getWarehouses_result other) {
20794
      if (!getClass().equals(other.getClass())) {
20795
        return getClass().getName().compareTo(other.getClass().getName());
20796
      }
20797
 
20798
      int lastComparison = 0;
20799
      getWarehouses_result typedOther = (getWarehouses_result)other;
20800
 
20801
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
20802
      if (lastComparison != 0) {
20803
        return lastComparison;
20804
      }
20805
      if (isSetSuccess()) {
20806
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
20807
        if (lastComparison != 0) {
20808
          return lastComparison;
20809
        }
20810
      }
20811
      return 0;
20812
    }
20813
 
20814
    public _Fields fieldForId(int fieldId) {
20815
      return _Fields.findByThriftId(fieldId);
20816
    }
20817
 
20818
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
20819
      org.apache.thrift.protocol.TField field;
20820
      iprot.readStructBegin();
20821
      while (true)
20822
      {
20823
        field = iprot.readFieldBegin();
20824
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
20825
          break;
20826
        }
20827
        switch (field.id) {
20828
          case 0: // SUCCESS
20829
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
20830
              {
20831
                org.apache.thrift.protocol.TList _list48 = iprot.readListBegin();
20832
                this.success = new ArrayList<Warehouse>(_list48.size);
20833
                for (int _i49 = 0; _i49 < _list48.size; ++_i49)
20834
                {
20835
                  Warehouse _elem50; // required
20836
                  _elem50 = new Warehouse();
20837
                  _elem50.read(iprot);
20838
                  this.success.add(_elem50);
20839
                }
20840
                iprot.readListEnd();
20841
              }
20842
            } else { 
20843
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20844
            }
20845
            break;
20846
          default:
20847
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
20848
        }
20849
        iprot.readFieldEnd();
20850
      }
20851
      iprot.readStructEnd();
20852
      validate();
20853
    }
20854
 
20855
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
20856
      oprot.writeStructBegin(STRUCT_DESC);
20857
 
20858
      if (this.isSetSuccess()) {
20859
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
20860
        {
20861
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
20862
          for (Warehouse _iter51 : this.success)
20863
          {
20864
            _iter51.write(oprot);
20865
          }
20866
          oprot.writeListEnd();
20867
        }
20868
        oprot.writeFieldEnd();
20869
      }
20870
      oprot.writeFieldStop();
20871
      oprot.writeStructEnd();
20872
    }
20873
 
20874
    @Override
20875
    public String toString() {
20876
      StringBuilder sb = new StringBuilder("getWarehouses_result(");
20877
      boolean first = true;
20878
 
20879
      sb.append("success:");
20880
      if (this.success == null) {
20881
        sb.append("null");
20882
      } else {
20883
        sb.append(this.success);
20884
      }
20885
      first = false;
20886
      sb.append(")");
20887
      return sb.toString();
20888
    }
20889
 
20890
    public void validate() throws org.apache.thrift.TException {
20891
      // check for required fields
20892
    }
20893
 
20894
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
20895
      try {
20896
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
20897
      } catch (org.apache.thrift.TException te) {
20898
        throw new java.io.IOException(te);
20899
      }
20900
    }
20901
 
20902
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
20903
      try {
20904
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
20905
      } catch (org.apache.thrift.TException te) {
20906
        throw new java.io.IOException(te);
20907
      }
20908
    }
20909
 
20910
  }
20911
 
20912
  public static class resetAvailability_args implements org.apache.thrift.TBase<resetAvailability_args, resetAvailability_args._Fields>, java.io.Serializable, Cloneable   {
20913
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailability_args");
20914
 
20915
    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);
20916
    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);
20917
    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);
20918
    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);
20919
 
20920
    private String itemKey; // required
20921
    private long vendorId; // required
20922
    private long quantity; // required
20923
    private long warehouseId; // required
20924
 
20925
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
20926
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
20927
      ITEM_KEY((short)1, "itemKey"),
20928
      VENDOR_ID((short)2, "vendorId"),
20929
      QUANTITY((short)3, "quantity"),
20930
      WAREHOUSE_ID((short)4, "warehouseId");
20931
 
20932
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
20933
 
20934
      static {
20935
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
20936
          byName.put(field.getFieldName(), field);
20937
        }
20938
      }
20939
 
20940
      /**
20941
       * Find the _Fields constant that matches fieldId, or null if its not found.
20942
       */
20943
      public static _Fields findByThriftId(int fieldId) {
20944
        switch(fieldId) {
20945
          case 1: // ITEM_KEY
20946
            return ITEM_KEY;
20947
          case 2: // VENDOR_ID
20948
            return VENDOR_ID;
20949
          case 3: // QUANTITY
20950
            return QUANTITY;
20951
          case 4: // WAREHOUSE_ID
20952
            return WAREHOUSE_ID;
20953
          default:
20954
            return null;
20955
        }
20956
      }
20957
 
20958
      /**
20959
       * Find the _Fields constant that matches fieldId, throwing an exception
20960
       * if it is not found.
20961
       */
20962
      public static _Fields findByThriftIdOrThrow(int fieldId) {
20963
        _Fields fields = findByThriftId(fieldId);
20964
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
20965
        return fields;
20966
      }
20967
 
20968
      /**
20969
       * Find the _Fields constant that matches name, or null if its not found.
20970
       */
20971
      public static _Fields findByName(String name) {
20972
        return byName.get(name);
20973
      }
20974
 
20975
      private final short _thriftId;
20976
      private final String _fieldName;
20977
 
20978
      _Fields(short thriftId, String fieldName) {
20979
        _thriftId = thriftId;
20980
        _fieldName = fieldName;
20981
      }
20982
 
20983
      public short getThriftFieldId() {
20984
        return _thriftId;
20985
      }
20986
 
20987
      public String getFieldName() {
20988
        return _fieldName;
20989
      }
20990
    }
20991
 
20992
    // isset id assignments
20993
    private static final int __VENDORID_ISSET_ID = 0;
20994
    private static final int __QUANTITY_ISSET_ID = 1;
20995
    private static final int __WAREHOUSEID_ISSET_ID = 2;
20996
    private BitSet __isset_bit_vector = new BitSet(3);
20997
 
20998
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
20999
    static {
21000
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21001
      tmpMap.put(_Fields.ITEM_KEY, new org.apache.thrift.meta_data.FieldMetaData("itemKey", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21002
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
21003
      tmpMap.put(_Fields.VENDOR_ID, new org.apache.thrift.meta_data.FieldMetaData("vendorId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21004
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21005
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21006
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21007
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21008
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21009
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21010
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailability_args.class, metaDataMap);
21011
    }
21012
 
21013
    public resetAvailability_args() {
21014
    }
21015
 
21016
    public resetAvailability_args(
21017
      String itemKey,
21018
      long vendorId,
21019
      long quantity,
21020
      long warehouseId)
21021
    {
21022
      this();
21023
      this.itemKey = itemKey;
21024
      this.vendorId = vendorId;
21025
      setVendorIdIsSet(true);
21026
      this.quantity = quantity;
21027
      setQuantityIsSet(true);
21028
      this.warehouseId = warehouseId;
21029
      setWarehouseIdIsSet(true);
21030
    }
21031
 
21032
    /**
21033
     * Performs a deep copy on <i>other</i>.
21034
     */
21035
    public resetAvailability_args(resetAvailability_args other) {
21036
      __isset_bit_vector.clear();
21037
      __isset_bit_vector.or(other.__isset_bit_vector);
21038
      if (other.isSetItemKey()) {
21039
        this.itemKey = other.itemKey;
21040
      }
21041
      this.vendorId = other.vendorId;
21042
      this.quantity = other.quantity;
21043
      this.warehouseId = other.warehouseId;
21044
    }
21045
 
21046
    public resetAvailability_args deepCopy() {
21047
      return new resetAvailability_args(this);
21048
    }
21049
 
21050
    @Override
21051
    public void clear() {
21052
      this.itemKey = null;
21053
      setVendorIdIsSet(false);
21054
      this.vendorId = 0;
21055
      setQuantityIsSet(false);
21056
      this.quantity = 0;
21057
      setWarehouseIdIsSet(false);
21058
      this.warehouseId = 0;
21059
    }
21060
 
21061
    public String getItemKey() {
21062
      return this.itemKey;
21063
    }
21064
 
21065
    public void setItemKey(String itemKey) {
21066
      this.itemKey = itemKey;
21067
    }
21068
 
21069
    public void unsetItemKey() {
21070
      this.itemKey = null;
21071
    }
21072
 
21073
    /** Returns true if field itemKey is set (has been assigned a value) and false otherwise */
21074
    public boolean isSetItemKey() {
21075
      return this.itemKey != null;
21076
    }
21077
 
21078
    public void setItemKeyIsSet(boolean value) {
21079
      if (!value) {
21080
        this.itemKey = null;
21081
      }
21082
    }
21083
 
21084
    public long getVendorId() {
21085
      return this.vendorId;
21086
    }
21087
 
21088
    public void setVendorId(long vendorId) {
21089
      this.vendorId = vendorId;
21090
      setVendorIdIsSet(true);
21091
    }
21092
 
21093
    public void unsetVendorId() {
21094
      __isset_bit_vector.clear(__VENDORID_ISSET_ID);
21095
    }
21096
 
21097
    /** Returns true if field vendorId is set (has been assigned a value) and false otherwise */
21098
    public boolean isSetVendorId() {
21099
      return __isset_bit_vector.get(__VENDORID_ISSET_ID);
21100
    }
21101
 
21102
    public void setVendorIdIsSet(boolean value) {
21103
      __isset_bit_vector.set(__VENDORID_ISSET_ID, value);
21104
    }
21105
 
21106
    public long getQuantity() {
21107
      return this.quantity;
21108
    }
21109
 
21110
    public void setQuantity(long quantity) {
21111
      this.quantity = quantity;
21112
      setQuantityIsSet(true);
21113
    }
21114
 
21115
    public void unsetQuantity() {
21116
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
21117
    }
21118
 
21119
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
21120
    public boolean isSetQuantity() {
21121
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
21122
    }
21123
 
21124
    public void setQuantityIsSet(boolean value) {
21125
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
21126
    }
21127
 
21128
    public long getWarehouseId() {
21129
      return this.warehouseId;
21130
    }
21131
 
21132
    public void setWarehouseId(long warehouseId) {
21133
      this.warehouseId = warehouseId;
21134
      setWarehouseIdIsSet(true);
21135
    }
21136
 
21137
    public void unsetWarehouseId() {
21138
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
21139
    }
21140
 
21141
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
21142
    public boolean isSetWarehouseId() {
21143
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
21144
    }
21145
 
21146
    public void setWarehouseIdIsSet(boolean value) {
21147
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
21148
    }
21149
 
21150
    public void setFieldValue(_Fields field, Object value) {
21151
      switch (field) {
21152
      case ITEM_KEY:
21153
        if (value == null) {
21154
          unsetItemKey();
21155
        } else {
21156
          setItemKey((String)value);
21157
        }
21158
        break;
21159
 
21160
      case VENDOR_ID:
21161
        if (value == null) {
21162
          unsetVendorId();
21163
        } else {
21164
          setVendorId((Long)value);
21165
        }
21166
        break;
21167
 
21168
      case QUANTITY:
21169
        if (value == null) {
21170
          unsetQuantity();
21171
        } else {
21172
          setQuantity((Long)value);
21173
        }
21174
        break;
21175
 
21176
      case WAREHOUSE_ID:
21177
        if (value == null) {
21178
          unsetWarehouseId();
21179
        } else {
21180
          setWarehouseId((Long)value);
21181
        }
21182
        break;
21183
 
21184
      }
21185
    }
21186
 
21187
    public Object getFieldValue(_Fields field) {
21188
      switch (field) {
21189
      case ITEM_KEY:
21190
        return getItemKey();
21191
 
21192
      case VENDOR_ID:
21193
        return Long.valueOf(getVendorId());
21194
 
21195
      case QUANTITY:
21196
        return Long.valueOf(getQuantity());
21197
 
21198
      case WAREHOUSE_ID:
21199
        return Long.valueOf(getWarehouseId());
21200
 
21201
      }
21202
      throw new IllegalStateException();
21203
    }
21204
 
21205
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21206
    public boolean isSet(_Fields field) {
21207
      if (field == null) {
21208
        throw new IllegalArgumentException();
21209
      }
21210
 
21211
      switch (field) {
21212
      case ITEM_KEY:
21213
        return isSetItemKey();
21214
      case VENDOR_ID:
21215
        return isSetVendorId();
21216
      case QUANTITY:
21217
        return isSetQuantity();
21218
      case WAREHOUSE_ID:
21219
        return isSetWarehouseId();
21220
      }
21221
      throw new IllegalStateException();
21222
    }
21223
 
21224
    @Override
21225
    public boolean equals(Object that) {
21226
      if (that == null)
21227
        return false;
21228
      if (that instanceof resetAvailability_args)
21229
        return this.equals((resetAvailability_args)that);
21230
      return false;
21231
    }
21232
 
21233
    public boolean equals(resetAvailability_args that) {
21234
      if (that == null)
21235
        return false;
21236
 
21237
      boolean this_present_itemKey = true && this.isSetItemKey();
21238
      boolean that_present_itemKey = true && that.isSetItemKey();
21239
      if (this_present_itemKey || that_present_itemKey) {
21240
        if (!(this_present_itemKey && that_present_itemKey))
21241
          return false;
21242
        if (!this.itemKey.equals(that.itemKey))
21243
          return false;
21244
      }
21245
 
21246
      boolean this_present_vendorId = true;
21247
      boolean that_present_vendorId = true;
21248
      if (this_present_vendorId || that_present_vendorId) {
21249
        if (!(this_present_vendorId && that_present_vendorId))
21250
          return false;
21251
        if (this.vendorId != that.vendorId)
21252
          return false;
21253
      }
21254
 
21255
      boolean this_present_quantity = true;
21256
      boolean that_present_quantity = true;
21257
      if (this_present_quantity || that_present_quantity) {
21258
        if (!(this_present_quantity && that_present_quantity))
21259
          return false;
21260
        if (this.quantity != that.quantity)
21261
          return false;
21262
      }
21263
 
21264
      boolean this_present_warehouseId = true;
21265
      boolean that_present_warehouseId = true;
21266
      if (this_present_warehouseId || that_present_warehouseId) {
21267
        if (!(this_present_warehouseId && that_present_warehouseId))
21268
          return false;
21269
        if (this.warehouseId != that.warehouseId)
21270
          return false;
21271
      }
21272
 
21273
      return true;
21274
    }
21275
 
21276
    @Override
21277
    public int hashCode() {
21278
      return 0;
21279
    }
21280
 
21281
    public int compareTo(resetAvailability_args other) {
21282
      if (!getClass().equals(other.getClass())) {
21283
        return getClass().getName().compareTo(other.getClass().getName());
21284
      }
21285
 
21286
      int lastComparison = 0;
21287
      resetAvailability_args typedOther = (resetAvailability_args)other;
21288
 
21289
      lastComparison = Boolean.valueOf(isSetItemKey()).compareTo(typedOther.isSetItemKey());
21290
      if (lastComparison != 0) {
21291
        return lastComparison;
21292
      }
21293
      if (isSetItemKey()) {
21294
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemKey, typedOther.itemKey);
21295
        if (lastComparison != 0) {
21296
          return lastComparison;
21297
        }
21298
      }
21299
      lastComparison = Boolean.valueOf(isSetVendorId()).compareTo(typedOther.isSetVendorId());
21300
      if (lastComparison != 0) {
21301
        return lastComparison;
21302
      }
21303
      if (isSetVendorId()) {
21304
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorId, typedOther.vendorId);
21305
        if (lastComparison != 0) {
21306
          return lastComparison;
21307
        }
21308
      }
21309
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
21310
      if (lastComparison != 0) {
21311
        return lastComparison;
21312
      }
21313
      if (isSetQuantity()) {
21314
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
21315
        if (lastComparison != 0) {
21316
          return lastComparison;
21317
        }
21318
      }
21319
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
21320
      if (lastComparison != 0) {
21321
        return lastComparison;
21322
      }
21323
      if (isSetWarehouseId()) {
21324
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
21325
        if (lastComparison != 0) {
21326
          return lastComparison;
21327
        }
21328
      }
21329
      return 0;
21330
    }
21331
 
21332
    public _Fields fieldForId(int fieldId) {
21333
      return _Fields.findByThriftId(fieldId);
21334
    }
21335
 
21336
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21337
      org.apache.thrift.protocol.TField field;
21338
      iprot.readStructBegin();
21339
      while (true)
21340
      {
21341
        field = iprot.readFieldBegin();
21342
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21343
          break;
21344
        }
21345
        switch (field.id) {
21346
          case 1: // ITEM_KEY
21347
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
21348
              this.itemKey = iprot.readString();
21349
            } else { 
21350
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21351
            }
21352
            break;
21353
          case 2: // VENDOR_ID
21354
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21355
              this.vendorId = iprot.readI64();
21356
              setVendorIdIsSet(true);
21357
            } else { 
21358
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21359
            }
21360
            break;
21361
          case 3: // QUANTITY
21362
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21363
              this.quantity = iprot.readI64();
21364
              setQuantityIsSet(true);
21365
            } else { 
21366
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21367
            }
21368
            break;
21369
          case 4: // WAREHOUSE_ID
21370
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21371
              this.warehouseId = iprot.readI64();
21372
              setWarehouseIdIsSet(true);
21373
            } else { 
21374
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21375
            }
21376
            break;
21377
          default:
21378
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21379
        }
21380
        iprot.readFieldEnd();
21381
      }
21382
      iprot.readStructEnd();
21383
      validate();
21384
    }
21385
 
21386
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21387
      validate();
21388
 
21389
      oprot.writeStructBegin(STRUCT_DESC);
21390
      if (this.itemKey != null) {
21391
        oprot.writeFieldBegin(ITEM_KEY_FIELD_DESC);
21392
        oprot.writeString(this.itemKey);
21393
        oprot.writeFieldEnd();
21394
      }
21395
      oprot.writeFieldBegin(VENDOR_ID_FIELD_DESC);
21396
      oprot.writeI64(this.vendorId);
21397
      oprot.writeFieldEnd();
21398
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
21399
      oprot.writeI64(this.quantity);
21400
      oprot.writeFieldEnd();
21401
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
21402
      oprot.writeI64(this.warehouseId);
21403
      oprot.writeFieldEnd();
21404
      oprot.writeFieldStop();
21405
      oprot.writeStructEnd();
21406
    }
21407
 
21408
    @Override
21409
    public String toString() {
21410
      StringBuilder sb = new StringBuilder("resetAvailability_args(");
21411
      boolean first = true;
21412
 
21413
      sb.append("itemKey:");
21414
      if (this.itemKey == null) {
21415
        sb.append("null");
21416
      } else {
21417
        sb.append(this.itemKey);
21418
      }
21419
      first = false;
21420
      if (!first) sb.append(", ");
21421
      sb.append("vendorId:");
21422
      sb.append(this.vendorId);
21423
      first = false;
21424
      if (!first) sb.append(", ");
21425
      sb.append("quantity:");
21426
      sb.append(this.quantity);
21427
      first = false;
21428
      if (!first) sb.append(", ");
21429
      sb.append("warehouseId:");
21430
      sb.append(this.warehouseId);
21431
      first = false;
21432
      sb.append(")");
21433
      return sb.toString();
21434
    }
21435
 
21436
    public void validate() throws org.apache.thrift.TException {
21437
      // check for required fields
21438
    }
21439
 
21440
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21441
      try {
21442
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21443
      } catch (org.apache.thrift.TException te) {
21444
        throw new java.io.IOException(te);
21445
      }
21446
    }
21447
 
21448
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21449
      try {
21450
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
21451
        __isset_bit_vector = new BitSet(1);
21452
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21453
      } catch (org.apache.thrift.TException te) {
21454
        throw new java.io.IOException(te);
21455
      }
21456
    }
21457
 
21458
  }
21459
 
21460
  public static class resetAvailability_result implements org.apache.thrift.TBase<resetAvailability_result, resetAvailability_result._Fields>, java.io.Serializable, Cloneable   {
21461
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailability_result");
21462
 
21463
    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);
21464
 
21465
    private InventoryServiceException cex; // required
21466
 
21467
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21468
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21469
      CEX((short)1, "cex");
21470
 
21471
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21472
 
21473
      static {
21474
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21475
          byName.put(field.getFieldName(), field);
21476
        }
21477
      }
21478
 
21479
      /**
21480
       * Find the _Fields constant that matches fieldId, or null if its not found.
21481
       */
21482
      public static _Fields findByThriftId(int fieldId) {
21483
        switch(fieldId) {
21484
          case 1: // CEX
21485
            return CEX;
21486
          default:
21487
            return null;
21488
        }
21489
      }
21490
 
21491
      /**
21492
       * Find the _Fields constant that matches fieldId, throwing an exception
21493
       * if it is not found.
21494
       */
21495
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21496
        _Fields fields = findByThriftId(fieldId);
21497
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21498
        return fields;
21499
      }
21500
 
21501
      /**
21502
       * Find the _Fields constant that matches name, or null if its not found.
21503
       */
21504
      public static _Fields findByName(String name) {
21505
        return byName.get(name);
21506
      }
21507
 
21508
      private final short _thriftId;
21509
      private final String _fieldName;
21510
 
21511
      _Fields(short thriftId, String fieldName) {
21512
        _thriftId = thriftId;
21513
        _fieldName = fieldName;
21514
      }
21515
 
21516
      public short getThriftFieldId() {
21517
        return _thriftId;
21518
      }
21519
 
21520
      public String getFieldName() {
21521
        return _fieldName;
21522
      }
21523
    }
21524
 
21525
    // isset id assignments
21526
 
21527
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21528
    static {
21529
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21530
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21531
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
21532
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21533
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailability_result.class, metaDataMap);
21534
    }
21535
 
21536
    public resetAvailability_result() {
21537
    }
21538
 
21539
    public resetAvailability_result(
21540
      InventoryServiceException cex)
21541
    {
21542
      this();
21543
      this.cex = cex;
21544
    }
21545
 
21546
    /**
21547
     * Performs a deep copy on <i>other</i>.
21548
     */
21549
    public resetAvailability_result(resetAvailability_result other) {
21550
      if (other.isSetCex()) {
21551
        this.cex = new InventoryServiceException(other.cex);
21552
      }
21553
    }
21554
 
21555
    public resetAvailability_result deepCopy() {
21556
      return new resetAvailability_result(this);
21557
    }
21558
 
21559
    @Override
21560
    public void clear() {
21561
      this.cex = null;
21562
    }
21563
 
21564
    public InventoryServiceException getCex() {
21565
      return this.cex;
21566
    }
21567
 
21568
    public void setCex(InventoryServiceException cex) {
21569
      this.cex = cex;
21570
    }
21571
 
21572
    public void unsetCex() {
21573
      this.cex = null;
21574
    }
21575
 
21576
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
21577
    public boolean isSetCex() {
21578
      return this.cex != null;
21579
    }
21580
 
21581
    public void setCexIsSet(boolean value) {
21582
      if (!value) {
21583
        this.cex = null;
21584
      }
21585
    }
21586
 
21587
    public void setFieldValue(_Fields field, Object value) {
21588
      switch (field) {
21589
      case CEX:
21590
        if (value == null) {
21591
          unsetCex();
21592
        } else {
21593
          setCex((InventoryServiceException)value);
21594
        }
21595
        break;
21596
 
21597
      }
21598
    }
21599
 
21600
    public Object getFieldValue(_Fields field) {
21601
      switch (field) {
21602
      case CEX:
21603
        return getCex();
21604
 
21605
      }
21606
      throw new IllegalStateException();
21607
    }
21608
 
21609
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21610
    public boolean isSet(_Fields field) {
21611
      if (field == null) {
21612
        throw new IllegalArgumentException();
21613
      }
21614
 
21615
      switch (field) {
21616
      case CEX:
21617
        return isSetCex();
21618
      }
21619
      throw new IllegalStateException();
21620
    }
21621
 
21622
    @Override
21623
    public boolean equals(Object that) {
21624
      if (that == null)
21625
        return false;
21626
      if (that instanceof resetAvailability_result)
21627
        return this.equals((resetAvailability_result)that);
21628
      return false;
21629
    }
21630
 
21631
    public boolean equals(resetAvailability_result that) {
21632
      if (that == null)
21633
        return false;
21634
 
21635
      boolean this_present_cex = true && this.isSetCex();
21636
      boolean that_present_cex = true && that.isSetCex();
21637
      if (this_present_cex || that_present_cex) {
21638
        if (!(this_present_cex && that_present_cex))
21639
          return false;
21640
        if (!this.cex.equals(that.cex))
21641
          return false;
21642
      }
21643
 
21644
      return true;
21645
    }
21646
 
21647
    @Override
21648
    public int hashCode() {
21649
      return 0;
21650
    }
21651
 
21652
    public int compareTo(resetAvailability_result other) {
21653
      if (!getClass().equals(other.getClass())) {
21654
        return getClass().getName().compareTo(other.getClass().getName());
21655
      }
21656
 
21657
      int lastComparison = 0;
21658
      resetAvailability_result typedOther = (resetAvailability_result)other;
21659
 
21660
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
21661
      if (lastComparison != 0) {
21662
        return lastComparison;
21663
      }
21664
      if (isSetCex()) {
21665
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
21666
        if (lastComparison != 0) {
21667
          return lastComparison;
21668
        }
21669
      }
21670
      return 0;
21671
    }
21672
 
21673
    public _Fields fieldForId(int fieldId) {
21674
      return _Fields.findByThriftId(fieldId);
21675
    }
21676
 
21677
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21678
      org.apache.thrift.protocol.TField field;
21679
      iprot.readStructBegin();
21680
      while (true)
21681
      {
21682
        field = iprot.readFieldBegin();
21683
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21684
          break;
21685
        }
21686
        switch (field.id) {
21687
          case 1: // CEX
21688
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
21689
              this.cex = new InventoryServiceException();
21690
              this.cex.read(iprot);
21691
            } else { 
21692
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21693
            }
21694
            break;
21695
          default:
21696
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21697
        }
21698
        iprot.readFieldEnd();
21699
      }
21700
      iprot.readStructEnd();
21701
      validate();
21702
    }
21703
 
21704
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
21705
      oprot.writeStructBegin(STRUCT_DESC);
21706
 
21707
      if (this.isSetCex()) {
21708
        oprot.writeFieldBegin(CEX_FIELD_DESC);
21709
        this.cex.write(oprot);
21710
        oprot.writeFieldEnd();
21711
      }
21712
      oprot.writeFieldStop();
21713
      oprot.writeStructEnd();
21714
    }
21715
 
21716
    @Override
21717
    public String toString() {
21718
      StringBuilder sb = new StringBuilder("resetAvailability_result(");
21719
      boolean first = true;
21720
 
21721
      sb.append("cex:");
21722
      if (this.cex == null) {
21723
        sb.append("null");
21724
      } else {
21725
        sb.append(this.cex);
21726
      }
21727
      first = false;
21728
      sb.append(")");
21729
      return sb.toString();
21730
    }
21731
 
21732
    public void validate() throws org.apache.thrift.TException {
21733
      // check for required fields
21734
    }
21735
 
21736
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
21737
      try {
21738
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
21739
      } catch (org.apache.thrift.TException te) {
21740
        throw new java.io.IOException(te);
21741
      }
21742
    }
21743
 
21744
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
21745
      try {
21746
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
21747
      } catch (org.apache.thrift.TException te) {
21748
        throw new java.io.IOException(te);
21749
      }
21750
    }
21751
 
21752
  }
21753
 
21754
  public static class resetAvailabilityForWarehouse_args implements org.apache.thrift.TBase<resetAvailabilityForWarehouse_args, resetAvailabilityForWarehouse_args._Fields>, java.io.Serializable, Cloneable   {
21755
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailabilityForWarehouse_args");
21756
 
21757
    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);
21758
 
21759
    private long warehouseId; // required
21760
 
21761
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
21762
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
21763
      WAREHOUSE_ID((short)1, "warehouseId");
21764
 
21765
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
21766
 
21767
      static {
21768
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
21769
          byName.put(field.getFieldName(), field);
21770
        }
21771
      }
21772
 
21773
      /**
21774
       * Find the _Fields constant that matches fieldId, or null if its not found.
21775
       */
21776
      public static _Fields findByThriftId(int fieldId) {
21777
        switch(fieldId) {
21778
          case 1: // WAREHOUSE_ID
21779
            return WAREHOUSE_ID;
21780
          default:
21781
            return null;
21782
        }
21783
      }
21784
 
21785
      /**
21786
       * Find the _Fields constant that matches fieldId, throwing an exception
21787
       * if it is not found.
21788
       */
21789
      public static _Fields findByThriftIdOrThrow(int fieldId) {
21790
        _Fields fields = findByThriftId(fieldId);
21791
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
21792
        return fields;
21793
      }
21794
 
21795
      /**
21796
       * Find the _Fields constant that matches name, or null if its not found.
21797
       */
21798
      public static _Fields findByName(String name) {
21799
        return byName.get(name);
21800
      }
21801
 
21802
      private final short _thriftId;
21803
      private final String _fieldName;
21804
 
21805
      _Fields(short thriftId, String fieldName) {
21806
        _thriftId = thriftId;
21807
        _fieldName = fieldName;
21808
      }
21809
 
21810
      public short getThriftFieldId() {
21811
        return _thriftId;
21812
      }
21813
 
21814
      public String getFieldName() {
21815
        return _fieldName;
21816
      }
21817
    }
21818
 
21819
    // isset id assignments
21820
    private static final int __WAREHOUSEID_ISSET_ID = 0;
21821
    private BitSet __isset_bit_vector = new BitSet(1);
21822
 
21823
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
21824
    static {
21825
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
21826
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
21827
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
21828
      metaDataMap = Collections.unmodifiableMap(tmpMap);
21829
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailabilityForWarehouse_args.class, metaDataMap);
21830
    }
21831
 
21832
    public resetAvailabilityForWarehouse_args() {
21833
    }
21834
 
21835
    public resetAvailabilityForWarehouse_args(
21836
      long warehouseId)
21837
    {
21838
      this();
21839
      this.warehouseId = warehouseId;
21840
      setWarehouseIdIsSet(true);
21841
    }
21842
 
21843
    /**
21844
     * Performs a deep copy on <i>other</i>.
21845
     */
21846
    public resetAvailabilityForWarehouse_args(resetAvailabilityForWarehouse_args other) {
21847
      __isset_bit_vector.clear();
21848
      __isset_bit_vector.or(other.__isset_bit_vector);
21849
      this.warehouseId = other.warehouseId;
21850
    }
21851
 
21852
    public resetAvailabilityForWarehouse_args deepCopy() {
21853
      return new resetAvailabilityForWarehouse_args(this);
21854
    }
21855
 
21856
    @Override
21857
    public void clear() {
21858
      setWarehouseIdIsSet(false);
21859
      this.warehouseId = 0;
21860
    }
21861
 
21862
    public long getWarehouseId() {
21863
      return this.warehouseId;
21864
    }
21865
 
21866
    public void setWarehouseId(long warehouseId) {
21867
      this.warehouseId = warehouseId;
21868
      setWarehouseIdIsSet(true);
21869
    }
21870
 
21871
    public void unsetWarehouseId() {
21872
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
21873
    }
21874
 
21875
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
21876
    public boolean isSetWarehouseId() {
21877
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
21878
    }
21879
 
21880
    public void setWarehouseIdIsSet(boolean value) {
21881
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
21882
    }
21883
 
21884
    public void setFieldValue(_Fields field, Object value) {
21885
      switch (field) {
21886
      case WAREHOUSE_ID:
21887
        if (value == null) {
21888
          unsetWarehouseId();
21889
        } else {
21890
          setWarehouseId((Long)value);
21891
        }
21892
        break;
21893
 
21894
      }
21895
    }
21896
 
21897
    public Object getFieldValue(_Fields field) {
21898
      switch (field) {
21899
      case WAREHOUSE_ID:
21900
        return Long.valueOf(getWarehouseId());
21901
 
21902
      }
21903
      throw new IllegalStateException();
21904
    }
21905
 
21906
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
21907
    public boolean isSet(_Fields field) {
21908
      if (field == null) {
21909
        throw new IllegalArgumentException();
21910
      }
21911
 
21912
      switch (field) {
21913
      case WAREHOUSE_ID:
21914
        return isSetWarehouseId();
21915
      }
21916
      throw new IllegalStateException();
21917
    }
21918
 
21919
    @Override
21920
    public boolean equals(Object that) {
21921
      if (that == null)
21922
        return false;
21923
      if (that instanceof resetAvailabilityForWarehouse_args)
21924
        return this.equals((resetAvailabilityForWarehouse_args)that);
21925
      return false;
21926
    }
21927
 
21928
    public boolean equals(resetAvailabilityForWarehouse_args that) {
21929
      if (that == null)
21930
        return false;
21931
 
21932
      boolean this_present_warehouseId = true;
21933
      boolean that_present_warehouseId = true;
21934
      if (this_present_warehouseId || that_present_warehouseId) {
21935
        if (!(this_present_warehouseId && that_present_warehouseId))
21936
          return false;
21937
        if (this.warehouseId != that.warehouseId)
21938
          return false;
21939
      }
21940
 
21941
      return true;
21942
    }
21943
 
21944
    @Override
21945
    public int hashCode() {
21946
      return 0;
21947
    }
21948
 
21949
    public int compareTo(resetAvailabilityForWarehouse_args other) {
21950
      if (!getClass().equals(other.getClass())) {
21951
        return getClass().getName().compareTo(other.getClass().getName());
21952
      }
21953
 
21954
      int lastComparison = 0;
21955
      resetAvailabilityForWarehouse_args typedOther = (resetAvailabilityForWarehouse_args)other;
21956
 
21957
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
21958
      if (lastComparison != 0) {
21959
        return lastComparison;
21960
      }
21961
      if (isSetWarehouseId()) {
21962
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
21963
        if (lastComparison != 0) {
21964
          return lastComparison;
21965
        }
21966
      }
21967
      return 0;
21968
    }
21969
 
21970
    public _Fields fieldForId(int fieldId) {
21971
      return _Fields.findByThriftId(fieldId);
21972
    }
21973
 
21974
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
21975
      org.apache.thrift.protocol.TField field;
21976
      iprot.readStructBegin();
21977
      while (true)
21978
      {
21979
        field = iprot.readFieldBegin();
21980
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
21981
          break;
21982
        }
21983
        switch (field.id) {
21984
          case 1: // WAREHOUSE_ID
21985
            if (field.type == org.apache.thrift.protocol.TType.I64) {
21986
              this.warehouseId = iprot.readI64();
21987
              setWarehouseIdIsSet(true);
21988
            } else { 
21989
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21990
            }
21991
            break;
21992
          default:
21993
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
21994
        }
21995
        iprot.readFieldEnd();
21996
      }
21997
      iprot.readStructEnd();
21998
      validate();
21999
    }
22000
 
22001
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22002
      validate();
22003
 
22004
      oprot.writeStructBegin(STRUCT_DESC);
22005
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
22006
      oprot.writeI64(this.warehouseId);
22007
      oprot.writeFieldEnd();
22008
      oprot.writeFieldStop();
22009
      oprot.writeStructEnd();
22010
    }
22011
 
22012
    @Override
22013
    public String toString() {
22014
      StringBuilder sb = new StringBuilder("resetAvailabilityForWarehouse_args(");
22015
      boolean first = true;
22016
 
22017
      sb.append("warehouseId:");
22018
      sb.append(this.warehouseId);
22019
      first = false;
22020
      sb.append(")");
22021
      return sb.toString();
22022
    }
22023
 
22024
    public void validate() throws org.apache.thrift.TException {
22025
      // check for required fields
22026
    }
22027
 
22028
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22029
      try {
22030
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22031
      } catch (org.apache.thrift.TException te) {
22032
        throw new java.io.IOException(te);
22033
      }
22034
    }
22035
 
22036
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22037
      try {
22038
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
22039
        __isset_bit_vector = new BitSet(1);
22040
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22041
      } catch (org.apache.thrift.TException te) {
22042
        throw new java.io.IOException(te);
22043
      }
22044
    }
22045
 
22046
  }
22047
 
22048
  public static class resetAvailabilityForWarehouse_result implements org.apache.thrift.TBase<resetAvailabilityForWarehouse_result, resetAvailabilityForWarehouse_result._Fields>, java.io.Serializable, Cloneable   {
22049
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("resetAvailabilityForWarehouse_result");
22050
 
22051
    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);
22052
 
22053
    private InventoryServiceException cex; // required
22054
 
22055
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22056
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22057
      CEX((short)1, "cex");
22058
 
22059
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22060
 
22061
      static {
22062
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22063
          byName.put(field.getFieldName(), field);
22064
        }
22065
      }
22066
 
22067
      /**
22068
       * Find the _Fields constant that matches fieldId, or null if its not found.
22069
       */
22070
      public static _Fields findByThriftId(int fieldId) {
22071
        switch(fieldId) {
22072
          case 1: // CEX
22073
            return CEX;
22074
          default:
22075
            return null;
22076
        }
22077
      }
22078
 
22079
      /**
22080
       * Find the _Fields constant that matches fieldId, throwing an exception
22081
       * if it is not found.
22082
       */
22083
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22084
        _Fields fields = findByThriftId(fieldId);
22085
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22086
        return fields;
22087
      }
22088
 
22089
      /**
22090
       * Find the _Fields constant that matches name, or null if its not found.
22091
       */
22092
      public static _Fields findByName(String name) {
22093
        return byName.get(name);
22094
      }
22095
 
22096
      private final short _thriftId;
22097
      private final String _fieldName;
22098
 
22099
      _Fields(short thriftId, String fieldName) {
22100
        _thriftId = thriftId;
22101
        _fieldName = fieldName;
22102
      }
22103
 
22104
      public short getThriftFieldId() {
22105
        return _thriftId;
22106
      }
22107
 
22108
      public String getFieldName() {
22109
        return _fieldName;
22110
      }
22111
    }
22112
 
22113
    // isset id assignments
22114
 
22115
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22116
    static {
22117
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22118
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22119
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
22120
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22121
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(resetAvailabilityForWarehouse_result.class, metaDataMap);
22122
    }
22123
 
22124
    public resetAvailabilityForWarehouse_result() {
22125
    }
22126
 
22127
    public resetAvailabilityForWarehouse_result(
22128
      InventoryServiceException cex)
22129
    {
22130
      this();
22131
      this.cex = cex;
22132
    }
22133
 
22134
    /**
22135
     * Performs a deep copy on <i>other</i>.
22136
     */
22137
    public resetAvailabilityForWarehouse_result(resetAvailabilityForWarehouse_result other) {
22138
      if (other.isSetCex()) {
22139
        this.cex = new InventoryServiceException(other.cex);
22140
      }
22141
    }
22142
 
22143
    public resetAvailabilityForWarehouse_result deepCopy() {
22144
      return new resetAvailabilityForWarehouse_result(this);
22145
    }
22146
 
22147
    @Override
22148
    public void clear() {
22149
      this.cex = null;
22150
    }
22151
 
22152
    public InventoryServiceException getCex() {
22153
      return this.cex;
22154
    }
22155
 
22156
    public void setCex(InventoryServiceException cex) {
22157
      this.cex = cex;
22158
    }
22159
 
22160
    public void unsetCex() {
22161
      this.cex = null;
22162
    }
22163
 
22164
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
22165
    public boolean isSetCex() {
22166
      return this.cex != null;
22167
    }
22168
 
22169
    public void setCexIsSet(boolean value) {
22170
      if (!value) {
22171
        this.cex = null;
22172
      }
22173
    }
22174
 
22175
    public void setFieldValue(_Fields field, Object value) {
22176
      switch (field) {
22177
      case CEX:
22178
        if (value == null) {
22179
          unsetCex();
22180
        } else {
22181
          setCex((InventoryServiceException)value);
22182
        }
22183
        break;
22184
 
22185
      }
22186
    }
22187
 
22188
    public Object getFieldValue(_Fields field) {
22189
      switch (field) {
22190
      case CEX:
22191
        return getCex();
22192
 
22193
      }
22194
      throw new IllegalStateException();
22195
    }
22196
 
22197
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22198
    public boolean isSet(_Fields field) {
22199
      if (field == null) {
22200
        throw new IllegalArgumentException();
22201
      }
22202
 
22203
      switch (field) {
22204
      case CEX:
22205
        return isSetCex();
22206
      }
22207
      throw new IllegalStateException();
22208
    }
22209
 
22210
    @Override
22211
    public boolean equals(Object that) {
22212
      if (that == null)
22213
        return false;
22214
      if (that instanceof resetAvailabilityForWarehouse_result)
22215
        return this.equals((resetAvailabilityForWarehouse_result)that);
22216
      return false;
22217
    }
22218
 
22219
    public boolean equals(resetAvailabilityForWarehouse_result that) {
22220
      if (that == null)
22221
        return false;
22222
 
22223
      boolean this_present_cex = true && this.isSetCex();
22224
      boolean that_present_cex = true && that.isSetCex();
22225
      if (this_present_cex || that_present_cex) {
22226
        if (!(this_present_cex && that_present_cex))
22227
          return false;
22228
        if (!this.cex.equals(that.cex))
22229
          return false;
22230
      }
22231
 
22232
      return true;
22233
    }
22234
 
22235
    @Override
22236
    public int hashCode() {
22237
      return 0;
22238
    }
22239
 
22240
    public int compareTo(resetAvailabilityForWarehouse_result other) {
22241
      if (!getClass().equals(other.getClass())) {
22242
        return getClass().getName().compareTo(other.getClass().getName());
22243
      }
22244
 
22245
      int lastComparison = 0;
22246
      resetAvailabilityForWarehouse_result typedOther = (resetAvailabilityForWarehouse_result)other;
22247
 
22248
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
22249
      if (lastComparison != 0) {
22250
        return lastComparison;
22251
      }
22252
      if (isSetCex()) {
22253
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
22254
        if (lastComparison != 0) {
22255
          return lastComparison;
22256
        }
22257
      }
22258
      return 0;
22259
    }
22260
 
22261
    public _Fields fieldForId(int fieldId) {
22262
      return _Fields.findByThriftId(fieldId);
22263
    }
22264
 
22265
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22266
      org.apache.thrift.protocol.TField field;
22267
      iprot.readStructBegin();
22268
      while (true)
22269
      {
22270
        field = iprot.readFieldBegin();
22271
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22272
          break;
22273
        }
22274
        switch (field.id) {
22275
          case 1: // CEX
22276
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
22277
              this.cex = new InventoryServiceException();
22278
              this.cex.read(iprot);
22279
            } else { 
22280
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22281
            }
22282
            break;
22283
          default:
22284
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22285
        }
22286
        iprot.readFieldEnd();
22287
      }
22288
      iprot.readStructEnd();
22289
      validate();
22290
    }
22291
 
22292
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22293
      oprot.writeStructBegin(STRUCT_DESC);
22294
 
22295
      if (this.isSetCex()) {
22296
        oprot.writeFieldBegin(CEX_FIELD_DESC);
22297
        this.cex.write(oprot);
22298
        oprot.writeFieldEnd();
22299
      }
22300
      oprot.writeFieldStop();
22301
      oprot.writeStructEnd();
22302
    }
22303
 
22304
    @Override
22305
    public String toString() {
22306
      StringBuilder sb = new StringBuilder("resetAvailabilityForWarehouse_result(");
22307
      boolean first = true;
22308
 
22309
      sb.append("cex:");
22310
      if (this.cex == null) {
22311
        sb.append("null");
22312
      } else {
22313
        sb.append(this.cex);
22314
      }
22315
      first = false;
22316
      sb.append(")");
22317
      return sb.toString();
22318
    }
22319
 
22320
    public void validate() throws org.apache.thrift.TException {
22321
      // check for required fields
22322
    }
22323
 
22324
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22325
      try {
22326
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22327
      } catch (org.apache.thrift.TException te) {
22328
        throw new java.io.IOException(te);
22329
      }
22330
    }
22331
 
22332
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22333
      try {
22334
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22335
      } catch (org.apache.thrift.TException te) {
22336
        throw new java.io.IOException(te);
22337
      }
22338
    }
22339
 
22340
  }
22341
 
22342
  public static class getItemKeysToBeProcessed_args implements org.apache.thrift.TBase<getItemKeysToBeProcessed_args, getItemKeysToBeProcessed_args._Fields>, java.io.Serializable, Cloneable   {
22343
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemKeysToBeProcessed_args");
22344
 
22345
    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);
22346
 
22347
    private long warehouseId; // required
22348
 
22349
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22350
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22351
      WAREHOUSE_ID((short)1, "warehouseId");
22352
 
22353
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22354
 
22355
      static {
22356
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22357
          byName.put(field.getFieldName(), field);
22358
        }
22359
      }
22360
 
22361
      /**
22362
       * Find the _Fields constant that matches fieldId, or null if its not found.
22363
       */
22364
      public static _Fields findByThriftId(int fieldId) {
22365
        switch(fieldId) {
22366
          case 1: // WAREHOUSE_ID
22367
            return WAREHOUSE_ID;
22368
          default:
22369
            return null;
22370
        }
22371
      }
22372
 
22373
      /**
22374
       * Find the _Fields constant that matches fieldId, throwing an exception
22375
       * if it is not found.
22376
       */
22377
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22378
        _Fields fields = findByThriftId(fieldId);
22379
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22380
        return fields;
22381
      }
22382
 
22383
      /**
22384
       * Find the _Fields constant that matches name, or null if its not found.
22385
       */
22386
      public static _Fields findByName(String name) {
22387
        return byName.get(name);
22388
      }
22389
 
22390
      private final short _thriftId;
22391
      private final String _fieldName;
22392
 
22393
      _Fields(short thriftId, String fieldName) {
22394
        _thriftId = thriftId;
22395
        _fieldName = fieldName;
22396
      }
22397
 
22398
      public short getThriftFieldId() {
22399
        return _thriftId;
22400
      }
22401
 
22402
      public String getFieldName() {
22403
        return _fieldName;
22404
      }
22405
    }
22406
 
22407
    // isset id assignments
22408
    private static final int __WAREHOUSEID_ISSET_ID = 0;
22409
    private BitSet __isset_bit_vector = new BitSet(1);
22410
 
22411
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22412
    static {
22413
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22414
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22415
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
22416
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22417
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemKeysToBeProcessed_args.class, metaDataMap);
22418
    }
22419
 
22420
    public getItemKeysToBeProcessed_args() {
22421
    }
22422
 
22423
    public getItemKeysToBeProcessed_args(
22424
      long warehouseId)
22425
    {
22426
      this();
22427
      this.warehouseId = warehouseId;
22428
      setWarehouseIdIsSet(true);
22429
    }
22430
 
22431
    /**
22432
     * Performs a deep copy on <i>other</i>.
22433
     */
22434
    public getItemKeysToBeProcessed_args(getItemKeysToBeProcessed_args other) {
22435
      __isset_bit_vector.clear();
22436
      __isset_bit_vector.or(other.__isset_bit_vector);
22437
      this.warehouseId = other.warehouseId;
22438
    }
22439
 
22440
    public getItemKeysToBeProcessed_args deepCopy() {
22441
      return new getItemKeysToBeProcessed_args(this);
22442
    }
22443
 
22444
    @Override
22445
    public void clear() {
22446
      setWarehouseIdIsSet(false);
22447
      this.warehouseId = 0;
22448
    }
22449
 
22450
    public long getWarehouseId() {
22451
      return this.warehouseId;
22452
    }
22453
 
22454
    public void setWarehouseId(long warehouseId) {
22455
      this.warehouseId = warehouseId;
22456
      setWarehouseIdIsSet(true);
22457
    }
22458
 
22459
    public void unsetWarehouseId() {
22460
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
22461
    }
22462
 
22463
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
22464
    public boolean isSetWarehouseId() {
22465
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
22466
    }
22467
 
22468
    public void setWarehouseIdIsSet(boolean value) {
22469
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
22470
    }
22471
 
22472
    public void setFieldValue(_Fields field, Object value) {
22473
      switch (field) {
22474
      case WAREHOUSE_ID:
22475
        if (value == null) {
22476
          unsetWarehouseId();
22477
        } else {
22478
          setWarehouseId((Long)value);
22479
        }
22480
        break;
22481
 
22482
      }
22483
    }
22484
 
22485
    public Object getFieldValue(_Fields field) {
22486
      switch (field) {
22487
      case WAREHOUSE_ID:
22488
        return Long.valueOf(getWarehouseId());
22489
 
22490
      }
22491
      throw new IllegalStateException();
22492
    }
22493
 
22494
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22495
    public boolean isSet(_Fields field) {
22496
      if (field == null) {
22497
        throw new IllegalArgumentException();
22498
      }
22499
 
22500
      switch (field) {
22501
      case WAREHOUSE_ID:
22502
        return isSetWarehouseId();
22503
      }
22504
      throw new IllegalStateException();
22505
    }
22506
 
22507
    @Override
22508
    public boolean equals(Object that) {
22509
      if (that == null)
22510
        return false;
22511
      if (that instanceof getItemKeysToBeProcessed_args)
22512
        return this.equals((getItemKeysToBeProcessed_args)that);
22513
      return false;
22514
    }
22515
 
22516
    public boolean equals(getItemKeysToBeProcessed_args that) {
22517
      if (that == null)
22518
        return false;
22519
 
22520
      boolean this_present_warehouseId = true;
22521
      boolean that_present_warehouseId = true;
22522
      if (this_present_warehouseId || that_present_warehouseId) {
22523
        if (!(this_present_warehouseId && that_present_warehouseId))
22524
          return false;
22525
        if (this.warehouseId != that.warehouseId)
22526
          return false;
22527
      }
22528
 
22529
      return true;
22530
    }
22531
 
22532
    @Override
22533
    public int hashCode() {
22534
      return 0;
22535
    }
22536
 
22537
    public int compareTo(getItemKeysToBeProcessed_args other) {
22538
      if (!getClass().equals(other.getClass())) {
22539
        return getClass().getName().compareTo(other.getClass().getName());
22540
      }
22541
 
22542
      int lastComparison = 0;
22543
      getItemKeysToBeProcessed_args typedOther = (getItemKeysToBeProcessed_args)other;
22544
 
22545
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
22546
      if (lastComparison != 0) {
22547
        return lastComparison;
22548
      }
22549
      if (isSetWarehouseId()) {
22550
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
22551
        if (lastComparison != 0) {
22552
          return lastComparison;
22553
        }
22554
      }
22555
      return 0;
22556
    }
22557
 
22558
    public _Fields fieldForId(int fieldId) {
22559
      return _Fields.findByThriftId(fieldId);
22560
    }
22561
 
22562
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22563
      org.apache.thrift.protocol.TField field;
22564
      iprot.readStructBegin();
22565
      while (true)
22566
      {
22567
        field = iprot.readFieldBegin();
22568
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22569
          break;
22570
        }
22571
        switch (field.id) {
22572
          case 1: // WAREHOUSE_ID
22573
            if (field.type == org.apache.thrift.protocol.TType.I64) {
22574
              this.warehouseId = iprot.readI64();
22575
              setWarehouseIdIsSet(true);
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
      validate();
22591
 
22592
      oprot.writeStructBegin(STRUCT_DESC);
22593
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
22594
      oprot.writeI64(this.warehouseId);
22595
      oprot.writeFieldEnd();
22596
      oprot.writeFieldStop();
22597
      oprot.writeStructEnd();
22598
    }
22599
 
22600
    @Override
22601
    public String toString() {
22602
      StringBuilder sb = new StringBuilder("getItemKeysToBeProcessed_args(");
22603
      boolean first = true;
22604
 
22605
      sb.append("warehouseId:");
22606
      sb.append(this.warehouseId);
22607
      first = false;
22608
      sb.append(")");
22609
      return sb.toString();
22610
    }
22611
 
22612
    public void validate() throws org.apache.thrift.TException {
22613
      // check for required fields
22614
    }
22615
 
22616
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22617
      try {
22618
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22619
      } catch (org.apache.thrift.TException te) {
22620
        throw new java.io.IOException(te);
22621
      }
22622
    }
22623
 
22624
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22625
      try {
22626
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22627
      } catch (org.apache.thrift.TException te) {
22628
        throw new java.io.IOException(te);
22629
      }
22630
    }
22631
 
22632
  }
22633
 
22634
  public static class getItemKeysToBeProcessed_result implements org.apache.thrift.TBase<getItemKeysToBeProcessed_result, getItemKeysToBeProcessed_result._Fields>, java.io.Serializable, Cloneable   {
22635
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getItemKeysToBeProcessed_result");
22636
 
22637
    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);
22638
 
22639
    private List<String> success; // required
22640
 
22641
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22642
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22643
      SUCCESS((short)0, "success");
22644
 
22645
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22646
 
22647
      static {
22648
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22649
          byName.put(field.getFieldName(), field);
22650
        }
22651
      }
22652
 
22653
      /**
22654
       * Find the _Fields constant that matches fieldId, or null if its not found.
22655
       */
22656
      public static _Fields findByThriftId(int fieldId) {
22657
        switch(fieldId) {
22658
          case 0: // SUCCESS
22659
            return SUCCESS;
22660
          default:
22661
            return null;
22662
        }
22663
      }
22664
 
22665
      /**
22666
       * Find the _Fields constant that matches fieldId, throwing an exception
22667
       * if it is not found.
22668
       */
22669
      public static _Fields findByThriftIdOrThrow(int fieldId) {
22670
        _Fields fields = findByThriftId(fieldId);
22671
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
22672
        return fields;
22673
      }
22674
 
22675
      /**
22676
       * Find the _Fields constant that matches name, or null if its not found.
22677
       */
22678
      public static _Fields findByName(String name) {
22679
        return byName.get(name);
22680
      }
22681
 
22682
      private final short _thriftId;
22683
      private final String _fieldName;
22684
 
22685
      _Fields(short thriftId, String fieldName) {
22686
        _thriftId = thriftId;
22687
        _fieldName = fieldName;
22688
      }
22689
 
22690
      public short getThriftFieldId() {
22691
        return _thriftId;
22692
      }
22693
 
22694
      public String getFieldName() {
22695
        return _fieldName;
22696
      }
22697
    }
22698
 
22699
    // isset id assignments
22700
 
22701
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
22702
    static {
22703
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
22704
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
22705
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
22706
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING))));
22707
      metaDataMap = Collections.unmodifiableMap(tmpMap);
22708
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getItemKeysToBeProcessed_result.class, metaDataMap);
22709
    }
22710
 
22711
    public getItemKeysToBeProcessed_result() {
22712
    }
22713
 
22714
    public getItemKeysToBeProcessed_result(
22715
      List<String> success)
22716
    {
22717
      this();
22718
      this.success = success;
22719
    }
22720
 
22721
    /**
22722
     * Performs a deep copy on <i>other</i>.
22723
     */
22724
    public getItemKeysToBeProcessed_result(getItemKeysToBeProcessed_result other) {
22725
      if (other.isSetSuccess()) {
22726
        List<String> __this__success = new ArrayList<String>();
22727
        for (String other_element : other.success) {
22728
          __this__success.add(other_element);
22729
        }
22730
        this.success = __this__success;
22731
      }
22732
    }
22733
 
22734
    public getItemKeysToBeProcessed_result deepCopy() {
22735
      return new getItemKeysToBeProcessed_result(this);
22736
    }
22737
 
22738
    @Override
22739
    public void clear() {
22740
      this.success = null;
22741
    }
22742
 
22743
    public int getSuccessSize() {
22744
      return (this.success == null) ? 0 : this.success.size();
22745
    }
22746
 
22747
    public java.util.Iterator<String> getSuccessIterator() {
22748
      return (this.success == null) ? null : this.success.iterator();
22749
    }
22750
 
22751
    public void addToSuccess(String elem) {
22752
      if (this.success == null) {
22753
        this.success = new ArrayList<String>();
22754
      }
22755
      this.success.add(elem);
22756
    }
22757
 
22758
    public List<String> getSuccess() {
22759
      return this.success;
22760
    }
22761
 
22762
    public void setSuccess(List<String> success) {
22763
      this.success = success;
22764
    }
22765
 
22766
    public void unsetSuccess() {
22767
      this.success = null;
22768
    }
22769
 
22770
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
22771
    public boolean isSetSuccess() {
22772
      return this.success != null;
22773
    }
22774
 
22775
    public void setSuccessIsSet(boolean value) {
22776
      if (!value) {
22777
        this.success = null;
22778
      }
22779
    }
22780
 
22781
    public void setFieldValue(_Fields field, Object value) {
22782
      switch (field) {
22783
      case SUCCESS:
22784
        if (value == null) {
22785
          unsetSuccess();
22786
        } else {
22787
          setSuccess((List<String>)value);
22788
        }
22789
        break;
22790
 
22791
      }
22792
    }
22793
 
22794
    public Object getFieldValue(_Fields field) {
22795
      switch (field) {
22796
      case SUCCESS:
22797
        return getSuccess();
22798
 
22799
      }
22800
      throw new IllegalStateException();
22801
    }
22802
 
22803
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
22804
    public boolean isSet(_Fields field) {
22805
      if (field == null) {
22806
        throw new IllegalArgumentException();
22807
      }
22808
 
22809
      switch (field) {
22810
      case SUCCESS:
22811
        return isSetSuccess();
22812
      }
22813
      throw new IllegalStateException();
22814
    }
22815
 
22816
    @Override
22817
    public boolean equals(Object that) {
22818
      if (that == null)
22819
        return false;
22820
      if (that instanceof getItemKeysToBeProcessed_result)
22821
        return this.equals((getItemKeysToBeProcessed_result)that);
22822
      return false;
22823
    }
22824
 
22825
    public boolean equals(getItemKeysToBeProcessed_result that) {
22826
      if (that == null)
22827
        return false;
22828
 
22829
      boolean this_present_success = true && this.isSetSuccess();
22830
      boolean that_present_success = true && that.isSetSuccess();
22831
      if (this_present_success || that_present_success) {
22832
        if (!(this_present_success && that_present_success))
22833
          return false;
22834
        if (!this.success.equals(that.success))
22835
          return false;
22836
      }
22837
 
22838
      return true;
22839
    }
22840
 
22841
    @Override
22842
    public int hashCode() {
22843
      return 0;
22844
    }
22845
 
22846
    public int compareTo(getItemKeysToBeProcessed_result other) {
22847
      if (!getClass().equals(other.getClass())) {
22848
        return getClass().getName().compareTo(other.getClass().getName());
22849
      }
22850
 
22851
      int lastComparison = 0;
22852
      getItemKeysToBeProcessed_result typedOther = (getItemKeysToBeProcessed_result)other;
22853
 
22854
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
22855
      if (lastComparison != 0) {
22856
        return lastComparison;
22857
      }
22858
      if (isSetSuccess()) {
22859
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
22860
        if (lastComparison != 0) {
22861
          return lastComparison;
22862
        }
22863
      }
22864
      return 0;
22865
    }
22866
 
22867
    public _Fields fieldForId(int fieldId) {
22868
      return _Fields.findByThriftId(fieldId);
22869
    }
22870
 
22871
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
22872
      org.apache.thrift.protocol.TField field;
22873
      iprot.readStructBegin();
22874
      while (true)
22875
      {
22876
        field = iprot.readFieldBegin();
22877
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
22878
          break;
22879
        }
22880
        switch (field.id) {
22881
          case 0: // SUCCESS
22882
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
22883
              {
22884
                org.apache.thrift.protocol.TList _list52 = iprot.readListBegin();
22885
                this.success = new ArrayList<String>(_list52.size);
22886
                for (int _i53 = 0; _i53 < _list52.size; ++_i53)
22887
                {
22888
                  String _elem54; // required
22889
                  _elem54 = iprot.readString();
22890
                  this.success.add(_elem54);
22891
                }
22892
                iprot.readListEnd();
22893
              }
22894
            } else { 
22895
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22896
            }
22897
            break;
22898
          default:
22899
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
22900
        }
22901
        iprot.readFieldEnd();
22902
      }
22903
      iprot.readStructEnd();
22904
      validate();
22905
    }
22906
 
22907
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
22908
      oprot.writeStructBegin(STRUCT_DESC);
22909
 
22910
      if (this.isSetSuccess()) {
22911
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
22912
        {
22913
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRING, this.success.size()));
22914
          for (String _iter55 : this.success)
22915
          {
22916
            oprot.writeString(_iter55);
22917
          }
22918
          oprot.writeListEnd();
22919
        }
22920
        oprot.writeFieldEnd();
22921
      }
22922
      oprot.writeFieldStop();
22923
      oprot.writeStructEnd();
22924
    }
22925
 
22926
    @Override
22927
    public String toString() {
22928
      StringBuilder sb = new StringBuilder("getItemKeysToBeProcessed_result(");
22929
      boolean first = true;
22930
 
22931
      sb.append("success:");
22932
      if (this.success == null) {
22933
        sb.append("null");
22934
      } else {
22935
        sb.append(this.success);
22936
      }
22937
      first = false;
22938
      sb.append(")");
22939
      return sb.toString();
22940
    }
22941
 
22942
    public void validate() throws org.apache.thrift.TException {
22943
      // check for required fields
22944
    }
22945
 
22946
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
22947
      try {
22948
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
22949
      } catch (org.apache.thrift.TException te) {
22950
        throw new java.io.IOException(te);
22951
      }
22952
    }
22953
 
22954
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
22955
      try {
22956
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
22957
      } catch (org.apache.thrift.TException te) {
22958
        throw new java.io.IOException(te);
22959
      }
22960
    }
22961
 
22962
  }
22963
 
22964
  public static class markMissedInventoryUpdatesAsProcessed_args implements org.apache.thrift.TBase<markMissedInventoryUpdatesAsProcessed_args, markMissedInventoryUpdatesAsProcessed_args._Fields>, java.io.Serializable, Cloneable   {
22965
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markMissedInventoryUpdatesAsProcessed_args");
22966
 
22967
    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);
22968
    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);
22969
 
22970
    private String itemKey; // required
22971
    private long warehouseId; // required
22972
 
22973
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
22974
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
22975
      ITEM_KEY((short)1, "itemKey"),
22976
      WAREHOUSE_ID((short)2, "warehouseId");
22977
 
22978
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
22979
 
22980
      static {
22981
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
22982
          byName.put(field.getFieldName(), field);
22983
        }
22984
      }
22985
 
22986
      /**
22987
       * Find the _Fields constant that matches fieldId, or null if its not found.
22988
       */
22989
      public static _Fields findByThriftId(int fieldId) {
22990
        switch(fieldId) {
22991
          case 1: // ITEM_KEY
22992
            return ITEM_KEY;
22993
          case 2: // WAREHOUSE_ID
22994
            return WAREHOUSE_ID;
22995
          default:
22996
            return null;
22997
        }
22998
      }
22999
 
23000
      /**
23001
       * Find the _Fields constant that matches fieldId, throwing an exception
23002
       * if it is not found.
23003
       */
23004
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23005
        _Fields fields = findByThriftId(fieldId);
23006
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23007
        return fields;
23008
      }
23009
 
23010
      /**
23011
       * Find the _Fields constant that matches name, or null if its not found.
23012
       */
23013
      public static _Fields findByName(String name) {
23014
        return byName.get(name);
23015
      }
23016
 
23017
      private final short _thriftId;
23018
      private final String _fieldName;
23019
 
23020
      _Fields(short thriftId, String fieldName) {
23021
        _thriftId = thriftId;
23022
        _fieldName = fieldName;
23023
      }
23024
 
23025
      public short getThriftFieldId() {
23026
        return _thriftId;
23027
      }
23028
 
23029
      public String getFieldName() {
23030
        return _fieldName;
23031
      }
23032
    }
23033
 
23034
    // isset id assignments
23035
    private static final int __WAREHOUSEID_ISSET_ID = 0;
23036
    private BitSet __isset_bit_vector = new BitSet(1);
23037
 
23038
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23039
    static {
23040
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23041
      tmpMap.put(_Fields.ITEM_KEY, new org.apache.thrift.meta_data.FieldMetaData("itemKey", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23042
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
23043
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23044
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
23045
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23046
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markMissedInventoryUpdatesAsProcessed_args.class, metaDataMap);
23047
    }
23048
 
23049
    public markMissedInventoryUpdatesAsProcessed_args() {
23050
    }
23051
 
23052
    public markMissedInventoryUpdatesAsProcessed_args(
23053
      String itemKey,
23054
      long warehouseId)
23055
    {
23056
      this();
23057
      this.itemKey = itemKey;
23058
      this.warehouseId = warehouseId;
23059
      setWarehouseIdIsSet(true);
23060
    }
23061
 
23062
    /**
23063
     * Performs a deep copy on <i>other</i>.
23064
     */
23065
    public markMissedInventoryUpdatesAsProcessed_args(markMissedInventoryUpdatesAsProcessed_args other) {
23066
      __isset_bit_vector.clear();
23067
      __isset_bit_vector.or(other.__isset_bit_vector);
23068
      if (other.isSetItemKey()) {
23069
        this.itemKey = other.itemKey;
23070
      }
23071
      this.warehouseId = other.warehouseId;
23072
    }
23073
 
23074
    public markMissedInventoryUpdatesAsProcessed_args deepCopy() {
23075
      return new markMissedInventoryUpdatesAsProcessed_args(this);
23076
    }
23077
 
23078
    @Override
23079
    public void clear() {
23080
      this.itemKey = null;
23081
      setWarehouseIdIsSet(false);
23082
      this.warehouseId = 0;
23083
    }
23084
 
23085
    public String getItemKey() {
23086
      return this.itemKey;
23087
    }
23088
 
23089
    public void setItemKey(String itemKey) {
23090
      this.itemKey = itemKey;
23091
    }
23092
 
23093
    public void unsetItemKey() {
23094
      this.itemKey = null;
23095
    }
23096
 
23097
    /** Returns true if field itemKey is set (has been assigned a value) and false otherwise */
23098
    public boolean isSetItemKey() {
23099
      return this.itemKey != null;
23100
    }
23101
 
23102
    public void setItemKeyIsSet(boolean value) {
23103
      if (!value) {
23104
        this.itemKey = null;
23105
      }
23106
    }
23107
 
23108
    public long getWarehouseId() {
23109
      return this.warehouseId;
23110
    }
23111
 
23112
    public void setWarehouseId(long warehouseId) {
23113
      this.warehouseId = warehouseId;
23114
      setWarehouseIdIsSet(true);
23115
    }
23116
 
23117
    public void unsetWarehouseId() {
23118
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
23119
    }
23120
 
23121
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
23122
    public boolean isSetWarehouseId() {
23123
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
23124
    }
23125
 
23126
    public void setWarehouseIdIsSet(boolean value) {
23127
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
23128
    }
23129
 
23130
    public void setFieldValue(_Fields field, Object value) {
23131
      switch (field) {
23132
      case ITEM_KEY:
23133
        if (value == null) {
23134
          unsetItemKey();
23135
        } else {
23136
          setItemKey((String)value);
23137
        }
23138
        break;
23139
 
23140
      case WAREHOUSE_ID:
23141
        if (value == null) {
23142
          unsetWarehouseId();
23143
        } else {
23144
          setWarehouseId((Long)value);
23145
        }
23146
        break;
23147
 
23148
      }
23149
    }
23150
 
23151
    public Object getFieldValue(_Fields field) {
23152
      switch (field) {
23153
      case ITEM_KEY:
23154
        return getItemKey();
23155
 
23156
      case WAREHOUSE_ID:
23157
        return Long.valueOf(getWarehouseId());
23158
 
23159
      }
23160
      throw new IllegalStateException();
23161
    }
23162
 
23163
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23164
    public boolean isSet(_Fields field) {
23165
      if (field == null) {
23166
        throw new IllegalArgumentException();
23167
      }
23168
 
23169
      switch (field) {
23170
      case ITEM_KEY:
23171
        return isSetItemKey();
23172
      case WAREHOUSE_ID:
23173
        return isSetWarehouseId();
23174
      }
23175
      throw new IllegalStateException();
23176
    }
23177
 
23178
    @Override
23179
    public boolean equals(Object that) {
23180
      if (that == null)
23181
        return false;
23182
      if (that instanceof markMissedInventoryUpdatesAsProcessed_args)
23183
        return this.equals((markMissedInventoryUpdatesAsProcessed_args)that);
23184
      return false;
23185
    }
23186
 
23187
    public boolean equals(markMissedInventoryUpdatesAsProcessed_args that) {
23188
      if (that == null)
23189
        return false;
23190
 
23191
      boolean this_present_itemKey = true && this.isSetItemKey();
23192
      boolean that_present_itemKey = true && that.isSetItemKey();
23193
      if (this_present_itemKey || that_present_itemKey) {
23194
        if (!(this_present_itemKey && that_present_itemKey))
23195
          return false;
23196
        if (!this.itemKey.equals(that.itemKey))
23197
          return false;
23198
      }
23199
 
23200
      boolean this_present_warehouseId = true;
23201
      boolean that_present_warehouseId = true;
23202
      if (this_present_warehouseId || that_present_warehouseId) {
23203
        if (!(this_present_warehouseId && that_present_warehouseId))
23204
          return false;
23205
        if (this.warehouseId != that.warehouseId)
23206
          return false;
23207
      }
23208
 
23209
      return true;
23210
    }
23211
 
23212
    @Override
23213
    public int hashCode() {
23214
      return 0;
23215
    }
23216
 
23217
    public int compareTo(markMissedInventoryUpdatesAsProcessed_args other) {
23218
      if (!getClass().equals(other.getClass())) {
23219
        return getClass().getName().compareTo(other.getClass().getName());
23220
      }
23221
 
23222
      int lastComparison = 0;
23223
      markMissedInventoryUpdatesAsProcessed_args typedOther = (markMissedInventoryUpdatesAsProcessed_args)other;
23224
 
23225
      lastComparison = Boolean.valueOf(isSetItemKey()).compareTo(typedOther.isSetItemKey());
23226
      if (lastComparison != 0) {
23227
        return lastComparison;
23228
      }
23229
      if (isSetItemKey()) {
23230
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemKey, typedOther.itemKey);
23231
        if (lastComparison != 0) {
23232
          return lastComparison;
23233
        }
23234
      }
23235
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
23236
      if (lastComparison != 0) {
23237
        return lastComparison;
23238
      }
23239
      if (isSetWarehouseId()) {
23240
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
23241
        if (lastComparison != 0) {
23242
          return lastComparison;
23243
        }
23244
      }
23245
      return 0;
23246
    }
23247
 
23248
    public _Fields fieldForId(int fieldId) {
23249
      return _Fields.findByThriftId(fieldId);
23250
    }
23251
 
23252
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23253
      org.apache.thrift.protocol.TField field;
23254
      iprot.readStructBegin();
23255
      while (true)
23256
      {
23257
        field = iprot.readFieldBegin();
23258
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23259
          break;
23260
        }
23261
        switch (field.id) {
23262
          case 1: // ITEM_KEY
23263
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
23264
              this.itemKey = iprot.readString();
23265
            } else { 
23266
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23267
            }
23268
            break;
23269
          case 2: // WAREHOUSE_ID
23270
            if (field.type == org.apache.thrift.protocol.TType.I64) {
23271
              this.warehouseId = iprot.readI64();
23272
              setWarehouseIdIsSet(true);
23273
            } else { 
23274
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23275
            }
23276
            break;
23277
          default:
23278
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23279
        }
23280
        iprot.readFieldEnd();
23281
      }
23282
      iprot.readStructEnd();
23283
      validate();
23284
    }
23285
 
23286
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23287
      validate();
23288
 
23289
      oprot.writeStructBegin(STRUCT_DESC);
23290
      if (this.itemKey != null) {
23291
        oprot.writeFieldBegin(ITEM_KEY_FIELD_DESC);
23292
        oprot.writeString(this.itemKey);
23293
        oprot.writeFieldEnd();
23294
      }
23295
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
23296
      oprot.writeI64(this.warehouseId);
23297
      oprot.writeFieldEnd();
23298
      oprot.writeFieldStop();
23299
      oprot.writeStructEnd();
23300
    }
23301
 
23302
    @Override
23303
    public String toString() {
23304
      StringBuilder sb = new StringBuilder("markMissedInventoryUpdatesAsProcessed_args(");
23305
      boolean first = true;
23306
 
23307
      sb.append("itemKey:");
23308
      if (this.itemKey == null) {
23309
        sb.append("null");
23310
      } else {
23311
        sb.append(this.itemKey);
23312
      }
23313
      first = false;
23314
      if (!first) sb.append(", ");
23315
      sb.append("warehouseId:");
23316
      sb.append(this.warehouseId);
23317
      first = false;
23318
      sb.append(")");
23319
      return sb.toString();
23320
    }
23321
 
23322
    public void validate() throws org.apache.thrift.TException {
23323
      // check for required fields
23324
    }
23325
 
23326
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23327
      try {
23328
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23329
      } catch (org.apache.thrift.TException te) {
23330
        throw new java.io.IOException(te);
23331
      }
23332
    }
23333
 
23334
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23335
      try {
23336
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23337
      } catch (org.apache.thrift.TException te) {
23338
        throw new java.io.IOException(te);
23339
      }
23340
    }
23341
 
23342
  }
23343
 
23344
  public static class markMissedInventoryUpdatesAsProcessed_result implements org.apache.thrift.TBase<markMissedInventoryUpdatesAsProcessed_result, markMissedInventoryUpdatesAsProcessed_result._Fields>, java.io.Serializable, Cloneable   {
23345
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("markMissedInventoryUpdatesAsProcessed_result");
23346
 
23347
 
23348
 
23349
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23350
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23351
;
23352
 
23353
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23354
 
23355
      static {
23356
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23357
          byName.put(field.getFieldName(), field);
23358
        }
23359
      }
23360
 
23361
      /**
23362
       * Find the _Fields constant that matches fieldId, or null if its not found.
23363
       */
23364
      public static _Fields findByThriftId(int fieldId) {
23365
        switch(fieldId) {
23366
          default:
23367
            return null;
23368
        }
23369
      }
23370
 
23371
      /**
23372
       * Find the _Fields constant that matches fieldId, throwing an exception
23373
       * if it is not found.
23374
       */
23375
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23376
        _Fields fields = findByThriftId(fieldId);
23377
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23378
        return fields;
23379
      }
23380
 
23381
      /**
23382
       * Find the _Fields constant that matches name, or null if its not found.
23383
       */
23384
      public static _Fields findByName(String name) {
23385
        return byName.get(name);
23386
      }
23387
 
23388
      private final short _thriftId;
23389
      private final String _fieldName;
23390
 
23391
      _Fields(short thriftId, String fieldName) {
23392
        _thriftId = thriftId;
23393
        _fieldName = fieldName;
23394
      }
23395
 
23396
      public short getThriftFieldId() {
23397
        return _thriftId;
23398
      }
23399
 
23400
      public String getFieldName() {
23401
        return _fieldName;
23402
      }
23403
    }
23404
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23405
    static {
23406
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23407
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23408
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(markMissedInventoryUpdatesAsProcessed_result.class, metaDataMap);
23409
    }
23410
 
23411
    public markMissedInventoryUpdatesAsProcessed_result() {
23412
    }
23413
 
23414
    /**
23415
     * Performs a deep copy on <i>other</i>.
23416
     */
23417
    public markMissedInventoryUpdatesAsProcessed_result(markMissedInventoryUpdatesAsProcessed_result other) {
23418
    }
23419
 
23420
    public markMissedInventoryUpdatesAsProcessed_result deepCopy() {
23421
      return new markMissedInventoryUpdatesAsProcessed_result(this);
23422
    }
23423
 
23424
    @Override
23425
    public void clear() {
23426
    }
23427
 
23428
    public void setFieldValue(_Fields field, Object value) {
23429
      switch (field) {
23430
      }
23431
    }
23432
 
23433
    public Object getFieldValue(_Fields field) {
23434
      switch (field) {
23435
      }
23436
      throw new IllegalStateException();
23437
    }
23438
 
23439
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23440
    public boolean isSet(_Fields field) {
23441
      if (field == null) {
23442
        throw new IllegalArgumentException();
23443
      }
23444
 
23445
      switch (field) {
23446
      }
23447
      throw new IllegalStateException();
23448
    }
23449
 
23450
    @Override
23451
    public boolean equals(Object that) {
23452
      if (that == null)
23453
        return false;
23454
      if (that instanceof markMissedInventoryUpdatesAsProcessed_result)
23455
        return this.equals((markMissedInventoryUpdatesAsProcessed_result)that);
23456
      return false;
23457
    }
23458
 
23459
    public boolean equals(markMissedInventoryUpdatesAsProcessed_result that) {
23460
      if (that == null)
23461
        return false;
23462
 
23463
      return true;
23464
    }
23465
 
23466
    @Override
23467
    public int hashCode() {
23468
      return 0;
23469
    }
23470
 
23471
    public int compareTo(markMissedInventoryUpdatesAsProcessed_result other) {
23472
      if (!getClass().equals(other.getClass())) {
23473
        return getClass().getName().compareTo(other.getClass().getName());
23474
      }
23475
 
23476
      int lastComparison = 0;
23477
      markMissedInventoryUpdatesAsProcessed_result typedOther = (markMissedInventoryUpdatesAsProcessed_result)other;
23478
 
23479
      return 0;
23480
    }
23481
 
23482
    public _Fields fieldForId(int fieldId) {
23483
      return _Fields.findByThriftId(fieldId);
23484
    }
23485
 
23486
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23487
      org.apache.thrift.protocol.TField field;
23488
      iprot.readStructBegin();
23489
      while (true)
23490
      {
23491
        field = iprot.readFieldBegin();
23492
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23493
          break;
23494
        }
23495
        switch (field.id) {
23496
          default:
23497
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23498
        }
23499
        iprot.readFieldEnd();
23500
      }
23501
      iprot.readStructEnd();
23502
      validate();
23503
    }
23504
 
23505
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23506
      oprot.writeStructBegin(STRUCT_DESC);
23507
 
23508
      oprot.writeFieldStop();
23509
      oprot.writeStructEnd();
23510
    }
23511
 
23512
    @Override
23513
    public String toString() {
23514
      StringBuilder sb = new StringBuilder("markMissedInventoryUpdatesAsProcessed_result(");
23515
      boolean first = true;
23516
 
23517
      sb.append(")");
23518
      return sb.toString();
23519
    }
23520
 
23521
    public void validate() throws org.apache.thrift.TException {
23522
      // check for required fields
23523
    }
23524
 
23525
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23526
      try {
23527
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23528
      } catch (org.apache.thrift.TException te) {
23529
        throw new java.io.IOException(te);
23530
      }
23531
    }
23532
 
23533
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23534
      try {
23535
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23536
      } catch (org.apache.thrift.TException te) {
23537
        throw new java.io.IOException(te);
23538
      }
23539
    }
23540
 
23541
  }
23542
 
23543
  public static class getIgnoredItemKeys_args implements org.apache.thrift.TBase<getIgnoredItemKeys_args, getIgnoredItemKeys_args._Fields>, java.io.Serializable, Cloneable   {
23544
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getIgnoredItemKeys_args");
23545
 
23546
 
23547
 
23548
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23549
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23550
;
23551
 
23552
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23553
 
23554
      static {
23555
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23556
          byName.put(field.getFieldName(), field);
23557
        }
23558
      }
23559
 
23560
      /**
23561
       * Find the _Fields constant that matches fieldId, or null if its not found.
23562
       */
23563
      public static _Fields findByThriftId(int fieldId) {
23564
        switch(fieldId) {
23565
          default:
23566
            return null;
23567
        }
23568
      }
23569
 
23570
      /**
23571
       * Find the _Fields constant that matches fieldId, throwing an exception
23572
       * if it is not found.
23573
       */
23574
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23575
        _Fields fields = findByThriftId(fieldId);
23576
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23577
        return fields;
23578
      }
23579
 
23580
      /**
23581
       * Find the _Fields constant that matches name, or null if its not found.
23582
       */
23583
      public static _Fields findByName(String name) {
23584
        return byName.get(name);
23585
      }
23586
 
23587
      private final short _thriftId;
23588
      private final String _fieldName;
23589
 
23590
      _Fields(short thriftId, String fieldName) {
23591
        _thriftId = thriftId;
23592
        _fieldName = fieldName;
23593
      }
23594
 
23595
      public short getThriftFieldId() {
23596
        return _thriftId;
23597
      }
23598
 
23599
      public String getFieldName() {
23600
        return _fieldName;
23601
      }
23602
    }
23603
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23604
    static {
23605
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23606
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23607
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getIgnoredItemKeys_args.class, metaDataMap);
23608
    }
23609
 
23610
    public getIgnoredItemKeys_args() {
23611
    }
23612
 
23613
    /**
23614
     * Performs a deep copy on <i>other</i>.
23615
     */
23616
    public getIgnoredItemKeys_args(getIgnoredItemKeys_args other) {
23617
    }
23618
 
23619
    public getIgnoredItemKeys_args deepCopy() {
23620
      return new getIgnoredItemKeys_args(this);
23621
    }
23622
 
23623
    @Override
23624
    public void clear() {
23625
    }
23626
 
23627
    public void setFieldValue(_Fields field, Object value) {
23628
      switch (field) {
23629
      }
23630
    }
23631
 
23632
    public Object getFieldValue(_Fields field) {
23633
      switch (field) {
23634
      }
23635
      throw new IllegalStateException();
23636
    }
23637
 
23638
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23639
    public boolean isSet(_Fields field) {
23640
      if (field == null) {
23641
        throw new IllegalArgumentException();
23642
      }
23643
 
23644
      switch (field) {
23645
      }
23646
      throw new IllegalStateException();
23647
    }
23648
 
23649
    @Override
23650
    public boolean equals(Object that) {
23651
      if (that == null)
23652
        return false;
23653
      if (that instanceof getIgnoredItemKeys_args)
23654
        return this.equals((getIgnoredItemKeys_args)that);
23655
      return false;
23656
    }
23657
 
23658
    public boolean equals(getIgnoredItemKeys_args that) {
23659
      if (that == null)
23660
        return false;
23661
 
23662
      return true;
23663
    }
23664
 
23665
    @Override
23666
    public int hashCode() {
23667
      return 0;
23668
    }
23669
 
23670
    public int compareTo(getIgnoredItemKeys_args other) {
23671
      if (!getClass().equals(other.getClass())) {
23672
        return getClass().getName().compareTo(other.getClass().getName());
23673
      }
23674
 
23675
      int lastComparison = 0;
23676
      getIgnoredItemKeys_args typedOther = (getIgnoredItemKeys_args)other;
23677
 
23678
      return 0;
23679
    }
23680
 
23681
    public _Fields fieldForId(int fieldId) {
23682
      return _Fields.findByThriftId(fieldId);
23683
    }
23684
 
23685
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23686
      org.apache.thrift.protocol.TField field;
23687
      iprot.readStructBegin();
23688
      while (true)
23689
      {
23690
        field = iprot.readFieldBegin();
23691
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
23692
          break;
23693
        }
23694
        switch (field.id) {
23695
          default:
23696
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
23697
        }
23698
        iprot.readFieldEnd();
23699
      }
23700
      iprot.readStructEnd();
23701
      validate();
23702
    }
23703
 
23704
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
23705
      validate();
23706
 
23707
      oprot.writeStructBegin(STRUCT_DESC);
23708
      oprot.writeFieldStop();
23709
      oprot.writeStructEnd();
23710
    }
23711
 
23712
    @Override
23713
    public String toString() {
23714
      StringBuilder sb = new StringBuilder("getIgnoredItemKeys_args(");
23715
      boolean first = true;
23716
 
23717
      sb.append(")");
23718
      return sb.toString();
23719
    }
23720
 
23721
    public void validate() throws org.apache.thrift.TException {
23722
      // check for required fields
23723
    }
23724
 
23725
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
23726
      try {
23727
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
23728
      } catch (org.apache.thrift.TException te) {
23729
        throw new java.io.IOException(te);
23730
      }
23731
    }
23732
 
23733
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
23734
      try {
23735
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
23736
      } catch (org.apache.thrift.TException te) {
23737
        throw new java.io.IOException(te);
23738
      }
23739
    }
23740
 
23741
  }
23742
 
23743
  public static class getIgnoredItemKeys_result implements org.apache.thrift.TBase<getIgnoredItemKeys_result, getIgnoredItemKeys_result._Fields>, java.io.Serializable, Cloneable   {
23744
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getIgnoredItemKeys_result");
23745
 
23746
    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);
23747
 
23748
    private Map<String,Map<Long,Long>> success; // required
23749
 
23750
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
23751
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
23752
      SUCCESS((short)0, "success");
23753
 
23754
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
23755
 
23756
      static {
23757
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
23758
          byName.put(field.getFieldName(), field);
23759
        }
23760
      }
23761
 
23762
      /**
23763
       * Find the _Fields constant that matches fieldId, or null if its not found.
23764
       */
23765
      public static _Fields findByThriftId(int fieldId) {
23766
        switch(fieldId) {
23767
          case 0: // SUCCESS
23768
            return SUCCESS;
23769
          default:
23770
            return null;
23771
        }
23772
      }
23773
 
23774
      /**
23775
       * Find the _Fields constant that matches fieldId, throwing an exception
23776
       * if it is not found.
23777
       */
23778
      public static _Fields findByThriftIdOrThrow(int fieldId) {
23779
        _Fields fields = findByThriftId(fieldId);
23780
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
23781
        return fields;
23782
      }
23783
 
23784
      /**
23785
       * Find the _Fields constant that matches name, or null if its not found.
23786
       */
23787
      public static _Fields findByName(String name) {
23788
        return byName.get(name);
23789
      }
23790
 
23791
      private final short _thriftId;
23792
      private final String _fieldName;
23793
 
23794
      _Fields(short thriftId, String fieldName) {
23795
        _thriftId = thriftId;
23796
        _fieldName = fieldName;
23797
      }
23798
 
23799
      public short getThriftFieldId() {
23800
        return _thriftId;
23801
      }
23802
 
23803
      public String getFieldName() {
23804
        return _fieldName;
23805
      }
23806
    }
23807
 
23808
    // isset id assignments
23809
 
23810
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
23811
    static {
23812
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
23813
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
23814
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
23815
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING), 
23816
              new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
23817
                  new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
23818
                  new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)))));
23819
      metaDataMap = Collections.unmodifiableMap(tmpMap);
23820
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getIgnoredItemKeys_result.class, metaDataMap);
23821
    }
23822
 
23823
    public getIgnoredItemKeys_result() {
23824
    }
23825
 
23826
    public getIgnoredItemKeys_result(
23827
      Map<String,Map<Long,Long>> success)
23828
    {
23829
      this();
23830
      this.success = success;
23831
    }
23832
 
23833
    /**
23834
     * Performs a deep copy on <i>other</i>.
23835
     */
23836
    public getIgnoredItemKeys_result(getIgnoredItemKeys_result other) {
23837
      if (other.isSetSuccess()) {
23838
        Map<String,Map<Long,Long>> __this__success = new HashMap<String,Map<Long,Long>>();
23839
        for (Map.Entry<String, Map<Long,Long>> other_element : other.success.entrySet()) {
23840
 
23841
          String other_element_key = other_element.getKey();
23842
          Map<Long,Long> other_element_value = other_element.getValue();
23843
 
23844
          String __this__success_copy_key = other_element_key;
23845
 
23846
          Map<Long,Long> __this__success_copy_value = new HashMap<Long,Long>();
23847
          for (Map.Entry<Long, Long> other_element_value_element : other_element_value.entrySet()) {
23848
 
23849
            Long other_element_value_element_key = other_element_value_element.getKey();
23850
            Long other_element_value_element_value = other_element_value_element.getValue();
23851
 
23852
            Long __this__success_copy_value_copy_key = other_element_value_element_key;
23853
 
23854
            Long __this__success_copy_value_copy_value = other_element_value_element_value;
23855
 
23856
            __this__success_copy_value.put(__this__success_copy_value_copy_key, __this__success_copy_value_copy_value);
23857
          }
23858
 
23859
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
23860
        }
23861
        this.success = __this__success;
23862
      }
23863
    }
23864
 
23865
    public getIgnoredItemKeys_result deepCopy() {
23866
      return new getIgnoredItemKeys_result(this);
23867
    }
23868
 
23869
    @Override
23870
    public void clear() {
23871
      this.success = null;
23872
    }
23873
 
23874
    public int getSuccessSize() {
23875
      return (this.success == null) ? 0 : this.success.size();
23876
    }
23877
 
23878
    public void putToSuccess(String key, Map<Long,Long> val) {
23879
      if (this.success == null) {
23880
        this.success = new HashMap<String,Map<Long,Long>>();
23881
      }
23882
      this.success.put(key, val);
23883
    }
23884
 
23885
    public Map<String,Map<Long,Long>> getSuccess() {
23886
      return this.success;
23887
    }
23888
 
23889
    public void setSuccess(Map<String,Map<Long,Long>> success) {
23890
      this.success = success;
23891
    }
23892
 
23893
    public void unsetSuccess() {
23894
      this.success = null;
23895
    }
23896
 
23897
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
23898
    public boolean isSetSuccess() {
23899
      return this.success != null;
23900
    }
23901
 
23902
    public void setSuccessIsSet(boolean value) {
23903
      if (!value) {
23904
        this.success = null;
23905
      }
23906
    }
23907
 
23908
    public void setFieldValue(_Fields field, Object value) {
23909
      switch (field) {
23910
      case SUCCESS:
23911
        if (value == null) {
23912
          unsetSuccess();
23913
        } else {
23914
          setSuccess((Map<String,Map<Long,Long>>)value);
23915
        }
23916
        break;
23917
 
23918
      }
23919
    }
23920
 
23921
    public Object getFieldValue(_Fields field) {
23922
      switch (field) {
23923
      case SUCCESS:
23924
        return getSuccess();
23925
 
23926
      }
23927
      throw new IllegalStateException();
23928
    }
23929
 
23930
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
23931
    public boolean isSet(_Fields field) {
23932
      if (field == null) {
23933
        throw new IllegalArgumentException();
23934
      }
23935
 
23936
      switch (field) {
23937
      case SUCCESS:
23938
        return isSetSuccess();
23939
      }
23940
      throw new IllegalStateException();
23941
    }
23942
 
23943
    @Override
23944
    public boolean equals(Object that) {
23945
      if (that == null)
23946
        return false;
23947
      if (that instanceof getIgnoredItemKeys_result)
23948
        return this.equals((getIgnoredItemKeys_result)that);
23949
      return false;
23950
    }
23951
 
23952
    public boolean equals(getIgnoredItemKeys_result that) {
23953
      if (that == null)
23954
        return false;
23955
 
23956
      boolean this_present_success = true && this.isSetSuccess();
23957
      boolean that_present_success = true && that.isSetSuccess();
23958
      if (this_present_success || that_present_success) {
23959
        if (!(this_present_success && that_present_success))
23960
          return false;
23961
        if (!this.success.equals(that.success))
23962
          return false;
23963
      }
23964
 
23965
      return true;
23966
    }
23967
 
23968
    @Override
23969
    public int hashCode() {
23970
      return 0;
23971
    }
23972
 
23973
    public int compareTo(getIgnoredItemKeys_result other) {
23974
      if (!getClass().equals(other.getClass())) {
23975
        return getClass().getName().compareTo(other.getClass().getName());
23976
      }
23977
 
23978
      int lastComparison = 0;
23979
      getIgnoredItemKeys_result typedOther = (getIgnoredItemKeys_result)other;
23980
 
23981
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
23982
      if (lastComparison != 0) {
23983
        return lastComparison;
23984
      }
23985
      if (isSetSuccess()) {
23986
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
23987
        if (lastComparison != 0) {
23988
          return lastComparison;
23989
        }
23990
      }
23991
      return 0;
23992
    }
23993
 
23994
    public _Fields fieldForId(int fieldId) {
23995
      return _Fields.findByThriftId(fieldId);
23996
    }
23997
 
23998
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
23999
      org.apache.thrift.protocol.TField field;
24000
      iprot.readStructBegin();
24001
      while (true)
24002
      {
24003
        field = iprot.readFieldBegin();
24004
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24005
          break;
24006
        }
24007
        switch (field.id) {
24008
          case 0: // SUCCESS
24009
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
24010
              {
24011
                org.apache.thrift.protocol.TMap _map56 = iprot.readMapBegin();
24012
                this.success = new HashMap<String,Map<Long,Long>>(2*_map56.size);
24013
                for (int _i57 = 0; _i57 < _map56.size; ++_i57)
24014
                {
24015
                  String _key58; // required
24016
                  Map<Long,Long> _val59; // required
24017
                  _key58 = iprot.readString();
24018
                  {
24019
                    org.apache.thrift.protocol.TMap _map60 = iprot.readMapBegin();
24020
                    _val59 = new HashMap<Long,Long>(2*_map60.size);
24021
                    for (int _i61 = 0; _i61 < _map60.size; ++_i61)
24022
                    {
24023
                      long _key62; // required
24024
                      long _val63; // required
24025
                      _key62 = iprot.readI64();
24026
                      _val63 = iprot.readI64();
24027
                      _val59.put(_key62, _val63);
24028
                    }
24029
                    iprot.readMapEnd();
24030
                  }
24031
                  this.success.put(_key58, _val59);
24032
                }
24033
                iprot.readMapEnd();
24034
              }
24035
            } else { 
24036
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24037
            }
24038
            break;
24039
          default:
24040
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24041
        }
24042
        iprot.readFieldEnd();
24043
      }
24044
      iprot.readStructEnd();
24045
      validate();
24046
    }
24047
 
24048
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24049
      oprot.writeStructBegin(STRUCT_DESC);
24050
 
24051
      if (this.isSetSuccess()) {
24052
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
24053
        {
24054
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.STRING, org.apache.thrift.protocol.TType.MAP, this.success.size()));
24055
          for (Map.Entry<String, Map<Long,Long>> _iter64 : this.success.entrySet())
24056
          {
24057
            oprot.writeString(_iter64.getKey());
24058
            {
24059
              oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.I64, _iter64.getValue().size()));
24060
              for (Map.Entry<Long, Long> _iter65 : _iter64.getValue().entrySet())
24061
              {
24062
                oprot.writeI64(_iter65.getKey());
24063
                oprot.writeI64(_iter65.getValue());
24064
              }
24065
              oprot.writeMapEnd();
24066
            }
24067
          }
24068
          oprot.writeMapEnd();
24069
        }
24070
        oprot.writeFieldEnd();
24071
      }
24072
      oprot.writeFieldStop();
24073
      oprot.writeStructEnd();
24074
    }
24075
 
24076
    @Override
24077
    public String toString() {
24078
      StringBuilder sb = new StringBuilder("getIgnoredItemKeys_result(");
24079
      boolean first = true;
24080
 
24081
      sb.append("success:");
24082
      if (this.success == null) {
24083
        sb.append("null");
24084
      } else {
24085
        sb.append(this.success);
24086
      }
24087
      first = false;
24088
      sb.append(")");
24089
      return sb.toString();
24090
    }
24091
 
24092
    public void validate() throws org.apache.thrift.TException {
24093
      // check for required fields
24094
    }
24095
 
24096
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24097
      try {
24098
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24099
      } catch (org.apache.thrift.TException te) {
24100
        throw new java.io.IOException(te);
24101
      }
24102
    }
24103
 
24104
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24105
      try {
24106
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24107
      } catch (org.apache.thrift.TException te) {
24108
        throw new java.io.IOException(te);
24109
      }
24110
    }
24111
 
24112
  }
24113
 
24114
  public static class addBadInventory_args implements org.apache.thrift.TBase<addBadInventory_args, addBadInventory_args._Fields>, java.io.Serializable, Cloneable   {
24115
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addBadInventory_args");
24116
 
24117
    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);
24118
    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);
24119
    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);
24120
 
24121
    private long itemId; // required
24122
    private long warehouseId; // required
24123
    private long quantity; // required
24124
 
24125
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24126
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24127
      ITEM_ID((short)1, "itemId"),
24128
      WAREHOUSE_ID((short)2, "warehouseId"),
24129
      QUANTITY((short)3, "quantity");
24130
 
24131
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24132
 
24133
      static {
24134
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24135
          byName.put(field.getFieldName(), field);
24136
        }
24137
      }
24138
 
24139
      /**
24140
       * Find the _Fields constant that matches fieldId, or null if its not found.
24141
       */
24142
      public static _Fields findByThriftId(int fieldId) {
24143
        switch(fieldId) {
24144
          case 1: // ITEM_ID
24145
            return ITEM_ID;
24146
          case 2: // WAREHOUSE_ID
24147
            return WAREHOUSE_ID;
24148
          case 3: // QUANTITY
24149
            return QUANTITY;
24150
          default:
24151
            return null;
24152
        }
24153
      }
24154
 
24155
      /**
24156
       * Find the _Fields constant that matches fieldId, throwing an exception
24157
       * if it is not found.
24158
       */
24159
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24160
        _Fields fields = findByThriftId(fieldId);
24161
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24162
        return fields;
24163
      }
24164
 
24165
      /**
24166
       * Find the _Fields constant that matches name, or null if its not found.
24167
       */
24168
      public static _Fields findByName(String name) {
24169
        return byName.get(name);
24170
      }
24171
 
24172
      private final short _thriftId;
24173
      private final String _fieldName;
24174
 
24175
      _Fields(short thriftId, String fieldName) {
24176
        _thriftId = thriftId;
24177
        _fieldName = fieldName;
24178
      }
24179
 
24180
      public short getThriftFieldId() {
24181
        return _thriftId;
24182
      }
24183
 
24184
      public String getFieldName() {
24185
        return _fieldName;
24186
      }
24187
    }
24188
 
24189
    // isset id assignments
24190
    private static final int __ITEMID_ISSET_ID = 0;
24191
    private static final int __WAREHOUSEID_ISSET_ID = 1;
24192
    private static final int __QUANTITY_ISSET_ID = 2;
24193
    private BitSet __isset_bit_vector = new BitSet(3);
24194
 
24195
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24196
    static {
24197
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24198
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24199
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24200
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24201
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24202
      tmpMap.put(_Fields.QUANTITY, new org.apache.thrift.meta_data.FieldMetaData("quantity", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24203
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
24204
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24205
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addBadInventory_args.class, metaDataMap);
24206
    }
24207
 
24208
    public addBadInventory_args() {
24209
    }
24210
 
24211
    public addBadInventory_args(
24212
      long itemId,
24213
      long warehouseId,
24214
      long quantity)
24215
    {
24216
      this();
24217
      this.itemId = itemId;
24218
      setItemIdIsSet(true);
24219
      this.warehouseId = warehouseId;
24220
      setWarehouseIdIsSet(true);
24221
      this.quantity = quantity;
24222
      setQuantityIsSet(true);
24223
    }
24224
 
24225
    /**
24226
     * Performs a deep copy on <i>other</i>.
24227
     */
24228
    public addBadInventory_args(addBadInventory_args other) {
24229
      __isset_bit_vector.clear();
24230
      __isset_bit_vector.or(other.__isset_bit_vector);
24231
      this.itemId = other.itemId;
24232
      this.warehouseId = other.warehouseId;
24233
      this.quantity = other.quantity;
24234
    }
24235
 
24236
    public addBadInventory_args deepCopy() {
24237
      return new addBadInventory_args(this);
24238
    }
24239
 
24240
    @Override
24241
    public void clear() {
24242
      setItemIdIsSet(false);
24243
      this.itemId = 0;
24244
      setWarehouseIdIsSet(false);
24245
      this.warehouseId = 0;
24246
      setQuantityIsSet(false);
24247
      this.quantity = 0;
24248
    }
24249
 
24250
    public long getItemId() {
24251
      return this.itemId;
24252
    }
24253
 
24254
    public void setItemId(long itemId) {
24255
      this.itemId = itemId;
24256
      setItemIdIsSet(true);
24257
    }
24258
 
24259
    public void unsetItemId() {
24260
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
24261
    }
24262
 
24263
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
24264
    public boolean isSetItemId() {
24265
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
24266
    }
24267
 
24268
    public void setItemIdIsSet(boolean value) {
24269
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
24270
    }
24271
 
24272
    public long getWarehouseId() {
24273
      return this.warehouseId;
24274
    }
24275
 
24276
    public void setWarehouseId(long warehouseId) {
24277
      this.warehouseId = warehouseId;
24278
      setWarehouseIdIsSet(true);
24279
    }
24280
 
24281
    public void unsetWarehouseId() {
24282
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
24283
    }
24284
 
24285
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
24286
    public boolean isSetWarehouseId() {
24287
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
24288
    }
24289
 
24290
    public void setWarehouseIdIsSet(boolean value) {
24291
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
24292
    }
24293
 
24294
    public long getQuantity() {
24295
      return this.quantity;
24296
    }
24297
 
24298
    public void setQuantity(long quantity) {
24299
      this.quantity = quantity;
24300
      setQuantityIsSet(true);
24301
    }
24302
 
24303
    public void unsetQuantity() {
24304
      __isset_bit_vector.clear(__QUANTITY_ISSET_ID);
24305
    }
24306
 
24307
    /** Returns true if field quantity is set (has been assigned a value) and false otherwise */
24308
    public boolean isSetQuantity() {
24309
      return __isset_bit_vector.get(__QUANTITY_ISSET_ID);
24310
    }
24311
 
24312
    public void setQuantityIsSet(boolean value) {
24313
      __isset_bit_vector.set(__QUANTITY_ISSET_ID, value);
24314
    }
24315
 
24316
    public void setFieldValue(_Fields field, Object value) {
24317
      switch (field) {
24318
      case ITEM_ID:
24319
        if (value == null) {
24320
          unsetItemId();
24321
        } else {
24322
          setItemId((Long)value);
24323
        }
24324
        break;
24325
 
24326
      case WAREHOUSE_ID:
24327
        if (value == null) {
24328
          unsetWarehouseId();
24329
        } else {
24330
          setWarehouseId((Long)value);
24331
        }
24332
        break;
24333
 
24334
      case QUANTITY:
24335
        if (value == null) {
24336
          unsetQuantity();
24337
        } else {
24338
          setQuantity((Long)value);
24339
        }
24340
        break;
24341
 
24342
      }
24343
    }
24344
 
24345
    public Object getFieldValue(_Fields field) {
24346
      switch (field) {
24347
      case ITEM_ID:
24348
        return Long.valueOf(getItemId());
24349
 
24350
      case WAREHOUSE_ID:
24351
        return Long.valueOf(getWarehouseId());
24352
 
24353
      case QUANTITY:
24354
        return Long.valueOf(getQuantity());
24355
 
24356
      }
24357
      throw new IllegalStateException();
24358
    }
24359
 
24360
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24361
    public boolean isSet(_Fields field) {
24362
      if (field == null) {
24363
        throw new IllegalArgumentException();
24364
      }
24365
 
24366
      switch (field) {
24367
      case ITEM_ID:
24368
        return isSetItemId();
24369
      case WAREHOUSE_ID:
24370
        return isSetWarehouseId();
24371
      case QUANTITY:
24372
        return isSetQuantity();
24373
      }
24374
      throw new IllegalStateException();
24375
    }
24376
 
24377
    @Override
24378
    public boolean equals(Object that) {
24379
      if (that == null)
24380
        return false;
24381
      if (that instanceof addBadInventory_args)
24382
        return this.equals((addBadInventory_args)that);
24383
      return false;
24384
    }
24385
 
24386
    public boolean equals(addBadInventory_args that) {
24387
      if (that == null)
24388
        return false;
24389
 
24390
      boolean this_present_itemId = true;
24391
      boolean that_present_itemId = true;
24392
      if (this_present_itemId || that_present_itemId) {
24393
        if (!(this_present_itemId && that_present_itemId))
24394
          return false;
24395
        if (this.itemId != that.itemId)
24396
          return false;
24397
      }
24398
 
24399
      boolean this_present_warehouseId = true;
24400
      boolean that_present_warehouseId = true;
24401
      if (this_present_warehouseId || that_present_warehouseId) {
24402
        if (!(this_present_warehouseId && that_present_warehouseId))
24403
          return false;
24404
        if (this.warehouseId != that.warehouseId)
24405
          return false;
24406
      }
24407
 
24408
      boolean this_present_quantity = true;
24409
      boolean that_present_quantity = true;
24410
      if (this_present_quantity || that_present_quantity) {
24411
        if (!(this_present_quantity && that_present_quantity))
24412
          return false;
24413
        if (this.quantity != that.quantity)
24414
          return false;
24415
      }
24416
 
24417
      return true;
24418
    }
24419
 
24420
    @Override
24421
    public int hashCode() {
24422
      return 0;
24423
    }
24424
 
24425
    public int compareTo(addBadInventory_args other) {
24426
      if (!getClass().equals(other.getClass())) {
24427
        return getClass().getName().compareTo(other.getClass().getName());
24428
      }
24429
 
24430
      int lastComparison = 0;
24431
      addBadInventory_args typedOther = (addBadInventory_args)other;
24432
 
24433
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
24434
      if (lastComparison != 0) {
24435
        return lastComparison;
24436
      }
24437
      if (isSetItemId()) {
24438
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
24439
        if (lastComparison != 0) {
24440
          return lastComparison;
24441
        }
24442
      }
24443
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
24444
      if (lastComparison != 0) {
24445
        return lastComparison;
24446
      }
24447
      if (isSetWarehouseId()) {
24448
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
24449
        if (lastComparison != 0) {
24450
          return lastComparison;
24451
        }
24452
      }
24453
      lastComparison = Boolean.valueOf(isSetQuantity()).compareTo(typedOther.isSetQuantity());
24454
      if (lastComparison != 0) {
24455
        return lastComparison;
24456
      }
24457
      if (isSetQuantity()) {
24458
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.quantity, typedOther.quantity);
24459
        if (lastComparison != 0) {
24460
          return lastComparison;
24461
        }
24462
      }
24463
      return 0;
24464
    }
24465
 
24466
    public _Fields fieldForId(int fieldId) {
24467
      return _Fields.findByThriftId(fieldId);
24468
    }
24469
 
24470
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24471
      org.apache.thrift.protocol.TField field;
24472
      iprot.readStructBegin();
24473
      while (true)
24474
      {
24475
        field = iprot.readFieldBegin();
24476
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24477
          break;
24478
        }
24479
        switch (field.id) {
24480
          case 1: // ITEM_ID
24481
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24482
              this.itemId = iprot.readI64();
24483
              setItemIdIsSet(true);
24484
            } else { 
24485
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24486
            }
24487
            break;
24488
          case 2: // WAREHOUSE_ID
24489
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24490
              this.warehouseId = iprot.readI64();
24491
              setWarehouseIdIsSet(true);
24492
            } else { 
24493
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24494
            }
24495
            break;
24496
          case 3: // QUANTITY
24497
            if (field.type == org.apache.thrift.protocol.TType.I64) {
24498
              this.quantity = iprot.readI64();
24499
              setQuantityIsSet(true);
24500
            } else { 
24501
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24502
            }
24503
            break;
24504
          default:
24505
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24506
        }
24507
        iprot.readFieldEnd();
24508
      }
24509
      iprot.readStructEnd();
24510
      validate();
24511
    }
24512
 
24513
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24514
      validate();
24515
 
24516
      oprot.writeStructBegin(STRUCT_DESC);
24517
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
24518
      oprot.writeI64(this.itemId);
24519
      oprot.writeFieldEnd();
24520
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
24521
      oprot.writeI64(this.warehouseId);
24522
      oprot.writeFieldEnd();
24523
      oprot.writeFieldBegin(QUANTITY_FIELD_DESC);
24524
      oprot.writeI64(this.quantity);
24525
      oprot.writeFieldEnd();
24526
      oprot.writeFieldStop();
24527
      oprot.writeStructEnd();
24528
    }
24529
 
24530
    @Override
24531
    public String toString() {
24532
      StringBuilder sb = new StringBuilder("addBadInventory_args(");
24533
      boolean first = true;
24534
 
24535
      sb.append("itemId:");
24536
      sb.append(this.itemId);
24537
      first = false;
24538
      if (!first) sb.append(", ");
24539
      sb.append("warehouseId:");
24540
      sb.append(this.warehouseId);
24541
      first = false;
24542
      if (!first) sb.append(", ");
24543
      sb.append("quantity:");
24544
      sb.append(this.quantity);
24545
      first = false;
24546
      sb.append(")");
24547
      return sb.toString();
24548
    }
24549
 
24550
    public void validate() throws org.apache.thrift.TException {
24551
      // check for required fields
24552
    }
24553
 
24554
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24555
      try {
24556
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24557
      } catch (org.apache.thrift.TException te) {
24558
        throw new java.io.IOException(te);
24559
      }
24560
    }
24561
 
24562
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24563
      try {
24564
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
24565
        __isset_bit_vector = new BitSet(1);
24566
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24567
      } catch (org.apache.thrift.TException te) {
24568
        throw new java.io.IOException(te);
24569
      }
24570
    }
24571
 
24572
  }
24573
 
24574
  public static class addBadInventory_result implements org.apache.thrift.TBase<addBadInventory_result, addBadInventory_result._Fields>, java.io.Serializable, Cloneable   {
24575
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("addBadInventory_result");
24576
 
24577
    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);
24578
 
24579
    private InventoryServiceException cex; // required
24580
 
24581
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24582
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24583
      CEX((short)1, "cex");
24584
 
24585
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24586
 
24587
      static {
24588
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24589
          byName.put(field.getFieldName(), field);
24590
        }
24591
      }
24592
 
24593
      /**
24594
       * Find the _Fields constant that matches fieldId, or null if its not found.
24595
       */
24596
      public static _Fields findByThriftId(int fieldId) {
24597
        switch(fieldId) {
24598
          case 1: // CEX
24599
            return CEX;
24600
          default:
24601
            return null;
24602
        }
24603
      }
24604
 
24605
      /**
24606
       * Find the _Fields constant that matches fieldId, throwing an exception
24607
       * if it is not found.
24608
       */
24609
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24610
        _Fields fields = findByThriftId(fieldId);
24611
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24612
        return fields;
24613
      }
24614
 
24615
      /**
24616
       * Find the _Fields constant that matches name, or null if its not found.
24617
       */
24618
      public static _Fields findByName(String name) {
24619
        return byName.get(name);
24620
      }
24621
 
24622
      private final short _thriftId;
24623
      private final String _fieldName;
24624
 
24625
      _Fields(short thriftId, String fieldName) {
24626
        _thriftId = thriftId;
24627
        _fieldName = fieldName;
24628
      }
24629
 
24630
      public short getThriftFieldId() {
24631
        return _thriftId;
24632
      }
24633
 
24634
      public String getFieldName() {
24635
        return _fieldName;
24636
      }
24637
    }
24638
 
24639
    // isset id assignments
24640
 
24641
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24642
    static {
24643
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24644
      tmpMap.put(_Fields.CEX, new org.apache.thrift.meta_data.FieldMetaData("cex", org.apache.thrift.TFieldRequirementType.DEFAULT, 
24645
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
24646
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24647
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(addBadInventory_result.class, metaDataMap);
24648
    }
24649
 
24650
    public addBadInventory_result() {
24651
    }
24652
 
24653
    public addBadInventory_result(
24654
      InventoryServiceException cex)
24655
    {
24656
      this();
24657
      this.cex = cex;
24658
    }
24659
 
24660
    /**
24661
     * Performs a deep copy on <i>other</i>.
24662
     */
24663
    public addBadInventory_result(addBadInventory_result other) {
24664
      if (other.isSetCex()) {
24665
        this.cex = new InventoryServiceException(other.cex);
24666
      }
24667
    }
24668
 
24669
    public addBadInventory_result deepCopy() {
24670
      return new addBadInventory_result(this);
24671
    }
24672
 
24673
    @Override
24674
    public void clear() {
24675
      this.cex = null;
24676
    }
24677
 
24678
    public InventoryServiceException getCex() {
24679
      return this.cex;
24680
    }
24681
 
24682
    public void setCex(InventoryServiceException cex) {
24683
      this.cex = cex;
24684
    }
24685
 
24686
    public void unsetCex() {
24687
      this.cex = null;
24688
    }
24689
 
24690
    /** Returns true if field cex is set (has been assigned a value) and false otherwise */
24691
    public boolean isSetCex() {
24692
      return this.cex != null;
24693
    }
24694
 
24695
    public void setCexIsSet(boolean value) {
24696
      if (!value) {
24697
        this.cex = null;
24698
      }
24699
    }
24700
 
24701
    public void setFieldValue(_Fields field, Object value) {
24702
      switch (field) {
24703
      case CEX:
24704
        if (value == null) {
24705
          unsetCex();
24706
        } else {
24707
          setCex((InventoryServiceException)value);
24708
        }
24709
        break;
24710
 
24711
      }
24712
    }
24713
 
24714
    public Object getFieldValue(_Fields field) {
24715
      switch (field) {
24716
      case CEX:
24717
        return getCex();
24718
 
24719
      }
24720
      throw new IllegalStateException();
24721
    }
24722
 
24723
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24724
    public boolean isSet(_Fields field) {
24725
      if (field == null) {
24726
        throw new IllegalArgumentException();
24727
      }
24728
 
24729
      switch (field) {
24730
      case CEX:
24731
        return isSetCex();
24732
      }
24733
      throw new IllegalStateException();
24734
    }
24735
 
24736
    @Override
24737
    public boolean equals(Object that) {
24738
      if (that == null)
24739
        return false;
24740
      if (that instanceof addBadInventory_result)
24741
        return this.equals((addBadInventory_result)that);
24742
      return false;
24743
    }
24744
 
24745
    public boolean equals(addBadInventory_result that) {
24746
      if (that == null)
24747
        return false;
24748
 
24749
      boolean this_present_cex = true && this.isSetCex();
24750
      boolean that_present_cex = true && that.isSetCex();
24751
      if (this_present_cex || that_present_cex) {
24752
        if (!(this_present_cex && that_present_cex))
24753
          return false;
24754
        if (!this.cex.equals(that.cex))
24755
          return false;
24756
      }
24757
 
24758
      return true;
24759
    }
24760
 
24761
    @Override
24762
    public int hashCode() {
24763
      return 0;
24764
    }
24765
 
24766
    public int compareTo(addBadInventory_result other) {
24767
      if (!getClass().equals(other.getClass())) {
24768
        return getClass().getName().compareTo(other.getClass().getName());
24769
      }
24770
 
24771
      int lastComparison = 0;
24772
      addBadInventory_result typedOther = (addBadInventory_result)other;
24773
 
24774
      lastComparison = Boolean.valueOf(isSetCex()).compareTo(typedOther.isSetCex());
24775
      if (lastComparison != 0) {
24776
        return lastComparison;
24777
      }
24778
      if (isSetCex()) {
24779
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.cex, typedOther.cex);
24780
        if (lastComparison != 0) {
24781
          return lastComparison;
24782
        }
24783
      }
24784
      return 0;
24785
    }
24786
 
24787
    public _Fields fieldForId(int fieldId) {
24788
      return _Fields.findByThriftId(fieldId);
24789
    }
24790
 
24791
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
24792
      org.apache.thrift.protocol.TField field;
24793
      iprot.readStructBegin();
24794
      while (true)
24795
      {
24796
        field = iprot.readFieldBegin();
24797
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
24798
          break;
24799
        }
24800
        switch (field.id) {
24801
          case 1: // CEX
24802
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
24803
              this.cex = new InventoryServiceException();
24804
              this.cex.read(iprot);
24805
            } else { 
24806
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24807
            }
24808
            break;
24809
          default:
24810
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
24811
        }
24812
        iprot.readFieldEnd();
24813
      }
24814
      iprot.readStructEnd();
24815
      validate();
24816
    }
24817
 
24818
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
24819
      oprot.writeStructBegin(STRUCT_DESC);
24820
 
24821
      if (this.isSetCex()) {
24822
        oprot.writeFieldBegin(CEX_FIELD_DESC);
24823
        this.cex.write(oprot);
24824
        oprot.writeFieldEnd();
24825
      }
24826
      oprot.writeFieldStop();
24827
      oprot.writeStructEnd();
24828
    }
24829
 
24830
    @Override
24831
    public String toString() {
24832
      StringBuilder sb = new StringBuilder("addBadInventory_result(");
24833
      boolean first = true;
24834
 
24835
      sb.append("cex:");
24836
      if (this.cex == null) {
24837
        sb.append("null");
24838
      } else {
24839
        sb.append(this.cex);
24840
      }
24841
      first = false;
24842
      sb.append(")");
24843
      return sb.toString();
24844
    }
24845
 
24846
    public void validate() throws org.apache.thrift.TException {
24847
      // check for required fields
24848
    }
24849
 
24850
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
24851
      try {
24852
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
24853
      } catch (org.apache.thrift.TException te) {
24854
        throw new java.io.IOException(te);
24855
      }
24856
    }
24857
 
24858
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
24859
      try {
24860
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
24861
      } catch (org.apache.thrift.TException te) {
24862
        throw new java.io.IOException(te);
24863
      }
24864
    }
24865
 
24866
  }
24867
 
24868
  public static class getShippingLocations_args implements org.apache.thrift.TBase<getShippingLocations_args, getShippingLocations_args._Fields>, java.io.Serializable, Cloneable   {
24869
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShippingLocations_args");
24870
 
24871
 
24872
 
24873
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
24874
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
24875
;
24876
 
24877
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
24878
 
24879
      static {
24880
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
24881
          byName.put(field.getFieldName(), field);
24882
        }
24883
      }
24884
 
24885
      /**
24886
       * Find the _Fields constant that matches fieldId, or null if its not found.
24887
       */
24888
      public static _Fields findByThriftId(int fieldId) {
24889
        switch(fieldId) {
24890
          default:
24891
            return null;
24892
        }
24893
      }
24894
 
24895
      /**
24896
       * Find the _Fields constant that matches fieldId, throwing an exception
24897
       * if it is not found.
24898
       */
24899
      public static _Fields findByThriftIdOrThrow(int fieldId) {
24900
        _Fields fields = findByThriftId(fieldId);
24901
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
24902
        return fields;
24903
      }
24904
 
24905
      /**
24906
       * Find the _Fields constant that matches name, or null if its not found.
24907
       */
24908
      public static _Fields findByName(String name) {
24909
        return byName.get(name);
24910
      }
24911
 
24912
      private final short _thriftId;
24913
      private final String _fieldName;
24914
 
24915
      _Fields(short thriftId, String fieldName) {
24916
        _thriftId = thriftId;
24917
        _fieldName = fieldName;
24918
      }
24919
 
24920
      public short getThriftFieldId() {
24921
        return _thriftId;
24922
      }
24923
 
24924
      public String getFieldName() {
24925
        return _fieldName;
24926
      }
24927
    }
24928
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
24929
    static {
24930
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
24931
      metaDataMap = Collections.unmodifiableMap(tmpMap);
24932
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShippingLocations_args.class, metaDataMap);
24933
    }
24934
 
24935
    public getShippingLocations_args() {
24936
    }
24937
 
24938
    /**
24939
     * Performs a deep copy on <i>other</i>.
24940
     */
24941
    public getShippingLocations_args(getShippingLocations_args other) {
24942
    }
24943
 
24944
    public getShippingLocations_args deepCopy() {
24945
      return new getShippingLocations_args(this);
24946
    }
24947
 
24948
    @Override
24949
    public void clear() {
24950
    }
24951
 
24952
    public void setFieldValue(_Fields field, Object value) {
24953
      switch (field) {
24954
      }
24955
    }
24956
 
24957
    public Object getFieldValue(_Fields field) {
24958
      switch (field) {
24959
      }
24960
      throw new IllegalStateException();
24961
    }
24962
 
24963
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
24964
    public boolean isSet(_Fields field) {
24965
      if (field == null) {
24966
        throw new IllegalArgumentException();
24967
      }
24968
 
24969
      switch (field) {
24970
      }
24971
      throw new IllegalStateException();
24972
    }
24973
 
24974
    @Override
24975
    public boolean equals(Object that) {
24976
      if (that == null)
24977
        return false;
24978
      if (that instanceof getShippingLocations_args)
24979
        return this.equals((getShippingLocations_args)that);
24980
      return false;
24981
    }
24982
 
24983
    public boolean equals(getShippingLocations_args that) {
24984
      if (that == null)
24985
        return false;
24986
 
24987
      return true;
24988
    }
24989
 
24990
    @Override
24991
    public int hashCode() {
24992
      return 0;
24993
    }
24994
 
24995
    public int compareTo(getShippingLocations_args other) {
24996
      if (!getClass().equals(other.getClass())) {
24997
        return getClass().getName().compareTo(other.getClass().getName());
24998
      }
24999
 
25000
      int lastComparison = 0;
25001
      getShippingLocations_args typedOther = (getShippingLocations_args)other;
25002
 
25003
      return 0;
25004
    }
25005
 
25006
    public _Fields fieldForId(int fieldId) {
25007
      return _Fields.findByThriftId(fieldId);
25008
    }
25009
 
25010
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25011
      org.apache.thrift.protocol.TField field;
25012
      iprot.readStructBegin();
25013
      while (true)
25014
      {
25015
        field = iprot.readFieldBegin();
25016
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25017
          break;
25018
        }
25019
        switch (field.id) {
25020
          default:
25021
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25022
        }
25023
        iprot.readFieldEnd();
25024
      }
25025
      iprot.readStructEnd();
25026
      validate();
25027
    }
25028
 
25029
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25030
      validate();
25031
 
25032
      oprot.writeStructBegin(STRUCT_DESC);
25033
      oprot.writeFieldStop();
25034
      oprot.writeStructEnd();
25035
    }
25036
 
25037
    @Override
25038
    public String toString() {
25039
      StringBuilder sb = new StringBuilder("getShippingLocations_args(");
25040
      boolean first = true;
25041
 
25042
      sb.append(")");
25043
      return sb.toString();
25044
    }
25045
 
25046
    public void validate() throws org.apache.thrift.TException {
25047
      // check for required fields
25048
    }
25049
 
25050
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25051
      try {
25052
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25053
      } catch (org.apache.thrift.TException te) {
25054
        throw new java.io.IOException(te);
25055
      }
25056
    }
25057
 
25058
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25059
      try {
25060
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25061
      } catch (org.apache.thrift.TException te) {
25062
        throw new java.io.IOException(te);
25063
      }
25064
    }
25065
 
25066
  }
25067
 
25068
  public static class getShippingLocations_result implements org.apache.thrift.TBase<getShippingLocations_result, getShippingLocations_result._Fields>, java.io.Serializable, Cloneable   {
25069
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShippingLocations_result");
25070
 
25071
    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);
25072
 
25073
    private List<Warehouse> success; // required
25074
 
25075
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25076
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25077
      SUCCESS((short)0, "success");
25078
 
25079
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25080
 
25081
      static {
25082
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25083
          byName.put(field.getFieldName(), field);
25084
        }
25085
      }
25086
 
25087
      /**
25088
       * Find the _Fields constant that matches fieldId, or null if its not found.
25089
       */
25090
      public static _Fields findByThriftId(int fieldId) {
25091
        switch(fieldId) {
25092
          case 0: // SUCCESS
25093
            return SUCCESS;
25094
          default:
25095
            return null;
25096
        }
25097
      }
25098
 
25099
      /**
25100
       * Find the _Fields constant that matches fieldId, throwing an exception
25101
       * if it is not found.
25102
       */
25103
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25104
        _Fields fields = findByThriftId(fieldId);
25105
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25106
        return fields;
25107
      }
25108
 
25109
      /**
25110
       * Find the _Fields constant that matches name, or null if its not found.
25111
       */
25112
      public static _Fields findByName(String name) {
25113
        return byName.get(name);
25114
      }
25115
 
25116
      private final short _thriftId;
25117
      private final String _fieldName;
25118
 
25119
      _Fields(short thriftId, String fieldName) {
25120
        _thriftId = thriftId;
25121
        _fieldName = fieldName;
25122
      }
25123
 
25124
      public short getThriftFieldId() {
25125
        return _thriftId;
25126
      }
25127
 
25128
      public String getFieldName() {
25129
        return _fieldName;
25130
      }
25131
    }
25132
 
25133
    // isset id assignments
25134
 
25135
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25136
    static {
25137
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25138
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
25139
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
25140
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Warehouse.class))));
25141
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25142
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShippingLocations_result.class, metaDataMap);
25143
    }
25144
 
25145
    public getShippingLocations_result() {
25146
    }
25147
 
25148
    public getShippingLocations_result(
25149
      List<Warehouse> success)
25150
    {
25151
      this();
25152
      this.success = success;
25153
    }
25154
 
25155
    /**
25156
     * Performs a deep copy on <i>other</i>.
25157
     */
25158
    public getShippingLocations_result(getShippingLocations_result other) {
25159
      if (other.isSetSuccess()) {
25160
        List<Warehouse> __this__success = new ArrayList<Warehouse>();
25161
        for (Warehouse other_element : other.success) {
25162
          __this__success.add(new Warehouse(other_element));
25163
        }
25164
        this.success = __this__success;
25165
      }
25166
    }
25167
 
25168
    public getShippingLocations_result deepCopy() {
25169
      return new getShippingLocations_result(this);
25170
    }
25171
 
25172
    @Override
25173
    public void clear() {
25174
      this.success = null;
25175
    }
25176
 
25177
    public int getSuccessSize() {
25178
      return (this.success == null) ? 0 : this.success.size();
25179
    }
25180
 
25181
    public java.util.Iterator<Warehouse> getSuccessIterator() {
25182
      return (this.success == null) ? null : this.success.iterator();
25183
    }
25184
 
25185
    public void addToSuccess(Warehouse elem) {
25186
      if (this.success == null) {
25187
        this.success = new ArrayList<Warehouse>();
25188
      }
25189
      this.success.add(elem);
25190
    }
25191
 
25192
    public List<Warehouse> getSuccess() {
25193
      return this.success;
25194
    }
25195
 
25196
    public void setSuccess(List<Warehouse> success) {
25197
      this.success = success;
25198
    }
25199
 
25200
    public void unsetSuccess() {
25201
      this.success = null;
25202
    }
25203
 
25204
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
25205
    public boolean isSetSuccess() {
25206
      return this.success != null;
25207
    }
25208
 
25209
    public void setSuccessIsSet(boolean value) {
25210
      if (!value) {
25211
        this.success = null;
25212
      }
25213
    }
25214
 
25215
    public void setFieldValue(_Fields field, Object value) {
25216
      switch (field) {
25217
      case SUCCESS:
25218
        if (value == null) {
25219
          unsetSuccess();
25220
        } else {
25221
          setSuccess((List<Warehouse>)value);
25222
        }
25223
        break;
25224
 
25225
      }
25226
    }
25227
 
25228
    public Object getFieldValue(_Fields field) {
25229
      switch (field) {
25230
      case SUCCESS:
25231
        return getSuccess();
25232
 
25233
      }
25234
      throw new IllegalStateException();
25235
    }
25236
 
25237
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25238
    public boolean isSet(_Fields field) {
25239
      if (field == null) {
25240
        throw new IllegalArgumentException();
25241
      }
25242
 
25243
      switch (field) {
25244
      case SUCCESS:
25245
        return isSetSuccess();
25246
      }
25247
      throw new IllegalStateException();
25248
    }
25249
 
25250
    @Override
25251
    public boolean equals(Object that) {
25252
      if (that == null)
25253
        return false;
25254
      if (that instanceof getShippingLocations_result)
25255
        return this.equals((getShippingLocations_result)that);
25256
      return false;
25257
    }
25258
 
25259
    public boolean equals(getShippingLocations_result that) {
25260
      if (that == null)
25261
        return false;
25262
 
25263
      boolean this_present_success = true && this.isSetSuccess();
25264
      boolean that_present_success = true && that.isSetSuccess();
25265
      if (this_present_success || that_present_success) {
25266
        if (!(this_present_success && that_present_success))
25267
          return false;
25268
        if (!this.success.equals(that.success))
25269
          return false;
25270
      }
25271
 
25272
      return true;
25273
    }
25274
 
25275
    @Override
25276
    public int hashCode() {
25277
      return 0;
25278
    }
25279
 
25280
    public int compareTo(getShippingLocations_result other) {
25281
      if (!getClass().equals(other.getClass())) {
25282
        return getClass().getName().compareTo(other.getClass().getName());
25283
      }
25284
 
25285
      int lastComparison = 0;
25286
      getShippingLocations_result typedOther = (getShippingLocations_result)other;
25287
 
25288
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
25289
      if (lastComparison != 0) {
25290
        return lastComparison;
25291
      }
25292
      if (isSetSuccess()) {
25293
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
25294
        if (lastComparison != 0) {
25295
          return lastComparison;
25296
        }
25297
      }
25298
      return 0;
25299
    }
25300
 
25301
    public _Fields fieldForId(int fieldId) {
25302
      return _Fields.findByThriftId(fieldId);
25303
    }
25304
 
25305
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25306
      org.apache.thrift.protocol.TField field;
25307
      iprot.readStructBegin();
25308
      while (true)
25309
      {
25310
        field = iprot.readFieldBegin();
25311
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25312
          break;
25313
        }
25314
        switch (field.id) {
25315
          case 0: // SUCCESS
25316
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
25317
              {
25318
                org.apache.thrift.protocol.TList _list66 = iprot.readListBegin();
25319
                this.success = new ArrayList<Warehouse>(_list66.size);
25320
                for (int _i67 = 0; _i67 < _list66.size; ++_i67)
25321
                {
25322
                  Warehouse _elem68; // required
25323
                  _elem68 = new Warehouse();
25324
                  _elem68.read(iprot);
25325
                  this.success.add(_elem68);
25326
                }
25327
                iprot.readListEnd();
25328
              }
25329
            } else { 
25330
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25331
            }
25332
            break;
25333
          default:
25334
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25335
        }
25336
        iprot.readFieldEnd();
25337
      }
25338
      iprot.readStructEnd();
25339
      validate();
25340
    }
25341
 
25342
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25343
      oprot.writeStructBegin(STRUCT_DESC);
25344
 
25345
      if (this.isSetSuccess()) {
25346
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
25347
        {
25348
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
25349
          for (Warehouse _iter69 : this.success)
25350
          {
25351
            _iter69.write(oprot);
25352
          }
25353
          oprot.writeListEnd();
25354
        }
25355
        oprot.writeFieldEnd();
25356
      }
25357
      oprot.writeFieldStop();
25358
      oprot.writeStructEnd();
25359
    }
25360
 
25361
    @Override
25362
    public String toString() {
25363
      StringBuilder sb = new StringBuilder("getShippingLocations_result(");
25364
      boolean first = true;
25365
 
25366
      sb.append("success:");
25367
      if (this.success == null) {
25368
        sb.append("null");
25369
      } else {
25370
        sb.append(this.success);
25371
      }
25372
      first = false;
25373
      sb.append(")");
25374
      return sb.toString();
25375
    }
25376
 
25377
    public void validate() throws org.apache.thrift.TException {
25378
      // check for required fields
25379
    }
25380
 
25381
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25382
      try {
25383
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25384
      } catch (org.apache.thrift.TException te) {
25385
        throw new java.io.IOException(te);
25386
      }
25387
    }
25388
 
25389
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25390
      try {
25391
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25392
      } catch (org.apache.thrift.TException te) {
25393
        throw new java.io.IOException(te);
25394
      }
25395
    }
25396
 
25397
  }
25398
 
25399
  public static class getAllVendorItemMappings_args implements org.apache.thrift.TBase<getAllVendorItemMappings_args, getAllVendorItemMappings_args._Fields>, java.io.Serializable, Cloneable   {
25400
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendorItemMappings_args");
25401
 
25402
 
25403
 
25404
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25405
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25406
;
25407
 
25408
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25409
 
25410
      static {
25411
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25412
          byName.put(field.getFieldName(), field);
25413
        }
25414
      }
25415
 
25416
      /**
25417
       * Find the _Fields constant that matches fieldId, or null if its not found.
25418
       */
25419
      public static _Fields findByThriftId(int fieldId) {
25420
        switch(fieldId) {
25421
          default:
25422
            return null;
25423
        }
25424
      }
25425
 
25426
      /**
25427
       * Find the _Fields constant that matches fieldId, throwing an exception
25428
       * if it is not found.
25429
       */
25430
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25431
        _Fields fields = findByThriftId(fieldId);
25432
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25433
        return fields;
25434
      }
25435
 
25436
      /**
25437
       * Find the _Fields constant that matches name, or null if its not found.
25438
       */
25439
      public static _Fields findByName(String name) {
25440
        return byName.get(name);
25441
      }
25442
 
25443
      private final short _thriftId;
25444
      private final String _fieldName;
25445
 
25446
      _Fields(short thriftId, String fieldName) {
25447
        _thriftId = thriftId;
25448
        _fieldName = fieldName;
25449
      }
25450
 
25451
      public short getThriftFieldId() {
25452
        return _thriftId;
25453
      }
25454
 
25455
      public String getFieldName() {
25456
        return _fieldName;
25457
      }
25458
    }
25459
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25460
    static {
25461
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25462
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25463
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendorItemMappings_args.class, metaDataMap);
25464
    }
25465
 
25466
    public getAllVendorItemMappings_args() {
25467
    }
25468
 
25469
    /**
25470
     * Performs a deep copy on <i>other</i>.
25471
     */
25472
    public getAllVendorItemMappings_args(getAllVendorItemMappings_args other) {
25473
    }
25474
 
25475
    public getAllVendorItemMappings_args deepCopy() {
25476
      return new getAllVendorItemMappings_args(this);
25477
    }
25478
 
25479
    @Override
25480
    public void clear() {
25481
    }
25482
 
25483
    public void setFieldValue(_Fields field, Object value) {
25484
      switch (field) {
25485
      }
25486
    }
25487
 
25488
    public Object getFieldValue(_Fields field) {
25489
      switch (field) {
25490
      }
25491
      throw new IllegalStateException();
25492
    }
25493
 
25494
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25495
    public boolean isSet(_Fields field) {
25496
      if (field == null) {
25497
        throw new IllegalArgumentException();
25498
      }
25499
 
25500
      switch (field) {
25501
      }
25502
      throw new IllegalStateException();
25503
    }
25504
 
25505
    @Override
25506
    public boolean equals(Object that) {
25507
      if (that == null)
25508
        return false;
25509
      if (that instanceof getAllVendorItemMappings_args)
25510
        return this.equals((getAllVendorItemMappings_args)that);
25511
      return false;
25512
    }
25513
 
25514
    public boolean equals(getAllVendorItemMappings_args that) {
25515
      if (that == null)
25516
        return false;
25517
 
25518
      return true;
25519
    }
25520
 
25521
    @Override
25522
    public int hashCode() {
25523
      return 0;
25524
    }
25525
 
25526
    public int compareTo(getAllVendorItemMappings_args other) {
25527
      if (!getClass().equals(other.getClass())) {
25528
        return getClass().getName().compareTo(other.getClass().getName());
25529
      }
25530
 
25531
      int lastComparison = 0;
25532
      getAllVendorItemMappings_args typedOther = (getAllVendorItemMappings_args)other;
25533
 
25534
      return 0;
25535
    }
25536
 
25537
    public _Fields fieldForId(int fieldId) {
25538
      return _Fields.findByThriftId(fieldId);
25539
    }
25540
 
25541
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25542
      org.apache.thrift.protocol.TField field;
25543
      iprot.readStructBegin();
25544
      while (true)
25545
      {
25546
        field = iprot.readFieldBegin();
25547
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25548
          break;
25549
        }
25550
        switch (field.id) {
25551
          default:
25552
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25553
        }
25554
        iprot.readFieldEnd();
25555
      }
25556
      iprot.readStructEnd();
25557
      validate();
25558
    }
25559
 
25560
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25561
      validate();
25562
 
25563
      oprot.writeStructBegin(STRUCT_DESC);
25564
      oprot.writeFieldStop();
25565
      oprot.writeStructEnd();
25566
    }
25567
 
25568
    @Override
25569
    public String toString() {
25570
      StringBuilder sb = new StringBuilder("getAllVendorItemMappings_args(");
25571
      boolean first = true;
25572
 
25573
      sb.append(")");
25574
      return sb.toString();
25575
    }
25576
 
25577
    public void validate() throws org.apache.thrift.TException {
25578
      // check for required fields
25579
    }
25580
 
25581
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25582
      try {
25583
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25584
      } catch (org.apache.thrift.TException te) {
25585
        throw new java.io.IOException(te);
25586
      }
25587
    }
25588
 
25589
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25590
      try {
25591
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25592
      } catch (org.apache.thrift.TException te) {
25593
        throw new java.io.IOException(te);
25594
      }
25595
    }
25596
 
25597
  }
25598
 
25599
  public static class getAllVendorItemMappings_result implements org.apache.thrift.TBase<getAllVendorItemMappings_result, getAllVendorItemMappings_result._Fields>, java.io.Serializable, Cloneable   {
25600
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllVendorItemMappings_result");
25601
 
25602
    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);
25603
 
25604
    private List<VendorItemMapping> success; // required
25605
 
25606
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25607
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25608
      SUCCESS((short)0, "success");
25609
 
25610
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25611
 
25612
      static {
25613
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25614
          byName.put(field.getFieldName(), field);
25615
        }
25616
      }
25617
 
25618
      /**
25619
       * Find the _Fields constant that matches fieldId, or null if its not found.
25620
       */
25621
      public static _Fields findByThriftId(int fieldId) {
25622
        switch(fieldId) {
25623
          case 0: // SUCCESS
25624
            return SUCCESS;
25625
          default:
25626
            return null;
25627
        }
25628
      }
25629
 
25630
      /**
25631
       * Find the _Fields constant that matches fieldId, throwing an exception
25632
       * if it is not found.
25633
       */
25634
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25635
        _Fields fields = findByThriftId(fieldId);
25636
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25637
        return fields;
25638
      }
25639
 
25640
      /**
25641
       * Find the _Fields constant that matches name, or null if its not found.
25642
       */
25643
      public static _Fields findByName(String name) {
25644
        return byName.get(name);
25645
      }
25646
 
25647
      private final short _thriftId;
25648
      private final String _fieldName;
25649
 
25650
      _Fields(short thriftId, String fieldName) {
25651
        _thriftId = thriftId;
25652
        _fieldName = fieldName;
25653
      }
25654
 
25655
      public short getThriftFieldId() {
25656
        return _thriftId;
25657
      }
25658
 
25659
      public String getFieldName() {
25660
        return _fieldName;
25661
      }
25662
    }
25663
 
25664
    // isset id assignments
25665
 
25666
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
25667
    static {
25668
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
25669
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
25670
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
25671
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, VendorItemMapping.class))));
25672
      metaDataMap = Collections.unmodifiableMap(tmpMap);
25673
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllVendorItemMappings_result.class, metaDataMap);
25674
    }
25675
 
25676
    public getAllVendorItemMappings_result() {
25677
    }
25678
 
25679
    public getAllVendorItemMappings_result(
25680
      List<VendorItemMapping> success)
25681
    {
25682
      this();
25683
      this.success = success;
25684
    }
25685
 
25686
    /**
25687
     * Performs a deep copy on <i>other</i>.
25688
     */
25689
    public getAllVendorItemMappings_result(getAllVendorItemMappings_result other) {
25690
      if (other.isSetSuccess()) {
25691
        List<VendorItemMapping> __this__success = new ArrayList<VendorItemMapping>();
25692
        for (VendorItemMapping other_element : other.success) {
25693
          __this__success.add(new VendorItemMapping(other_element));
25694
        }
25695
        this.success = __this__success;
25696
      }
25697
    }
25698
 
25699
    public getAllVendorItemMappings_result deepCopy() {
25700
      return new getAllVendorItemMappings_result(this);
25701
    }
25702
 
25703
    @Override
25704
    public void clear() {
25705
      this.success = null;
25706
    }
25707
 
25708
    public int getSuccessSize() {
25709
      return (this.success == null) ? 0 : this.success.size();
25710
    }
25711
 
25712
    public java.util.Iterator<VendorItemMapping> getSuccessIterator() {
25713
      return (this.success == null) ? null : this.success.iterator();
25714
    }
25715
 
25716
    public void addToSuccess(VendorItemMapping elem) {
25717
      if (this.success == null) {
25718
        this.success = new ArrayList<VendorItemMapping>();
25719
      }
25720
      this.success.add(elem);
25721
    }
25722
 
25723
    public List<VendorItemMapping> getSuccess() {
25724
      return this.success;
25725
    }
25726
 
25727
    public void setSuccess(List<VendorItemMapping> success) {
25728
      this.success = success;
25729
    }
25730
 
25731
    public void unsetSuccess() {
25732
      this.success = null;
25733
    }
25734
 
25735
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
25736
    public boolean isSetSuccess() {
25737
      return this.success != null;
25738
    }
25739
 
25740
    public void setSuccessIsSet(boolean value) {
25741
      if (!value) {
25742
        this.success = null;
25743
      }
25744
    }
25745
 
25746
    public void setFieldValue(_Fields field, Object value) {
25747
      switch (field) {
25748
      case SUCCESS:
25749
        if (value == null) {
25750
          unsetSuccess();
25751
        } else {
25752
          setSuccess((List<VendorItemMapping>)value);
25753
        }
25754
        break;
25755
 
25756
      }
25757
    }
25758
 
25759
    public Object getFieldValue(_Fields field) {
25760
      switch (field) {
25761
      case SUCCESS:
25762
        return getSuccess();
25763
 
25764
      }
25765
      throw new IllegalStateException();
25766
    }
25767
 
25768
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
25769
    public boolean isSet(_Fields field) {
25770
      if (field == null) {
25771
        throw new IllegalArgumentException();
25772
      }
25773
 
25774
      switch (field) {
25775
      case SUCCESS:
25776
        return isSetSuccess();
25777
      }
25778
      throw new IllegalStateException();
25779
    }
25780
 
25781
    @Override
25782
    public boolean equals(Object that) {
25783
      if (that == null)
25784
        return false;
25785
      if (that instanceof getAllVendorItemMappings_result)
25786
        return this.equals((getAllVendorItemMappings_result)that);
25787
      return false;
25788
    }
25789
 
25790
    public boolean equals(getAllVendorItemMappings_result that) {
25791
      if (that == null)
25792
        return false;
25793
 
25794
      boolean this_present_success = true && this.isSetSuccess();
25795
      boolean that_present_success = true && that.isSetSuccess();
25796
      if (this_present_success || that_present_success) {
25797
        if (!(this_present_success && that_present_success))
25798
          return false;
25799
        if (!this.success.equals(that.success))
25800
          return false;
25801
      }
25802
 
25803
      return true;
25804
    }
25805
 
25806
    @Override
25807
    public int hashCode() {
25808
      return 0;
25809
    }
25810
 
25811
    public int compareTo(getAllVendorItemMappings_result other) {
25812
      if (!getClass().equals(other.getClass())) {
25813
        return getClass().getName().compareTo(other.getClass().getName());
25814
      }
25815
 
25816
      int lastComparison = 0;
25817
      getAllVendorItemMappings_result typedOther = (getAllVendorItemMappings_result)other;
25818
 
25819
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
25820
      if (lastComparison != 0) {
25821
        return lastComparison;
25822
      }
25823
      if (isSetSuccess()) {
25824
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
25825
        if (lastComparison != 0) {
25826
          return lastComparison;
25827
        }
25828
      }
25829
      return 0;
25830
    }
25831
 
25832
    public _Fields fieldForId(int fieldId) {
25833
      return _Fields.findByThriftId(fieldId);
25834
    }
25835
 
25836
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
25837
      org.apache.thrift.protocol.TField field;
25838
      iprot.readStructBegin();
25839
      while (true)
25840
      {
25841
        field = iprot.readFieldBegin();
25842
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
25843
          break;
25844
        }
25845
        switch (field.id) {
25846
          case 0: // SUCCESS
25847
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
25848
              {
25849
                org.apache.thrift.protocol.TList _list70 = iprot.readListBegin();
25850
                this.success = new ArrayList<VendorItemMapping>(_list70.size);
25851
                for (int _i71 = 0; _i71 < _list70.size; ++_i71)
25852
                {
25853
                  VendorItemMapping _elem72; // required
25854
                  _elem72 = new VendorItemMapping();
25855
                  _elem72.read(iprot);
25856
                  this.success.add(_elem72);
25857
                }
25858
                iprot.readListEnd();
25859
              }
25860
            } else { 
25861
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25862
            }
25863
            break;
25864
          default:
25865
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
25866
        }
25867
        iprot.readFieldEnd();
25868
      }
25869
      iprot.readStructEnd();
25870
      validate();
25871
    }
25872
 
25873
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
25874
      oprot.writeStructBegin(STRUCT_DESC);
25875
 
25876
      if (this.isSetSuccess()) {
25877
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
25878
        {
25879
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
25880
          for (VendorItemMapping _iter73 : this.success)
25881
          {
25882
            _iter73.write(oprot);
25883
          }
25884
          oprot.writeListEnd();
25885
        }
25886
        oprot.writeFieldEnd();
25887
      }
25888
      oprot.writeFieldStop();
25889
      oprot.writeStructEnd();
25890
    }
25891
 
25892
    @Override
25893
    public String toString() {
25894
      StringBuilder sb = new StringBuilder("getAllVendorItemMappings_result(");
25895
      boolean first = true;
25896
 
25897
      sb.append("success:");
25898
      if (this.success == null) {
25899
        sb.append("null");
25900
      } else {
25901
        sb.append(this.success);
25902
      }
25903
      first = false;
25904
      sb.append(")");
25905
      return sb.toString();
25906
    }
25907
 
25908
    public void validate() throws org.apache.thrift.TException {
25909
      // check for required fields
25910
    }
25911
 
25912
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
25913
      try {
25914
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
25915
      } catch (org.apache.thrift.TException te) {
25916
        throw new java.io.IOException(te);
25917
      }
25918
    }
25919
 
25920
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
25921
      try {
25922
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
25923
      } catch (org.apache.thrift.TException te) {
25924
        throw new java.io.IOException(te);
25925
      }
25926
    }
25927
 
25928
  }
25929
 
25930
  public static class getInventorySnapshot_args implements org.apache.thrift.TBase<getInventorySnapshot_args, getInventorySnapshot_args._Fields>, java.io.Serializable, Cloneable   {
25931
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventorySnapshot_args");
25932
 
25933
    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);
25934
 
25935
    private long warehouseId; // required
25936
 
25937
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
25938
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
25939
      WAREHOUSE_ID((short)1, "warehouseId");
25940
 
25941
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
25942
 
25943
      static {
25944
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
25945
          byName.put(field.getFieldName(), field);
25946
        }
25947
      }
25948
 
25949
      /**
25950
       * Find the _Fields constant that matches fieldId, or null if its not found.
25951
       */
25952
      public static _Fields findByThriftId(int fieldId) {
25953
        switch(fieldId) {
25954
          case 1: // WAREHOUSE_ID
25955
            return WAREHOUSE_ID;
25956
          default:
25957
            return null;
25958
        }
25959
      }
25960
 
25961
      /**
25962
       * Find the _Fields constant that matches fieldId, throwing an exception
25963
       * if it is not found.
25964
       */
25965
      public static _Fields findByThriftIdOrThrow(int fieldId) {
25966
        _Fields fields = findByThriftId(fieldId);
25967
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
25968
        return fields;
25969
      }
25970
 
25971
      /**
25972
       * Find the _Fields constant that matches name, or null if its not found.
25973
       */
25974
      public static _Fields findByName(String name) {
25975
        return byName.get(name);
25976
      }
25977
 
25978
      private final short _thriftId;
25979
      private final String _fieldName;
25980
 
25981
      _Fields(short thriftId, String fieldName) {
25982
        _thriftId = thriftId;
25983
        _fieldName = fieldName;
25984
      }
25985
 
25986
      public short getThriftFieldId() {
25987
        return _thriftId;
25988
      }
25989
 
25990
      public String getFieldName() {
25991
        return _fieldName;
25992
      }
25993
    }
25994
 
25995
    // isset id assignments
25996
    private static final int __WAREHOUSEID_ISSET_ID = 0;
25997
    private BitSet __isset_bit_vector = new BitSet(1);
25998
 
25999
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26000
    static {
26001
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26002
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
26003
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
26004
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26005
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventorySnapshot_args.class, metaDataMap);
26006
    }
26007
 
26008
    public getInventorySnapshot_args() {
26009
    }
26010
 
26011
    public getInventorySnapshot_args(
26012
      long warehouseId)
26013
    {
26014
      this();
26015
      this.warehouseId = warehouseId;
26016
      setWarehouseIdIsSet(true);
26017
    }
26018
 
26019
    /**
26020
     * Performs a deep copy on <i>other</i>.
26021
     */
26022
    public getInventorySnapshot_args(getInventorySnapshot_args other) {
26023
      __isset_bit_vector.clear();
26024
      __isset_bit_vector.or(other.__isset_bit_vector);
26025
      this.warehouseId = other.warehouseId;
26026
    }
26027
 
26028
    public getInventorySnapshot_args deepCopy() {
26029
      return new getInventorySnapshot_args(this);
26030
    }
26031
 
26032
    @Override
26033
    public void clear() {
26034
      setWarehouseIdIsSet(false);
26035
      this.warehouseId = 0;
26036
    }
26037
 
26038
    public long getWarehouseId() {
26039
      return this.warehouseId;
26040
    }
26041
 
26042
    public void setWarehouseId(long warehouseId) {
26043
      this.warehouseId = warehouseId;
26044
      setWarehouseIdIsSet(true);
26045
    }
26046
 
26047
    public void unsetWarehouseId() {
26048
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
26049
    }
26050
 
26051
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
26052
    public boolean isSetWarehouseId() {
26053
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
26054
    }
26055
 
26056
    public void setWarehouseIdIsSet(boolean value) {
26057
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
26058
    }
26059
 
26060
    public void setFieldValue(_Fields field, Object value) {
26061
      switch (field) {
26062
      case WAREHOUSE_ID:
26063
        if (value == null) {
26064
          unsetWarehouseId();
26065
        } else {
26066
          setWarehouseId((Long)value);
26067
        }
26068
        break;
26069
 
26070
      }
26071
    }
26072
 
26073
    public Object getFieldValue(_Fields field) {
26074
      switch (field) {
26075
      case WAREHOUSE_ID:
26076
        return Long.valueOf(getWarehouseId());
26077
 
26078
      }
26079
      throw new IllegalStateException();
26080
    }
26081
 
26082
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26083
    public boolean isSet(_Fields field) {
26084
      if (field == null) {
26085
        throw new IllegalArgumentException();
26086
      }
26087
 
26088
      switch (field) {
26089
      case WAREHOUSE_ID:
26090
        return isSetWarehouseId();
26091
      }
26092
      throw new IllegalStateException();
26093
    }
26094
 
26095
    @Override
26096
    public boolean equals(Object that) {
26097
      if (that == null)
26098
        return false;
26099
      if (that instanceof getInventorySnapshot_args)
26100
        return this.equals((getInventorySnapshot_args)that);
26101
      return false;
26102
    }
26103
 
26104
    public boolean equals(getInventorySnapshot_args that) {
26105
      if (that == null)
26106
        return false;
26107
 
26108
      boolean this_present_warehouseId = true;
26109
      boolean that_present_warehouseId = true;
26110
      if (this_present_warehouseId || that_present_warehouseId) {
26111
        if (!(this_present_warehouseId && that_present_warehouseId))
26112
          return false;
26113
        if (this.warehouseId != that.warehouseId)
26114
          return false;
26115
      }
26116
 
26117
      return true;
26118
    }
26119
 
26120
    @Override
26121
    public int hashCode() {
26122
      return 0;
26123
    }
26124
 
26125
    public int compareTo(getInventorySnapshot_args other) {
26126
      if (!getClass().equals(other.getClass())) {
26127
        return getClass().getName().compareTo(other.getClass().getName());
26128
      }
26129
 
26130
      int lastComparison = 0;
26131
      getInventorySnapshot_args typedOther = (getInventorySnapshot_args)other;
26132
 
26133
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
26134
      if (lastComparison != 0) {
26135
        return lastComparison;
26136
      }
26137
      if (isSetWarehouseId()) {
26138
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
26139
        if (lastComparison != 0) {
26140
          return lastComparison;
26141
        }
26142
      }
26143
      return 0;
26144
    }
26145
 
26146
    public _Fields fieldForId(int fieldId) {
26147
      return _Fields.findByThriftId(fieldId);
26148
    }
26149
 
26150
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26151
      org.apache.thrift.protocol.TField field;
26152
      iprot.readStructBegin();
26153
      while (true)
26154
      {
26155
        field = iprot.readFieldBegin();
26156
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26157
          break;
26158
        }
26159
        switch (field.id) {
26160
          case 1: // WAREHOUSE_ID
26161
            if (field.type == org.apache.thrift.protocol.TType.I64) {
26162
              this.warehouseId = iprot.readI64();
26163
              setWarehouseIdIsSet(true);
26164
            } else { 
26165
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26166
            }
26167
            break;
26168
          default:
26169
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26170
        }
26171
        iprot.readFieldEnd();
26172
      }
26173
      iprot.readStructEnd();
26174
      validate();
26175
    }
26176
 
26177
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26178
      validate();
26179
 
26180
      oprot.writeStructBegin(STRUCT_DESC);
26181
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
26182
      oprot.writeI64(this.warehouseId);
26183
      oprot.writeFieldEnd();
26184
      oprot.writeFieldStop();
26185
      oprot.writeStructEnd();
26186
    }
26187
 
26188
    @Override
26189
    public String toString() {
26190
      StringBuilder sb = new StringBuilder("getInventorySnapshot_args(");
26191
      boolean first = true;
26192
 
26193
      sb.append("warehouseId:");
26194
      sb.append(this.warehouseId);
26195
      first = false;
26196
      sb.append(")");
26197
      return sb.toString();
26198
    }
26199
 
26200
    public void validate() throws org.apache.thrift.TException {
26201
      // check for required fields
26202
    }
26203
 
26204
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26205
      try {
26206
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26207
      } catch (org.apache.thrift.TException te) {
26208
        throw new java.io.IOException(te);
26209
      }
26210
    }
26211
 
26212
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26213
      try {
26214
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
26215
        __isset_bit_vector = new BitSet(1);
26216
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26217
      } catch (org.apache.thrift.TException te) {
26218
        throw new java.io.IOException(te);
26219
      }
26220
    }
26221
 
26222
  }
26223
 
26224
  public static class getInventorySnapshot_result implements org.apache.thrift.TBase<getInventorySnapshot_result, getInventorySnapshot_result._Fields>, java.io.Serializable, Cloneable   {
26225
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getInventorySnapshot_result");
26226
 
26227
    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);
26228
 
26229
    private Map<Long,ItemInventory> success; // required
26230
 
26231
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26232
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26233
      SUCCESS((short)0, "success");
26234
 
26235
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26236
 
26237
      static {
26238
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26239
          byName.put(field.getFieldName(), field);
26240
        }
26241
      }
26242
 
26243
      /**
26244
       * Find the _Fields constant that matches fieldId, or null if its not found.
26245
       */
26246
      public static _Fields findByThriftId(int fieldId) {
26247
        switch(fieldId) {
26248
          case 0: // SUCCESS
26249
            return SUCCESS;
26250
          default:
26251
            return null;
26252
        }
26253
      }
26254
 
26255
      /**
26256
       * Find the _Fields constant that matches fieldId, throwing an exception
26257
       * if it is not found.
26258
       */
26259
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26260
        _Fields fields = findByThriftId(fieldId);
26261
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26262
        return fields;
26263
      }
26264
 
26265
      /**
26266
       * Find the _Fields constant that matches name, or null if its not found.
26267
       */
26268
      public static _Fields findByName(String name) {
26269
        return byName.get(name);
26270
      }
26271
 
26272
      private final short _thriftId;
26273
      private final String _fieldName;
26274
 
26275
      _Fields(short thriftId, String fieldName) {
26276
        _thriftId = thriftId;
26277
        _fieldName = fieldName;
26278
      }
26279
 
26280
      public short getThriftFieldId() {
26281
        return _thriftId;
26282
      }
26283
 
26284
      public String getFieldName() {
26285
        return _fieldName;
26286
      }
26287
    }
26288
 
26289
    // isset id assignments
26290
 
26291
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26292
    static {
26293
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26294
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
26295
          new org.apache.thrift.meta_data.MapMetaData(org.apache.thrift.protocol.TType.MAP, 
26296
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64), 
26297
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, ItemInventory.class))));
26298
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26299
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getInventorySnapshot_result.class, metaDataMap);
26300
    }
26301
 
26302
    public getInventorySnapshot_result() {
26303
    }
26304
 
26305
    public getInventorySnapshot_result(
26306
      Map<Long,ItemInventory> success)
26307
    {
26308
      this();
26309
      this.success = success;
26310
    }
26311
 
26312
    /**
26313
     * Performs a deep copy on <i>other</i>.
26314
     */
26315
    public getInventorySnapshot_result(getInventorySnapshot_result other) {
26316
      if (other.isSetSuccess()) {
26317
        Map<Long,ItemInventory> __this__success = new HashMap<Long,ItemInventory>();
26318
        for (Map.Entry<Long, ItemInventory> other_element : other.success.entrySet()) {
26319
 
26320
          Long other_element_key = other_element.getKey();
26321
          ItemInventory other_element_value = other_element.getValue();
26322
 
26323
          Long __this__success_copy_key = other_element_key;
26324
 
26325
          ItemInventory __this__success_copy_value = new ItemInventory(other_element_value);
26326
 
26327
          __this__success.put(__this__success_copy_key, __this__success_copy_value);
26328
        }
26329
        this.success = __this__success;
26330
      }
26331
    }
26332
 
26333
    public getInventorySnapshot_result deepCopy() {
26334
      return new getInventorySnapshot_result(this);
26335
    }
26336
 
26337
    @Override
26338
    public void clear() {
26339
      this.success = null;
26340
    }
26341
 
26342
    public int getSuccessSize() {
26343
      return (this.success == null) ? 0 : this.success.size();
26344
    }
26345
 
26346
    public void putToSuccess(long key, ItemInventory val) {
26347
      if (this.success == null) {
26348
        this.success = new HashMap<Long,ItemInventory>();
26349
      }
26350
      this.success.put(key, val);
26351
    }
26352
 
26353
    public Map<Long,ItemInventory> getSuccess() {
26354
      return this.success;
26355
    }
26356
 
26357
    public void setSuccess(Map<Long,ItemInventory> success) {
26358
      this.success = success;
26359
    }
26360
 
26361
    public void unsetSuccess() {
26362
      this.success = null;
26363
    }
26364
 
26365
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
26366
    public boolean isSetSuccess() {
26367
      return this.success != null;
26368
    }
26369
 
26370
    public void setSuccessIsSet(boolean value) {
26371
      if (!value) {
26372
        this.success = null;
26373
      }
26374
    }
26375
 
26376
    public void setFieldValue(_Fields field, Object value) {
26377
      switch (field) {
26378
      case SUCCESS:
26379
        if (value == null) {
26380
          unsetSuccess();
26381
        } else {
26382
          setSuccess((Map<Long,ItemInventory>)value);
26383
        }
26384
        break;
26385
 
26386
      }
26387
    }
26388
 
26389
    public Object getFieldValue(_Fields field) {
26390
      switch (field) {
26391
      case SUCCESS:
26392
        return getSuccess();
26393
 
26394
      }
26395
      throw new IllegalStateException();
26396
    }
26397
 
26398
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26399
    public boolean isSet(_Fields field) {
26400
      if (field == null) {
26401
        throw new IllegalArgumentException();
26402
      }
26403
 
26404
      switch (field) {
26405
      case SUCCESS:
26406
        return isSetSuccess();
26407
      }
26408
      throw new IllegalStateException();
26409
    }
26410
 
26411
    @Override
26412
    public boolean equals(Object that) {
26413
      if (that == null)
26414
        return false;
26415
      if (that instanceof getInventorySnapshot_result)
26416
        return this.equals((getInventorySnapshot_result)that);
26417
      return false;
26418
    }
26419
 
26420
    public boolean equals(getInventorySnapshot_result that) {
26421
      if (that == null)
26422
        return false;
26423
 
26424
      boolean this_present_success = true && this.isSetSuccess();
26425
      boolean that_present_success = true && that.isSetSuccess();
26426
      if (this_present_success || that_present_success) {
26427
        if (!(this_present_success && that_present_success))
26428
          return false;
26429
        if (!this.success.equals(that.success))
26430
          return false;
26431
      }
26432
 
26433
      return true;
26434
    }
26435
 
26436
    @Override
26437
    public int hashCode() {
26438
      return 0;
26439
    }
26440
 
26441
    public int compareTo(getInventorySnapshot_result other) {
26442
      if (!getClass().equals(other.getClass())) {
26443
        return getClass().getName().compareTo(other.getClass().getName());
26444
      }
26445
 
26446
      int lastComparison = 0;
26447
      getInventorySnapshot_result typedOther = (getInventorySnapshot_result)other;
26448
 
26449
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
26450
      if (lastComparison != 0) {
26451
        return lastComparison;
26452
      }
26453
      if (isSetSuccess()) {
26454
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
26455
        if (lastComparison != 0) {
26456
          return lastComparison;
26457
        }
26458
      }
26459
      return 0;
26460
    }
26461
 
26462
    public _Fields fieldForId(int fieldId) {
26463
      return _Fields.findByThriftId(fieldId);
26464
    }
26465
 
26466
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26467
      org.apache.thrift.protocol.TField field;
26468
      iprot.readStructBegin();
26469
      while (true)
26470
      {
26471
        field = iprot.readFieldBegin();
26472
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26473
          break;
26474
        }
26475
        switch (field.id) {
26476
          case 0: // SUCCESS
26477
            if (field.type == org.apache.thrift.protocol.TType.MAP) {
26478
              {
26479
                org.apache.thrift.protocol.TMap _map74 = iprot.readMapBegin();
26480
                this.success = new HashMap<Long,ItemInventory>(2*_map74.size);
26481
                for (int _i75 = 0; _i75 < _map74.size; ++_i75)
26482
                {
26483
                  long _key76; // required
26484
                  ItemInventory _val77; // required
26485
                  _key76 = iprot.readI64();
26486
                  _val77 = new ItemInventory();
26487
                  _val77.read(iprot);
26488
                  this.success.put(_key76, _val77);
26489
                }
26490
                iprot.readMapEnd();
26491
              }
26492
            } else { 
26493
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26494
            }
26495
            break;
26496
          default:
26497
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26498
        }
26499
        iprot.readFieldEnd();
26500
      }
26501
      iprot.readStructEnd();
26502
      validate();
26503
    }
26504
 
26505
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26506
      oprot.writeStructBegin(STRUCT_DESC);
26507
 
26508
      if (this.isSetSuccess()) {
26509
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
26510
        {
26511
          oprot.writeMapBegin(new org.apache.thrift.protocol.TMap(org.apache.thrift.protocol.TType.I64, org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
26512
          for (Map.Entry<Long, ItemInventory> _iter78 : this.success.entrySet())
26513
          {
26514
            oprot.writeI64(_iter78.getKey());
26515
            _iter78.getValue().write(oprot);
26516
          }
26517
          oprot.writeMapEnd();
26518
        }
26519
        oprot.writeFieldEnd();
26520
      }
26521
      oprot.writeFieldStop();
26522
      oprot.writeStructEnd();
26523
    }
26524
 
26525
    @Override
26526
    public String toString() {
26527
      StringBuilder sb = new StringBuilder("getInventorySnapshot_result(");
26528
      boolean first = true;
26529
 
26530
      sb.append("success:");
26531
      if (this.success == null) {
26532
        sb.append("null");
26533
      } else {
26534
        sb.append(this.success);
26535
      }
26536
      first = false;
26537
      sb.append(")");
26538
      return sb.toString();
26539
    }
26540
 
26541
    public void validate() throws org.apache.thrift.TException {
26542
      // check for required fields
26543
    }
26544
 
26545
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26546
      try {
26547
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26548
      } catch (org.apache.thrift.TException te) {
26549
        throw new java.io.IOException(te);
26550
      }
26551
    }
26552
 
26553
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26554
      try {
26555
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26556
      } catch (org.apache.thrift.TException te) {
26557
        throw new java.io.IOException(te);
26558
      }
26559
    }
26560
 
26561
  }
26562
 
26563
  public static class clearItemAvailabilityCache_args implements org.apache.thrift.TBase<clearItemAvailabilityCache_args, clearItemAvailabilityCache_args._Fields>, java.io.Serializable, Cloneable   {
26564
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCache_args");
26565
 
26566
 
26567
 
26568
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26569
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26570
;
26571
 
26572
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26573
 
26574
      static {
26575
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26576
          byName.put(field.getFieldName(), field);
26577
        }
26578
      }
26579
 
26580
      /**
26581
       * Find the _Fields constant that matches fieldId, or null if its not found.
26582
       */
26583
      public static _Fields findByThriftId(int fieldId) {
26584
        switch(fieldId) {
26585
          default:
26586
            return null;
26587
        }
26588
      }
26589
 
26590
      /**
26591
       * Find the _Fields constant that matches fieldId, throwing an exception
26592
       * if it is not found.
26593
       */
26594
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26595
        _Fields fields = findByThriftId(fieldId);
26596
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26597
        return fields;
26598
      }
26599
 
26600
      /**
26601
       * Find the _Fields constant that matches name, or null if its not found.
26602
       */
26603
      public static _Fields findByName(String name) {
26604
        return byName.get(name);
26605
      }
26606
 
26607
      private final short _thriftId;
26608
      private final String _fieldName;
26609
 
26610
      _Fields(short thriftId, String fieldName) {
26611
        _thriftId = thriftId;
26612
        _fieldName = fieldName;
26613
      }
26614
 
26615
      public short getThriftFieldId() {
26616
        return _thriftId;
26617
      }
26618
 
26619
      public String getFieldName() {
26620
        return _fieldName;
26621
      }
26622
    }
26623
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26624
    static {
26625
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26626
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26627
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCache_args.class, metaDataMap);
26628
    }
26629
 
26630
    public clearItemAvailabilityCache_args() {
26631
    }
26632
 
26633
    /**
26634
     * Performs a deep copy on <i>other</i>.
26635
     */
26636
    public clearItemAvailabilityCache_args(clearItemAvailabilityCache_args other) {
26637
    }
26638
 
26639
    public clearItemAvailabilityCache_args deepCopy() {
26640
      return new clearItemAvailabilityCache_args(this);
26641
    }
26642
 
26643
    @Override
26644
    public void clear() {
26645
    }
26646
 
26647
    public void setFieldValue(_Fields field, Object value) {
26648
      switch (field) {
26649
      }
26650
    }
26651
 
26652
    public Object getFieldValue(_Fields field) {
26653
      switch (field) {
26654
      }
26655
      throw new IllegalStateException();
26656
    }
26657
 
26658
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26659
    public boolean isSet(_Fields field) {
26660
      if (field == null) {
26661
        throw new IllegalArgumentException();
26662
      }
26663
 
26664
      switch (field) {
26665
      }
26666
      throw new IllegalStateException();
26667
    }
26668
 
26669
    @Override
26670
    public boolean equals(Object that) {
26671
      if (that == null)
26672
        return false;
26673
      if (that instanceof clearItemAvailabilityCache_args)
26674
        return this.equals((clearItemAvailabilityCache_args)that);
26675
      return false;
26676
    }
26677
 
26678
    public boolean equals(clearItemAvailabilityCache_args that) {
26679
      if (that == null)
26680
        return false;
26681
 
26682
      return true;
26683
    }
26684
 
26685
    @Override
26686
    public int hashCode() {
26687
      return 0;
26688
    }
26689
 
26690
    public int compareTo(clearItemAvailabilityCache_args other) {
26691
      if (!getClass().equals(other.getClass())) {
26692
        return getClass().getName().compareTo(other.getClass().getName());
26693
      }
26694
 
26695
      int lastComparison = 0;
26696
      clearItemAvailabilityCache_args typedOther = (clearItemAvailabilityCache_args)other;
26697
 
26698
      return 0;
26699
    }
26700
 
26701
    public _Fields fieldForId(int fieldId) {
26702
      return _Fields.findByThriftId(fieldId);
26703
    }
26704
 
26705
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26706
      org.apache.thrift.protocol.TField field;
26707
      iprot.readStructBegin();
26708
      while (true)
26709
      {
26710
        field = iprot.readFieldBegin();
26711
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26712
          break;
26713
        }
26714
        switch (field.id) {
26715
          default:
26716
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26717
        }
26718
        iprot.readFieldEnd();
26719
      }
26720
      iprot.readStructEnd();
26721
      validate();
26722
    }
26723
 
26724
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26725
      validate();
26726
 
26727
      oprot.writeStructBegin(STRUCT_DESC);
26728
      oprot.writeFieldStop();
26729
      oprot.writeStructEnd();
26730
    }
26731
 
26732
    @Override
26733
    public String toString() {
26734
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCache_args(");
26735
      boolean first = true;
26736
 
26737
      sb.append(")");
26738
      return sb.toString();
26739
    }
26740
 
26741
    public void validate() throws org.apache.thrift.TException {
26742
      // check for required fields
26743
    }
26744
 
26745
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26746
      try {
26747
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26748
      } catch (org.apache.thrift.TException te) {
26749
        throw new java.io.IOException(te);
26750
      }
26751
    }
26752
 
26753
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26754
      try {
26755
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26756
      } catch (org.apache.thrift.TException te) {
26757
        throw new java.io.IOException(te);
26758
      }
26759
    }
26760
 
26761
  }
26762
 
26763
  public static class clearItemAvailabilityCache_result implements org.apache.thrift.TBase<clearItemAvailabilityCache_result, clearItemAvailabilityCache_result._Fields>, java.io.Serializable, Cloneable   {
26764
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("clearItemAvailabilityCache_result");
26765
 
26766
 
26767
 
26768
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26769
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26770
;
26771
 
26772
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26773
 
26774
      static {
26775
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26776
          byName.put(field.getFieldName(), field);
26777
        }
26778
      }
26779
 
26780
      /**
26781
       * Find the _Fields constant that matches fieldId, or null if its not found.
26782
       */
26783
      public static _Fields findByThriftId(int fieldId) {
26784
        switch(fieldId) {
26785
          default:
26786
            return null;
26787
        }
26788
      }
26789
 
26790
      /**
26791
       * Find the _Fields constant that matches fieldId, throwing an exception
26792
       * if it is not found.
26793
       */
26794
      public static _Fields findByThriftIdOrThrow(int fieldId) {
26795
        _Fields fields = findByThriftId(fieldId);
26796
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
26797
        return fields;
26798
      }
26799
 
26800
      /**
26801
       * Find the _Fields constant that matches name, or null if its not found.
26802
       */
26803
      public static _Fields findByName(String name) {
26804
        return byName.get(name);
26805
      }
26806
 
26807
      private final short _thriftId;
26808
      private final String _fieldName;
26809
 
26810
      _Fields(short thriftId, String fieldName) {
26811
        _thriftId = thriftId;
26812
        _fieldName = fieldName;
26813
      }
26814
 
26815
      public short getThriftFieldId() {
26816
        return _thriftId;
26817
      }
26818
 
26819
      public String getFieldName() {
26820
        return _fieldName;
26821
      }
26822
    }
26823
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
26824
    static {
26825
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
26826
      metaDataMap = Collections.unmodifiableMap(tmpMap);
26827
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(clearItemAvailabilityCache_result.class, metaDataMap);
26828
    }
26829
 
26830
    public clearItemAvailabilityCache_result() {
26831
    }
26832
 
26833
    /**
26834
     * Performs a deep copy on <i>other</i>.
26835
     */
26836
    public clearItemAvailabilityCache_result(clearItemAvailabilityCache_result other) {
26837
    }
26838
 
26839
    public clearItemAvailabilityCache_result deepCopy() {
26840
      return new clearItemAvailabilityCache_result(this);
26841
    }
26842
 
26843
    @Override
26844
    public void clear() {
26845
    }
26846
 
26847
    public void setFieldValue(_Fields field, Object value) {
26848
      switch (field) {
26849
      }
26850
    }
26851
 
26852
    public Object getFieldValue(_Fields field) {
26853
      switch (field) {
26854
      }
26855
      throw new IllegalStateException();
26856
    }
26857
 
26858
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
26859
    public boolean isSet(_Fields field) {
26860
      if (field == null) {
26861
        throw new IllegalArgumentException();
26862
      }
26863
 
26864
      switch (field) {
26865
      }
26866
      throw new IllegalStateException();
26867
    }
26868
 
26869
    @Override
26870
    public boolean equals(Object that) {
26871
      if (that == null)
26872
        return false;
26873
      if (that instanceof clearItemAvailabilityCache_result)
26874
        return this.equals((clearItemAvailabilityCache_result)that);
26875
      return false;
26876
    }
26877
 
26878
    public boolean equals(clearItemAvailabilityCache_result that) {
26879
      if (that == null)
26880
        return false;
26881
 
26882
      return true;
26883
    }
26884
 
26885
    @Override
26886
    public int hashCode() {
26887
      return 0;
26888
    }
26889
 
26890
    public int compareTo(clearItemAvailabilityCache_result other) {
26891
      if (!getClass().equals(other.getClass())) {
26892
        return getClass().getName().compareTo(other.getClass().getName());
26893
      }
26894
 
26895
      int lastComparison = 0;
26896
      clearItemAvailabilityCache_result typedOther = (clearItemAvailabilityCache_result)other;
26897
 
26898
      return 0;
26899
    }
26900
 
26901
    public _Fields fieldForId(int fieldId) {
26902
      return _Fields.findByThriftId(fieldId);
26903
    }
26904
 
26905
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
26906
      org.apache.thrift.protocol.TField field;
26907
      iprot.readStructBegin();
26908
      while (true)
26909
      {
26910
        field = iprot.readFieldBegin();
26911
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
26912
          break;
26913
        }
26914
        switch (field.id) {
26915
          default:
26916
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
26917
        }
26918
        iprot.readFieldEnd();
26919
      }
26920
      iprot.readStructEnd();
26921
      validate();
26922
    }
26923
 
26924
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
26925
      oprot.writeStructBegin(STRUCT_DESC);
26926
 
26927
      oprot.writeFieldStop();
26928
      oprot.writeStructEnd();
26929
    }
26930
 
26931
    @Override
26932
    public String toString() {
26933
      StringBuilder sb = new StringBuilder("clearItemAvailabilityCache_result(");
26934
      boolean first = true;
26935
 
26936
      sb.append(")");
26937
      return sb.toString();
26938
    }
26939
 
26940
    public void validate() throws org.apache.thrift.TException {
26941
      // check for required fields
26942
    }
26943
 
26944
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
26945
      try {
26946
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
26947
      } catch (org.apache.thrift.TException te) {
26948
        throw new java.io.IOException(te);
26949
      }
26950
    }
26951
 
26952
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
26953
      try {
26954
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
26955
      } catch (org.apache.thrift.TException te) {
26956
        throw new java.io.IOException(te);
26957
      }
26958
    }
26959
 
26960
  }
26961
 
26962
  public static class updateVendorString_args implements org.apache.thrift.TBase<updateVendorString_args, updateVendorString_args._Fields>, java.io.Serializable, Cloneable   {
26963
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateVendorString_args");
26964
 
26965
    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);
26966
    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);
26967
 
26968
    private long warehouseId; // required
26969
    private String vendorString; // required
26970
 
26971
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
26972
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
26973
      WAREHOUSE_ID((short)1, "warehouseId"),
26974
      VENDOR_STRING((short)2, "vendorString");
26975
 
26976
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
26977
 
26978
      static {
26979
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
26980
          byName.put(field.getFieldName(), field);
26981
        }
26982
      }
26983
 
26984
      /**
26985
       * Find the _Fields constant that matches fieldId, or null if its not found.
26986
       */
26987
      public static _Fields findByThriftId(int fieldId) {
26988
        switch(fieldId) {
26989
          case 1: // WAREHOUSE_ID
26990
            return WAREHOUSE_ID;
26991
          case 2: // VENDOR_STRING
26992
            return VENDOR_STRING;
26993
          default:
26994
            return null;
26995
        }
26996
      }
26997
 
26998
      /**
26999
       * Find the _Fields constant that matches fieldId, throwing an exception
27000
       * if it is not found.
27001
       */
27002
      public static _Fields findByThriftIdOrThrow(int fieldId) {
27003
        _Fields fields = findByThriftId(fieldId);
27004
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
27005
        return fields;
27006
      }
27007
 
27008
      /**
27009
       * Find the _Fields constant that matches name, or null if its not found.
27010
       */
27011
      public static _Fields findByName(String name) {
27012
        return byName.get(name);
27013
      }
27014
 
27015
      private final short _thriftId;
27016
      private final String _fieldName;
27017
 
27018
      _Fields(short thriftId, String fieldName) {
27019
        _thriftId = thriftId;
27020
        _fieldName = fieldName;
27021
      }
27022
 
27023
      public short getThriftFieldId() {
27024
        return _thriftId;
27025
      }
27026
 
27027
      public String getFieldName() {
27028
        return _fieldName;
27029
      }
27030
    }
27031
 
27032
    // isset id assignments
27033
    private static final int __WAREHOUSEID_ISSET_ID = 0;
27034
    private BitSet __isset_bit_vector = new BitSet(1);
27035
 
27036
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
27037
    static {
27038
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
27039
      tmpMap.put(_Fields.WAREHOUSE_ID, new org.apache.thrift.meta_data.FieldMetaData("warehouseId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
27040
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
27041
      tmpMap.put(_Fields.VENDOR_STRING, new org.apache.thrift.meta_data.FieldMetaData("vendorString", org.apache.thrift.TFieldRequirementType.DEFAULT, 
27042
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
27043
      metaDataMap = Collections.unmodifiableMap(tmpMap);
27044
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateVendorString_args.class, metaDataMap);
27045
    }
27046
 
27047
    public updateVendorString_args() {
27048
    }
27049
 
27050
    public updateVendorString_args(
27051
      long warehouseId,
27052
      String vendorString)
27053
    {
27054
      this();
27055
      this.warehouseId = warehouseId;
27056
      setWarehouseIdIsSet(true);
27057
      this.vendorString = vendorString;
27058
    }
27059
 
27060
    /**
27061
     * Performs a deep copy on <i>other</i>.
27062
     */
27063
    public updateVendorString_args(updateVendorString_args other) {
27064
      __isset_bit_vector.clear();
27065
      __isset_bit_vector.or(other.__isset_bit_vector);
27066
      this.warehouseId = other.warehouseId;
27067
      if (other.isSetVendorString()) {
27068
        this.vendorString = other.vendorString;
27069
      }
27070
    }
27071
 
27072
    public updateVendorString_args deepCopy() {
27073
      return new updateVendorString_args(this);
27074
    }
27075
 
27076
    @Override
27077
    public void clear() {
27078
      setWarehouseIdIsSet(false);
27079
      this.warehouseId = 0;
27080
      this.vendorString = null;
27081
    }
27082
 
27083
    public long getWarehouseId() {
27084
      return this.warehouseId;
27085
    }
27086
 
27087
    public void setWarehouseId(long warehouseId) {
27088
      this.warehouseId = warehouseId;
27089
      setWarehouseIdIsSet(true);
27090
    }
27091
 
27092
    public void unsetWarehouseId() {
27093
      __isset_bit_vector.clear(__WAREHOUSEID_ISSET_ID);
27094
    }
27095
 
27096
    /** Returns true if field warehouseId is set (has been assigned a value) and false otherwise */
27097
    public boolean isSetWarehouseId() {
27098
      return __isset_bit_vector.get(__WAREHOUSEID_ISSET_ID);
27099
    }
27100
 
27101
    public void setWarehouseIdIsSet(boolean value) {
27102
      __isset_bit_vector.set(__WAREHOUSEID_ISSET_ID, value);
27103
    }
27104
 
27105
    public String getVendorString() {
27106
      return this.vendorString;
27107
    }
27108
 
27109
    public void setVendorString(String vendorString) {
27110
      this.vendorString = vendorString;
27111
    }
27112
 
27113
    public void unsetVendorString() {
27114
      this.vendorString = null;
27115
    }
27116
 
27117
    /** Returns true if field vendorString is set (has been assigned a value) and false otherwise */
27118
    public boolean isSetVendorString() {
27119
      return this.vendorString != null;
27120
    }
27121
 
27122
    public void setVendorStringIsSet(boolean value) {
27123
      if (!value) {
27124
        this.vendorString = null;
27125
      }
27126
    }
27127
 
27128
    public void setFieldValue(_Fields field, Object value) {
27129
      switch (field) {
27130
      case WAREHOUSE_ID:
27131
        if (value == null) {
27132
          unsetWarehouseId();
27133
        } else {
27134
          setWarehouseId((Long)value);
27135
        }
27136
        break;
27137
 
27138
      case VENDOR_STRING:
27139
        if (value == null) {
27140
          unsetVendorString();
27141
        } else {
27142
          setVendorString((String)value);
27143
        }
27144
        break;
27145
 
27146
      }
27147
    }
27148
 
27149
    public Object getFieldValue(_Fields field) {
27150
      switch (field) {
27151
      case WAREHOUSE_ID:
27152
        return Long.valueOf(getWarehouseId());
27153
 
27154
      case VENDOR_STRING:
27155
        return getVendorString();
27156
 
27157
      }
27158
      throw new IllegalStateException();
27159
    }
27160
 
27161
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
27162
    public boolean isSet(_Fields field) {
27163
      if (field == null) {
27164
        throw new IllegalArgumentException();
27165
      }
27166
 
27167
      switch (field) {
27168
      case WAREHOUSE_ID:
27169
        return isSetWarehouseId();
27170
      case VENDOR_STRING:
27171
        return isSetVendorString();
27172
      }
27173
      throw new IllegalStateException();
27174
    }
27175
 
27176
    @Override
27177
    public boolean equals(Object that) {
27178
      if (that == null)
27179
        return false;
27180
      if (that instanceof updateVendorString_args)
27181
        return this.equals((updateVendorString_args)that);
27182
      return false;
27183
    }
27184
 
27185
    public boolean equals(updateVendorString_args that) {
27186
      if (that == null)
27187
        return false;
27188
 
27189
      boolean this_present_warehouseId = true;
27190
      boolean that_present_warehouseId = true;
27191
      if (this_present_warehouseId || that_present_warehouseId) {
27192
        if (!(this_present_warehouseId && that_present_warehouseId))
27193
          return false;
27194
        if (this.warehouseId != that.warehouseId)
27195
          return false;
27196
      }
27197
 
27198
      boolean this_present_vendorString = true && this.isSetVendorString();
27199
      boolean that_present_vendorString = true && that.isSetVendorString();
27200
      if (this_present_vendorString || that_present_vendorString) {
27201
        if (!(this_present_vendorString && that_present_vendorString))
27202
          return false;
27203
        if (!this.vendorString.equals(that.vendorString))
27204
          return false;
27205
      }
27206
 
27207
      return true;
27208
    }
27209
 
27210
    @Override
27211
    public int hashCode() {
27212
      return 0;
27213
    }
27214
 
27215
    public int compareTo(updateVendorString_args other) {
27216
      if (!getClass().equals(other.getClass())) {
27217
        return getClass().getName().compareTo(other.getClass().getName());
27218
      }
27219
 
27220
      int lastComparison = 0;
27221
      updateVendorString_args typedOther = (updateVendorString_args)other;
27222
 
27223
      lastComparison = Boolean.valueOf(isSetWarehouseId()).compareTo(typedOther.isSetWarehouseId());
27224
      if (lastComparison != 0) {
27225
        return lastComparison;
27226
      }
27227
      if (isSetWarehouseId()) {
27228
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.warehouseId, typedOther.warehouseId);
27229
        if (lastComparison != 0) {
27230
          return lastComparison;
27231
        }
27232
      }
27233
      lastComparison = Boolean.valueOf(isSetVendorString()).compareTo(typedOther.isSetVendorString());
27234
      if (lastComparison != 0) {
27235
        return lastComparison;
27236
      }
27237
      if (isSetVendorString()) {
27238
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.vendorString, typedOther.vendorString);
27239
        if (lastComparison != 0) {
27240
          return lastComparison;
27241
        }
27242
      }
27243
      return 0;
27244
    }
27245
 
27246
    public _Fields fieldForId(int fieldId) {
27247
      return _Fields.findByThriftId(fieldId);
27248
    }
27249
 
27250
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
27251
      org.apache.thrift.protocol.TField field;
27252
      iprot.readStructBegin();
27253
      while (true)
27254
      {
27255
        field = iprot.readFieldBegin();
27256
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
27257
          break;
27258
        }
27259
        switch (field.id) {
27260
          case 1: // WAREHOUSE_ID
27261
            if (field.type == org.apache.thrift.protocol.TType.I64) {
27262
              this.warehouseId = iprot.readI64();
27263
              setWarehouseIdIsSet(true);
27264
            } else { 
27265
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27266
            }
27267
            break;
27268
          case 2: // VENDOR_STRING
27269
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
27270
              this.vendorString = iprot.readString();
27271
            } else { 
27272
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27273
            }
27274
            break;
27275
          default:
27276
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27277
        }
27278
        iprot.readFieldEnd();
27279
      }
27280
      iprot.readStructEnd();
27281
      validate();
27282
    }
27283
 
27284
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
27285
      validate();
27286
 
27287
      oprot.writeStructBegin(STRUCT_DESC);
27288
      oprot.writeFieldBegin(WAREHOUSE_ID_FIELD_DESC);
27289
      oprot.writeI64(this.warehouseId);
27290
      oprot.writeFieldEnd();
27291
      if (this.vendorString != null) {
27292
        oprot.writeFieldBegin(VENDOR_STRING_FIELD_DESC);
27293
        oprot.writeString(this.vendorString);
27294
        oprot.writeFieldEnd();
27295
      }
27296
      oprot.writeFieldStop();
27297
      oprot.writeStructEnd();
27298
    }
27299
 
27300
    @Override
27301
    public String toString() {
27302
      StringBuilder sb = new StringBuilder("updateVendorString_args(");
27303
      boolean first = true;
27304
 
27305
      sb.append("warehouseId:");
27306
      sb.append(this.warehouseId);
27307
      first = false;
27308
      if (!first) sb.append(", ");
27309
      sb.append("vendorString:");
27310
      if (this.vendorString == null) {
27311
        sb.append("null");
27312
      } else {
27313
        sb.append(this.vendorString);
27314
      }
27315
      first = false;
27316
      sb.append(")");
27317
      return sb.toString();
27318
    }
27319
 
27320
    public void validate() throws org.apache.thrift.TException {
27321
      // check for required fields
27322
    }
27323
 
27324
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
27325
      try {
27326
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
27327
      } catch (org.apache.thrift.TException te) {
27328
        throw new java.io.IOException(te);
27329
      }
27330
    }
27331
 
27332
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
27333
      try {
5967 rajveer 27334
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
27335
        __isset_bit_vector = new BitSet(1);
5945 mandeep.dh 27336
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
27337
      } catch (org.apache.thrift.TException te) {
27338
        throw new java.io.IOException(te);
27339
      }
27340
    }
27341
 
27342
  }
27343
 
27344
  public static class updateVendorString_result implements org.apache.thrift.TBase<updateVendorString_result, updateVendorString_result._Fields>, java.io.Serializable, Cloneable   {
27345
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("updateVendorString_result");
27346
 
27347
 
27348
 
27349
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
27350
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
27351
;
27352
 
27353
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
27354
 
27355
      static {
27356
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
27357
          byName.put(field.getFieldName(), field);
27358
        }
27359
      }
27360
 
27361
      /**
27362
       * Find the _Fields constant that matches fieldId, or null if its not found.
27363
       */
27364
      public static _Fields findByThriftId(int fieldId) {
27365
        switch(fieldId) {
27366
          default:
27367
            return null;
27368
        }
27369
      }
27370
 
27371
      /**
27372
       * Find the _Fields constant that matches fieldId, throwing an exception
27373
       * if it is not found.
27374
       */
27375
      public static _Fields findByThriftIdOrThrow(int fieldId) {
27376
        _Fields fields = findByThriftId(fieldId);
27377
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
27378
        return fields;
27379
      }
27380
 
27381
      /**
27382
       * Find the _Fields constant that matches name, or null if its not found.
27383
       */
27384
      public static _Fields findByName(String name) {
27385
        return byName.get(name);
27386
      }
27387
 
27388
      private final short _thriftId;
27389
      private final String _fieldName;
27390
 
27391
      _Fields(short thriftId, String fieldName) {
27392
        _thriftId = thriftId;
27393
        _fieldName = fieldName;
27394
      }
27395
 
27396
      public short getThriftFieldId() {
27397
        return _thriftId;
27398
      }
27399
 
27400
      public String getFieldName() {
27401
        return _fieldName;
27402
      }
27403
    }
27404
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
27405
    static {
27406
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
27407
      metaDataMap = Collections.unmodifiableMap(tmpMap);
27408
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(updateVendorString_result.class, metaDataMap);
27409
    }
27410
 
27411
    public updateVendorString_result() {
27412
    }
27413
 
27414
    /**
27415
     * Performs a deep copy on <i>other</i>.
27416
     */
27417
    public updateVendorString_result(updateVendorString_result other) {
27418
    }
27419
 
27420
    public updateVendorString_result deepCopy() {
27421
      return new updateVendorString_result(this);
27422
    }
27423
 
27424
    @Override
27425
    public void clear() {
27426
    }
27427
 
27428
    public void setFieldValue(_Fields field, Object value) {
27429
      switch (field) {
27430
      }
27431
    }
27432
 
27433
    public Object getFieldValue(_Fields field) {
27434
      switch (field) {
27435
      }
27436
      throw new IllegalStateException();
27437
    }
27438
 
27439
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
27440
    public boolean isSet(_Fields field) {
27441
      if (field == null) {
27442
        throw new IllegalArgumentException();
27443
      }
27444
 
27445
      switch (field) {
27446
      }
27447
      throw new IllegalStateException();
27448
    }
27449
 
27450
    @Override
27451
    public boolean equals(Object that) {
27452
      if (that == null)
27453
        return false;
27454
      if (that instanceof updateVendorString_result)
27455
        return this.equals((updateVendorString_result)that);
27456
      return false;
27457
    }
27458
 
27459
    public boolean equals(updateVendorString_result that) {
27460
      if (that == null)
27461
        return false;
27462
 
27463
      return true;
27464
    }
27465
 
27466
    @Override
27467
    public int hashCode() {
27468
      return 0;
27469
    }
27470
 
27471
    public int compareTo(updateVendorString_result other) {
27472
      if (!getClass().equals(other.getClass())) {
27473
        return getClass().getName().compareTo(other.getClass().getName());
27474
      }
27475
 
27476
      int lastComparison = 0;
27477
      updateVendorString_result typedOther = (updateVendorString_result)other;
27478
 
27479
      return 0;
27480
    }
27481
 
27482
    public _Fields fieldForId(int fieldId) {
27483
      return _Fields.findByThriftId(fieldId);
27484
    }
27485
 
27486
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
27487
      org.apache.thrift.protocol.TField field;
27488
      iprot.readStructBegin();
27489
      while (true)
27490
      {
27491
        field = iprot.readFieldBegin();
27492
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
27493
          break;
27494
        }
27495
        switch (field.id) {
27496
          default:
27497
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
27498
        }
27499
        iprot.readFieldEnd();
27500
      }
27501
      iprot.readStructEnd();
27502
      validate();
27503
    }
27504
 
27505
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
27506
      oprot.writeStructBegin(STRUCT_DESC);
27507
 
27508
      oprot.writeFieldStop();
27509
      oprot.writeStructEnd();
27510
    }
27511
 
27512
    @Override
27513
    public String toString() {
27514
      StringBuilder sb = new StringBuilder("updateVendorString_result(");
27515
      boolean first = true;
27516
 
27517
      sb.append(")");
27518
      return sb.toString();
27519
    }
27520
 
27521
    public void validate() throws org.apache.thrift.TException {
27522
      // check for required fields
27523
    }
27524
 
27525
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
27526
      try {
27527
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
27528
      } catch (org.apache.thrift.TException te) {
27529
        throw new java.io.IOException(te);
27530
      }
27531
    }
27532
 
27533
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
27534
      try {
27535
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
27536
      } catch (org.apache.thrift.TException te) {
27537
        throw new java.io.IOException(te);
27538
      }
27539
    }
27540
 
27541
  }
27542
 
27543
}