Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
412 ashish 1
#
3431 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
 
7
from thrift.Thrift import *
3376 rajveer 8
import shop2020.thriftpy.generic.GenericService
412 ashish 9
from ttypes import *
10
from thrift.Thrift import TProcessor
11
from thrift.transport import TTransport
3431 rajveer 12
from thrift.protocol import TBinaryProtocol, TProtocol
412 ashish 13
try:
14
  from thrift.protocol import fastbinary
15
except:
16
  fastbinary = None
17
 
18
 
3376 rajveer 19
class Iface(shop2020.thriftpy.generic.GenericService.Iface):
669 chandransh 20
  def getProvider(self, providerId):
21
    """
22
    Returns a provider for a given provider ID. Throws an exception if none found.
3431 rajveer 23
 
669 chandransh 24
    Parameters:
25
     - providerId
26
    """
27
    pass
28
 
675 chandransh 29
  def getAllProviders(self, ):
30
    """
31
    Returns a list containing all the providers.
32
    """
33
    pass
34
 
4630 mandeep.dh 35
  def getLogisticsEstimation(self, itemId, destination_pin, type):
483 rajveer 36
    """
647 chandransh 37
    Returns a LogisticsInfo structure w/o an airway bill number. Use this method during the estimation phase.
38
    Raises an exception if this pincode is not allocated to any warehouse zone or provider. Also, if the pincode
39
    is allocated to a warehouse zone but there are no actual warehouses in that zone, an exception is raised.
3431 rajveer 40
 
483 rajveer 41
    Parameters:
647 chandransh 42
     - itemId
43
     - destination_pin
4630 mandeep.dh 44
     - type
483 rajveer 45
    """
46
    pass
47
 
3044 chandransh 48
  def getLogisticsInfo(self, destination_pincode, item_id, type):
472 rajveer 49
    """
647 chandransh 50
    Same as above excpet that an airway bill number is also allocated and returned.
3431 rajveer 51
 
472 rajveer 52
    Parameters:
647 chandransh 53
     - destination_pincode
54
     - item_id
3044 chandransh 55
     - type
472 rajveer 56
    """
57
    pass
58
 
647 chandransh 59
  def getEmptyAWB(self, providerId):
412 ashish 60
    """
647 chandransh 61
    Returns an unused AWB number for the given provider.
3431 rajveer 62
 
412 ashish 63
    Parameters:
647 chandransh 64
     - providerId
412 ashish 65
    """
66
    pass
67
 
647 chandransh 68
  def getShipmentInfo(self, awb, providerId):
412 ashish 69
    """
647 chandransh 70
    Returns the list of updates for the given AWB number and provider id. The list is empty if there are no updates yet.
3431 rajveer 71
 
412 ashish 72
    Parameters:
73
     - awb
647 chandransh 74
     - providerId
412 ashish 75
    """
76
    pass
77
 
732 chandransh 78
  def getDestinationCode(self, providerId, pinCode):
79
    """
80
    Returns the short three letter code of a pincode for the given provider.
81
       Raises an exception if the pin code is not serviced by the given provider.
3431 rajveer 82
 
732 chandransh 83
    Parameters:
84
     - providerId
85
     - pinCode
86
    """
87
    pass
412 ashish 88
 
3103 chandransh 89
  def getFreeAwbCount(self, providerId, type):
1137 chandransh 90
    """
3103 chandransh 91
    Returns the number of unused AWB numbers for the given provider of the given type
3431 rajveer 92
 
1137 chandransh 93
    Parameters:
94
     - providerId
3103 chandransh 95
     - type
1137 chandransh 96
    """
97
    pass
732 chandransh 98
 
1730 ankur.sing 99
  def getHolidays(self, fromDate, toDate):
100
    """
101
    Returns list of Holiday dates between fromDate and toDate (both inclusive)
102
    fromDate should be passed as milliseconds corresponding to the start of the day.
103
    If fromDate is passed as -1, fromDate is not considered for filtering
104
    If toDate is passed as -1, toDate is not considered for filtering
3431 rajveer 105
 
1730 ankur.sing 106
    Parameters:
107
     - fromDate
108
     - toDate
109
    """
110
    pass
1137 chandransh 111
 
3064 chandransh 112
  def isCodAllowed(self, destination_pincode):
113
    """
114
    Returns true if COD is allowed for this destination pincode
3431 rajveer 115
 
3064 chandransh 116
    Parameters:
117
     - destination_pincode
118
    """
119
    pass
1730 ankur.sing 120
 
3064 chandransh 121
 
3376 rajveer 122
class Client(shop2020.thriftpy.generic.GenericService.Client, Iface):
412 ashish 123
  def __init__(self, iprot, oprot=None):
3376 rajveer 124
    shop2020.thriftpy.generic.GenericService.Client.__init__(self, iprot, oprot)
412 ashish 125
 
669 chandransh 126
  def getProvider(self, providerId):
127
    """
128
    Returns a provider for a given provider ID. Throws an exception if none found.
3431 rajveer 129
 
669 chandransh 130
    Parameters:
131
     - providerId
132
    """
133
    self.send_getProvider(providerId)
134
    return self.recv_getProvider()
135
 
136
  def send_getProvider(self, providerId):
137
    self._oprot.writeMessageBegin('getProvider', TMessageType.CALL, self._seqid)
138
    args = getProvider_args()
139
    args.providerId = providerId
140
    args.write(self._oprot)
141
    self._oprot.writeMessageEnd()
142
    self._oprot.trans.flush()
143
 
144
  def recv_getProvider(self, ):
145
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
146
    if mtype == TMessageType.EXCEPTION:
147
      x = TApplicationException()
148
      x.read(self._iprot)
149
      self._iprot.readMessageEnd()
150
      raise x
151
    result = getProvider_result()
152
    result.read(self._iprot)
153
    self._iprot.readMessageEnd()
3431 rajveer 154
    if result.success is not None:
669 chandransh 155
      return result.success
3431 rajveer 156
    if result.lse is not None:
669 chandransh 157
      raise result.lse
158
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getProvider failed: unknown result");
159
 
675 chandransh 160
  def getAllProviders(self, ):
161
    """
162
    Returns a list containing all the providers.
163
    """
164
    self.send_getAllProviders()
165
    return self.recv_getAllProviders()
166
 
167
  def send_getAllProviders(self, ):
168
    self._oprot.writeMessageBegin('getAllProviders', TMessageType.CALL, self._seqid)
169
    args = getAllProviders_args()
170
    args.write(self._oprot)
171
    self._oprot.writeMessageEnd()
172
    self._oprot.trans.flush()
173
 
174
  def recv_getAllProviders(self, ):
175
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
176
    if mtype == TMessageType.EXCEPTION:
177
      x = TApplicationException()
178
      x.read(self._iprot)
179
      self._iprot.readMessageEnd()
180
      raise x
181
    result = getAllProviders_result()
182
    result.read(self._iprot)
183
    self._iprot.readMessageEnd()
3431 rajveer 184
    if result.success is not None:
675 chandransh 185
      return result.success
3431 rajveer 186
    if result.lse is not None:
675 chandransh 187
      raise result.lse
188
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAllProviders failed: unknown result");
189
 
4630 mandeep.dh 190
  def getLogisticsEstimation(self, itemId, destination_pin, type):
483 rajveer 191
    """
647 chandransh 192
    Returns a LogisticsInfo structure w/o an airway bill number. Use this method during the estimation phase.
193
    Raises an exception if this pincode is not allocated to any warehouse zone or provider. Also, if the pincode
194
    is allocated to a warehouse zone but there are no actual warehouses in that zone, an exception is raised.
3431 rajveer 195
 
483 rajveer 196
    Parameters:
647 chandransh 197
     - itemId
198
     - destination_pin
4630 mandeep.dh 199
     - type
483 rajveer 200
    """
4630 mandeep.dh 201
    self.send_getLogisticsEstimation(itemId, destination_pin, type)
647 chandransh 202
    return self.recv_getLogisticsEstimation()
483 rajveer 203
 
4630 mandeep.dh 204
  def send_getLogisticsEstimation(self, itemId, destination_pin, type):
647 chandransh 205
    self._oprot.writeMessageBegin('getLogisticsEstimation', TMessageType.CALL, self._seqid)
206
    args = getLogisticsEstimation_args()
207
    args.itemId = itemId
208
    args.destination_pin = destination_pin
4630 mandeep.dh 209
    args.type = type
483 rajveer 210
    args.write(self._oprot)
211
    self._oprot.writeMessageEnd()
212
    self._oprot.trans.flush()
213
 
647 chandransh 214
  def recv_getLogisticsEstimation(self, ):
483 rajveer 215
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
216
    if mtype == TMessageType.EXCEPTION:
217
      x = TApplicationException()
218
      x.read(self._iprot)
219
      self._iprot.readMessageEnd()
220
      raise x
647 chandransh 221
    result = getLogisticsEstimation_result()
483 rajveer 222
    result.read(self._iprot)
223
    self._iprot.readMessageEnd()
3431 rajveer 224
    if result.success is not None:
483 rajveer 225
      return result.success
3431 rajveer 226
    if result.se is not None:
483 rajveer 227
      raise result.se
647 chandransh 228
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getLogisticsEstimation failed: unknown result");
483 rajveer 229
 
3044 chandransh 230
  def getLogisticsInfo(self, destination_pincode, item_id, type):
