Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
412 ashish 1
/**
3430 rajveer 2
 * Autogenerated by Thrift Compiler (0.7.0)
412 ashish 3
 *
4
 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5
 */
6
package in.shop2020.logistics;
7
 
8
import java.util.List;
9
import java.util.ArrayList;
10
import java.util.Map;
11
import java.util.HashMap;
12
import java.util.EnumMap;
13
import java.util.Set;
14
import java.util.HashSet;
15
import java.util.EnumSet;
16
import java.util.Collections;
17
import java.util.BitSet;
3430 rajveer 18
import java.nio.ByteBuffer;
412 ashish 19
import java.util.Arrays;
20
import org.slf4j.Logger;
21
import org.slf4j.LoggerFactory;
22
 
23
public class LogisticsService {
24
 
3374 rajveer 25
  public interface Iface extends in.shop2020.generic.GenericService.Iface {
412 ashish 26
 
648 chandransh 27
    /**
668 chandransh 28
     * Returns a provider for a given provider ID. Throws an exception if none found.
29
     * 
30
     * @param providerId
31
     */
3430 rajveer 32
    public Provider getProvider(long providerId) throws LogisticsServiceException, org.apache.thrift.TException;
668 chandransh 33
 
34
    /**
674 chandransh 35
     * Returns a list containing all the providers.
36
     */
3430 rajveer 37
    public List<Provider> getAllProviders() throws LogisticsServiceException, org.apache.thrift.TException;
674 chandransh 38
 
39
    /**
648 chandransh 40
     * Returns a LogisticsInfo structure w/o an airway bill number. Use this method during the estimation phase.
41
     * Raises an exception if this pincode is not allocated to any warehouse zone or provider. Also, if the pincode
42
     * is allocated to a warehouse zone but there are no actual warehouses in that zone, an exception is raised.
43
     * 
44
     * @param itemId
45
     * @param destination_pin
4630 mandeep.dh 46
     * @param type
648 chandransh 47
     */
4630 mandeep.dh 48
    public LogisticsInfo getLogisticsEstimation(long itemId, String destination_pin, DeliveryType type) throws LogisticsServiceException, org.apache.thrift.TException;
483 rajveer 49
 
648 chandransh 50
    /**
51
     * Same as above excpet that an airway bill number is also allocated and returned.
52
     * 
53
     * @param destination_pincode
54
     * @param item_id
3044 chandransh 55
     * @param type
648 chandransh 56
     */
3430 rajveer 57
    public LogisticsInfo getLogisticsInfo(String destination_pincode, long item_id, DeliveryType type) throws LogisticsServiceException, org.apache.thrift.TException;
471 rajveer 58
 
648 chandransh 59
    /**
60
     * Returns an unused AWB number for the given provider.
61
     * 
62
     * @param providerId
5247 rajveer 63
     * @param type
648 chandransh 64
     */
5247 rajveer 65
    public String getEmptyAWB(long providerId, DeliveryType type) throws LogisticsServiceException, org.apache.thrift.TException;
471 rajveer 66
 
648 chandransh 67
    /**
68
     * Returns the list of updates for the given AWB number and provider id. The list is empty if there are no updates yet.
69
     * 
70
     * @param awb
71
     * @param providerId
72
     */
3430 rajveer 73
    public List<AwbUpdate> getShipmentInfo(String awb, long providerId) throws LogisticsServiceException, org.apache.thrift.TException;
477 rajveer 74
 
730 chandransh 75
    /**
76
     * Returns the short three letter code of a pincode for the given provider.
77
     *    Raises an exception if the pin code is not serviced by the given provider.
78
     * 
79
     * @param providerId
80
     * @param pinCode
81
     */
3430 rajveer 82
    public String getDestinationCode(long providerId, String pinCode) throws LogisticsServiceException, org.apache.thrift.TException;
730 chandransh 83
 
1139 chandransh 84
    /**
3103 chandransh 85
     * Returns the number of unused AWB numbers for the given provider of the given type
1139 chandransh 86
     * 
87
     * @param providerId
3103 chandransh 88
     * @param type
1139 chandransh 89
     */
3430 rajveer 90
    public long getFreeAwbCount(long providerId, String type) throws org.apache.thrift.TException;
1139 chandransh 91
 
1730 ankur.sing 92
    /**
93
     * Returns list of Holiday dates between fromDate and toDate (both inclusive)
94
     * fromDate should be passed as milliseconds corresponding to the start of the day.
95
     * If fromDate is passed as -1, fromDate is not considered for filtering
96
     * If toDate is passed as -1, toDate is not considered for filtering
97
     * 
98
     * @param fromDate
99
     * @param toDate
100
     */
3430 rajveer 101
    public List<Long> getHolidays(long fromDate, long toDate) throws org.apache.thrift.TException;
1730 ankur.sing 102
 
4934 amit.gupta 103
    /**
104
     * Returns a LogisticsInfo structure w/o an airway bill number. Use this method during the estimation phase.
105
     * Raises an exception if this pincode is not allocated to any warehouse zone or provider. Also, if the pincode
106
     * is allocated to a warehouse zone but there are no actual warehouses in that zone, an exception is raised.
107
     * 
108
     * @param catalogItemId
109
     * @param destination_pin
110
     * @param type
111
     */
112
    public List<Long> getEntityLogisticsEstimation(long catalogItemId, String destination_pin, DeliveryType type) throws LogisticsServiceException, org.apache.thrift.TException;
113
 
412 ashish 114
  }
115
 
3430 rajveer 116
  public interface AsyncIface extends in.shop2020.generic.GenericService .AsyncIface {
117
 
118
    public void getProvider(long providerId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getProvider_call> resultHandler) throws org.apache.thrift.TException;
119
 
120
    public void getAllProviders(org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getAllProviders_call> resultHandler) throws org.apache.thrift.TException;
121
 
4630 mandeep.dh 122
    public void getLogisticsEstimation(long itemId, String destination_pin, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getLogisticsEstimation_call> resultHandler) throws org.apache.thrift.TException;
3430 rajveer 123
 
124
    public void getLogisticsInfo(String destination_pincode, long item_id, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getLogisticsInfo_call> resultHandler) throws org.apache.thrift.TException;
125
 
5247 rajveer 126
    public void getEmptyAWB(long providerId, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getEmptyAWB_call> resultHandler) throws org.apache.thrift.TException;
3430 rajveer 127
 
128
    public void getShipmentInfo(String awb, long providerId, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getShipmentInfo_call> resultHandler) throws org.apache.thrift.TException;
129
 
130
    public void getDestinationCode(long providerId, String pinCode, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getDestinationCode_call> resultHandler) throws org.apache.thrift.TException;
131
 
132
    public void getFreeAwbCount(long providerId, String type, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getFreeAwbCount_call> resultHandler) throws org.apache.thrift.TException;
133
 
134
    public void getHolidays(long fromDate, long toDate, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getHolidays_call> resultHandler) throws org.apache.thrift.TException;
135
 
4934 amit.gupta 136
    public void getEntityLogisticsEstimation(long catalogItemId, String destination_pin, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<AsyncClient.getEntityLogisticsEstimation_call> resultHandler) throws org.apache.thrift.TException;
137
 
3430 rajveer 138
  }
139
 
3374 rajveer 140
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
3430 rajveer 141
    public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
142
      public Factory() {}
143
      public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
144
        return new Client(prot);
145
      }
146
      public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
147
        return new Client(iprot, oprot);
148
      }
149
    }
150
 
151
    public Client(org.apache.thrift.protocol.TProtocol prot)
412 ashish 152
    {
3430 rajveer 153
      super(prot, prot);
412 ashish 154
    }
155
 
3430 rajveer 156
    public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
3374 rajveer 157
      super(iprot, oprot);
412 ashish 158
    }
159
 
3430 rajveer 160
    public Provider getProvider(long providerId) throws LogisticsServiceException, org.apache.thrift.TException
668 chandransh 161
    {
162
      send_getProvider(providerId);
163
      return recv_getProvider();
164
    }
165
 
3430 rajveer 166
    public void send_getProvider(long providerId) throws org.apache.thrift.TException
668 chandransh 167
    {
168
      getProvider_args args = new getProvider_args();
3430 rajveer 169
      args.setProviderId(providerId);
170
      sendBase("getProvider", args);
668 chandransh 171
    }
172
 
3430 rajveer 173
    public Provider recv_getProvider() throws LogisticsServiceException, org.apache.thrift.TException
668 chandransh 174
    {
175
      getProvider_result result = new getProvider_result();
3430 rajveer 176
      receiveBase(result, "getProvider");
668 chandransh 177
      if (result.isSetSuccess()) {
178
        return result.success;
179
      }
180
      if (result.lse != null) {
181
        throw result.lse;
182
      }
3430 rajveer 183
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getProvider failed: unknown result");
668 chandransh 184
    }
185
 
3430 rajveer 186
    public List<Provider> getAllProviders() throws LogisticsServiceException, org.apache.thrift.TException
674 chandransh 187
    {
188
      send_getAllProviders();
189
      return recv_getAllProviders();
190
    }
191
 
3430 rajveer 192
    public void send_getAllProviders() throws org.apache.thrift.TException
674 chandransh 193
    {
194
      getAllProviders_args args = new getAllProviders_args();
3430 rajveer 195
      sendBase("getAllProviders", args);
674 chandransh 196
    }
197
 
3430 rajveer 198
    public List<Provider> recv_getAllProviders() throws LogisticsServiceException, org.apache.thrift.TException
674 chandransh 199
    {
200
      getAllProviders_result result = new getAllProviders_result();
3430 rajveer 201
      receiveBase(result, "getAllProviders");
674 chandransh 202
      if (result.isSetSuccess()) {
203
        return result.success;
204
      }
205
      if (result.lse != null) {
206
        throw result.lse;
207
      }
3430 rajveer 208
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getAllProviders failed: unknown result");
674 chandransh 209
    }
210
 
4630 mandeep.dh 211
    public LogisticsInfo getLogisticsEstimation(long itemId, String destination_pin, DeliveryType type) throws LogisticsServiceException, org.apache.thrift.TException
483 rajveer 212
    {
4630 mandeep.dh 213
      send_getLogisticsEstimation(itemId, destination_pin, type);
471 rajveer 214
      return recv_getLogisticsEstimation();
215
    }
216
 
4630 mandeep.dh 217
    public void send_getLogisticsEstimation(long itemId, String destination_pin, DeliveryType type) throws org.apache.thrift.TException
471 rajveer 218
    {
219
      getLogisticsEstimation_args args = new getLogisticsEstimation_args();
3430 rajveer 220
      args.setItemId(itemId);
221
      args.setDestination_pin(destination_pin);
4630 mandeep.dh 222
      args.setType(type);
3430 rajveer 223
      sendBase("getLogisticsEstimation", args);
471 rajveer 224
    }
225
 
3430 rajveer 226
    public LogisticsInfo recv_getLogisticsEstimation() throws LogisticsServiceException, org.apache.thrift.TException
471 rajveer 227
    {
228
      getLogisticsEstimation_result result = new getLogisticsEstimation_result();
3430 rajveer 229
      receiveBase(result, "getLogisticsEstimation");
471 rajveer 230
      if (result.isSetSuccess()) {
231
        return result.success;
232
      }
233
      if (result.se != null) {
234
        throw result.se;
235
      }
3430 rajveer 236
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getLogisticsEstimation failed: unknown result");
471 rajveer 237
    }
238
 
3430 rajveer 239
    public LogisticsInfo getLogisticsInfo(String destination_pincode, long item_id, DeliveryType type) throws LogisticsServiceException, org.apache.thrift.TException
471 rajveer 240
    {
3044 chandransh 241
      send_getLogisticsInfo(destination_pincode, item_id, type);
648 chandransh 242
      return recv_getLogisticsInfo();
471 rajveer 243
    }
244
 
3430 rajveer 245
    public void send_getLogisticsInfo(String destination_pincode, long item_id, DeliveryType type) throws org.apache.thrift.TException
471 rajveer 246
    {
648 chandransh 247
      getLogisticsInfo_args args = new getLogisticsInfo_args();
3430 rajveer 248
      args.setDestination_pincode(destination_pincode);
249
      args.setItem_id(item_id);
250
      args.setType(type);
251
      sendBase("getLogisticsInfo", args);
471 rajveer 252
    }
253
 
3430 rajveer 254
    public LogisticsInfo recv_getLogisticsInfo() throws LogisticsServiceException, org.apache.thrift.TException
471 rajveer 255
    {
648 chandransh 256
      getLogisticsInfo_result result = new getLogisticsInfo_result();
3430 rajveer 257
      receiveBase(result, "getLogisticsInfo");
648 chandransh 258
      if (result.isSetSuccess()) {
259
        return result.success;
477 rajveer 260
      }
648 chandransh 261
      if (result.se != null) {
262
        throw result.se;
412 ashish 263
      }
3430 rajveer 264
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getLogisticsInfo failed: unknown result");
412 ashish 265
    }
266
 
5247 rajveer 267
    public String getEmptyAWB(long providerId, DeliveryType type) throws LogisticsServiceException, org.apache.thrift.TException
412 ashish 268
    {
5247 rajveer 269
      send_getEmptyAWB(providerId, type);
412 ashish 270
      return recv_getEmptyAWB();
271
    }
272
 
5247 rajveer 273
    public void send_getEmptyAWB(long providerId, DeliveryType type) throws org.apache.thrift.TException
412 ashish 274
    {
275
      getEmptyAWB_args args = new getEmptyAWB_args();
3430 rajveer 276
      args.setProviderId(providerId);
5247 rajveer 277
      args.setType(type);
3430 rajveer 278
      sendBase("getEmptyAWB", args);
412 ashish 279
    }
280
 
3430 rajveer 281
    public String recv_getEmptyAWB() throws LogisticsServiceException, org.apache.thrift.TException
412 ashish 282
    {
283
      getEmptyAWB_result result = new getEmptyAWB_result();
3430 rajveer 284
      receiveBase(result, "getEmptyAWB");
412 ashish 285
      if (result.isSetSuccess()) {
286
        return result.success;
287
      }
648 chandransh 288
      if (result.se != null) {
289
        throw result.se;
290
      }
3430 rajveer 291
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getEmptyAWB failed: unknown result");
412 ashish 292
    }
293
 
3430 rajveer 294
    public List<AwbUpdate> getShipmentInfo(String awb, long providerId) throws LogisticsServiceException, org.apache.thrift.TException
412 ashish 295
    {
648 chandransh 296
      send_getShipmentInfo(awb, providerId);
412 ashish 297
      return recv_getShipmentInfo();
298
    }
299
 
3430 rajveer 300
    public void send_getShipmentInfo(String awb, long providerId) throws org.apache.thrift.TException
412 ashish 301
    {
302
      getShipmentInfo_args args = new getShipmentInfo_args();
3430 rajveer 303
      args.setAwb(awb);
304
      args.setProviderId(providerId);
305
      sendBase("getShipmentInfo", args);
412 ashish 306
    }
307
 
3430 rajveer 308
    public List<AwbUpdate> recv_getShipmentInfo() throws LogisticsServiceException, org.apache.thrift.TException
412 ashish 309
    {
310
      getShipmentInfo_result result = new getShipmentInfo_result();
3430 rajveer 311
      receiveBase(result, "getShipmentInfo");
412 ashish 312
      if (result.isSetSuccess()) {
313
        return result.success;
314
      }
648 chandransh 315
      if (result.se != null) {
316
        throw result.se;
317
      }
3430 rajveer 318
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getShipmentInfo failed: unknown result");
412 ashish 319
    }
320
 
3430 rajveer 321
    public String getDestinationCode(long providerId, String pinCode) throws LogisticsServiceException, org.apache.thrift.TException
730 chandransh 322
    {
323
      send_getDestinationCode(providerId, pinCode);
324
      return recv_getDestinationCode();
325
    }
326
 
3430 rajveer 327
    public void send_getDestinationCode(long providerId, String pinCode) throws org.apache.thrift.TException
730 chandransh 328
    {
329
      getDestinationCode_args args = new getDestinationCode_args();
3430 rajveer 330
      args.setProviderId(providerId);
331
      args.setPinCode(pinCode);
332
      sendBase("getDestinationCode", args);
730 chandransh 333
    }
334
 
3430 rajveer 335
    public String recv_getDestinationCode() throws LogisticsServiceException, org.apache.thrift.TException
730 chandransh 336
    {
337
      getDestinationCode_result result = new getDestinationCode_result();
3430 rajveer 338
      receiveBase(result, "getDestinationCode");
730 chandransh 339
      if (result.isSetSuccess()) {
340
        return result.success;
341
      }
342
      if (result.se != null) {
343
        throw result.se;
344
      }
3430 rajveer 345
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getDestinationCode failed: unknown result");
730 chandransh 346
    }
347
 
3430 rajveer 348
    public long getFreeAwbCount(long providerId, String type) throws org.apache.thrift.TException
1139 chandransh 349
    {
3103 chandransh 350
      send_getFreeAwbCount(providerId, type);
1139 chandransh 351
      return recv_getFreeAwbCount();
352
    }
353
 
3430 rajveer 354
    public void send_getFreeAwbCount(long providerId, String type) throws org.apache.thrift.TException
1139 chandransh 355
    {
356
      getFreeAwbCount_args args = new getFreeAwbCount_args();
3430 rajveer 357
      args.setProviderId(providerId);
358
      args.setType(type);
359
      sendBase("getFreeAwbCount", args);
1139 chandransh 360
    }
361
 
3430 rajveer 362
    public long recv_getFreeAwbCount() throws org.apache.thrift.TException
1139 chandransh 363
    {
364
      getFreeAwbCount_result result = new getFreeAwbCount_result();
3430 rajveer 365
      receiveBase(result, "getFreeAwbCount");
1139 chandransh 366
      if (result.isSetSuccess()) {
367
        return result.success;
368
      }
3430 rajveer 369
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getFreeAwbCount failed: unknown result");
1139 chandransh 370
    }
371
 
3430 rajveer 372
    public List<Long> getHolidays(long fromDate, long toDate) throws org.apache.thrift.TException
1730 ankur.sing 373
    {
374
      send_getHolidays(fromDate, toDate);
375
      return recv_getHolidays();
376
    }
377
 
3430 rajveer 378
    public void send_getHolidays(long fromDate, long toDate) throws org.apache.thrift.TException
1730 ankur.sing 379
    {
380
      getHolidays_args args = new getHolidays_args();
3430 rajveer 381
      args.setFromDate(fromDate);
382
      args.setToDate(toDate);
383
      sendBase("getHolidays", args);
1730 ankur.sing 384
    }
385
 
3430 rajveer 386
    public List<Long> recv_getHolidays() throws org.apache.thrift.TException
1730 ankur.sing 387
    {
388
      getHolidays_result result = new getHolidays_result();
3430 rajveer 389
      receiveBase(result, "getHolidays");
1730 ankur.sing 390
      if (result.isSetSuccess()) {
391
        return result.success;
392
      }
3430 rajveer 393
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getHolidays failed: unknown result");
1730 ankur.sing 394
    }
395
 
4934 amit.gupta 396
    public List<Long> getEntityLogisticsEstimation(long catalogItemId, String destination_pin, DeliveryType type) throws LogisticsServiceException, org.apache.thrift.TException
397
    {
398
      send_getEntityLogisticsEstimation(catalogItemId, destination_pin, type);
399
      return recv_getEntityLogisticsEstimation();
400
    }
401
 
402
    public void send_getEntityLogisticsEstimation(long catalogItemId, String destination_pin, DeliveryType type) throws org.apache.thrift.TException
403
    {
404
      getEntityLogisticsEstimation_args args = new getEntityLogisticsEstimation_args();
405
      args.setCatalogItemId(catalogItemId);
406
      args.setDestination_pin(destination_pin);
407
      args.setType(type);
408
      sendBase("getEntityLogisticsEstimation", args);
409
    }
410
 
411
    public List<Long> recv_getEntityLogisticsEstimation() throws LogisticsServiceException, org.apache.thrift.TException
412
    {
413
      getEntityLogisticsEstimation_result result = new getEntityLogisticsEstimation_result();
414
      receiveBase(result, "getEntityLogisticsEstimation");
415
      if (result.isSetSuccess()) {
416
        return result.success;
417
      }
418
      if (result.se != null) {
419
        throw result.se;
420
      }
421
      throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "getEntityLogisticsEstimation failed: unknown result");
422
    }
423
 
412 ashish 424
  }
3430 rajveer 425
  public static class AsyncClient extends in.shop2020.generic.GenericService.AsyncClient implements AsyncIface {
426
    public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
427
      private org.apache.thrift.async.TAsyncClientManager clientManager;
428
      private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
429
      public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
430
        this.clientManager = clientManager;
431
        this.protocolFactory = protocolFactory;
432
      }
433
      public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
434
        return new AsyncClient(protocolFactory, clientManager, transport);
435
      }
412 ashish 436
    }
437
 
3430 rajveer 438
    public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
439
      super(protocolFactory, clientManager, transport);
440
    }
412 ashish 441
 
3430 rajveer 442
    public void getProvider(long providerId, org.apache.thrift.async.AsyncMethodCallback<getProvider_call> resultHandler) throws org.apache.thrift.TException {
443
      checkReady();
444
      getProvider_call method_call = new getProvider_call(providerId, resultHandler, this, ___protocolFactory, ___transport);
445
      this.___currentMethod = method_call;
446
      ___manager.call(method_call);
447
    }
448
 
449
    public static class getProvider_call extends org.apache.thrift.async.TAsyncMethodCall {
450
      private long providerId;
451
      public getProvider_call(long providerId, org.apache.thrift.async.AsyncMethodCallback<getProvider_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 {
452
        super(client, protocolFactory, transport, resultHandler, false);
453
        this.providerId = providerId;
412 ashish 454
      }
3430 rajveer 455
 
456
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
457
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getProvider", org.apache.thrift.protocol.TMessageType.CALL, 0));
458
        getProvider_args args = new getProvider_args();
459
        args.setProviderId(providerId);
460
        args.write(prot);
461
        prot.writeMessageEnd();
462
      }
463
 
464
      public Provider getResult() throws LogisticsServiceException, org.apache.thrift.TException {
465
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
466
          throw new IllegalStateException("Method call not finished!");
467
        }
468
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
469
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
470
        return (new Client(prot)).recv_getProvider();
471
      }
412 ashish 472
    }
473
 
3430 rajveer 474
    public void getAllProviders(org.apache.thrift.async.AsyncMethodCallback<getAllProviders_call> resultHandler) throws org.apache.thrift.TException {
475
      checkReady();
476
      getAllProviders_call method_call = new getAllProviders_call(resultHandler, this, ___protocolFactory, ___transport);
477
      this.___currentMethod = method_call;
478
      ___manager.call(method_call);
479
    }
480
 
481
    public static class getAllProviders_call extends org.apache.thrift.async.TAsyncMethodCall {
482
      public getAllProviders_call(org.apache.thrift.async.AsyncMethodCallback<getAllProviders_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 {
483
        super(client, protocolFactory, transport, resultHandler, false);
484
      }
485
 
486
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
487
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getAllProviders", org.apache.thrift.protocol.TMessageType.CALL, 0));
488
        getAllProviders_args args = new getAllProviders_args();
489
        args.write(prot);
490
        prot.writeMessageEnd();
491
      }
492
 
493
      public List<Provider> getResult() throws LogisticsServiceException, org.apache.thrift.TException {
494
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
495
          throw new IllegalStateException("Method call not finished!");
496
        }
497
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
498
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
499
        return (new Client(prot)).recv_getAllProviders();
500
      }
501
    }
502
 
4630 mandeep.dh 503
    public void getLogisticsEstimation(long itemId, String destination_pin, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<getLogisticsEstimation_call> resultHandler) throws org.apache.thrift.TException {
3430 rajveer 504
      checkReady();
4630 mandeep.dh 505
      getLogisticsEstimation_call method_call = new getLogisticsEstimation_call(itemId, destination_pin, type, resultHandler, this, ___protocolFactory, ___transport);
3430 rajveer 506
      this.___currentMethod = method_call;
507
      ___manager.call(method_call);
508
    }
509
 
510
    public static class getLogisticsEstimation_call extends org.apache.thrift.async.TAsyncMethodCall {
511
      private long itemId;
512
      private String destination_pin;
4630 mandeep.dh 513
      private DeliveryType type;
514
      public getLogisticsEstimation_call(long itemId, String destination_pin, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<getLogisticsEstimation_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
3430 rajveer 515
        super(client, protocolFactory, transport, resultHandler, false);
516
        this.itemId = itemId;
517
        this.destination_pin = destination_pin;
4630 mandeep.dh 518
        this.type = type;
3430 rajveer 519
      }
520
 
521
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
522
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getLogisticsEstimation", org.apache.thrift.protocol.TMessageType.CALL, 0));
523
        getLogisticsEstimation_args args = new getLogisticsEstimation_args();
524
        args.setItemId(itemId);
525
        args.setDestination_pin(destination_pin);
4630 mandeep.dh 526
        args.setType(type);
3430 rajveer 527
        args.write(prot);
528
        prot.writeMessageEnd();
529
      }
530
 
531
      public LogisticsInfo getResult() throws LogisticsServiceException, org.apache.thrift.TException {
532
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
533
          throw new IllegalStateException("Method call not finished!");
534
        }
535
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
536
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
537
        return (new Client(prot)).recv_getLogisticsEstimation();
538
      }
539
    }
540
 
541
    public void getLogisticsInfo(String destination_pincode, long item_id, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<getLogisticsInfo_call> resultHandler) throws org.apache.thrift.TException {
542
      checkReady();
543
      getLogisticsInfo_call method_call = new getLogisticsInfo_call(destination_pincode, item_id, type, resultHandler, this, ___protocolFactory, ___transport);
544
      this.___currentMethod = method_call;
545
      ___manager.call(method_call);
546
    }
547
 
548
    public static class getLogisticsInfo_call extends org.apache.thrift.async.TAsyncMethodCall {
549
      private String destination_pincode;
550
      private long item_id;
551
      private DeliveryType type;
552
      public getLogisticsInfo_call(String destination_pincode, long item_id, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<getLogisticsInfo_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 {
553
        super(client, protocolFactory, transport, resultHandler, false);
554
        this.destination_pincode = destination_pincode;
555
        this.item_id = item_id;
556
        this.type = type;
557
      }
558
 
559
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
560
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getLogisticsInfo", org.apache.thrift.protocol.TMessageType.CALL, 0));
561
        getLogisticsInfo_args args = new getLogisticsInfo_args();
562
        args.setDestination_pincode(destination_pincode);
563
        args.setItem_id(item_id);
564
        args.setType(type);
565
        args.write(prot);
566
        prot.writeMessageEnd();
567
      }
568
 
569
      public LogisticsInfo getResult() throws LogisticsServiceException, org.apache.thrift.TException {
570
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
571
          throw new IllegalStateException("Method call not finished!");
572
        }
573
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
574
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
575
        return (new Client(prot)).recv_getLogisticsInfo();
576
      }
577
    }
578
 
5247 rajveer 579
    public void getEmptyAWB(long providerId, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<getEmptyAWB_call> resultHandler) throws org.apache.thrift.TException {
3430 rajveer 580
      checkReady();
5247 rajveer 581
      getEmptyAWB_call method_call = new getEmptyAWB_call(providerId, type, resultHandler, this, ___protocolFactory, ___transport);
3430 rajveer 582
      this.___currentMethod = method_call;
583
      ___manager.call(method_call);
584
    }
585
 
586
    public static class getEmptyAWB_call extends org.apache.thrift.async.TAsyncMethodCall {
587
      private long providerId;
5247 rajveer 588
      private DeliveryType type;
589
      public getEmptyAWB_call(long providerId, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<getEmptyAWB_call> resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
3430 rajveer 590
        super(client, protocolFactory, transport, resultHandler, false);
591
        this.providerId = providerId;
5247 rajveer 592
        this.type = type;
3430 rajveer 593
      }
594
 
595
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
596
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getEmptyAWB", org.apache.thrift.protocol.TMessageType.CALL, 0));
597
        getEmptyAWB_args args = new getEmptyAWB_args();
598
        args.setProviderId(providerId);
5247 rajveer 599
        args.setType(type);
3430 rajveer 600
        args.write(prot);
601
        prot.writeMessageEnd();
602
      }
603
 
604
      public String getResult() throws LogisticsServiceException, org.apache.thrift.TException {
605
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
606
          throw new IllegalStateException("Method call not finished!");
607
        }
608
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
609
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
610
        return (new Client(prot)).recv_getEmptyAWB();
611
      }
612
    }
613
 
614
    public void getShipmentInfo(String awb, long providerId, org.apache.thrift.async.AsyncMethodCallback<getShipmentInfo_call> resultHandler) throws org.apache.thrift.TException {
615
      checkReady();
616
      getShipmentInfo_call method_call = new getShipmentInfo_call(awb, providerId, resultHandler, this, ___protocolFactory, ___transport);
617
      this.___currentMethod = method_call;
618
      ___manager.call(method_call);
619
    }
620
 
621
    public static class getShipmentInfo_call extends org.apache.thrift.async.TAsyncMethodCall {
622
      private String awb;
623
      private long providerId;
624
      public getShipmentInfo_call(String awb, long providerId, org.apache.thrift.async.AsyncMethodCallback<getShipmentInfo_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 {
625
        super(client, protocolFactory, transport, resultHandler, false);
626
        this.awb = awb;
627
        this.providerId = providerId;
628
      }
629
 
630
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
631
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getShipmentInfo", org.apache.thrift.protocol.TMessageType.CALL, 0));
632
        getShipmentInfo_args args = new getShipmentInfo_args();
633
        args.setAwb(awb);
634
        args.setProviderId(providerId);
635
        args.write(prot);
636
        prot.writeMessageEnd();
637
      }
638
 
639
      public List<AwbUpdate> getResult() throws LogisticsServiceException, org.apache.thrift.TException {
640
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
641
          throw new IllegalStateException("Method call not finished!");
642
        }
643
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
644
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
645
        return (new Client(prot)).recv_getShipmentInfo();
646
      }
647
    }
648
 
649
    public void getDestinationCode(long providerId, String pinCode, org.apache.thrift.async.AsyncMethodCallback<getDestinationCode_call> resultHandler) throws org.apache.thrift.TException {
650
      checkReady();
651
      getDestinationCode_call method_call = new getDestinationCode_call(providerId, pinCode, resultHandler, this, ___protocolFactory, ___transport);
652
      this.___currentMethod = method_call;
653
      ___manager.call(method_call);
654
    }
655
 
656
    public static class getDestinationCode_call extends org.apache.thrift.async.TAsyncMethodCall {
657
      private long providerId;
658
      private String pinCode;
659
      public getDestinationCode_call(long providerId, String pinCode, org.apache.thrift.async.AsyncMethodCallback<getDestinationCode_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 {
660
        super(client, protocolFactory, transport, resultHandler, false);
661
        this.providerId = providerId;
662
        this.pinCode = pinCode;
663
      }
664
 
665
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
666
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getDestinationCode", org.apache.thrift.protocol.TMessageType.CALL, 0));
667
        getDestinationCode_args args = new getDestinationCode_args();
668
        args.setProviderId(providerId);
669
        args.setPinCode(pinCode);
670
        args.write(prot);
671
        prot.writeMessageEnd();
672
      }
673
 
674
      public String getResult() throws LogisticsServiceException, org.apache.thrift.TException {
675
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
676
          throw new IllegalStateException("Method call not finished!");
677
        }
678
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
679
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
680
        return (new Client(prot)).recv_getDestinationCode();
681
      }
682
    }
683
 
684
    public void getFreeAwbCount(long providerId, String type, org.apache.thrift.async.AsyncMethodCallback<getFreeAwbCount_call> resultHandler) throws org.apache.thrift.TException {
685
      checkReady();
686
      getFreeAwbCount_call method_call = new getFreeAwbCount_call(providerId, type, resultHandler, this, ___protocolFactory, ___transport);
687
      this.___currentMethod = method_call;
688
      ___manager.call(method_call);
689
    }
690
 
691
    public static class getFreeAwbCount_call extends org.apache.thrift.async.TAsyncMethodCall {
692
      private long providerId;
693
      private String type;
694
      public getFreeAwbCount_call(long providerId, String type, org.apache.thrift.async.AsyncMethodCallback<getFreeAwbCount_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 {
695
        super(client, protocolFactory, transport, resultHandler, false);
696
        this.providerId = providerId;
697
        this.type = type;
698
      }
699
 
700
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
701
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getFreeAwbCount", org.apache.thrift.protocol.TMessageType.CALL, 0));
702
        getFreeAwbCount_args args = new getFreeAwbCount_args();
703
        args.setProviderId(providerId);
704
        args.setType(type);
705
        args.write(prot);
706
        prot.writeMessageEnd();
707
      }
708
 
709
      public long getResult() throws org.apache.thrift.TException {
710
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
711
          throw new IllegalStateException("Method call not finished!");
712
        }
713
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
714
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
715
        return (new Client(prot)).recv_getFreeAwbCount();
716
      }
717
    }
718
 
719
    public void getHolidays(long fromDate, long toDate, org.apache.thrift.async.AsyncMethodCallback<getHolidays_call> resultHandler) throws org.apache.thrift.TException {
720
      checkReady();
721
      getHolidays_call method_call = new getHolidays_call(fromDate, toDate, resultHandler, this, ___protocolFactory, ___transport);
722
      this.___currentMethod = method_call;
723
      ___manager.call(method_call);
724
    }
725
 
726
    public static class getHolidays_call extends org.apache.thrift.async.TAsyncMethodCall {
727
      private long fromDate;
728
      private long toDate;
729
      public getHolidays_call(long fromDate, long toDate, org.apache.thrift.async.AsyncMethodCallback<getHolidays_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 {
730
        super(client, protocolFactory, transport, resultHandler, false);
731
        this.fromDate = fromDate;
732
        this.toDate = toDate;
733
      }
734
 
735
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
736
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getHolidays", org.apache.thrift.protocol.TMessageType.CALL, 0));
737
        getHolidays_args args = new getHolidays_args();
738
        args.setFromDate(fromDate);
739
        args.setToDate(toDate);
740
        args.write(prot);
741
        prot.writeMessageEnd();
742
      }
743
 
744
      public List<Long> getResult() throws org.apache.thrift.TException {
745
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
746
          throw new IllegalStateException("Method call not finished!");
747
        }
748
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
749
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
750
        return (new Client(prot)).recv_getHolidays();
751
      }
752
    }
753
 
4934 amit.gupta 754
    public void getEntityLogisticsEstimation(long catalogItemId, String destination_pin, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<getEntityLogisticsEstimation_call> resultHandler) throws org.apache.thrift.TException {
755
      checkReady();
756
      getEntityLogisticsEstimation_call method_call = new getEntityLogisticsEstimation_call(catalogItemId, destination_pin, type, resultHandler, this, ___protocolFactory, ___transport);
757
      this.___currentMethod = method_call;
758
      ___manager.call(method_call);
759
    }
760
 
761
    public static class getEntityLogisticsEstimation_call extends org.apache.thrift.async.TAsyncMethodCall {
762
      private long catalogItemId;
763
      private String destination_pin;
764
      private DeliveryType type;
765
      public getEntityLogisticsEstimation_call(long catalogItemId, String destination_pin, DeliveryType type, org.apache.thrift.async.AsyncMethodCallback<getEntityLogisticsEstimation_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 {
766
        super(client, protocolFactory, transport, resultHandler, false);
767
        this.catalogItemId = catalogItemId;
768
        this.destination_pin = destination_pin;
769
        this.type = type;
770
      }
771
 
772
      public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
773
        prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("getEntityLogisticsEstimation", org.apache.thrift.protocol.TMessageType.CALL, 0));
774
        getEntityLogisticsEstimation_args args = new getEntityLogisticsEstimation_args();
775
        args.setCatalogItemId(catalogItemId);
776
        args.setDestination_pin(destination_pin);
777
        args.setType(type);
778
        args.write(prot);
779
        prot.writeMessageEnd();
780
      }
781
 
782
      public List<Long> getResult() throws LogisticsServiceException, org.apache.thrift.TException {
783
        if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
784
          throw new IllegalStateException("Method call not finished!");
785
        }
786
        org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
787
        org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
788
        return (new Client(prot)).recv_getEntityLogisticsEstimation();
789
      }
790
    }
791
 
3430 rajveer 792
  }
793
 
