Subversion Repositories SmartDukaan

Rev

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

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