472 rajveer 231
    """
647 chandransh 232
    Same as above excpet that an airway bill number is also allocated and returned.
3431 rajveer 233
 
472 rajveer 234
    Parameters:
647 chandransh 235
     - destination_pincode
236
     - item_id
3044 chandransh 237
     - type
472 rajveer 238
    """
3044 chandransh 239
    self.send_getLogisticsInfo(destination_pincode, item_id, type)
647 chandransh 240
    return self.recv_getLogisticsInfo()
472 rajveer 241
 
3044 chandransh 242
  def send_getLogisticsInfo(self, destination_pincode, item_id, type):
647 chandransh 243
    self._oprot.writeMessageBegin('getLogisticsInfo', TMessageType.CALL, self._seqid)
244
    args = getLogisticsInfo_args()
245
    args.destination_pincode = destination_pincode
246
    args.item_id = item_id
3044 chandransh 247
    args.type = type
472 rajveer 248
    args.write(self._oprot)
249
    self._oprot.writeMessageEnd()
250
    self._oprot.trans.flush()
251
 
647 chandransh 252
  def recv_getLogisticsInfo(self, ):
472 rajveer 253
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
254
    if mtype == TMessageType.EXCEPTION:
255
      x = TApplicationException()
256
      x.read(self._iprot)
257
      self._iprot.readMessageEnd()
258
      raise x
647 chandransh 259
    result = getLogisticsInfo_result()
472 rajveer 260
    result.read(self._iprot)
261
    self._iprot.readMessageEnd()
3431 rajveer 262
    if result.success is not None:
472 rajveer 263
      return result.success
3431 rajveer 264
    if result.se is not None:
472 rajveer 265
      raise result.se
647 chandransh 266
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getLogisticsInfo failed: unknown result");
472 rajveer 267
 
647 chandransh 268
  def getEmptyAWB(self, providerId):
412 ashish 269
    """
647 chandransh 270
    Returns an unused AWB number for the given provider.
3431 rajveer 271
 
412 ashish 272
    Parameters:
647 chandransh 273
     - providerId
412 ashish 274
    """
647 chandransh 275
    self.send_getEmptyAWB(providerId)
412 ashish 276
    return self.recv_getEmptyAWB()
277
 
647 chandransh 278
  def send_getEmptyAWB(self, providerId):
412 ashish 279
    self._oprot.writeMessageBegin('getEmptyAWB', TMessageType.CALL, self._seqid)
280
    args = getEmptyAWB_args()
647 chandransh 281
    args.providerId = providerId
412 ashish 282
    args.write(self._oprot)
283
    self._oprot.writeMessageEnd()
284
    self._oprot.trans.flush()
285
 
286
  def recv_getEmptyAWB(self, ):
287
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
288
    if mtype == TMessageType.EXCEPTION:
289
      x = TApplicationException()
290
      x.read(self._iprot)
291
      self._iprot.readMessageEnd()
292
      raise x
293
    result = getEmptyAWB_result()
294
    result.read(self._iprot)
295
    self._iprot.readMessageEnd()
3431 rajveer 296
    if result.success is not None:
412 ashish 297
      return result.success
3431 rajveer 298
    if result.se is not None:
647 chandransh 299
      raise result.se
412 ashish 300
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getEmptyAWB failed: unknown result");
301
 
647 chandransh 302
  def getShipmentInfo(self, awb, providerId):
412 ashish 303
    """
647 chandransh 304
    Returns the list of updates for the given AWB number and provider id. The list is empty if there are no updates yet.
3431 rajveer 305
 
412 ashish 306
    Parameters:
307
     - awb
647 chandransh 308
     - providerId
412 ashish 309
    """
647 chandransh 310
    self.send_getShipmentInfo(awb, providerId)
412 ashish 311
    return self.recv_getShipmentInfo()
312
 
647 chandransh 313
  def send_getShipmentInfo(self, awb, providerId):
412 ashish 314
    self._oprot.writeMessageBegin('getShipmentInfo', TMessageType.CALL, self._seqid)
315
    args = getShipmentInfo_args()
316
    args.awb = awb
647 chandransh 317
    args.providerId = providerId
412 ashish 318
    args.write(self._oprot)
319
    self._oprot.writeMessageEnd()
320
    self._oprot.trans.flush()
321
 
322
  def recv_getShipmentInfo(self, ):
323
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
324
    if mtype == TMessageType.EXCEPTION:
325
      x = TApplicationException()
326
      x.read(self._iprot)
327
      self._iprot.readMessageEnd()
328
      raise x
329
    result = getShipmentInfo_result()
330
    result.read(self._iprot)
331
    self._iprot.readMessageEnd()
3431 rajveer 332
    if result.success is not None:
412 ashish 333
      return result.success
3431 rajveer 334
    if result.se is not None:
647 chandransh 335
      raise result.se
412 ashish 336
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getShipmentInfo failed: unknown result");
337
 
732 chandransh 338
  def getDestinationCode(self, providerId, pinCode):
339
    """
340
    Returns the short three letter code of a pincode for the given provider.
341
       Raises an exception if the pin code is not serviced by the given provider.
3431 rajveer 342
 
732 chandransh 343
    Parameters:
344
     - providerId
345
     - pinCode
346
    """
347
    self.send_getDestinationCode(providerId, pinCode)
348
    return self.recv_getDestinationCode()
412 ashish 349
 
732 chandransh 350
  def send_getDestinationCode(self, providerId, pinCode):
351
    self._oprot.writeMessageBegin('getDestinationCode', TMessageType.CALL, self._seqid)
352
    args = getDestinationCode_args()
353
    args.providerId = providerId
354
    args.pinCode = pinCode
355
    args.write(self._oprot)
356
    self._oprot.writeMessageEnd()
357
    self._oprot.trans.flush()
358
 
359
  def recv_getDestinationCode(self, ):
360
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
361
    if mtype == TMessageType.EXCEPTION:
362
      x = TApplicationException()
363
      x.read(self._iprot)
364
      self._iprot.readMessageEnd()
365
      raise x
366
    result = getDestinationCode_result()
367
    result.read(self._iprot)
368
    self._iprot.readMessageEnd()
3431 rajveer 369
    if result.success is not None:
732 chandransh 370
      return result.success
3431 rajveer 371
    if result.se is not None:
732 chandransh 372
      raise result.se
373
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getDestinationCode failed: unknown result");
374
 
3103 chandransh 375
  def getFreeAwbCount(self, providerId, type):
1137 chandransh 376
    """
3103 chandransh 377
    Returns the number of unused AWB numbers for the given provider of the given type
3431 rajveer 378
 
1137 chandransh 379
    Parameters:
380
     - providerId
3103 chandransh 381
     - type
1137 chandransh 382
    """
3103 chandransh 383
    self.send_getFreeAwbCount(providerId, type)
1137 chandransh 384
    return self.recv_getFreeAwbCount()
732 chandransh 385
 
3103 chandransh 386
  def send_getFreeAwbCount(self, providerId, type):
1137 chandransh 387
    self._oprot.writeMessageBegin('getFreeAwbCount', TMessageType.CALL, self._seqid)
388
    args = getFreeAwbCount_args()
389
    args.providerId = providerId
3103 chandransh 390
    args.type = type
1137 chandransh 391
    args.write(self._oprot)
392
    self._oprot.writeMessageEnd()
393
    self._oprot.trans.flush()
394
 
395
  def recv_getFreeAwbCount(self, ):
396
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
397
    if mtype == TMessageType.EXCEPTION:
398
      x = TApplicationException()
399
      x.read(self._iprot)
400
      self._iprot.readMessageEnd()
401
      raise x
402
    result = getFreeAwbCount_result()
403
    result.read(self._iprot)
404
    self._iprot.readMessageEnd()
3431 rajveer 405
    if result.success is not None:
1137 chandransh 406
      return result.success
407
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getFreeAwbCount failed: unknown result");
408
 
1730 ankur.sing 409
  def getHolidays(self, fromDate, toDate):
410
    """
411
    Returns list of Holiday dates between fromDate and toDate (both inclusive)
412
    fromDate should be passed as milliseconds corresponding to the start of the day.
413
    If fromDate is passed as -1, fromDate is not considered for filtering
414
    If toDate is passed as -1, toDate is not considered for filtering
3431 rajveer 415
 
1730 ankur.sing 416
    Parameters:
417
     - fromDate
418
     - toDate
419
    """
420
    self.send_getHolidays(fromDate, toDate)
421
    return self.recv_getHolidays()
1137 chandransh 422
 
1730 ankur.sing 423
  def send_getHolidays(self, fromDate, toDate):
424
    self._oprot.writeMessageBegin('getHolidays', TMessageType.CALL, self._seqid)
425
    args = getHolidays_args()
426
    args.fromDate = fromDate
427
    args.toDate = toDate
428
    args.write(self._oprot)
429
    self._oprot.writeMessageEnd()
430
    self._oprot.trans.flush()
431
 
432
  def recv_getHolidays(self, ):
433
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
434
    if mtype == TMessageType.EXCEPTION:
435
      x = TApplicationException()
436
      x.read(self._iprot)
437
      self._iprot.readMessageEnd()
438
      raise x
439
    result = getHolidays_result()
440
    result.read(self._iprot)
441
    self._iprot.readMessageEnd()
3431 rajveer 442
    if result.success is not None:
1730 ankur.sing 443
      return result.success
444
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getHolidays failed: unknown result");
445
 
3064 chandransh 446
  def isCodAllowed(self, destination_pincode):