794
  public static class Processor<I extends Iface> extends in.shop2020.generic.GenericService.Processor implements org.apache.thrift.TProcessor {
795
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
796
    public Processor(I iface) {
797
      super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
798
    }
799
 
800
    protected Processor(I iface, Map<String,  org.apache.thrift.ProcessFunction<I, ? extends  org.apache.thrift.TBase>> processMap) {
801
      super(iface, getProcessMap(processMap));
802
    }
803
 
804
    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) {
805
      processMap.put("getProvider", new getProvider());
806
      processMap.put("getAllProviders", new getAllProviders());
807
      processMap.put("getLogisticsEstimation", new getLogisticsEstimation());
808
      processMap.put("getLogisticsInfo", new getLogisticsInfo());
809
      processMap.put("getEmptyAWB", new getEmptyAWB());
810
      processMap.put("getShipmentInfo", new getShipmentInfo());
811
      processMap.put("getDestinationCode", new getDestinationCode());
812
      processMap.put("getFreeAwbCount", new getFreeAwbCount());
813
      processMap.put("getHolidays", new getHolidays());
4934 amit.gupta 814
      processMap.put("getEntityLogisticsEstimation", new getEntityLogisticsEstimation());
3430 rajveer 815
      return processMap;
816
    }
817
 
818
    private static class getProvider<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getProvider_args> {
819
      public getProvider() {
820
        super("getProvider");
821
      }
822
 
823
      protected getProvider_args getEmptyArgsInstance() {
824
        return new getProvider_args();
825
      }
826
 
827
      protected getProvider_result getResult(I iface, getProvider_args args) throws org.apache.thrift.TException {
668 chandransh 828
        getProvider_result result = new getProvider_result();
829
        try {
3430 rajveer 830
          result.success = iface.getProvider(args.providerId);
668 chandransh 831
        } catch (LogisticsServiceException lse) {
832
          result.lse = lse;
833
        }
3430 rajveer 834
        return result;
668 chandransh 835
      }
836
    }
837
 
3430 rajveer 838
    private static class getAllProviders<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getAllProviders_args> {
839
      public getAllProviders() {
840
        super("getAllProviders");
841
      }
842
 
843
      protected getAllProviders_args getEmptyArgsInstance() {
844
        return new getAllProviders_args();
845
      }
846
 
847
      protected getAllProviders_result getResult(I iface, getAllProviders_args args) throws org.apache.thrift.TException {
674 chandransh 848
        getAllProviders_result result = new getAllProviders_result();
849
        try {
3430 rajveer 850
          result.success = iface.getAllProviders();
674 chandransh 851
        } catch (LogisticsServiceException lse) {
852
          result.lse = lse;
853
        }
3430 rajveer 854
        return result;
674 chandransh 855
      }
856
    }
857
 
3430 rajveer 858
    private static class getLogisticsEstimation<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getLogisticsEstimation_args> {
859
      public getLogisticsEstimation() {
860
        super("getLogisticsEstimation");
861
      }
862
 
863
      protected getLogisticsEstimation_args getEmptyArgsInstance() {
864
        return new getLogisticsEstimation_args();
865
      }
866
 
867
      protected getLogisticsEstimation_result getResult(I iface, getLogisticsEstimation_args args) throws org.apache.thrift.TException {
648 chandransh 868
        getLogisticsEstimation_result result = new getLogisticsEstimation_result();
483 rajveer 869
        try {
4630 mandeep.dh 870
          result.success = iface.getLogisticsEstimation(args.itemId, args.destination_pin, args.type);
483 rajveer 871
        } catch (LogisticsServiceException se) {
872
          result.se = se;
873
        }
3430 rajveer 874
        return result;
483 rajveer 875
      }
876
    }
877
 
3430 rajveer 878
    private static class getLogisticsInfo<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getLogisticsInfo_args> {
879
      public getLogisticsInfo() {
880
        super("getLogisticsInfo");
881
      }
882
 
883
      protected getLogisticsInfo_args getEmptyArgsInstance() {
884
        return new getLogisticsInfo_args();
885
      }
886
 
887
      protected getLogisticsInfo_result getResult(I iface, getLogisticsInfo_args args) throws org.apache.thrift.TException {
648 chandransh 888
        getLogisticsInfo_result result = new getLogisticsInfo_result();
471 rajveer 889
        try {
3430 rajveer 890
          result.success = iface.getLogisticsInfo(args.destination_pincode, args.item_id, args.type);
471 rajveer 891
        } catch (LogisticsServiceException se) {
892
          result.se = se;
893
        }
3430 rajveer 894
        return result;
471 rajveer 895
      }
896
    }
897
 
3430 rajveer 898
    private static class getEmptyAWB<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getEmptyAWB_args> {
899
      public getEmptyAWB() {
900
        super("getEmptyAWB");
901
      }
902
 
903
      protected getEmptyAWB_args getEmptyArgsInstance() {
904
        return new getEmptyAWB_args();
905
      }
906
 
907
      protected getEmptyAWB_result getResult(I iface, getEmptyAWB_args args) throws org.apache.thrift.TException {
412 ashish 908
        getEmptyAWB_result result = new getEmptyAWB_result();
648 chandransh 909
        try {
5247 rajveer 910
          result.success = iface.getEmptyAWB(args.providerId, args.type);
648 chandransh 911
        } catch (LogisticsServiceException se) {
912
          result.se = se;
913
        }
3430 rajveer 914
        return result;
412 ashish 915
      }
916
    }
917
 
3430 rajveer 918
    private static class getShipmentInfo<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getShipmentInfo_args> {
919
      public getShipmentInfo() {
920
        super("getShipmentInfo");
921
      }
922
 
923
      protected getShipmentInfo_args getEmptyArgsInstance() {
924
        return new getShipmentInfo_args();
925
      }
926
 
927
      protected getShipmentInfo_result getResult(I iface, getShipmentInfo_args args) throws org.apache.thrift.TException {
412 ashish 928
        getShipmentInfo_result result = new getShipmentInfo_result();
648 chandransh 929
        try {
3430 rajveer 930
          result.success = iface.getShipmentInfo(args.awb, args.providerId);
648 chandransh 931
        } catch (LogisticsServiceException se) {
932
          result.se = se;
933
        }
3430 rajveer 934
        return result;
412 ashish 935
      }
936
    }
937
 
3430 rajveer 938
    private static class getDestinationCode<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getDestinationCode_args> {
939
      public getDestinationCode() {
940
        super("getDestinationCode");
941
      }
942
 
943
      protected getDestinationCode_args getEmptyArgsInstance() {
944
        return new getDestinationCode_args();
945
      }
946
 
947
      protected getDestinationCode_result getResult(I iface, getDestinationCode_args args) throws org.apache.thrift.TException {
730 chandransh 948
        getDestinationCode_result result = new getDestinationCode_result();
949
        try {
3430 rajveer 950
          result.success = iface.getDestinationCode(args.providerId, args.pinCode);
730 chandransh 951
        } catch (LogisticsServiceException se) {
952
          result.se = se;
953
        }
3430 rajveer 954
        return result;
730 chandransh 955
      }
956
    }
957
 
3430 rajveer 958
    private static class getFreeAwbCount<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getFreeAwbCount_args> {
959
      public getFreeAwbCount() {
960
        super("getFreeAwbCount");
961
      }
962
 
963
      protected getFreeAwbCount_args getEmptyArgsInstance() {
964
        return new getFreeAwbCount_args();
965
      }
966
 
967
      protected getFreeAwbCount_result getResult(I iface, getFreeAwbCount_args args) throws org.apache.thrift.TException {
1139 chandransh 968
        getFreeAwbCount_result result = new getFreeAwbCount_result();
3430 rajveer 969
        result.success = iface.getFreeAwbCount(args.providerId, args.type);
1139 chandransh 970
        result.setSuccessIsSet(true);
3430 rajveer 971
        return result;
1139 chandransh 972
      }
973
    }
974
 
3430 rajveer 975
    private static class getHolidays<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getHolidays_args> {
976
      public getHolidays() {
977
        super("getHolidays");
978
      }
979
 
980
      protected getHolidays_args getEmptyArgsInstance() {
981
        return new getHolidays_args();
982
      }
983
 
984
      protected getHolidays_result getResult(I iface, getHolidays_args args) throws org.apache.thrift.TException {
1730 ankur.sing 985
        getHolidays_result result = new getHolidays_result();
3430 rajveer 986
        result.success = iface.getHolidays(args.fromDate, args.toDate);
987
        return result;
1730 ankur.sing 988
      }
989
    }
990
 
4934 amit.gupta 991
    private static class getEntityLogisticsEstimation<I extends Iface> extends org.apache.thrift.ProcessFunction<I, getEntityLogisticsEstimation_args> {
992
      public getEntityLogisticsEstimation() {
993
        super("getEntityLogisticsEstimation");
994
      }
995
 
996
      protected getEntityLogisticsEstimation_args getEmptyArgsInstance() {
997
        return new getEntityLogisticsEstimation_args();
998
      }
999
 
1000
      protected getEntityLogisticsEstimation_result getResult(I iface, getEntityLogisticsEstimation_args args) throws org.apache.thrift.TException {
1001
        getEntityLogisticsEstimation_result result = new getEntityLogisticsEstimation_result();
1002
        try {
1003
          result.success = iface.getEntityLogisticsEstimation(args.catalogItemId, args.destination_pin, args.type);
1004
        } catch (LogisticsServiceException se) {
1005
          result.se = se;
1006
        }
1007
        return result;
1008
      }
1009
    }
1010
 
412 ashish 1011
  }
1012
 
3430 rajveer 1013
  public static class getProvider_args implements org.apache.thrift.TBase<getProvider_args, getProvider_args._Fields>, java.io.Serializable, Cloneable   {
1014
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getProvider_args");
668 chandransh 1015
 
3430 rajveer 1016
    private static final org.apache.thrift.protocol.TField PROVIDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("providerId", org.apache.thrift.protocol.TType.I64, (short)1);
668 chandransh 1017
 
3430 rajveer 1018
    private long providerId; // required
668 chandransh 1019
 
1020
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 1021
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
668 chandransh 1022
      PROVIDER_ID((short)1, "providerId");
1023
 
1024
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
1025
 
1026
      static {
1027
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
1028
          byName.put(field.getFieldName(), field);
1029
        }
1030
      }
1031
 
1032
      /**
1033
       * Find the _Fields constant that matches fieldId, or null if its not found.
1034
       */
1035
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 1036
        switch(fieldId) {
1037
          case 1: // PROVIDER_ID
1038
            return PROVIDER_ID;
1039
          default:
1040
            return null;
1041
        }
668 chandransh 1042
      }
1043
 
1044
      /**
1045
       * Find the _Fields constant that matches fieldId, throwing an exception
1046
       * if it is not found.
1047
       */
1048
      public static _Fields findByThriftIdOrThrow(int fieldId) {
1049
        _Fields fields = findByThriftId(fieldId);
1050
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
1051
        return fields;
1052
      }
1053
 
1054
      /**
1055
       * Find the _Fields constant that matches name, or null if its not found.
1056
       */
1057
      public static _Fields findByName(String name) {
1058
        return byName.get(name);
1059
      }
1060
 
1061
      private final short _thriftId;
1062
      private final String _fieldName;
1063
 
1064
      _Fields(short thriftId, String fieldName) {
1065
        _thriftId = thriftId;
1066
        _fieldName = fieldName;
1067
      }
1068
 
1069
      public short getThriftFieldId() {
1070
        return _thriftId;
1071
      }
1072
 
1073
      public String getFieldName() {
1074
        return _fieldName;
1075
      }
1076
    }
1077
 
1078
    // isset id assignments
1079
    private static final int __PROVIDERID_ISSET_ID = 0;
1080
    private BitSet __isset_bit_vector = new BitSet(1);
1081
 
3430 rajveer 1082
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
668 chandransh 1083
    static {
3430 rajveer 1084
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
1085
      tmpMap.put(_Fields.PROVIDER_ID, new org.apache.thrift.meta_data.FieldMetaData("providerId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
1086
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
1087
      metaDataMap = Collections.unmodifiableMap(tmpMap);
1088
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getProvider_args.class, metaDataMap);
668 chandransh 1089
    }
1090
 
1091
    public getProvider_args() {
1092
    }
1093
 
1094
    public getProvider_args(
1095
      long providerId)
1096
    {
1097
      this();
1098
      this.providerId = providerId;
1099
      setProviderIdIsSet(true);
1100
    }
1101
 
1102
    /**
1103
     * Performs a deep copy on <i>other</i>.
1104
     */
1105
    public getProvider_args(getProvider_args other) {
1106
      __isset_bit_vector.clear();
1107
      __isset_bit_vector.or(other.__isset_bit_vector);
1108
      this.providerId = other.providerId;
1109
    }
1110
 
1111
    public getProvider_args deepCopy() {
1112
      return new getProvider_args(this);
1113
    }
1114
 
3430 rajveer 1115
    @Override
1116
    public void clear() {
1117
      setProviderIdIsSet(false);
1118
      this.providerId = 0;
668 chandransh 1119
    }
1120
 
1121
    public long getProviderId() {
1122
      return this.providerId;
1123
    }
1124
 
3430 rajveer 1125
    public void setProviderId(long providerId) {
668 chandransh 1126
      this.providerId = providerId;
1127
      setProviderIdIsSet(true);
1128
    }
1129
 
1130
    public void unsetProviderId() {
1131
      __isset_bit_vector.clear(__PROVIDERID_ISSET_ID);
1132
    }
1133
 
3430 rajveer 1134
    /** Returns true if field providerId is set (has been assigned a value) and false otherwise */
668 chandransh 1135
    public boolean isSetProviderId() {
1136
      return __isset_bit_vector.get(__PROVIDERID_ISSET_ID);
1137
    }
1138
 
1139
    public void setProviderIdIsSet(boolean value) {
1140
      __isset_bit_vector.set(__PROVIDERID_ISSET_ID, value);
1141
    }
1142
 
1143
    public void setFieldValue(_Fields field, Object value) {
1144
      switch (field) {
1145
      case PROVIDER_ID:
1146
        if (value == null) {
1147
          unsetProviderId();
1148
        } else {
1149
          setProviderId((Long)value);
1150
        }
1151
        break;
1152
 
1153
      }
1154
    }
1155
 
1156
    public Object getFieldValue(_Fields field) {
1157
      switch (field) {
1158
      case PROVIDER_ID:
3430 rajveer 1159
        return Long.valueOf(getProviderId());
668 chandransh 1160
 
1161
      }
1162
      throw new IllegalStateException();
1163
    }
1164
 
3430 rajveer 1165
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
1166
    public boolean isSet(_Fields field) {
1167
      if (field == null) {
1168
        throw new IllegalArgumentException();
1169
      }
668 chandransh 1170
 
1171
      switch (field) {
1172
      case PROVIDER_ID:
1173
        return isSetProviderId();
1174
      }
1175
      throw new IllegalStateException();
1176
    }
1177
 
1178
    @Override
1179
    public boolean equals(Object that) {
1180
      if (that == null)
1181
        return false;
1182
      if (that instanceof getProvider_args)
1183
        return this.equals((getProvider_args)that);
1184
      return false;
1185
    }
1186
 
1187
    public boolean equals(getProvider_args that) {
1188
      if (that == null)
1189
        return false;
1190
 
1191
      boolean this_present_providerId = true;
1192
      boolean that_present_providerId = true;
1193
      if (this_present_providerId || that_present_providerId) {
1194
        if (!(this_present_providerId && that_present_providerId))
1195
          return false;
1196
        if (this.providerId != that.providerId)
1197
          return false;
1198
      }
1199
 
1200
      return true;
1201
    }
1202
 
1203
    @Override
1204
    public int hashCode() {
1205
      return 0;
1206
    }
1207
 
1208
    public int compareTo(getProvider_args other) {
1209
      if (!getClass().equals(other.getClass())) {
1210
        return getClass().getName().compareTo(other.getClass().getName());
1211
      }
1212
 
1213
      int lastComparison = 0;
1214
      getProvider_args typedOther = (getProvider_args)other;
1215
 
3430 rajveer 1216
      lastComparison = Boolean.valueOf(isSetProviderId()).compareTo(typedOther.isSetProviderId());
668 chandransh 1217
      if (lastComparison != 0) {
1218
        return lastComparison;
1219
      }
3430 rajveer 1220
      if (isSetProviderId()) {
1221
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.providerId, typedOther.providerId);
1222
        if (lastComparison != 0) {
1223
          return lastComparison;
1224
        }
668 chandransh 1225
      }
1226
      return 0;
1227
    }
1228
 
3430 rajveer 1229
    public _Fields fieldForId(int fieldId) {
1230
      return _Fields.findByThriftId(fieldId);
1231
    }
1232
 
1233
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
1234
      org.apache.thrift.protocol.TField field;
668 chandransh 1235
      iprot.readStructBegin();
1236
      while (true)
1237
      {
1238
        field = iprot.readFieldBegin();
3430 rajveer 1239
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
668 chandransh 1240
          break;
1241
        }
3430 rajveer 1242
        switch (field.id) {
1243
          case 1: // PROVIDER_ID
1244
            if (field.type == org.apache.thrift.protocol.TType.I64) {
1245
              this.providerId = iprot.readI64();
1246
              setProviderIdIsSet(true);
1247
            } else { 
1248
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1249
            }
1250
            break;
1251
          default:
1252
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
668 chandransh 1253
        }
3430 rajveer 1254
        iprot.readFieldEnd();
668 chandransh 1255
      }
1256
      iprot.readStructEnd();
1257
      validate();
1258
    }
1259
 
3430 rajveer 1260
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
668 chandransh 1261
      validate();
1262
 
1263
      oprot.writeStructBegin(STRUCT_DESC);
1264
      oprot.writeFieldBegin(PROVIDER_ID_FIELD_DESC);
1265
      oprot.writeI64(this.providerId);
1266
      oprot.writeFieldEnd();
1267
      oprot.writeFieldStop();
1268
      oprot.writeStructEnd();
1269
    }
1270
 
1271
    @Override
1272
    public String toString() {
1273
      StringBuilder sb = new StringBuilder("getProvider_args(");
1274
      boolean first = true;
1275
 
1276
      sb.append("providerId:");
1277
      sb.append(this.providerId);
1278
      first = false;
1279
      sb.append(")");
1280
      return sb.toString();
1281
    }
1282
 
3430 rajveer 1283
    public void validate() throws org.apache.thrift.TException {
668 chandransh 1284
      // check for required fields
1285
    }
1286
 
3430 rajveer 1287
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
1288
      try {
1289
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
1290
      } catch (org.apache.thrift.TException te) {
1291
        throw new java.io.IOException(te);
1292
      }
1293
    }
1294
 
1295
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
1296
      try {
1297
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
1298
      } catch (org.apache.thrift.TException te) {
1299
        throw new java.io.IOException(te);
1300
      }
1301
    }
1302
 
668 chandransh 1303
  }
1304
 
3430 rajveer 1305
  public static class getProvider_result implements org.apache.thrift.TBase<getProvider_result, getProvider_result._Fields>, java.io.Serializable, Cloneable   {
1306
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getProvider_result");
668 chandransh 1307
 
3430 rajveer 1308
    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);
1309
    private static final org.apache.thrift.protocol.TField LSE_FIELD_DESC = new org.apache.thrift.protocol.TField("lse", org.apache.thrift.protocol.TType.STRUCT, (short)1);
668 chandransh 1310
 
3430 rajveer 1311
    private Provider success; // required
1312
    private LogisticsServiceException lse; // required
668 chandransh 1313
 
1314
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 1315
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
668 chandransh 1316
      SUCCESS((short)0, "success"),
1317
      LSE((short)1, "lse");
1318
 
1319
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
1320
 
1321
      static {
1322
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
1323
          byName.put(field.getFieldName(), field);
1324
        }
1325
      }
1326
 
1327
      /**
1328
       * Find the _Fields constant that matches fieldId, or null if its not found.
1329
       */
1330
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 1331
        switch(fieldId) {
1332
          case 0: // SUCCESS
1333
            return SUCCESS;
1334
          case 1: // LSE
1335
            return LSE;
1336
          default:
1337
            return null;
1338
        }
668 chandransh 1339
      }
1340
 
1341
      /**
1342
       * Find the _Fields constant that matches fieldId, throwing an exception
1343
       * if it is not found.
1344
       */
1345
      public static _Fields findByThriftIdOrThrow(int fieldId) {
1346
        _Fields fields = findByThriftId(fieldId);
1347
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
1348
        return fields;
1349
      }
1350
 
1351
      /**
1352
       * Find the _Fields constant that matches name, or null if its not found.
1353
       */
1354
      public static _Fields findByName(String name) {
1355
        return byName.get(name);
1356
      }
1357
 
1358
      private final short _thriftId;
1359
      private final String _fieldName;
1360
 
1361
      _Fields(short thriftId, String fieldName) {
1362
        _thriftId = thriftId;
1363
        _fieldName = fieldName;
1364
      }
1365
 
1366
      public short getThriftFieldId() {
1367
        return _thriftId;
1368
      }
1369
 
1370
      public String getFieldName() {
1371
        return _fieldName;
1372
      }
1373
    }
1374
 
1375
    // isset id assignments
1376
 
3430 rajveer 1377
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
668 chandransh 1378
    static {
3430 rajveer 1379
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
1380
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
1381
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Provider.class)));
1382
      tmpMap.put(_Fields.LSE, new org.apache.thrift.meta_data.FieldMetaData("lse", org.apache.thrift.TFieldRequirementType.DEFAULT, 
1383
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
1384
      metaDataMap = Collections.unmodifiableMap(tmpMap);
1385
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getProvider_result.class, metaDataMap);
668 chandransh 1386
    }
1387
 
1388
    public getProvider_result() {
1389
    }
1390
 
1391
    public getProvider_result(
1392
      Provider success,
1393
      LogisticsServiceException lse)
1394
    {
1395
      this();
1396
      this.success = success;
1397
      this.lse = lse;
1398
    }
1399
 
1400
    /**
1401
     * Performs a deep copy on <i>other</i>.
1402
     */
1403
    public getProvider_result(getProvider_result other) {
1404
      if (other.isSetSuccess()) {
1405
        this.success = new Provider(other.success);
1406
      }
1407
      if (other.isSetLse()) {
1408
        this.lse = new LogisticsServiceException(other.lse);
1409
      }
1410
    }
1411
 
1412
    public getProvider_result deepCopy() {
1413
      return new getProvider_result(this);
1414
    }
1415
 
3430 rajveer 1416
    @Override
1417
    public void clear() {
1418
      this.success = null;
1419
      this.lse = null;
668 chandransh 1420
    }
1421
 
1422
    public Provider getSuccess() {
1423
      return this.success;
1424
    }
1425
 
3430 rajveer 1426
    public void setSuccess(Provider success) {
668 chandransh 1427
      this.success = success;
1428
    }
1429
 
1430
    public void unsetSuccess() {
1431
      this.success = null;
1432
    }
1433
 
3430 rajveer 1434
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
668 chandransh 1435
    public boolean isSetSuccess() {
1436
      return this.success != null;
1437
    }
1438
 
1439
    public void setSuccessIsSet(boolean value) {
1440
      if (!value) {
1441
        this.success = null;
1442
      }
1443
    }
1444
 
1445
    public LogisticsServiceException getLse() {
1446
      return this.lse;
1447
    }
1448
 
3430 rajveer 1449
    public void setLse(LogisticsServiceException lse) {
668 chandransh 1450
      this.lse = lse;
1451
    }
1452
 
1453
    public void unsetLse() {
1454
      this.lse = null;
1455
    }
1456
 
3430 rajveer 1457
    /** Returns true if field lse is set (has been assigned a value) and false otherwise */
668 chandransh 1458
    public boolean isSetLse() {
1459
      return this.lse != null;
1460
    }
1461
 
1462
    public void setLseIsSet(boolean value) {
1463
      if (!value) {
1464
        this.lse = null;
1465
      }
1466
    }
1467
 
1468
    public void setFieldValue(_Fields field, Object value) {
1469
      switch (field) {
1470
      case SUCCESS:
1471
        if (value == null) {
1472
          unsetSuccess();
1473
        } else {
1474
          setSuccess((Provider)value);
1475
        }
1476
        break;
1477
 
1478
      case LSE:
1479
        if (value == null) {
1480
          unsetLse();
1481
        } else {
1482
          setLse((LogisticsServiceException)value);
1483
        }
1484
        break;
1485
 
1486
      }
1487
    }
1488
 
1489
    public Object getFieldValue(_Fields field) {
1490
      switch (field) {
1491
      case SUCCESS:
1492
        return getSuccess();
1493
 
1494
      case LSE:
1495
        return getLse();
1496
 
1497
      }
1498
      throw new IllegalStateException();
1499
    }
1500
 
3430 rajveer 1501
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
1502
    public boolean isSet(_Fields field) {
1503
      if (field == null) {
1504
        throw new IllegalArgumentException();
1505
      }
668 chandransh 1506
 
1507
      switch (field) {
1508
      case SUCCESS:
1509
        return isSetSuccess();
1510
      case LSE:
1511
        return isSetLse();
1512
      }
1513
      throw new IllegalStateException();
1514
    }
1515
 
1516
    @Override
1517
    public boolean equals(Object that) {
1518
      if (that == null)
1519
        return false;
1520
      if (that instanceof getProvider_result)
1521
        return this.equals((getProvider_result)that);
1522
      return false;
1523
    }
1524
 
1525
    public boolean equals(getProvider_result that) {
1526
      if (that == null)
1527
        return false;
1528
 
1529
      boolean this_present_success = true && this.isSetSuccess();
1530
      boolean that_present_success = true && that.isSetSuccess();
1531
      if (this_present_success || that_present_success) {
1532
        if (!(this_present_success && that_present_success))
1533
          return false;
1534
        if (!this.success.equals(that.success))
1535
          return false;
1536
      }
1537
 
1538
      boolean this_present_lse = true && this.isSetLse();
1539
      boolean that_present_lse = true && that.isSetLse();
1540
      if (this_present_lse || that_present_lse) {
1541
        if (!(this_present_lse && that_present_lse))
1542
          return false;
1543
        if (!this.lse.equals(that.lse))
1544
          return false;
1545
      }
1546
 
1547
      return true;
1548
    }
1549
 
1550
    @Override
1551
    public int hashCode() {
1552
      return 0;
1553
    }
1554
 
3430 rajveer 1555
    public int compareTo(getProvider_result other) {
1556
      if (!getClass().equals(other.getClass())) {
1557
        return getClass().getName().compareTo(other.getClass().getName());
1558
      }
1559
 
1560
      int lastComparison = 0;
1561
      getProvider_result typedOther = (getProvider_result)other;
1562
 
1563
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
1564
      if (lastComparison != 0) {
1565
        return lastComparison;
1566
      }
1567
      if (isSetSuccess()) {
1568
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
1569
        if (lastComparison != 0) {
1570
          return lastComparison;
1571
        }
1572
      }
1573
      lastComparison = Boolean.valueOf(isSetLse()).compareTo(typedOther.isSetLse());
1574
      if (lastComparison != 0) {
1575
        return lastComparison;
1576
      }
1577
      if (isSetLse()) {
1578
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.lse, typedOther.lse);
1579
        if (lastComparison != 0) {
1580
          return lastComparison;
1581
        }
1582
      }
1583
      return 0;
1584
    }
1585
 
1586
    public _Fields fieldForId(int fieldId) {
1587
      return _Fields.findByThriftId(fieldId);
1588
    }
1589
 
1590
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
1591
      org.apache.thrift.protocol.TField field;
668 chandransh 1592
      iprot.readStructBegin();
1593
      while (true)
1594
      {
1595
        field = iprot.readFieldBegin();
3430 rajveer 1596
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
668 chandransh 1597
          break;
1598
        }
3430 rajveer 1599
        switch (field.id) {
1600
          case 0: // SUCCESS
1601
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
1602
              this.success = new Provider();
1603
              this.success.read(iprot);
1604
            } else { 
1605
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1606
            }
1607
            break;
1608
          case 1: // LSE
1609
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
1610
              this.lse = new LogisticsServiceException();
1611
              this.lse.read(iprot);
1612
            } else { 
1613
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1614
            }
1615
            break;
1616
          default:
1617
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
668 chandransh 1618
        }
3430 rajveer 1619
        iprot.readFieldEnd();
668 chandransh 1620
      }
1621
      iprot.readStructEnd();
1622
      validate();
1623
    }
1624
 
3430 rajveer 1625
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
668 chandransh 1626
      oprot.writeStructBegin(STRUCT_DESC);
1627
 
1628
      if (this.isSetSuccess()) {
1629
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
1630
        this.success.write(oprot);
1631
        oprot.writeFieldEnd();
1632
      } else if (this.isSetLse()) {
1633
        oprot.writeFieldBegin(LSE_FIELD_DESC);
1634
        this.lse.write(oprot);
1635
        oprot.writeFieldEnd();
1636
      }
1637
      oprot.writeFieldStop();
1638
      oprot.writeStructEnd();
1639
    }
1640
 
1641
    @Override
1642
    public String toString() {
1643
      StringBuilder sb = new StringBuilder("getProvider_result(");
1644
      boolean first = true;
1645
 
1646
      sb.append("success:");
1647
      if (this.success == null) {
1648
        sb.append("null");
1649
      } else {
1650
        sb.append(this.success);
1651
      }
1652
      first = false;
1653
      if (!first) sb.append(", ");
1654
      sb.append("lse:");
1655
      if (this.lse == null) {
1656
        sb.append("null");
1657
      } else {
1658
        sb.append(this.lse);
1659
      }
1660
      first = false;
1661
      sb.append(")");
1662
      return sb.toString();
1663
    }
1664
 
3430 rajveer 1665
    public void validate() throws org.apache.thrift.TException {
668 chandransh 1666
      // check for required fields
1667
    }
1668
 
3430 rajveer 1669
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
1670
      try {
1671
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
1672
      } catch (org.apache.thrift.TException te) {
1673
        throw new java.io.IOException(te);
1674
      }
1675
    }
1676
 
1677
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
1678
      try {
1679
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
1680
      } catch (org.apache.thrift.TException te) {
1681
        throw new java.io.IOException(te);
1682
      }
1683
    }
1684
 
668 chandransh 1685
  }
1686
 
3430 rajveer 1687
  public static class getAllProviders_args implements org.apache.thrift.TBase<getAllProviders_args, getAllProviders_args._Fields>, java.io.Serializable, Cloneable   {
1688
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllProviders_args");
674 chandransh 1689
 
1690
 
1691
 
1692
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 1693
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
674 chandransh 1694
;
1695
 
1696
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
1697
 
1698
      static {
1699
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
1700
          byName.put(field.getFieldName(), field);
1701
        }
1702
      }
1703
 
1704
      /**
1705
       * Find the _Fields constant that matches fieldId, or null if its not found.
1706
       */
1707
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 1708
        switch(fieldId) {
1709
          default:
1710
            return null;
1711
        }
674 chandransh 1712
      }
1713
 
1714
      /**
1715
       * Find the _Fields constant that matches fieldId, throwing an exception
1716
       * if it is not found.
1717
       */
1718
      public static _Fields findByThriftIdOrThrow(int fieldId) {
1719
        _Fields fields = findByThriftId(fieldId);
1720
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
1721
        return fields;
1722
      }
1723
 
1724
      /**
1725
       * Find the _Fields constant that matches name, or null if its not found.
1726
       */
1727
      public static _Fields findByName(String name) {
1728
        return byName.get(name);
1729
      }
1730
 
1731
      private final short _thriftId;
1732
      private final String _fieldName;
1733
 
1734
      _Fields(short thriftId, String fieldName) {
1735
        _thriftId = thriftId;
1736
        _fieldName = fieldName;
1737
      }
1738
 
1739
      public short getThriftFieldId() {
1740
        return _thriftId;
1741
      }
1742
 
1743
      public String getFieldName() {
1744
        return _fieldName;
1745
      }
1746
    }
3430 rajveer 1747
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
674 chandransh 1748
    static {
3430 rajveer 1749
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
1750
      metaDataMap = Collections.unmodifiableMap(tmpMap);
1751
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllProviders_args.class, metaDataMap);
674 chandransh 1752
    }
1753
 
1754
    public getAllProviders_args() {
1755
    }
1756
 
1757
    /**
1758
     * Performs a deep copy on <i>other</i>.
1759
     */
1760
    public getAllProviders_args(getAllProviders_args other) {
1761
    }
1762
 
1763
    public getAllProviders_args deepCopy() {
1764
      return new getAllProviders_args(this);
1765
    }
1766
 
3430 rajveer 1767
    @Override
1768
    public void clear() {
674 chandransh 1769
    }
1770
 
1771
    public void setFieldValue(_Fields field, Object value) {
1772
      switch (field) {
1773
      }
1774
    }
1775
 
1776
    public Object getFieldValue(_Fields field) {
1777
      switch (field) {
1778
      }
1779
      throw new IllegalStateException();
1780
    }
1781
 
3430 rajveer 1782
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
1783
    public boolean isSet(_Fields field) {
1784
      if (field == null) {
1785
        throw new IllegalArgumentException();
1786
      }
674 chandransh 1787
 
1788
      switch (field) {
1789
      }
1790
      throw new IllegalStateException();
1791
    }
1792
 
1793
    @Override
1794
    public boolean equals(Object that) {
1795
      if (that == null)
1796
        return false;
1797
      if (that instanceof getAllProviders_args)
1798
        return this.equals((getAllProviders_args)that);
1799
      return false;
1800
    }
1801
 
1802
    public boolean equals(getAllProviders_args that) {
1803
      if (that == null)
1804
        return false;
1805
 
1806
      return true;
1807
    }
1808
 
1809
    @Override
1810
    public int hashCode() {
1811
      return 0;
1812
    }
1813
 
1814
    public int compareTo(getAllProviders_args other) {
1815
      if (!getClass().equals(other.getClass())) {
1816
        return getClass().getName().compareTo(other.getClass().getName());
1817
      }
1818
 
1819
      int lastComparison = 0;
1820
      getAllProviders_args typedOther = (getAllProviders_args)other;
1821
 
1822
      return 0;
1823
    }
1824
 
3430 rajveer 1825
    public _Fields fieldForId(int fieldId) {
1826
      return _Fields.findByThriftId(fieldId);
1827
    }
1828
 
1829
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
1830
      org.apache.thrift.protocol.TField field;
674 chandransh 1831
      iprot.readStructBegin();
1832
      while (true)
1833
      {
1834
        field = iprot.readFieldBegin();
3430 rajveer 1835
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
674 chandransh 1836
          break;
1837
        }
3430 rajveer 1838
        switch (field.id) {
1839
          default:
1840
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
674 chandransh 1841
        }
3430 rajveer 1842
        iprot.readFieldEnd();
674 chandransh 1843
      }
1844
      iprot.readStructEnd();
1845
      validate();
1846
    }
1847
 
3430 rajveer 1848
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
674 chandransh 1849
      validate();
1850
 
1851
      oprot.writeStructBegin(STRUCT_DESC);
1852
      oprot.writeFieldStop();
1853
      oprot.writeStructEnd();
1854
    }
1855
 
1856
    @Override
1857
    public String toString() {
1858
      StringBuilder sb = new StringBuilder("getAllProviders_args(");
1859
      boolean first = true;
1860
 
1861
      sb.append(")");
1862
      return sb.toString();
1863
    }
1864
 
3430 rajveer 1865
    public void validate() throws org.apache.thrift.TException {
674 chandransh 1866
      // check for required fields
1867
    }
1868
 
3430 rajveer 1869
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
1870
      try {
1871
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
1872
      } catch (org.apache.thrift.TException te) {
1873
        throw new java.io.IOException(te);
1874
      }
1875
    }
1876
 
1877
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
1878
      try {
1879
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
1880
      } catch (org.apache.thrift.TException te) {
1881
        throw new java.io.IOException(te);
1882
      }
1883
    }
1884
 
674 chandransh 1885
  }
1886
 
3430 rajveer 1887
  public static class getAllProviders_result implements org.apache.thrift.TBase<getAllProviders_result, getAllProviders_result._Fields>, java.io.Serializable, Cloneable   {
1888
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getAllProviders_result");
674 chandransh 1889
 
3430 rajveer 1890
    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);
1891
    private static final org.apache.thrift.protocol.TField LSE_FIELD_DESC = new org.apache.thrift.protocol.TField("lse", org.apache.thrift.protocol.TType.STRUCT, (short)1);
674 chandransh 1892
 
3430 rajveer 1893
    private List<Provider> success; // required
1894
    private LogisticsServiceException lse; // required
674 chandransh 1895
 
1896
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 1897
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
674 chandransh 1898
      SUCCESS((short)0, "success"),
1899
      LSE((short)1, "lse");
1900
 
1901
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
1902
 
1903
      static {
1904
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
1905
          byName.put(field.getFieldName(), field);
1906
        }
1907
      }
1908
 
1909
      /**
1910
       * Find the _Fields constant that matches fieldId, or null if its not found.
1911
       */
1912
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 1913
        switch(fieldId) {
1914
          case 0: // SUCCESS
1915
            return SUCCESS;
1916
          case 1: // LSE
1917
            return LSE;
1918
          default:
1919
            return null;
1920
        }
674 chandransh 1921
      }
1922
 
1923
      /**
1924
       * Find the _Fields constant that matches fieldId, throwing an exception
1925
       * if it is not found.
1926
       */
1927
      public static _Fields findByThriftIdOrThrow(int fieldId) {
1928
        _Fields fields = findByThriftId(fieldId);
1929
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
1930
        return fields;
1931
      }
1932
 
1933
      /**
1934
       * Find the _Fields constant that matches name, or null if its not found.
1935
       */
1936
      public static _Fields findByName(String name) {
1937
        return byName.get(name);
1938
      }
1939
 
1940
      private final short _thriftId;
1941
      private final String _fieldName;
1942
 
1943
      _Fields(short thriftId, String fieldName) {
1944
        _thriftId = thriftId;
1945
        _fieldName = fieldName;
1946
      }
1947
 
1948
      public short getThriftFieldId() {
1949
        return _thriftId;
1950
      }
1951
 
1952
      public String getFieldName() {
1953
        return _fieldName;
1954
      }
1955
    }
1956
 
1957
    // isset id assignments
1958
 
3430 rajveer 1959
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
674 chandransh 1960
    static {
3430 rajveer 1961
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
1962
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
1963
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
1964
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, Provider.class))));
1965
      tmpMap.put(_Fields.LSE, new org.apache.thrift.meta_data.FieldMetaData("lse", org.apache.thrift.TFieldRequirementType.DEFAULT, 
1966
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
1967
      metaDataMap = Collections.unmodifiableMap(tmpMap);
1968
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getAllProviders_result.class, metaDataMap);
674 chandransh 1969
    }
1970
 
1971
    public getAllProviders_result() {
1972
    }
1973
 
1974
    public getAllProviders_result(
1975
      List<Provider> success,
1976
      LogisticsServiceException lse)
1977
    {
1978
      this();
1979
      this.success = success;
1980
      this.lse = lse;
1981
    }
1982
 
1983
    /**
1984
     * Performs a deep copy on <i>other</i>.
1985
     */
1986
    public getAllProviders_result(getAllProviders_result other) {
1987
      if (other.isSetSuccess()) {
1988
        List<Provider> __this__success = new ArrayList<Provider>();
1989
        for (Provider other_element : other.success) {
1990
          __this__success.add(new Provider(other_element));
1991
        }
1992
        this.success = __this__success;
1993
      }
1994
      if (other.isSetLse()) {
1995
        this.lse = new LogisticsServiceException(other.lse);
1996
      }
1997
    }
1998
 
1999
    public getAllProviders_result deepCopy() {
2000
      return new getAllProviders_result(this);
2001
    }
2002
 
3430 rajveer 2003
    @Override
2004
    public void clear() {
2005
      this.success = null;
2006
      this.lse = null;
674 chandransh 2007
    }
2008
 
2009
    public int getSuccessSize() {
2010
      return (this.success == null) ? 0 : this.success.size();
2011
    }
2012
 
2013
    public java.util.Iterator<Provider> getSuccessIterator() {
2014
      return (this.success == null) ? null : this.success.iterator();
2015
    }
2016
 
2017
    public void addToSuccess(Provider elem) {
2018
      if (this.success == null) {
2019
        this.success = new ArrayList<Provider>();
2020
      }
2021
      this.success.add(elem);
2022
    }
2023
 
2024
    public List<Provider> getSuccess() {
2025
      return this.success;
2026
    }
2027
 
3430 rajveer 2028
    public void setSuccess(List<Provider> success) {
674 chandransh 2029
      this.success = success;
2030
    }
2031
 
2032
    public void unsetSuccess() {
2033
      this.success = null;
2034
    }
2035
 
3430 rajveer 2036
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
674 chandransh 2037
    public boolean isSetSuccess() {
2038
      return this.success != null;
2039
    }
2040
 
2041
    public void setSuccessIsSet(boolean value) {
2042
      if (!value) {
2043
        this.success = null;
2044
      }
2045
    }
2046
 
2047
    public LogisticsServiceException getLse() {
2048
      return this.lse;
2049
    }
2050
 
3430 rajveer 2051
    public void setLse(LogisticsServiceException lse) {
674 chandransh 2052
      this.lse = lse;
2053
    }
2054
 
2055
    public void unsetLse() {
2056
      this.lse = null;
2057
    }
2058
 
3430 rajveer 2059
    /** Returns true if field lse is set (has been assigned a value) and false otherwise */
674 chandransh 2060
    public boolean isSetLse() {
2061
      return this.lse != null;
2062
    }
2063
 
2064
    public void setLseIsSet(boolean value) {
2065
      if (!value) {
2066
        this.lse = null;
2067
      }
2068
    }
2069
 
2070
    public void setFieldValue(_Fields field, Object value) {
2071
      switch (field) {
2072
      case SUCCESS:
2073
        if (value == null) {
2074
          unsetSuccess();
2075
        } else {
2076
          setSuccess((List<Provider>)value);
2077
        }
2078
        break;
2079
 
2080
      case LSE:
2081
        if (value == null) {
2082
          unsetLse();
2083
        } else {
2084
          setLse((LogisticsServiceException)value);
2085
        }
2086
        break;
2087
 
2088
      }
2089
    }
2090
 
2091
    public Object getFieldValue(_Fields field) {
2092
      switch (field) {
2093
      case SUCCESS:
2094
        return getSuccess();
2095
 
2096
      case LSE:
2097
        return getLse();
2098
 
2099
      }
2100
      throw new IllegalStateException();
2101
    }
2102
 
3430 rajveer 2103
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2104
    public boolean isSet(_Fields field) {
2105
      if (field == null) {
2106
        throw new IllegalArgumentException();
2107
      }
674 chandransh 2108
 
2109
      switch (field) {
2110
      case SUCCESS:
2111
        return isSetSuccess();
2112
      case LSE:
2113
        return isSetLse();
2114
      }
2115
      throw new IllegalStateException();
2116
    }
2117
 
2118
    @Override
2119
    public boolean equals(Object that) {
2120
      if (that == null)
2121
        return false;
2122
      if (that instanceof getAllProviders_result)
2123
        return this.equals((getAllProviders_result)that);
2124
      return false;
2125
    }
2126
 
2127
    public boolean equals(getAllProviders_result that) {
2128
      if (that == null)
2129
        return false;
2130
 
2131
      boolean this_present_success = true && this.isSetSuccess();
2132
      boolean that_present_success = true && that.isSetSuccess();
2133
      if (this_present_success || that_present_success) {
2134
        if (!(this_present_success && that_present_success))
2135
          return false;
2136
        if (!this.success.equals(that.success))
2137
          return false;
2138
      }
2139
 
2140
      boolean this_present_lse = true && this.isSetLse();
2141
      boolean that_present_lse = true && that.isSetLse();
2142
      if (this_present_lse || that_present_lse) {
2143
        if (!(this_present_lse && that_present_lse))
2144
          return false;
2145
        if (!this.lse.equals(that.lse))
2146
          return false;
2147
      }
2148
 
2149
      return true;
2150
    }
2151
 
2152
    @Override
2153
    public int hashCode() {
2154
      return 0;
2155
    }
2156
 
3430 rajveer 2157
    public int compareTo(getAllProviders_result other) {
2158
      if (!getClass().equals(other.getClass())) {
2159
        return getClass().getName().compareTo(other.getClass().getName());
2160
      }
2161
 
2162
      int lastComparison = 0;
2163
      getAllProviders_result typedOther = (getAllProviders_result)other;
2164
 
2165
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
2166
      if (lastComparison != 0) {
2167
        return lastComparison;
2168
      }
2169
      if (isSetSuccess()) {
2170
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
2171
        if (lastComparison != 0) {
2172
          return lastComparison;
2173
        }
2174
      }
2175
      lastComparison = Boolean.valueOf(isSetLse()).compareTo(typedOther.isSetLse());
2176
      if (lastComparison != 0) {
2177
        return lastComparison;
2178
      }
2179
      if (isSetLse()) {
2180
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.lse, typedOther.lse);
2181
        if (lastComparison != 0) {
2182
          return lastComparison;
2183
        }
2184
      }
2185
      return 0;
2186
    }
2187
 
2188
    public _Fields fieldForId(int fieldId) {
2189
      return _Fields.findByThriftId(fieldId);
2190
    }
2191
 
2192
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2193
      org.apache.thrift.protocol.TField field;
674 chandransh 2194
      iprot.readStructBegin();
2195
      while (true)
2196
      {
2197
        field = iprot.readFieldBegin();
3430 rajveer 2198
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
674 chandransh 2199
          break;
2200
        }
3430 rajveer 2201
        switch (field.id) {
2202
          case 0: // SUCCESS
2203
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
2204
              {
2205
                org.apache.thrift.protocol.TList _list5 = iprot.readListBegin();
2206
                this.success = new ArrayList<Provider>(_list5.size);
2207
                for (int _i6 = 0; _i6 < _list5.size; ++_i6)
674 chandransh 2208
                {
3430 rajveer 2209
                  Provider _elem7; // required
2210
                  _elem7 = new Provider();
2211
                  _elem7.read(iprot);
2212
                  this.success.add(_elem7);
674 chandransh 2213
                }
3430 rajveer 2214
                iprot.readListEnd();
674 chandransh 2215
              }
3430 rajveer 2216
            } else { 
2217
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2218
            }
2219
            break;
2220
          case 1: // LSE
2221
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
2222
              this.lse = new LogisticsServiceException();
2223
              this.lse.read(iprot);
2224
            } else { 
2225
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2226
            }
2227
            break;
2228
          default:
2229
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
674 chandransh 2230
        }
3430 rajveer 2231
        iprot.readFieldEnd();
674 chandransh 2232
      }
2233
      iprot.readStructEnd();
2234
      validate();
2235
    }
2236
 
3430 rajveer 2237
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
674 chandransh 2238
      oprot.writeStructBegin(STRUCT_DESC);
2239
 
2240
      if (this.isSetSuccess()) {
2241
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
2242
        {
3430 rajveer 2243
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
3044 chandransh 2244
          for (Provider _iter8 : this.success)
674 chandransh 2245
          {
3044 chandransh 2246
            _iter8.write(oprot);
674 chandransh 2247
          }
2248
          oprot.writeListEnd();
2249
        }
2250
        oprot.writeFieldEnd();
2251
      } else if (this.isSetLse()) {
2252
        oprot.writeFieldBegin(LSE_FIELD_DESC);
2253
        this.lse.write(oprot);
2254
        oprot.writeFieldEnd();
2255
      }
2256
      oprot.writeFieldStop();
2257
      oprot.writeStructEnd();
2258
    }
2259
 
2260
    @Override
2261
    public String toString() {
2262
      StringBuilder sb = new StringBuilder("getAllProviders_result(");
2263
      boolean first = true;
2264
 
2265
      sb.append("success:");
2266
      if (this.success == null) {
2267
        sb.append("null");
2268
      } else {
2269
        sb.append(this.success);
2270
      }
2271
      first = false;
2272
      if (!first) sb.append(", ");
2273
      sb.append("lse:");
2274
      if (this.lse == null) {
2275
        sb.append("null");
2276
      } else {
2277
        sb.append(this.lse);
2278
      }
2279
      first = false;
2280
      sb.append(")");
2281
      return sb.toString();
2282
    }
2283
 
3430 rajveer 2284
    public void validate() throws org.apache.thrift.TException {
674 chandransh 2285
      // check for required fields
2286
    }
2287
 
3430 rajveer 2288
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
2289
      try {
2290
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
2291
      } catch (org.apache.thrift.TException te) {
2292
        throw new java.io.IOException(te);
2293
      }
2294
    }
2295
 
2296
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
2297
      try {
2298
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
2299
      } catch (org.apache.thrift.TException te) {
2300
        throw new java.io.IOException(te);
2301
      }
2302
    }
2303
 
674 chandransh 2304
  }
2305
 
3430 rajveer 2306
  public static class getLogisticsEstimation_args implements org.apache.thrift.TBase<getLogisticsEstimation_args, getLogisticsEstimation_args._Fields>, java.io.Serializable, Cloneable   {
2307
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getLogisticsEstimation_args");
471 rajveer 2308
 
3430 rajveer 2309
    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);
2310
    private static final org.apache.thrift.protocol.TField DESTINATION_PIN_FIELD_DESC = new org.apache.thrift.protocol.TField("destination_pin", org.apache.thrift.protocol.TType.STRING, (short)2);
4630 mandeep.dh 2311
    private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)3);
471 rajveer 2312
 
3430 rajveer 2313
    private long itemId; // required
2314
    private String destination_pin; // required
4630 mandeep.dh 2315
    private DeliveryType type; // required
471 rajveer 2316
 
2317
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2318
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
471 rajveer 2319
      ITEM_ID((short)1, "itemId"),
4630 mandeep.dh 2320
      DESTINATION_PIN((short)2, "destination_pin"),
2321
      /**
2322
       * 
2323
       * @see DeliveryType
2324
       */
2325
      TYPE((short)3, "type");
471 rajveer 2326
 
2327
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2328
 
2329
      static {
2330
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2331
          byName.put(field.getFieldName(), field);
2332
        }
2333
      }
2334
 
2335
      /**
2336
       * Find the _Fields constant that matches fieldId, or null if its not found.
2337
       */
2338
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2339
        switch(fieldId) {
2340
          case 1: // ITEM_ID
2341
            return ITEM_ID;
2342
          case 2: // DESTINATION_PIN
2343
            return DESTINATION_PIN;
4630 mandeep.dh 2344
          case 3: // TYPE
2345
            return TYPE;
3430 rajveer 2346
          default:
2347
            return null;
2348
        }
471 rajveer 2349
      }
2350
 
2351
      /**
2352
       * Find the _Fields constant that matches fieldId, throwing an exception
2353
       * if it is not found.
2354
       */
2355
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2356
        _Fields fields = findByThriftId(fieldId);
2357
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2358
        return fields;
2359
      }
2360
 
2361
      /**
2362
       * Find the _Fields constant that matches name, or null if its not found.
2363
       */
2364
      public static _Fields findByName(String name) {
2365
        return byName.get(name);
2366
      }
2367
 
2368
      private final short _thriftId;
2369
      private final String _fieldName;
2370
 
2371
      _Fields(short thriftId, String fieldName) {
2372
        _thriftId = thriftId;
2373
        _fieldName = fieldName;
2374
      }
2375
 
2376
      public short getThriftFieldId() {
2377
        return _thriftId;
2378
      }
2379
 
2380
      public String getFieldName() {
2381
        return _fieldName;
2382
      }
2383
    }
2384
 
2385
    // isset id assignments
2386
    private static final int __ITEMID_ISSET_ID = 0;
648 chandransh 2387
    private BitSet __isset_bit_vector = new BitSet(1);
471 rajveer 2388
 
3430 rajveer 2389
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
471 rajveer 2390
    static {
3430 rajveer 2391
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2392
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("itemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2393
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
2394
      tmpMap.put(_Fields.DESTINATION_PIN, new org.apache.thrift.meta_data.FieldMetaData("destination_pin", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2395
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
4630 mandeep.dh 2396
      tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2397
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, DeliveryType.class)));
3430 rajveer 2398
      metaDataMap = Collections.unmodifiableMap(tmpMap);
2399
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getLogisticsEstimation_args.class, metaDataMap);
471 rajveer 2400
    }
2401
 
2402
    public getLogisticsEstimation_args() {
2403
    }
2404
 
2405
    public getLogisticsEstimation_args(
2406
      long itemId,
4630 mandeep.dh 2407
      String destination_pin,
2408
      DeliveryType type)
471 rajveer 2409
    {
2410
      this();
2411
      this.itemId = itemId;
2412
      setItemIdIsSet(true);
2413
      this.destination_pin = destination_pin;
4630 mandeep.dh 2414
      this.type = type;
471 rajveer 2415
    }
2416
 
2417
    /**
2418
     * Performs a deep copy on <i>other</i>.
2419
     */
2420
    public getLogisticsEstimation_args(getLogisticsEstimation_args other) {
2421
      __isset_bit_vector.clear();
2422
      __isset_bit_vector.or(other.__isset_bit_vector);
2423
      this.itemId = other.itemId;
2424
      if (other.isSetDestination_pin()) {
2425
        this.destination_pin = other.destination_pin;
2426
      }
4630 mandeep.dh 2427
      if (other.isSetType()) {
2428
        this.type = other.type;
2429
      }
471 rajveer 2430
    }
2431
 
2432
    public getLogisticsEstimation_args deepCopy() {
2433
      return new getLogisticsEstimation_args(this);
2434
    }
2435
 
3430 rajveer 2436
    @Override
2437
    public void clear() {
2438
      setItemIdIsSet(false);
2439
      this.itemId = 0;
2440
      this.destination_pin = null;
4630 mandeep.dh 2441
      this.type = null;
471 rajveer 2442
    }
2443
 
2444
    public long getItemId() {
2445
      return this.itemId;
2446
    }
2447
 
3430 rajveer 2448
    public void setItemId(long itemId) {
471 rajveer 2449
      this.itemId = itemId;
2450
      setItemIdIsSet(true);
2451
    }
2452
 
2453
    public void unsetItemId() {
2454
      __isset_bit_vector.clear(__ITEMID_ISSET_ID);
2455
    }
2456
 
3430 rajveer 2457
    /** Returns true if field itemId is set (has been assigned a value) and false otherwise */
471 rajveer 2458
    public boolean isSetItemId() {
2459
      return __isset_bit_vector.get(__ITEMID_ISSET_ID);
2460
    }
2461
 
2462
    public void setItemIdIsSet(boolean value) {
2463
      __isset_bit_vector.set(__ITEMID_ISSET_ID, value);
2464
    }
2465
 
2466
    public String getDestination_pin() {
2467
      return this.destination_pin;
2468
    }
2469
 
3430 rajveer 2470
    public void setDestination_pin(String destination_pin) {
471 rajveer 2471
      this.destination_pin = destination_pin;
2472
    }
2473
 
2474
    public void unsetDestination_pin() {
2475
      this.destination_pin = null;
2476
    }
2477
 
3430 rajveer 2478
    /** Returns true if field destination_pin is set (has been assigned a value) and false otherwise */
471 rajveer 2479
    public boolean isSetDestination_pin() {
2480
      return this.destination_pin != null;
2481
    }
2482
 
2483
    public void setDestination_pinIsSet(boolean value) {
2484
      if (!value) {
2485
        this.destination_pin = null;
2486
      }
2487
    }
2488
 
4630 mandeep.dh 2489
    /**
2490
     * 
2491
     * @see DeliveryType
2492
     */
2493
    public DeliveryType getType() {
2494
      return this.type;
2495
    }
2496
 
2497
    /**
2498
     * 
2499
     * @see DeliveryType
2500
     */
2501
    public void setType(DeliveryType type) {
2502
      this.type = type;
2503
    }
2504
 
2505
    public void unsetType() {
2506
      this.type = null;
2507
    }
2508
 
2509
    /** Returns true if field type is set (has been assigned a value) and false otherwise */
2510
    public boolean isSetType() {
2511
      return this.type != null;
2512
    }
2513
 
2514
    public void setTypeIsSet(boolean value) {
2515
      if (!value) {
2516
        this.type = null;
2517
      }
2518
    }
2519
 
471 rajveer 2520
    public void setFieldValue(_Fields field, Object value) {
2521
      switch (field) {
2522
      case ITEM_ID:
2523
        if (value == null) {
2524
          unsetItemId();
2525
        } else {
2526
          setItemId((Long)value);
2527
        }
2528
        break;
2529
 
2530
      case DESTINATION_PIN:
2531
        if (value == null) {
2532
          unsetDestination_pin();
2533
        } else {
2534
          setDestination_pin((String)value);
2535
        }
2536
        break;
2537
 
4630 mandeep.dh 2538
      case TYPE:
2539
        if (value == null) {
2540
          unsetType();
2541
        } else {
2542
          setType((DeliveryType)value);
2543
        }
2544
        break;
2545
 
471 rajveer 2546
      }
2547
    }
2548
 
2549
    public Object getFieldValue(_Fields field) {
2550
      switch (field) {
2551
      case ITEM_ID:
3430 rajveer 2552
        return Long.valueOf(getItemId());
471 rajveer 2553
 
2554
      case DESTINATION_PIN:
2555
        return getDestination_pin();
2556
 
4630 mandeep.dh 2557
      case TYPE:
2558
        return getType();
2559
 
471 rajveer 2560
      }
2561
      throw new IllegalStateException();
2562
    }
2563
 
3430 rajveer 2564
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2565
    public boolean isSet(_Fields field) {
2566
      if (field == null) {
2567
        throw new IllegalArgumentException();
2568
      }
471 rajveer 2569
 
2570
      switch (field) {
2571
      case ITEM_ID:
2572
        return isSetItemId();
2573
      case DESTINATION_PIN:
2574
        return isSetDestination_pin();
4630 mandeep.dh 2575
      case TYPE:
2576
        return isSetType();
471 rajveer 2577
      }
2578
      throw new IllegalStateException();
2579
    }
2580
 
2581
    @Override
2582
    public boolean equals(Object that) {
2583
      if (that == null)
2584
        return false;
2585
      if (that instanceof getLogisticsEstimation_args)
2586
        return this.equals((getLogisticsEstimation_args)that);
2587
      return false;
2588
    }
2589
 
2590
    public boolean equals(getLogisticsEstimation_args that) {
2591
      if (that == null)
2592
        return false;
2593
 
2594
      boolean this_present_itemId = true;
2595
      boolean that_present_itemId = true;
2596
      if (this_present_itemId || that_present_itemId) {
2597
        if (!(this_present_itemId && that_present_itemId))
2598
          return false;
2599
        if (this.itemId != that.itemId)
2600
          return false;
2601
      }
2602
 
2603
      boolean this_present_destination_pin = true && this.isSetDestination_pin();
2604
      boolean that_present_destination_pin = true && that.isSetDestination_pin();
2605
      if (this_present_destination_pin || that_present_destination_pin) {
2606
        if (!(this_present_destination_pin && that_present_destination_pin))
2607
          return false;
2608
        if (!this.destination_pin.equals(that.destination_pin))
2609
          return false;
2610
      }
2611
 
4630 mandeep.dh 2612
      boolean this_present_type = true && this.isSetType();
2613
      boolean that_present_type = true && that.isSetType();
2614
      if (this_present_type || that_present_type) {
2615
        if (!(this_present_type && that_present_type))
2616
          return false;
2617
        if (!this.type.equals(that.type))
2618
          return false;
2619
      }
2620
 
471 rajveer 2621
      return true;
2622
    }
2623
 
2624
    @Override
2625
    public int hashCode() {
2626
      return 0;
2627
    }
2628
 
2629
    public int compareTo(getLogisticsEstimation_args other) {
2630
      if (!getClass().equals(other.getClass())) {
2631
        return getClass().getName().compareTo(other.getClass().getName());
2632
      }
2633
 
2634
      int lastComparison = 0;
2635
      getLogisticsEstimation_args typedOther = (getLogisticsEstimation_args)other;
2636
 
3430 rajveer 2637
      lastComparison = Boolean.valueOf(isSetItemId()).compareTo(typedOther.isSetItemId());
471 rajveer 2638
      if (lastComparison != 0) {
2639
        return lastComparison;
2640
      }
3430 rajveer 2641
      if (isSetItemId()) {
2642
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.itemId, typedOther.itemId);
2643
        if (lastComparison != 0) {
2644
          return lastComparison;
2645
        }
471 rajveer 2646
      }
3430 rajveer 2647
      lastComparison = Boolean.valueOf(isSetDestination_pin()).compareTo(typedOther.isSetDestination_pin());
471 rajveer 2648
      if (lastComparison != 0) {
2649
        return lastComparison;
2650
      }
3430 rajveer 2651
      if (isSetDestination_pin()) {
2652
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.destination_pin, typedOther.destination_pin);
2653
        if (lastComparison != 0) {
2654
          return lastComparison;
2655
        }
471 rajveer 2656
      }
4630 mandeep.dh 2657
      lastComparison = Boolean.valueOf(isSetType()).compareTo(typedOther.isSetType());
2658
      if (lastComparison != 0) {
2659
        return lastComparison;
2660
      }
2661
      if (isSetType()) {
2662
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, typedOther.type);
2663
        if (lastComparison != 0) {
2664
          return lastComparison;
2665
        }
2666
      }
471 rajveer 2667
      return 0;
2668
    }
2669
 
3430 rajveer 2670
    public _Fields fieldForId(int fieldId) {
2671
      return _Fields.findByThriftId(fieldId);
2672
    }
2673
 
2674
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2675
      org.apache.thrift.protocol.TField field;
471 rajveer 2676
      iprot.readStructBegin();
2677
      while (true)
2678
      {
2679
        field = iprot.readFieldBegin();
3430 rajveer 2680
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
471 rajveer 2681
          break;
2682
        }
3430 rajveer 2683
        switch (field.id) {
2684
          case 1: // ITEM_ID
2685
            if (field.type == org.apache.thrift.protocol.TType.I64) {
2686
              this.itemId = iprot.readI64();
2687
              setItemIdIsSet(true);
2688
            } else { 
2689
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2690
            }
2691
            break;
2692
          case 2: // DESTINATION_PIN
2693
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
2694
              this.destination_pin = iprot.readString();
2695
            } else { 
2696
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2697
            }
2698
            break;
4630 mandeep.dh 2699
          case 3: // TYPE
2700
            if (field.type == org.apache.thrift.protocol.TType.I32) {
2701
              this.type = DeliveryType.findByValue(iprot.readI32());
2702
            } else { 
2703
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
2704
            }
2705
            break;
3430 rajveer 2706
          default:
2707
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
471 rajveer 2708
        }
3430 rajveer 2709
        iprot.readFieldEnd();
471 rajveer 2710
      }
2711
      iprot.readStructEnd();
2712
      validate();
2713
    }
2714
 
3430 rajveer 2715
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
471 rajveer 2716
      validate();
2717
 
2718
      oprot.writeStructBegin(STRUCT_DESC);
2719
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
2720
      oprot.writeI64(this.itemId);
2721
      oprot.writeFieldEnd();
2722
      if (this.destination_pin != null) {
2723
        oprot.writeFieldBegin(DESTINATION_PIN_FIELD_DESC);
2724
        oprot.writeString(this.destination_pin);
2725
        oprot.writeFieldEnd();
2726
      }
4630 mandeep.dh 2727
      if (this.type != null) {
2728
        oprot.writeFieldBegin(TYPE_FIELD_DESC);
2729
        oprot.writeI32(this.type.getValue());
2730
        oprot.writeFieldEnd();
2731
      }
471 rajveer 2732
      oprot.writeFieldStop();
2733
      oprot.writeStructEnd();
2734
    }
2735
 
2736
    @Override
2737
    public String toString() {
2738
      StringBuilder sb = new StringBuilder("getLogisticsEstimation_args(");
2739
      boolean first = true;
2740
 
2741
      sb.append("itemId:");
2742
      sb.append(this.itemId);
2743
      first = false;
2744
      if (!first) sb.append(", ");
2745
      sb.append("destination_pin:");
2746
      if (this.destination_pin == null) {
2747
        sb.append("null");
2748
      } else {
2749
        sb.append(this.destination_pin);
2750
      }
2751
      first = false;
4630 mandeep.dh 2752
      if (!first) sb.append(", ");
2753
      sb.append("type:");
2754
      if (this.type == null) {
2755
        sb.append("null");
2756
      } else {
2757
        sb.append(this.type);
2758
      }
2759
      first = false;
471 rajveer 2760
      sb.append(")");
2761
      return sb.toString();
2762
    }
2763
 
3430 rajveer 2764
    public void validate() throws org.apache.thrift.TException {
471 rajveer 2765
      // check for required fields
2766
    }
2767
 
3430 rajveer 2768
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
2769
      try {
2770
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
2771
      } catch (org.apache.thrift.TException te) {
2772
        throw new java.io.IOException(te);
2773
      }
2774
    }
2775
 
2776
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
2777
      try {
2778
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
2779
      } catch (org.apache.thrift.TException te) {
2780
        throw new java.io.IOException(te);
2781
      }
2782
    }
2783
 
471 rajveer 2784
  }
2785
 
3430 rajveer 2786
  public static class getLogisticsEstimation_result implements org.apache.thrift.TBase<getLogisticsEstimation_result, getLogisticsEstimation_result._Fields>, java.io.Serializable, Cloneable   {
2787
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getLogisticsEstimation_result");
471 rajveer 2788
 
3430 rajveer 2789
    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);
2790
    private static final org.apache.thrift.protocol.TField SE_FIELD_DESC = new org.apache.thrift.protocol.TField("se", org.apache.thrift.protocol.TType.STRUCT, (short)1);
471 rajveer 2791
 
3430 rajveer 2792
    private LogisticsInfo success; // required
2793
    private LogisticsServiceException se; // required
471 rajveer 2794
 
2795
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 2796
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
471 rajveer 2797
      SUCCESS((short)0, "success"),
2798
      SE((short)1, "se");
2799
 
2800
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2801
 
2802
      static {
2803
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
2804
          byName.put(field.getFieldName(), field);
2805
        }
2806
      }
2807
 
2808
      /**
2809
       * Find the _Fields constant that matches fieldId, or null if its not found.
2810
       */
2811
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 2812
        switch(fieldId) {
2813
          case 0: // SUCCESS
2814
            return SUCCESS;
2815
          case 1: // SE
2816
            return SE;
2817
          default:
2818
            return null;
2819
        }
471 rajveer 2820
      }
2821
 
2822
      /**
2823
       * Find the _Fields constant that matches fieldId, throwing an exception
2824
       * if it is not found.
2825
       */
2826
      public static _Fields findByThriftIdOrThrow(int fieldId) {
2827
        _Fields fields = findByThriftId(fieldId);
2828
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2829
        return fields;
2830
      }
2831
 
2832
      /**
2833
       * Find the _Fields constant that matches name, or null if its not found.
2834
       */
2835
      public static _Fields findByName(String name) {
2836
        return byName.get(name);
2837
      }
2838
 
2839
      private final short _thriftId;
2840
      private final String _fieldName;
2841
 
2842
      _Fields(short thriftId, String fieldName) {
2843
        _thriftId = thriftId;
2844
        _fieldName = fieldName;
2845
      }
2846
 
2847
      public short getThriftFieldId() {
2848
        return _thriftId;
2849
      }
2850
 
2851
      public String getFieldName() {
2852
        return _fieldName;
2853
      }
2854
    }
2855
 
2856
    // isset id assignments
2857
 
3430 rajveer 2858
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
471 rajveer 2859
    static {
3430 rajveer 2860
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2861
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2862
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, LogisticsInfo.class)));
2863
      tmpMap.put(_Fields.SE, new org.apache.thrift.meta_data.FieldMetaData("se", org.apache.thrift.TFieldRequirementType.DEFAULT, 
2864
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
2865
      metaDataMap = Collections.unmodifiableMap(tmpMap);
2866
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getLogisticsEstimation_result.class, metaDataMap);
471 rajveer 2867
    }
2868
 
2869
    public getLogisticsEstimation_result() {
2870
    }
2871
 
2872
    public getLogisticsEstimation_result(
648 chandransh 2873
      LogisticsInfo success,
471 rajveer 2874
      LogisticsServiceException se)
2875
    {
2876
      this();
2877
      this.success = success;
2878
      this.se = se;
2879
    }
2880
 
2881
    /**
2882
     * Performs a deep copy on <i>other</i>.
2883
     */
2884
    public getLogisticsEstimation_result(getLogisticsEstimation_result other) {
2885
      if (other.isSetSuccess()) {
648 chandransh 2886
        this.success = new LogisticsInfo(other.success);
471 rajveer 2887
      }
2888
      if (other.isSetSe()) {
2889
        this.se = new LogisticsServiceException(other.se);
2890
      }
2891
    }
2892
 
2893
    public getLogisticsEstimation_result deepCopy() {
2894
      return new getLogisticsEstimation_result(this);
2895
    }
2896
 
3430 rajveer 2897
    @Override
2898
    public void clear() {
2899
      this.success = null;
2900
      this.se = null;
471 rajveer 2901
    }
2902
 
648 chandransh 2903
    public LogisticsInfo getSuccess() {
471 rajveer 2904
      return this.success;
2905
    }
2906
 
3430 rajveer 2907
    public void setSuccess(LogisticsInfo success) {
471 rajveer 2908
      this.success = success;
2909
    }
2910
 
2911
    public void unsetSuccess() {
2912
      this.success = null;
2913
    }
2914
 
3430 rajveer 2915
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
471 rajveer 2916
    public boolean isSetSuccess() {
2917
      return this.success != null;
2918
    }
2919
 
2920
    public void setSuccessIsSet(boolean value) {
2921
      if (!value) {
2922
        this.success = null;
2923
      }
2924
    }
2925
 
2926
    public LogisticsServiceException getSe() {
2927
      return this.se;
2928
    }
2929
 
3430 rajveer 2930
    public void setSe(LogisticsServiceException se) {
471 rajveer 2931
      this.se = se;
2932
    }
2933
 
2934
    public void unsetSe() {
2935
      this.se = null;
2936
    }
2937
 
3430 rajveer 2938
    /** Returns true if field se is set (has been assigned a value) and false otherwise */
471 rajveer 2939
    public boolean isSetSe() {
2940
      return this.se != null;
2941
    }
2942
 
2943
    public void setSeIsSet(boolean value) {
2944
      if (!value) {
2945
        this.se = null;
2946
      }
2947
    }
2948
 
2949
    public void setFieldValue(_Fields field, Object value) {
2950
      switch (field) {
2951
      case SUCCESS:
2952
        if (value == null) {
2953
          unsetSuccess();
2954
        } else {
648 chandransh 2955
          setSuccess((LogisticsInfo)value);
471 rajveer 2956
        }
2957
        break;
2958
 
2959
      case SE:
2960
        if (value == null) {
2961
          unsetSe();
2962
        } else {
2963
          setSe((LogisticsServiceException)value);
2964
        }
2965
        break;
2966
 
2967
      }
2968
    }
2969
 
2970
    public Object getFieldValue(_Fields field) {
2971
      switch (field) {
2972
      case SUCCESS:
2973
        return getSuccess();
2974
 
2975
      case SE:
2976
        return getSe();
2977
 
2978
      }
2979
      throw new IllegalStateException();
2980
    }
2981
 
3430 rajveer 2982
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2983
    public boolean isSet(_Fields field) {
2984
      if (field == null) {
2985
        throw new IllegalArgumentException();
2986
      }
471 rajveer 2987
 
2988
      switch (field) {
2989
      case SUCCESS:
2990
        return isSetSuccess();
2991
      case SE:
2992
        return isSetSe();
2993
      }
2994
      throw new IllegalStateException();
2995
    }
2996
 
2997
    @Override
2998
    public boolean equals(Object that) {
2999
      if (that == null)
3000
        return false;
3001
      if (that instanceof getLogisticsEstimation_result)
3002
        return this.equals((getLogisticsEstimation_result)that);
3003
      return false;
3004
    }
3005
 
3006
    public boolean equals(getLogisticsEstimation_result that) {
3007
      if (that == null)
3008
        return false;
3009
 
3010
      boolean this_present_success = true && this.isSetSuccess();
3011
      boolean that_present_success = true && that.isSetSuccess();
3012
      if (this_present_success || that_present_success) {
3013
        if (!(this_present_success && that_present_success))
3014
          return false;
3015
        if (!this.success.equals(that.success))
3016
          return false;
3017
      }
3018
 
3019
      boolean this_present_se = true && this.isSetSe();
3020
      boolean that_present_se = true && that.isSetSe();
3021
      if (this_present_se || that_present_se) {
3022
        if (!(this_present_se && that_present_se))
3023
          return false;
3024
        if (!this.se.equals(that.se))
3025
          return false;
3026
      }
3027
 
3028
      return true;
3029
    }
3030
 
3031
    @Override
3032
    public int hashCode() {
3033
      return 0;
3034
    }
3035
 
3036
    public int compareTo(getLogisticsEstimation_result other) {
3037
      if (!getClass().equals(other.getClass())) {
3038
        return getClass().getName().compareTo(other.getClass().getName());
3039
      }
3040
 
3041
      int lastComparison = 0;
3042
      getLogisticsEstimation_result typedOther = (getLogisticsEstimation_result)other;
3043
 
3430 rajveer 3044
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
471 rajveer 3045
      if (lastComparison != 0) {
3046
        return lastComparison;
3047
      }
3430 rajveer 3048
      if (isSetSuccess()) {
3049
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3050
        if (lastComparison != 0) {
3051
          return lastComparison;
3052
        }
471 rajveer 3053
      }
3430 rajveer 3054
      lastComparison = Boolean.valueOf(isSetSe()).compareTo(typedOther.isSetSe());
471 rajveer 3055
      if (lastComparison != 0) {
3056
        return lastComparison;
3057
      }
3430 rajveer 3058
      if (isSetSe()) {
3059
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.se, typedOther.se);
3060
        if (lastComparison != 0) {
3061
          return lastComparison;
3062
        }
471 rajveer 3063
      }
3064
      return 0;
3065
    }
3066
 
3430 rajveer 3067
    public _Fields fieldForId(int fieldId) {
3068
      return _Fields.findByThriftId(fieldId);
3069
    }