447
    """
448
    Returns true if COD is allowed for this destination pincode
3431 rajveer 449
 
3064 chandransh 450
    Parameters:
451
     - destination_pincode
452
    """
453
    self.send_isCodAllowed(destination_pincode)
454
    return self.recv_isCodAllowed()
1730 ankur.sing 455
 
3064 chandransh 456
  def send_isCodAllowed(self, destination_pincode):
457
    self._oprot.writeMessageBegin('isCodAllowed', TMessageType.CALL, self._seqid)
458
    args = isCodAllowed_args()
459
    args.destination_pincode = destination_pincode
460
    args.write(self._oprot)
461
    self._oprot.writeMessageEnd()
462
    self._oprot.trans.flush()
463
 
464
  def recv_isCodAllowed(self, ):
465
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
466
    if mtype == TMessageType.EXCEPTION:
467
      x = TApplicationException()
468
      x.read(self._iprot)
469
      self._iprot.readMessageEnd()
470
      raise x
471
    result = isCodAllowed_result()
472
    result.read(self._iprot)
473
    self._iprot.readMessageEnd()
3431 rajveer 474
    if result.success is not None:
3064 chandransh 475
      return result.success
476
    raise TApplicationException(TApplicationException.MISSING_RESULT, "isCodAllowed failed: unknown result");
477
 
478
 
3376 rajveer 479
class Processor(shop2020.thriftpy.generic.GenericService.Processor, Iface, TProcessor):
412 ashish 480
  def __init__(self, handler):
3376 rajveer 481
    shop2020.thriftpy.generic.GenericService.Processor.__init__(self, handler)
669 chandransh 482
    self._processMap["getProvider"] = Processor.process_getProvider
675 chandransh 483
    self._processMap["getAllProviders"] = Processor.process_getAllProviders
647 chandransh 484
    self._processMap["getLogisticsEstimation"] = Processor.process_getLogisticsEstimation
483 rajveer 485
    self._processMap["getLogisticsInfo"] = Processor.process_getLogisticsInfo
412 ashish 486
    self._processMap["getEmptyAWB"] = Processor.process_getEmptyAWB
487
    self._processMap["getShipmentInfo"] = Processor.process_getShipmentInfo
732 chandransh 488
    self._processMap["getDestinationCode"] = Processor.process_getDestinationCode
1137 chandransh 489
    self._processMap["getFreeAwbCount"] = Processor.process_getFreeAwbCount
1730 ankur.sing 490
    self._processMap["getHolidays"] = Processor.process_getHolidays
3064 chandransh 491
    self._processMap["isCodAllowed"] = Processor.process_isCodAllowed
412 ashish 492
 
493
  def process(self, iprot, oprot):
494
    (name, type, seqid) = iprot.readMessageBegin()
495
    if name not in self._processMap:
496
      iprot.skip(TType.STRUCT)
497
      iprot.readMessageEnd()
498
      x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
499
      oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
500
      x.write(oprot)
501
      oprot.writeMessageEnd()
502
      oprot.trans.flush()
503
      return
504
    else:
505
      self._processMap[name](self, seqid, iprot, oprot)
506
    return True
507
 
669 chandransh 508
  def process_getProvider(self, seqid, iprot, oprot):
509
    args = getProvider_args()
510
    args.read(iprot)
511
    iprot.readMessageEnd()
512
    result = getProvider_result()
513
    try:
514
      result.success = self._handler.getProvider(args.providerId)
515
    except LogisticsServiceException, lse:
516
      result.lse = lse
517
    oprot.writeMessageBegin("getProvider", TMessageType.REPLY, seqid)
518
    result.write(oprot)
519
    oprot.writeMessageEnd()
520
    oprot.trans.flush()
521
 
675 chandransh 522
  def process_getAllProviders(self, seqid, iprot, oprot):
523
    args = getAllProviders_args()
524
    args.read(iprot)
525
    iprot.readMessageEnd()
526
    result = getAllProviders_result()
527
    try:
528
      result.success = self._handler.getAllProviders()
529
    except LogisticsServiceException, lse:
530
      result.lse = lse
531
    oprot.writeMessageBegin("getAllProviders", TMessageType.REPLY, seqid)
532
    result.write(oprot)
533
    oprot.writeMessageEnd()
534
    oprot.trans.flush()
535
 
647 chandransh 536
  def process_getLogisticsEstimation(self, seqid, iprot, oprot):
537
    args = getLogisticsEstimation_args()
483 rajveer 538
    args.read(iprot)
539
    iprot.readMessageEnd()
647 chandransh 540
    result = getLogisticsEstimation_result()
483 rajveer 541
    try:
4630 mandeep.dh 542
      result.success = self._handler.getLogisticsEstimation(args.itemId, args.destination_pin, args.type)
483 rajveer 543
    except LogisticsServiceException, se:
544
      result.se = se
647 chandransh 545
    oprot.writeMessageBegin("getLogisticsEstimation", TMessageType.REPLY, seqid)
483 rajveer 546
    result.write(oprot)
547
    oprot.writeMessageEnd()
548
    oprot.trans.flush()
549
 
647 chandransh 550
  def process_getLogisticsInfo(self, seqid, iprot, oprot):
551
    args = getLogisticsInfo_args()
472 rajveer 552
    args.read(iprot)
553
    iprot.readMessageEnd()
647 chandransh 554
    result = getLogisticsInfo_result()
472 rajveer 555
    try:
3044 chandransh 556
      result.success = self._handler.getLogisticsInfo(args.destination_pincode, args.item_id, args.type)
472 rajveer 557
    except LogisticsServiceException, se:
558
      result.se = se
647 chandransh 559
    oprot.writeMessageBegin("getLogisticsInfo", TMessageType.REPLY, seqid)
472 rajveer 560
    result.write(oprot)
561
    oprot.writeMessageEnd()
562
    oprot.trans.flush()
563
 
412 ashish 564
  def process_getEmptyAWB(self, seqid, iprot, oprot):
565
    args = getEmptyAWB_args()
566
    args.read(iprot)
567
    iprot.readMessageEnd()
568
    result = getEmptyAWB_result()
647 chandransh 569
    try:
570
      result.success = self._handler.getEmptyAWB(args.providerId)
571
    except LogisticsServiceException, se:
572
      result.se = se
412 ashish 573
    oprot.writeMessageBegin("getEmptyAWB", TMessageType.REPLY, seqid)
574
    result.write(oprot)
575
    oprot.writeMessageEnd()
576
    oprot.trans.flush()
577
 
578
  def process_getShipmentInfo(self, seqid, iprot, oprot):
579
    args = getShipmentInfo_args()
580
    args.read(iprot)
581
    iprot.readMessageEnd()
582
    result = getShipmentInfo_result()
647 chandransh 583
    try:
584
      result.success = self._handler.getShipmentInfo(args.awb, args.providerId)
585
    except LogisticsServiceException, se:
586
      result.se = se
412 ashish 587
    oprot.writeMessageBegin("getShipmentInfo", TMessageType.REPLY, seqid)
588
    result.write(oprot)
589
    oprot.writeMessageEnd()
590
    oprot.trans.flush()
591
 
732 chandransh 592
  def process_getDestinationCode(self, seqid, iprot, oprot):
593
    args = getDestinationCode_args()
594
    args.read(iprot)
595
    iprot.readMessageEnd()
596
    result = getDestinationCode_result()
597
    try:
598
      result.success = self._handler.getDestinationCode(args.providerId, args.pinCode)
599
    except LogisticsServiceException, se:
600
      result.se = se
601
    oprot.writeMessageBegin("getDestinationCode", TMessageType.REPLY, seqid)
602
    result.write(oprot)
603
    oprot.writeMessageEnd()
604
    oprot.trans.flush()
412 ashish 605
 
1137 chandransh 606
  def process_getFreeAwbCount(self, seqid, iprot, oprot):
607
    args = getFreeAwbCount_args()
608
    args.read(iprot)
609
    iprot.readMessageEnd()
610
    result = getFreeAwbCount_result()
3103 chandransh 611
    result.success = self._handler.getFreeAwbCount(args.providerId, args.type)
1137 chandransh 612
    oprot.writeMessageBegin("getFreeAwbCount", TMessageType.REPLY, seqid)
613
    result.write(oprot)
614
    oprot.writeMessageEnd()
615
    oprot.trans.flush()
732 chandransh 616
 
1730 ankur.sing 617
  def process_getHolidays(self, seqid, iprot, oprot):
618
    args = getHolidays_args()
619
    args.read(iprot)
620
    iprot.readMessageEnd()
621
    result = getHolidays_result()
622
    result.success = self._handler.getHolidays(args.fromDate, args.toDate)
623
    oprot.writeMessageBegin("getHolidays", TMessageType.REPLY, seqid)
624
    result.write(oprot)
625
    oprot.writeMessageEnd()
626
    oprot.trans.flush()
1137 chandransh 627
 
3064 chandransh 628
  def process_isCodAllowed(self, seqid, iprot, oprot):
629
    args = isCodAllowed_args()
630
    args.read(iprot)
631
    iprot.readMessageEnd()
632
    result = isCodAllowed_result()
633
    result.success = self._handler.isCodAllowed(args.destination_pincode)
634
    oprot.writeMessageBegin("isCodAllowed", TMessageType.REPLY, seqid)
635
    result.write(oprot)
636
    oprot.writeMessageEnd()