3070
 
3071
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3072
      org.apache.thrift.protocol.TField field;
471 rajveer 3073
      iprot.readStructBegin();
3074
      while (true)
3075
      {
3076
        field = iprot.readFieldBegin();
3430 rajveer 3077
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
471 rajveer 3078
          break;
3079
        }
3430 rajveer 3080
        switch (field.id) {
3081
          case 0: // SUCCESS
3082
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3083
              this.success = new LogisticsInfo();
3084
              this.success.read(iprot);
3085
            } else { 
3086
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3087
            }
3088
            break;
3089
          case 1: // SE
3090
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3091
              this.se = new LogisticsServiceException();
3092
              this.se.read(iprot);
3093
            } else { 
3094
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3095
            }
3096
            break;
3097
          default:
3098
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
471 rajveer 3099
        }
3430 rajveer 3100
        iprot.readFieldEnd();
471 rajveer 3101
      }
3102
      iprot.readStructEnd();
3103
      validate();
3104
    }
3105
 
3430 rajveer 3106
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
471 rajveer 3107
      oprot.writeStructBegin(STRUCT_DESC);
3108
 
3109
      if (this.isSetSuccess()) {
3110
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3111
        this.success.write(oprot);
3112
        oprot.writeFieldEnd();
3113
      } else if (this.isSetSe()) {
3114
        oprot.writeFieldBegin(SE_FIELD_DESC);
3115
        this.se.write(oprot);
3116
        oprot.writeFieldEnd();
3117
      }
3118
      oprot.writeFieldStop();
3119
      oprot.writeStructEnd();
3120
    }
3121
 
3122
    @Override
3123
    public String toString() {
3124
      StringBuilder sb = new StringBuilder("getLogisticsEstimation_result(");
3125
      boolean first = true;
3126
 
3127
      sb.append("success:");
3128
      if (this.success == null) {
3129
        sb.append("null");
3130
      } else {
3131
        sb.append(this.success);
3132
      }
3133
      first = false;
3134
      if (!first) sb.append(", ");
3135
      sb.append("se:");
3136
      if (this.se == null) {
3137
        sb.append("null");
3138
      } else {
3139
        sb.append(this.se);
3140
      }
3141
      first = false;
3142
      sb.append(")");
3143
      return sb.toString();
3144
    }
3145
 
3430 rajveer 3146
    public void validate() throws org.apache.thrift.TException {
471 rajveer 3147
      // check for required fields
3148
    }
3149
 
3430 rajveer 3150
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3151
      try {
3152
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3153
      } catch (org.apache.thrift.TException te) {
3154
        throw new java.io.IOException(te);
3155
      }
3156
    }
3157
 
3158
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3159
      try {
3160
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3161
      } catch (org.apache.thrift.TException te) {
3162
        throw new java.io.IOException(te);
3163
      }
3164
    }
3165
 
471 rajveer 3166
  }
3167
 
3430 rajveer 3168
  public static class getLogisticsInfo_args implements org.apache.thrift.TBase<getLogisticsInfo_args, getLogisticsInfo_args._Fields>, java.io.Serializable, Cloneable   {
3169
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getLogisticsInfo_args");
471 rajveer 3170
 
3430 rajveer 3171
    private static final org.apache.thrift.protocol.TField DESTINATION_PINCODE_FIELD_DESC = new org.apache.thrift.protocol.TField("destination_pincode", org.apache.thrift.protocol.TType.STRING, (short)1);
3172
    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);
3173
    private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)3);
471 rajveer 3174
 
3430 rajveer 3175
    private String destination_pincode; // required
3176
    private long item_id; // required
3177
    private DeliveryType type; // required
471 rajveer 3178
 
3179
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3180
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
648 chandransh 3181
      DESTINATION_PINCODE((short)1, "destination_pincode"),
3044 chandransh 3182
      ITEM_ID((short)2, "item_id"),
3183
      /**
3184
       * 
3185
       * @see DeliveryType
3186
       */
3187
      TYPE((short)3, "type");
471 rajveer 3188
 
3189
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3190
 
3191
      static {
3192
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3193
          byName.put(field.getFieldName(), field);
3194
        }
3195
      }
3196
 
3197
      /**
3198
       * Find the _Fields constant that matches fieldId, or null if its not found.
3199
       */
3200
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3201
        switch(fieldId) {
3202
          case 1: // DESTINATION_PINCODE
3203
            return DESTINATION_PINCODE;
3204
          case 2: // ITEM_ID
3205
            return ITEM_ID;
3206
          case 3: // TYPE
3207
            return TYPE;
3208
          default:
3209
            return null;
3210
        }
471 rajveer 3211
      }
3212
 
3213
      /**
3214
       * Find the _Fields constant that matches fieldId, throwing an exception
3215
       * if it is not found.
3216
       */
3217
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3218
        _Fields fields = findByThriftId(fieldId);
3219
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3220
        return fields;
3221
      }
3222
 
3223
      /**
3224
       * Find the _Fields constant that matches name, or null if its not found.
3225
       */
3226
      public static _Fields findByName(String name) {
3227
        return byName.get(name);
3228
      }
3229
 
3230
      private final short _thriftId;
3231
      private final String _fieldName;
3232
 
3233
      _Fields(short thriftId, String fieldName) {
3234
        _thriftId = thriftId;
3235
        _fieldName = fieldName;
3236
      }
3237
 
3238
      public short getThriftFieldId() {
3239
        return _thriftId;
3240
      }
3241
 
3242
      public String getFieldName() {
3243
        return _fieldName;
3244
      }
3245
    }
3246
 
3247
    // isset id assignments
715 rajveer 3248
    private static final int __ITEM_ID_ISSET_ID = 0;
3249
    private BitSet __isset_bit_vector = new BitSet(1);
471 rajveer 3250
 
3430 rajveer 3251
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
477 rajveer 3252
    static {
3430 rajveer 3253
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3254
      tmpMap.put(_Fields.DESTINATION_PINCODE, new org.apache.thrift.meta_data.FieldMetaData("destination_pincode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3255
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
3256
      tmpMap.put(_Fields.ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("item_id", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3257
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
3258
      tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3259
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, DeliveryType.class)));
3260
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3261
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getLogisticsInfo_args.class, metaDataMap);
477 rajveer 3262
    }
3263
 
648 chandransh 3264
    public getLogisticsInfo_args() {
477 rajveer 3265
    }
3266
 
648 chandransh 3267
    public getLogisticsInfo_args(
3268
      String destination_pincode,
3044 chandransh 3269
      long item_id,
3270
      DeliveryType type)
477 rajveer 3271
    {
3272
      this();
648 chandransh 3273
      this.destination_pincode = destination_pincode;
3274
      this.item_id = item_id;
715 rajveer 3275
      setItem_idIsSet(true);
3044 chandransh 3276
      this.type = type;
477 rajveer 3277
    }
3278
 
3279
    /**
3280
     * Performs a deep copy on <i>other</i>.
3281
     */
648 chandransh 3282
    public getLogisticsInfo_args(getLogisticsInfo_args other) {
715 rajveer 3283
      __isset_bit_vector.clear();
3284
      __isset_bit_vector.or(other.__isset_bit_vector);
648 chandransh 3285
      if (other.isSetDestination_pincode()) {
3286
        this.destination_pincode = other.destination_pincode;
477 rajveer 3287
      }
715 rajveer 3288
      this.item_id = other.item_id;
3044 chandransh 3289
      if (other.isSetType()) {
3290
        this.type = other.type;
3291
      }
477 rajveer 3292
    }
3293
 
648 chandransh 3294
    public getLogisticsInfo_args deepCopy() {
3295
      return new getLogisticsInfo_args(this);
477 rajveer 3296
    }
3297
 
3430 rajveer 3298
    @Override
3299
    public void clear() {
3300
      this.destination_pincode = null;
3301
      setItem_idIsSet(false);
3302
      this.item_id = 0;
3303
      this.type = null;
477 rajveer 3304
    }
3305
 
648 chandransh 3306
    public String getDestination_pincode() {
3307
      return this.destination_pincode;
477 rajveer 3308
    }
3309
 
3430 rajveer 3310
    public void setDestination_pincode(String destination_pincode) {
648 chandransh 3311
      this.destination_pincode = destination_pincode;
477 rajveer 3312
    }
3313
 
648 chandransh 3314
    public void unsetDestination_pincode() {
3315
      this.destination_pincode = null;
477 rajveer 3316
    }
3317
 
3430 rajveer 3318
    /** Returns true if field destination_pincode is set (has been assigned a value) and false otherwise */
648 chandransh 3319
    public boolean isSetDestination_pincode() {
3320
      return this.destination_pincode != null;
477 rajveer 3321
    }
3322
 
648 chandransh 3323
    public void setDestination_pincodeIsSet(boolean value) {
477 rajveer 3324
      if (!value) {
648 chandransh 3325
        this.destination_pincode = null;
477 rajveer 3326
      }
3327
    }
3328
 
715 rajveer 3329
    public long getItem_id() {
648 chandransh 3330
      return this.item_id;
477 rajveer 3331
    }
3332
 
3430 rajveer 3333
    public void setItem_id(long item_id) {
648 chandransh 3334
      this.item_id = item_id;
715 rajveer 3335
      setItem_idIsSet(true);
477 rajveer 3336
    }
3337
 
648 chandransh 3338
    public void unsetItem_id() {
715 rajveer 3339
      __isset_bit_vector.clear(__ITEM_ID_ISSET_ID);
477 rajveer 3340
    }
3341
 
3430 rajveer 3342
    /** Returns true if field item_id is set (has been assigned a value) and false otherwise */
648 chandransh 3343
    public boolean isSetItem_id() {
715 rajveer 3344
      return __isset_bit_vector.get(__ITEM_ID_ISSET_ID);
477 rajveer 3345
    }
3346
 
648 chandransh 3347
    public void setItem_idIsSet(boolean value) {
715 rajveer 3348
      __isset_bit_vector.set(__ITEM_ID_ISSET_ID, value);
477 rajveer 3349
    }
3350
 
3044 chandransh 3351
    /**
3352
     * 
3353
     * @see DeliveryType
3354
     */
3355
    public DeliveryType getType() {
3356
      return this.type;
3357
    }
3358
 
3359
    /**
3360
     * 
3361
     * @see DeliveryType
3362
     */
3430 rajveer 3363
    public void setType(DeliveryType type) {
3044 chandransh 3364
      this.type = type;
3365
    }
3366
 
3367
    public void unsetType() {
3368
      this.type = null;
3369
    }
3370
 
3430 rajveer 3371
    /** Returns true if field type is set (has been assigned a value) and false otherwise */
3044 chandransh 3372
    public boolean isSetType() {
3373
      return this.type != null;
3374
    }
3375
 
3376
    public void setTypeIsSet(boolean value) {
3377
      if (!value) {
3378
        this.type = null;
3379
      }
3380
    }
3381
 
477 rajveer 3382
    public void setFieldValue(_Fields field, Object value) {
3383
      switch (field) {
648 chandransh 3384
      case DESTINATION_PINCODE:
477 rajveer 3385
        if (value == null) {
648 chandransh 3386
          unsetDestination_pincode();
477 rajveer 3387
        } else {
648 chandransh 3388
          setDestination_pincode((String)value);
477 rajveer 3389
        }
3390
        break;
3391
 
648 chandransh 3392
      case ITEM_ID:
477 rajveer 3393
        if (value == null) {
648 chandransh 3394
          unsetItem_id();
477 rajveer 3395
        } else {
715 rajveer 3396
          setItem_id((Long)value);
477 rajveer 3397
        }
3398
        break;
3399
 
3044 chandransh 3400
      case TYPE:
3401
        if (value == null) {
3402
          unsetType();
3403
        } else {
3404
          setType((DeliveryType)value);
3405
        }
3406
        break;
3407
 
477 rajveer 3408
      }
3409
    }
3410
 
3411
    public Object getFieldValue(_Fields field) {
3412
      switch (field) {
648 chandransh 3413
      case DESTINATION_PINCODE:
3414
        return getDestination_pincode();
477 rajveer 3415
 
648 chandransh 3416
      case ITEM_ID:
3430 rajveer 3417
        return Long.valueOf(getItem_id());
477 rajveer 3418
 
3044 chandransh 3419
      case TYPE:
3420
        return getType();
3421
 
477 rajveer 3422
      }
3423
      throw new IllegalStateException();
3424
    }
3425
 
3430 rajveer 3426
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3427
    public boolean isSet(_Fields field) {
3428
      if (field == null) {
3429
        throw new IllegalArgumentException();
3430
      }
477 rajveer 3431
 
3432
      switch (field) {
648 chandransh 3433
      case DESTINATION_PINCODE:
3434
        return isSetDestination_pincode();
3435
      case ITEM_ID:
3436
        return isSetItem_id();
3044 chandransh 3437
      case TYPE:
3438
        return isSetType();
477 rajveer 3439
      }
3440
      throw new IllegalStateException();
3441
    }
3442
 
3443
    @Override
3444
    public boolean equals(Object that) {
3445
      if (that == null)
3446
        return false;
648 chandransh 3447
      if (that instanceof getLogisticsInfo_args)
3448
        return this.equals((getLogisticsInfo_args)that);
477 rajveer 3449
      return false;
3450
    }
3451
 
648 chandransh 3452
    public boolean equals(getLogisticsInfo_args that) {
477 rajveer 3453
      if (that == null)
3454
        return false;
3455
 
648 chandransh 3456
      boolean this_present_destination_pincode = true && this.isSetDestination_pincode();
3457
      boolean that_present_destination_pincode = true && that.isSetDestination_pincode();
3458
      if (this_present_destination_pincode || that_present_destination_pincode) {
3459
        if (!(this_present_destination_pincode && that_present_destination_pincode))
477 rajveer 3460
          return false;
648 chandransh 3461
        if (!this.destination_pincode.equals(that.destination_pincode))
477 rajveer 3462
          return false;
3463
      }
3464
 
715 rajveer 3465
      boolean this_present_item_id = true;
3466
      boolean that_present_item_id = true;
648 chandransh 3467
      if (this_present_item_id || that_present_item_id) {
3468
        if (!(this_present_item_id && that_present_item_id))
477 rajveer 3469
          return false;
715 rajveer 3470
        if (this.item_id != that.item_id)
477 rajveer 3471
          return false;
3472
      }
3473
 
3044 chandransh 3474
      boolean this_present_type = true && this.isSetType();
3475
      boolean that_present_type = true && that.isSetType();
3476
      if (this_present_type || that_present_type) {
3477
        if (!(this_present_type && that_present_type))
3478
          return false;
3479
        if (!this.type.equals(that.type))
3480
          return false;
3481
      }
3482
 
477 rajveer 3483
      return true;
3484
    }
3485
 
3486
    @Override
3487
    public int hashCode() {
3488
      return 0;
3489
    }
3490
 
648 chandransh 3491
    public int compareTo(getLogisticsInfo_args other) {
477 rajveer 3492
      if (!getClass().equals(other.getClass())) {
3493
        return getClass().getName().compareTo(other.getClass().getName());
3494
      }
3495
 
3496
      int lastComparison = 0;
648 chandransh 3497
      getLogisticsInfo_args typedOther = (getLogisticsInfo_args)other;
477 rajveer 3498
 
3430 rajveer 3499
      lastComparison = Boolean.valueOf(isSetDestination_pincode()).compareTo(typedOther.isSetDestination_pincode());
477 rajveer 3500
      if (lastComparison != 0) {
3501
        return lastComparison;
3502
      }
3430 rajveer 3503
      if (isSetDestination_pincode()) {
3504
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.destination_pincode, typedOther.destination_pincode);
3505
        if (lastComparison != 0) {
3506
          return lastComparison;
3507
        }
477 rajveer 3508
      }
3430 rajveer 3509
      lastComparison = Boolean.valueOf(isSetItem_id()).compareTo(typedOther.isSetItem_id());
477 rajveer 3510
      if (lastComparison != 0) {
3511
        return lastComparison;
3512
      }
3430 rajveer 3513
      if (isSetItem_id()) {
3514
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.item_id, typedOther.item_id);
3515
        if (lastComparison != 0) {
3516
          return lastComparison;
3517
        }
477 rajveer 3518
      }
3430 rajveer 3519
      lastComparison = Boolean.valueOf(isSetType()).compareTo(typedOther.isSetType());
3044 chandransh 3520
      if (lastComparison != 0) {
3521
        return lastComparison;
3522
      }
3430 rajveer 3523
      if (isSetType()) {
3524
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, typedOther.type);
3525
        if (lastComparison != 0) {
3526
          return lastComparison;
3527
        }
3044 chandransh 3528
      }
477 rajveer 3529
      return 0;
3530
    }
3531
 
3430 rajveer 3532
    public _Fields fieldForId(int fieldId) {
3533
      return _Fields.findByThriftId(fieldId);
3534
    }
3535
 
3536
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3537
      org.apache.thrift.protocol.TField field;
477 rajveer 3538
      iprot.readStructBegin();
3539
      while (true)
3540
      {
3541
        field = iprot.readFieldBegin();
3430 rajveer 3542
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
477 rajveer 3543
          break;
3544
        }
3430 rajveer 3545
        switch (field.id) {
3546
          case 1: // DESTINATION_PINCODE
3547
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
3548
              this.destination_pincode = iprot.readString();
3549
            } else { 
3550
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3551
            }
3552
            break;
3553
          case 2: // ITEM_ID
3554
            if (field.type == org.apache.thrift.protocol.TType.I64) {
3555
              this.item_id = iprot.readI64();
3556
              setItem_idIsSet(true);
3557
            } else { 
3558
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3559
            }
3560
            break;
3561
          case 3: // TYPE
3562
            if (field.type == org.apache.thrift.protocol.TType.I32) {
3563
              this.type = DeliveryType.findByValue(iprot.readI32());
3564
            } else { 
3565
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3566
            }
3567
            break;
3568
          default:
3569
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
477 rajveer 3570
        }
3430 rajveer 3571
        iprot.readFieldEnd();
477 rajveer 3572
      }
3573
      iprot.readStructEnd();
3574
      validate();
3575
    }
3576
 
3430 rajveer 3577
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
477 rajveer 3578
      validate();
3579
 
3580
      oprot.writeStructBegin(STRUCT_DESC);
648 chandransh 3581
      if (this.destination_pincode != null) {
3582
        oprot.writeFieldBegin(DESTINATION_PINCODE_FIELD_DESC);
3583
        oprot.writeString(this.destination_pincode);
477 rajveer 3584
        oprot.writeFieldEnd();
3585
      }
715 rajveer 3586
      oprot.writeFieldBegin(ITEM_ID_FIELD_DESC);
3587
      oprot.writeI64(this.item_id);
3588
      oprot.writeFieldEnd();
3044 chandransh 3589
      if (this.type != null) {
3590
        oprot.writeFieldBegin(TYPE_FIELD_DESC);
3591
        oprot.writeI32(this.type.getValue());
3592
        oprot.writeFieldEnd();
3593
      }
477 rajveer 3594
      oprot.writeFieldStop();
3595
      oprot.writeStructEnd();
3596
    }
3597
 
3598
    @Override
3599
    public String toString() {
648 chandransh 3600
      StringBuilder sb = new StringBuilder("getLogisticsInfo_args(");
477 rajveer 3601
      boolean first = true;
3602
 
648 chandransh 3603
      sb.append("destination_pincode:");
3604
      if (this.destination_pincode == null) {
477 rajveer 3605
        sb.append("null");
3606
      } else {
648 chandransh 3607
        sb.append(this.destination_pincode);
477 rajveer 3608
      }
3609
      first = false;
3610
      if (!first) sb.append(", ");
648 chandransh 3611
      sb.append("item_id:");
715 rajveer 3612
      sb.append(this.item_id);
477 rajveer 3613
      first = false;
3044 chandransh 3614
      if (!first) sb.append(", ");
3615
      sb.append("type:");
3616
      if (this.type == null) {
3617
        sb.append("null");
3618
      } else {
3619
        sb.append(this.type);
3620
      }
3621
      first = false;
477 rajveer 3622
      sb.append(")");
3623
      return sb.toString();
3624
    }
3625
 
3430 rajveer 3626
    public void validate() throws org.apache.thrift.TException {
477 rajveer 3627
      // check for required fields
3628
    }
3629
 
3430 rajveer 3630
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
3631
      try {
3632
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
3633
      } catch (org.apache.thrift.TException te) {
3634
        throw new java.io.IOException(te);
3635
      }
3636
    }
3637
 
3638
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
3639
      try {
3640
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
3641
      } catch (org.apache.thrift.TException te) {
3642
        throw new java.io.IOException(te);
3643
      }
3644
    }
3645
 
477 rajveer 3646
  }
3647
 
3430 rajveer 3648
  public static class getLogisticsInfo_result implements org.apache.thrift.TBase<getLogisticsInfo_result, getLogisticsInfo_result._Fields>, java.io.Serializable, Cloneable   {
3649
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getLogisticsInfo_result");
477 rajveer 3650
 
3430 rajveer 3651
    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);
3652
    private static final org.apache.thrift.protocol.TField SE_FIELD_DESC = new org.apache.thrift.protocol.TField("se", org.apache.thrift.protocol.TType.STRUCT, (short)1);
477 rajveer 3653
 
3430 rajveer 3654
    private LogisticsInfo success; // required
3655
    private LogisticsServiceException se; // required
477 rajveer 3656
 
3657
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 3658
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
648 chandransh 3659
      SUCCESS((short)0, "success"),
3660
      SE((short)1, "se");
477 rajveer 3661
 
3662
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
3663
 
3664
      static {
3665
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
3666
          byName.put(field.getFieldName(), field);
3667
        }
3668
      }
3669
 
3670
      /**
3671
       * Find the _Fields constant that matches fieldId, or null if its not found.
3672
       */
3673
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 3674
        switch(fieldId) {
3675
          case 0: // SUCCESS
3676
            return SUCCESS;
3677
          case 1: // SE
3678
            return SE;
3679
          default:
3680
            return null;
3681
        }
477 rajveer 3682
      }
3683
 
3684
      /**
3685
       * Find the _Fields constant that matches fieldId, throwing an exception
3686
       * if it is not found.
3687
       */
3688
      public static _Fields findByThriftIdOrThrow(int fieldId) {
3689
        _Fields fields = findByThriftId(fieldId);
3690
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
3691
        return fields;
3692
      }
3693
 
3694
      /**
3695
       * Find the _Fields constant that matches name, or null if its not found.
3696
       */
3697
      public static _Fields findByName(String name) {
3698
        return byName.get(name);
3699
      }
3700
 
3701
      private final short _thriftId;
3702
      private final String _fieldName;
3703
 
3704
      _Fields(short thriftId, String fieldName) {
3705
        _thriftId = thriftId;
3706
        _fieldName = fieldName;
3707
      }
3708
 
3709
      public short getThriftFieldId() {
3710
        return _thriftId;
3711
      }
3712
 
3713
      public String getFieldName() {
3714
        return _fieldName;
3715
      }
3716
    }
3717
 
412 ashish 3718
    // isset id assignments
3719
 
3430 rajveer 3720
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
412 ashish 3721
    static {
3430 rajveer 3722
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
3723
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3724
          new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, LogisticsInfo.class)));
3725
      tmpMap.put(_Fields.SE, new org.apache.thrift.meta_data.FieldMetaData("se", org.apache.thrift.TFieldRequirementType.DEFAULT, 
3726
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
3727
      metaDataMap = Collections.unmodifiableMap(tmpMap);
3728
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getLogisticsInfo_result.class, metaDataMap);
412 ashish 3729
    }
3730
 
648 chandransh 3731
    public getLogisticsInfo_result() {
412 ashish 3732
    }
3733
 
648 chandransh 3734
    public getLogisticsInfo_result(
3735
      LogisticsInfo success,
3736
      LogisticsServiceException se)
412 ashish 3737
    {
3738
      this();
648 chandransh 3739
      this.success = success;
3740
      this.se = se;
412 ashish 3741
    }
3742
 
3743
    /**
3744
     * Performs a deep copy on <i>other</i>.
3745
     */
648 chandransh 3746
    public getLogisticsInfo_result(getLogisticsInfo_result other) {
3747
      if (other.isSetSuccess()) {
3748
        this.success = new LogisticsInfo(other.success);
412 ashish 3749
      }
648 chandransh 3750
      if (other.isSetSe()) {
3751
        this.se = new LogisticsServiceException(other.se);
3752
      }
412 ashish 3753
    }
3754
 
648 chandransh 3755
    public getLogisticsInfo_result deepCopy() {
3756
      return new getLogisticsInfo_result(this);
412 ashish 3757
    }
3758
 
3430 rajveer 3759
    @Override
3760
    public void clear() {
3761
      this.success = null;
3762
      this.se = null;
412 ashish 3763
    }
3764
 
648 chandransh 3765
    public LogisticsInfo getSuccess() {
3766
      return this.success;
412 ashish 3767
    }
3768
 
3430 rajveer 3769
    public void setSuccess(LogisticsInfo success) {
648 chandransh 3770
      this.success = success;
412 ashish 3771
    }
3772
 
648 chandransh 3773
    public void unsetSuccess() {
3774
      this.success = null;
412 ashish 3775
    }
3776
 
3430 rajveer 3777
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
648 chandransh 3778
    public boolean isSetSuccess() {
3779
      return this.success != null;
412 ashish 3780
    }
3781
 
648 chandransh 3782
    public void setSuccessIsSet(boolean value) {
412 ashish 3783
      if (!value) {
648 chandransh 3784
        this.success = null;
412 ashish 3785
      }
3786
    }
3787
 
648 chandransh 3788
    public LogisticsServiceException getSe() {
3789
      return this.se;
412 ashish 3790
    }
3791
 
3430 rajveer 3792
    public void setSe(LogisticsServiceException se) {
648 chandransh 3793
      this.se = se;
412 ashish 3794
    }
3795
 
648 chandransh 3796
    public void unsetSe() {
3797
      this.se = null;
412 ashish 3798
    }
3799
 
3430 rajveer 3800
    /** Returns true if field se is set (has been assigned a value) and false otherwise */
648 chandransh 3801
    public boolean isSetSe() {
3802
      return this.se != null;
412 ashish 3803
    }
3804
 
648 chandransh 3805
    public void setSeIsSet(boolean value) {
3806
      if (!value) {
3807
        this.se = null;
3808
      }
412 ashish 3809
    }
3810
 
3811
    public void setFieldValue(_Fields field, Object value) {
3812
      switch (field) {
648 chandransh 3813
      case SUCCESS:
412 ashish 3814
        if (value == null) {
648 chandransh 3815
          unsetSuccess();
412 ashish 3816
        } else {
648 chandransh 3817
          setSuccess((LogisticsInfo)value);
412 ashish 3818
        }
3819
        break;
3820
 
648 chandransh 3821
      case SE:
412 ashish 3822
        if (value == null) {
648 chandransh 3823
          unsetSe();
412 ashish 3824
        } else {
648 chandransh 3825
          setSe((LogisticsServiceException)value);
412 ashish 3826
        }
3827
        break;
3828
 
3829
      }
3830
    }
3831
 
3832
    public Object getFieldValue(_Fields field) {
3833
      switch (field) {
648 chandransh 3834
      case SUCCESS:
3835
        return getSuccess();
412 ashish 3836
 
648 chandransh 3837
      case SE:
3838
        return getSe();
412 ashish 3839
 
3840
      }
3841
      throw new IllegalStateException();
3842
    }
3843
 
3430 rajveer 3844
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
3845
    public boolean isSet(_Fields field) {
3846
      if (field == null) {
3847
        throw new IllegalArgumentException();
3848
      }
412 ashish 3849
 
3850
      switch (field) {
648 chandransh 3851
      case SUCCESS:
3852
        return isSetSuccess();
3853
      case SE:
3854
        return isSetSe();
412 ashish 3855
      }
3856
      throw new IllegalStateException();
3857
    }
3858
 
3859
    @Override
3860
    public boolean equals(Object that) {
3861
      if (that == null)
3862
        return false;
648 chandransh 3863
      if (that instanceof getLogisticsInfo_result)
3864
        return this.equals((getLogisticsInfo_result)that);
412 ashish 3865
      return false;
3866
    }
3867
 
648 chandransh 3868
    public boolean equals(getLogisticsInfo_result that) {
412 ashish 3869
      if (that == null)
3870
        return false;
3871
 
648 chandransh 3872
      boolean this_present_success = true && this.isSetSuccess();
3873
      boolean that_present_success = true && that.isSetSuccess();
3874
      if (this_present_success || that_present_success) {
3875
        if (!(this_present_success && that_present_success))
412 ashish 3876
          return false;
648 chandransh 3877
        if (!this.success.equals(that.success))
412 ashish 3878
          return false;
3879
      }
3880
 
648 chandransh 3881
      boolean this_present_se = true && this.isSetSe();
3882
      boolean that_present_se = true && that.isSetSe();
3883
      if (this_present_se || that_present_se) {
3884
        if (!(this_present_se && that_present_se))
412 ashish 3885
          return false;
648 chandransh 3886
        if (!this.se.equals(that.se))
412 ashish 3887
          return false;
3888
      }
3889
 
3890
      return true;
3891
    }
3892
 
3893
    @Override
3894
    public int hashCode() {
3895
      return 0;
3896
    }
3897
 
648 chandransh 3898
    public int compareTo(getLogisticsInfo_result other) {
412 ashish 3899
      if (!getClass().equals(other.getClass())) {
3900
        return getClass().getName().compareTo(other.getClass().getName());
3901
      }
3902
 
3903
      int lastComparison = 0;
648 chandransh 3904
      getLogisticsInfo_result typedOther = (getLogisticsInfo_result)other;
412 ashish 3905
 
3430 rajveer 3906
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
412 ashish 3907
      if (lastComparison != 0) {
3908
        return lastComparison;
3909
      }
3430 rajveer 3910
      if (isSetSuccess()) {
3911
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
3912
        if (lastComparison != 0) {
3913
          return lastComparison;
3914
        }
412 ashish 3915
      }
3430 rajveer 3916
      lastComparison = Boolean.valueOf(isSetSe()).compareTo(typedOther.isSetSe());
412 ashish 3917
      if (lastComparison != 0) {
3918
        return lastComparison;
3919
      }
3430 rajveer 3920
      if (isSetSe()) {
3921
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.se, typedOther.se);
3922
        if (lastComparison != 0) {
3923
          return lastComparison;
3924
        }
412 ashish 3925
      }
3926
      return 0;
3927
    }
3928
 
3430 rajveer 3929
    public _Fields fieldForId(int fieldId) {
3930
      return _Fields.findByThriftId(fieldId);
3931
    }
3932
 
3933
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
3934
      org.apache.thrift.protocol.TField field;
412 ashish 3935
      iprot.readStructBegin();
3936
      while (true)
3937
      {
3938
        field = iprot.readFieldBegin();
3430 rajveer 3939
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
412 ashish 3940
          break;
3941
        }
3430 rajveer 3942
        switch (field.id) {
3943
          case 0: // SUCCESS
3944
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3945
              this.success = new LogisticsInfo();
3946
              this.success.read(iprot);
3947
            } else { 
3948
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3949
            }
3950
            break;
3951
          case 1: // SE
3952
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
3953
              this.se = new LogisticsServiceException();
3954
              this.se.read(iprot);
3955
            } else { 
3956
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
3957
            }
3958
            break;
3959
          default:
3960
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
412 ashish 3961
        }
3430 rajveer 3962
        iprot.readFieldEnd();
412 ashish 3963
      }
3964
      iprot.readStructEnd();
3965
      validate();
3966
    }
3967
 
3430 rajveer 3968
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
648 chandransh 3969
      oprot.writeStructBegin(STRUCT_DESC);
412 ashish 3970
 
648 chandransh 3971
      if (this.isSetSuccess()) {
3972
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
3973
        this.success.write(oprot);
412 ashish 3974
        oprot.writeFieldEnd();
648 chandransh 3975
      } else if (this.isSetSe()) {
3976
        oprot.writeFieldBegin(SE_FIELD_DESC);
3977
        this.se.write(oprot);
3978
        oprot.writeFieldEnd();
412 ashish 3979
      }
3980
      oprot.writeFieldStop();
3981
      oprot.writeStructEnd();
3982
    }
3983
 
3984
    @Override
3985
    public String toString() {
648 chandransh 3986
      StringBuilder sb = new StringBuilder("getLogisticsInfo_result(");
412 ashish 3987
      boolean first = true;
3988
 
648 chandransh 3989
      sb.append("success:");
3990
      if (this.success == null) {
412 ashish 3991
        sb.append("null");
3992
      } else {
648 chandransh 3993
        sb.append(this.success);
412 ashish 3994
      }
3995
      first = false;
3996
      if (!first) sb.append(", ");
648 chandransh 3997
      sb.append("se:");
3998
      if (this.se == null) {
3999
        sb.append("null");
4000
      } else {
4001
        sb.append(this.se);
4002
      }
412 ashish 4003
      first = false;
4004
      sb.append(")");
4005
      return sb.toString();
4006
    }
4007
 
3430 rajveer 4008
    public void validate() throws org.apache.thrift.TException {
412 ashish 4009
      // check for required fields
4010
    }
4011
 
3430 rajveer 4012
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4013
      try {
4014
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4015
      } catch (org.apache.thrift.TException te) {
4016
        throw new java.io.IOException(te);
4017
      }
4018
    }
4019
 
4020
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4021
      try {
4022
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4023
      } catch (org.apache.thrift.TException te) {
4024
        throw new java.io.IOException(te);
4025
      }
4026
    }
4027
 
412 ashish 4028
  }
4029
 
3430 rajveer 4030
  public static class getEmptyAWB_args implements org.apache.thrift.TBase<getEmptyAWB_args, getEmptyAWB_args._Fields>, java.io.Serializable, Cloneable   {
4031
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getEmptyAWB_args");
412 ashish 4032
 
3430 rajveer 4033
    private static final org.apache.thrift.protocol.TField PROVIDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("providerId", org.apache.thrift.protocol.TType.I64, (short)1);
5247 rajveer 4034
    private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)-1);
412 ashish 4035
 
3430 rajveer 4036
    private long providerId; // required
5247 rajveer 4037
    private DeliveryType type; // required
412 ashish 4038
 
4039
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4040
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
5247 rajveer 4041
      PROVIDER_ID((short)1, "providerId"),
4042
      /**
4043
       * 
4044
       * @see DeliveryType
4045
       */
4046
      TYPE((short)-1, "type");
412 ashish 4047
 
4048
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4049
 
4050
      static {
4051
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4052
          byName.put(field.getFieldName(), field);
4053
        }
4054
      }
4055
 
4056
      /**
4057
       * Find the _Fields constant that matches fieldId, or null if its not found.
4058
       */
4059
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4060
        switch(fieldId) {
4061
          case 1: // PROVIDER_ID
4062
            return PROVIDER_ID;
5247 rajveer 4063
          case -1: // TYPE
4064
            return TYPE;
3430 rajveer 4065
          default:
4066
            return null;
4067
        }
412 ashish 4068
      }
4069
 
4070
      /**
4071
       * Find the _Fields constant that matches fieldId, throwing an exception
4072
       * if it is not found.
4073
       */
4074
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4075
        _Fields fields = findByThriftId(fieldId);
4076
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4077
        return fields;
4078
      }
4079
 
4080
      /**
4081
       * Find the _Fields constant that matches name, or null if its not found.
4082
       */
4083
      public static _Fields findByName(String name) {
4084
        return byName.get(name);
4085
      }
4086
 
4087
      private final short _thriftId;
4088
      private final String _fieldName;
4089
 
4090
      _Fields(short thriftId, String fieldName) {
4091
        _thriftId = thriftId;
4092
        _fieldName = fieldName;
4093
      }
4094
 
4095
      public short getThriftFieldId() {
4096
        return _thriftId;
4097
      }
4098
 
4099
      public String getFieldName() {
4100
        return _fieldName;
4101
      }
4102
    }
4103
 
4104
    // isset id assignments
648 chandransh 4105
    private static final int __PROVIDERID_ISSET_ID = 0;
412 ashish 4106
    private BitSet __isset_bit_vector = new BitSet(1);
4107
 
3430 rajveer 4108
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
412 ashish 4109
    static {
3430 rajveer 4110
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4111
      tmpMap.put(_Fields.PROVIDER_ID, new org.apache.thrift.meta_data.FieldMetaData("providerId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4112
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5247 rajveer 4113
      tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4114
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, DeliveryType.class)));
3430 rajveer 4115
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4116
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getEmptyAWB_args.class, metaDataMap);
412 ashish 4117
    }
4118
 
4119
    public getEmptyAWB_args() {
4120
    }
4121
 
4122
    public getEmptyAWB_args(
5247 rajveer 4123
      long providerId,
4124
      DeliveryType type)