637
    oprot.trans.flush()
1730 ankur.sing 638
 
3064 chandransh 639
 
412 ashish 640
# HELPER FUNCTIONS AND STRUCTURES
641
 
669 chandransh 642
class getProvider_args:
643
  """
644
  Attributes:
645
   - providerId
646
  """
647
 
648
  thrift_spec = (
649
    None, # 0
650
    (1, TType.I64, 'providerId', None, None, ), # 1
651
  )
652
 
653
  def __init__(self, providerId=None,):
654
    self.providerId = providerId
655
 
656
  def read(self, iprot):
657
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
658
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
659
      return
660
    iprot.readStructBegin()
661
    while True:
662
      (fname, ftype, fid) = iprot.readFieldBegin()
663
      if ftype == TType.STOP:
664
        break
665
      if fid == 1:
666
        if ftype == TType.I64:
667
          self.providerId = iprot.readI64();
668
        else:
669
          iprot.skip(ftype)
670
      else:
671
        iprot.skip(ftype)
672
      iprot.readFieldEnd()
673
    iprot.readStructEnd()
674
 
675
  def write(self, oprot):
676
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
677
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
678
      return
679
    oprot.writeStructBegin('getProvider_args')
3431 rajveer 680
    if self.providerId is not None:
669 chandransh 681
      oprot.writeFieldBegin('providerId', TType.I64, 1)
682
      oprot.writeI64(self.providerId)
683
      oprot.writeFieldEnd()
684
    oprot.writeFieldStop()
685
    oprot.writeStructEnd()
686
 
3431 rajveer 687
  def validate(self):
688
    return
689
 
690
 
669 chandransh 691
  def __repr__(self):
692
    L = ['%s=%r' % (key, value)
693
      for key, value in self.__dict__.iteritems()]
694
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
695
 
696
  def __eq__(self, other):
697
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
698
 
699
  def __ne__(self, other):
700
    return not (self == other)
701
 
702
class getProvider_result:
703
  """
704
  Attributes:
705
   - success
706
   - lse
707
  """
708
 