412 ashish 4125
    {
4126
      this();
648 chandransh 4127
      this.providerId = providerId;
4128
      setProviderIdIsSet(true);
5247 rajveer 4129
      this.type = type;
412 ashish 4130
    }
4131
 
4132
    /**
4133
     * Performs a deep copy on <i>other</i>.
4134
     */
4135
    public getEmptyAWB_args(getEmptyAWB_args other) {
4136
      __isset_bit_vector.clear();
4137
      __isset_bit_vector.or(other.__isset_bit_vector);
648 chandransh 4138
      this.providerId = other.providerId;
5247 rajveer 4139
      if (other.isSetType()) {
4140
        this.type = other.type;
4141
      }
412 ashish 4142
    }
4143
 
4144
    public getEmptyAWB_args deepCopy() {
4145
      return new getEmptyAWB_args(this);
4146
    }
4147
 
3430 rajveer 4148
    @Override
4149
    public void clear() {
4150
      setProviderIdIsSet(false);
4151
      this.providerId = 0;
5247 rajveer 4152
      this.type = null;
412 ashish 4153
    }
4154
 
648 chandransh 4155
    public long getProviderId() {
4156
      return this.providerId;
412 ashish 4157
    }
4158
 
3430 rajveer 4159
    public void setProviderId(long providerId) {
648 chandransh 4160
      this.providerId = providerId;
4161
      setProviderIdIsSet(true);
412 ashish 4162
    }
4163
 
648 chandransh 4164
    public void unsetProviderId() {
4165
      __isset_bit_vector.clear(__PROVIDERID_ISSET_ID);
412 ashish 4166
    }
4167
 
3430 rajveer 4168
    /** Returns true if field providerId is set (has been assigned a value) and false otherwise */
648 chandransh 4169
    public boolean isSetProviderId() {
4170
      return __isset_bit_vector.get(__PROVIDERID_ISSET_ID);
412 ashish 4171
    }
4172
 
648 chandransh 4173
    public void setProviderIdIsSet(boolean value) {
4174
      __isset_bit_vector.set(__PROVIDERID_ISSET_ID, value);
412 ashish 4175
    }
4176
 
5247 rajveer 4177
    /**
4178
     * 
4179
     * @see DeliveryType
4180
     */
4181
    public DeliveryType getType() {
4182
      return this.type;
4183
    }
4184
 
4185
    /**
4186
     * 
4187
     * @see DeliveryType
4188
     */
4189
    public void setType(DeliveryType type) {
4190
      this.type = type;
4191
    }
4192
 
4193
    public void unsetType() {
4194
      this.type = null;
4195
    }
4196
 
4197
    /** Returns true if field type is set (has been assigned a value) and false otherwise */
4198
    public boolean isSetType() {
4199
      return this.type != null;
4200
    }
4201
 
4202
    public void setTypeIsSet(boolean value) {
4203
      if (!value) {
4204
        this.type = null;
4205
      }
4206
    }
4207
 
412 ashish 4208
    public void setFieldValue(_Fields field, Object value) {
4209
      switch (field) {
4210
      case PROVIDER_ID:
4211
        if (value == null) {
648 chandransh 4212
          unsetProviderId();
412 ashish 4213
        } else {
648 chandransh 4214
          setProviderId((Long)value);
412 ashish 4215
        }
4216
        break;
4217
 
5247 rajveer 4218
      case TYPE:
4219
        if (value == null) {
4220
          unsetType();
4221
        } else {
4222
          setType((DeliveryType)value);
4223
        }
4224
        break;
4225
 
412 ashish 4226
      }
4227
    }
4228
 
4229
    public Object getFieldValue(_Fields field) {
4230
      switch (field) {
4231
      case PROVIDER_ID:
3430 rajveer 4232
        return Long.valueOf(getProviderId());
412 ashish 4233
 
5247 rajveer 4234
      case TYPE:
4235
        return getType();
4236
 
412 ashish 4237
      }
4238
      throw new IllegalStateException();
4239
    }
4240
 
3430 rajveer 4241
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4242
    public boolean isSet(_Fields field) {
4243
      if (field == null) {
4244
        throw new IllegalArgumentException();
4245
      }
412 ashish 4246
 
4247
      switch (field) {
4248
      case PROVIDER_ID:
648 chandransh 4249
        return isSetProviderId();
5247 rajveer 4250
      case TYPE:
4251
        return isSetType();
412 ashish 4252
      }
4253
      throw new IllegalStateException();
4254
    }
4255
 
4256
    @Override
4257
    public boolean equals(Object that) {
4258
      if (that == null)
4259
        return false;
4260
      if (that instanceof getEmptyAWB_args)
4261
        return this.equals((getEmptyAWB_args)that);
4262
      return false;
4263
    }
4264
 
4265
    public boolean equals(getEmptyAWB_args that) {
4266
      if (that == null)
4267
        return false;
4268
 
648 chandransh 4269
      boolean this_present_providerId = true;
4270
      boolean that_present_providerId = true;
4271
      if (this_present_providerId || that_present_providerId) {
4272
        if (!(this_present_providerId && that_present_providerId))
412 ashish 4273
          return false;
648 chandransh 4274
        if (this.providerId != that.providerId)
412 ashish 4275
          return false;
4276
      }
4277
 
5247 rajveer 4278
      boolean this_present_type = true && this.isSetType();
4279
      boolean that_present_type = true && that.isSetType();
4280
      if (this_present_type || that_present_type) {
4281
        if (!(this_present_type && that_present_type))
4282
          return false;
4283
        if (!this.type.equals(that.type))
4284
          return false;
4285
      }
4286
 
412 ashish 4287
      return true;
4288
    }
4289
 
4290
    @Override
4291
    public int hashCode() {
4292
      return 0;
4293
    }
4294
 
4295
    public int compareTo(getEmptyAWB_args other) {
4296
      if (!getClass().equals(other.getClass())) {
4297
        return getClass().getName().compareTo(other.getClass().getName());
4298
      }
4299
 
4300
      int lastComparison = 0;
4301
      getEmptyAWB_args typedOther = (getEmptyAWB_args)other;
4302
 
3430 rajveer 4303
      lastComparison = Boolean.valueOf(isSetProviderId()).compareTo(typedOther.isSetProviderId());
412 ashish 4304
      if (lastComparison != 0) {
4305
        return lastComparison;
4306
      }
3430 rajveer 4307
      if (isSetProviderId()) {
4308
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.providerId, typedOther.providerId);
4309
        if (lastComparison != 0) {
4310
          return lastComparison;
4311
        }
412 ashish 4312
      }
5247 rajveer 4313
      lastComparison = Boolean.valueOf(isSetType()).compareTo(typedOther.isSetType());
4314
      if (lastComparison != 0) {
4315
        return lastComparison;
4316
      }
4317
      if (isSetType()) {
4318
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, typedOther.type);
4319
        if (lastComparison != 0) {
4320
          return lastComparison;
4321
        }
4322
      }
412 ashish 4323
      return 0;
4324
    }
4325
 
3430 rajveer 4326
    public _Fields fieldForId(int fieldId) {
4327
      return _Fields.findByThriftId(fieldId);
4328
    }
4329
 
4330
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4331
      org.apache.thrift.protocol.TField field;
412 ashish 4332
      iprot.readStructBegin();
4333
      while (true)
4334
      {
4335
        field = iprot.readFieldBegin();
3430 rajveer 4336
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
412 ashish 4337
          break;
4338
        }
3430 rajveer 4339
        switch (field.id) {
4340
          case 1: // PROVIDER_ID
4341
            if (field.type == org.apache.thrift.protocol.TType.I64) {
4342
              this.providerId = iprot.readI64();
4343
              setProviderIdIsSet(true);
4344
            } else { 
4345
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4346
            }
4347
            break;
5247 rajveer 4348
          case -1: // TYPE
4349
            if (field.type == org.apache.thrift.protocol.TType.I32) {
4350
              this.type = DeliveryType.findByValue(iprot.readI32());
4351
            } else { 
4352
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4353
            }
4354
            break;
3430 rajveer 4355
          default:
4356
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
412 ashish 4357
        }
3430 rajveer 4358
        iprot.readFieldEnd();
412 ashish 4359
      }
4360
      iprot.readStructEnd();
4361
      validate();
4362
    }
4363
 
3430 rajveer 4364
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
412 ashish 4365
      validate();
4366
 
4367
      oprot.writeStructBegin(STRUCT_DESC);
5247 rajveer 4368
      if (this.type != null) {
4369
        oprot.writeFieldBegin(TYPE_FIELD_DESC);
4370
        oprot.writeI32(this.type.getValue());
4371
        oprot.writeFieldEnd();
4372
      }
412 ashish 4373
      oprot.writeFieldBegin(PROVIDER_ID_FIELD_DESC);
648 chandransh 4374
      oprot.writeI64(this.providerId);
412 ashish 4375
      oprot.writeFieldEnd();
4376
      oprot.writeFieldStop();
4377
      oprot.writeStructEnd();
4378
    }
4379
 
4380
    @Override
4381
    public String toString() {
4382
      StringBuilder sb = new StringBuilder("getEmptyAWB_args(");
4383
      boolean first = true;
4384
 
648 chandransh 4385
      sb.append("providerId:");
4386
      sb.append(this.providerId);
412 ashish 4387
      first = false;
5247 rajveer 4388
      if (!first) sb.append(", ");
4389
      sb.append("type:");
4390
      if (this.type == null) {
4391
        sb.append("null");
4392
      } else {
4393
        sb.append(this.type);
4394
      }
4395
      first = false;
412 ashish 4396
      sb.append(")");
4397
      return sb.toString();
4398
    }
4399
 
3430 rajveer 4400
    public void validate() throws org.apache.thrift.TException {
412 ashish 4401
      // check for required fields
4402
    }
4403
 
3430 rajveer 4404
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4405
      try {
4406
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4407
      } catch (org.apache.thrift.TException te) {
4408
        throw new java.io.IOException(te);
4409
      }
4410
    }
4411
 
4412
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4413
      try {
4414
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
4415
        __isset_bit_vector = new BitSet(1);
4416
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4417
      } catch (org.apache.thrift.TException te) {
4418
        throw new java.io.IOException(te);
4419
      }
4420
    }
4421
 
412 ashish 4422
  }
4423
 
3430 rajveer 4424
  public static class getEmptyAWB_result implements org.apache.thrift.TBase<getEmptyAWB_result, getEmptyAWB_result._Fields>, java.io.Serializable, Cloneable   {
4425
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getEmptyAWB_result");
412 ashish 4426
 
3430 rajveer 4427
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRING, (short)0);
4428
    private static final org.apache.thrift.protocol.TField SE_FIELD_DESC = new org.apache.thrift.protocol.TField("se", org.apache.thrift.protocol.TType.STRUCT, (short)1);
412 ashish 4429
 
3430 rajveer 4430
    private String success; // required
4431
    private LogisticsServiceException se; // required
412 ashish 4432
 
4433
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4434
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
648 chandransh 4435
      SUCCESS((short)0, "success"),
4436
      SE((short)1, "se");
412 ashish 4437
 
4438
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4439
 
4440
      static {
4441
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4442
          byName.put(field.getFieldName(), field);
4443
        }
4444
      }
4445
 
4446
      /**
4447
       * Find the _Fields constant that matches fieldId, or null if its not found.
4448
       */
4449
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4450
        switch(fieldId) {
4451
          case 0: // SUCCESS
4452
            return SUCCESS;
4453
          case 1: // SE
4454
            return SE;
4455
          default:
4456
            return null;
4457
        }
412 ashish 4458
      }
4459
 
4460
      /**
4461
       * Find the _Fields constant that matches fieldId, throwing an exception
4462
       * if it is not found.
4463
       */
4464
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4465
        _Fields fields = findByThriftId(fieldId);
4466
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4467
        return fields;
4468
      }
4469
 
4470
      /**
4471
       * Find the _Fields constant that matches name, or null if its not found.
4472
       */
4473
      public static _Fields findByName(String name) {
4474
        return byName.get(name);
4475
      }
4476
 
4477
      private final short _thriftId;
4478
      private final String _fieldName;
4479
 
4480
      _Fields(short thriftId, String fieldName) {
4481
        _thriftId = thriftId;
4482
        _fieldName = fieldName;
4483
      }
4484
 
4485
      public short getThriftFieldId() {
4486
        return _thriftId;
4487
      }
4488
 
4489
      public String getFieldName() {
4490
        return _fieldName;
4491
      }
4492
    }
4493
 
4494
    // isset id assignments
4495
 
3430 rajveer 4496
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
412 ashish 4497
    static {
3430 rajveer 4498
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4499
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4500
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
4501
      tmpMap.put(_Fields.SE, new org.apache.thrift.meta_data.FieldMetaData("se", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4502
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
4503
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4504
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getEmptyAWB_result.class, metaDataMap);
412 ashish 4505
    }
4506
 
4507
    public getEmptyAWB_result() {
4508
    }
4509
 
4510
    public getEmptyAWB_result(
648 chandransh 4511
      String success,
4512
      LogisticsServiceException se)
412 ashish 4513
    {
4514
      this();
4515
      this.success = success;
648 chandransh 4516
      this.se = se;
412 ashish 4517
    }
4518
 
4519
    /**
4520
     * Performs a deep copy on <i>other</i>.
4521
     */
4522
    public getEmptyAWB_result(getEmptyAWB_result other) {
4523
      if (other.isSetSuccess()) {
4524
        this.success = other.success;
4525
      }
648 chandransh 4526
      if (other.isSetSe()) {
4527
        this.se = new LogisticsServiceException(other.se);
4528
      }
412 ashish 4529
    }
4530
 
4531
    public getEmptyAWB_result deepCopy() {
4532
      return new getEmptyAWB_result(this);
4533
    }
4534
 
3430 rajveer 4535
    @Override
4536
    public void clear() {
4537
      this.success = null;
4538
      this.se = null;
412 ashish 4539
    }
4540
 
4541
    public String getSuccess() {
4542
      return this.success;
4543
    }
4544
 
3430 rajveer 4545
    public void setSuccess(String success) {
412 ashish 4546
      this.success = success;
4547
    }
4548
 
4549
    public void unsetSuccess() {
4550
      this.success = null;
4551
    }
4552
 
3430 rajveer 4553
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
412 ashish 4554
    public boolean isSetSuccess() {
4555
      return this.success != null;
4556
    }
4557
 
4558
    public void setSuccessIsSet(boolean value) {
4559
      if (!value) {
4560
        this.success = null;
4561
      }
4562
    }
4563
 
648 chandransh 4564
    public LogisticsServiceException getSe() {
4565
      return this.se;
412 ashish 4566
    }
4567
 
3430 rajveer 4568
    public void setSe(LogisticsServiceException se) {
648 chandransh 4569
      this.se = se;
412 ashish 4570
    }
4571
 
648 chandransh 4572
    public void unsetSe() {
4573
      this.se = null;
412 ashish 4574
    }
4575
 
3430 rajveer 4576
    /** Returns true if field se is set (has been assigned a value) and false otherwise */
648 chandransh 4577
    public boolean isSetSe() {
4578
      return this.se != null;
412 ashish 4579
    }
4580
 
648 chandransh 4581
    public void setSeIsSet(boolean value) {
412 ashish 4582
      if (!value) {
648 chandransh 4583
        this.se = null;
412 ashish 4584
      }
4585
    }
4586
 
4587
    public void setFieldValue(_Fields field, Object value) {
4588
      switch (field) {
4589
      case SUCCESS:
4590
        if (value == null) {
4591
          unsetSuccess();
4592
        } else {
648 chandransh 4593
          setSuccess((String)value);
412 ashish 4594
        }
4595
        break;
4596
 
648 chandransh 4597
      case SE:
4598
        if (value == null) {
4599
          unsetSe();
4600
        } else {
4601
          setSe((LogisticsServiceException)value);
4602
        }
4603
        break;
4604
 
412 ashish 4605
      }
4606
    }
4607
 
4608
    public Object getFieldValue(_Fields field) {
4609
      switch (field) {
4610
      case SUCCESS:
4611
        return getSuccess();
4612
 
648 chandransh 4613
      case SE:
4614
        return getSe();
4615
 
412 ashish 4616
      }
4617
      throw new IllegalStateException();
4618
    }
4619
 
3430 rajveer 4620
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
4621
    public boolean isSet(_Fields field) {
4622
      if (field == null) {
4623
        throw new IllegalArgumentException();
4624
      }
412 ashish 4625
 
4626
      switch (field) {
4627
      case SUCCESS:
4628
        return isSetSuccess();
648 chandransh 4629
      case SE:
4630
        return isSetSe();
412 ashish 4631
      }
4632
      throw new IllegalStateException();
4633
    }
4634
 
4635
    @Override
4636
    public boolean equals(Object that) {
4637
      if (that == null)
4638
        return false;
648 chandransh 4639
      if (that instanceof getEmptyAWB_result)
4640
        return this.equals((getEmptyAWB_result)that);
412 ashish 4641
      return false;
4642
    }
4643
 
648 chandransh 4644
    public boolean equals(getEmptyAWB_result that) {
412 ashish 4645
      if (that == null)
4646
        return false;
4647
 
4648
      boolean this_present_success = true && this.isSetSuccess();
4649
      boolean that_present_success = true && that.isSetSuccess();
4650
      if (this_present_success || that_present_success) {
4651
        if (!(this_present_success && that_present_success))
4652
          return false;
4653
        if (!this.success.equals(that.success))
4654
          return false;
4655
      }
4656
 
648 chandransh 4657
      boolean this_present_se = true && this.isSetSe();
4658
      boolean that_present_se = true && that.isSetSe();
4659
      if (this_present_se || that_present_se) {
4660
        if (!(this_present_se && that_present_se))
4661
          return false;
4662
        if (!this.se.equals(that.se))
4663
          return false;
4664
      }
4665
 
412 ashish 4666
      return true;
4667
    }
4668
 
4669
    @Override
4670
    public int hashCode() {
4671
      return 0;
4672
    }
4673
 
648 chandransh 4674
    public int compareTo(getEmptyAWB_result other) {
412 ashish 4675
      if (!getClass().equals(other.getClass())) {
4676
        return getClass().getName().compareTo(other.getClass().getName());
4677
      }
4678
 
4679
      int lastComparison = 0;
648 chandransh 4680
      getEmptyAWB_result typedOther = (getEmptyAWB_result)other;
412 ashish 4681
 
3430 rajveer 4682
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
412 ashish 4683
      if (lastComparison != 0) {
4684
        return lastComparison;
4685
      }
3430 rajveer 4686
      if (isSetSuccess()) {
4687
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
4688
        if (lastComparison != 0) {
4689
          return lastComparison;
4690
        }
412 ashish 4691
      }
3430 rajveer 4692
      lastComparison = Boolean.valueOf(isSetSe()).compareTo(typedOther.isSetSe());
412 ashish 4693
      if (lastComparison != 0) {
4694
        return lastComparison;
4695
      }
3430 rajveer 4696
      if (isSetSe()) {
4697
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.se, typedOther.se);
4698
        if (lastComparison != 0) {
4699
          return lastComparison;
4700
        }
412 ashish 4701
      }
4702
      return 0;
4703
    }
4704
 
3430 rajveer 4705
    public _Fields fieldForId(int fieldId) {
4706
      return _Fields.findByThriftId(fieldId);
4707
    }
4708
 
4709
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
4710
      org.apache.thrift.protocol.TField field;
412 ashish 4711
      iprot.readStructBegin();
4712
      while (true)
4713
      {
4714
        field = iprot.readFieldBegin();
3430 rajveer 4715
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
412 ashish 4716
          break;
4717
        }
3430 rajveer 4718
        switch (field.id) {
4719
          case 0: // SUCCESS
4720
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
4721
              this.success = iprot.readString();
4722
            } else { 
4723
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4724
            }
4725
            break;
4726
          case 1: // SE
4727
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
4728
              this.se = new LogisticsServiceException();
4729
              this.se.read(iprot);
4730
            } else { 
4731
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
4732
            }
4733
            break;
4734
          default:
4735
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
412 ashish 4736
        }
3430 rajveer 4737
        iprot.readFieldEnd();
412 ashish 4738
      }
4739
      iprot.readStructEnd();
4740
      validate();
4741
    }
4742
 
3430 rajveer 4743
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
412 ashish 4744
      oprot.writeStructBegin(STRUCT_DESC);
4745
 
4746
      if (this.isSetSuccess()) {
4747
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
648 chandransh 4748
        oprot.writeString(this.success);
412 ashish 4749
        oprot.writeFieldEnd();
648 chandransh 4750
      } else if (this.isSetSe()) {
4751
        oprot.writeFieldBegin(SE_FIELD_DESC);
4752
        this.se.write(oprot);
4753
        oprot.writeFieldEnd();
412 ashish 4754
      }
4755
      oprot.writeFieldStop();
4756
      oprot.writeStructEnd();
4757
    }
4758
 
4759
    @Override
4760
    public String toString() {
648 chandransh 4761
      StringBuilder sb = new StringBuilder("getEmptyAWB_result(");
412 ashish 4762
      boolean first = true;
4763
 
4764
      sb.append("success:");
4765
      if (this.success == null) {
4766
        sb.append("null");
4767
      } else {
4768
        sb.append(this.success);
4769
      }
4770
      first = false;
648 chandransh 4771
      if (!first) sb.append(", ");
4772
      sb.append("se:");
4773
      if (this.se == null) {
442 rajveer 4774
        sb.append("null");
4775
      } else {
648 chandransh 4776
        sb.append(this.se);
442 rajveer 4777
      }
4778
      first = false;
4779
      sb.append(")");
4780
      return sb.toString();
4781
    }
4782
 
3430 rajveer 4783
    public void validate() throws org.apache.thrift.TException {
442 rajveer 4784
      // check for required fields
4785
    }
4786
 
3430 rajveer 4787
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
4788
      try {
4789
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
4790
      } catch (org.apache.thrift.TException te) {
4791
        throw new java.io.IOException(te);
4792
      }
4793
    }
4794
 
4795
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
4796
      try {
4797
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
4798
      } catch (org.apache.thrift.TException te) {
4799
        throw new java.io.IOException(te);
4800
      }
4801
    }
4802
 
442 rajveer 4803
  }
4804
 
3430 rajveer 4805
  public static class getShipmentInfo_args implements org.apache.thrift.TBase<getShipmentInfo_args, getShipmentInfo_args._Fields>, java.io.Serializable, Cloneable   {
4806
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShipmentInfo_args");
442 rajveer 4807
 
3430 rajveer 4808
    private static final org.apache.thrift.protocol.TField AWB_FIELD_DESC = new org.apache.thrift.protocol.TField("awb", org.apache.thrift.protocol.TType.STRING, (short)1);
4809
    private static final org.apache.thrift.protocol.TField PROVIDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("providerId", org.apache.thrift.protocol.TType.I64, (short)2);
442 rajveer 4810
 
3430 rajveer 4811
    private String awb; // required
4812
    private long providerId; // required
442 rajveer 4813
 
4814
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 4815
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
442 rajveer 4816
      AWB((short)1, "awb"),
648 chandransh 4817
      PROVIDER_ID((short)2, "providerId");
442 rajveer 4818
 
4819
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
4820
 
4821
      static {
4822
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
4823
          byName.put(field.getFieldName(), field);
4824
        }
4825
      }
4826
 
4827
      /**
4828
       * Find the _Fields constant that matches fieldId, or null if its not found.
4829
       */
4830
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 4831
        switch(fieldId) {
4832
          case 1: // AWB
4833
            return AWB;
4834
          case 2: // PROVIDER_ID
4835
            return PROVIDER_ID;
4836
          default:
4837
            return null;
4838
        }
442 rajveer 4839
      }
4840
 
4841
      /**
4842
       * Find the _Fields constant that matches fieldId, throwing an exception
4843
       * if it is not found.
4844
       */
4845
      public static _Fields findByThriftIdOrThrow(int fieldId) {
4846
        _Fields fields = findByThriftId(fieldId);
4847
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
4848
        return fields;
4849
      }
4850
 
4851
      /**
4852
       * Find the _Fields constant that matches name, or null if its not found.
4853
       */
4854
      public static _Fields findByName(String name) {
4855
        return byName.get(name);
4856
      }
4857
 
4858
      private final short _thriftId;
4859
      private final String _fieldName;
4860
 
4861
      _Fields(short thriftId, String fieldName) {
4862
        _thriftId = thriftId;
4863
        _fieldName = fieldName;
4864
      }
4865
 
4866
      public short getThriftFieldId() {
4867
        return _thriftId;
4868
      }
4869
 
4870
      public String getFieldName() {
4871
        return _fieldName;
4872
      }
4873
    }
4874
 
4875
    // isset id assignments
648 chandransh 4876
    private static final int __PROVIDERID_ISSET_ID = 0;
4877
    private BitSet __isset_bit_vector = new BitSet(1);
442 rajveer 4878
 
3430 rajveer 4879
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
442 rajveer 4880
    static {
3430 rajveer 4881
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
4882
      tmpMap.put(_Fields.AWB, new org.apache.thrift.meta_data.FieldMetaData("awb", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4883
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
4884
      tmpMap.put(_Fields.PROVIDER_ID, new org.apache.thrift.meta_data.FieldMetaData("providerId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
4885
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
4886
      metaDataMap = Collections.unmodifiableMap(tmpMap);
4887
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShipmentInfo_args.class, metaDataMap);
442 rajveer 4888
    }
4889
 
648 chandransh 4890
    public getShipmentInfo_args() {
442 rajveer 4891
    }
4892
 
648 chandransh 4893
    public getShipmentInfo_args(
442 rajveer 4894
      String awb,
648 chandransh 4895
      long providerId)
442 rajveer 4896
    {
4897
      this();
4898
      this.awb = awb;
648 chandransh 4899
      this.providerId = providerId;
4900
      setProviderIdIsSet(true);
442 rajveer 4901
    }
4902
 
4903
    /**
4904
     * Performs a deep copy on <i>other</i>.
4905
     */
648 chandransh 4906
    public getShipmentInfo_args(getShipmentInfo_args other) {
4907
      __isset_bit_vector.clear();
4908
      __isset_bit_vector.or(other.__isset_bit_vector);
442 rajveer 4909
      if (other.isSetAwb()) {
4910
        this.awb = other.awb;
4911
      }
648 chandransh 4912
      this.providerId = other.providerId;
442 rajveer 4913
    }
4914
 
648 chandransh 4915
    public getShipmentInfo_args deepCopy() {
4916
      return new getShipmentInfo_args(this);
442 rajveer 4917
    }
4918
 
3430 rajveer 4919
    @Override
4920
    public void clear() {
4921
      this.awb = null;
4922
      setProviderIdIsSet(false);
4923
      this.providerId = 0;
442 rajveer 4924
    }
4925
 
4926
    public String getAwb() {
4927
      return this.awb;
4928
    }
4929
 
3430 rajveer 4930
    public void setAwb(String awb) {
442 rajveer 4931
      this.awb = awb;
4932
    }
4933
 
4934
    public void unsetAwb() {
4935
      this.awb = null;
4936
    }
4937
 
3430 rajveer 4938
    /** Returns true if field awb is set (has been assigned a value) and false otherwise */
442 rajveer 4939
    public boolean isSetAwb() {
4940
      return this.awb != null;
4941
    }
4942
 
4943
    public void setAwbIsSet(boolean value) {
4944
      if (!value) {
4945
        this.awb = null;
4946
      }
4947
    }
4948
 
648 chandransh 4949
    public long getProviderId() {
4950
      return this.providerId;
442 rajveer 4951
    }
4952
 
3430 rajveer 4953
    public void setProviderId(long providerId) {
648 chandransh 4954
      this.providerId = providerId;
4955
      setProviderIdIsSet(true);
442 rajveer 4956
    }
4957
 
648 chandransh 4958
    public void unsetProviderId() {
4959
      __isset_bit_vector.clear(__PROVIDERID_ISSET_ID);
442 rajveer 4960
    }
4961
 
3430 rajveer 4962
    /** Returns true if field providerId is set (has been assigned a value) and false otherwise */
648 chandransh 4963
    public boolean isSetProviderId() {
4964
      return __isset_bit_vector.get(__PROVIDERID_ISSET_ID);
442 rajveer 4965
    }
4966
 
648 chandransh 4967
    public void setProviderIdIsSet(boolean value) {
4968
      __isset_bit_vector.set(__PROVIDERID_ISSET_ID, value);
442 rajveer 4969
    }
4970
 
4971
    public void setFieldValue(_Fields field, Object value) {
4972
      switch (field) {
4973
      case AWB:
4974
        if (value == null) {
4975
          unsetAwb();
4976
        } else {
4977
          setAwb((String)value);
4978
        }
4979
        break;
4980
 
648 chandransh 4981
      case PROVIDER_ID:
442 rajveer 4982
        if (value == null) {
648 chandransh 4983
          unsetProviderId();
442 rajveer 4984
        } else {
648 chandransh 4985
          setProviderId((Long)value);
442 rajveer 4986
        }
4987
        break;
4988
 
4989
      }
4990
    }
4991
 
4992
    public Object getFieldValue(_Fields field) {
4993
      switch (field) {
4994
      case AWB:
4995
        return getAwb();
4996
 
648 chandransh 4997
      case PROVIDER_ID:
3430 rajveer 4998
        return Long.valueOf(getProviderId());
442 rajveer 4999
 
5000
      }
5001
      throw new IllegalStateException();
5002
    }
5003
 
3430 rajveer 5004
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5005
    public boolean isSet(_Fields field) {
5006
      if (field == null) {
5007
        throw new IllegalArgumentException();
5008
      }
442 rajveer 5009
 
5010
      switch (field) {
5011
      case AWB:
5012
        return isSetAwb();
648 chandransh 5013
      case PROVIDER_ID:
5014
        return isSetProviderId();
442 rajveer 5015
      }
5016
      throw new IllegalStateException();
5017
    }
5018
 
5019
    @Override
5020
    public boolean equals(Object that) {
5021
      if (that == null)
5022
        return false;
648 chandransh 5023
      if (that instanceof getShipmentInfo_args)
5024
        return this.equals((getShipmentInfo_args)that);
442 rajveer 5025
      return false;
5026
    }
5027
 
648 chandransh 5028
    public boolean equals(getShipmentInfo_args that) {
442 rajveer 5029
      if (that == null)
5030
        return false;
5031
 
5032
      boolean this_present_awb = true && this.isSetAwb();
5033
      boolean that_present_awb = true && that.isSetAwb();
5034
      if (this_present_awb || that_present_awb) {
5035
        if (!(this_present_awb && that_present_awb))
5036
          return false;
5037
        if (!this.awb.equals(that.awb))
5038
          return false;
5039
      }
5040
 
648 chandransh 5041
      boolean this_present_providerId = true;
5042
      boolean that_present_providerId = true;
5043
      if (this_present_providerId || that_present_providerId) {
5044
        if (!(this_present_providerId && that_present_providerId))
442 rajveer 5045
          return false;
648 chandransh 5046
        if (this.providerId != that.providerId)
442 rajveer 5047
          return false;
5048
      }
5049
 
5050
      return true;
5051
    }
5052
 
5053
    @Override
5054
    public int hashCode() {
5055
      return 0;
5056
    }
5057
 
648 chandransh 5058
    public int compareTo(getShipmentInfo_args other) {
442 rajveer 5059
      if (!getClass().equals(other.getClass())) {
5060
        return getClass().getName().compareTo(other.getClass().getName());
5061
      }
5062
 
5063
      int lastComparison = 0;
648 chandransh 5064
      getShipmentInfo_args typedOther = (getShipmentInfo_args)other;
442 rajveer 5065
 
3430 rajveer 5066
      lastComparison = Boolean.valueOf(isSetAwb()).compareTo(typedOther.isSetAwb());
442 rajveer 5067
      if (lastComparison != 0) {
5068
        return lastComparison;
5069
      }
3430 rajveer 5070
      if (isSetAwb()) {
5071
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.awb, typedOther.awb);
5072
        if (lastComparison != 0) {
5073
          return lastComparison;
5074
        }
442 rajveer 5075
      }
3430 rajveer 5076
      lastComparison = Boolean.valueOf(isSetProviderId()).compareTo(typedOther.isSetProviderId());
442 rajveer 5077
      if (lastComparison != 0) {
5078
        return lastComparison;
5079
      }
3430 rajveer 5080
      if (isSetProviderId()) {
5081
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.providerId, typedOther.providerId);
5082
        if (lastComparison != 0) {
5083
          return lastComparison;
5084
        }
442 rajveer 5085
      }
5086
      return 0;
5087
    }
5088
 
3430 rajveer 5089
    public _Fields fieldForId(int fieldId) {
5090
      return _Fields.findByThriftId(fieldId);
5091
    }
5092
 
5093
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5094
      org.apache.thrift.protocol.TField field;
442 rajveer 5095
      iprot.readStructBegin();
5096
      while (true)
5097
      {
5098
        field = iprot.readFieldBegin();
3430 rajveer 5099
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
442 rajveer 5100
          break;
5101
        }
3430 rajveer 5102
        switch (field.id) {
5103
          case 1: // AWB
5104
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
5105
              this.awb = iprot.readString();
5106
            } else { 
5107
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5108
            }
5109
            break;
5110
          case 2: // PROVIDER_ID
5111
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5112
              this.providerId = iprot.readI64();
5113
              setProviderIdIsSet(true);
5114
            } else { 
5115
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5116
            }
5117
            break;
5118
          default:
5119
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
442 rajveer 5120
        }
3430 rajveer 5121
        iprot.readFieldEnd();
442 rajveer 5122
      }
5123
      iprot.readStructEnd();
5124
      validate();
5125
    }
5126
 
3430 rajveer 5127
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
442 rajveer 5128
      validate();
5129
 
5130
      oprot.writeStructBegin(STRUCT_DESC);
5131
      if (this.awb != null) {
5132
        oprot.writeFieldBegin(AWB_FIELD_DESC);
5133
        oprot.writeString(this.awb);
5134
        oprot.writeFieldEnd();
5135
      }
648 chandransh 5136
      oprot.writeFieldBegin(PROVIDER_ID_FIELD_DESC);
5137
      oprot.writeI64(this.providerId);
5138
      oprot.writeFieldEnd();
442 rajveer 5139
      oprot.writeFieldStop();
5140
      oprot.writeStructEnd();
5141
    }
5142
 
5143
    @Override
5144
    public String toString() {
648 chandransh 5145
      StringBuilder sb = new StringBuilder("getShipmentInfo_args(");
442 rajveer 5146
      boolean first = true;
5147
 
5148
      sb.append("awb:");
5149
      if (this.awb == null) {
5150
        sb.append("null");
5151
      } else {
5152
        sb.append(this.awb);
5153
      }
5154
      first = false;
5155
      if (!first) sb.append(", ");
648 chandransh 5156
      sb.append("providerId:");
5157
      sb.append(this.providerId);
442 rajveer 5158
      first = false;
5159
      sb.append(")");
5160
      return sb.toString();
5161
    }
5162
 
3430 rajveer 5163
    public void validate() throws org.apache.thrift.TException {
442 rajveer 5164
      // check for required fields
5165
    }
5166
 
3430 rajveer 5167
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5168
      try {
5169
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5170
      } catch (org.apache.thrift.TException te) {
5171
        throw new java.io.IOException(te);
5172
      }
5173
    }
5174
 
5175
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5176
      try {
5177
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5178
      } catch (org.apache.thrift.TException te) {
5179
        throw new java.io.IOException(te);
5180
      }
5181
    }
5182
 
442 rajveer 5183
  }
5184
 
3430 rajveer 5185
  public static class getShipmentInfo_result implements org.apache.thrift.TBase<getShipmentInfo_result, getShipmentInfo_result._Fields>, java.io.Serializable, Cloneable   {
5186
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getShipmentInfo_result");
412 ashish 5187
 
3430 rajveer 5188
    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);
5189
    private static final org.apache.thrift.protocol.TField SE_FIELD_DESC = new org.apache.thrift.protocol.TField("se", org.apache.thrift.protocol.TType.STRUCT, (short)1);
412 ashish 5190
 
3430 rajveer 5191
    private List<AwbUpdate> success; // required
5192
    private LogisticsServiceException se; // required
412 ashish 5193
 
5194
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 5195
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
648 chandransh 5196
      SUCCESS((short)0, "success"),
5197
      SE((short)1, "se");
412 ashish 5198
 
5199
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5200
 
5201
      static {
5202
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5203
          byName.put(field.getFieldName(), field);
5204
        }
5205
      }
5206
 
5207
      /**
5208
       * Find the _Fields constant that matches fieldId, or null if its not found.
5209
       */
5210
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 5211
        switch(fieldId) {
5212
          case 0: // SUCCESS
5213
            return SUCCESS;
5214
          case 1: // SE
5215
            return SE;
5216
          default:
5217
            return null;
5218
        }
412 ashish 5219
      }
5220
 
5221
      /**
5222
       * Find the _Fields constant that matches fieldId, throwing an exception
5223
       * if it is not found.
5224
       */
5225
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5226
        _Fields fields = findByThriftId(fieldId);
5227
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5228
        return fields;
5229
      }
5230
 
5231
      /**
5232
       * Find the _Fields constant that matches name, or null if its not found.
5233
       */
5234
      public static _Fields findByName(String name) {
5235
        return byName.get(name);
5236
      }
5237
 
5238
      private final short _thriftId;
5239
      private final String _fieldName;
5240
 
5241
      _Fields(short thriftId, String fieldName) {
5242
        _thriftId = thriftId;
5243
        _fieldName = fieldName;
5244
      }
5245
 
5246
      public short getThriftFieldId() {
5247
        return _thriftId;
5248
      }
5249
 
5250
      public String getFieldName() {
5251
        return _fieldName;
5252
      }
5253
    }
5254
 
5255
    // isset id assignments
5256
 
3430 rajveer 5257
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
412 ashish 5258
    static {
3430 rajveer 5259
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5260
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5261
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
5262
              new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, AwbUpdate.class))));
5263
      tmpMap.put(_Fields.SE, new org.apache.thrift.meta_data.FieldMetaData("se", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5264
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
5265
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5266
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getShipmentInfo_result.class, metaDataMap);
412 ashish 5267
    }
5268
 
5269
    public getShipmentInfo_result() {
5270
    }
5271
 
5272
    public getShipmentInfo_result(
648 chandransh 5273
      List<AwbUpdate> success,
5274
      LogisticsServiceException se)
412 ashish 5275
    {
5276
      this();
5277
      this.success = success;
648 chandransh 5278
      this.se = se;
412 ashish 5279
    }
5280
 
5281
    /**
5282
     * Performs a deep copy on <i>other</i>.
5283
     */
5284
    public getShipmentInfo_result(getShipmentInfo_result other) {
5285
      if (other.isSetSuccess()) {
648 chandransh 5286
        List<AwbUpdate> __this__success = new ArrayList<AwbUpdate>();
5287
        for (AwbUpdate other_element : other.success) {
5288
          __this__success.add(new AwbUpdate(other_element));
5289
        }
5290
        this.success = __this__success;
412 ashish 5291
      }
648 chandransh 5292
      if (other.isSetSe()) {
5293
        this.se = new LogisticsServiceException(other.se);
5294
      }
412 ashish 5295
    }
5296
 
5297
    public getShipmentInfo_result deepCopy() {
5298
      return new getShipmentInfo_result(this);
5299
    }
5300
 
3430 rajveer 5301
    @Override
5302
    public void clear() {
5303
      this.success = null;
5304
      this.se = null;
412 ashish 5305
    }
5306
 
5307
    public int getSuccessSize() {
5308
      return (this.success == null) ? 0 : this.success.size();
5309
    }
5310
 
648 chandransh 5311
    public java.util.Iterator<AwbUpdate> getSuccessIterator() {
412 ashish 5312
      return (this.success == null) ? null : this.success.iterator();
5313
    }
5314
 
648 chandransh 5315
    public void addToSuccess(AwbUpdate elem) {
412 ashish 5316
      if (this.success == null) {
648 chandransh 5317
        this.success = new ArrayList<AwbUpdate>();
412 ashish 5318
      }
5319
      this.success.add(elem);
5320
    }
5321
 
648 chandransh 5322
    public List<AwbUpdate> getSuccess() {
412 ashish 5323
      return this.success;
5324
    }
5325
 
3430 rajveer 5326
    public void setSuccess(List<AwbUpdate> success) {
412 ashish 5327
      this.success = success;
5328
    }
5329
 
5330
    public void unsetSuccess() {
5331
      this.success = null;
5332
    }
5333
 
3430 rajveer 5334
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
412 ashish 5335
    public boolean isSetSuccess() {
5336
      return this.success != null;
5337
    }
5338
 
5339
    public void setSuccessIsSet(boolean value) {
5340
      if (!value) {
5341
        this.success = null;
5342
      }
5343
    }
5344
 
648 chandransh 5345
    public LogisticsServiceException getSe() {
5346
      return this.se;
412 ashish 5347
    }
5348
 
3430 rajveer 5349
    public void setSe(LogisticsServiceException se) {
648 chandransh 5350
      this.se = se;
412 ashish 5351
    }
5352
 
648 chandransh 5353
    public void unsetSe() {
5354
      this.se = null;
412 ashish 5355
    }
5356
 
3430 rajveer 5357
    /** Returns true if field se is set (has been assigned a value) and false otherwise */
648 chandransh 5358
    public boolean isSetSe() {
5359
      return this.se != null;
412 ashish 5360
    }
5361
 
648 chandransh 5362
    public void setSeIsSet(boolean value) {
5363
      if (!value) {
5364
        this.se = null;
412 ashish 5365
      }
5366
    }
5367
 
5368
    public void setFieldValue(_Fields field, Object value) {
5369
      switch (field) {
648 chandransh 5370
      case SUCCESS:
412 ashish 5371
        if (value == null) {
648 chandransh 5372
          unsetSuccess();
412 ashish 5373
        } else {
648 chandransh 5374
          setSuccess((List<AwbUpdate>)value);
412 ashish 5375
        }
5376
        break;
5377
 
648 chandransh 5378
      case SE:
412 ashish 5379
        if (value == null) {
648 chandransh 5380
          unsetSe();
412 ashish 5381
        } else {
648 chandransh 5382
          setSe((LogisticsServiceException)value);
412 ashish 5383
        }
5384
        break;
5385
 
5386
      }
5387
    }
5388
 
5389
    public Object getFieldValue(_Fields field) {
5390
      switch (field) {
648 chandransh 5391
      case SUCCESS:
5392
        return getSuccess();
412 ashish 5393
 
648 chandransh 5394
      case SE:
5395
        return getSe();
412 ashish 5396
 
5397
      }
5398
      throw new IllegalStateException();
5399
    }
5400
 
3430 rajveer 5401
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5402
    public boolean isSet(_Fields field) {
5403
      if (field == null) {
5404
        throw new IllegalArgumentException();
5405
      }
412 ashish 5406
 
5407
      switch (field) {
648 chandransh 5408
      case SUCCESS:
5409
        return isSetSuccess();
5410
      case SE:
5411
        return isSetSe();
412 ashish 5412
      }
5413
      throw new IllegalStateException();
5414
    }
5415
 
5416
    @Override
5417
    public boolean equals(Object that) {
5418
      if (that == null)
5419
        return false;
648 chandransh 5420
      if (that instanceof getShipmentInfo_result)
5421
        return this.equals((getShipmentInfo_result)that);
412 ashish 5422
      return false;
5423
    }
5424
 
648 chandransh 5425
    public boolean equals(getShipmentInfo_result that) {
412 ashish 5426
      if (that == null)
5427
        return false;
5428
 
648 chandransh 5429
      boolean this_present_success = true && this.isSetSuccess();
5430
      boolean that_present_success = true && that.isSetSuccess();
5431
      if (this_present_success || that_present_success) {
5432
        if (!(this_present_success && that_present_success))
412 ashish 5433
          return false;
648 chandransh 5434
        if (!this.success.equals(that.success))
412 ashish 5435
          return false;
5436
      }
5437
 
648 chandransh 5438
      boolean this_present_se = true && this.isSetSe();
5439
      boolean that_present_se = true && that.isSetSe();
5440
      if (this_present_se || that_present_se) {
5441
        if (!(this_present_se && that_present_se))
412 ashish 5442
          return false;
648 chandransh 5443
        if (!this.se.equals(that.se))
412 ashish 5444
          return false;
5445
      }
5446
 
5447
      return true;
5448
    }
5449
 
5450
    @Override
5451
    public int hashCode() {
5452
      return 0;
5453
    }
5454
 
648 chandransh 5455
    public int compareTo(getShipmentInfo_result other) {
412 ashish 5456
      if (!getClass().equals(other.getClass())) {
5457
        return getClass().getName().compareTo(other.getClass().getName());
5458
      }
5459
 
5460
      int lastComparison = 0;
648 chandransh 5461
      getShipmentInfo_result typedOther = (getShipmentInfo_result)other;
412 ashish 5462
 
3430 rajveer 5463
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
412 ashish 5464
      if (lastComparison != 0) {
5465
        return lastComparison;
5466
      }
3430 rajveer 5467
      if (isSetSuccess()) {
5468
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
5469
        if (lastComparison != 0) {
5470
          return lastComparison;
5471
        }
412 ashish 5472
      }
3430 rajveer 5473
      lastComparison = Boolean.valueOf(isSetSe()).compareTo(typedOther.isSetSe());
412 ashish 5474
      if (lastComparison != 0) {
5475
        return lastComparison;
5476
      }
3430 rajveer 5477
      if (isSetSe()) {
5478
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.se, typedOther.se);
5479
        if (lastComparison != 0) {
5480
          return lastComparison;
5481
        }
412 ashish 5482
      }
5483
      return 0;
5484
    }
5485
 
3430 rajveer 5486
    public _Fields fieldForId(int fieldId) {
5487
      return _Fields.findByThriftId(fieldId);
5488
    }
5489
 
5490
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5491
      org.apache.thrift.protocol.TField field;
412 ashish 5492
      iprot.readStructBegin();
5493
      while (true)
5494
      {
5495
        field = iprot.readFieldBegin();
3430 rajveer 5496
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
412 ashish 5497
          break;
5498
        }
3430 rajveer 5499
        switch (field.id) {
5500
          case 0: // SUCCESS
5501
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
5502
              {
5503
                org.apache.thrift.protocol.TList _list9 = iprot.readListBegin();
5504
                this.success = new ArrayList<AwbUpdate>(_list9.size);
5505
                for (int _i10 = 0; _i10 < _list9.size; ++_i10)
412 ashish 5506
                {
3430 rajveer 5507
                  AwbUpdate _elem11; // required
5508
                  _elem11 = new AwbUpdate();
5509
                  _elem11.read(iprot);
5510
                  this.success.add(_elem11);
412 ashish 5511
                }
3430 rajveer 5512
                iprot.readListEnd();
412 ashish 5513
              }
3430 rajveer 5514
            } else { 
5515
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5516
            }
5517
            break;
5518
          case 1: // SE
5519
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
5520
              this.se = new LogisticsServiceException();
5521
              this.se.read(iprot);
5522
            } else { 
5523
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5524
            }
5525
            break;
5526
          default:
5527
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
412 ashish 5528
        }
3430 rajveer 5529
        iprot.readFieldEnd();
412 ashish 5530
      }
5531
      iprot.readStructEnd();
5532
      validate();
5533
    }
5534
 
3430 rajveer 5535
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
412 ashish 5536
      oprot.writeStructBegin(STRUCT_DESC);
5537
 
5538
      if (this.isSetSuccess()) {
5539
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
5540
        {
3430 rajveer 5541
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.STRUCT, this.success.size()));
3044 chandransh 5542
          for (AwbUpdate _iter12 : this.success)
412 ashish 5543
          {
3044 chandransh 5544
            _iter12.write(oprot);
412 ashish 5545
          }
5546
          oprot.writeListEnd();
5547
        }
5548
        oprot.writeFieldEnd();
648 chandransh 5549
      } else if (this.isSetSe()) {
5550
        oprot.writeFieldBegin(SE_FIELD_DESC);
5551
        this.se.write(oprot);
5552
        oprot.writeFieldEnd();
412 ashish 5553
      }
5554
      oprot.writeFieldStop();
5555
      oprot.writeStructEnd();
5556
    }
5557
 
5558
    @Override
5559
    public String toString() {
648 chandransh 5560
      StringBuilder sb = new StringBuilder("getShipmentInfo_result(");
412 ashish 5561
      boolean first = true;
5562
 
5563
      sb.append("success:");
5564
      if (this.success == null) {
5565
        sb.append("null");
5566
      } else {
5567
        sb.append(this.success);
5568
      }
5569
      first = false;
648 chandransh 5570
      if (!first) sb.append(", ");
5571
      sb.append("se:");
5572
      if (this.se == null) {
5573
        sb.append("null");
5574
      } else {
5575
        sb.append(this.se);
5576
      }
5577
      first = false;
412 ashish 5578
      sb.append(")");
5579
      return sb.toString();
5580
    }
5581
 
3430 rajveer 5582
    public void validate() throws org.apache.thrift.TException {
412 ashish 5583
      // check for required fields
5584
    }
5585
 
3430 rajveer 5586
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5587
      try {
5588
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5589
      } catch (org.apache.thrift.TException te) {
5590
        throw new java.io.IOException(te);
5591
      }
5592
    }
5593
 
5594
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5595
      try {
5596
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5597
      } catch (org.apache.thrift.TException te) {
5598
        throw new java.io.IOException(te);
5599
      }
5600
    }
5601
 
412 ashish 5602
  }
5603
 
3430 rajveer 5604
  public static class getDestinationCode_args implements org.apache.thrift.TBase<getDestinationCode_args, getDestinationCode_args._Fields>, java.io.Serializable, Cloneable   {
5605
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getDestinationCode_args");
730 chandransh 5606
 
3430 rajveer 5607
    private static final org.apache.thrift.protocol.TField PROVIDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("providerId", org.apache.thrift.protocol.TType.I64, (short)1);
5608
    private static final org.apache.thrift.protocol.TField PIN_CODE_FIELD_DESC = new org.apache.thrift.protocol.TField("pinCode", org.apache.thrift.protocol.TType.STRING, (short)2);
730 chandransh 5609
 
3430 rajveer 5610
    private long providerId; // required
5611
    private String pinCode; // required
730 chandransh 5612
 
5613
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 5614
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
730 chandransh 5615
      PROVIDER_ID((short)1, "providerId"),
5616
      PIN_CODE((short)2, "pinCode");
5617
 
5618
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5619
 
5620
      static {
5621
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
5622
          byName.put(field.getFieldName(), field);
5623
        }
5624
      }
5625
 
5626
      /**
5627
       * Find the _Fields constant that matches fieldId, or null if its not found.
5628
       */
5629
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 5630
        switch(fieldId) {
5631
          case 1: // PROVIDER_ID
5632
            return PROVIDER_ID;
5633
          case 2: // PIN_CODE
5634
            return PIN_CODE;
5635
          default:
5636
            return null;
5637
        }
730 chandransh 5638
      }
5639
 
5640
      /**
5641
       * Find the _Fields constant that matches fieldId, throwing an exception
5642
       * if it is not found.
5643
       */
5644
      public static _Fields findByThriftIdOrThrow(int fieldId) {
5645
        _Fields fields = findByThriftId(fieldId);
5646
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
5647
        return fields;
5648
      }
5649
 
5650
      /**
5651
       * Find the _Fields constant that matches name, or null if its not found.
5652
       */
5653
      public static _Fields findByName(String name) {
5654
        return byName.get(name);
5655
      }
5656
 
5657
      private final short _thriftId;
5658
      private final String _fieldName;
5659
 
5660
      _Fields(short thriftId, String fieldName) {
5661
        _thriftId = thriftId;
5662
        _fieldName = fieldName;
5663
      }
5664
 
5665
      public short getThriftFieldId() {
5666
        return _thriftId;
5667
      }
5668
 
5669
      public String getFieldName() {
5670
        return _fieldName;
5671
      }
5672
    }
5673
 
5674
    // isset id assignments
5675
    private static final int __PROVIDERID_ISSET_ID = 0;
5676
    private BitSet __isset_bit_vector = new BitSet(1);
5677
 
3430 rajveer 5678
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
730 chandransh 5679
    static {
3430 rajveer 5680
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
5681
      tmpMap.put(_Fields.PROVIDER_ID, new org.apache.thrift.meta_data.FieldMetaData("providerId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5682
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
5683
      tmpMap.put(_Fields.PIN_CODE, new org.apache.thrift.meta_data.FieldMetaData("pinCode", org.apache.thrift.TFieldRequirementType.DEFAULT, 
5684
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
5685
      metaDataMap = Collections.unmodifiableMap(tmpMap);
5686
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getDestinationCode_args.class, metaDataMap);
730 chandransh 5687
    }
5688
 
5689
    public getDestinationCode_args() {
5690
    }
5691
 
5692
    public getDestinationCode_args(
5693
      long providerId,
5694
      String pinCode)
5695
    {
5696
      this();
5697
      this.providerId = providerId;
5698
      setProviderIdIsSet(true);
5699
      this.pinCode = pinCode;
5700
    }
5701
 
5702
    /**
5703
     * Performs a deep copy on <i>other</i>.
5704
     */
5705
    public getDestinationCode_args(getDestinationCode_args other) {
5706
      __isset_bit_vector.clear();
5707
      __isset_bit_vector.or(other.__isset_bit_vector);
5708
      this.providerId = other.providerId;
5709
      if (other.isSetPinCode()) {
5710
        this.pinCode = other.pinCode;
5711
      }
5712
    }
5713
 
5714
    public getDestinationCode_args deepCopy() {
5715
      return new getDestinationCode_args(this);
5716
    }
5717
 
3430 rajveer 5718
    @Override
5719
    public void clear() {
5720
      setProviderIdIsSet(false);
5721
      this.providerId = 0;
5722
      this.pinCode = null;
730 chandransh 5723
    }
5724
 
5725
    public long getProviderId() {
5726
      return this.providerId;
5727
    }
5728
 
3430 rajveer 5729
    public void setProviderId(long providerId) {
730 chandransh 5730
      this.providerId = providerId;
5731
      setProviderIdIsSet(true);
5732
    }
5733
 
5734
    public void unsetProviderId() {
5735
      __isset_bit_vector.clear(__PROVIDERID_ISSET_ID);
5736
    }
5737
 
3430 rajveer 5738
    /** Returns true if field providerId is set (has been assigned a value) and false otherwise */
730 chandransh 5739
    public boolean isSetProviderId() {
5740
      return __isset_bit_vector.get(__PROVIDERID_ISSET_ID);
5741
    }
5742
 
5743
    public void setProviderIdIsSet(boolean value) {
5744
      __isset_bit_vector.set(__PROVIDERID_ISSET_ID, value);
5745
    }
5746
 
5747
    public String getPinCode() {
5748
      return this.pinCode;
5749
    }
5750
 
3430 rajveer 5751
    public void setPinCode(String pinCode) {
730 chandransh 5752
      this.pinCode = pinCode;
5753
    }
5754
 
5755
    public void unsetPinCode() {
5756
      this.pinCode = null;
5757
    }
5758
 
3430 rajveer 5759
    /** Returns true if field pinCode is set (has been assigned a value) and false otherwise */
730 chandransh 5760
    public boolean isSetPinCode() {
5761
      return this.pinCode != null;
5762
    }
5763
 
5764
    public void setPinCodeIsSet(boolean value) {
5765
      if (!value) {
5766
        this.pinCode = null;
5767
      }
5768
    }
5769
 
5770
    public void setFieldValue(_Fields field, Object value) {
5771
      switch (field) {
5772
      case PROVIDER_ID:
5773
        if (value == null) {
5774
          unsetProviderId();
5775
        } else {
5776
          setProviderId((Long)value);
5777
        }
5778
        break;
5779
 
5780
      case PIN_CODE:
5781
        if (value == null) {
5782
          unsetPinCode();
5783
        } else {
5784
          setPinCode((String)value);
5785
        }
5786
        break;
5787
 
5788
      }
5789
    }
5790
 
5791
    public Object getFieldValue(_Fields field) {
5792
      switch (field) {
5793
      case PROVIDER_ID:
3430 rajveer 5794
        return Long.valueOf(getProviderId());
730 chandransh 5795
 
5796
      case PIN_CODE:
5797
        return getPinCode();
5798
 
5799
      }
5800
      throw new IllegalStateException();
5801
    }
5802
 
3430 rajveer 5803
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
5804
    public boolean isSet(_Fields field) {
5805
      if (field == null) {
5806
        throw new IllegalArgumentException();
5807
      }
730 chandransh 5808
 
5809
      switch (field) {
5810
      case PROVIDER_ID:
5811
        return isSetProviderId();
5812
      case PIN_CODE:
5813
        return isSetPinCode();
5814
      }
5815
      throw new IllegalStateException();
5816
    }
5817
 
5818
    @Override
5819
    public boolean equals(Object that) {
5820
      if (that == null)
5821
        return false;
5822
      if (that instanceof getDestinationCode_args)
5823
        return this.equals((getDestinationCode_args)that);
5824
      return false;
5825
    }
5826
 
5827
    public boolean equals(getDestinationCode_args that) {
5828
      if (that == null)
5829
        return false;
5830
 
5831
      boolean this_present_providerId = true;
5832
      boolean that_present_providerId = true;
5833
      if (this_present_providerId || that_present_providerId) {
5834
        if (!(this_present_providerId && that_present_providerId))
5835
          return false;
5836
        if (this.providerId != that.providerId)
5837
          return false;
5838
      }
5839
 
5840
      boolean this_present_pinCode = true && this.isSetPinCode();
5841
      boolean that_present_pinCode = true && that.isSetPinCode();
5842
      if (this_present_pinCode || that_present_pinCode) {
5843
        if (!(this_present_pinCode && that_present_pinCode))
5844
          return false;
5845
        if (!this.pinCode.equals(that.pinCode))
5846
          return false;
5847
      }
5848
 
5849
      return true;
5850
    }
5851
 
5852
    @Override
5853
    public int hashCode() {
5854
      return 0;
5855
    }
5856
 
5857
    public int compareTo(getDestinationCode_args other) {
5858
      if (!getClass().equals(other.getClass())) {
5859
        return getClass().getName().compareTo(other.getClass().getName());
5860
      }
5861
 
5862
      int lastComparison = 0;
5863
      getDestinationCode_args typedOther = (getDestinationCode_args)other;
5864
 
3430 rajveer 5865
      lastComparison = Boolean.valueOf(isSetProviderId()).compareTo(typedOther.isSetProviderId());
730 chandransh 5866
      if (lastComparison != 0) {
5867
        return lastComparison;
5868
      }
3430 rajveer 5869
      if (isSetProviderId()) {
5870
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.providerId, typedOther.providerId);
5871
        if (lastComparison != 0) {
5872
          return lastComparison;
5873
        }
730 chandransh 5874
      }
3430 rajveer 5875
      lastComparison = Boolean.valueOf(isSetPinCode()).compareTo(typedOther.isSetPinCode());
730 chandransh 5876
      if (lastComparison != 0) {
5877
        return lastComparison;
5878
      }
3430 rajveer 5879
      if (isSetPinCode()) {
5880
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.pinCode, typedOther.pinCode);
5881
        if (lastComparison != 0) {
5882
          return lastComparison;
5883
        }
730 chandransh 5884
      }
5885
      return 0;
5886
    }
5887
 
3430 rajveer 5888
    public _Fields fieldForId(int fieldId) {
5889
      return _Fields.findByThriftId(fieldId);
5890
    }
5891
 
5892
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
5893
      org.apache.thrift.protocol.TField field;
730 chandransh 5894
      iprot.readStructBegin();
5895
      while (true)
5896
      {
5897
        field = iprot.readFieldBegin();
3430 rajveer 5898
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
730 chandransh 5899
          break;
5900
        }
3430 rajveer 5901
        switch (field.id) {
5902
          case 1: // PROVIDER_ID
5903
            if (field.type == org.apache.thrift.protocol.TType.I64) {
5904
              this.providerId = iprot.readI64();
5905
              setProviderIdIsSet(true);
5906
            } else { 
5907
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5908
            }
5909
            break;
5910
          case 2: // PIN_CODE
5911
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
5912
              this.pinCode = iprot.readString();
5913
            } else { 
5914
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
5915
            }
5916
            break;
5917
          default:
5918
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
730 chandransh 5919
        }
3430 rajveer 5920
        iprot.readFieldEnd();
730 chandransh 5921
      }
5922
      iprot.readStructEnd();
5923
      validate();
5924
    }
5925
 
3430 rajveer 5926
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
730 chandransh 5927
      validate();
5928
 
5929
      oprot.writeStructBegin(STRUCT_DESC);
5930
      oprot.writeFieldBegin(PROVIDER_ID_FIELD_DESC);
5931
      oprot.writeI64(this.providerId);
5932
      oprot.writeFieldEnd();
5933
      if (this.pinCode != null) {
5934
        oprot.writeFieldBegin(PIN_CODE_FIELD_DESC);
5935
        oprot.writeString(this.pinCode);
5936
        oprot.writeFieldEnd();
5937
      }
5938
      oprot.writeFieldStop();
5939
      oprot.writeStructEnd();
5940
    }
5941
 
5942
    @Override
5943
    public String toString() {
5944
      StringBuilder sb = new StringBuilder("getDestinationCode_args(");
5945
      boolean first = true;
5946
 
5947
      sb.append("providerId:");
5948
      sb.append(this.providerId);
5949
      first = false;
5950
      if (!first) sb.append(", ");
5951
      sb.append("pinCode:");
5952
      if (this.pinCode == null) {
5953
        sb.append("null");
5954
      } else {
5955
        sb.append(this.pinCode);
5956
      }
5957
      first = false;
5958
      sb.append(")");
5959
      return sb.toString();
5960
    }
5961
 
3430 rajveer 5962
    public void validate() throws org.apache.thrift.TException {
730 chandransh 5963
      // check for required fields
5964
    }
5965
 
3430 rajveer 5966
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
5967
      try {
5968
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
5969
      } catch (org.apache.thrift.TException te) {
5970
        throw new java.io.IOException(te);
5971
      }
5972
    }
5973
 
5974
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
5975
      try {
5976
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
5977
      } catch (org.apache.thrift.TException te) {
5978
        throw new java.io.IOException(te);
5979
      }
5980
    }
5981
 
730 chandransh 5982
  }
5983
 
3430 rajveer 5984
  public static class getDestinationCode_result implements org.apache.thrift.TBase<getDestinationCode_result, getDestinationCode_result._Fields>, java.io.Serializable, Cloneable   {
5985
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getDestinationCode_result");
730 chandransh 5986
 
3430 rajveer 5987
    private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRING, (short)0);
5988
    private static final org.apache.thrift.protocol.TField SE_FIELD_DESC = new org.apache.thrift.protocol.TField("se", org.apache.thrift.protocol.TType.STRUCT, (short)1);
730 chandransh 5989
 
3430 rajveer 5990
    private String success; // required
5991
    private LogisticsServiceException se; // required
730 chandransh 5992
 
5993
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 5994
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
730 chandransh 5995
      SUCCESS((short)0, "success"),
5996
      SE((short)1, "se");
5997
 
5998
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
5999
 
6000
      static {
6001
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6002
          byName.put(field.getFieldName(), field);
6003
        }
6004
      }
6005
 
6006
      /**
6007
       * Find the _Fields constant that matches fieldId, or null if its not found.
6008
       */
6009
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6010
        switch(fieldId) {
6011
          case 0: // SUCCESS
6012
            return SUCCESS;
6013
          case 1: // SE
6014
            return SE;
6015
          default:
6016
            return null;
6017
        }
730 chandransh 6018
      }
6019
 
6020
      /**
6021
       * Find the _Fields constant that matches fieldId, throwing an exception
6022
       * if it is not found.
6023
       */
6024
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6025
        _Fields fields = findByThriftId(fieldId);
6026
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6027
        return fields;
6028
      }
6029
 
6030
      /**
6031
       * Find the _Fields constant that matches name, or null if its not found.
6032
       */
6033
      public static _Fields findByName(String name) {
6034
        return byName.get(name);
6035
      }
6036
 
6037
      private final short _thriftId;
6038
      private final String _fieldName;
6039
 
6040
      _Fields(short thriftId, String fieldName) {
6041
        _thriftId = thriftId;
6042
        _fieldName = fieldName;
6043
      }
6044
 
6045
      public short getThriftFieldId() {
6046
        return _thriftId;
6047
      }
6048
 
6049
      public String getFieldName() {
6050
        return _fieldName;
6051
      }
6052
    }
6053
 
6054
    // isset id assignments
6055
 
3430 rajveer 6056
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
730 chandransh 6057
    static {
3430 rajveer 6058
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6059
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6060
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
6061
      tmpMap.put(_Fields.SE, new org.apache.thrift.meta_data.FieldMetaData("se", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6062
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
6063
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6064
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getDestinationCode_result.class, metaDataMap);
730 chandransh 6065
    }
6066
 
6067
    public getDestinationCode_result() {
6068
    }
6069
 
6070
    public getDestinationCode_result(
6071
      String success,
6072
      LogisticsServiceException se)
6073
    {
6074
      this();
6075
      this.success = success;
6076
      this.se = se;
6077
    }
6078
 
6079
    /**
6080
     * Performs a deep copy on <i>other</i>.
6081
     */
6082
    public getDestinationCode_result(getDestinationCode_result other) {
6083
      if (other.isSetSuccess()) {
6084
        this.success = other.success;
6085
      }
6086
      if (other.isSetSe()) {
6087
        this.se = new LogisticsServiceException(other.se);
6088
      }
6089
    }
6090
 
6091
    public getDestinationCode_result deepCopy() {
6092
      return new getDestinationCode_result(this);
6093
    }
6094
 
3430 rajveer 6095
    @Override
6096
    public void clear() {
6097
      this.success = null;
6098
      this.se = null;
730 chandransh 6099
    }
6100
 
6101
    public String getSuccess() {
6102
      return this.success;
6103
    }
6104
 
3430 rajveer 6105
    public void setSuccess(String success) {
730 chandransh 6106
      this.success = success;
6107
    }
6108
 
6109
    public void unsetSuccess() {
6110
      this.success = null;
6111
    }
6112
 
3430 rajveer 6113
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
730 chandransh 6114
    public boolean isSetSuccess() {
6115
      return this.success != null;
6116
    }
6117
 
6118
    public void setSuccessIsSet(boolean value) {
6119
      if (!value) {
6120
        this.success = null;
6121
      }
6122
    }
6123
 
6124
    public LogisticsServiceException getSe() {
6125
      return this.se;
6126
    }
6127
 
3430 rajveer 6128
    public void setSe(LogisticsServiceException se) {
730 chandransh 6129
      this.se = se;
6130
    }
6131
 
6132
    public void unsetSe() {
6133
      this.se = null;
6134
    }
6135
 
3430 rajveer 6136
    /** Returns true if field se is set (has been assigned a value) and false otherwise */
730 chandransh 6137
    public boolean isSetSe() {
6138
      return this.se != null;
6139
    }
6140
 
6141
    public void setSeIsSet(boolean value) {
6142
      if (!value) {
6143
        this.se = null;
6144
      }
6145
    }
6146
 
6147
    public void setFieldValue(_Fields field, Object value) {
6148
      switch (field) {
6149
      case SUCCESS:
6150
        if (value == null) {
6151
          unsetSuccess();
6152
        } else {
6153
          setSuccess((String)value);
6154
        }
6155
        break;
6156
 
6157
      case SE:
6158
        if (value == null) {
6159
          unsetSe();
6160
        } else {
6161
          setSe((LogisticsServiceException)value);
6162
        }
6163
        break;
6164
 
6165
      }
6166
    }
6167
 
6168
    public Object getFieldValue(_Fields field) {
6169
      switch (field) {
6170
      case SUCCESS:
6171
        return getSuccess();
6172
 
6173
      case SE:
6174
        return getSe();
6175
 
6176
      }
6177
      throw new IllegalStateException();
6178
    }
6179
 
3430 rajveer 6180
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6181
    public boolean isSet(_Fields field) {
6182
      if (field == null) {
6183
        throw new IllegalArgumentException();
6184
      }
730 chandransh 6185
 
6186
      switch (field) {
6187
      case SUCCESS:
6188
        return isSetSuccess();
6189
      case SE:
6190
        return isSetSe();
6191
      }
6192
      throw new IllegalStateException();
6193
    }
6194
 
6195
    @Override
6196
    public boolean equals(Object that) {
6197
      if (that == null)
6198
        return false;
6199
      if (that instanceof getDestinationCode_result)
6200
        return this.equals((getDestinationCode_result)that);
6201
      return false;
6202
    }
6203
 
6204
    public boolean equals(getDestinationCode_result that) {
6205
      if (that == null)
6206
        return false;
6207
 
6208
      boolean this_present_success = true && this.isSetSuccess();
6209
      boolean that_present_success = true && that.isSetSuccess();
6210
      if (this_present_success || that_present_success) {
6211
        if (!(this_present_success && that_present_success))
6212
          return false;
6213
        if (!this.success.equals(that.success))
6214
          return false;
6215
      }
6216
 
6217
      boolean this_present_se = true && this.isSetSe();
6218
      boolean that_present_se = true && that.isSetSe();
6219
      if (this_present_se || that_present_se) {
6220
        if (!(this_present_se && that_present_se))
6221
          return false;
6222
        if (!this.se.equals(that.se))
6223
          return false;
6224
      }
6225
 
6226
      return true;
6227
    }
6228
 
6229
    @Override
6230
    public int hashCode() {
6231
      return 0;
6232
    }
6233
 
6234
    public int compareTo(getDestinationCode_result other) {
6235
      if (!getClass().equals(other.getClass())) {
6236
        return getClass().getName().compareTo(other.getClass().getName());
6237
      }
6238
 
6239
      int lastComparison = 0;
6240
      getDestinationCode_result typedOther = (getDestinationCode_result)other;
6241
 
3430 rajveer 6242
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
730 chandransh 6243
      if (lastComparison != 0) {
6244
        return lastComparison;
6245
      }
3430 rajveer 6246
      if (isSetSuccess()) {
6247
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
6248
        if (lastComparison != 0) {
6249
          return lastComparison;
6250
        }
730 chandransh 6251
      }
3430 rajveer 6252
      lastComparison = Boolean.valueOf(isSetSe()).compareTo(typedOther.isSetSe());
730 chandransh 6253
      if (lastComparison != 0) {
6254
        return lastComparison;
6255
      }
3430 rajveer 6256
      if (isSetSe()) {
6257
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.se, typedOther.se);
6258
        if (lastComparison != 0) {
6259
          return lastComparison;
6260
        }
730 chandransh 6261
      }
6262
      return 0;
6263
    }
6264
 
3430 rajveer 6265
    public _Fields fieldForId(int fieldId) {
6266
      return _Fields.findByThriftId(fieldId);
6267
    }
6268
 
6269
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6270
      org.apache.thrift.protocol.TField field;
730 chandransh 6271
      iprot.readStructBegin();
6272
      while (true)
6273
      {
6274
        field = iprot.readFieldBegin();
3430 rajveer 6275
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
730 chandransh 6276
          break;
6277
        }
3430 rajveer 6278
        switch (field.id) {
6279
          case 0: // SUCCESS
6280
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
6281
              this.success = iprot.readString();
6282
            } else { 
6283
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6284
            }
6285
            break;
6286
          case 1: // SE
6287
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
6288
              this.se = new LogisticsServiceException();
6289
              this.se.read(iprot);
6290
            } else { 
6291
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6292
            }
6293
            break;
6294
          default:
6295
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
730 chandransh 6296
        }
3430 rajveer 6297
        iprot.readFieldEnd();
730 chandransh 6298
      }
6299
      iprot.readStructEnd();
6300
      validate();
6301
    }
6302
 
3430 rajveer 6303
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
730 chandransh 6304
      oprot.writeStructBegin(STRUCT_DESC);
6305
 
6306
      if (this.isSetSuccess()) {
6307
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
6308
        oprot.writeString(this.success);
6309
        oprot.writeFieldEnd();
6310
      } else if (this.isSetSe()) {
6311
        oprot.writeFieldBegin(SE_FIELD_DESC);
6312
        this.se.write(oprot);
6313
        oprot.writeFieldEnd();
6314
      }
6315
      oprot.writeFieldStop();
6316
      oprot.writeStructEnd();
6317
    }
6318
 
6319
    @Override
6320
    public String toString() {
6321
      StringBuilder sb = new StringBuilder("getDestinationCode_result(");
6322
      boolean first = true;
6323
 
6324
      sb.append("success:");
6325
      if (this.success == null) {
6326
        sb.append("null");
6327
      } else {
6328
        sb.append(this.success);
6329
      }
6330
      first = false;
6331
      if (!first) sb.append(", ");
6332
      sb.append("se:");
6333
      if (this.se == null) {
6334
        sb.append("null");
6335
      } else {
6336
        sb.append(this.se);
6337
      }
6338
      first = false;
6339
      sb.append(")");
6340
      return sb.toString();
6341
    }
6342
 
3430 rajveer 6343
    public void validate() throws org.apache.thrift.TException {
730 chandransh 6344
      // check for required fields
6345
    }
6346
 
3430 rajveer 6347
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6348
      try {
6349
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6350
      } catch (org.apache.thrift.TException te) {
6351
        throw new java.io.IOException(te);
6352
      }
6353
    }
6354
 
6355
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6356
      try {
6357
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6358
      } catch (org.apache.thrift.TException te) {
6359
        throw new java.io.IOException(te);
6360
      }
6361
    }
6362
 
730 chandransh 6363
  }
6364
 