709
  thrift_spec = (
710
    (0, TType.STRUCT, 'success', (Provider, Provider.thrift_spec), None, ), # 0
711
    (1, TType.STRUCT, 'lse', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
712
  )
713
 
714
  def __init__(self, success=None, lse=None,):
715
    self.success = success
716
    self.lse = lse
717
 
718
  def read(self, iprot):
719
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
720
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
721
      return
722
    iprot.readStructBegin()
723
    while True:
724
      (fname, ftype, fid) = iprot.readFieldBegin()
725
      if ftype == TType.STOP:
726
        break
727
      if fid == 0:
728
        if ftype == TType.STRUCT:
729
          self.success = Provider()
730
          self.success.read(iprot)
731
        else:
732
          iprot.skip(ftype)
733
      elif fid == 1:
734
        if ftype == TType.STRUCT:
735
          self.lse = LogisticsServiceException()
736
          self.lse.read(iprot)
737
        else:
738
          iprot.skip(ftype)
739
      else:
740
        iprot.skip(ftype)
741
      iprot.readFieldEnd()
742
    iprot.readStructEnd()
743
 
744
  def write(self, oprot):
745
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
746
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
747
      return
748
    oprot.writeStructBegin('getProvider_result')
3431 rajveer 749
    if self.success is not None:
669 chandransh 750
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
751
      self.success.write(oprot)
752
      oprot.writeFieldEnd()
3431 rajveer 753
    if self.lse is not None:
669 chandransh 754
      oprot.writeFieldBegin('lse', TType.STRUCT, 1)
755
      self.lse.write(oprot)
756
      oprot.writeFieldEnd()
757
    oprot.writeFieldStop()
758
    oprot.writeStructEnd()
759
 
3431 rajveer 760
  def validate(self):
761
    return
762
 
763
 
669 chandransh 764
  def __repr__(self):
765
    L = ['%s=%r' % (key, value)
766
      for key, value in self.__dict__.iteritems()]
767
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
768
 
769
  def __eq__(self, other):
770
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
771
 
772
  def __ne__(self, other):
773
    return not (self == other)
774
 
675 chandransh 775
class getAllProviders_args:
776
 
777
  thrift_spec = (
778
  )
779
 
780
  def read(self, iprot):
781
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
782
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
783
      return
784
    iprot.readStructBegin()
785
    while True:
786
      (fname, ftype, fid) = iprot.readFieldBegin()
787
      if ftype == TType.STOP:
788
        break
789
      else:
790
        iprot.skip(ftype)
791
      iprot.readFieldEnd()
792
    iprot.readStructEnd()
793
 
794
  def write(self, oprot):
795
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
796
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
797
      return
798
    oprot.writeStructBegin('getAllProviders_args')
799
    oprot.writeFieldStop()
800
    oprot.writeStructEnd()
801
 
3431 rajveer 802
  def validate(self):
803
    return
804
 
805
 
675 chandransh 806
  def __repr__(self):
807
    L = ['%s=%r' % (key, value)
808
      for key, value in self.__dict__.iteritems()]
809
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
810
 
811
  def __eq__(self, other):
812
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
813
 
814
  def __ne__(self, other):
815
    return not (self == other)
816
 
817
class getAllProviders_result:
818
  """
819
  Attributes:
820
   - success
821
   - lse
822
  """
823
 
824
  thrift_spec = (
825
    (0, TType.LIST, 'success', (TType.STRUCT,(Provider, Provider.thrift_spec)), None, ), # 0
826
    (1, TType.STRUCT, 'lse', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
827
  )
828
 
829
  def __init__(self, success=None, lse=None,):
830
    self.success = success
831
    self.lse = lse
832
 
833
  def read(self, iprot):
834
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
835
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
836
      return
837
    iprot.readStructBegin()
838
    while True:
839
      (fname, ftype, fid) = iprot.readFieldBegin()
840
      if ftype == TType.STOP:
841
        break
842
      if fid == 0:
843
        if ftype == TType.LIST:
844
          self.success = []
3044 chandransh 845
          (_etype12, _size9) = iprot.readListBegin()
846
          for _i13 in xrange(_size9):
847
            _elem14 = Provider()
848
            _elem14.read(iprot)
849
            self.success.append(_elem14)
675 chandransh 850
          iprot.readListEnd()
851
        else:
852
          iprot.skip(ftype)
853
      elif fid == 1:
854
        if ftype == TType.STRUCT:
855
          self.lse = LogisticsServiceException()
856
          self.lse.read(iprot)
857
        else:
858
          iprot.skip(ftype)
859
      else:
860
        iprot.skip(ftype)
861
      iprot.readFieldEnd()
862
    iprot.readStructEnd()
863
 
864
  def write(self, oprot):
865
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
866
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
867
      return
868
    oprot.writeStructBegin('getAllProviders_result')
3431 rajveer 869
    if self.success is not None:
675 chandransh 870
      oprot.writeFieldBegin('success', TType.LIST, 0)
871
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3044 chandransh 872
      for iter15 in self.success:
873
        iter15.write(oprot)
675 chandransh 874
      oprot.writeListEnd()
875
      oprot.writeFieldEnd()
3431 rajveer 876
    if self.lse is not None:
675 chandransh 877
      oprot.writeFieldBegin('lse', TType.STRUCT, 1)
878
      self.lse.write(oprot)
879
      oprot.writeFieldEnd()
880
    oprot.writeFieldStop()
881
    oprot.writeStructEnd()
882
 
3431 rajveer 883
  def validate(self):
884
    return
885
 
886
 
675 chandransh 887
  def __repr__(self):
888
    L = ['%s=%r' % (key, value)
889
      for key, value in self.__dict__.iteritems()]
890
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
891
 
892
  def __eq__(self, other):
893
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
894
 
895
  def __ne__(self, other):
896
    return not (self == other)
897
 
647 chandransh 898
class getLogisticsEstimation_args:
483 rajveer 899
  """
900
  Attributes:
647 chandransh 901
   - itemId
902
   - destination_pin
4630 mandeep.dh 903
   - type
483 rajveer 904
  """
905
 
906
  thrift_spec = (
907
    None, # 0
647 chandransh 908
    (1, TType.I64, 'itemId', None, None, ), # 1
909
    (2, TType.STRING, 'destination_pin', None, None, ), # 2
4630 mandeep.dh 910
    (3, TType.I32, 'type', None, None, ), # 3
483 rajveer 911
  )
912
 
4630 mandeep.dh 913
  def __init__(self, itemId=None, destination_pin=None, type=None,):
647 chandransh 914
    self.itemId = itemId
915
    self.destination_pin = destination_pin
4630 mandeep.dh 916
    self.type = type
483 rajveer 917
 
918
  def read(self, iprot):
919
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
920
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
921
      return
922
    iprot.readStructBegin()
923
    while True:
924
      (fname, ftype, fid) = iprot.readFieldBegin()
925
      if ftype == TType.STOP:
926
        break
927
      if fid == 1:
647 chandransh 928
        if ftype == TType.I64:
929
          self.itemId = iprot.readI64();
483 rajveer 930
        else:
931
          iprot.skip(ftype)
932
      elif fid == 2:
933
        if ftype == TType.STRING:
647 chandransh 934
          self.destination_pin = iprot.readString();
483 rajveer 935
        else:
936
          iprot.skip(ftype)
4630 mandeep.dh 937
      elif fid == 3:
938
        if ftype == TType.I32:
939
          self.type = iprot.readI32();
940
        else:
941
          iprot.skip(ftype)
483 rajveer 942
      else:
943
        iprot.skip(ftype)
944
      iprot.readFieldEnd()
945
    iprot.readStructEnd()
946
 
947
  def write(self, oprot):
948
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
949
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
950
      return
647 chandransh 951
    oprot.writeStructBegin('getLogisticsEstimation_args')
3431 rajveer 952
    if self.itemId is not None:
647 chandransh 953
      oprot.writeFieldBegin('itemId', TType.I64, 1)
954
      oprot.writeI64(self.itemId)
483 rajveer 955
      oprot.writeFieldEnd()
3431 rajveer 956
    if self.destination_pin is not None:
647 chandransh 957
      oprot.writeFieldBegin('destination_pin', TType.STRING, 2)
958
      oprot.writeString(self.destination_pin)
483 rajveer 959
      oprot.writeFieldEnd()
4630 mandeep.dh 960
    if self.type is not None:
961
      oprot.writeFieldBegin('type', TType.I32, 3)
962
      oprot.writeI32(self.type)
963
      oprot.writeFieldEnd()
483 rajveer 964
    oprot.writeFieldStop()
965
    oprot.writeStructEnd()
966
 
3431 rajveer 967
  def validate(self):
968
    return
969
 
970
 
483 rajveer 971
  def __repr__(self):
972
    L = ['%s=%r' % (key, value)
973
      for key, value in self.__dict__.iteritems()]
974
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
975
 
976
  def __eq__(self, other):
977
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
978
 
979
  def __ne__(self, other):
980
    return not (self == other)
981
 
647 chandransh 982
class getLogisticsEstimation_result:
483 rajveer 983
  """
984
  Attributes:
985
   - success
986
   - se
987
  """
988
 
989
  thrift_spec = (
990
    (0, TType.STRUCT, 'success', (LogisticsInfo, LogisticsInfo.thrift_spec), None, ), # 0
991
    (1, TType.STRUCT, 'se', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
992
  )
993
 
994
  def __init__(self, success=None, se=None,):
995
    self.success = success
996
    self.se = se
997
 
998
  def read(self, iprot):
999
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1000
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1001
      return
1002
    iprot.readStructBegin()
1003
    while True:
1004
      (fname, ftype, fid) = iprot.readFieldBegin()
1005
      if ftype == TType.STOP:
1006
        break
1007
      if fid == 0:
1008
        if ftype == TType.STRUCT:
1009
          self.success = LogisticsInfo()
1010
          self.success.read(iprot)
1011
        else:
1012
          iprot.skip(ftype)
1013
      elif fid == 1:
1014
        if ftype == TType.STRUCT:
1015
          self.se = LogisticsServiceException()
1016
          self.se.read(iprot)
1017
        else:
1018
          iprot.skip(ftype)
1019
      else:
1020
        iprot.skip(ftype)
1021
      iprot.readFieldEnd()
1022
    iprot.readStructEnd()
1023
 
1024
  def write(self, oprot):
1025
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1026
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1027
      return
647 chandransh 1028
    oprot.writeStructBegin('getLogisticsEstimation_result')
3431 rajveer 1029
    if self.success is not None:
483 rajveer 1030
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
1031
      self.success.write(oprot)
1032
      oprot.writeFieldEnd()
3431 rajveer 1033
    if self.se is not None:
483 rajveer 1034
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1035
      self.se.write(oprot)
1036
      oprot.writeFieldEnd()
1037
    oprot.writeFieldStop()
1038
    oprot.writeStructEnd()
1039
 
3431 rajveer 1040
  def validate(self):
1041
    return
1042
 
1043
 
483 rajveer 1044
  def __repr__(self):
1045
    L = ['%s=%r' % (key, value)
1046
      for key, value in self.__dict__.iteritems()]
1047
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1048
 
1049
  def __eq__(self, other):
1050
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1051
 
1052
  def __ne__(self, other):
1053
    return not (self == other)
1054
 
647 chandransh 1055
class getLogisticsInfo_args:
472 rajveer 1056
  """
1057
  Attributes:
647 chandransh 1058
   - destination_pincode
1059
   - item_id
3044 chandransh 1060
   - type
472 rajveer 1061
  """
1062
 
1063
  thrift_spec = (
1064
    None, # 0
647 chandransh 1065
    (1, TType.STRING, 'destination_pincode', None, None, ), # 1
716 rajveer 1066
    (2, TType.I64, 'item_id', None, None, ), # 2
3044 chandransh 1067
    (3, TType.I32, 'type', None, None, ), # 3
472 rajveer 1068
  )
1069
 
3044 chandransh 1070
  def __init__(self, destination_pincode=None, item_id=None, type=None,):
647 chandransh 1071
    self.destination_pincode = destination_pincode
1072
    self.item_id = item_id
3044 chandransh 1073
    self.type = type
472 rajveer 1074
 
1075
  def read(self, iprot):
1076
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1077
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1078
      return
1079
    iprot.readStructBegin()
1080
    while True:
1081
      (fname, ftype, fid) = iprot.readFieldBegin()
1082
      if ftype == TType.STOP:
1083
        break
1084
      if fid == 1:
647 chandransh 1085
        if ftype == TType.STRING:
1086
          self.destination_pincode = iprot.readString();
472 rajveer 1087
        else:
1088
          iprot.skip(ftype)
1089
      elif fid == 2:
716 rajveer 1090
        if ftype == TType.I64:
1091
          self.item_id = iprot.readI64();
472 rajveer 1092
        else:
1093
          iprot.skip(ftype)
3044 chandransh 1094
      elif fid == 3:
1095
        if ftype == TType.I32:
1096
          self.type = iprot.readI32();
1097
        else:
1098
          iprot.skip(ftype)
472 rajveer 1099
      else:
1100
        iprot.skip(ftype)
1101
      iprot.readFieldEnd()
1102
    iprot.readStructEnd()
1103
 
1104
  def write(self, oprot):
1105
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1106
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1107
      return
647 chandransh 1108
    oprot.writeStructBegin('getLogisticsInfo_args')
3431 rajveer 1109
    if self.destination_pincode is not None:
647 chandransh 1110
      oprot.writeFieldBegin('destination_pincode', TType.STRING, 1)
1111
      oprot.writeString(self.destination_pincode)
472 rajveer 1112
      oprot.writeFieldEnd()
3431 rajveer 1113
    if self.item_id is not None:
716 rajveer 1114
      oprot.writeFieldBegin('item_id', TType.I64, 2)
1115
      oprot.writeI64(self.item_id)
472 rajveer 1116
      oprot.writeFieldEnd()
3431 rajveer 1117
    if self.type is not None:
3044 chandransh 1118
      oprot.writeFieldBegin('type', TType.I32, 3)
1119
      oprot.writeI32(self.type)
1120
      oprot.writeFieldEnd()
472 rajveer 1121
    oprot.writeFieldStop()
1122
    oprot.writeStructEnd()
1123
 
3431 rajveer 1124
  def validate(self):
1125
    return
1126
 
1127
 
472 rajveer 1128
  def __repr__(self):
1129
    L = ['%s=%r' % (key, value)
1130
      for key, value in self.__dict__.iteritems()]
1131
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1132
 
1133
  def __eq__(self, other):
1134
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1135
 
1136
  def __ne__(self, other):
1137
    return not (self == other)
1138
 
647 chandransh 1139
class getLogisticsInfo_result:
472 rajveer 1140
  """
1141
  Attributes:
1142
   - success
1143
   - se
1144
  """
1145
 
1146
  thrift_spec = (
644 chandransh 1147
    (0, TType.STRUCT, 'success', (LogisticsInfo, LogisticsInfo.thrift_spec), None, ), # 0
472 rajveer 1148
    (1, TType.STRUCT, 'se', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
1149
  )
1150
 
1151
  def __init__(self, success=None, se=None,):
1152
    self.success = success
1153
    self.se = se
1154
 
1155
  def read(self, iprot):
1156
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1157
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1158
      return
1159
    iprot.readStructBegin()
1160
    while True:
1161
      (fname, ftype, fid) = iprot.readFieldBegin()
1162
      if ftype == TType.STOP:
1163
        break
1164
      if fid == 0:
1165
        if ftype == TType.STRUCT:
644 chandransh 1166
          self.success = LogisticsInfo()
472 rajveer 1167
          self.success.read(iprot)
1168
        else:
1169
          iprot.skip(ftype)
1170
      elif fid == 1:
1171
        if ftype == TType.STRUCT:
1172
          self.se = LogisticsServiceException()
1173
          self.se.read(iprot)
1174
        else:
1175
          iprot.skip(ftype)
1176
      else:
1177
        iprot.skip(ftype)
1178
      iprot.readFieldEnd()
1179
    iprot.readStructEnd()
1180
 
1181
  def write(self, oprot):
1182
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1183
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1184
      return
647 chandransh 1185
    oprot.writeStructBegin('getLogisticsInfo_result')
3431 rajveer 1186
    if self.success is not None:
472 rajveer 1187
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
1188
      self.success.write(oprot)
1189
      oprot.writeFieldEnd()
3431 rajveer 1190
    if self.se is not None:
472 rajveer 1191
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1192
      self.se.write(oprot)
1193
      oprot.writeFieldEnd()
1194
    oprot.writeFieldStop()
1195
    oprot.writeStructEnd()
1196
 
3431 rajveer 1197
  def validate(self):
1198
    return
1199
 
1200
 
472 rajveer 1201
  def __repr__(self):
1202
    L = ['%s=%r' % (key, value)
1203
      for key, value in self.__dict__.iteritems()]
1204
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1205
 
1206
  def __eq__(self, other):
1207
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1208
 
1209
  def __ne__(self, other):
1210
    return not (self == other)
1211
 
412 ashish 1212
class getEmptyAWB_args:
1213
  """
1214
  Attributes:
647 chandransh 1215
   - providerId
412 ashish 1216
  """
1217
 
1218
  thrift_spec = (
1219
    None, # 0
647 chandransh 1220
    (1, TType.I64, 'providerId', None, None, ), # 1
412 ashish 1221
  )
1222
 
647 chandransh 1223
  def __init__(self, providerId=None,):
1224
    self.providerId = providerId
412 ashish 1225
 
1226
  def read(self, iprot):
1227
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1228
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1229
      return
1230
    iprot.readStructBegin()
1231
    while True:
1232
      (fname, ftype, fid) = iprot.readFieldBegin()
1233
      if ftype == TType.STOP:
1234
        break
1235
      if fid == 1:
1236
        if ftype == TType.I64:
647 chandransh 1237
          self.providerId = iprot.readI64();
412 ashish 1238
        else:
1239
          iprot.skip(ftype)
1240
      else:
1241
        iprot.skip(ftype)
1242
      iprot.readFieldEnd()
1243
    iprot.readStructEnd()
1244
 
1245
  def write(self, oprot):
1246
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1247
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1248
      return
1249
    oprot.writeStructBegin('getEmptyAWB_args')
3431 rajveer 1250
    if self.providerId is not None:
647 chandransh 1251
      oprot.writeFieldBegin('providerId', TType.I64, 1)
1252
      oprot.writeI64(self.providerId)
412 ashish 1253
      oprot.writeFieldEnd()
1254
    oprot.writeFieldStop()
1255
    oprot.writeStructEnd()
1256
 
3431 rajveer 1257
  def validate(self):
1258
    return
1259
 
1260
 
412 ashish 1261
  def __repr__(self):
1262
    L = ['%s=%r' % (key, value)
1263
      for key, value in self.__dict__.iteritems()]
1264
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1265
 
1266
  def __eq__(self, other):
1267
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1268
 
1269
  def __ne__(self, other):
1270
    return not (self == other)
1271
 
1272
class getEmptyAWB_result:
1273
  """
1274
  Attributes:
1275
   - success
647 chandransh 1276
   - se
412 ashish 1277
  """
1278
 
1279
  thrift_spec = (
1280
    (0, TType.STRING, 'success', None, None, ), # 0
647 chandransh 1281
    (1, TType.STRUCT, 'se', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
412 ashish 1282
  )
1283
 
647 chandransh 1284
  def __init__(self, success=None, se=None,):
412 ashish 1285
    self.success = success
647 chandransh 1286
    self.se = se
412 ashish 1287
 
1288
  def read(self, iprot):
1289
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1290
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1291
      return
1292
    iprot.readStructBegin()
1293
    while True:
1294
      (fname, ftype, fid) = iprot.readFieldBegin()
1295
      if ftype == TType.STOP:
1296
        break
1297
      if fid == 0:
1298
        if ftype == TType.STRING:
1299
          self.success = iprot.readString();
1300
        else:
1301
          iprot.skip(ftype)
647 chandransh 1302
      elif fid == 1:
1303
        if ftype == TType.STRUCT:
1304
          self.se = LogisticsServiceException()
1305
          self.se.read(iprot)
1306
        else:
1307
          iprot.skip(ftype)
412 ashish 1308
      else:
1309
        iprot.skip(ftype)
1310
      iprot.readFieldEnd()
1311
    iprot.readStructEnd()
1312
 
1313
  def write(self, oprot):
1314
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1315
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1316
      return
1317
    oprot.writeStructBegin('getEmptyAWB_result')
3431 rajveer 1318
    if self.success is not None:
412 ashish 1319
      oprot.writeFieldBegin('success', TType.STRING, 0)
1320
      oprot.writeString(self.success)
1321
      oprot.writeFieldEnd()
3431 rajveer 1322
    if self.se is not None:
647 chandransh 1323
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1324
      self.se.write(oprot)
1325
      oprot.writeFieldEnd()
412 ashish 1326
    oprot.writeFieldStop()
1327
    oprot.writeStructEnd()
1328
 
3431 rajveer 1329
  def validate(self):
1330
    return
1331
 
1332
 
412 ashish 1333
  def __repr__(self):
1334
    L = ['%s=%r' % (key, value)
1335
      for key, value in self.__dict__.iteritems()]
1336
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1337
 
1338
  def __eq__(self, other):
1339
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1340
 
1341
  def __ne__(self, other):
1342
    return not (self == other)
1343
 
1344
class getShipmentInfo_args:
1345
  """
1346
  Attributes:
1347
   - awb
647 chandransh 1348
   - providerId
412 ashish 1349
  """
1350
 
1351
  thrift_spec = (
1352
    None, # 0
1353
    (1, TType.STRING, 'awb', None, None, ), # 1
647 chandransh 1354
    (2, TType.I64, 'providerId', None, None, ), # 2
412 ashish 1355
  )
1356
 
647 chandransh 1357
  def __init__(self, awb=None, providerId=None,):
412 ashish 1358
    self.awb = awb
647 chandransh 1359
    self.providerId = providerId
412 ashish 1360
 
1361
  def read(self, iprot):
1362
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1363
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1364
      return
1365
    iprot.readStructBegin()
1366
    while True:
1367
      (fname, ftype, fid) = iprot.readFieldBegin()
1368
      if ftype == TType.STOP:
1369
        break
1370
      if fid == 1:
1371
        if ftype == TType.STRING:
1372
          self.awb = iprot.readString();
1373
        else:
1374
          iprot.skip(ftype)
647 chandransh 1375
      elif fid == 2:
1376
        if ftype == TType.I64:
1377
          self.providerId = iprot.readI64();
1378
        else:
1379
          iprot.skip(ftype)
412 ashish 1380
      else:
1381
        iprot.skip(ftype)
1382
      iprot.readFieldEnd()
1383
    iprot.readStructEnd()
1384
 
1385
  def write(self, oprot):
1386
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1387
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1388
      return
1389
    oprot.writeStructBegin('getShipmentInfo_args')
3431 rajveer 1390
    if self.awb is not None:
412 ashish 1391
      oprot.writeFieldBegin('awb', TType.STRING, 1)
1392
      oprot.writeString(self.awb)
1393
      oprot.writeFieldEnd()
3431 rajveer 1394
    if self.providerId is not None:
647 chandransh 1395
      oprot.writeFieldBegin('providerId', TType.I64, 2)
1396
      oprot.writeI64(self.providerId)
1397
      oprot.writeFieldEnd()
412 ashish 1398
    oprot.writeFieldStop()
1399
    oprot.writeStructEnd()
1400
 
3431 rajveer 1401
  def validate(self):
1402
    return
1403
 
1404
 
412 ashish 1405
  def __repr__(self):
1406
    L = ['%s=%r' % (key, value)
1407
      for key, value in self.__dict__.iteritems()]
1408
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1409
 
1410
  def __eq__(self, other):
1411
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1412
 
1413
  def __ne__(self, other):
1414
    return not (self == other)
1415
 
1416
class getShipmentInfo_result:
1417
  """
1418
  Attributes:
1419
   - success
647 chandransh 1420
   - se
412 ashish 1421
  """
1422
 
1423
  thrift_spec = (
644 chandransh 1424
    (0, TType.LIST, 'success', (TType.STRUCT,(AwbUpdate, AwbUpdate.thrift_spec)), None, ), # 0
647 chandransh 1425
    (1, TType.STRUCT, 'se', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
412 ashish 1426
  )
1427
 
647 chandransh 1428
  def __init__(self, success=None, se=None,):
412 ashish 1429
    self.success = success
647 chandransh 1430
    self.se = se
412 ashish 1431
 
1432
  def read(self, iprot):
1433
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1434
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1435
      return
1436
    iprot.readStructBegin()
1437
    while True:
1438
      (fname, ftype, fid) = iprot.readFieldBegin()
1439
      if ftype == TType.STOP:
1440
        break
1441
      if fid == 0:
1442
        if ftype == TType.LIST:
1443
          self.success = []
3044 chandransh 1444
          (_etype19, _size16) = iprot.readListBegin()
1445
          for _i20 in xrange(_size16):
1446
            _elem21 = AwbUpdate()
1447
            _elem21.read(iprot)
1448
            self.success.append(_elem21)
412 ashish 1449
          iprot.readListEnd()
1450
        else:
1451
          iprot.skip(ftype)
647 chandransh 1452
      elif fid == 1:
1453
        if ftype == TType.STRUCT:
1454
          self.se = LogisticsServiceException()
1455
          self.se.read(iprot)
1456
        else:
1457
          iprot.skip(ftype)
412 ashish 1458
      else:
1459
        iprot.skip(ftype)
1460
      iprot.readFieldEnd()
1461
    iprot.readStructEnd()
1462
 
1463
  def write(self, oprot):
1464
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1465
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1466
      return
644 chandransh 1467
    oprot.writeStructBegin('getShipmentInfo_result')
3431 rajveer 1468
    if self.success is not None:
412 ashish 1469
      oprot.writeFieldBegin('success', TType.LIST, 0)
1470
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3044 chandransh 1471
      for iter22 in self.success:
1472
        iter22.write(oprot)
412 ashish 1473
      oprot.writeListEnd()
1474
      oprot.writeFieldEnd()
3431 rajveer 1475
    if self.se is not None:
647 chandransh 1476
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1477
      self.se.write(oprot)
1478
      oprot.writeFieldEnd()
412 ashish 1479
    oprot.writeFieldStop()
1480
    oprot.writeStructEnd()
1481
 
3431 rajveer 1482
  def validate(self):
1483
    return
1484
 
1485
 
412 ashish 1486
  def __repr__(self):
1487
    L = ['%s=%r' % (key, value)
1488
      for key, value in self.__dict__.iteritems()]
1489
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1490
 
1491
  def __eq__(self, other):
1492
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1493
 
1494
  def __ne__(self, other):
1495
    return not (self == other)
1496
 
732 chandransh 1497
class getDestinationCode_args:
1498
  """
1499
  Attributes:
1500
   - providerId
1501
   - pinCode
1502
  """
412 ashish 1503
 
732 chandransh 1504
  thrift_spec = (
1505
    None, # 0
1506
    (1, TType.I64, 'providerId', None, None, ), # 1
1507
    (2, TType.STRING, 'pinCode', None, None, ), # 2
1508
  )
1509
 
1510
  def __init__(self, providerId=None, pinCode=None,):
1511
    self.providerId = providerId
1512
    self.pinCode = pinCode
1513
 
1514
  def read(self, iprot):
1515
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1516
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1517
      return
1518
    iprot.readStructBegin()
1519
    while True:
1520
      (fname, ftype, fid) = iprot.readFieldBegin()
1521
      if ftype == TType.STOP:
1522
        break
1523
      if fid == 1:
1524
        if ftype == TType.I64:
1525
          self.providerId = iprot.readI64();
1526
        else:
1527
          iprot.skip(ftype)
1528
      elif fid == 2:
1529
        if ftype == TType.STRING:
1530
          self.pinCode = iprot.readString();
1531
        else:
1532
          iprot.skip(ftype)
1533
      else:
1534
        iprot.skip(ftype)
1535
      iprot.readFieldEnd()
1536
    iprot.readStructEnd()
1537
 
1538
  def write(self, oprot):
1539
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1540
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1541
      return
1542
    oprot.writeStructBegin('getDestinationCode_args')
3431 rajveer 1543
    if self.providerId is not None:
732 chandransh 1544
      oprot.writeFieldBegin('providerId', TType.I64, 1)
1545
      oprot.writeI64(self.providerId)
1546
      oprot.writeFieldEnd()
3431 rajveer 1547
    if self.pinCode is not None:
732 chandransh 1548
      oprot.writeFieldBegin('pinCode', TType.STRING, 2)
1549
      oprot.writeString(self.pinCode)
1550
      oprot.writeFieldEnd()
1551
    oprot.writeFieldStop()
1552
    oprot.writeStructEnd()
1553
 
3431 rajveer 1554
  def validate(self):
1555
    return
1556
 
1557
 
732 chandransh 1558
  def __repr__(self):
1559
    L = ['%s=%r' % (key, value)
1560
      for key, value in self.__dict__.iteritems()]
1561
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1562
 
1563
  def __eq__(self, other):
1564
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1565
 
1566
  def __ne__(self, other):
1567
    return not (self == other)
1568
 
1569
class getDestinationCode_result:
1570
  """
1571
  Attributes:
1572
   - success
1573
   - se
1574
  """
1575
 
1576
  thrift_spec = (
1577
    (0, TType.STRING, 'success', None, None, ), # 0
1578
    (1, TType.STRUCT, 'se', (LogisticsServiceException, LogisticsServiceException.thrift_spec), None, ), # 1
1579
  )
1580
 
1581
  def __init__(self, success=None, se=None,):
1582
    self.success = success
1583
    self.se = se
1584
 
1585
  def read(self, iprot):
1586
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1587
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1588
      return
1589
    iprot.readStructBegin()
1590
    while True:
1591
      (fname, ftype, fid) = iprot.readFieldBegin()
1592
      if ftype == TType.STOP:
1593
        break
1594
      if fid == 0:
1595
        if ftype == TType.STRING:
1596
          self.success = iprot.readString();
1597
        else:
1598
          iprot.skip(ftype)
1599
      elif fid == 1:
1600
        if ftype == TType.STRUCT:
1601
          self.se = LogisticsServiceException()
1602
          self.se.read(iprot)
1603
        else:
1604
          iprot.skip(ftype)
1605
      else:
1606
        iprot.skip(ftype)
1607
      iprot.readFieldEnd()
1608
    iprot.readStructEnd()
1609
 
1610
  def write(self, oprot):
1611
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1612
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1613
      return
1614
    oprot.writeStructBegin('getDestinationCode_result')
3431 rajveer 1615
    if self.success is not None:
732 chandransh 1616
      oprot.writeFieldBegin('success', TType.STRING, 0)
1617
      oprot.writeString(self.success)
1618
      oprot.writeFieldEnd()
3431 rajveer 1619
    if self.se is not None:
732 chandransh 1620
      oprot.writeFieldBegin('se', TType.STRUCT, 1)
1621
      self.se.write(oprot)
1622
      oprot.writeFieldEnd()
1623
    oprot.writeFieldStop()
1624
    oprot.writeStructEnd()
1625
 
3431 rajveer 1626
  def validate(self):
1627
    return
1628
 
1629
 
732 chandransh 1630
  def __repr__(self):
1631
    L = ['%s=%r' % (key, value)
1632
      for key, value in self.__dict__.iteritems()]
1633
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1634
 
1635
  def __eq__(self, other):
1636
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1637
 
1638
  def __ne__(self, other):
1639
    return not (self == other)
1640
 
1137 chandransh 1641
class getFreeAwbCount_args:
1642
  """
1643
  Attributes:
1644
   - providerId
3103 chandransh 1645
   - type
1137 chandransh 1646
  """
732 chandransh 1647
 
1137 chandransh 1648
  thrift_spec = (
1649
    None, # 0
1650
    (1, TType.I64, 'providerId', None, None, ), # 1
3103 chandransh 1651
    (2, TType.STRING, 'type', None, None, ), # 2
1137 chandransh 1652
  )
1653
 
3103 chandransh 1654
  def __init__(self, providerId=None, type=None,):
1137 chandransh 1655
    self.providerId = providerId
3103 chandransh 1656
    self.type = type
1137 chandransh 1657
 
1658
  def read(self, iprot):
1659
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1660
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1661
      return
1662
    iprot.readStructBegin()
1663
    while True:
1664
      (fname, ftype, fid) = iprot.readFieldBegin()
1665
      if ftype == TType.STOP:
1666
        break
1667
      if fid == 1:
1668
        if ftype == TType.I64:
1669
          self.providerId = iprot.readI64();
1670
        else:
1671
          iprot.skip(ftype)
3103 chandransh 1672
      elif fid == 2:
1673
        if ftype == TType.STRING:
1674
          self.type = iprot.readString();
1675
        else:
1676
          iprot.skip(ftype)
1137 chandransh 1677
      else:
1678
        iprot.skip(ftype)
1679
      iprot.readFieldEnd()
1680
    iprot.readStructEnd()
1681
 
1682
  def write(self, oprot):
1683
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1684
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1685
      return
1686
    oprot.writeStructBegin('getFreeAwbCount_args')
3431 rajveer 1687
    if self.providerId is not None:
1137 chandransh 1688
      oprot.writeFieldBegin('providerId', TType.I64, 1)
1689
      oprot.writeI64(self.providerId)
1690
      oprot.writeFieldEnd()
3431 rajveer 1691
    if self.type is not None:
3103 chandransh 1692
      oprot.writeFieldBegin('type', TType.STRING, 2)
1693
      oprot.writeString(self.type)
1694
      oprot.writeFieldEnd()
1137 chandransh 1695
    oprot.writeFieldStop()
1696
    oprot.writeStructEnd()
1697
 
3431 rajveer 1698
  def validate(self):
1699
    return
1700
 
1701
 
1137 chandransh 1702
  def __repr__(self):
1703
    L = ['%s=%r' % (key, value)
1704
      for key, value in self.__dict__.iteritems()]
1705
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1706
 
1707
  def __eq__(self, other):
1708
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1709
 
1710
  def __ne__(self, other):
1711
    return not (self == other)
1712
 
1713
class getFreeAwbCount_result:
1714
  """
1715
  Attributes:
1716
   - success
1717
  """
1718
 
1719
  thrift_spec = (
1720
    (0, TType.I64, 'success', None, None, ), # 0
1721
  )
1722
 
1723
  def __init__(self, success=None,):
1724
    self.success = success
1725
 
1726
  def read(self, iprot):
1727
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1728
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1729
      return
1730
    iprot.readStructBegin()
1731
    while True:
1732
      (fname, ftype, fid) = iprot.readFieldBegin()
1733
      if ftype == TType.STOP:
1734
        break
1735
      if fid == 0:
1736
        if ftype == TType.I64:
1737
          self.success = iprot.readI64();
1738
        else:
1739
          iprot.skip(ftype)
1740
      else:
1741
        iprot.skip(ftype)
1742
      iprot.readFieldEnd()
1743
    iprot.readStructEnd()
1744
 
1745
  def write(self, oprot):
1746
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1747
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1748
      return
1749
    oprot.writeStructBegin('getFreeAwbCount_result')
3431 rajveer 1750
    if self.success is not None:
1137 chandransh 1751
      oprot.writeFieldBegin('success', TType.I64, 0)
1752
      oprot.writeI64(self.success)
1753
      oprot.writeFieldEnd()
1754
    oprot.writeFieldStop()
1755
    oprot.writeStructEnd()
1756
 
3431 rajveer 1757
  def validate(self):
1758
    return
1759
 
1760
 
1137 chandransh 1761
  def __repr__(self):
1762
    L = ['%s=%r' % (key, value)
1763
      for key, value in self.__dict__.iteritems()]
1764
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1765
 
1766
  def __eq__(self, other):
1767
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1768
 
1769
  def __ne__(self, other):
1770
    return not (self == other)
1771
 
1730 ankur.sing 1772
class getHolidays_args:
1773
  """
1774
  Attributes:
1775
   - fromDate
1776
   - toDate
1777
  """
1137 chandransh 1778
 
1730 ankur.sing 1779
  thrift_spec = (
1780
    None, # 0
1781
    (1, TType.I64, 'fromDate', None, None, ), # 1
1782
    (2, TType.I64, 'toDate', None, None, ), # 2
1783
  )
1784
 
1785
  def __init__(self, fromDate=None, toDate=None,):
1786
    self.fromDate = fromDate
1787
    self.toDate = toDate
1788
 
1789
  def read(self, iprot):
1790
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1791
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1792
      return
1793
    iprot.readStructBegin()
1794
    while True:
1795
      (fname, ftype, fid) = iprot.readFieldBegin()
1796
      if ftype == TType.STOP:
1797
        break
1798
      if fid == 1:
1799
        if ftype == TType.I64:
1800
          self.fromDate = iprot.readI64();
1801
        else:
1802
          iprot.skip(ftype)
1803
      elif fid == 2:
1804
        if ftype == TType.I64:
1805
          self.toDate = iprot.readI64();
1806
        else:
1807
          iprot.skip(ftype)
1808
      else:
1809
        iprot.skip(ftype)
1810
      iprot.readFieldEnd()
1811
    iprot.readStructEnd()
1812
 
1813
  def write(self, oprot):
1814
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1815
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1816
      return
1817
    oprot.writeStructBegin('getHolidays_args')
3431 rajveer 1818
    if self.fromDate is not None:
1730 ankur.sing 1819
      oprot.writeFieldBegin('fromDate', TType.I64, 1)
1820
      oprot.writeI64(self.fromDate)
1821
      oprot.writeFieldEnd()
3431 rajveer 1822
    if self.toDate is not None:
1730 ankur.sing 1823
      oprot.writeFieldBegin('toDate', TType.I64, 2)
1824
      oprot.writeI64(self.toDate)
1825
      oprot.writeFieldEnd()
1826
    oprot.writeFieldStop()
1827
    oprot.writeStructEnd()
1828
 
3431 rajveer 1829
  def validate(self):
1830
    return
1831
 
1832
 
1730 ankur.sing 1833
  def __repr__(self):
1834
    L = ['%s=%r' % (key, value)
1835
      for key, value in self.__dict__.iteritems()]
1836
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1837
 
1838
  def __eq__(self, other):
1839
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1840
 
1841
  def __ne__(self, other):
1842
    return not (self == other)
1843
 
1844
class getHolidays_result:
1845
  """
1846
  Attributes:
1847
   - success
1848
  """
1849
 
1850
  thrift_spec = (
1851
    (0, TType.LIST, 'success', (TType.I64,None), None, ), # 0
1852
  )
1853
 
1854
  def __init__(self, success=None,):
1855
    self.success = success
1856
 
1857
  def read(self, iprot):
1858
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1859
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1860
      return
1861
    iprot.readStructBegin()
1862
    while True:
1863
      (fname, ftype, fid) = iprot.readFieldBegin()
1864
      if ftype == TType.STOP:
1865
        break
1866
      if fid == 0:
1867
        if ftype == TType.LIST:
1868
          self.success = []
3044 chandransh 1869
          (_etype26, _size23) = iprot.readListBegin()
1870
          for _i27 in xrange(_size23):
1871
            _elem28 = iprot.readI64();
1872
            self.success.append(_elem28)
1730 ankur.sing 1873
          iprot.readListEnd()
1874
        else:
1875
          iprot.skip(ftype)
1876
      else:
1877
        iprot.skip(ftype)
1878
      iprot.readFieldEnd()
1879
    iprot.readStructEnd()
1880
 
1881
  def write(self, oprot):
1882
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1883
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1884
      return
1885
    oprot.writeStructBegin('getHolidays_result')
3431 rajveer 1886
    if self.success is not None:
1730 ankur.sing 1887
      oprot.writeFieldBegin('success', TType.LIST, 0)
1888
      oprot.writeListBegin(TType.I64, len(self.success))
3044 chandransh 1889
      for iter29 in self.success:
1890
        oprot.writeI64(iter29)
1730 ankur.sing 1891
      oprot.writeListEnd()
1892
      oprot.writeFieldEnd()
1893
    oprot.writeFieldStop()
1894
    oprot.writeStructEnd()
1895
 
3431 rajveer 1896
  def validate(self):
1897
    return
1898
 
1899
 
1730 ankur.sing 1900
  def __repr__(self):
1901
    L = ['%s=%r' % (key, value)
1902
      for key, value in self.__dict__.iteritems()]
1903
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1904
 
1905
  def __eq__(self, other):
1906
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1907
 
1908
  def __ne__(self, other):
1909
    return not (self == other)
1910
 
3064 chandransh 1911
class isCodAllowed_args:
1912
  """
1913
  Attributes:
1914
   - destination_pincode
1915
  """
1730 ankur.sing 1916
 
3064 chandransh 1917
  thrift_spec = (
1918
    None, # 0
1919
    (1, TType.STRING, 'destination_pincode', None, None, ), # 1
1920
  )
1921
 
1922
  def __init__(self, destination_pincode=None,):
1923
    self.destination_pincode = destination_pincode
1924
 
1925
  def read(self, iprot):
1926
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1927
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1928
      return
1929
    iprot.readStructBegin()
1930
    while True:
1931
      (fname, ftype, fid) = iprot.readFieldBegin()
1932
      if ftype == TType.STOP:
1933
        break
1934
      if fid == 1:
1935
        if ftype == TType.STRING:
1936
          self.destination_pincode = iprot.readString();
1937
        else:
1938
          iprot.skip(ftype)
1939
      else:
1940
        iprot.skip(ftype)
1941
      iprot.readFieldEnd()
1942
    iprot.readStructEnd()
1943
 
1944
  def write(self, oprot):
1945
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
1946
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
1947
      return
1948
    oprot.writeStructBegin('isCodAllowed_args')
3431 rajveer 1949
    if self.destination_pincode is not None:
3064 chandransh 1950
      oprot.writeFieldBegin('destination_pincode', TType.STRING, 1)
1951
      oprot.writeString(self.destination_pincode)
1952
      oprot.writeFieldEnd()
1953
    oprot.writeFieldStop()
1954
    oprot.writeStructEnd()
1955
 
3431 rajveer 1956
  def validate(self):
1957
    return
1958
 
1959
 
3064 chandransh 1960
  def __repr__(self):
1961
    L = ['%s=%r' % (key, value)
1962
      for key, value in self.__dict__.iteritems()]
1963
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
1964
 
1965
  def __eq__(self, other):
1966
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
1967
 
1968
  def __ne__(self, other):
1969
    return not (self == other)
1970
 
1971
class isCodAllowed_result:
1972
  """
1973
  Attributes:
1974
   - success
1975
  """
1976
 
1977
  thrift_spec = (
1978
    (0, TType.BOOL, 'success', None, None, ), # 0
1979
  )
1980
 
1981
  def __init__(self, success=None,):
1982
    self.success = success
1983
 
1984
  def read(self, iprot):
1985
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1986
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1987
      return
1988
    iprot.readStructBegin()
1989
    while True:
1990
      (fname, ftype, fid) = iprot.readFieldBegin()
1991
      if ftype == TType.STOP:
1992
        break
1993
      if fid == 0:
1994
        if ftype == TType.BOOL:
1995
          self.success = iprot.readBool();
1996
        else:
1997
          iprot.skip(ftype)
1998
      else:
1999
        iprot.skip(ftype)
2000
      iprot.readFieldEnd()
2001
    iprot.readStructEnd()
2002
 
2003
  def write(self, oprot):
2004
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2005
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2006
      return
2007
    oprot.writeStructBegin('isCodAllowed_result')
3431 rajveer 2008
    if self.success is not None:
3064 chandransh 2009
      oprot.writeFieldBegin('success', TType.BOOL, 0)
2010
      oprot.writeBool(self.success)
2011
      oprot.writeFieldEnd()
2012
    oprot.writeFieldStop()
2013
    oprot.writeStructEnd()
2014
 
3431 rajveer 2015
  def validate(self):
2016
    return
2017
 
2018
 
3064 chandransh 2019
  def __repr__(self):
2020
    L = ['%s=%r' % (key, value)
2021
      for key, value in self.__dict__.iteritems()]
2022
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2023
 
2024
  def __eq__(self, other):
2025
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2026
 
2027
  def __ne__(self, other):
2028
    return not (self == other)