3430 rajveer 6365
  public static class getFreeAwbCount_args implements org.apache.thrift.TBase<getFreeAwbCount_args, getFreeAwbCount_args._Fields>, java.io.Serializable, Cloneable   {
6366
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getFreeAwbCount_args");
1139 chandransh 6367
 
3430 rajveer 6368
    private static final org.apache.thrift.protocol.TField PROVIDER_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("providerId", org.apache.thrift.protocol.TType.I64, (short)1);
6369
    private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.STRING, (short)2);
1139 chandransh 6370
 
3430 rajveer 6371
    private long providerId; // required
6372
    private String type; // required
1139 chandransh 6373
 
6374
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 6375
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
3103 chandransh 6376
      PROVIDER_ID((short)1, "providerId"),
6377
      TYPE((short)2, "type");
1139 chandransh 6378
 
6379
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6380
 
6381
      static {
6382
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6383
          byName.put(field.getFieldName(), field);
6384
        }
6385
      }
6386
 
6387
      /**
6388
       * Find the _Fields constant that matches fieldId, or null if its not found.
6389
       */
6390
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6391
        switch(fieldId) {
6392
          case 1: // PROVIDER_ID
6393
            return PROVIDER_ID;
6394
          case 2: // TYPE
6395
            return TYPE;
6396
          default:
6397
            return null;
6398
        }
1139 chandransh 6399
      }
6400
 
6401
      /**
6402
       * Find the _Fields constant that matches fieldId, throwing an exception
6403
       * if it is not found.
6404
       */
6405
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6406
        _Fields fields = findByThriftId(fieldId);
6407
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6408
        return fields;
6409
      }
6410
 
6411
      /**
6412
       * Find the _Fields constant that matches name, or null if its not found.
6413
       */
6414
      public static _Fields findByName(String name) {
6415
        return byName.get(name);
6416
      }
6417
 
6418
      private final short _thriftId;
6419
      private final String _fieldName;
6420
 
6421
      _Fields(short thriftId, String fieldName) {
6422
        _thriftId = thriftId;
6423
        _fieldName = fieldName;
6424
      }
6425
 
6426
      public short getThriftFieldId() {
6427
        return _thriftId;
6428
      }
6429
 
6430
      public String getFieldName() {
6431
        return _fieldName;
6432
      }
6433
    }
6434
 
6435
    // isset id assignments
6436
    private static final int __PROVIDERID_ISSET_ID = 0;
6437
    private BitSet __isset_bit_vector = new BitSet(1);
6438
 
3430 rajveer 6439
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1139 chandransh 6440
    static {
3430 rajveer 6441
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6442
      tmpMap.put(_Fields.PROVIDER_ID, new org.apache.thrift.meta_data.FieldMetaData("providerId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6443
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6444
      tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6445
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
6446
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6447
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getFreeAwbCount_args.class, metaDataMap);
1139 chandransh 6448
    }
6449
 
6450
    public getFreeAwbCount_args() {
6451
    }
6452
 
6453
    public getFreeAwbCount_args(
3103 chandransh 6454
      long providerId,
6455
      String type)
1139 chandransh 6456
    {
6457
      this();
6458
      this.providerId = providerId;
6459
      setProviderIdIsSet(true);
3103 chandransh 6460
      this.type = type;
1139 chandransh 6461
    }
6462
 
6463
    /**
6464
     * Performs a deep copy on <i>other</i>.
6465
     */
6466
    public getFreeAwbCount_args(getFreeAwbCount_args other) {
6467
      __isset_bit_vector.clear();
6468
      __isset_bit_vector.or(other.__isset_bit_vector);
6469
      this.providerId = other.providerId;
3103 chandransh 6470
      if (other.isSetType()) {
6471
        this.type = other.type;
6472
      }
1139 chandransh 6473
    }
6474
 
6475
    public getFreeAwbCount_args deepCopy() {
6476
      return new getFreeAwbCount_args(this);
6477
    }
6478
 
3430 rajveer 6479
    @Override
6480
    public void clear() {
6481
      setProviderIdIsSet(false);
6482
      this.providerId = 0;
6483
      this.type = null;
1139 chandransh 6484
    }
6485
 
6486
    public long getProviderId() {
6487
      return this.providerId;
6488
    }
6489
 
3430 rajveer 6490
    public void setProviderId(long providerId) {
1139 chandransh 6491
      this.providerId = providerId;
6492
      setProviderIdIsSet(true);
6493
    }
6494
 
6495
    public void unsetProviderId() {
6496
      __isset_bit_vector.clear(__PROVIDERID_ISSET_ID);
6497
    }
6498
 
3430 rajveer 6499
    /** Returns true if field providerId is set (has been assigned a value) and false otherwise */
1139 chandransh 6500
    public boolean isSetProviderId() {
6501
      return __isset_bit_vector.get(__PROVIDERID_ISSET_ID);
6502
    }
6503
 
6504
    public void setProviderIdIsSet(boolean value) {
6505
      __isset_bit_vector.set(__PROVIDERID_ISSET_ID, value);
6506
    }
6507
 
3103 chandransh 6508
    public String getType() {
6509
      return this.type;
6510
    }
6511
 
3430 rajveer 6512
    public void setType(String type) {
3103 chandransh 6513
      this.type = type;
6514
    }
6515
 
6516
    public void unsetType() {
6517
      this.type = null;
6518
    }
6519
 
3430 rajveer 6520
    /** Returns true if field type is set (has been assigned a value) and false otherwise */
3103 chandransh 6521
    public boolean isSetType() {
6522
      return this.type != null;
6523
    }
6524
 
6525
    public void setTypeIsSet(boolean value) {
6526
      if (!value) {
6527
        this.type = null;
6528
      }
6529
    }
6530
 
1139 chandransh 6531
    public void setFieldValue(_Fields field, Object value) {
6532
      switch (field) {
6533
      case PROVIDER_ID:
6534
        if (value == null) {
6535
          unsetProviderId();
6536
        } else {
6537
          setProviderId((Long)value);
6538
        }
6539
        break;
6540
 
3103 chandransh 6541
      case TYPE:
6542
        if (value == null) {
6543
          unsetType();
6544
        } else {
6545
          setType((String)value);
6546
        }
6547
        break;
6548
 
1139 chandransh 6549
      }
6550
    }
6551
 
6552
    public Object getFieldValue(_Fields field) {
6553
      switch (field) {
6554
      case PROVIDER_ID:
3430 rajveer 6555
        return Long.valueOf(getProviderId());
1139 chandransh 6556
 
3103 chandransh 6557
      case TYPE:
6558
        return getType();
6559
 
1139 chandransh 6560
      }
6561
      throw new IllegalStateException();
6562
    }
6563
 
3430 rajveer 6564
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6565
    public boolean isSet(_Fields field) {
6566
      if (field == null) {
6567
        throw new IllegalArgumentException();
6568
      }
1139 chandransh 6569
 
6570
      switch (field) {
6571
      case PROVIDER_ID:
6572
        return isSetProviderId();
3103 chandransh 6573
      case TYPE:
6574
        return isSetType();
1139 chandransh 6575
      }
6576
      throw new IllegalStateException();
6577
    }
6578
 
6579
    @Override
6580
    public boolean equals(Object that) {
6581
      if (that == null)
6582
        return false;
6583
      if (that instanceof getFreeAwbCount_args)
6584
        return this.equals((getFreeAwbCount_args)that);
6585
      return false;
6586
    }
6587
 
6588
    public boolean equals(getFreeAwbCount_args that) {
6589
      if (that == null)
6590
        return false;
6591
 
6592
      boolean this_present_providerId = true;
6593
      boolean that_present_providerId = true;
6594
      if (this_present_providerId || that_present_providerId) {
6595
        if (!(this_present_providerId && that_present_providerId))
6596
          return false;
6597
        if (this.providerId != that.providerId)
6598
          return false;
6599
      }
6600
 
3103 chandransh 6601
      boolean this_present_type = true && this.isSetType();
6602
      boolean that_present_type = true && that.isSetType();
6603
      if (this_present_type || that_present_type) {
6604
        if (!(this_present_type && that_present_type))
6605
          return false;
6606
        if (!this.type.equals(that.type))
6607
          return false;
6608
      }
6609
 
1139 chandransh 6610
      return true;
6611
    }
6612
 
6613
    @Override
6614
    public int hashCode() {
6615
      return 0;
6616
    }
6617
 
6618
    public int compareTo(getFreeAwbCount_args other) {
6619
      if (!getClass().equals(other.getClass())) {
6620
        return getClass().getName().compareTo(other.getClass().getName());
6621
      }
6622
 
6623
      int lastComparison = 0;
6624
      getFreeAwbCount_args typedOther = (getFreeAwbCount_args)other;
6625
 
3430 rajveer 6626
      lastComparison = Boolean.valueOf(isSetProviderId()).compareTo(typedOther.isSetProviderId());
1139 chandransh 6627
      if (lastComparison != 0) {
6628
        return lastComparison;
6629
      }
3430 rajveer 6630
      if (isSetProviderId()) {
6631
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.providerId, typedOther.providerId);
6632
        if (lastComparison != 0) {
6633
          return lastComparison;
6634
        }
1139 chandransh 6635
      }
3430 rajveer 6636
      lastComparison = Boolean.valueOf(isSetType()).compareTo(typedOther.isSetType());
3103 chandransh 6637
      if (lastComparison != 0) {
6638
        return lastComparison;
6639
      }
3430 rajveer 6640
      if (isSetType()) {
6641
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, typedOther.type);
6642
        if (lastComparison != 0) {
6643
          return lastComparison;
6644
        }
3103 chandransh 6645
      }
1139 chandransh 6646
      return 0;
6647
    }
6648
 
3430 rajveer 6649
    public _Fields fieldForId(int fieldId) {
6650
      return _Fields.findByThriftId(fieldId);
6651
    }
6652
 
6653
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6654
      org.apache.thrift.protocol.TField field;
1139 chandransh 6655
      iprot.readStructBegin();
6656
      while (true)
6657
      {
6658
        field = iprot.readFieldBegin();
3430 rajveer 6659
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1139 chandransh 6660
          break;
6661
        }
3430 rajveer 6662
        switch (field.id) {
6663
          case 1: // PROVIDER_ID
6664
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6665
              this.providerId = iprot.readI64();
6666
              setProviderIdIsSet(true);
6667
            } else { 
6668
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6669
            }
6670
            break;
6671
          case 2: // TYPE
6672
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
6673
              this.type = iprot.readString();
6674
            } else { 
6675
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6676
            }
6677
            break;
6678
          default:
6679
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1139 chandransh 6680
        }
3430 rajveer 6681
        iprot.readFieldEnd();
1139 chandransh 6682
      }
6683
      iprot.readStructEnd();
6684
      validate();
6685
    }
6686
 
3430 rajveer 6687
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1139 chandransh 6688
      validate();
6689
 
6690
      oprot.writeStructBegin(STRUCT_DESC);
6691
      oprot.writeFieldBegin(PROVIDER_ID_FIELD_DESC);
6692
      oprot.writeI64(this.providerId);
6693
      oprot.writeFieldEnd();
3103 chandransh 6694
      if (this.type != null) {
6695
        oprot.writeFieldBegin(TYPE_FIELD_DESC);
6696
        oprot.writeString(this.type);
6697
        oprot.writeFieldEnd();
6698
      }
1139 chandransh 6699
      oprot.writeFieldStop();
6700
      oprot.writeStructEnd();
6701
    }
6702
 
6703
    @Override
6704
    public String toString() {
6705
      StringBuilder sb = new StringBuilder("getFreeAwbCount_args(");
6706
      boolean first = true;
6707
 
6708
      sb.append("providerId:");
6709
      sb.append(this.providerId);
6710
      first = false;
3103 chandransh 6711
      if (!first) sb.append(", ");
6712
      sb.append("type:");
6713
      if (this.type == null) {
6714
        sb.append("null");
6715
      } else {
6716
        sb.append(this.type);
6717
      }
6718
      first = false;
1139 chandransh 6719
      sb.append(")");
6720
      return sb.toString();
6721
    }
6722
 
3430 rajveer 6723
    public void validate() throws org.apache.thrift.TException {
1139 chandransh 6724
      // check for required fields
6725
    }
6726
 
3430 rajveer 6727
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
6728
      try {
6729
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
6730
      } catch (org.apache.thrift.TException te) {
6731
        throw new java.io.IOException(te);
6732
      }
6733
    }
6734
 
6735
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
6736
      try {
6737
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
6738
      } catch (org.apache.thrift.TException te) {
6739
        throw new java.io.IOException(te);
6740
      }
6741
    }
6742
 
1139 chandransh 6743
  }
6744
 
3430 rajveer 6745
  public static class getFreeAwbCount_result implements org.apache.thrift.TBase<getFreeAwbCount_result, getFreeAwbCount_result._Fields>, java.io.Serializable, Cloneable   {
6746
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getFreeAwbCount_result");
1139 chandransh 6747
 
3430 rajveer 6748
    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);
1139 chandransh 6749
 
3430 rajveer 6750
    private long success; // required
1139 chandransh 6751
 
6752
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 6753
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1139 chandransh 6754
      SUCCESS((short)0, "success");
6755
 
6756
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
6757
 
6758
      static {
6759
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
6760
          byName.put(field.getFieldName(), field);
6761
        }
6762
      }
6763
 
6764
      /**
6765
       * Find the _Fields constant that matches fieldId, or null if its not found.
6766
       */
6767
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 6768
        switch(fieldId) {
6769
          case 0: // SUCCESS
6770
            return SUCCESS;
6771
          default:
6772
            return null;
6773
        }
1139 chandransh 6774
      }
6775
 
6776
      /**
6777
       * Find the _Fields constant that matches fieldId, throwing an exception
6778
       * if it is not found.
6779
       */
6780
      public static _Fields findByThriftIdOrThrow(int fieldId) {
6781
        _Fields fields = findByThriftId(fieldId);
6782
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
6783
        return fields;
6784
      }
6785
 
6786
      /**
6787
       * Find the _Fields constant that matches name, or null if its not found.
6788
       */
6789
      public static _Fields findByName(String name) {
6790
        return byName.get(name);
6791
      }
6792
 
6793
      private final short _thriftId;
6794
      private final String _fieldName;
6795
 
6796
      _Fields(short thriftId, String fieldName) {
6797
        _thriftId = thriftId;
6798
        _fieldName = fieldName;
6799
      }
6800
 
6801
      public short getThriftFieldId() {
6802
        return _thriftId;
6803
      }
6804
 
6805
      public String getFieldName() {
6806
        return _fieldName;
6807
      }
6808
    }
6809
 
6810
    // isset id assignments
6811
    private static final int __SUCCESS_ISSET_ID = 0;
6812
    private BitSet __isset_bit_vector = new BitSet(1);
6813
 
3430 rajveer 6814
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1139 chandransh 6815
    static {
3430 rajveer 6816
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
6817
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
6818
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
6819
      metaDataMap = Collections.unmodifiableMap(tmpMap);
6820
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getFreeAwbCount_result.class, metaDataMap);
1139 chandransh 6821
    }
6822
 
6823
    public getFreeAwbCount_result() {
6824
    }
6825
 
6826
    public getFreeAwbCount_result(
6827
      long success)
6828
    {
6829
      this();
6830
      this.success = success;
6831
      setSuccessIsSet(true);
6832
    }
6833
 
6834
    /**
6835
     * Performs a deep copy on <i>other</i>.
6836
     */
6837
    public getFreeAwbCount_result(getFreeAwbCount_result other) {
6838
      __isset_bit_vector.clear();
6839
      __isset_bit_vector.or(other.__isset_bit_vector);
6840
      this.success = other.success;
6841
    }
6842
 
6843
    public getFreeAwbCount_result deepCopy() {
6844
      return new getFreeAwbCount_result(this);
6845
    }
6846
 
3430 rajveer 6847
    @Override
6848
    public void clear() {
6849
      setSuccessIsSet(false);
6850
      this.success = 0;
1139 chandransh 6851
    }
6852
 
6853
    public long getSuccess() {
6854
      return this.success;
6855
    }
6856
 
3430 rajveer 6857
    public void setSuccess(long success) {
1139 chandransh 6858
      this.success = success;
6859
      setSuccessIsSet(true);
6860
    }
6861
 
6862
    public void unsetSuccess() {
6863
      __isset_bit_vector.clear(__SUCCESS_ISSET_ID);
6864
    }
6865
 
3430 rajveer 6866
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
1139 chandransh 6867
    public boolean isSetSuccess() {
6868
      return __isset_bit_vector.get(__SUCCESS_ISSET_ID);
6869
    }
6870
 
6871
    public void setSuccessIsSet(boolean value) {
6872
      __isset_bit_vector.set(__SUCCESS_ISSET_ID, value);
6873
    }
6874
 
6875
    public void setFieldValue(_Fields field, Object value) {
6876
      switch (field) {
6877
      case SUCCESS:
6878
        if (value == null) {
6879
          unsetSuccess();
6880
        } else {
6881
          setSuccess((Long)value);
6882
        }
6883
        break;
6884
 
6885
      }
6886
    }
6887
 
6888
    public Object getFieldValue(_Fields field) {
6889
      switch (field) {
6890
      case SUCCESS:
3430 rajveer 6891
        return Long.valueOf(getSuccess());
1139 chandransh 6892
 
6893
      }
6894
      throw new IllegalStateException();
6895
    }
6896
 
3430 rajveer 6897
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
6898
    public boolean isSet(_Fields field) {
6899
      if (field == null) {
6900
        throw new IllegalArgumentException();
6901
      }
1139 chandransh 6902
 
6903
      switch (field) {
6904
      case SUCCESS:
6905
        return isSetSuccess();
6906
      }
6907
      throw new IllegalStateException();
6908
    }
6909
 
6910
    @Override
6911
    public boolean equals(Object that) {
6912
      if (that == null)
6913
        return false;
6914
      if (that instanceof getFreeAwbCount_result)
6915
        return this.equals((getFreeAwbCount_result)that);
6916
      return false;
6917
    }
6918
 
6919
    public boolean equals(getFreeAwbCount_result that) {
6920
      if (that == null)
6921
        return false;
6922
 
6923
      boolean this_present_success = true;
6924
      boolean that_present_success = true;
6925
      if (this_present_success || that_present_success) {
6926
        if (!(this_present_success && that_present_success))
6927
          return false;
6928
        if (this.success != that.success)
6929
          return false;
6930
      }
6931
 
6932
      return true;
6933
    }
6934
 
6935
    @Override
6936
    public int hashCode() {
6937
      return 0;
6938
    }
6939
 
6940
    public int compareTo(getFreeAwbCount_result other) {
6941
      if (!getClass().equals(other.getClass())) {
6942
        return getClass().getName().compareTo(other.getClass().getName());
6943
      }
6944
 
6945
      int lastComparison = 0;
6946
      getFreeAwbCount_result typedOther = (getFreeAwbCount_result)other;
6947
 
3430 rajveer 6948
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
1139 chandransh 6949
      if (lastComparison != 0) {
6950
        return lastComparison;
6951
      }
3430 rajveer 6952
      if (isSetSuccess()) {
6953
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
6954
        if (lastComparison != 0) {
6955
          return lastComparison;
6956
        }
1139 chandransh 6957
      }
6958
      return 0;
6959
    }
6960
 
3430 rajveer 6961
    public _Fields fieldForId(int fieldId) {
6962
      return _Fields.findByThriftId(fieldId);
6963
    }
6964
 
6965
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
6966
      org.apache.thrift.protocol.TField field;
1139 chandransh 6967
      iprot.readStructBegin();
6968
      while (true)
6969
      {
6970
        field = iprot.readFieldBegin();
3430 rajveer 6971
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1139 chandransh 6972
          break;
6973
        }
3430 rajveer 6974
        switch (field.id) {
6975
          case 0: // SUCCESS
6976
            if (field.type == org.apache.thrift.protocol.TType.I64) {
6977
              this.success = iprot.readI64();
6978
              setSuccessIsSet(true);
6979
            } else { 
6980
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
6981
            }
6982
            break;
6983
          default:
6984
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1139 chandransh 6985
        }
3430 rajveer 6986
        iprot.readFieldEnd();
1139 chandransh 6987
      }
6988
      iprot.readStructEnd();
6989
      validate();
6990
    }
6991
 
3430 rajveer 6992
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1139 chandransh 6993
      oprot.writeStructBegin(STRUCT_DESC);
6994
 
6995
      if (this.isSetSuccess()) {
6996
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
6997
        oprot.writeI64(this.success);
6998
        oprot.writeFieldEnd();
6999
      }
7000
      oprot.writeFieldStop();
7001
      oprot.writeStructEnd();
7002
    }
7003
 
7004
    @Override
7005
    public String toString() {
7006
      StringBuilder sb = new StringBuilder("getFreeAwbCount_result(");
7007
      boolean first = true;
7008
 
7009
      sb.append("success:");
7010
      sb.append(this.success);
7011
      first = false;
7012
      sb.append(")");
7013
      return sb.toString();
7014
    }
7015
 
3430 rajveer 7016
    public void validate() throws org.apache.thrift.TException {
1139 chandransh 7017
      // check for required fields
7018
    }
7019
 
3430 rajveer 7020
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7021
      try {
7022
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7023
      } catch (org.apache.thrift.TException te) {
7024
        throw new java.io.IOException(te);
7025
      }
7026
    }
7027
 
7028
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7029
      try {
7030
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7031
      } catch (org.apache.thrift.TException te) {
7032
        throw new java.io.IOException(te);
7033
      }
7034
    }
7035
 
1139 chandransh 7036
  }
7037
 
3430 rajveer 7038
  public static class getHolidays_args implements org.apache.thrift.TBase<getHolidays_args, getHolidays_args._Fields>, java.io.Serializable, Cloneable   {
7039
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getHolidays_args");
1730 ankur.sing 7040
 
3430 rajveer 7041
    private static final org.apache.thrift.protocol.TField FROM_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("fromDate", org.apache.thrift.protocol.TType.I64, (short)1);
7042
    private static final org.apache.thrift.protocol.TField TO_DATE_FIELD_DESC = new org.apache.thrift.protocol.TField("toDate", org.apache.thrift.protocol.TType.I64, (short)2);
1730 ankur.sing 7043
 
3430 rajveer 7044
    private long fromDate; // required
7045
    private long toDate; // required
1730 ankur.sing 7046
 
7047
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 7048
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1730 ankur.sing 7049
      FROM_DATE((short)1, "fromDate"),
7050
      TO_DATE((short)2, "toDate");
7051
 
7052
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7053
 
7054
      static {
7055
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7056
          byName.put(field.getFieldName(), field);
7057
        }
7058
      }
7059
 
7060
      /**
7061
       * Find the _Fields constant that matches fieldId, or null if its not found.
7062
       */
7063
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 7064
        switch(fieldId) {
7065
          case 1: // FROM_DATE
7066
            return FROM_DATE;
7067
          case 2: // TO_DATE
7068
            return TO_DATE;
7069
          default:
7070
            return null;
7071
        }
1730 ankur.sing 7072
      }
7073
 
7074
      /**
7075
       * Find the _Fields constant that matches fieldId, throwing an exception
7076
       * if it is not found.
7077
       */
7078
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7079
        _Fields fields = findByThriftId(fieldId);
7080
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7081
        return fields;
7082
      }
7083
 
7084
      /**
7085
       * Find the _Fields constant that matches name, or null if its not found.
7086
       */
7087
      public static _Fields findByName(String name) {
7088
        return byName.get(name);
7089
      }
7090
 
7091
      private final short _thriftId;
7092
      private final String _fieldName;
7093
 
7094
      _Fields(short thriftId, String fieldName) {
7095
        _thriftId = thriftId;
7096
        _fieldName = fieldName;
7097
      }
7098
 
7099
      public short getThriftFieldId() {
7100
        return _thriftId;
7101
      }
7102
 
7103
      public String getFieldName() {
7104
        return _fieldName;
7105
      }
7106
    }
7107
 
7108
    // isset id assignments
7109
    private static final int __FROMDATE_ISSET_ID = 0;
7110
    private static final int __TODATE_ISSET_ID = 1;
7111
    private BitSet __isset_bit_vector = new BitSet(2);
7112
 
3430 rajveer 7113
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1730 ankur.sing 7114
    static {
3430 rajveer 7115
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7116
      tmpMap.put(_Fields.FROM_DATE, new org.apache.thrift.meta_data.FieldMetaData("fromDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7117
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7118
      tmpMap.put(_Fields.TO_DATE, new org.apache.thrift.meta_data.FieldMetaData("toDate", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7119
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7120
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7121
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getHolidays_args.class, metaDataMap);
1730 ankur.sing 7122
    }
7123
 
7124
    public getHolidays_args() {
7125
    }
7126
 
7127
    public getHolidays_args(
7128
      long fromDate,
7129
      long toDate)
7130
    {
7131
      this();
7132
      this.fromDate = fromDate;
7133
      setFromDateIsSet(true);
7134
      this.toDate = toDate;
7135
      setToDateIsSet(true);
7136
    }
7137
 
7138
    /**
7139
     * Performs a deep copy on <i>other</i>.
7140
     */
7141
    public getHolidays_args(getHolidays_args other) {
7142
      __isset_bit_vector.clear();
7143
      __isset_bit_vector.or(other.__isset_bit_vector);
7144
      this.fromDate = other.fromDate;
7145
      this.toDate = other.toDate;
7146
    }
7147
 
7148
    public getHolidays_args deepCopy() {
7149
      return new getHolidays_args(this);
7150
    }
7151
 
3430 rajveer 7152
    @Override
7153
    public void clear() {
7154
      setFromDateIsSet(false);
7155
      this.fromDate = 0;
7156
      setToDateIsSet(false);
7157
      this.toDate = 0;
1730 ankur.sing 7158
    }
7159
 
7160
    public long getFromDate() {
7161
      return this.fromDate;
7162
    }
7163
 
3430 rajveer 7164
    public void setFromDate(long fromDate) {
1730 ankur.sing 7165
      this.fromDate = fromDate;
7166
      setFromDateIsSet(true);
7167
    }
7168
 
7169
    public void unsetFromDate() {
7170
      __isset_bit_vector.clear(__FROMDATE_ISSET_ID);
7171
    }
7172
 
3430 rajveer 7173
    /** Returns true if field fromDate is set (has been assigned a value) and false otherwise */
1730 ankur.sing 7174
    public boolean isSetFromDate() {
7175
      return __isset_bit_vector.get(__FROMDATE_ISSET_ID);
7176
    }
7177
 
7178
    public void setFromDateIsSet(boolean value) {
7179
      __isset_bit_vector.set(__FROMDATE_ISSET_ID, value);
7180
    }
7181
 
7182
    public long getToDate() {
7183
      return this.toDate;
7184
    }
7185
 
3430 rajveer 7186
    public void setToDate(long toDate) {
1730 ankur.sing 7187
      this.toDate = toDate;
7188
      setToDateIsSet(true);
7189
    }
7190
 
7191
    public void unsetToDate() {
7192
      __isset_bit_vector.clear(__TODATE_ISSET_ID);
7193
    }
7194
 
3430 rajveer 7195
    /** Returns true if field toDate is set (has been assigned a value) and false otherwise */
1730 ankur.sing 7196
    public boolean isSetToDate() {
7197
      return __isset_bit_vector.get(__TODATE_ISSET_ID);
7198
    }
7199
 
7200
    public void setToDateIsSet(boolean value) {
7201
      __isset_bit_vector.set(__TODATE_ISSET_ID, value);
7202
    }
7203
 
7204
    public void setFieldValue(_Fields field, Object value) {
7205
      switch (field) {
7206
      case FROM_DATE:
7207
        if (value == null) {
7208
          unsetFromDate();
7209
        } else {
7210
          setFromDate((Long)value);
7211
        }
7212
        break;
7213
 
7214
      case TO_DATE:
7215
        if (value == null) {
7216
          unsetToDate();
7217
        } else {
7218
          setToDate((Long)value);
7219
        }
7220
        break;
7221
 
7222
      }
7223
    }
7224
 
7225
    public Object getFieldValue(_Fields field) {
7226
      switch (field) {
7227
      case FROM_DATE:
3430 rajveer 7228
        return Long.valueOf(getFromDate());
1730 ankur.sing 7229
 
7230
      case TO_DATE:
3430 rajveer 7231
        return Long.valueOf(getToDate());
1730 ankur.sing 7232
 
7233
      }
7234
      throw new IllegalStateException();
7235
    }
7236
 
3430 rajveer 7237
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7238
    public boolean isSet(_Fields field) {
7239
      if (field == null) {
7240
        throw new IllegalArgumentException();
7241
      }
1730 ankur.sing 7242
 
7243
      switch (field) {
7244
      case FROM_DATE:
7245
        return isSetFromDate();
7246
      case TO_DATE:
7247
        return isSetToDate();
7248
      }
7249
      throw new IllegalStateException();
7250
    }
7251
 
7252
    @Override
7253
    public boolean equals(Object that) {
7254
      if (that == null)
7255
        return false;
7256
      if (that instanceof getHolidays_args)
7257
        return this.equals((getHolidays_args)that);
7258
      return false;
7259
    }
7260
 
7261
    public boolean equals(getHolidays_args that) {
7262
      if (that == null)
7263
        return false;
7264
 
7265
      boolean this_present_fromDate = true;
7266
      boolean that_present_fromDate = true;
7267
      if (this_present_fromDate || that_present_fromDate) {
7268
        if (!(this_present_fromDate && that_present_fromDate))
7269
          return false;
7270
        if (this.fromDate != that.fromDate)
7271
          return false;
7272
      }
7273
 
7274
      boolean this_present_toDate = true;
7275
      boolean that_present_toDate = true;
7276
      if (this_present_toDate || that_present_toDate) {
7277
        if (!(this_present_toDate && that_present_toDate))
7278
          return false;
7279
        if (this.toDate != that.toDate)
7280
          return false;
7281
      }
7282
 
7283
      return true;
7284
    }
7285
 
7286
    @Override
7287
    public int hashCode() {
7288
      return 0;
7289
    }
7290
 
7291
    public int compareTo(getHolidays_args other) {
7292
      if (!getClass().equals(other.getClass())) {
7293
        return getClass().getName().compareTo(other.getClass().getName());
7294
      }
7295
 
7296
      int lastComparison = 0;
7297
      getHolidays_args typedOther = (getHolidays_args)other;
7298
 
3430 rajveer 7299
      lastComparison = Boolean.valueOf(isSetFromDate()).compareTo(typedOther.isSetFromDate());
1730 ankur.sing 7300
      if (lastComparison != 0) {
7301
        return lastComparison;
7302
      }
3430 rajveer 7303
      if (isSetFromDate()) {
7304
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.fromDate, typedOther.fromDate);
7305
        if (lastComparison != 0) {
7306
          return lastComparison;
7307
        }
1730 ankur.sing 7308
      }
3430 rajveer 7309
      lastComparison = Boolean.valueOf(isSetToDate()).compareTo(typedOther.isSetToDate());
1730 ankur.sing 7310
      if (lastComparison != 0) {
7311
        return lastComparison;
7312
      }
3430 rajveer 7313
      if (isSetToDate()) {
7314
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.toDate, typedOther.toDate);
7315
        if (lastComparison != 0) {
7316
          return lastComparison;
7317
        }
1730 ankur.sing 7318
      }
7319
      return 0;
7320
    }
7321
 
3430 rajveer 7322
    public _Fields fieldForId(int fieldId) {
7323
      return _Fields.findByThriftId(fieldId);
7324
    }
7325
 
7326
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7327
      org.apache.thrift.protocol.TField field;
1730 ankur.sing 7328
      iprot.readStructBegin();
7329
      while (true)
7330
      {
7331
        field = iprot.readFieldBegin();
3430 rajveer 7332
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1730 ankur.sing 7333
          break;
7334
        }
3430 rajveer 7335
        switch (field.id) {
7336
          case 1: // FROM_DATE
7337
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7338
              this.fromDate = iprot.readI64();
7339
              setFromDateIsSet(true);
7340
            } else { 
7341
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7342
            }
7343
            break;
7344
          case 2: // TO_DATE
7345
            if (field.type == org.apache.thrift.protocol.TType.I64) {
7346
              this.toDate = iprot.readI64();
7347
              setToDateIsSet(true);
7348
            } else { 
7349
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7350
            }
7351
            break;
7352
          default:
7353
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1730 ankur.sing 7354
        }
3430 rajveer 7355
        iprot.readFieldEnd();
1730 ankur.sing 7356
      }
7357
      iprot.readStructEnd();
7358
      validate();
7359
    }
7360
 
3430 rajveer 7361
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1730 ankur.sing 7362
      validate();
7363
 
7364
      oprot.writeStructBegin(STRUCT_DESC);
7365
      oprot.writeFieldBegin(FROM_DATE_FIELD_DESC);
7366
      oprot.writeI64(this.fromDate);
7367
      oprot.writeFieldEnd();
7368
      oprot.writeFieldBegin(TO_DATE_FIELD_DESC);
7369
      oprot.writeI64(this.toDate);
7370
      oprot.writeFieldEnd();
7371
      oprot.writeFieldStop();
7372
      oprot.writeStructEnd();
7373
    }
7374
 
7375
    @Override
7376
    public String toString() {
7377
      StringBuilder sb = new StringBuilder("getHolidays_args(");
7378
      boolean first = true;
7379
 
7380
      sb.append("fromDate:");
7381
      sb.append(this.fromDate);
7382
      first = false;
7383
      if (!first) sb.append(", ");
7384
      sb.append("toDate:");
7385
      sb.append(this.toDate);
7386
      first = false;
7387
      sb.append(")");
7388
      return sb.toString();
7389
    }
7390
 
3430 rajveer 7391
    public void validate() throws org.apache.thrift.TException {
1730 ankur.sing 7392
      // check for required fields
7393
    }
7394
 
3430 rajveer 7395
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7396
      try {
7397
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7398
      } catch (org.apache.thrift.TException te) {
7399
        throw new java.io.IOException(te);
7400
      }
7401
    }
7402
 
7403
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7404
      try {
7405
        // it doesn't seem like you should have to do this, but java serialization is wacky, and doesn't call the default constructor.
7406
        __isset_bit_vector = new BitSet(1);
7407
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7408
      } catch (org.apache.thrift.TException te) {
7409
        throw new java.io.IOException(te);
7410
      }
7411
    }
7412
 
1730 ankur.sing 7413
  }
7414
 
3430 rajveer 7415
  public static class getHolidays_result implements org.apache.thrift.TBase<getHolidays_result, getHolidays_result._Fields>, java.io.Serializable, Cloneable   {
7416
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getHolidays_result");
1730 ankur.sing 7417
 
3430 rajveer 7418
    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);
1730 ankur.sing 7419
 
3430 rajveer 7420
    private List<Long> success; // required
1730 ankur.sing 7421
 
7422
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
3430 rajveer 7423
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1730 ankur.sing 7424
      SUCCESS((short)0, "success");
7425
 
7426
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7427
 
7428
      static {
7429
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7430
          byName.put(field.getFieldName(), field);
7431
        }
7432
      }
7433
 
7434
      /**
7435
       * Find the _Fields constant that matches fieldId, or null if its not found.
7436
       */
7437
      public static _Fields findByThriftId(int fieldId) {
3430 rajveer 7438
        switch(fieldId) {
7439
          case 0: // SUCCESS
7440
            return SUCCESS;
7441
          default:
7442
            return null;
7443
        }
1730 ankur.sing 7444
      }
7445
 
7446
      /**
7447
       * Find the _Fields constant that matches fieldId, throwing an exception
7448
       * if it is not found.
7449
       */
7450
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7451
        _Fields fields = findByThriftId(fieldId);
7452
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7453
        return fields;
7454
      }
7455
 
7456
      /**
7457
       * Find the _Fields constant that matches name, or null if its not found.
7458
       */
7459
      public static _Fields findByName(String name) {
7460
        return byName.get(name);
7461
      }
7462
 
7463
      private final short _thriftId;
7464
      private final String _fieldName;
7465
 
7466
      _Fields(short thriftId, String fieldName) {
7467
        _thriftId = thriftId;
7468
        _fieldName = fieldName;
7469
      }
7470
 
7471
      public short getThriftFieldId() {
7472
        return _thriftId;
7473
      }
7474
 
7475
      public String getFieldName() {
7476
        return _fieldName;
7477
      }
7478
    }
7479
 
7480
    // isset id assignments
7481
 
3430 rajveer 7482
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1730 ankur.sing 7483
    static {
3430 rajveer 7484
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7485
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7486
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
7487
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
7488
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7489
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getHolidays_result.class, metaDataMap);
1730 ankur.sing 7490
    }
7491
 
7492
    public getHolidays_result() {
7493
    }
7494
 
7495
    public getHolidays_result(
7496
      List<Long> success)
7497
    {
7498
      this();
7499
      this.success = success;
7500
    }
7501
 
7502
    /**
7503
     * Performs a deep copy on <i>other</i>.
7504
     */
7505
    public getHolidays_result(getHolidays_result other) {
7506
      if (other.isSetSuccess()) {
7507
        List<Long> __this__success = new ArrayList<Long>();
7508
        for (Long other_element : other.success) {
7509
          __this__success.add(other_element);
7510
        }
7511
        this.success = __this__success;
7512
      }
7513
    }
7514
 
7515
    public getHolidays_result deepCopy() {
7516
      return new getHolidays_result(this);
7517
    }
7518
 
3430 rajveer 7519
    @Override
7520
    public void clear() {
7521
      this.success = null;
1730 ankur.sing 7522
    }
7523
 
7524
    public int getSuccessSize() {
7525
      return (this.success == null) ? 0 : this.success.size();
7526
    }
7527
 
7528
    public java.util.Iterator<Long> getSuccessIterator() {
7529
      return (this.success == null) ? null : this.success.iterator();
7530
    }
7531
 
7532
    public void addToSuccess(long elem) {
7533
      if (this.success == null) {
7534
        this.success = new ArrayList<Long>();
7535
      }
7536
      this.success.add(elem);
7537
    }
7538
 
7539
    public List<Long> getSuccess() {
7540
      return this.success;
7541
    }
7542
 
3430 rajveer 7543
    public void setSuccess(List<Long> success) {
1730 ankur.sing 7544
      this.success = success;
7545
    }
7546
 
7547
    public void unsetSuccess() {
7548
      this.success = null;
7549
    }
7550
 
3430 rajveer 7551
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
1730 ankur.sing 7552
    public boolean isSetSuccess() {
7553
      return this.success != null;
7554
    }
7555
 
7556
    public void setSuccessIsSet(boolean value) {
7557
      if (!value) {
7558
        this.success = null;
7559
      }
7560
    }
7561
 
7562
    public void setFieldValue(_Fields field, Object value) {
7563
      switch (field) {
7564
      case SUCCESS:
7565
        if (value == null) {
7566
          unsetSuccess();
7567
        } else {
7568
          setSuccess((List<Long>)value);
7569
        }
7570
        break;
7571
 
7572
      }
7573
    }
7574
 
7575
    public Object getFieldValue(_Fields field) {
7576
      switch (field) {
7577
      case SUCCESS:
7578
        return getSuccess();
7579
 
7580
      }
7581
      throw new IllegalStateException();
7582
    }
7583
 
3430 rajveer 7584
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
7585
    public boolean isSet(_Fields field) {
7586
      if (field == null) {
7587
        throw new IllegalArgumentException();
7588
      }
1730 ankur.sing 7589
 
7590
      switch (field) {
7591
      case SUCCESS:
7592
        return isSetSuccess();
7593
      }
7594
      throw new IllegalStateException();
7595
    }
7596
 
7597
    @Override
7598
    public boolean equals(Object that) {
7599
      if (that == null)
7600
        return false;
7601
      if (that instanceof getHolidays_result)
7602
        return this.equals((getHolidays_result)that);
7603
      return false;
7604
    }
7605
 
7606
    public boolean equals(getHolidays_result that) {
7607
      if (that == null)
7608
        return false;
7609
 
7610
      boolean this_present_success = true && this.isSetSuccess();
7611
      boolean that_present_success = true && that.isSetSuccess();
7612
      if (this_present_success || that_present_success) {
7613
        if (!(this_present_success && that_present_success))
7614
          return false;
7615
        if (!this.success.equals(that.success))
7616
          return false;
7617
      }
7618
 
7619
      return true;
7620
    }
7621
 
7622
    @Override
7623
    public int hashCode() {
7624
      return 0;
7625
    }
7626
 
7627
    public int compareTo(getHolidays_result other) {
7628
      if (!getClass().equals(other.getClass())) {
7629
        return getClass().getName().compareTo(other.getClass().getName());
7630
      }
7631
 
7632
      int lastComparison = 0;
7633
      getHolidays_result typedOther = (getHolidays_result)other;
7634
 
3430 rajveer 7635
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
1730 ankur.sing 7636
      if (lastComparison != 0) {
7637
        return lastComparison;
7638
      }
3430 rajveer 7639
      if (isSetSuccess()) {
7640
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
7641
        if (lastComparison != 0) {
7642
          return lastComparison;
7643
        }
1730 ankur.sing 7644
      }
7645
      return 0;
7646
    }
7647
 
3430 rajveer 7648
    public _Fields fieldForId(int fieldId) {
7649
      return _Fields.findByThriftId(fieldId);
7650
    }
7651
 
7652
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
7653
      org.apache.thrift.protocol.TField field;
1730 ankur.sing 7654
      iprot.readStructBegin();
7655
      while (true)
7656
      {
7657
        field = iprot.readFieldBegin();
3430 rajveer 7658
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
1730 ankur.sing 7659
          break;
7660
        }
3430 rajveer 7661
        switch (field.id) {
7662
          case 0: // SUCCESS
7663
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
7664
              {
7665
                org.apache.thrift.protocol.TList _list13 = iprot.readListBegin();
7666
                this.success = new ArrayList<Long>(_list13.size);
7667
                for (int _i14 = 0; _i14 < _list13.size; ++_i14)
1730 ankur.sing 7668
                {
3430 rajveer 7669
                  long _elem15; // required
7670
                  _elem15 = iprot.readI64();
7671
                  this.success.add(_elem15);
1730 ankur.sing 7672
                }
3430 rajveer 7673
                iprot.readListEnd();
1730 ankur.sing 7674
              }
3430 rajveer 7675
            } else { 
7676
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
7677
            }
7678
            break;
7679
          default:
7680
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
1730 ankur.sing 7681
        }
3430 rajveer 7682
        iprot.readFieldEnd();
1730 ankur.sing 7683
      }
7684
      iprot.readStructEnd();
7685
      validate();
7686
    }
7687
 
3430 rajveer 7688
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1730 ankur.sing 7689
      oprot.writeStructBegin(STRUCT_DESC);
7690
 
7691
      if (this.isSetSuccess()) {
7692
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
7693
        {
3430 rajveer 7694
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
3044 chandransh 7695
          for (long _iter16 : this.success)
1730 ankur.sing 7696
          {
3044 chandransh 7697
            oprot.writeI64(_iter16);
1730 ankur.sing 7698
          }
7699
          oprot.writeListEnd();
7700
        }
7701
        oprot.writeFieldEnd();
7702
      }
7703
      oprot.writeFieldStop();
7704
      oprot.writeStructEnd();
7705
    }
7706
 
7707
    @Override
7708
    public String toString() {
7709
      StringBuilder sb = new StringBuilder("getHolidays_result(");
7710
      boolean first = true;
7711
 
7712
      sb.append("success:");
7713
      if (this.success == null) {
7714
        sb.append("null");
7715
      } else {
7716
        sb.append(this.success);
7717
      }
7718
      first = false;
7719
      sb.append(")");
7720
      return sb.toString();
7721
    }
7722
 
3430 rajveer 7723
    public void validate() throws org.apache.thrift.TException {
1730 ankur.sing 7724
      // check for required fields
7725
    }
7726
 
3430 rajveer 7727
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
7728
      try {
7729
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
7730
      } catch (org.apache.thrift.TException te) {
7731
        throw new java.io.IOException(te);
7732
      }
7733
    }
7734
 
7735
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
7736
      try {
7737
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
7738
      } catch (org.apache.thrift.TException te) {
7739
        throw new java.io.IOException(te);
7740
      }
7741
    }
7742
 
1730 ankur.sing 7743
  }
7744
 
4934 amit.gupta 7745
  public static class getEntityLogisticsEstimation_args implements org.apache.thrift.TBase<getEntityLogisticsEstimation_args, getEntityLogisticsEstimation_args._Fields>, java.io.Serializable, Cloneable   {
7746
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getEntityLogisticsEstimation_args");
7747
 
7748
    private static final org.apache.thrift.protocol.TField CATALOG_ITEM_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("catalogItemId", org.apache.thrift.protocol.TType.I64, (short)1);
7749
    private static final org.apache.thrift.protocol.TField DESTINATION_PIN_FIELD_DESC = new org.apache.thrift.protocol.TField("destination_pin", org.apache.thrift.protocol.TType.STRING, (short)2);
7750
    private static final org.apache.thrift.protocol.TField TYPE_FIELD_DESC = new org.apache.thrift.protocol.TField("type", org.apache.thrift.protocol.TType.I32, (short)3);
7751
 
7752
    private long catalogItemId; // required
7753
    private String destination_pin; // required
7754
    private DeliveryType type; // required
7755
 
7756
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
7757
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
7758
      CATALOG_ITEM_ID((short)1, "catalogItemId"),
7759
      DESTINATION_PIN((short)2, "destination_pin"),
7760
      /**
7761
       * 
7762
       * @see DeliveryType
7763
       */
7764
      TYPE((short)3, "type");
7765
 
7766
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
7767
 
7768
      static {
7769
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
7770
          byName.put(field.getFieldName(), field);
7771
        }
7772
      }
7773
 
7774
      /**
7775
       * Find the _Fields constant that matches fieldId, or null if its not found.
7776
       */
7777
      public static _Fields findByThriftId(int fieldId) {
7778
        switch(fieldId) {
7779
          case 1: // CATALOG_ITEM_ID
7780
            return CATALOG_ITEM_ID;
7781
          case 2: // DESTINATION_PIN
7782
            return DESTINATION_PIN;
7783
          case 3: // TYPE
7784
            return TYPE;
7785
          default:
7786
            return null;
7787
        }
7788
      }
7789
 
7790
      /**
7791
       * Find the _Fields constant that matches fieldId, throwing an exception
7792
       * if it is not found.
7793
       */
7794
      public static _Fields findByThriftIdOrThrow(int fieldId) {
7795
        _Fields fields = findByThriftId(fieldId);
7796
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
7797
        return fields;
7798
      }
7799
 
7800
      /**
7801
       * Find the _Fields constant that matches name, or null if its not found.
7802
       */
7803
      public static _Fields findByName(String name) {
7804
        return byName.get(name);
7805
      }
7806
 
7807
      private final short _thriftId;
7808
      private final String _fieldName;
7809
 
7810
      _Fields(short thriftId, String fieldName) {
7811
        _thriftId = thriftId;
7812
        _fieldName = fieldName;
7813
      }
7814
 
7815
      public short getThriftFieldId() {
7816
        return _thriftId;
7817
      }
7818
 
7819
      public String getFieldName() {
7820
        return _fieldName;
7821
      }
7822
    }
7823
 
7824
    // isset id assignments
7825
    private static final int __CATALOGITEMID_ISSET_ID = 0;
7826
    private BitSet __isset_bit_vector = new BitSet(1);
7827
 
7828
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
7829
    static {
7830
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
7831
      tmpMap.put(_Fields.CATALOG_ITEM_ID, new org.apache.thrift.meta_data.FieldMetaData("catalogItemId", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7832
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64)));
7833
      tmpMap.put(_Fields.DESTINATION_PIN, new org.apache.thrift.meta_data.FieldMetaData("destination_pin", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7834
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRING)));
7835
      tmpMap.put(_Fields.TYPE, new org.apache.thrift.meta_data.FieldMetaData("type", org.apache.thrift.TFieldRequirementType.DEFAULT, 
7836
          new org.apache.thrift.meta_data.EnumMetaData(org.apache.thrift.protocol.TType.ENUM, DeliveryType.class)));
7837
      metaDataMap = Collections.unmodifiableMap(tmpMap);
7838
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getEntityLogisticsEstimation_args.class, metaDataMap);
7839
    }
7840
 
7841
    public getEntityLogisticsEstimation_args() {
7842
    }
7843
 
7844
    public getEntityLogisticsEstimation_args(
7845
      long catalogItemId,
7846
      String destination_pin,
7847
      DeliveryType type)
7848
    {
7849
      this();
7850
      this.catalogItemId = catalogItemId;
7851
      setCatalogItemIdIsSet(true);
7852
      this.destination_pin = destination_pin;
7853
      this.type = type;
7854
    }
7855
 
7856
    /**
7857
     * Performs a deep copy on <i>other</i>.
7858
     */
7859
    public getEntityLogisticsEstimation_args(getEntityLogisticsEstimation_args other) {
7860
      __isset_bit_vector.clear();
7861
      __isset_bit_vector.or(other.__isset_bit_vector);
7862
      this.catalogItemId = other.catalogItemId;
7863
      if (other.isSetDestination_pin()) {
7864
        this.destination_pin = other.destination_pin;
7865
      }
7866
      if (other.isSetType()) {
7867
        this.type = other.type;
7868
      }
7869
    }
7870
 
7871
    public getEntityLogisticsEstimation_args deepCopy() {
7872
      return new getEntityLogisticsEstimation_args(this);
7873
    }
7874
 
7875
    @Override
7876
    public void clear() {
7877
      setCatalogItemIdIsSet(false);
7878
      this.catalogItemId = 0;
7879
      this.destination_pin = null;
7880
      this.type = null;
7881
    }
7882
 
7883
    public long getCatalogItemId() {
7884
      return this.catalogItemId;
7885
    }
7886
 
7887
    public void setCatalogItemId(long catalogItemId) {
7888
      this.catalogItemId = catalogItemId;
7889
      setCatalogItemIdIsSet(true);
7890
    }
7891
 
7892
    public void unsetCatalogItemId() {
7893
      __isset_bit_vector.clear(__CATALOGITEMID_ISSET_ID);
7894
    }
7895
 
7896
    /** Returns true if field catalogItemId is set (has been assigned a value) and false otherwise */
7897
    public boolean isSetCatalogItemId() {
7898
      return __isset_bit_vector.get(__CATALOGITEMID_ISSET_ID);
7899
    }
7900
 
7901
    public void setCatalogItemIdIsSet(boolean value) {
7902
      __isset_bit_vector.set(__CATALOGITEMID_ISSET_ID, value);
7903
    }
7904
 
7905
    public String getDestination_pin() {
7906
      return this.destination_pin;
7907
    }
7908
 
7909
    public void setDestination_pin(String destination_pin) {
7910
      this.destination_pin = destination_pin;
7911
    }
7912
 
7913
    public void unsetDestination_pin() {
7914
      this.destination_pin = null;
7915
    }
7916
 
7917
    /** Returns true if field destination_pin is set (has been assigned a value) and false otherwise */
7918
    public boolean isSetDestination_pin() {
7919
      return this.destination_pin != null;
7920
    }
7921
 
7922
    public void setDestination_pinIsSet(boolean value) {
7923
      if (!value) {
7924
        this.destination_pin = null;
7925
      }
7926
    }
7927
 
7928
    /**
7929
     * 
7930
     * @see DeliveryType
7931
     */
7932
    public DeliveryType getType() {
7933
      return this.type;
7934
    }
7935
 
7936
    /**
7937
     * 
7938
     * @see DeliveryType
7939
     */
7940
    public void setType(DeliveryType type) {
7941
      this.type = type;
7942
    }
7943
 
7944
    public void unsetType() {
7945
      this.type = null;
7946
    }
7947
 
7948
    /** Returns true if field type is set (has been assigned a value) and false otherwise */
7949
    public boolean isSetType() {
7950
      return this.type != null;
7951
    }
7952
 
7953
    public void setTypeIsSet(boolean value) {
7954
      if (!value) {
7955
        this.type = null;
7956
      }
7957
    }
7958
 
7959
    public void setFieldValue(_Fields field, Object value) {
7960
      switch (field) {
7961
      case CATALOG_ITEM_ID:
7962
        if (value == null) {
7963
          unsetCatalogItemId();
7964
        } else {
7965
          setCatalogItemId((Long)value);
7966
        }
7967
        break;
7968
 
7969
      case DESTINATION_PIN:
7970
        if (value == null) {
7971
          unsetDestination_pin();
7972
        } else {
7973
          setDestination_pin((String)value);
7974
        }
7975
        break;
7976
 
7977
      case TYPE:
7978
        if (value == null) {
7979
          unsetType();
7980
        } else {
7981
          setType((DeliveryType)value);
7982
        }
7983
        break;
7984
 
7985
      }
7986
    }
7987
 
7988
    public Object getFieldValue(_Fields field) {
7989
      switch (field) {
7990
      case CATALOG_ITEM_ID:
7991
        return Long.valueOf(getCatalogItemId());
7992
 
7993
      case DESTINATION_PIN:
7994
        return getDestination_pin();
7995
 
7996
      case TYPE:
7997
        return getType();
7998
 
7999
      }
8000
      throw new IllegalStateException();
8001
    }
8002
 
8003
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8004
    public boolean isSet(_Fields field) {
8005
      if (field == null) {
8006
        throw new IllegalArgumentException();
8007
      }
8008
 
8009
      switch (field) {
8010
      case CATALOG_ITEM_ID:
8011
        return isSetCatalogItemId();
8012
      case DESTINATION_PIN:
8013
        return isSetDestination_pin();
8014
      case TYPE:
8015
        return isSetType();
8016
      }
8017
      throw new IllegalStateException();
8018
    }
8019
 
8020
    @Override
8021
    public boolean equals(Object that) {
8022
      if (that == null)
8023
        return false;
8024
      if (that instanceof getEntityLogisticsEstimation_args)
8025
        return this.equals((getEntityLogisticsEstimation_args)that);
8026
      return false;
8027
    }
8028
 
8029
    public boolean equals(getEntityLogisticsEstimation_args that) {
8030
      if (that == null)
8031
        return false;
8032
 
8033
      boolean this_present_catalogItemId = true;
8034
      boolean that_present_catalogItemId = true;
8035
      if (this_present_catalogItemId || that_present_catalogItemId) {
8036
        if (!(this_present_catalogItemId && that_present_catalogItemId))
8037
          return false;
8038
        if (this.catalogItemId != that.catalogItemId)
8039
          return false;
8040
      }
8041
 
8042
      boolean this_present_destination_pin = true && this.isSetDestination_pin();
8043
      boolean that_present_destination_pin = true && that.isSetDestination_pin();
8044
      if (this_present_destination_pin || that_present_destination_pin) {
8045
        if (!(this_present_destination_pin && that_present_destination_pin))
8046
          return false;
8047
        if (!this.destination_pin.equals(that.destination_pin))
8048
          return false;
8049
      }
8050
 
8051
      boolean this_present_type = true && this.isSetType();
8052
      boolean that_present_type = true && that.isSetType();
8053
      if (this_present_type || that_present_type) {
8054
        if (!(this_present_type && that_present_type))
8055
          return false;
8056
        if (!this.type.equals(that.type))
8057
          return false;
8058
      }
8059
 
8060
      return true;
8061
    }
8062
 
8063
    @Override
8064
    public int hashCode() {
8065
      return 0;
8066
    }
8067
 
8068
    public int compareTo(getEntityLogisticsEstimation_args other) {
8069
      if (!getClass().equals(other.getClass())) {
8070
        return getClass().getName().compareTo(other.getClass().getName());
8071
      }
8072
 
8073
      int lastComparison = 0;
8074
      getEntityLogisticsEstimation_args typedOther = (getEntityLogisticsEstimation_args)other;
8075
 
8076
      lastComparison = Boolean.valueOf(isSetCatalogItemId()).compareTo(typedOther.isSetCatalogItemId());
8077
      if (lastComparison != 0) {
8078
        return lastComparison;
8079
      }
8080
      if (isSetCatalogItemId()) {
8081
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.catalogItemId, typedOther.catalogItemId);
8082
        if (lastComparison != 0) {
8083
          return lastComparison;
8084
        }
8085
      }
8086
      lastComparison = Boolean.valueOf(isSetDestination_pin()).compareTo(typedOther.isSetDestination_pin());
8087
      if (lastComparison != 0) {
8088
        return lastComparison;
8089
      }
8090
      if (isSetDestination_pin()) {
8091
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.destination_pin, typedOther.destination_pin);
8092
        if (lastComparison != 0) {
8093
          return lastComparison;
8094
        }
8095
      }
8096
      lastComparison = Boolean.valueOf(isSetType()).compareTo(typedOther.isSetType());
8097
      if (lastComparison != 0) {
8098
        return lastComparison;
8099
      }
8100
      if (isSetType()) {
8101
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.type, typedOther.type);
8102
        if (lastComparison != 0) {
8103
          return lastComparison;
8104
        }
8105
      }
8106
      return 0;
8107
    }
8108
 
8109
    public _Fields fieldForId(int fieldId) {
8110
      return _Fields.findByThriftId(fieldId);
8111
    }
8112
 
8113
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8114
      org.apache.thrift.protocol.TField field;
8115
      iprot.readStructBegin();
8116
      while (true)
8117
      {
8118
        field = iprot.readFieldBegin();
8119
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8120
          break;
8121
        }
8122
        switch (field.id) {
8123
          case 1: // CATALOG_ITEM_ID
8124
            if (field.type == org.apache.thrift.protocol.TType.I64) {
8125
              this.catalogItemId = iprot.readI64();
8126
              setCatalogItemIdIsSet(true);
8127
            } else { 
8128
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8129
            }
8130
            break;
8131
          case 2: // DESTINATION_PIN
8132
            if (field.type == org.apache.thrift.protocol.TType.STRING) {
8133
              this.destination_pin = iprot.readString();
8134
            } else { 
8135
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8136
            }
8137
            break;
8138
          case 3: // TYPE
8139
            if (field.type == org.apache.thrift.protocol.TType.I32) {
8140
              this.type = DeliveryType.findByValue(iprot.readI32());
8141
            } else { 
8142
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8143
            }
8144
            break;
8145
          default:
8146
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8147
        }
8148
        iprot.readFieldEnd();
8149
      }
8150
      iprot.readStructEnd();
8151
      validate();
8152
    }
8153
 
8154
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8155
      validate();
8156
 
8157
      oprot.writeStructBegin(STRUCT_DESC);
8158
      oprot.writeFieldBegin(CATALOG_ITEM_ID_FIELD_DESC);
8159
      oprot.writeI64(this.catalogItemId);
8160
      oprot.writeFieldEnd();
8161
      if (this.destination_pin != null) {
8162
        oprot.writeFieldBegin(DESTINATION_PIN_FIELD_DESC);
8163
        oprot.writeString(this.destination_pin);
8164
        oprot.writeFieldEnd();
8165
      }
8166
      if (this.type != null) {
8167
        oprot.writeFieldBegin(TYPE_FIELD_DESC);
8168
        oprot.writeI32(this.type.getValue());
8169
        oprot.writeFieldEnd();
8170
      }
8171
      oprot.writeFieldStop();
8172
      oprot.writeStructEnd();
8173
    }
8174
 
8175
    @Override
8176
    public String toString() {
8177
      StringBuilder sb = new StringBuilder("getEntityLogisticsEstimation_args(");
8178
      boolean first = true;
8179
 
8180
      sb.append("catalogItemId:");
8181
      sb.append(this.catalogItemId);
8182
      first = false;
8183
      if (!first) sb.append(", ");
8184
      sb.append("destination_pin:");
8185
      if (this.destination_pin == null) {
8186
        sb.append("null");
8187
      } else {
8188
        sb.append(this.destination_pin);
8189
      }
8190
      first = false;
8191
      if (!first) sb.append(", ");
8192
      sb.append("type:");
8193
      if (this.type == null) {
8194
        sb.append("null");
8195
      } else {
8196
        sb.append(this.type);
8197
      }
8198
      first = false;
8199
      sb.append(")");
8200
      return sb.toString();
8201
    }
8202
 
8203
    public void validate() throws org.apache.thrift.TException {
8204
      // check for required fields
8205
    }
8206
 
8207
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8208
      try {
8209
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8210
      } catch (org.apache.thrift.TException te) {
8211
        throw new java.io.IOException(te);
8212
      }
8213
    }
8214
 
8215
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8216
      try {
8217
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8218
      } catch (org.apache.thrift.TException te) {
8219
        throw new java.io.IOException(te);
8220
      }
8221
    }
8222
 
8223
  }
8224
 
8225
  public static class getEntityLogisticsEstimation_result implements org.apache.thrift.TBase<getEntityLogisticsEstimation_result, getEntityLogisticsEstimation_result._Fields>, java.io.Serializable, Cloneable   {
8226
    private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("getEntityLogisticsEstimation_result");
8227
 
8228
    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);
8229
    private static final org.apache.thrift.protocol.TField SE_FIELD_DESC = new org.apache.thrift.protocol.TField("se", org.apache.thrift.protocol.TType.STRUCT, (short)1);
8230
 
8231
    private List<Long> success; // required
8232
    private LogisticsServiceException se; // required
8233
 
8234
    /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
8235
    public enum _Fields implements org.apache.thrift.TFieldIdEnum {
8236
      SUCCESS((short)0, "success"),
8237
      SE((short)1, "se");
8238
 
8239
      private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
8240
 
8241
      static {
8242
        for (_Fields field : EnumSet.allOf(_Fields.class)) {
8243
          byName.put(field.getFieldName(), field);
8244
        }
8245
      }
8246
 
8247
      /**
8248
       * Find the _Fields constant that matches fieldId, or null if its not found.
8249
       */
8250
      public static _Fields findByThriftId(int fieldId) {
8251
        switch(fieldId) {
8252
          case 0: // SUCCESS
8253
            return SUCCESS;
8254
          case 1: // SE
8255
            return SE;
8256
          default:
8257
            return null;
8258
        }
8259
      }
8260
 
8261
      /**
8262
       * Find the _Fields constant that matches fieldId, throwing an exception
8263
       * if it is not found.
8264
       */
8265
      public static _Fields findByThriftIdOrThrow(int fieldId) {
8266
        _Fields fields = findByThriftId(fieldId);
8267
        if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
8268
        return fields;
8269
      }
8270
 
8271
      /**
8272
       * Find the _Fields constant that matches name, or null if its not found.
8273
       */
8274
      public static _Fields findByName(String name) {
8275
        return byName.get(name);
8276
      }
8277
 
8278
      private final short _thriftId;
8279
      private final String _fieldName;
8280
 
8281
      _Fields(short thriftId, String fieldName) {
8282
        _thriftId = thriftId;
8283
        _fieldName = fieldName;
8284
      }
8285
 
8286
      public short getThriftFieldId() {
8287
        return _thriftId;
8288
      }
8289
 
8290
      public String getFieldName() {
8291
        return _fieldName;
8292
      }
8293
    }
8294
 
8295
    // isset id assignments
8296
 
8297
    public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
8298
    static {
8299
      Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
8300
      tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8301
          new org.apache.thrift.meta_data.ListMetaData(org.apache.thrift.protocol.TType.LIST, 
8302
              new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.I64))));
8303
      tmpMap.put(_Fields.SE, new org.apache.thrift.meta_data.FieldMetaData("se", org.apache.thrift.TFieldRequirementType.DEFAULT, 
8304
          new org.apache.thrift.meta_data.FieldValueMetaData(org.apache.thrift.protocol.TType.STRUCT)));
8305
      metaDataMap = Collections.unmodifiableMap(tmpMap);
8306
      org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(getEntityLogisticsEstimation_result.class, metaDataMap);
8307
    }
8308
 
8309
    public getEntityLogisticsEstimation_result() {
8310
    }
8311
 
8312
    public getEntityLogisticsEstimation_result(
8313
      List<Long> success,
8314
      LogisticsServiceException se)
8315
    {
8316
      this();
8317
      this.success = success;
8318
      this.se = se;
8319
    }
8320
 
8321
    /**
8322
     * Performs a deep copy on <i>other</i>.
8323
     */
8324
    public getEntityLogisticsEstimation_result(getEntityLogisticsEstimation_result other) {
8325
      if (other.isSetSuccess()) {
8326
        List<Long> __this__success = new ArrayList<Long>();
8327
        for (Long other_element : other.success) {
8328
          __this__success.add(other_element);
8329
        }
8330
        this.success = __this__success;
8331
      }
8332
      if (other.isSetSe()) {
8333
        this.se = new LogisticsServiceException(other.se);
8334
      }
8335
    }
8336
 
8337
    public getEntityLogisticsEstimation_result deepCopy() {
8338
      return new getEntityLogisticsEstimation_result(this);
8339
    }
8340
 
8341
    @Override
8342
    public void clear() {
8343
      this.success = null;
8344
      this.se = null;
8345
    }
8346
 
8347
    public int getSuccessSize() {
8348
      return (this.success == null) ? 0 : this.success.size();
8349
    }
8350
 
8351
    public java.util.Iterator<Long> getSuccessIterator() {
8352
      return (this.success == null) ? null : this.success.iterator();
8353
    }
8354
 
8355
    public void addToSuccess(long elem) {
8356
      if (this.success == null) {
8357
        this.success = new ArrayList<Long>();
8358
      }
8359
      this.success.add(elem);
8360
    }
8361
 
8362
    public List<Long> getSuccess() {
8363
      return this.success;
8364
    }
8365
 
8366
    public void setSuccess(List<Long> success) {
8367
      this.success = success;
8368
    }
8369
 
8370
    public void unsetSuccess() {
8371
      this.success = null;
8372
    }
8373
 
8374
    /** Returns true if field success is set (has been assigned a value) and false otherwise */
8375
    public boolean isSetSuccess() {
8376
      return this.success != null;
8377
    }
8378
 
8379
    public void setSuccessIsSet(boolean value) {
8380
      if (!value) {
8381
        this.success = null;
8382
      }
8383
    }
8384
 
8385
    public LogisticsServiceException getSe() {
8386
      return this.se;
8387
    }
8388
 
8389
    public void setSe(LogisticsServiceException se) {
8390
      this.se = se;
8391
    }
8392
 
8393
    public void unsetSe() {
8394
      this.se = null;
8395
    }
8396
 
8397
    /** Returns true if field se is set (has been assigned a value) and false otherwise */
8398
    public boolean isSetSe() {
8399
      return this.se != null;
8400
    }
8401
 
8402
    public void setSeIsSet(boolean value) {
8403
      if (!value) {
8404
        this.se = null;
8405
      }
8406
    }
8407
 
8408
    public void setFieldValue(_Fields field, Object value) {
8409
      switch (field) {
8410
      case SUCCESS:
8411
        if (value == null) {
8412
          unsetSuccess();
8413
        } else {
8414
          setSuccess((List<Long>)value);
8415
        }
8416
        break;
8417
 
8418
      case SE:
8419
        if (value == null) {
8420
          unsetSe();
8421
        } else {
8422
          setSe((LogisticsServiceException)value);
8423
        }
8424
        break;
8425
 
8426
      }
8427
    }
8428
 
8429
    public Object getFieldValue(_Fields field) {
8430
      switch (field) {
8431
      case SUCCESS:
8432
        return getSuccess();
8433
 
8434
      case SE:
8435
        return getSe();
8436
 
8437
      }
8438
      throw new IllegalStateException();
8439
    }
8440
 
8441
    /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
8442
    public boolean isSet(_Fields field) {
8443
      if (field == null) {
8444
        throw new IllegalArgumentException();
8445
      }
8446
 
8447
      switch (field) {
8448
      case SUCCESS:
8449
        return isSetSuccess();
8450
      case SE:
8451
        return isSetSe();
8452
      }
8453
      throw new IllegalStateException();
8454
    }
8455
 
8456
    @Override
8457
    public boolean equals(Object that) {
8458
      if (that == null)
8459
        return false;
8460
      if (that instanceof getEntityLogisticsEstimation_result)
8461
        return this.equals((getEntityLogisticsEstimation_result)that);
8462
      return false;
8463
    }
8464
 
8465
    public boolean equals(getEntityLogisticsEstimation_result that) {
8466
      if (that == null)
8467
        return false;
8468
 
8469
      boolean this_present_success = true && this.isSetSuccess();
8470
      boolean that_present_success = true && that.isSetSuccess();
8471
      if (this_present_success || that_present_success) {
8472
        if (!(this_present_success && that_present_success))
8473
          return false;
8474
        if (!this.success.equals(that.success))
8475
          return false;
8476
      }
8477
 
8478
      boolean this_present_se = true && this.isSetSe();
8479
      boolean that_present_se = true && that.isSetSe();
8480
      if (this_present_se || that_present_se) {
8481
        if (!(this_present_se && that_present_se))
8482
          return false;
8483
        if (!this.se.equals(that.se))
8484
          return false;
8485
      }
8486
 
8487
      return true;
8488
    }
8489
 
8490
    @Override
8491
    public int hashCode() {
8492
      return 0;
8493
    }
8494
 
8495
    public int compareTo(getEntityLogisticsEstimation_result other) {
8496
      if (!getClass().equals(other.getClass())) {
8497
        return getClass().getName().compareTo(other.getClass().getName());
8498
      }
8499
 
8500
      int lastComparison = 0;
8501
      getEntityLogisticsEstimation_result typedOther = (getEntityLogisticsEstimation_result)other;
8502
 
8503
      lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(typedOther.isSetSuccess());
8504
      if (lastComparison != 0) {
8505
        return lastComparison;
8506
      }
8507
      if (isSetSuccess()) {
8508
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, typedOther.success);
8509
        if (lastComparison != 0) {
8510
          return lastComparison;
8511
        }
8512
      }
8513
      lastComparison = Boolean.valueOf(isSetSe()).compareTo(typedOther.isSetSe());
8514
      if (lastComparison != 0) {
8515
        return lastComparison;
8516
      }
8517
      if (isSetSe()) {
8518
        lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.se, typedOther.se);
8519
        if (lastComparison != 0) {
8520
          return lastComparison;
8521
        }
8522
      }
8523
      return 0;
8524
    }
8525
 
8526
    public _Fields fieldForId(int fieldId) {
8527
      return _Fields.findByThriftId(fieldId);
8528
    }
8529
 
8530
    public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
8531
      org.apache.thrift.protocol.TField field;
8532
      iprot.readStructBegin();
8533
      while (true)
8534
      {
8535
        field = iprot.readFieldBegin();
8536
        if (field.type == org.apache.thrift.protocol.TType.STOP) { 
8537
          break;
8538
        }
8539
        switch (field.id) {
8540
          case 0: // SUCCESS
8541
            if (field.type == org.apache.thrift.protocol.TType.LIST) {
8542
              {
8543
                org.apache.thrift.protocol.TList _list17 = iprot.readListBegin();
8544
                this.success = new ArrayList<Long>(_list17.size);
8545
                for (int _i18 = 0; _i18 < _list17.size; ++_i18)
8546
                {
8547
                  long _elem19; // required
8548
                  _elem19 = iprot.readI64();
8549
                  this.success.add(_elem19);
8550
                }
8551
                iprot.readListEnd();
8552
              }
8553
            } else { 
8554
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8555
            }
8556
            break;
8557
          case 1: // SE
8558
            if (field.type == org.apache.thrift.protocol.TType.STRUCT) {
8559
              this.se = new LogisticsServiceException();
8560
              this.se.read(iprot);
8561
            } else { 
8562
              org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8563
            }
8564
            break;
8565
          default:
8566
            org.apache.thrift.protocol.TProtocolUtil.skip(iprot, field.type);
8567
        }
8568
        iprot.readFieldEnd();
8569
      }
8570
      iprot.readStructEnd();
8571
      validate();
8572
    }
8573
 
8574
    public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
8575
      oprot.writeStructBegin(STRUCT_DESC);
8576
 
8577
      if (this.isSetSuccess()) {
8578
        oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
8579
        {
8580
          oprot.writeListBegin(new org.apache.thrift.protocol.TList(org.apache.thrift.protocol.TType.I64, this.success.size()));
8581
          for (long _iter20 : this.success)
8582
          {
8583
            oprot.writeI64(_iter20);
8584
          }
8585
          oprot.writeListEnd();
8586
        }
8587
        oprot.writeFieldEnd();
8588
      } else if (this.isSetSe()) {
8589
        oprot.writeFieldBegin(SE_FIELD_DESC);
8590
        this.se.write(oprot);
8591
        oprot.writeFieldEnd();
8592
      }
8593
      oprot.writeFieldStop();
8594
      oprot.writeStructEnd();
8595
    }
8596
 
8597
    @Override
8598
    public String toString() {
8599
      StringBuilder sb = new StringBuilder("getEntityLogisticsEstimation_result(");
8600
      boolean first = true;
8601
 
8602
      sb.append("success:");
8603
      if (this.success == null) {
8604
        sb.append("null");
8605
      } else {
8606
        sb.append(this.success);
8607
      }
8608
      first = false;
8609
      if (!first) sb.append(", ");
8610
      sb.append("se:");
8611
      if (this.se == null) {
8612
        sb.append("null");
8613
      } else {
8614
        sb.append(this.se);
8615
      }
8616
      first = false;
8617
      sb.append(")");
8618
      return sb.toString();
8619
    }
8620
 
8621
    public void validate() throws org.apache.thrift.TException {
8622
      // check for required fields
8623
    }
8624
 
8625
    private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
8626
      try {
8627
        write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
8628
      } catch (org.apache.thrift.TException te) {
8629
        throw new java.io.IOException(te);
8630
      }
8631
    }
8632
 
8633
    private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
8634
      try {
8635
        read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
8636
      } catch (org.apache.thrift.TException te) {
8637
        throw new java.io.IOException(te);
8638
      }
8639
    }
8640
 
8641
  }
8642
 
412 ashish 8643
}