Subversion Repositories SmartDukaan

Rev

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

Rev Author Line No. Line
94 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
 
94 ashish 25
  def createTransaction(self, transaction):
26
    """
27
    Parameters:
28
     - transaction
29
    """
30
    pass
31
 
32
  def getTransaction(self, id):
33
    """
34
    Parameters:
35
     - id
36
    """
37
    pass
38
 
39
  def getTransactionsForCustomer(self, customerId, from_date, to_date, status):
40
    """
41
    Parameters:
42
     - customerId
43
     - from_date
44
     - to_date
45
     - status
46
    """
47
    pass
48
 
132 ashish 49
  def getTransactionsForShoppingCartId(self, shoppingCartId):
50
    """
51
    Parameters:
52
     - shoppingCartId
53
    """
54
    pass
55
 
94 ashish 56
  def getTransactionStatus(self, transactionId):
57
    """
58
    Parameters:
59
     - transactionId
60
    """
61
    pass
62
 
63
  def changeTransactionStatus(self, transactionId, status, description):
64
    """
65
    Parameters:
66
     - transactionId
67
     - status
68
     - description
69
    """
70
    pass
71
 
1398 varun.gupt 72
  def enqueueTransactionInfoEmail(self, transactionId):
1382 varun.gupt 73
    """
74
    Parameters:
75
     - transactionId
76
    """
77
    pass
78
 
483 rajveer 79
  def getAllOrders(self, status, from_date, to_date, warehouse_id):
94 ashish 80
    """
81
    Parameters:
483 rajveer 82
     - status
83
     - from_date
84
     - to_date
85
     - warehouse_id
94 ashish 86
    """
87
    pass
88
 
999 varun.gupt 89
  def getOrdersByBillingDate(self, status, start_billing_date, end_billing_date, warehouse_id):
90
    """
1132 chandransh 91
    Returns orders within a range of their billing dates
92
 
999 varun.gupt 93
    Parameters:
94
     - status
95
     - start_billing_date
96
     - end_billing_date
97
     - warehouse_id
98
    """
99
    pass
100
 
1382 varun.gupt 101
  def getReturnableOrdersForCustomer(self, customer_id, limit):
102
    """
103
    Returns order ids for orders which can be returned
104
 
105
    Parameters:
106
     - customer_id
107
     - limit
108
    """
109
    pass
110
 
111
  def getCancellableOrdersForCustomer(self, customer_id, limit):
112
    """
113
    Returns order ids for orders which can be cancelled
114
 
115
    Parameters:
116
     - customer_id
117
     - limit
118
    """
119
    pass
120
 
483 rajveer 121
  def changeOrderStatus(self, orderId, status, description):
94 ashish 122
    """
123
    Parameters:
483 rajveer 124
     - orderId
125
     - status
126
     - description
94 ashish 127
    """
128
    pass
129
 
1149 chandransh 130
  def addBillingDetails(self, orderId, invoice_number, billed_by):
494 rajveer 131
    """
1149 chandransh 132
    Add billing details such as the bill number and the biller to the Order.
133
 
494 rajveer 134
    Parameters:
135
     - orderId
136
     - invoice_number
137
     - billed_by
138
    """
139
    pass
140
 
1149 chandransh 141
  def addJacketNumber(self, orderId, jacketNumber):
142
    """
143
    Adds jacket number to the order. Return false if it doesn't find the order with the given ID.
144
 
145
    Parameters:
146
     - orderId
147
     - jacketNumber
148
    """
149
    pass
150
 
921 rajveer 151
  def acceptOrder(self, orderId):
152
    """
153
    Parameters:
154
     - orderId
155
    """
156
    pass
157
 
158
  def billOrder(self, orderId):
159
    """
160
    Parameters:
161
     - orderId
162
    """
163
    pass
164
 
1528 ankur.sing 165
  def getOrdersForTransaction(self, transactionId, customerId):
94 ashish 166
    """
1528 ankur.sing 167
    Returns list of orders for given transaction Id. Also filters based on customer Id so that
168
    only user who owns the transaction can view its order details.
169
 
94 ashish 170
    Parameters:
171
     - transactionId
1528 ankur.sing 172
     - customerId
94 ashish 173
    """
174
    pass
175
 
483 rajveer 176
  def getOrdersForCustomer(self, customerId, from_date, to_date, status):
94 ashish 177
    """
178
    Parameters:
483 rajveer 179
     - customerId
180
     - from_date
181
     - to_date
182
     - status
94 ashish 183
    """
184
    pass
185
 
483 rajveer 186
  def createOrder(self, order):
94 ashish 187
    """
188
    Parameters:
483 rajveer 189
     - order
94 ashish 190
    """
191
    pass
192
 
483 rajveer 193
  def getOrder(self, id):
94 ashish 194
    """
195
    Parameters:
483 rajveer 196
     - id
94 ashish 197
    """
198
    pass
199
 
483 rajveer 200
  def getLineItemsForOrder(self, orderId):
94 ashish 201
    """
202
    Parameters:
483 rajveer 203
     - orderId
94 ashish 204
    """
205
    pass
206
 
1528 ankur.sing 207
  def getOrderForCustomer(self, orderId, customerId):
208
    """
209
    Returns an order for the order Id. Also checks if the order belongs to the customer whose Id is passed.
210
    Throws exception if either order Id is invalid or order does not below to the customer whose Id is passed.
211
 
212
    Parameters:
213
     - orderId
214
     - customerId
215
    """
216
    pass
217
 
1220 chandransh 218
  def batchOrders(self, warehouseId):
219
    """
220
    Create a batch of all the pending orders for the given warehouse.
221
    The returned list is orderd by created_timestamp.
222
    If there are no pending orders, an empty list is returned.
223
 
224
    Parameters:
225
     - warehouseId
226
    """
227
    pass
228
 
1208 chandransh 229
  def markOrderAsOutOfStock(self, orderId):
230
    """
231
    Mark the given order as out of stock. Throws an exception if the order with the given Id couldn't be found.
232
 
233
    Parameters:
234
     - orderId
235
    """
236
    pass
237
 
759 chandransh 238
  def markOrdersAsManifested(self, warehouseId, providerId):
239
    """
240
    Marks all BILLED orders for a warehouse and a provider as SHIPPED_FROM_WH
241
 
242
    Parameters:
243
     - warehouseId
244
     - providerId
245
    """
246
    pass
247
 
1113 chandransh 248
  def markOrdersAsPickedUp(self, providerId, pickupDetails):
249
    """
250
    Marks all SHIPPED_FROM_WH orders of the previous day for a provider as SHIPPED_TO_LOGISTICS.
251
    Returns a list of orders that were shipped from warehouse but did not appear in the pick-up report.
252
    Raises an exception if we encounter report for an AWB number that we did not ship.
253
 
254
    Parameters:
255
     - providerId
256
     - pickupDetails
257
    """
258
    pass
259
 
1132 chandransh 260
  def markOrdersAsDelivered(self, providerId, deliveredOrders):
261
    """
262
    Marks all orders with AWBs in the given map as delivered. Also sets the delivery timestamp and
263
    the name of the receiver.
264
    Raises an exception if we encounter report for an AWB number that we did not ship.
265
 
266
    Parameters:
267
     - providerId
268
     - deliveredOrders
269
    """
270
    pass
271
 
1135 chandransh 272
  def markOrdersAsFailed(self, providerId, returnedOrders):
273
    """
274
    Mark all orders with AWBs in the given map as failed. Also sets the delivery timestamp.
275
    Raises an exception if we encounter report for an AWB number that we did not ship.
276
 
277
    Parameters:
278
     - providerId
279
     - returnedOrders
280
    """
281
    pass
282
 
1246 chandransh 283
  def updateNonDeliveryReason(self, providerId, undeliveredOrders):
284
    """
285
    Update the status description of orders whose AWB numbers are keys of the Map.
286
 
287
    Parameters:
288
     - providerId
289
     - undeliveredOrders
290
    """
291
    pass
292
 
1408 ankur.sing 293
  def getUndeliveredOrders(self, providerId, warehouseId):
294
    """
295
    Returns the list of orders whose delivery time has passed but have not been
296
    delivered yet for the given provider and warehouse. To get a complete list of
297
    undelivered orders, pass them as -1.
298
    Returns an empty list if no such orders exist.
299
 
300
    Parameters:
301
     - providerId
302
     - warehouseId
303
    """
304
    pass
305
 
483 rajveer 306
  def getAlerts(self, orderId, valid):
94 ashish 307
    """
308
    Parameters:
483 rajveer 309
     - orderId
304 ashish 310
     - valid
311
    """
312
    pass
94 ashish 313
 
483 rajveer 314
  def setAlert(self, orderId, unset, type, comment):
304 ashish 315
    """
316
    Parameters:
483 rajveer 317
     - orderId
304 ashish 318
     - unset
319
     - type
320
     - comment
321
    """
322
    pass
323
 
324
 
94 ashish 325
class Client(Iface):
326
  def __init__(self, iprot, oprot=None):
327
    self._iprot = self._oprot = iprot
328
    if oprot != None:
329
      self._oprot = oprot
330
    self._seqid = 0
331
 
765 rajveer 332
  def closeSession(self, ):
333
    """
334
    For closing the open session in sqlalchemy
335
    """
336
    self.send_closeSession()
337
    self.recv_closeSession()
338
 
339
  def send_closeSession(self, ):
340
    self._oprot.writeMessageBegin('closeSession', TMessageType.CALL, self._seqid)
341
    args = closeSession_args()
342
    args.write(self._oprot)
343
    self._oprot.writeMessageEnd()
344
    self._oprot.trans.flush()
345
 
346
  def recv_closeSession(self, ):
347
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
348
    if mtype == TMessageType.EXCEPTION:
349
      x = TApplicationException()
350
      x.read(self._iprot)
351
      self._iprot.readMessageEnd()
352
      raise x
353
    result = closeSession_result()
354
    result.read(self._iprot)
355
    self._iprot.readMessageEnd()
356
    return
357
 
94 ashish 358
  def createTransaction(self, transaction):
359
    """
360
    Parameters:
361
     - transaction
362
    """
363
    self.send_createTransaction(transaction)
132 ashish 364
    return self.recv_createTransaction()
94 ashish 365
 
366
  def send_createTransaction(self, transaction):
367
    self._oprot.writeMessageBegin('createTransaction', TMessageType.CALL, self._seqid)
368
    args = createTransaction_args()
369
    args.transaction = transaction
370
    args.write(self._oprot)
371
    self._oprot.writeMessageEnd()
372
    self._oprot.trans.flush()
373
 
374
  def recv_createTransaction(self, ):
375
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
376
    if mtype == TMessageType.EXCEPTION:
377
      x = TApplicationException()
378
      x.read(self._iprot)
379
      self._iprot.readMessageEnd()
380
      raise x
381
    result = createTransaction_result()
382
    result.read(self._iprot)
383
    self._iprot.readMessageEnd()
132 ashish 384
    if result.success != None:
385
      return result.success
94 ashish 386
    if result.ex != None:
387
      raise result.ex
132 ashish 388
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createTransaction failed: unknown result");
94 ashish 389
 
390
  def getTransaction(self, id):
391
    """
392
    Parameters:
393
     - id
394
    """
395
    self.send_getTransaction(id)
396
    return self.recv_getTransaction()
397
 
398
  def send_getTransaction(self, id):
399
    self._oprot.writeMessageBegin('getTransaction', TMessageType.CALL, self._seqid)
400
    args = getTransaction_args()
401
    args.id = id
402
    args.write(self._oprot)
403
    self._oprot.writeMessageEnd()
404
    self._oprot.trans.flush()
405
 
406
  def recv_getTransaction(self, ):
407
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
408
    if mtype == TMessageType.EXCEPTION:
409
      x = TApplicationException()
410
      x.read(self._iprot)
411
      self._iprot.readMessageEnd()
412
      raise x
413
    result = getTransaction_result()
414
    result.read(self._iprot)
415
    self._iprot.readMessageEnd()
416
    if result.success != None:
417
      return result.success
418
    if result.ex != None:
419
      raise result.ex
420
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTransaction failed: unknown result");
421
 
422
  def getTransactionsForCustomer(self, customerId, from_date, to_date, status):
423
    """
424
    Parameters:
425
     - customerId
426
     - from_date
427
     - to_date
428
     - status
429
    """
430
    self.send_getTransactionsForCustomer(customerId, from_date, to_date, status)
431
    return self.recv_getTransactionsForCustomer()
432
 
433
  def send_getTransactionsForCustomer(self, customerId, from_date, to_date, status):
434
    self._oprot.writeMessageBegin('getTransactionsForCustomer', TMessageType.CALL, self._seqid)
435
    args = getTransactionsForCustomer_args()
436
    args.customerId = customerId
437
    args.from_date = from_date
438
    args.to_date = to_date
439
    args.status = status
440
    args.write(self._oprot)
441
    self._oprot.writeMessageEnd()
442
    self._oprot.trans.flush()
443
 
444
  def recv_getTransactionsForCustomer(self, ):
445
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
446
    if mtype == TMessageType.EXCEPTION:
447
      x = TApplicationException()
448
      x.read(self._iprot)
449
      self._iprot.readMessageEnd()
450
      raise x
451
    result = getTransactionsForCustomer_result()
452
    result.read(self._iprot)
453
    self._iprot.readMessageEnd()
454
    if result.success != None:
455
      return result.success
456
    if result.ex != None:
457
      raise result.ex
458
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTransactionsForCustomer failed: unknown result");
459
 
132 ashish 460
  def getTransactionsForShoppingCartId(self, shoppingCartId):
461
    """
462
    Parameters:
463
     - shoppingCartId
464
    """
465
    self.send_getTransactionsForShoppingCartId(shoppingCartId)
466
    return self.recv_getTransactionsForShoppingCartId()
467
 
468
  def send_getTransactionsForShoppingCartId(self, shoppingCartId):
469
    self._oprot.writeMessageBegin('getTransactionsForShoppingCartId', TMessageType.CALL, self._seqid)
470
    args = getTransactionsForShoppingCartId_args()
471
    args.shoppingCartId = shoppingCartId
472
    args.write(self._oprot)
473
    self._oprot.writeMessageEnd()
474
    self._oprot.trans.flush()
475
 
476
  def recv_getTransactionsForShoppingCartId(self, ):
477
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
478
    if mtype == TMessageType.EXCEPTION:
479
      x = TApplicationException()
480
      x.read(self._iprot)
481
      self._iprot.readMessageEnd()
482
      raise x
483
    result = getTransactionsForShoppingCartId_result()
484
    result.read(self._iprot)
485
    self._iprot.readMessageEnd()
486
    if result.success != None:
487
      return result.success
488
    if result.ex != None:
489
      raise result.ex
490
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTransactionsForShoppingCartId failed: unknown result");
491
 
94 ashish 492
  def getTransactionStatus(self, transactionId):
493
    """
494
    Parameters:
495
     - transactionId
496
    """
497
    self.send_getTransactionStatus(transactionId)
498
    return self.recv_getTransactionStatus()
499
 
500
  def send_getTransactionStatus(self, transactionId):
501
    self._oprot.writeMessageBegin('getTransactionStatus', TMessageType.CALL, self._seqid)
502
    args = getTransactionStatus_args()
503
    args.transactionId = transactionId
504
    args.write(self._oprot)
505
    self._oprot.writeMessageEnd()
506
    self._oprot.trans.flush()
507
 
508
  def recv_getTransactionStatus(self, ):
509
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
510
    if mtype == TMessageType.EXCEPTION:
511
      x = TApplicationException()
512
      x.read(self._iprot)
513
      self._iprot.readMessageEnd()
514
      raise x
515
    result = getTransactionStatus_result()
516
    result.read(self._iprot)
517
    self._iprot.readMessageEnd()
518
    if result.success != None:
519
      return result.success
520
    if result.ex != None:
521
      raise result.ex
522
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getTransactionStatus failed: unknown result");
523
 
524
  def changeTransactionStatus(self, transactionId, status, description):
525
    """
526
    Parameters:
527
     - transactionId
528
     - status
529
     - description
530
    """
531
    self.send_changeTransactionStatus(transactionId, status, description)
532
    return self.recv_changeTransactionStatus()
533
 
534
  def send_changeTransactionStatus(self, transactionId, status, description):
535
    self._oprot.writeMessageBegin('changeTransactionStatus', TMessageType.CALL, self._seqid)
536
    args = changeTransactionStatus_args()
537
    args.transactionId = transactionId
538
    args.status = status
539
    args.description = description
540
    args.write(self._oprot)
541
    self._oprot.writeMessageEnd()
542
    self._oprot.trans.flush()
543
 
544
  def recv_changeTransactionStatus(self, ):
545
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
546
    if mtype == TMessageType.EXCEPTION:
547
      x = TApplicationException()
548
      x.read(self._iprot)
549
      self._iprot.readMessageEnd()
550
      raise x
551
    result = changeTransactionStatus_result()
552
    result.read(self._iprot)
553
    self._iprot.readMessageEnd()
554
    if result.success != None:
555
      return result.success
556
    if result.ex != None:
557
      raise result.ex
558
    raise TApplicationException(TApplicationException.MISSING_RESULT, "changeTransactionStatus failed: unknown result");
559
 
1398 varun.gupt 560
  def enqueueTransactionInfoEmail(self, transactionId):
1382 varun.gupt 561
    """
562
    Parameters:
563
     - transactionId
564
    """
1398 varun.gupt 565
    self.send_enqueueTransactionInfoEmail(transactionId)
566
    return self.recv_enqueueTransactionInfoEmail()
1382 varun.gupt 567
 
1398 varun.gupt 568
  def send_enqueueTransactionInfoEmail(self, transactionId):
569
    self._oprot.writeMessageBegin('enqueueTransactionInfoEmail', TMessageType.CALL, self._seqid)
570
    args = enqueueTransactionInfoEmail_args()
1382 varun.gupt 571
    args.transactionId = transactionId
572
    args.write(self._oprot)
573
    self._oprot.writeMessageEnd()
574
    self._oprot.trans.flush()
575
 
1398 varun.gupt 576
  def recv_enqueueTransactionInfoEmail(self, ):
1382 varun.gupt 577
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
578
    if mtype == TMessageType.EXCEPTION:
579
      x = TApplicationException()
580
      x.read(self._iprot)
581
      self._iprot.readMessageEnd()
582
      raise x
1398 varun.gupt 583
    result = enqueueTransactionInfoEmail_result()
1382 varun.gupt 584
    result.read(self._iprot)
585
    self._iprot.readMessageEnd()
586
    if result.success != None:
587
      return result.success
588
    if result.ex != None:
589
      raise result.ex
1398 varun.gupt 590
    raise TApplicationException(TApplicationException.MISSING_RESULT, "enqueueTransactionInfoEmail failed: unknown result");
1382 varun.gupt 591
 
483 rajveer 592
  def getAllOrders(self, status, from_date, to_date, warehouse_id):
94 ashish 593
    """
594
    Parameters:
483 rajveer 595
     - status
596
     - from_date
597
     - to_date
598
     - warehouse_id
94 ashish 599
    """
483 rajveer 600
    self.send_getAllOrders(status, from_date, to_date, warehouse_id)
601
    return self.recv_getAllOrders()
94 ashish 602
 
483 rajveer 603
  def send_getAllOrders(self, status, from_date, to_date, warehouse_id):
604
    self._oprot.writeMessageBegin('getAllOrders', TMessageType.CALL, self._seqid)
605
    args = getAllOrders_args()
606
    args.status = status
607
    args.from_date = from_date
608
    args.to_date = to_date
609
    args.warehouse_id = warehouse_id
94 ashish 610
    args.write(self._oprot)
611
    self._oprot.writeMessageEnd()
612
    self._oprot.trans.flush()
613
 
483 rajveer 614
  def recv_getAllOrders(self, ):
94 ashish 615
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
616
    if mtype == TMessageType.EXCEPTION:
617
      x = TApplicationException()
618
      x.read(self._iprot)
619
      self._iprot.readMessageEnd()
620
      raise x
483 rajveer 621
    result = getAllOrders_result()
94 ashish 622
    result.read(self._iprot)
623
    self._iprot.readMessageEnd()
624
    if result.success != None:
625
      return result.success
626
    if result.ex != None:
627
      raise result.ex
483 rajveer 628
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAllOrders failed: unknown result");
94 ashish 629
 
999 varun.gupt 630
  def getOrdersByBillingDate(self, status, start_billing_date, end_billing_date, warehouse_id):
631
    """
1132 chandransh 632
    Returns orders within a range of their billing dates
633
 
999 varun.gupt 634
    Parameters:
635
     - status
636
     - start_billing_date
637
     - end_billing_date
638
     - warehouse_id
639
    """
640
    self.send_getOrdersByBillingDate(status, start_billing_date, end_billing_date, warehouse_id)
641
    return self.recv_getOrdersByBillingDate()
642
 
643
  def send_getOrdersByBillingDate(self, status, start_billing_date, end_billing_date, warehouse_id):
644
    self._oprot.writeMessageBegin('getOrdersByBillingDate', TMessageType.CALL, self._seqid)
645
    args = getOrdersByBillingDate_args()
646
    args.status = status
647
    args.start_billing_date = start_billing_date
648
    args.end_billing_date = end_billing_date
649
    args.warehouse_id = warehouse_id
650
    args.write(self._oprot)
651
    self._oprot.writeMessageEnd()
652
    self._oprot.trans.flush()
653
 
654
  def recv_getOrdersByBillingDate(self, ):
655
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
656
    if mtype == TMessageType.EXCEPTION:
657
      x = TApplicationException()
658
      x.read(self._iprot)
659
      self._iprot.readMessageEnd()
660
      raise x
661
    result = getOrdersByBillingDate_result()
662
    result.read(self._iprot)
663
    self._iprot.readMessageEnd()
664
    if result.success != None:
665
      return result.success
666
    if result.ex != None:
667
      raise result.ex
668
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrdersByBillingDate failed: unknown result");
669
 
1382 varun.gupt 670
  def getReturnableOrdersForCustomer(self, customer_id, limit):
671
    """
672
    Returns order ids for orders which can be returned
673
 
674
    Parameters:
675
     - customer_id
676
     - limit
677
    """
678
    self.send_getReturnableOrdersForCustomer(customer_id, limit)
679
    return self.recv_getReturnableOrdersForCustomer()
680
 
681
  def send_getReturnableOrdersForCustomer(self, customer_id, limit):
682
    self._oprot.writeMessageBegin('getReturnableOrdersForCustomer', TMessageType.CALL, self._seqid)
683
    args = getReturnableOrdersForCustomer_args()
684
    args.customer_id = customer_id
685
    args.limit = limit
686
    args.write(self._oprot)
687
    self._oprot.writeMessageEnd()
688
    self._oprot.trans.flush()
689
 
690
  def recv_getReturnableOrdersForCustomer(self, ):
691
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
692
    if mtype == TMessageType.EXCEPTION:
693
      x = TApplicationException()
694
      x.read(self._iprot)
695
      self._iprot.readMessageEnd()
696
      raise x
697
    result = getReturnableOrdersForCustomer_result()
698
    result.read(self._iprot)
699
    self._iprot.readMessageEnd()
700
    if result.success != None:
701
      return result.success
702
    if result.ex != None:
703
      raise result.ex
704
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getReturnableOrdersForCustomer failed: unknown result");
705
 
706
  def getCancellableOrdersForCustomer(self, customer_id, limit):
707
    """
708
    Returns order ids for orders which can be cancelled
709
 
710
    Parameters:
711
     - customer_id
712
     - limit
713
    """
714
    self.send_getCancellableOrdersForCustomer(customer_id, limit)
715
    return self.recv_getCancellableOrdersForCustomer()
716
 
717
  def send_getCancellableOrdersForCustomer(self, customer_id, limit):
718
    self._oprot.writeMessageBegin('getCancellableOrdersForCustomer', TMessageType.CALL, self._seqid)
719
    args = getCancellableOrdersForCustomer_args()
720
    args.customer_id = customer_id
721
    args.limit = limit
722
    args.write(self._oprot)
723
    self._oprot.writeMessageEnd()
724
    self._oprot.trans.flush()
725
 
726
  def recv_getCancellableOrdersForCustomer(self, ):
727
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
728
    if mtype == TMessageType.EXCEPTION:
729
      x = TApplicationException()
730
      x.read(self._iprot)
731
      self._iprot.readMessageEnd()
732
      raise x
733
    result = getCancellableOrdersForCustomer_result()
734
    result.read(self._iprot)
735
    self._iprot.readMessageEnd()
736
    if result.success != None:
737
      return result.success
738
    if result.ex != None:
739
      raise result.ex
740
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getCancellableOrdersForCustomer failed: unknown result");
741
 
483 rajveer 742
  def changeOrderStatus(self, orderId, status, description):
94 ashish 743
    """
744
    Parameters:
483 rajveer 745
     - orderId
746
     - status
747
     - description
94 ashish 748
    """
483 rajveer 749
    self.send_changeOrderStatus(orderId, status, description)
750
    return self.recv_changeOrderStatus()
94 ashish 751
 
483 rajveer 752
  def send_changeOrderStatus(self, orderId, status, description):
753
    self._oprot.writeMessageBegin('changeOrderStatus', TMessageType.CALL, self._seqid)
754
    args = changeOrderStatus_args()
755
    args.orderId = orderId
756
    args.status = status
757
    args.description = description
94 ashish 758
    args.write(self._oprot)
759
    self._oprot.writeMessageEnd()
760
    self._oprot.trans.flush()
761
 
483 rajveer 762
  def recv_changeOrderStatus(self, ):
94 ashish 763
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
764
    if mtype == TMessageType.EXCEPTION:
765
      x = TApplicationException()
766
      x.read(self._iprot)
767
      self._iprot.readMessageEnd()
768
      raise x
483 rajveer 769
    result = changeOrderStatus_result()
94 ashish 770
    result.read(self._iprot)
771
    self._iprot.readMessageEnd()
772
    if result.success != None:
773
      return result.success
774
    if result.ex != None:
775
      raise result.ex
483 rajveer 776
    raise TApplicationException(TApplicationException.MISSING_RESULT, "changeOrderStatus failed: unknown result");
94 ashish 777
 
1149 chandransh 778
  def addBillingDetails(self, orderId, invoice_number, billed_by):
494 rajveer 779
    """
1149 chandransh 780
    Add billing details such as the bill number and the biller to the Order.
781
 
494 rajveer 782
    Parameters:
783
     - orderId
784
     - invoice_number
785
     - billed_by
786
    """
1149 chandransh 787
    self.send_addBillingDetails(orderId, invoice_number, billed_by)
494 rajveer 788
    return self.recv_addBillingDetails()
789
 
1149 chandransh 790
  def send_addBillingDetails(self, orderId, invoice_number, billed_by):
494 rajveer 791
    self._oprot.writeMessageBegin('addBillingDetails', TMessageType.CALL, self._seqid)
792
    args = addBillingDetails_args()
793
    args.orderId = orderId
794
    args.invoice_number = invoice_number
795
    args.billed_by = billed_by
796
    args.write(self._oprot)
797
    self._oprot.writeMessageEnd()
798
    self._oprot.trans.flush()
799
 
800
  def recv_addBillingDetails(self, ):
801
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
802
    if mtype == TMessageType.EXCEPTION:
803
      x = TApplicationException()
804
      x.read(self._iprot)
805
      self._iprot.readMessageEnd()
806
      raise x
807
    result = addBillingDetails_result()
808
    result.read(self._iprot)
809
    self._iprot.readMessageEnd()
810
    if result.success != None:
811
      return result.success
812
    if result.ex != None:
813
      raise result.ex
814
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addBillingDetails failed: unknown result");
815
 
1149 chandransh 816
  def addJacketNumber(self, orderId, jacketNumber):
817
    """
818
    Adds jacket number to the order. Return false if it doesn't find the order with the given ID.
819
 
820
    Parameters:
821
     - orderId
822
     - jacketNumber
823
    """
824
    self.send_addJacketNumber(orderId, jacketNumber)
825
    return self.recv_addJacketNumber()
826
 
827
  def send_addJacketNumber(self, orderId, jacketNumber):
828
    self._oprot.writeMessageBegin('addJacketNumber', TMessageType.CALL, self._seqid)
829
    args = addJacketNumber_args()
830
    args.orderId = orderId
831
    args.jacketNumber = jacketNumber
832
    args.write(self._oprot)
833
    self._oprot.writeMessageEnd()
834
    self._oprot.trans.flush()
835
 
836
  def recv_addJacketNumber(self, ):
837
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
838
    if mtype == TMessageType.EXCEPTION:
839
      x = TApplicationException()
840
      x.read(self._iprot)
841
      self._iprot.readMessageEnd()
842
      raise x
843
    result = addJacketNumber_result()
844
    result.read(self._iprot)
845
    self._iprot.readMessageEnd()
846
    if result.success != None:
847
      return result.success
848
    if result.ex != None:
849
      raise result.ex
850
    raise TApplicationException(TApplicationException.MISSING_RESULT, "addJacketNumber failed: unknown result");
851
 
921 rajveer 852
  def acceptOrder(self, orderId):
853
    """
854
    Parameters:
855
     - orderId
856
    """
857
    self.send_acceptOrder(orderId)
858
    return self.recv_acceptOrder()
859
 
860
  def send_acceptOrder(self, orderId):
861
    self._oprot.writeMessageBegin('acceptOrder', TMessageType.CALL, self._seqid)
862
    args = acceptOrder_args()
863
    args.orderId = orderId
864
    args.write(self._oprot)
865
    self._oprot.writeMessageEnd()
866
    self._oprot.trans.flush()
867
 
868
  def recv_acceptOrder(self, ):
869
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
870
    if mtype == TMessageType.EXCEPTION:
871
      x = TApplicationException()
872
      x.read(self._iprot)
873
      self._iprot.readMessageEnd()
874
      raise x
875
    result = acceptOrder_result()
876
    result.read(self._iprot)
877
    self._iprot.readMessageEnd()
878
    if result.success != None:
879
      return result.success
880
    if result.ex != None:
881
      raise result.ex
882
    raise TApplicationException(TApplicationException.MISSING_RESULT, "acceptOrder failed: unknown result");
883
 
884
  def billOrder(self, orderId):
885
    """
886
    Parameters:
887
     - orderId
888
    """
889
    self.send_billOrder(orderId)
890
    return self.recv_billOrder()
891
 
892
  def send_billOrder(self, orderId):
893
    self._oprot.writeMessageBegin('billOrder', TMessageType.CALL, self._seqid)
894
    args = billOrder_args()
895
    args.orderId = orderId
896
    args.write(self._oprot)
897
    self._oprot.writeMessageEnd()
898
    self._oprot.trans.flush()
899
 
900
  def recv_billOrder(self, ):
901
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
902
    if mtype == TMessageType.EXCEPTION:
903
      x = TApplicationException()
904
      x.read(self._iprot)
905
      self._iprot.readMessageEnd()
906
      raise x
907
    result = billOrder_result()
908
    result.read(self._iprot)
909
    self._iprot.readMessageEnd()
910
    if result.success != None:
911
      return result.success
912
    if result.ex != None:
913
      raise result.ex
914
    raise TApplicationException(TApplicationException.MISSING_RESULT, "billOrder failed: unknown result");
915
 
1528 ankur.sing 916
  def getOrdersForTransaction(self, transactionId, customerId):
94 ashish 917
    """
1528 ankur.sing 918
    Returns list of orders for given transaction Id. Also filters based on customer Id so that
919
    only user who owns the transaction can view its order details.
920
 
94 ashish 921
    Parameters:
922
     - transactionId
1528 ankur.sing 923
     - customerId
94 ashish 924
    """
1528 ankur.sing 925
    self.send_getOrdersForTransaction(transactionId, customerId)
483 rajveer 926
    return self.recv_getOrdersForTransaction()
94 ashish 927
 
1528 ankur.sing 928
  def send_getOrdersForTransaction(self, transactionId, customerId):
483 rajveer 929
    self._oprot.writeMessageBegin('getOrdersForTransaction', TMessageType.CALL, self._seqid)
930
    args = getOrdersForTransaction_args()
94 ashish 931
    args.transactionId = transactionId
1528 ankur.sing 932
    args.customerId = customerId
94 ashish 933
    args.write(self._oprot)
934
    self._oprot.writeMessageEnd()
935
    self._oprot.trans.flush()
936
 
483 rajveer 937
  def recv_getOrdersForTransaction(self, ):
94 ashish 938
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
939
    if mtype == TMessageType.EXCEPTION:
940
      x = TApplicationException()
941
      x.read(self._iprot)
942
      self._iprot.readMessageEnd()
943
      raise x
483 rajveer 944
    result = getOrdersForTransaction_result()
94 ashish 945
    result.read(self._iprot)
946
    self._iprot.readMessageEnd()
947
    if result.success != None:
948
      return result.success
949
    if result.ex != None:
950
      raise result.ex
483 rajveer 951
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrdersForTransaction failed: unknown result");
94 ashish 952
 
483 rajveer 953
  def getOrdersForCustomer(self, customerId, from_date, to_date, status):
94 ashish 954
    """
955
    Parameters:
483 rajveer 956
     - customerId
957
     - from_date
958
     - to_date
959
     - status
94 ashish 960
    """
483 rajveer 961
    self.send_getOrdersForCustomer(customerId, from_date, to_date, status)
962
    return self.recv_getOrdersForCustomer()
94 ashish 963
 
483 rajveer 964
  def send_getOrdersForCustomer(self, customerId, from_date, to_date, status):
965
    self._oprot.writeMessageBegin('getOrdersForCustomer', TMessageType.CALL, self._seqid)
966
    args = getOrdersForCustomer_args()
967
    args.customerId = customerId
968
    args.from_date = from_date
969
    args.to_date = to_date
970
    args.status = status
94 ashish 971
    args.write(self._oprot)
972
    self._oprot.writeMessageEnd()
973
    self._oprot.trans.flush()
974
 
483 rajveer 975
  def recv_getOrdersForCustomer(self, ):
94 ashish 976
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
977
    if mtype == TMessageType.EXCEPTION:
978
      x = TApplicationException()
979
      x.read(self._iprot)
980
      self._iprot.readMessageEnd()
981
      raise x
483 rajveer 982
    result = getOrdersForCustomer_result()
94 ashish 983
    result.read(self._iprot)
984
    self._iprot.readMessageEnd()
985
    if result.success != None:
986
      return result.success
987
    if result.ex != None:
988
      raise result.ex
483 rajveer 989
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrdersForCustomer failed: unknown result");
94 ashish 990
 
483 rajveer 991
  def createOrder(self, order):
94 ashish 992
    """
993
    Parameters:
483 rajveer 994
     - order
94 ashish 995
    """
483 rajveer 996
    self.send_createOrder(order)
997
    return self.recv_createOrder()
94 ashish 998
 
483 rajveer 999
  def send_createOrder(self, order):
1000
    self._oprot.writeMessageBegin('createOrder', TMessageType.CALL, self._seqid)
1001
    args = createOrder_args()
1002
    args.order = order
94 ashish 1003
    args.write(self._oprot)
1004
    self._oprot.writeMessageEnd()
1005
    self._oprot.trans.flush()
1006
 
483 rajveer 1007
  def recv_createOrder(self, ):
94 ashish 1008
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1009
    if mtype == TMessageType.EXCEPTION:
1010
      x = TApplicationException()
1011
      x.read(self._iprot)
1012
      self._iprot.readMessageEnd()
1013
      raise x
483 rajveer 1014
    result = createOrder_result()
94 ashish 1015
    result.read(self._iprot)
1016
    self._iprot.readMessageEnd()
1017
    if result.success != None:
1018
      return result.success
1019
    if result.ex != None:
1020
      raise result.ex
483 rajveer 1021
    raise TApplicationException(TApplicationException.MISSING_RESULT, "createOrder failed: unknown result");
94 ashish 1022
 
483 rajveer 1023
  def getOrder(self, id):
94 ashish 1024
    """
1025
    Parameters:
483 rajveer 1026
     - id
94 ashish 1027
    """
483 rajveer 1028
    self.send_getOrder(id)
1029
    return self.recv_getOrder()
94 ashish 1030
 
483 rajveer 1031
  def send_getOrder(self, id):
1032
    self._oprot.writeMessageBegin('getOrder', TMessageType.CALL, self._seqid)
1033
    args = getOrder_args()
1034
    args.id = id
94 ashish 1035
    args.write(self._oprot)
1036
    self._oprot.writeMessageEnd()
1037
    self._oprot.trans.flush()
1038
 
483 rajveer 1039
  def recv_getOrder(self, ):
94 ashish 1040
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1041
    if mtype == TMessageType.EXCEPTION:
1042
      x = TApplicationException()
1043
      x.read(self._iprot)
1044
      self._iprot.readMessageEnd()
1045
      raise x
483 rajveer 1046
    result = getOrder_result()
94 ashish 1047
    result.read(self._iprot)
1048
    self._iprot.readMessageEnd()
1049
    if result.success != None:
1050
      return result.success
1051
    if result.ex != None:
1052
      raise result.ex
483 rajveer 1053
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrder failed: unknown result");
94 ashish 1054
 
483 rajveer 1055
  def getLineItemsForOrder(self, orderId):
94 ashish 1056
    """
1057
    Parameters:
483 rajveer 1058
     - orderId
94 ashish 1059
    """
483 rajveer 1060
    self.send_getLineItemsForOrder(orderId)
1061
    return self.recv_getLineItemsForOrder()
94 ashish 1062
 
483 rajveer 1063
  def send_getLineItemsForOrder(self, orderId):
1064
    self._oprot.writeMessageBegin('getLineItemsForOrder', TMessageType.CALL, self._seqid)
1065
    args = getLineItemsForOrder_args()
1066
    args.orderId = orderId
94 ashish 1067
    args.write(self._oprot)
1068
    self._oprot.writeMessageEnd()
1069
    self._oprot.trans.flush()
1070
 
483 rajveer 1071
  def recv_getLineItemsForOrder(self, ):
94 ashish 1072
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1073
    if mtype == TMessageType.EXCEPTION:
1074
      x = TApplicationException()
1075
      x.read(self._iprot)
1076
      self._iprot.readMessageEnd()
1077
      raise x
483 rajveer 1078
    result = getLineItemsForOrder_result()
94 ashish 1079
    result.read(self._iprot)
1080
    self._iprot.readMessageEnd()
1081
    if result.success != None:
1082
      return result.success
1083
    if result.ex != None:
1084
      raise result.ex
483 rajveer 1085
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getLineItemsForOrder failed: unknown result");
94 ashish 1086
 
1528 ankur.sing 1087
  def getOrderForCustomer(self, orderId, customerId):
1088
    """
1089
    Returns an order for the order Id. Also checks if the order belongs to the customer whose Id is passed.
1090
    Throws exception if either order Id is invalid or order does not below to the customer whose Id is passed.
1091
 
1092
    Parameters:
1093
     - orderId
1094
     - customerId
1095
    """
1096
    self.send_getOrderForCustomer(orderId, customerId)
1097
    return self.recv_getOrderForCustomer()
1098
 
1099
  def send_getOrderForCustomer(self, orderId, customerId):
1100
    self._oprot.writeMessageBegin('getOrderForCustomer', TMessageType.CALL, self._seqid)
1101
    args = getOrderForCustomer_args()
1102
    args.orderId = orderId
1103
    args.customerId = customerId
1104
    args.write(self._oprot)
1105
    self._oprot.writeMessageEnd()
1106
    self._oprot.trans.flush()
1107
 
1108
  def recv_getOrderForCustomer(self, ):
1109
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1110
    if mtype == TMessageType.EXCEPTION:
1111
      x = TApplicationException()
1112
      x.read(self._iprot)
1113
      self._iprot.readMessageEnd()
1114
      raise x
1115
    result = getOrderForCustomer_result()
1116
    result.read(self._iprot)
1117
    self._iprot.readMessageEnd()
1118
    if result.success != None:
1119
      return result.success
1120
    if result.ex != None:
1121
      raise result.ex
1122
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getOrderForCustomer failed: unknown result");
1123
 
1220 chandransh 1124
  def batchOrders(self, warehouseId):
1125
    """
1126
    Create a batch of all the pending orders for the given warehouse.
1127
    The returned list is orderd by created_timestamp.
1128
    If there are no pending orders, an empty list is returned.
1129
 
1130
    Parameters:
1131
     - warehouseId
1132
    """
1133
    self.send_batchOrders(warehouseId)
1134
    return self.recv_batchOrders()
1135
 
1136
  def send_batchOrders(self, warehouseId):
1137
    self._oprot.writeMessageBegin('batchOrders', TMessageType.CALL, self._seqid)
1138
    args = batchOrders_args()
1139
    args.warehouseId = warehouseId
1140
    args.write(self._oprot)
1141
    self._oprot.writeMessageEnd()
1142
    self._oprot.trans.flush()
1143
 
1144
  def recv_batchOrders(self, ):
1145
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1146
    if mtype == TMessageType.EXCEPTION:
1147
      x = TApplicationException()
1148
      x.read(self._iprot)
1149
      self._iprot.readMessageEnd()
1150
      raise x
1151
    result = batchOrders_result()
1152
    result.read(self._iprot)
1153
    self._iprot.readMessageEnd()
1154
    if result.success != None:
1155
      return result.success
1156
    if result.ex != None:
1157
      raise result.ex
1158
    raise TApplicationException(TApplicationException.MISSING_RESULT, "batchOrders failed: unknown result");
1159
 
1208 chandransh 1160
  def markOrderAsOutOfStock(self, orderId):
1161
    """
1162
    Mark the given order as out of stock. Throws an exception if the order with the given Id couldn't be found.
1163
 
1164
    Parameters:
1165
     - orderId
1166
    """
1167
    self.send_markOrderAsOutOfStock(orderId)
1168
    return self.recv_markOrderAsOutOfStock()
1169
 
1170
  def send_markOrderAsOutOfStock(self, orderId):
1171
    self._oprot.writeMessageBegin('markOrderAsOutOfStock', TMessageType.CALL, self._seqid)
1172
    args = markOrderAsOutOfStock_args()
1173
    args.orderId = orderId
1174
    args.write(self._oprot)
1175
    self._oprot.writeMessageEnd()
1176
    self._oprot.trans.flush()
1177
 
1178
  def recv_markOrderAsOutOfStock(self, ):
1179
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1180
    if mtype == TMessageType.EXCEPTION:
1181
      x = TApplicationException()
1182
      x.read(self._iprot)
1183
      self._iprot.readMessageEnd()
1184
      raise x
1185
    result = markOrderAsOutOfStock_result()
1186
    result.read(self._iprot)
1187
    self._iprot.readMessageEnd()
1188
    if result.success != None:
1189
      return result.success
1190
    if result.ex != None:
1191
      raise result.ex
1192
    raise TApplicationException(TApplicationException.MISSING_RESULT, "markOrderAsOutOfStock failed: unknown result");
1193
 
759 chandransh 1194
  def markOrdersAsManifested(self, warehouseId, providerId):
1195
    """
1196
    Marks all BILLED orders for a warehouse and a provider as SHIPPED_FROM_WH
1197
 
1198
    Parameters:
1199
     - warehouseId
1200
     - providerId
1201
    """
1202
    self.send_markOrdersAsManifested(warehouseId, providerId)
1203
    return self.recv_markOrdersAsManifested()
1204
 
1205
  def send_markOrdersAsManifested(self, warehouseId, providerId):
1206
    self._oprot.writeMessageBegin('markOrdersAsManifested', TMessageType.CALL, self._seqid)
1207
    args = markOrdersAsManifested_args()
1208
    args.warehouseId = warehouseId
1209
    args.providerId = providerId
1210
    args.write(self._oprot)
1211
    self._oprot.writeMessageEnd()
1212
    self._oprot.trans.flush()
1213
 
1214
  def recv_markOrdersAsManifested(self, ):
1215
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1216
    if mtype == TMessageType.EXCEPTION:
1217
      x = TApplicationException()
1218
      x.read(self._iprot)
1219
      self._iprot.readMessageEnd()
1220
      raise x
1221
    result = markOrdersAsManifested_result()
1222
    result.read(self._iprot)
1223
    self._iprot.readMessageEnd()
1224
    if result.success != None:
1225
      return result.success
1226
    if result.ex != None:
1227
      raise result.ex
1228
    raise TApplicationException(TApplicationException.MISSING_RESULT, "markOrdersAsManifested failed: unknown result");
1229
 
1113 chandransh 1230
  def markOrdersAsPickedUp(self, providerId, pickupDetails):
1231
    """
1232
    Marks all SHIPPED_FROM_WH orders of the previous day for a provider as SHIPPED_TO_LOGISTICS.
1233
    Returns a list of orders that were shipped from warehouse but did not appear in the pick-up report.
1234
    Raises an exception if we encounter report for an AWB number that we did not ship.
1235
 
1236
    Parameters:
1237
     - providerId
1238
     - pickupDetails
1239
    """
1240
    self.send_markOrdersAsPickedUp(providerId, pickupDetails)
1241
    return self.recv_markOrdersAsPickedUp()
1242
 
1243
  def send_markOrdersAsPickedUp(self, providerId, pickupDetails):
1244
    self._oprot.writeMessageBegin('markOrdersAsPickedUp', TMessageType.CALL, self._seqid)
1245
    args = markOrdersAsPickedUp_args()
1246
    args.providerId = providerId
1247
    args.pickupDetails = pickupDetails
1248
    args.write(self._oprot)
1249
    self._oprot.writeMessageEnd()
1250
    self._oprot.trans.flush()
1251
 
1252
  def recv_markOrdersAsPickedUp(self, ):
1253
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1254
    if mtype == TMessageType.EXCEPTION:
1255
      x = TApplicationException()
1256
      x.read(self._iprot)
1257
      self._iprot.readMessageEnd()
1258
      raise x
1259
    result = markOrdersAsPickedUp_result()
1260
    result.read(self._iprot)
1261
    self._iprot.readMessageEnd()
1262
    if result.success != None:
1263
      return result.success
1264
    if result.ex != None:
1265
      raise result.ex
1266
    raise TApplicationException(TApplicationException.MISSING_RESULT, "markOrdersAsPickedUp failed: unknown result");
1267
 
1132 chandransh 1268
  def markOrdersAsDelivered(self, providerId, deliveredOrders):
1269
    """
1270
    Marks all orders with AWBs in the given map as delivered. Also sets the delivery timestamp and
1271
    the name of the receiver.
1272
    Raises an exception if we encounter report for an AWB number that we did not ship.
1273
 
1274
    Parameters:
1275
     - providerId
1276
     - deliveredOrders
1277
    """
1278
    self.send_markOrdersAsDelivered(providerId, deliveredOrders)
1279
    self.recv_markOrdersAsDelivered()
1280
 
1281
  def send_markOrdersAsDelivered(self, providerId, deliveredOrders):
1282
    self._oprot.writeMessageBegin('markOrdersAsDelivered', TMessageType.CALL, self._seqid)
1283
    args = markOrdersAsDelivered_args()
1284
    args.providerId = providerId
1285
    args.deliveredOrders = deliveredOrders
1286
    args.write(self._oprot)
1287
    self._oprot.writeMessageEnd()
1288
    self._oprot.trans.flush()
1289
 
1290
  def recv_markOrdersAsDelivered(self, ):
1291
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1292
    if mtype == TMessageType.EXCEPTION:
1293
      x = TApplicationException()
1294
      x.read(self._iprot)
1295
      self._iprot.readMessageEnd()
1296
      raise x
1297
    result = markOrdersAsDelivered_result()
1298
    result.read(self._iprot)
1299
    self._iprot.readMessageEnd()
1300
    if result.ex != None:
1301
      raise result.ex
1302
    return
1303
 
1135 chandransh 1304
  def markOrdersAsFailed(self, providerId, returnedOrders):
1305
    """
1306
    Mark all orders with AWBs in the given map as failed. Also sets the delivery timestamp.
1307
    Raises an exception if we encounter report for an AWB number that we did not ship.
1308
 
1309
    Parameters:
1310
     - providerId
1311
     - returnedOrders
1312
    """
1313
    self.send_markOrdersAsFailed(providerId, returnedOrders)
1314
    self.recv_markOrdersAsFailed()
1315
 
1316
  def send_markOrdersAsFailed(self, providerId, returnedOrders):
1317
    self._oprot.writeMessageBegin('markOrdersAsFailed', TMessageType.CALL, self._seqid)
1318
    args = markOrdersAsFailed_args()
1319
    args.providerId = providerId
1320
    args.returnedOrders = returnedOrders
1321
    args.write(self._oprot)
1322
    self._oprot.writeMessageEnd()
1323
    self._oprot.trans.flush()
1324
 
1325
  def recv_markOrdersAsFailed(self, ):
1326
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1327
    if mtype == TMessageType.EXCEPTION:
1328
      x = TApplicationException()
1329
      x.read(self._iprot)
1330
      self._iprot.readMessageEnd()
1331
      raise x
1332
    result = markOrdersAsFailed_result()
1333
    result.read(self._iprot)
1334
    self._iprot.readMessageEnd()
1335
    if result.ex != None:
1336
      raise result.ex
1337
    return
1338
 
1246 chandransh 1339
  def updateNonDeliveryReason(self, providerId, undeliveredOrders):
1340
    """
1341
    Update the status description of orders whose AWB numbers are keys of the Map.
1342
 
1343
    Parameters:
1344
     - providerId
1345
     - undeliveredOrders
1346
    """
1347
    self.send_updateNonDeliveryReason(providerId, undeliveredOrders)
1348
    self.recv_updateNonDeliveryReason()
1349
 
1350
  def send_updateNonDeliveryReason(self, providerId, undeliveredOrders):
1351
    self._oprot.writeMessageBegin('updateNonDeliveryReason', TMessageType.CALL, self._seqid)
1352
    args = updateNonDeliveryReason_args()
1353
    args.providerId = providerId
1354
    args.undeliveredOrders = undeliveredOrders
1355
    args.write(self._oprot)
1356
    self._oprot.writeMessageEnd()
1357
    self._oprot.trans.flush()
1358
 
1359
  def recv_updateNonDeliveryReason(self, ):
1360
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1361
    if mtype == TMessageType.EXCEPTION:
1362
      x = TApplicationException()
1363
      x.read(self._iprot)
1364
      self._iprot.readMessageEnd()
1365
      raise x
1366
    result = updateNonDeliveryReason_result()
1367
    result.read(self._iprot)
1368
    self._iprot.readMessageEnd()
1369
    if result.ex != None:
1370
      raise result.ex
1371
    return
1372
 
1408 ankur.sing 1373
  def getUndeliveredOrders(self, providerId, warehouseId):
1374
    """
1375
    Returns the list of orders whose delivery time has passed but have not been
1376
    delivered yet for the given provider and warehouse. To get a complete list of
1377
    undelivered orders, pass them as -1.
1378
    Returns an empty list if no such orders exist.
1379
 
1380
    Parameters:
1381
     - providerId
1382
     - warehouseId
1383
    """
1384
    self.send_getUndeliveredOrders(providerId, warehouseId)
1385
    return self.recv_getUndeliveredOrders()
1386
 
1387
  def send_getUndeliveredOrders(self, providerId, warehouseId):
1388
    self._oprot.writeMessageBegin('getUndeliveredOrders', TMessageType.CALL, self._seqid)
1389
    args = getUndeliveredOrders_args()
1390
    args.providerId = providerId
1391
    args.warehouseId = warehouseId
1392
    args.write(self._oprot)
1393
    self._oprot.writeMessageEnd()
1394
    self._oprot.trans.flush()
1395
 
1396
  def recv_getUndeliveredOrders(self, ):
1397
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1398
    if mtype == TMessageType.EXCEPTION:
1399
      x = TApplicationException()
1400
      x.read(self._iprot)
1401
      self._iprot.readMessageEnd()
1402
      raise x
1403
    result = getUndeliveredOrders_result()
1404
    result.read(self._iprot)
1405
    self._iprot.readMessageEnd()
1406
    if result.success != None:
1407
      return result.success
1408
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getUndeliveredOrders failed: unknown result");
1409
 
483 rajveer 1410
  def getAlerts(self, orderId, valid):
94 ashish 1411
    """
1412
    Parameters:
483 rajveer 1413
     - orderId
304 ashish 1414
     - valid
1415
    """
483 rajveer 1416
    self.send_getAlerts(orderId, valid)
304 ashish 1417
    return self.recv_getAlerts()
94 ashish 1418
 
483 rajveer 1419
  def send_getAlerts(self, orderId, valid):
304 ashish 1420
    self._oprot.writeMessageBegin('getAlerts', TMessageType.CALL, self._seqid)
1421
    args = getAlerts_args()
483 rajveer 1422
    args.orderId = orderId
304 ashish 1423
    args.valid = valid
1424
    args.write(self._oprot)
1425
    self._oprot.writeMessageEnd()
1426
    self._oprot.trans.flush()
1427
 
1428
  def recv_getAlerts(self, ):
1429
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1430
    if mtype == TMessageType.EXCEPTION:
1431
      x = TApplicationException()
1432
      x.read(self._iprot)
1433
      self._iprot.readMessageEnd()
1434
      raise x
1435
    result = getAlerts_result()
1436
    result.read(self._iprot)
1437
    self._iprot.readMessageEnd()
1438
    if result.success != None:
1439
      return result.success
1440
    raise TApplicationException(TApplicationException.MISSING_RESULT, "getAlerts failed: unknown result");
1441
 
483 rajveer 1442
  def setAlert(self, orderId, unset, type, comment):
304 ashish 1443
    """
1444
    Parameters:
483 rajveer 1445
     - orderId
304 ashish 1446
     - unset
1447
     - type
1448
     - comment
1449
    """
483 rajveer 1450
    self.send_setAlert(orderId, unset, type, comment)
304 ashish 1451
    self.recv_setAlert()
1452
 
483 rajveer 1453
  def send_setAlert(self, orderId, unset, type, comment):
304 ashish 1454
    self._oprot.writeMessageBegin('setAlert', TMessageType.CALL, self._seqid)
1455
    args = setAlert_args()
483 rajveer 1456
    args.orderId = orderId
304 ashish 1457
    args.unset = unset
1458
    args.type = type
1459
    args.comment = comment
1460
    args.write(self._oprot)
1461
    self._oprot.writeMessageEnd()
1462
    self._oprot.trans.flush()
1463
 
1464
  def recv_setAlert(self, ):
1465
    (fname, mtype, rseqid) = self._iprot.readMessageBegin()
1466
    if mtype == TMessageType.EXCEPTION:
1467
      x = TApplicationException()
1468
      x.read(self._iprot)
1469
      self._iprot.readMessageEnd()
1470
      raise x
1471
    result = setAlert_result()
1472
    result.read(self._iprot)
1473
    self._iprot.readMessageEnd()
1474
    return
1475
 
1476
 
94 ashish 1477
class Processor(Iface, TProcessor):
1478
  def __init__(self, handler):
1479
    self._handler = handler
1480
    self._processMap = {}
765 rajveer 1481
    self._processMap["closeSession"] = Processor.process_closeSession
94 ashish 1482
    self._processMap["createTransaction"] = Processor.process_createTransaction
1483
    self._processMap["getTransaction"] = Processor.process_getTransaction
1484
    self._processMap["getTransactionsForCustomer"] = Processor.process_getTransactionsForCustomer
132 ashish 1485
    self._processMap["getTransactionsForShoppingCartId"] = Processor.process_getTransactionsForShoppingCartId
94 ashish 1486
    self._processMap["getTransactionStatus"] = Processor.process_getTransactionStatus
1487
    self._processMap["changeTransactionStatus"] = Processor.process_changeTransactionStatus
1398 varun.gupt 1488
    self._processMap["enqueueTransactionInfoEmail"] = Processor.process_enqueueTransactionInfoEmail
483 rajveer 1489
    self._processMap["getAllOrders"] = Processor.process_getAllOrders
999 varun.gupt 1490
    self._processMap["getOrdersByBillingDate"] = Processor.process_getOrdersByBillingDate
1382 varun.gupt 1491
    self._processMap["getReturnableOrdersForCustomer"] = Processor.process_getReturnableOrdersForCustomer
1492
    self._processMap["getCancellableOrdersForCustomer"] = Processor.process_getCancellableOrdersForCustomer
483 rajveer 1493
    self._processMap["changeOrderStatus"] = Processor.process_changeOrderStatus
494 rajveer 1494
    self._processMap["addBillingDetails"] = Processor.process_addBillingDetails
1149 chandransh 1495
    self._processMap["addJacketNumber"] = Processor.process_addJacketNumber
921 rajveer 1496
    self._processMap["acceptOrder"] = Processor.process_acceptOrder
1497
    self._processMap["billOrder"] = Processor.process_billOrder
483 rajveer 1498
    self._processMap["getOrdersForTransaction"] = Processor.process_getOrdersForTransaction
1499
    self._processMap["getOrdersForCustomer"] = Processor.process_getOrdersForCustomer
1500
    self._processMap["createOrder"] = Processor.process_createOrder
1501
    self._processMap["getOrder"] = Processor.process_getOrder
1502
    self._processMap["getLineItemsForOrder"] = Processor.process_getLineItemsForOrder
1528 ankur.sing 1503
    self._processMap["getOrderForCustomer"] = Processor.process_getOrderForCustomer
1220 chandransh 1504
    self._processMap["batchOrders"] = Processor.process_batchOrders
1208 chandransh 1505
    self._processMap["markOrderAsOutOfStock"] = Processor.process_markOrderAsOutOfStock
759 chandransh 1506
    self._processMap["markOrdersAsManifested"] = Processor.process_markOrdersAsManifested
1113 chandransh 1507
    self._processMap["markOrdersAsPickedUp"] = Processor.process_markOrdersAsPickedUp
1132 chandransh 1508
    self._processMap["markOrdersAsDelivered"] = Processor.process_markOrdersAsDelivered
1135 chandransh 1509
    self._processMap["markOrdersAsFailed"] = Processor.process_markOrdersAsFailed
1246 chandransh 1510
    self._processMap["updateNonDeliveryReason"] = Processor.process_updateNonDeliveryReason
1408 ankur.sing 1511
    self._processMap["getUndeliveredOrders"] = Processor.process_getUndeliveredOrders
304 ashish 1512
    self._processMap["getAlerts"] = Processor.process_getAlerts
1513
    self._processMap["setAlert"] = Processor.process_setAlert
94 ashish 1514
 
1515
  def process(self, iprot, oprot):
1516
    (name, type, seqid) = iprot.readMessageBegin()
1517
    if name not in self._processMap:
1518
      iprot.skip(TType.STRUCT)
1519
      iprot.readMessageEnd()
1520
      x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
1521
      oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
1522
      x.write(oprot)
1523
      oprot.writeMessageEnd()
1524
      oprot.trans.flush()
1525
      return
1526
    else:
1527
      self._processMap[name](self, seqid, iprot, oprot)
1528
    return True
1529
 
765 rajveer 1530
  def process_closeSession(self, seqid, iprot, oprot):
1531
    args = closeSession_args()
1532
    args.read(iprot)
1533
    iprot.readMessageEnd()
1534
    result = closeSession_result()
1535
    self._handler.closeSession()
1536
    oprot.writeMessageBegin("closeSession", TMessageType.REPLY, seqid)
1537
    result.write(oprot)
1538
    oprot.writeMessageEnd()
1539
    oprot.trans.flush()
1540
 
94 ashish 1541
  def process_createTransaction(self, seqid, iprot, oprot):
1542
    args = createTransaction_args()
1543
    args.read(iprot)
1544
    iprot.readMessageEnd()
1545
    result = createTransaction_result()
1546
    try:
132 ashish 1547
      result.success = self._handler.createTransaction(args.transaction)
94 ashish 1548
    except TransactionServiceException, ex:
1549
      result.ex = ex
1550
    oprot.writeMessageBegin("createTransaction", TMessageType.REPLY, seqid)
1551
    result.write(oprot)
1552
    oprot.writeMessageEnd()
1553
    oprot.trans.flush()
1554
 
1555
  def process_getTransaction(self, seqid, iprot, oprot):
1556
    args = getTransaction_args()
1557
    args.read(iprot)
1558
    iprot.readMessageEnd()
1559
    result = getTransaction_result()
1560
    try:
1561
      result.success = self._handler.getTransaction(args.id)
1562
    except TransactionServiceException, ex:
1563
      result.ex = ex
1564
    oprot.writeMessageBegin("getTransaction", TMessageType.REPLY, seqid)
1565
    result.write(oprot)
1566
    oprot.writeMessageEnd()
1567
    oprot.trans.flush()
1568
 
1569
  def process_getTransactionsForCustomer(self, seqid, iprot, oprot):
1570
    args = getTransactionsForCustomer_args()
1571
    args.read(iprot)
1572
    iprot.readMessageEnd()
1573
    result = getTransactionsForCustomer_result()
1574
    try:
1575
      result.success = self._handler.getTransactionsForCustomer(args.customerId, args.from_date, args.to_date, args.status)
1576
    except TransactionServiceException, ex:
1577
      result.ex = ex
1578
    oprot.writeMessageBegin("getTransactionsForCustomer", TMessageType.REPLY, seqid)
1579
    result.write(oprot)
1580
    oprot.writeMessageEnd()
1581
    oprot.trans.flush()
1582
 
132 ashish 1583
  def process_getTransactionsForShoppingCartId(self, seqid, iprot, oprot):
1584
    args = getTransactionsForShoppingCartId_args()
1585
    args.read(iprot)
1586
    iprot.readMessageEnd()
1587
    result = getTransactionsForShoppingCartId_result()
1588
    try:
1589
      result.success = self._handler.getTransactionsForShoppingCartId(args.shoppingCartId)
1590
    except TransactionServiceException, ex:
1591
      result.ex = ex
1592
    oprot.writeMessageBegin("getTransactionsForShoppingCartId", TMessageType.REPLY, seqid)
1593
    result.write(oprot)
1594
    oprot.writeMessageEnd()
1595
    oprot.trans.flush()
1596
 
94 ashish 1597
  def process_getTransactionStatus(self, seqid, iprot, oprot):
1598
    args = getTransactionStatus_args()
1599
    args.read(iprot)
1600
    iprot.readMessageEnd()
1601
    result = getTransactionStatus_result()
1602
    try:
1603
      result.success = self._handler.getTransactionStatus(args.transactionId)
1604
    except TransactionServiceException, ex:
1605
      result.ex = ex
1606
    oprot.writeMessageBegin("getTransactionStatus", TMessageType.REPLY, seqid)
1607
    result.write(oprot)
1608
    oprot.writeMessageEnd()
1609
    oprot.trans.flush()
1610
 
1611
  def process_changeTransactionStatus(self, seqid, iprot, oprot):
1612
    args = changeTransactionStatus_args()
1613
    args.read(iprot)
1614
    iprot.readMessageEnd()
1615
    result = changeTransactionStatus_result()
1616
    try:
1617
      result.success = self._handler.changeTransactionStatus(args.transactionId, args.status, args.description)
1618
    except TransactionServiceException, ex:
1619
      result.ex = ex
1620
    oprot.writeMessageBegin("changeTransactionStatus", TMessageType.REPLY, seqid)
1621
    result.write(oprot)
1622
    oprot.writeMessageEnd()
1623
    oprot.trans.flush()
1624
 
1398 varun.gupt 1625
  def process_enqueueTransactionInfoEmail(self, seqid, iprot, oprot):
1626
    args = enqueueTransactionInfoEmail_args()
1382 varun.gupt 1627
    args.read(iprot)
1628
    iprot.readMessageEnd()
1398 varun.gupt 1629
    result = enqueueTransactionInfoEmail_result()
1382 varun.gupt 1630
    try:
1398 varun.gupt 1631
      result.success = self._handler.enqueueTransactionInfoEmail(args.transactionId)
1382 varun.gupt 1632
    except TransactionServiceException, ex:
1633
      result.ex = ex
1398 varun.gupt 1634
    oprot.writeMessageBegin("enqueueTransactionInfoEmail", TMessageType.REPLY, seqid)
1382 varun.gupt 1635
    result.write(oprot)
1636
    oprot.writeMessageEnd()
1637
    oprot.trans.flush()
1638
 
483 rajveer 1639
  def process_getAllOrders(self, seqid, iprot, oprot):
1640
    args = getAllOrders_args()
94 ashish 1641
    args.read(iprot)
1642
    iprot.readMessageEnd()
483 rajveer 1643
    result = getAllOrders_result()
94 ashish 1644
    try:
483 rajveer 1645
      result.success = self._handler.getAllOrders(args.status, args.from_date, args.to_date, args.warehouse_id)
94 ashish 1646
    except TransactionServiceException, ex:
1647
      result.ex = ex
483 rajveer 1648
    oprot.writeMessageBegin("getAllOrders", TMessageType.REPLY, seqid)
94 ashish 1649
    result.write(oprot)
1650
    oprot.writeMessageEnd()
1651
    oprot.trans.flush()
1652
 
999 varun.gupt 1653
  def process_getOrdersByBillingDate(self, seqid, iprot, oprot):
1654
    args = getOrdersByBillingDate_args()
1655
    args.read(iprot)
1656
    iprot.readMessageEnd()
1657
    result = getOrdersByBillingDate_result()
1658
    try:
1659
      result.success = self._handler.getOrdersByBillingDate(args.status, args.start_billing_date, args.end_billing_date, args.warehouse_id)
1660
    except TransactionServiceException, ex:
1661
      result.ex = ex
1662
    oprot.writeMessageBegin("getOrdersByBillingDate", TMessageType.REPLY, seqid)
1663
    result.write(oprot)
1664
    oprot.writeMessageEnd()
1665
    oprot.trans.flush()
1666
 
1382 varun.gupt 1667
  def process_getReturnableOrdersForCustomer(self, seqid, iprot, oprot):
1668
    args = getReturnableOrdersForCustomer_args()
1669
    args.read(iprot)
1670
    iprot.readMessageEnd()
1671
    result = getReturnableOrdersForCustomer_result()
1672
    try:
1673
      result.success = self._handler.getReturnableOrdersForCustomer(args.customer_id, args.limit)
1674
    except TransactionServiceException, ex:
1675
      result.ex = ex
1676
    oprot.writeMessageBegin("getReturnableOrdersForCustomer", TMessageType.REPLY, seqid)
1677
    result.write(oprot)
1678
    oprot.writeMessageEnd()
1679
    oprot.trans.flush()
1680
 
1681
  def process_getCancellableOrdersForCustomer(self, seqid, iprot, oprot):
1682
    args = getCancellableOrdersForCustomer_args()
1683
    args.read(iprot)
1684
    iprot.readMessageEnd()
1685
    result = getCancellableOrdersForCustomer_result()
1686
    try:
1687
      result.success = self._handler.getCancellableOrdersForCustomer(args.customer_id, args.limit)
1688
    except TransactionServiceException, ex:
1689
      result.ex = ex
1690
    oprot.writeMessageBegin("getCancellableOrdersForCustomer", TMessageType.REPLY, seqid)
1691
    result.write(oprot)
1692
    oprot.writeMessageEnd()
1693
    oprot.trans.flush()
1694
 
483 rajveer 1695
  def process_changeOrderStatus(self, seqid, iprot, oprot):
1696
    args = changeOrderStatus_args()
94 ashish 1697
    args.read(iprot)
1698
    iprot.readMessageEnd()
483 rajveer 1699
    result = changeOrderStatus_result()
94 ashish 1700
    try:
483 rajveer 1701
      result.success = self._handler.changeOrderStatus(args.orderId, args.status, args.description)
94 ashish 1702
    except TransactionServiceException, ex:
1703
      result.ex = ex
483 rajveer 1704
    oprot.writeMessageBegin("changeOrderStatus", TMessageType.REPLY, seqid)
94 ashish 1705
    result.write(oprot)
1706
    oprot.writeMessageEnd()
1707
    oprot.trans.flush()
1708
 
494 rajveer 1709
  def process_addBillingDetails(self, seqid, iprot, oprot):
1710
    args = addBillingDetails_args()
1711
    args.read(iprot)
1712
    iprot.readMessageEnd()
1713
    result = addBillingDetails_result()
1714
    try:
1149 chandransh 1715
      result.success = self._handler.addBillingDetails(args.orderId, args.invoice_number, args.billed_by)
494 rajveer 1716
    except TransactionServiceException, ex:
1717
      result.ex = ex
1718
    oprot.writeMessageBegin("addBillingDetails", TMessageType.REPLY, seqid)
1719
    result.write(oprot)
1720
    oprot.writeMessageEnd()
1721
    oprot.trans.flush()
1722
 
1149 chandransh 1723
  def process_addJacketNumber(self, seqid, iprot, oprot):
1724
    args = addJacketNumber_args()
1725
    args.read(iprot)
1726
    iprot.readMessageEnd()
1727
    result = addJacketNumber_result()
1728
    try:
1729
      result.success = self._handler.addJacketNumber(args.orderId, args.jacketNumber)
1730
    except TransactionServiceException, ex:
1731
      result.ex = ex
1732
    oprot.writeMessageBegin("addJacketNumber", TMessageType.REPLY, seqid)
1733
    result.write(oprot)
1734
    oprot.writeMessageEnd()
1735
    oprot.trans.flush()
1736
 
921 rajveer 1737
  def process_acceptOrder(self, seqid, iprot, oprot):
1738
    args = acceptOrder_args()
1739
    args.read(iprot)
1740
    iprot.readMessageEnd()
1741
    result = acceptOrder_result()
1742
    try:
1743
      result.success = self._handler.acceptOrder(args.orderId)
1744
    except TransactionServiceException, ex:
1745
      result.ex = ex
1746
    oprot.writeMessageBegin("acceptOrder", TMessageType.REPLY, seqid)
1747
    result.write(oprot)
1748
    oprot.writeMessageEnd()
1749
    oprot.trans.flush()
1750
 
1751
  def process_billOrder(self, seqid, iprot, oprot):
1752
    args = billOrder_args()
1753
    args.read(iprot)
1754
    iprot.readMessageEnd()
1755
    result = billOrder_result()
1756
    try:
1757
      result.success = self._handler.billOrder(args.orderId)
1758
    except TransactionServiceException, ex:
1759
      result.ex = ex
1760
    oprot.writeMessageBegin("billOrder", TMessageType.REPLY, seqid)
1761
    result.write(oprot)
1762
    oprot.writeMessageEnd()
1763
    oprot.trans.flush()
1764
 
483 rajveer 1765
  def process_getOrdersForTransaction(self, seqid, iprot, oprot):
1766
    args = getOrdersForTransaction_args()
94 ashish 1767
    args.read(iprot)
1768
    iprot.readMessageEnd()
483 rajveer 1769
    result = getOrdersForTransaction_result()
94 ashish 1770
    try:
1528 ankur.sing 1771
      result.success = self._handler.getOrdersForTransaction(args.transactionId, args.customerId)
94 ashish 1772
    except TransactionServiceException, ex:
1773
      result.ex = ex
483 rajveer 1774
    oprot.writeMessageBegin("getOrdersForTransaction", TMessageType.REPLY, seqid)
94 ashish 1775
    result.write(oprot)
1776
    oprot.writeMessageEnd()
1777
    oprot.trans.flush()
1778
 
483 rajveer 1779
  def process_getOrdersForCustomer(self, seqid, iprot, oprot):
1780
    args = getOrdersForCustomer_args()
94 ashish 1781
    args.read(iprot)
1782
    iprot.readMessageEnd()
483 rajveer 1783
    result = getOrdersForCustomer_result()
94 ashish 1784
    try:
483 rajveer 1785
      result.success = self._handler.getOrdersForCustomer(args.customerId, args.from_date, args.to_date, args.status)
94 ashish 1786
    except TransactionServiceException, ex:
1787
      result.ex = ex
483 rajveer 1788
    oprot.writeMessageBegin("getOrdersForCustomer", TMessageType.REPLY, seqid)
94 ashish 1789
    result.write(oprot)
1790
    oprot.writeMessageEnd()
1791
    oprot.trans.flush()
1792
 
483 rajveer 1793
  def process_createOrder(self, seqid, iprot, oprot):
1794
    args = createOrder_args()
94 ashish 1795
    args.read(iprot)
1796
    iprot.readMessageEnd()
483 rajveer 1797
    result = createOrder_result()
94 ashish 1798
    try:
483 rajveer 1799
      result.success = self._handler.createOrder(args.order)
94 ashish 1800
    except TransactionServiceException, ex:
1801
      result.ex = ex
483 rajveer 1802
    oprot.writeMessageBegin("createOrder", TMessageType.REPLY, seqid)
94 ashish 1803
    result.write(oprot)
1804
    oprot.writeMessageEnd()
1805
    oprot.trans.flush()
1806
 
483 rajveer 1807
  def process_getOrder(self, seqid, iprot, oprot):
1808
    args = getOrder_args()
94 ashish 1809
    args.read(iprot)
1810
    iprot.readMessageEnd()
483 rajveer 1811
    result = getOrder_result()
94 ashish 1812
    try:
483 rajveer 1813
      result.success = self._handler.getOrder(args.id)
94 ashish 1814
    except TransactionServiceException, ex:
1815
      result.ex = ex
483 rajveer 1816
    oprot.writeMessageBegin("getOrder", TMessageType.REPLY, seqid)
94 ashish 1817
    result.write(oprot)
1818
    oprot.writeMessageEnd()
1819
    oprot.trans.flush()
1820
 
483 rajveer 1821
  def process_getLineItemsForOrder(self, seqid, iprot, oprot):
1822
    args = getLineItemsForOrder_args()
94 ashish 1823
    args.read(iprot)
1824
    iprot.readMessageEnd()
483 rajveer 1825
    result = getLineItemsForOrder_result()
94 ashish 1826
    try:
483 rajveer 1827
      result.success = self._handler.getLineItemsForOrder(args.orderId)
94 ashish 1828
    except TransactionServiceException, ex:
1829
      result.ex = ex
483 rajveer 1830
    oprot.writeMessageBegin("getLineItemsForOrder", TMessageType.REPLY, seqid)
94 ashish 1831
    result.write(oprot)
1832
    oprot.writeMessageEnd()
1833
    oprot.trans.flush()
1834
 
1528 ankur.sing 1835
  def process_getOrderForCustomer(self, seqid, iprot, oprot):
1836
    args = getOrderForCustomer_args()
1837
    args.read(iprot)
1838
    iprot.readMessageEnd()
1839
    result = getOrderForCustomer_result()
1840
    try:
1841
      result.success = self._handler.getOrderForCustomer(args.orderId, args.customerId)
1842
    except TransactionServiceException, ex:
1843
      result.ex = ex
1844
    oprot.writeMessageBegin("getOrderForCustomer", TMessageType.REPLY, seqid)
1845
    result.write(oprot)
1846
    oprot.writeMessageEnd()
1847
    oprot.trans.flush()
1848
 
1220 chandransh 1849
  def process_batchOrders(self, seqid, iprot, oprot):
1850
    args = batchOrders_args()
1851
    args.read(iprot)
1852
    iprot.readMessageEnd()
1853
    result = batchOrders_result()
1854
    try:
1855
      result.success = self._handler.batchOrders(args.warehouseId)
1856
    except TransactionServiceException, ex:
1857
      result.ex = ex
1858
    oprot.writeMessageBegin("batchOrders", TMessageType.REPLY, seqid)
1859
    result.write(oprot)
1860
    oprot.writeMessageEnd()
1861
    oprot.trans.flush()
1862
 
1208 chandransh 1863
  def process_markOrderAsOutOfStock(self, seqid, iprot, oprot):
1864
    args = markOrderAsOutOfStock_args()
1865
    args.read(iprot)
1866
    iprot.readMessageEnd()
1867
    result = markOrderAsOutOfStock_result()
1868
    try:
1869
      result.success = self._handler.markOrderAsOutOfStock(args.orderId)
1870
    except TransactionServiceException, ex:
1871
      result.ex = ex
1872
    oprot.writeMessageBegin("markOrderAsOutOfStock", TMessageType.REPLY, seqid)
1873
    result.write(oprot)
1874
    oprot.writeMessageEnd()
1875
    oprot.trans.flush()
1876
 
759 chandransh 1877
  def process_markOrdersAsManifested(self, seqid, iprot, oprot):
1878
    args = markOrdersAsManifested_args()
1879
    args.read(iprot)
1880
    iprot.readMessageEnd()
1881
    result = markOrdersAsManifested_result()
1882
    try:
1883
      result.success = self._handler.markOrdersAsManifested(args.warehouseId, args.providerId)
1884
    except TransactionServiceException, ex:
1885
      result.ex = ex
1886
    oprot.writeMessageBegin("markOrdersAsManifested", TMessageType.REPLY, seqid)
1887
    result.write(oprot)
1888
    oprot.writeMessageEnd()
1889
    oprot.trans.flush()
1890
 
1113 chandransh 1891
  def process_markOrdersAsPickedUp(self, seqid, iprot, oprot):
1892
    args = markOrdersAsPickedUp_args()
1893
    args.read(iprot)
1894
    iprot.readMessageEnd()
1895
    result = markOrdersAsPickedUp_result()
1896
    try:
1897
      result.success = self._handler.markOrdersAsPickedUp(args.providerId, args.pickupDetails)
1898
    except TransactionServiceException, ex:
1899
      result.ex = ex
1900
    oprot.writeMessageBegin("markOrdersAsPickedUp", TMessageType.REPLY, seqid)
1901
    result.write(oprot)
1902
    oprot.writeMessageEnd()
1903
    oprot.trans.flush()
1904
 
1132 chandransh 1905
  def process_markOrdersAsDelivered(self, seqid, iprot, oprot):
1906
    args = markOrdersAsDelivered_args()
1907
    args.read(iprot)
1908
    iprot.readMessageEnd()
1909
    result = markOrdersAsDelivered_result()
1910
    try:
1911
      self._handler.markOrdersAsDelivered(args.providerId, args.deliveredOrders)
1912
    except TransactionServiceException, ex:
1913
      result.ex = ex
1914
    oprot.writeMessageBegin("markOrdersAsDelivered", TMessageType.REPLY, seqid)
1915
    result.write(oprot)
1916
    oprot.writeMessageEnd()
1917
    oprot.trans.flush()
1918
 
1135 chandransh 1919
  def process_markOrdersAsFailed(self, seqid, iprot, oprot):
1920
    args = markOrdersAsFailed_args()
1921
    args.read(iprot)
1922
    iprot.readMessageEnd()
1923
    result = markOrdersAsFailed_result()
1924
    try:
1925
      self._handler.markOrdersAsFailed(args.providerId, args.returnedOrders)
1926
    except TransactionServiceException, ex:
1927
      result.ex = ex
1928
    oprot.writeMessageBegin("markOrdersAsFailed", TMessageType.REPLY, seqid)
1929
    result.write(oprot)
1930
    oprot.writeMessageEnd()
1931
    oprot.trans.flush()
1932
 
1246 chandransh 1933
  def process_updateNonDeliveryReason(self, seqid, iprot, oprot):
1934
    args = updateNonDeliveryReason_args()
1935
    args.read(iprot)
1936
    iprot.readMessageEnd()
1937
    result = updateNonDeliveryReason_result()
1938
    try:
1939
      self._handler.updateNonDeliveryReason(args.providerId, args.undeliveredOrders)
1940
    except TransactionServiceException, ex:
1941
      result.ex = ex
1942
    oprot.writeMessageBegin("updateNonDeliveryReason", TMessageType.REPLY, seqid)
1943
    result.write(oprot)
1944
    oprot.writeMessageEnd()
1945
    oprot.trans.flush()
1946
 
1408 ankur.sing 1947
  def process_getUndeliveredOrders(self, seqid, iprot, oprot):
1948
    args = getUndeliveredOrders_args()
1949
    args.read(iprot)
1950
    iprot.readMessageEnd()
1951
    result = getUndeliveredOrders_result()
1952
    result.success = self._handler.getUndeliveredOrders(args.providerId, args.warehouseId)
1953
    oprot.writeMessageBegin("getUndeliveredOrders", TMessageType.REPLY, seqid)
1954
    result.write(oprot)
1955
    oprot.writeMessageEnd()
1956
    oprot.trans.flush()
1957
 
304 ashish 1958
  def process_getAlerts(self, seqid, iprot, oprot):
1959
    args = getAlerts_args()
1960
    args.read(iprot)
1961
    iprot.readMessageEnd()
1962
    result = getAlerts_result()
483 rajveer 1963
    result.success = self._handler.getAlerts(args.orderId, args.valid)
304 ashish 1964
    oprot.writeMessageBegin("getAlerts", TMessageType.REPLY, seqid)
1965
    result.write(oprot)
1966
    oprot.writeMessageEnd()
1967
    oprot.trans.flush()
94 ashish 1968
 
304 ashish 1969
  def process_setAlert(self, seqid, iprot, oprot):
1970
    args = setAlert_args()
1971
    args.read(iprot)
1972
    iprot.readMessageEnd()
1973
    result = setAlert_result()
483 rajveer 1974
    self._handler.setAlert(args.orderId, args.unset, args.type, args.comment)
304 ashish 1975
    oprot.writeMessageBegin("setAlert", TMessageType.REPLY, seqid)
1976
    result.write(oprot)
1977
    oprot.writeMessageEnd()
1978
    oprot.trans.flush()
1979
 
1980
 
94 ashish 1981
# HELPER FUNCTIONS AND STRUCTURES
1982
 
765 rajveer 1983
class closeSession_args:
1984
 
1985
  thrift_spec = (
1986
  )
1987
 
1988
  def read(self, iprot):
1989
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
1990
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
1991
      return
1992
    iprot.readStructBegin()
1993
    while True:
1994
      (fname, ftype, fid) = iprot.readFieldBegin()
1995
      if ftype == TType.STOP:
1996
        break
1997
      else:
1998
        iprot.skip(ftype)
1999
      iprot.readFieldEnd()
2000
    iprot.readStructEnd()
2001
 
2002
  def write(self, oprot):
2003
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2004
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2005
      return
2006
    oprot.writeStructBegin('closeSession_args')
2007
    oprot.writeFieldStop()
2008
    oprot.writeStructEnd()
2009
 
2010
  def __repr__(self):
2011
    L = ['%s=%r' % (key, value)
2012
      for key, value in self.__dict__.iteritems()]
2013
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2014
 
2015
  def __eq__(self, other):
2016
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2017
 
2018
  def __ne__(self, other):
2019
    return not (self == other)
2020
 
2021
class closeSession_result:
2022
 
2023
  thrift_spec = (
2024
  )
2025
 
2026
  def read(self, iprot):
2027
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2028
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2029
      return
2030
    iprot.readStructBegin()
2031
    while True:
2032
      (fname, ftype, fid) = iprot.readFieldBegin()
2033
      if ftype == TType.STOP:
2034
        break
2035
      else:
2036
        iprot.skip(ftype)
2037
      iprot.readFieldEnd()
2038
    iprot.readStructEnd()
2039
 
2040
  def write(self, oprot):
2041
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2042
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2043
      return
2044
    oprot.writeStructBegin('closeSession_result')
2045
    oprot.writeFieldStop()
2046
    oprot.writeStructEnd()
2047
 
2048
  def __repr__(self):
2049
    L = ['%s=%r' % (key, value)
2050
      for key, value in self.__dict__.iteritems()]
2051
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2052
 
2053
  def __eq__(self, other):
2054
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2055
 
2056
  def __ne__(self, other):
2057
    return not (self == other)
2058
 
94 ashish 2059
class createTransaction_args:
2060
  """
2061
  Attributes:
2062
   - transaction
2063
  """
2064
 
2065
  thrift_spec = (
2066
    None, # 0
2067
    (1, TType.STRUCT, 'transaction', (Transaction, Transaction.thrift_spec), None, ), # 1
2068
  )
2069
 
2070
  def __init__(self, transaction=None,):
2071
    self.transaction = transaction
2072
 
2073
  def read(self, iprot):
2074
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2075
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2076
      return
2077
    iprot.readStructBegin()
2078
    while True:
2079
      (fname, ftype, fid) = iprot.readFieldBegin()
2080
      if ftype == TType.STOP:
2081
        break
2082
      if fid == 1:
2083
        if ftype == TType.STRUCT:
2084
          self.transaction = Transaction()
2085
          self.transaction.read(iprot)
2086
        else:
2087
          iprot.skip(ftype)
2088
      else:
2089
        iprot.skip(ftype)
2090
      iprot.readFieldEnd()
2091
    iprot.readStructEnd()
2092
 
2093
  def write(self, oprot):
2094
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2095
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2096
      return
2097
    oprot.writeStructBegin('createTransaction_args')
2098
    if self.transaction != None:
2099
      oprot.writeFieldBegin('transaction', TType.STRUCT, 1)
2100
      self.transaction.write(oprot)
2101
      oprot.writeFieldEnd()
2102
    oprot.writeFieldStop()
2103
    oprot.writeStructEnd()
2104
 
2105
  def __repr__(self):
2106
    L = ['%s=%r' % (key, value)
2107
      for key, value in self.__dict__.iteritems()]
2108
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2109
 
2110
  def __eq__(self, other):
2111
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2112
 
2113
  def __ne__(self, other):
2114
    return not (self == other)
2115
 
2116
class createTransaction_result:
2117
  """
2118
  Attributes:
132 ashish 2119
   - success
94 ashish 2120
   - ex
2121
  """
2122
 
2123
  thrift_spec = (
132 ashish 2124
    (0, TType.I64, 'success', None, None, ), # 0
94 ashish 2125
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
2126
  )
2127
 
132 ashish 2128
  def __init__(self, success=None, ex=None,):
2129
    self.success = success
94 ashish 2130
    self.ex = ex
2131
 
2132
  def read(self, iprot):
2133
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2134
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2135
      return
2136
    iprot.readStructBegin()
2137
    while True:
2138
      (fname, ftype, fid) = iprot.readFieldBegin()
2139
      if ftype == TType.STOP:
2140
        break
132 ashish 2141
      if fid == 0:
2142
        if ftype == TType.I64:
2143
          self.success = iprot.readI64();
2144
        else:
2145
          iprot.skip(ftype)
2146
      elif fid == 1:
94 ashish 2147
        if ftype == TType.STRUCT:
2148
          self.ex = TransactionServiceException()
2149
          self.ex.read(iprot)
2150
        else:
2151
          iprot.skip(ftype)
2152
      else:
2153
        iprot.skip(ftype)
2154
      iprot.readFieldEnd()
2155
    iprot.readStructEnd()
2156
 
2157
  def write(self, oprot):
2158
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2159
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2160
      return
2161
    oprot.writeStructBegin('createTransaction_result')
132 ashish 2162
    if self.success != None:
2163
      oprot.writeFieldBegin('success', TType.I64, 0)
2164
      oprot.writeI64(self.success)
2165
      oprot.writeFieldEnd()
94 ashish 2166
    if self.ex != None:
2167
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
2168
      self.ex.write(oprot)
2169
      oprot.writeFieldEnd()
2170
    oprot.writeFieldStop()
2171
    oprot.writeStructEnd()
2172
 
2173
  def __repr__(self):
2174
    L = ['%s=%r' % (key, value)
2175
      for key, value in self.__dict__.iteritems()]
2176
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2177
 
2178
  def __eq__(self, other):
2179
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2180
 
2181
  def __ne__(self, other):
2182
    return not (self == other)
2183
 
2184
class getTransaction_args:
2185
  """
2186
  Attributes:
2187
   - id
2188
  """
2189
 
2190
  thrift_spec = (
2191
    None, # 0
2192
    (1, TType.I64, 'id', None, None, ), # 1
2193
  )
2194
 
2195
  def __init__(self, id=None,):
2196
    self.id = id
2197
 
2198
  def read(self, iprot):
2199
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2200
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2201
      return
2202
    iprot.readStructBegin()
2203
    while True:
2204
      (fname, ftype, fid) = iprot.readFieldBegin()
2205
      if ftype == TType.STOP:
2206
        break
2207
      if fid == 1:
2208
        if ftype == TType.I64:
2209
          self.id = iprot.readI64();
2210
        else:
2211
          iprot.skip(ftype)
2212
      else:
2213
        iprot.skip(ftype)
2214
      iprot.readFieldEnd()
2215
    iprot.readStructEnd()
2216
 
2217
  def write(self, oprot):
2218
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2219
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2220
      return
2221
    oprot.writeStructBegin('getTransaction_args')
2222
    if self.id != None:
2223
      oprot.writeFieldBegin('id', TType.I64, 1)
2224
      oprot.writeI64(self.id)
2225
      oprot.writeFieldEnd()
2226
    oprot.writeFieldStop()
2227
    oprot.writeStructEnd()
2228
 
2229
  def __repr__(self):
2230
    L = ['%s=%r' % (key, value)
2231
      for key, value in self.__dict__.iteritems()]
2232
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2233
 
2234
  def __eq__(self, other):
2235
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2236
 
2237
  def __ne__(self, other):
2238
    return not (self == other)
2239
 
2240
class getTransaction_result:
2241
  """
2242
  Attributes:
2243
   - success
2244
   - ex
2245
  """
2246
 
2247
  thrift_spec = (
2248
    (0, TType.STRUCT, 'success', (Transaction, Transaction.thrift_spec), None, ), # 0
2249
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
2250
  )
2251
 
2252
  def __init__(self, success=None, ex=None,):
2253
    self.success = success
2254
    self.ex = ex
2255
 
2256
  def read(self, iprot):
2257
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2258
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2259
      return
2260
    iprot.readStructBegin()
2261
    while True:
2262
      (fname, ftype, fid) = iprot.readFieldBegin()
2263
      if ftype == TType.STOP:
2264
        break
2265
      if fid == 0:
2266
        if ftype == TType.STRUCT:
2267
          self.success = Transaction()
2268
          self.success.read(iprot)
2269
        else:
2270
          iprot.skip(ftype)
2271
      elif fid == 1:
2272
        if ftype == TType.STRUCT:
2273
          self.ex = TransactionServiceException()
2274
          self.ex.read(iprot)
2275
        else:
2276
          iprot.skip(ftype)
2277
      else:
2278
        iprot.skip(ftype)
2279
      iprot.readFieldEnd()
2280
    iprot.readStructEnd()
2281
 
2282
  def write(self, oprot):
2283
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2284
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2285
      return
2286
    oprot.writeStructBegin('getTransaction_result')
2287
    if self.success != None:
2288
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
2289
      self.success.write(oprot)
2290
      oprot.writeFieldEnd()
2291
    if self.ex != None:
2292
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
2293
      self.ex.write(oprot)
2294
      oprot.writeFieldEnd()
2295
    oprot.writeFieldStop()
2296
    oprot.writeStructEnd()
2297
 
2298
  def __repr__(self):
2299
    L = ['%s=%r' % (key, value)
2300
      for key, value in self.__dict__.iteritems()]
2301
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2302
 
2303
  def __eq__(self, other):
2304
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2305
 
2306
  def __ne__(self, other):
2307
    return not (self == other)
2308
 
2309
class getTransactionsForCustomer_args:
2310
  """
2311
  Attributes:
2312
   - customerId
2313
   - from_date
2314
   - to_date
2315
   - status
2316
  """
2317
 
2318
  thrift_spec = (
2319
    None, # 0
2320
    (1, TType.I64, 'customerId', None, None, ), # 1
2321
    (2, TType.I64, 'from_date', None, None, ), # 2
2322
    (3, TType.I64, 'to_date', None, None, ), # 3
2323
    (4, TType.I32, 'status', None, None, ), # 4
2324
  )
2325
 
2326
  def __init__(self, customerId=None, from_date=None, to_date=None, status=None,):
2327
    self.customerId = customerId
2328
    self.from_date = from_date
2329
    self.to_date = to_date
2330
    self.status = status
2331
 
2332
  def read(self, iprot):
2333
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2334
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2335
      return
2336
    iprot.readStructBegin()
2337
    while True:
2338
      (fname, ftype, fid) = iprot.readFieldBegin()
2339
      if ftype == TType.STOP:
2340
        break
2341
      if fid == 1:
2342
        if ftype == TType.I64:
2343
          self.customerId = iprot.readI64();
2344
        else:
2345
          iprot.skip(ftype)
2346
      elif fid == 2:
2347
        if ftype == TType.I64:
2348
          self.from_date = iprot.readI64();
2349
        else:
2350
          iprot.skip(ftype)
2351
      elif fid == 3:
2352
        if ftype == TType.I64:
2353
          self.to_date = iprot.readI64();
2354
        else:
2355
          iprot.skip(ftype)
2356
      elif fid == 4:
2357
        if ftype == TType.I32:
2358
          self.status = iprot.readI32();
2359
        else:
2360
          iprot.skip(ftype)
2361
      else:
2362
        iprot.skip(ftype)
2363
      iprot.readFieldEnd()
2364
    iprot.readStructEnd()
2365
 
2366
  def write(self, oprot):
2367
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2368
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2369
      return
2370
    oprot.writeStructBegin('getTransactionsForCustomer_args')
2371
    if self.customerId != None:
2372
      oprot.writeFieldBegin('customerId', TType.I64, 1)
2373
      oprot.writeI64(self.customerId)
2374
      oprot.writeFieldEnd()
2375
    if self.from_date != None:
2376
      oprot.writeFieldBegin('from_date', TType.I64, 2)
2377
      oprot.writeI64(self.from_date)
2378
      oprot.writeFieldEnd()
2379
    if self.to_date != None:
2380
      oprot.writeFieldBegin('to_date', TType.I64, 3)
2381
      oprot.writeI64(self.to_date)
2382
      oprot.writeFieldEnd()
2383
    if self.status != None:
2384
      oprot.writeFieldBegin('status', TType.I32, 4)
2385
      oprot.writeI32(self.status)
2386
      oprot.writeFieldEnd()
2387
    oprot.writeFieldStop()
2388
    oprot.writeStructEnd()
2389
 
2390
  def __repr__(self):
2391
    L = ['%s=%r' % (key, value)
2392
      for key, value in self.__dict__.iteritems()]
2393
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2394
 
2395
  def __eq__(self, other):
2396
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2397
 
2398
  def __ne__(self, other):
2399
    return not (self == other)
2400
 
2401
class getTransactionsForCustomer_result:
2402
  """
2403
  Attributes:
2404
   - success
2405
   - ex
2406
  """
2407
 
2408
  thrift_spec = (
2409
    (0, TType.LIST, 'success', (TType.STRUCT,(Transaction, Transaction.thrift_spec)), None, ), # 0
2410
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
2411
  )
2412
 
2413
  def __init__(self, success=None, ex=None,):
2414
    self.success = success
2415
    self.ex = ex
2416
 
2417
  def read(self, iprot):
2418
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2419
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2420
      return
2421
    iprot.readStructBegin()
2422
    while True:
2423
      (fname, ftype, fid) = iprot.readFieldBegin()
2424
      if ftype == TType.STOP:
2425
        break
2426
      if fid == 0:
2427
        if ftype == TType.LIST:
2428
          self.success = []
685 chandransh 2429
          (_etype17, _size14) = iprot.readListBegin()
2430
          for _i18 in xrange(_size14):
2431
            _elem19 = Transaction()
2432
            _elem19.read(iprot)
2433
            self.success.append(_elem19)
94 ashish 2434
          iprot.readListEnd()
2435
        else:
2436
          iprot.skip(ftype)
2437
      elif fid == 1:
2438
        if ftype == TType.STRUCT:
2439
          self.ex = TransactionServiceException()
2440
          self.ex.read(iprot)
2441
        else:
2442
          iprot.skip(ftype)
2443
      else:
2444
        iprot.skip(ftype)
2445
      iprot.readFieldEnd()
2446
    iprot.readStructEnd()
2447
 
2448
  def write(self, oprot):
2449
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2450
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2451
      return
2452
    oprot.writeStructBegin('getTransactionsForCustomer_result')
2453
    if self.success != None:
2454
      oprot.writeFieldBegin('success', TType.LIST, 0)
2455
      oprot.writeListBegin(TType.STRUCT, len(self.success))
685 chandransh 2456
      for iter20 in self.success:
2457
        iter20.write(oprot)
94 ashish 2458
      oprot.writeListEnd()
2459
      oprot.writeFieldEnd()
2460
    if self.ex != None:
2461
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
2462
      self.ex.write(oprot)
2463
      oprot.writeFieldEnd()
2464
    oprot.writeFieldStop()
2465
    oprot.writeStructEnd()
2466
 
2467
  def __repr__(self):
2468
    L = ['%s=%r' % (key, value)
2469
      for key, value in self.__dict__.iteritems()]
2470
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2471
 
2472
  def __eq__(self, other):
2473
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2474
 
2475
  def __ne__(self, other):
2476
    return not (self == other)
2477
 
132 ashish 2478
class getTransactionsForShoppingCartId_args:
2479
  """
2480
  Attributes:
2481
   - shoppingCartId
2482
  """
2483
 
2484
  thrift_spec = (
2485
    None, # 0
2486
    (1, TType.I64, 'shoppingCartId', None, None, ), # 1
2487
  )
2488
 
2489
  def __init__(self, shoppingCartId=None,):
2490
    self.shoppingCartId = shoppingCartId
2491
 
2492
  def read(self, iprot):
2493
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2494
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2495
      return
2496
    iprot.readStructBegin()
2497
    while True:
2498
      (fname, ftype, fid) = iprot.readFieldBegin()
2499
      if ftype == TType.STOP:
2500
        break
2501
      if fid == 1:
2502
        if ftype == TType.I64:
2503
          self.shoppingCartId = iprot.readI64();
2504
        else:
2505
          iprot.skip(ftype)
2506
      else:
2507
        iprot.skip(ftype)
2508
      iprot.readFieldEnd()
2509
    iprot.readStructEnd()
2510
 
2511
  def write(self, oprot):
2512
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2513
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2514
      return
2515
    oprot.writeStructBegin('getTransactionsForShoppingCartId_args')
2516
    if self.shoppingCartId != None:
2517
      oprot.writeFieldBegin('shoppingCartId', TType.I64, 1)
2518
      oprot.writeI64(self.shoppingCartId)
2519
      oprot.writeFieldEnd()
2520
    oprot.writeFieldStop()
2521
    oprot.writeStructEnd()
2522
 
2523
  def __repr__(self):
2524
    L = ['%s=%r' % (key, value)
2525
      for key, value in self.__dict__.iteritems()]
2526
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2527
 
2528
  def __eq__(self, other):
2529
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2530
 
2531
  def __ne__(self, other):
2532
    return not (self == other)
2533
 
2534
class getTransactionsForShoppingCartId_result:
2535
  """
2536
  Attributes:
2537
   - success
2538
   - ex
2539
  """
2540
 
2541
  thrift_spec = (
2542
    (0, TType.LIST, 'success', (TType.STRUCT,(Transaction, Transaction.thrift_spec)), None, ), # 0
2543
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
2544
  )
2545
 
2546
  def __init__(self, success=None, ex=None,):
2547
    self.success = success
2548
    self.ex = ex
2549
 
2550
  def read(self, iprot):
2551
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2552
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2553
      return
2554
    iprot.readStructBegin()
2555
    while True:
2556
      (fname, ftype, fid) = iprot.readFieldBegin()
2557
      if ftype == TType.STOP:
2558
        break
2559
      if fid == 0:
2560
        if ftype == TType.LIST:
2561
          self.success = []
685 chandransh 2562
          (_etype24, _size21) = iprot.readListBegin()
2563
          for _i25 in xrange(_size21):
2564
            _elem26 = Transaction()
2565
            _elem26.read(iprot)
2566
            self.success.append(_elem26)
132 ashish 2567
          iprot.readListEnd()
2568
        else:
2569
          iprot.skip(ftype)
2570
      elif fid == 1:
2571
        if ftype == TType.STRUCT:
2572
          self.ex = TransactionServiceException()
2573
          self.ex.read(iprot)
2574
        else:
2575
          iprot.skip(ftype)
2576
      else:
2577
        iprot.skip(ftype)
2578
      iprot.readFieldEnd()
2579
    iprot.readStructEnd()
2580
 
2581
  def write(self, oprot):
2582
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2583
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2584
      return
2585
    oprot.writeStructBegin('getTransactionsForShoppingCartId_result')
2586
    if self.success != None:
2587
      oprot.writeFieldBegin('success', TType.LIST, 0)
2588
      oprot.writeListBegin(TType.STRUCT, len(self.success))
685 chandransh 2589
      for iter27 in self.success:
2590
        iter27.write(oprot)
132 ashish 2591
      oprot.writeListEnd()
2592
      oprot.writeFieldEnd()
2593
    if self.ex != None:
2594
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
2595
      self.ex.write(oprot)
2596
      oprot.writeFieldEnd()
2597
    oprot.writeFieldStop()
2598
    oprot.writeStructEnd()
2599
 
2600
  def __repr__(self):
2601
    L = ['%s=%r' % (key, value)
2602
      for key, value in self.__dict__.iteritems()]
2603
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2604
 
2605
  def __eq__(self, other):
2606
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2607
 
2608
  def __ne__(self, other):
2609
    return not (self == other)
2610
 
94 ashish 2611
class getTransactionStatus_args:
2612
  """
2613
  Attributes:
2614
   - transactionId
2615
  """
2616
 
2617
  thrift_spec = (
2618
    None, # 0
2619
    (1, TType.I64, 'transactionId', None, None, ), # 1
2620
  )
2621
 
2622
  def __init__(self, transactionId=None,):
2623
    self.transactionId = transactionId
2624
 
2625
  def read(self, iprot):
2626
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2627
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2628
      return
2629
    iprot.readStructBegin()
2630
    while True:
2631
      (fname, ftype, fid) = iprot.readFieldBegin()
2632
      if ftype == TType.STOP:
2633
        break
2634
      if fid == 1:
2635
        if ftype == TType.I64:
2636
          self.transactionId = iprot.readI64();
2637
        else:
2638
          iprot.skip(ftype)
2639
      else:
2640
        iprot.skip(ftype)
2641
      iprot.readFieldEnd()
2642
    iprot.readStructEnd()
2643
 
2644
  def write(self, oprot):
2645
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2646
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2647
      return
2648
    oprot.writeStructBegin('getTransactionStatus_args')
2649
    if self.transactionId != None:
2650
      oprot.writeFieldBegin('transactionId', TType.I64, 1)
2651
      oprot.writeI64(self.transactionId)
2652
      oprot.writeFieldEnd()
2653
    oprot.writeFieldStop()
2654
    oprot.writeStructEnd()
2655
 
2656
  def __repr__(self):
2657
    L = ['%s=%r' % (key, value)
2658
      for key, value in self.__dict__.iteritems()]
2659
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2660
 
2661
  def __eq__(self, other):
2662
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2663
 
2664
  def __ne__(self, other):
2665
    return not (self == other)
2666
 
2667
class getTransactionStatus_result:
2668
  """
2669
  Attributes:
2670
   - success
2671
   - ex
2672
  """
2673
 
2674
  thrift_spec = (
2675
    (0, TType.I32, 'success', None, None, ), # 0
2676
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
2677
  )
2678
 
2679
  def __init__(self, success=None, ex=None,):
2680
    self.success = success
2681
    self.ex = ex
2682
 
2683
  def read(self, iprot):
2684
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2685
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2686
      return
2687
    iprot.readStructBegin()
2688
    while True:
2689
      (fname, ftype, fid) = iprot.readFieldBegin()
2690
      if ftype == TType.STOP:
2691
        break
2692
      if fid == 0:
2693
        if ftype == TType.I32:
2694
          self.success = iprot.readI32();
2695
        else:
2696
          iprot.skip(ftype)
2697
      elif fid == 1:
2698
        if ftype == TType.STRUCT:
2699
          self.ex = TransactionServiceException()
2700
          self.ex.read(iprot)
2701
        else:
2702
          iprot.skip(ftype)
2703
      else:
2704
        iprot.skip(ftype)
2705
      iprot.readFieldEnd()
2706
    iprot.readStructEnd()
2707
 
2708
  def write(self, oprot):
2709
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2710
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2711
      return
2712
    oprot.writeStructBegin('getTransactionStatus_result')
2713
    if self.success != None:
2714
      oprot.writeFieldBegin('success', TType.I32, 0)
2715
      oprot.writeI32(self.success)
2716
      oprot.writeFieldEnd()
2717
    if self.ex != None:
2718
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
2719
      self.ex.write(oprot)
2720
      oprot.writeFieldEnd()
2721
    oprot.writeFieldStop()
2722
    oprot.writeStructEnd()
2723
 
2724
  def __repr__(self):
2725
    L = ['%s=%r' % (key, value)
2726
      for key, value in self.__dict__.iteritems()]
2727
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2728
 
2729
  def __eq__(self, other):
2730
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2731
 
2732
  def __ne__(self, other):
2733
    return not (self == other)
2734
 
2735
class changeTransactionStatus_args:
2736
  """
2737
  Attributes:
2738
   - transactionId
2739
   - status
2740
   - description
2741
  """
2742
 
2743
  thrift_spec = (
2744
    None, # 0
2745
    (1, TType.I64, 'transactionId', None, None, ), # 1
2746
    (2, TType.I32, 'status', None, None, ), # 2
2747
    (3, TType.STRING, 'description', None, None, ), # 3
2748
  )
2749
 
2750
  def __init__(self, transactionId=None, status=None, description=None,):
2751
    self.transactionId = transactionId
2752
    self.status = status
2753
    self.description = description
2754
 
2755
  def read(self, iprot):
2756
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2757
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2758
      return
2759
    iprot.readStructBegin()
2760
    while True:
2761
      (fname, ftype, fid) = iprot.readFieldBegin()
2762
      if ftype == TType.STOP:
2763
        break
2764
      if fid == 1:
2765
        if ftype == TType.I64:
2766
          self.transactionId = iprot.readI64();
2767
        else:
2768
          iprot.skip(ftype)
2769
      elif fid == 2:
2770
        if ftype == TType.I32:
2771
          self.status = iprot.readI32();
2772
        else:
2773
          iprot.skip(ftype)
2774
      elif fid == 3:
2775
        if ftype == TType.STRING:
2776
          self.description = iprot.readString();
2777
        else:
2778
          iprot.skip(ftype)
2779
      else:
2780
        iprot.skip(ftype)
2781
      iprot.readFieldEnd()
2782
    iprot.readStructEnd()
2783
 
2784
  def write(self, oprot):
2785
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2786
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2787
      return
2788
    oprot.writeStructBegin('changeTransactionStatus_args')
2789
    if self.transactionId != None:
2790
      oprot.writeFieldBegin('transactionId', TType.I64, 1)
2791
      oprot.writeI64(self.transactionId)
2792
      oprot.writeFieldEnd()
2793
    if self.status != None:
2794
      oprot.writeFieldBegin('status', TType.I32, 2)
2795
      oprot.writeI32(self.status)
2796
      oprot.writeFieldEnd()
2797
    if self.description != None:
2798
      oprot.writeFieldBegin('description', TType.STRING, 3)
2799
      oprot.writeString(self.description)
2800
      oprot.writeFieldEnd()
2801
    oprot.writeFieldStop()
2802
    oprot.writeStructEnd()
2803
 
2804
  def __repr__(self):
2805
    L = ['%s=%r' % (key, value)
2806
      for key, value in self.__dict__.iteritems()]
2807
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2808
 
2809
  def __eq__(self, other):
2810
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2811
 
2812
  def __ne__(self, other):
2813
    return not (self == other)
2814
 
2815
class changeTransactionStatus_result:
2816
  """
2817
  Attributes:
2818
   - success
2819
   - ex
2820
  """
2821
 
2822
  thrift_spec = (
2823
    (0, TType.BOOL, 'success', None, None, ), # 0
2824
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
2825
  )
2826
 
2827
  def __init__(self, success=None, ex=None,):
2828
    self.success = success
2829
    self.ex = ex
2830
 
2831
  def read(self, iprot):
2832
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2833
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2834
      return
2835
    iprot.readStructBegin()
2836
    while True:
2837
      (fname, ftype, fid) = iprot.readFieldBegin()
2838
      if ftype == TType.STOP:
2839
        break
2840
      if fid == 0:
2841
        if ftype == TType.BOOL:
2842
          self.success = iprot.readBool();
2843
        else:
2844
          iprot.skip(ftype)
2845
      elif fid == 1:
2846
        if ftype == TType.STRUCT:
2847
          self.ex = TransactionServiceException()
2848
          self.ex.read(iprot)
2849
        else:
2850
          iprot.skip(ftype)
2851
      else:
2852
        iprot.skip(ftype)
2853
      iprot.readFieldEnd()
2854
    iprot.readStructEnd()
2855
 
2856
  def write(self, oprot):
2857
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2858
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2859
      return
2860
    oprot.writeStructBegin('changeTransactionStatus_result')
2861
    if self.success != None:
2862
      oprot.writeFieldBegin('success', TType.BOOL, 0)
2863
      oprot.writeBool(self.success)
2864
      oprot.writeFieldEnd()
2865
    if self.ex != None:
2866
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
2867
      self.ex.write(oprot)
2868
      oprot.writeFieldEnd()
2869
    oprot.writeFieldStop()
2870
    oprot.writeStructEnd()
2871
 
2872
  def __repr__(self):
2873
    L = ['%s=%r' % (key, value)
2874
      for key, value in self.__dict__.iteritems()]
2875
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2876
 
2877
  def __eq__(self, other):
2878
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2879
 
2880
  def __ne__(self, other):
2881
    return not (self == other)
2882
 
1398 varun.gupt 2883
class enqueueTransactionInfoEmail_args:
1382 varun.gupt 2884
  """
2885
  Attributes:
2886
   - transactionId
2887
  """
2888
 
2889
  thrift_spec = (
2890
    None, # 0
2891
    (1, TType.I64, 'transactionId', None, None, ), # 1
2892
  )
2893
 
2894
  def __init__(self, transactionId=None,):
2895
    self.transactionId = transactionId
2896
 
2897
  def read(self, iprot):
2898
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2899
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2900
      return
2901
    iprot.readStructBegin()
2902
    while True:
2903
      (fname, ftype, fid) = iprot.readFieldBegin()
2904
      if ftype == TType.STOP:
2905
        break
2906
      if fid == 1:
2907
        if ftype == TType.I64:
2908
          self.transactionId = iprot.readI64();
2909
        else:
2910
          iprot.skip(ftype)
2911
      else:
2912
        iprot.skip(ftype)
2913
      iprot.readFieldEnd()
2914
    iprot.readStructEnd()
2915
 
2916
  def write(self, oprot):
2917
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2918
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2919
      return
1398 varun.gupt 2920
    oprot.writeStructBegin('enqueueTransactionInfoEmail_args')
1382 varun.gupt 2921
    if self.transactionId != None:
2922
      oprot.writeFieldBegin('transactionId', TType.I64, 1)
2923
      oprot.writeI64(self.transactionId)
2924
      oprot.writeFieldEnd()
2925
    oprot.writeFieldStop()
2926
    oprot.writeStructEnd()
2927
 
2928
  def __repr__(self):
2929
    L = ['%s=%r' % (key, value)
2930
      for key, value in self.__dict__.iteritems()]
2931
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
2932
 
2933
  def __eq__(self, other):
2934
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
2935
 
2936
  def __ne__(self, other):
2937
    return not (self == other)
2938
 
1398 varun.gupt 2939
class enqueueTransactionInfoEmail_result:
1382 varun.gupt 2940
  """
2941
  Attributes:
2942
   - success
2943
   - ex
2944
  """
2945
 
2946
  thrift_spec = (
2947
    (0, TType.BOOL, 'success', None, None, ), # 0
2948
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
2949
  )
2950
 
2951
  def __init__(self, success=None, ex=None,):
2952
    self.success = success
2953
    self.ex = ex
2954
 
2955
  def read(self, iprot):
2956
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
2957
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
2958
      return
2959
    iprot.readStructBegin()
2960
    while True:
2961
      (fname, ftype, fid) = iprot.readFieldBegin()
2962
      if ftype == TType.STOP:
2963
        break
2964
      if fid == 0:
2965
        if ftype == TType.BOOL:
2966
          self.success = iprot.readBool();
2967
        else:
2968
          iprot.skip(ftype)
2969
      elif fid == 1:
2970
        if ftype == TType.STRUCT:
2971
          self.ex = TransactionServiceException()
2972
          self.ex.read(iprot)
2973
        else:
2974
          iprot.skip(ftype)
2975
      else:
2976
        iprot.skip(ftype)
2977
      iprot.readFieldEnd()
2978
    iprot.readStructEnd()
2979
 
2980
  def write(self, oprot):
2981
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
2982
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
2983
      return
1398 varun.gupt 2984
    oprot.writeStructBegin('enqueueTransactionInfoEmail_result')
1382 varun.gupt 2985
    if self.success != None:
2986
      oprot.writeFieldBegin('success', TType.BOOL, 0)
2987
      oprot.writeBool(self.success)
2988
      oprot.writeFieldEnd()
2989
    if self.ex != None:
2990
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
2991
      self.ex.write(oprot)
2992
      oprot.writeFieldEnd()
2993
    oprot.writeFieldStop()
2994
    oprot.writeStructEnd()
2995
 
2996
  def __repr__(self):
2997
    L = ['%s=%r' % (key, value)
2998
      for key, value in self.__dict__.iteritems()]
2999
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3000
 
3001
  def __eq__(self, other):
3002
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3003
 
3004
  def __ne__(self, other):
3005
    return not (self == other)
3006
 
483 rajveer 3007
class getAllOrders_args:
94 ashish 3008
  """
3009
  Attributes:
483 rajveer 3010
   - status
3011
   - from_date
3012
   - to_date
3013
   - warehouse_id
94 ashish 3014
  """
3015
 
3016
  thrift_spec = (
3017
    None, # 0
483 rajveer 3018
    (1, TType.I32, 'status', None, None, ), # 1
3019
    (2, TType.I64, 'from_date', None, None, ), # 2
3020
    (3, TType.I64, 'to_date', None, None, ), # 3
3021
    (4, TType.I64, 'warehouse_id', None, None, ), # 4
94 ashish 3022
  )
3023
 
483 rajveer 3024
  def __init__(self, status=None, from_date=None, to_date=None, warehouse_id=None,):
3025
    self.status = status
3026
    self.from_date = from_date
3027
    self.to_date = to_date
3028
    self.warehouse_id = warehouse_id
94 ashish 3029
 
3030
  def read(self, iprot):
3031
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3032
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3033
      return
3034
    iprot.readStructBegin()
3035
    while True:
3036
      (fname, ftype, fid) = iprot.readFieldBegin()
3037
      if ftype == TType.STOP:
3038
        break
3039
      if fid == 1:
483 rajveer 3040
        if ftype == TType.I32:
3041
          self.status = iprot.readI32();
94 ashish 3042
        else:
3043
          iprot.skip(ftype)
483 rajveer 3044
      elif fid == 2:
3045
        if ftype == TType.I64:
3046
          self.from_date = iprot.readI64();
94 ashish 3047
        else:
3048
          iprot.skip(ftype)
483 rajveer 3049
      elif fid == 3:
3050
        if ftype == TType.I64:
3051
          self.to_date = iprot.readI64();
94 ashish 3052
        else:
3053
          iprot.skip(ftype)
483 rajveer 3054
      elif fid == 4:
94 ashish 3055
        if ftype == TType.I64:
483 rajveer 3056
          self.warehouse_id = iprot.readI64();
94 ashish 3057
        else:
3058
          iprot.skip(ftype)
3059
      else:
3060
        iprot.skip(ftype)
3061
      iprot.readFieldEnd()
3062
    iprot.readStructEnd()
3063
 
3064
  def write(self, oprot):
3065
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3066
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3067
      return
483 rajveer 3068
    oprot.writeStructBegin('getAllOrders_args')
3069
    if self.status != None:
3070
      oprot.writeFieldBegin('status', TType.I32, 1)
3071
      oprot.writeI32(self.status)
94 ashish 3072
      oprot.writeFieldEnd()
483 rajveer 3073
    if self.from_date != None:
3074
      oprot.writeFieldBegin('from_date', TType.I64, 2)
3075
      oprot.writeI64(self.from_date)
94 ashish 3076
      oprot.writeFieldEnd()
483 rajveer 3077
    if self.to_date != None:
3078
      oprot.writeFieldBegin('to_date', TType.I64, 3)
3079
      oprot.writeI64(self.to_date)
94 ashish 3080
      oprot.writeFieldEnd()
483 rajveer 3081
    if self.warehouse_id != None:
3082
      oprot.writeFieldBegin('warehouse_id', TType.I64, 4)
3083
      oprot.writeI64(self.warehouse_id)
94 ashish 3084
      oprot.writeFieldEnd()
3085
    oprot.writeFieldStop()
3086
    oprot.writeStructEnd()
3087
 
3088
  def __repr__(self):
3089
    L = ['%s=%r' % (key, value)
3090
      for key, value in self.__dict__.iteritems()]
3091
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3092
 
3093
  def __eq__(self, other):
3094
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3095
 
3096
  def __ne__(self, other):
3097
    return not (self == other)
3098
 
483 rajveer 3099
class getAllOrders_result:
94 ashish 3100
  """
3101
  Attributes:
3102
   - success
3103
   - ex
3104
  """
3105
 
3106
  thrift_spec = (
483 rajveer 3107
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
94 ashish 3108
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3109
  )
3110
 
3111
  def __init__(self, success=None, ex=None,):
3112
    self.success = success
3113
    self.ex = ex
3114
 
3115
  def read(self, iprot):
3116
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3117
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3118
      return
3119
    iprot.readStructBegin()
3120
    while True:
3121
      (fname, ftype, fid) = iprot.readFieldBegin()
3122
      if ftype == TType.STOP:
3123
        break
3124
      if fid == 0:
483 rajveer 3125
        if ftype == TType.LIST:
3126
          self.success = []
685 chandransh 3127
          (_etype31, _size28) = iprot.readListBegin()
3128
          for _i32 in xrange(_size28):
3129
            _elem33 = Order()
3130
            _elem33.read(iprot)
3131
            self.success.append(_elem33)
483 rajveer 3132
          iprot.readListEnd()
94 ashish 3133
        else:
3134
          iprot.skip(ftype)
3135
      elif fid == 1:
3136
        if ftype == TType.STRUCT:
3137
          self.ex = TransactionServiceException()
3138
          self.ex.read(iprot)
3139
        else:
3140
          iprot.skip(ftype)
3141
      else:
3142
        iprot.skip(ftype)
3143
      iprot.readFieldEnd()
3144
    iprot.readStructEnd()
3145
 
3146
  def write(self, oprot):
3147
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3148
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3149
      return
483 rajveer 3150
    oprot.writeStructBegin('getAllOrders_result')
94 ashish 3151
    if self.success != None:
483 rajveer 3152
      oprot.writeFieldBegin('success', TType.LIST, 0)
3153
      oprot.writeListBegin(TType.STRUCT, len(self.success))
685 chandransh 3154
      for iter34 in self.success:
3155
        iter34.write(oprot)
483 rajveer 3156
      oprot.writeListEnd()
94 ashish 3157
      oprot.writeFieldEnd()
3158
    if self.ex != None:
3159
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3160
      self.ex.write(oprot)
3161
      oprot.writeFieldEnd()
3162
    oprot.writeFieldStop()
3163
    oprot.writeStructEnd()
3164
 
3165
  def __repr__(self):
3166
    L = ['%s=%r' % (key, value)
3167
      for key, value in self.__dict__.iteritems()]
3168
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3169
 
3170
  def __eq__(self, other):
3171
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3172
 
3173
  def __ne__(self, other):
3174
    return not (self == other)
3175
 
999 varun.gupt 3176
class getOrdersByBillingDate_args:
3177
  """
3178
  Attributes:
3179
   - status
3180
   - start_billing_date
3181
   - end_billing_date
3182
   - warehouse_id
3183
  """
3184
 
3185
  thrift_spec = (
3186
    None, # 0
3187
    (1, TType.I32, 'status', None, None, ), # 1
3188
    (2, TType.I64, 'start_billing_date', None, None, ), # 2
3189
    (3, TType.I64, 'end_billing_date', None, None, ), # 3
3190
    (4, TType.I64, 'warehouse_id', None, None, ), # 4
3191
  )
3192
 
3193
  def __init__(self, status=None, start_billing_date=None, end_billing_date=None, warehouse_id=None,):
3194
    self.status = status
3195
    self.start_billing_date = start_billing_date
3196
    self.end_billing_date = end_billing_date
3197
    self.warehouse_id = warehouse_id
3198
 
3199
  def read(self, iprot):
3200
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3201
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3202
      return
3203
    iprot.readStructBegin()
3204
    while True:
3205
      (fname, ftype, fid) = iprot.readFieldBegin()
3206
      if ftype == TType.STOP:
3207
        break
3208
      if fid == 1:
3209
        if ftype == TType.I32:
3210
          self.status = iprot.readI32();
3211
        else:
3212
          iprot.skip(ftype)
3213
      elif fid == 2:
3214
        if ftype == TType.I64:
3215
          self.start_billing_date = iprot.readI64();
3216
        else:
3217
          iprot.skip(ftype)
3218
      elif fid == 3:
3219
        if ftype == TType.I64:
3220
          self.end_billing_date = iprot.readI64();
3221
        else:
3222
          iprot.skip(ftype)
3223
      elif fid == 4:
3224
        if ftype == TType.I64:
3225
          self.warehouse_id = iprot.readI64();
3226
        else:
3227
          iprot.skip(ftype)
3228
      else:
3229
        iprot.skip(ftype)
3230
      iprot.readFieldEnd()
3231
    iprot.readStructEnd()
3232
 
3233
  def write(self, oprot):
3234
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3235
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3236
      return
3237
    oprot.writeStructBegin('getOrdersByBillingDate_args')
3238
    if self.status != None:
3239
      oprot.writeFieldBegin('status', TType.I32, 1)
3240
      oprot.writeI32(self.status)
3241
      oprot.writeFieldEnd()
3242
    if self.start_billing_date != None:
3243
      oprot.writeFieldBegin('start_billing_date', TType.I64, 2)
3244
      oprot.writeI64(self.start_billing_date)
3245
      oprot.writeFieldEnd()
3246
    if self.end_billing_date != None:
3247
      oprot.writeFieldBegin('end_billing_date', TType.I64, 3)
3248
      oprot.writeI64(self.end_billing_date)
3249
      oprot.writeFieldEnd()
3250
    if self.warehouse_id != None:
3251
      oprot.writeFieldBegin('warehouse_id', TType.I64, 4)
3252
      oprot.writeI64(self.warehouse_id)
3253
      oprot.writeFieldEnd()
3254
    oprot.writeFieldStop()
3255
    oprot.writeStructEnd()
3256
 
3257
  def __repr__(self):
3258
    L = ['%s=%r' % (key, value)
3259
      for key, value in self.__dict__.iteritems()]
3260
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3261
 
3262
  def __eq__(self, other):
3263
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3264
 
3265
  def __ne__(self, other):
3266
    return not (self == other)
3267
 
3268
class getOrdersByBillingDate_result:
3269
  """
3270
  Attributes:
3271
   - success
3272
   - ex
3273
  """
3274
 
3275
  thrift_spec = (
3276
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
3277
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3278
  )
3279
 
3280
  def __init__(self, success=None, ex=None,):
3281
    self.success = success
3282
    self.ex = ex
3283
 
3284
  def read(self, iprot):
3285
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3286
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3287
      return
3288
    iprot.readStructBegin()
3289
    while True:
3290
      (fname, ftype, fid) = iprot.readFieldBegin()
3291
      if ftype == TType.STOP:
3292
        break
3293
      if fid == 0:
3294
        if ftype == TType.LIST:
3295
          self.success = []
3296
          (_etype38, _size35) = iprot.readListBegin()
3297
          for _i39 in xrange(_size35):
3298
            _elem40 = Order()
3299
            _elem40.read(iprot)
3300
            self.success.append(_elem40)
3301
          iprot.readListEnd()
3302
        else:
3303
          iprot.skip(ftype)
3304
      elif fid == 1:
3305
        if ftype == TType.STRUCT:
3306
          self.ex = TransactionServiceException()
3307
          self.ex.read(iprot)
3308
        else:
3309
          iprot.skip(ftype)
3310
      else:
3311
        iprot.skip(ftype)
3312
      iprot.readFieldEnd()
3313
    iprot.readStructEnd()
3314
 
3315
  def write(self, oprot):
3316
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3317
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3318
      return
3319
    oprot.writeStructBegin('getOrdersByBillingDate_result')
3320
    if self.success != None:
3321
      oprot.writeFieldBegin('success', TType.LIST, 0)
3322
      oprot.writeListBegin(TType.STRUCT, len(self.success))
3323
      for iter41 in self.success:
3324
        iter41.write(oprot)
3325
      oprot.writeListEnd()
3326
      oprot.writeFieldEnd()
3327
    if self.ex != None:
3328
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3329
      self.ex.write(oprot)
3330
      oprot.writeFieldEnd()
3331
    oprot.writeFieldStop()
3332
    oprot.writeStructEnd()
3333
 
3334
  def __repr__(self):
3335
    L = ['%s=%r' % (key, value)
3336
      for key, value in self.__dict__.iteritems()]
3337
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3338
 
3339
  def __eq__(self, other):
3340
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3341
 
3342
  def __ne__(self, other):
3343
    return not (self == other)
3344
 
1382 varun.gupt 3345
class getReturnableOrdersForCustomer_args:
3346
  """
3347
  Attributes:
3348
   - customer_id
3349
   - limit
3350
  """
3351
 
3352
  thrift_spec = (
3353
    None, # 0
3354
    (1, TType.I64, 'customer_id', None, None, ), # 1
3355
    (2, TType.I64, 'limit', None, None, ), # 2
3356
  )
3357
 
3358
  def __init__(self, customer_id=None, limit=None,):
3359
    self.customer_id = customer_id
3360
    self.limit = limit
3361
 
3362
  def read(self, iprot):
3363
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3364
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3365
      return
3366
    iprot.readStructBegin()
3367
    while True:
3368
      (fname, ftype, fid) = iprot.readFieldBegin()
3369
      if ftype == TType.STOP:
3370
        break
3371
      if fid == 1:
3372
        if ftype == TType.I64:
3373
          self.customer_id = iprot.readI64();
3374
        else:
3375
          iprot.skip(ftype)
3376
      elif fid == 2:
3377
        if ftype == TType.I64:
3378
          self.limit = iprot.readI64();
3379
        else:
3380
          iprot.skip(ftype)
3381
      else:
3382
        iprot.skip(ftype)
3383
      iprot.readFieldEnd()
3384
    iprot.readStructEnd()
3385
 
3386
  def write(self, oprot):
3387
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3388
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3389
      return
3390
    oprot.writeStructBegin('getReturnableOrdersForCustomer_args')
3391
    if self.customer_id != None:
3392
      oprot.writeFieldBegin('customer_id', TType.I64, 1)
3393
      oprot.writeI64(self.customer_id)
3394
      oprot.writeFieldEnd()
3395
    if self.limit != None:
3396
      oprot.writeFieldBegin('limit', TType.I64, 2)
3397
      oprot.writeI64(self.limit)
3398
      oprot.writeFieldEnd()
3399
    oprot.writeFieldStop()
3400
    oprot.writeStructEnd()
3401
 
3402
  def __repr__(self):
3403
    L = ['%s=%r' % (key, value)
3404
      for key, value in self.__dict__.iteritems()]
3405
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3406
 
3407
  def __eq__(self, other):
3408
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3409
 
3410
  def __ne__(self, other):
3411
    return not (self == other)
3412
 
3413
class getReturnableOrdersForCustomer_result:
3414
  """
3415
  Attributes:
3416
   - success
3417
   - ex
3418
  """
3419
 
3420
  thrift_spec = (
3421
    (0, TType.LIST, 'success', (TType.I64,None), None, ), # 0
3422
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3423
  )
3424
 
3425
  def __init__(self, success=None, ex=None,):
3426
    self.success = success
3427
    self.ex = ex
3428
 
3429
  def read(self, iprot):
3430
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3431
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3432
      return
3433
    iprot.readStructBegin()
3434
    while True:
3435
      (fname, ftype, fid) = iprot.readFieldBegin()
3436
      if ftype == TType.STOP:
3437
        break
3438
      if fid == 0:
3439
        if ftype == TType.LIST:
3440
          self.success = []
3441
          (_etype45, _size42) = iprot.readListBegin()
3442
          for _i46 in xrange(_size42):
3443
            _elem47 = iprot.readI64();
3444
            self.success.append(_elem47)
3445
          iprot.readListEnd()
3446
        else:
3447
          iprot.skip(ftype)
3448
      elif fid == 1:
3449
        if ftype == TType.STRUCT:
3450
          self.ex = TransactionServiceException()
3451
          self.ex.read(iprot)
3452
        else:
3453
          iprot.skip(ftype)
3454
      else:
3455
        iprot.skip(ftype)
3456
      iprot.readFieldEnd()
3457
    iprot.readStructEnd()
3458
 
3459
  def write(self, oprot):
3460
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3461
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3462
      return
3463
    oprot.writeStructBegin('getReturnableOrdersForCustomer_result')
3464
    if self.success != None:
3465
      oprot.writeFieldBegin('success', TType.LIST, 0)
3466
      oprot.writeListBegin(TType.I64, len(self.success))
3467
      for iter48 in self.success:
3468
        oprot.writeI64(iter48)
3469
      oprot.writeListEnd()
3470
      oprot.writeFieldEnd()
3471
    if self.ex != None:
3472
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3473
      self.ex.write(oprot)
3474
      oprot.writeFieldEnd()
3475
    oprot.writeFieldStop()
3476
    oprot.writeStructEnd()
3477
 
3478
  def __repr__(self):
3479
    L = ['%s=%r' % (key, value)
3480
      for key, value in self.__dict__.iteritems()]
3481
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3482
 
3483
  def __eq__(self, other):
3484
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3485
 
3486
  def __ne__(self, other):
3487
    return not (self == other)
3488
 
3489
class getCancellableOrdersForCustomer_args:
3490
  """
3491
  Attributes:
3492
   - customer_id
3493
   - limit
3494
  """
3495
 
3496
  thrift_spec = (
3497
    None, # 0
3498
    (1, TType.I64, 'customer_id', None, None, ), # 1
3499
    (2, TType.I64, 'limit', None, None, ), # 2
3500
  )
3501
 
3502
  def __init__(self, customer_id=None, limit=None,):
3503
    self.customer_id = customer_id
3504
    self.limit = limit
3505
 
3506
  def read(self, iprot):
3507
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3508
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3509
      return
3510
    iprot.readStructBegin()
3511
    while True:
3512
      (fname, ftype, fid) = iprot.readFieldBegin()
3513
      if ftype == TType.STOP:
3514
        break
3515
      if fid == 1:
3516
        if ftype == TType.I64:
3517
          self.customer_id = iprot.readI64();
3518
        else:
3519
          iprot.skip(ftype)
3520
      elif fid == 2:
3521
        if ftype == TType.I64:
3522
          self.limit = iprot.readI64();
3523
        else:
3524
          iprot.skip(ftype)
3525
      else:
3526
        iprot.skip(ftype)
3527
      iprot.readFieldEnd()
3528
    iprot.readStructEnd()
3529
 
3530
  def write(self, oprot):
3531
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3532
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3533
      return
3534
    oprot.writeStructBegin('getCancellableOrdersForCustomer_args')
3535
    if self.customer_id != None:
3536
      oprot.writeFieldBegin('customer_id', TType.I64, 1)
3537
      oprot.writeI64(self.customer_id)
3538
      oprot.writeFieldEnd()
3539
    if self.limit != None:
3540
      oprot.writeFieldBegin('limit', TType.I64, 2)
3541
      oprot.writeI64(self.limit)
3542
      oprot.writeFieldEnd()
3543
    oprot.writeFieldStop()
3544
    oprot.writeStructEnd()
3545
 
3546
  def __repr__(self):
3547
    L = ['%s=%r' % (key, value)
3548
      for key, value in self.__dict__.iteritems()]
3549
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3550
 
3551
  def __eq__(self, other):
3552
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3553
 
3554
  def __ne__(self, other):
3555
    return not (self == other)
3556
 
3557
class getCancellableOrdersForCustomer_result:
3558
  """
3559
  Attributes:
3560
   - success
3561
   - ex
3562
  """
3563
 
3564
  thrift_spec = (
3565
    (0, TType.LIST, 'success', (TType.I64,None), None, ), # 0
3566
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3567
  )
3568
 
3569
  def __init__(self, success=None, ex=None,):
3570
    self.success = success
3571
    self.ex = ex
3572
 
3573
  def read(self, iprot):
3574
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3575
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3576
      return
3577
    iprot.readStructBegin()
3578
    while True:
3579
      (fname, ftype, fid) = iprot.readFieldBegin()
3580
      if ftype == TType.STOP:
3581
        break
3582
      if fid == 0:
3583
        if ftype == TType.LIST:
3584
          self.success = []
3585
          (_etype52, _size49) = iprot.readListBegin()
3586
          for _i53 in xrange(_size49):
3587
            _elem54 = iprot.readI64();
3588
            self.success.append(_elem54)
3589
          iprot.readListEnd()
3590
        else:
3591
          iprot.skip(ftype)
3592
      elif fid == 1:
3593
        if ftype == TType.STRUCT:
3594
          self.ex = TransactionServiceException()
3595
          self.ex.read(iprot)
3596
        else:
3597
          iprot.skip(ftype)
3598
      else:
3599
        iprot.skip(ftype)
3600
      iprot.readFieldEnd()
3601
    iprot.readStructEnd()
3602
 
3603
  def write(self, oprot):
3604
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3605
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3606
      return
3607
    oprot.writeStructBegin('getCancellableOrdersForCustomer_result')
3608
    if self.success != None:
3609
      oprot.writeFieldBegin('success', TType.LIST, 0)
3610
      oprot.writeListBegin(TType.I64, len(self.success))
3611
      for iter55 in self.success:
3612
        oprot.writeI64(iter55)
3613
      oprot.writeListEnd()
3614
      oprot.writeFieldEnd()
3615
    if self.ex != None:
3616
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3617
      self.ex.write(oprot)
3618
      oprot.writeFieldEnd()
3619
    oprot.writeFieldStop()
3620
    oprot.writeStructEnd()
3621
 
3622
  def __repr__(self):
3623
    L = ['%s=%r' % (key, value)
3624
      for key, value in self.__dict__.iteritems()]
3625
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3626
 
3627
  def __eq__(self, other):
3628
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3629
 
3630
  def __ne__(self, other):
3631
    return not (self == other)
3632
 
483 rajveer 3633
class changeOrderStatus_args:
94 ashish 3634
  """
3635
  Attributes:
483 rajveer 3636
   - orderId
3637
   - status
3638
   - description
94 ashish 3639
  """
3640
 
3641
  thrift_spec = (
3642
    None, # 0
483 rajveer 3643
    (1, TType.I64, 'orderId', None, None, ), # 1
3644
    (2, TType.I32, 'status', None, None, ), # 2
3645
    (3, TType.STRING, 'description', None, None, ), # 3
94 ashish 3646
  )
3647
 
483 rajveer 3648
  def __init__(self, orderId=None, status=None, description=None,):
3649
    self.orderId = orderId
3650
    self.status = status
3651
    self.description = description
94 ashish 3652
 
3653
  def read(self, iprot):
3654
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3655
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3656
      return
3657
    iprot.readStructBegin()
3658
    while True:
3659
      (fname, ftype, fid) = iprot.readFieldBegin()
3660
      if ftype == TType.STOP:
3661
        break
3662
      if fid == 1:
3663
        if ftype == TType.I64:
483 rajveer 3664
          self.orderId = iprot.readI64();
94 ashish 3665
        else:
3666
          iprot.skip(ftype)
3667
      elif fid == 2:
483 rajveer 3668
        if ftype == TType.I32:
3669
          self.status = iprot.readI32();
94 ashish 3670
        else:
3671
          iprot.skip(ftype)
483 rajveer 3672
      elif fid == 3:
3673
        if ftype == TType.STRING:
3674
          self.description = iprot.readString();
3675
        else:
3676
          iprot.skip(ftype)
94 ashish 3677
      else:
3678
        iprot.skip(ftype)
3679
      iprot.readFieldEnd()
3680
    iprot.readStructEnd()
3681
 
3682
  def write(self, oprot):
3683
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3684
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3685
      return
483 rajveer 3686
    oprot.writeStructBegin('changeOrderStatus_args')
3687
    if self.orderId != None:
3688
      oprot.writeFieldBegin('orderId', TType.I64, 1)
3689
      oprot.writeI64(self.orderId)
94 ashish 3690
      oprot.writeFieldEnd()
483 rajveer 3691
    if self.status != None:
3692
      oprot.writeFieldBegin('status', TType.I32, 2)
3693
      oprot.writeI32(self.status)
94 ashish 3694
      oprot.writeFieldEnd()
483 rajveer 3695
    if self.description != None:
3696
      oprot.writeFieldBegin('description', TType.STRING, 3)
3697
      oprot.writeString(self.description)
3698
      oprot.writeFieldEnd()
94 ashish 3699
    oprot.writeFieldStop()
3700
    oprot.writeStructEnd()
3701
 
3702
  def __repr__(self):
3703
    L = ['%s=%r' % (key, value)
3704
      for key, value in self.__dict__.iteritems()]
3705
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3706
 
3707
  def __eq__(self, other):
3708
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3709
 
3710
  def __ne__(self, other):
3711
    return not (self == other)
3712
 
483 rajveer 3713
class changeOrderStatus_result:
94 ashish 3714
  """
3715
  Attributes:
3716
   - success
3717
   - ex
3718
  """
3719
 
3720
  thrift_spec = (
3721
    (0, TType.BOOL, 'success', None, None, ), # 0
3722
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3723
  )
3724
 
3725
  def __init__(self, success=None, ex=None,):
3726
    self.success = success
3727
    self.ex = ex
3728
 
3729
  def read(self, iprot):
3730
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3731
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3732
      return
3733
    iprot.readStructBegin()
3734
    while True:
3735
      (fname, ftype, fid) = iprot.readFieldBegin()
3736
      if ftype == TType.STOP:
3737
        break
3738
      if fid == 0:
3739
        if ftype == TType.BOOL:
3740
          self.success = iprot.readBool();
3741
        else:
3742
          iprot.skip(ftype)
3743
      elif fid == 1:
3744
        if ftype == TType.STRUCT:
3745
          self.ex = TransactionServiceException()
3746
          self.ex.read(iprot)
3747
        else:
3748
          iprot.skip(ftype)
3749
      else:
3750
        iprot.skip(ftype)
3751
      iprot.readFieldEnd()
3752
    iprot.readStructEnd()
3753
 
3754
  def write(self, oprot):
3755
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3756
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3757
      return
483 rajveer 3758
    oprot.writeStructBegin('changeOrderStatus_result')
94 ashish 3759
    if self.success != None:
3760
      oprot.writeFieldBegin('success', TType.BOOL, 0)
3761
      oprot.writeBool(self.success)
3762
      oprot.writeFieldEnd()
3763
    if self.ex != None:
3764
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3765
      self.ex.write(oprot)
3766
      oprot.writeFieldEnd()
3767
    oprot.writeFieldStop()
3768
    oprot.writeStructEnd()
3769
 
3770
  def __repr__(self):
3771
    L = ['%s=%r' % (key, value)
3772
      for key, value in self.__dict__.iteritems()]
3773
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3774
 
3775
  def __eq__(self, other):
3776
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3777
 
3778
  def __ne__(self, other):
3779
    return not (self == other)
3780
 
494 rajveer 3781
class addBillingDetails_args:
3782
  """
3783
  Attributes:
3784
   - orderId
3785
   - invoice_number
3786
   - billed_by
3787
  """
3788
 
3789
  thrift_spec = (
3790
    None, # 0
3791
    (1, TType.I64, 'orderId', None, None, ), # 1
3792
    (2, TType.STRING, 'invoice_number', None, None, ), # 2
1149 chandransh 3793
    (3, TType.STRING, 'billed_by', None, None, ), # 3
494 rajveer 3794
  )
3795
 
1149 chandransh 3796
  def __init__(self, orderId=None, invoice_number=None, billed_by=None,):
494 rajveer 3797
    self.orderId = orderId
3798
    self.invoice_number = invoice_number
3799
    self.billed_by = billed_by
3800
 
3801
  def read(self, iprot):
3802
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3803
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3804
      return
3805
    iprot.readStructBegin()
3806
    while True:
3807
      (fname, ftype, fid) = iprot.readFieldBegin()
3808
      if ftype == TType.STOP:
3809
        break
3810
      if fid == 1:
3811
        if ftype == TType.I64:
3812
          self.orderId = iprot.readI64();
3813
        else:
3814
          iprot.skip(ftype)
3815
      elif fid == 2:
3816
        if ftype == TType.STRING:
3817
          self.invoice_number = iprot.readString();
3818
        else:
3819
          iprot.skip(ftype)
3820
      elif fid == 3:
3821
        if ftype == TType.STRING:
3822
          self.billed_by = iprot.readString();
3823
        else:
3824
          iprot.skip(ftype)
3825
      else:
3826
        iprot.skip(ftype)
3827
      iprot.readFieldEnd()
3828
    iprot.readStructEnd()
3829
 
3830
  def write(self, oprot):
3831
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3832
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3833
      return
3834
    oprot.writeStructBegin('addBillingDetails_args')
3835
    if self.orderId != None:
3836
      oprot.writeFieldBegin('orderId', TType.I64, 1)
3837
      oprot.writeI64(self.orderId)
3838
      oprot.writeFieldEnd()
3839
    if self.invoice_number != None:
3840
      oprot.writeFieldBegin('invoice_number', TType.STRING, 2)
3841
      oprot.writeString(self.invoice_number)
3842
      oprot.writeFieldEnd()
3843
    if self.billed_by != None:
1149 chandransh 3844
      oprot.writeFieldBegin('billed_by', TType.STRING, 3)
494 rajveer 3845
      oprot.writeString(self.billed_by)
3846
      oprot.writeFieldEnd()
3847
    oprot.writeFieldStop()
3848
    oprot.writeStructEnd()
3849
 
3850
  def __repr__(self):
3851
    L = ['%s=%r' % (key, value)
3852
      for key, value in self.__dict__.iteritems()]
3853
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3854
 
3855
  def __eq__(self, other):
3856
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3857
 
3858
  def __ne__(self, other):
3859
    return not (self == other)
3860
 
3861
class addBillingDetails_result:
3862
  """
3863
  Attributes:
3864
   - success
3865
   - ex
3866
  """
3867
 
3868
  thrift_spec = (
3869
    (0, TType.BOOL, 'success', None, None, ), # 0
3870
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
3871
  )
3872
 
3873
  def __init__(self, success=None, ex=None,):
3874
    self.success = success
3875
    self.ex = ex
3876
 
3877
  def read(self, iprot):
3878
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3879
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3880
      return
3881
    iprot.readStructBegin()
3882
    while True:
3883
      (fname, ftype, fid) = iprot.readFieldBegin()
3884
      if ftype == TType.STOP:
3885
        break
3886
      if fid == 0:
3887
        if ftype == TType.BOOL:
3888
          self.success = iprot.readBool();
3889
        else:
3890
          iprot.skip(ftype)
3891
      elif fid == 1:
3892
        if ftype == TType.STRUCT:
3893
          self.ex = TransactionServiceException()
3894
          self.ex.read(iprot)
3895
        else:
3896
          iprot.skip(ftype)
3897
      else:
3898
        iprot.skip(ftype)
3899
      iprot.readFieldEnd()
3900
    iprot.readStructEnd()
3901
 
3902
  def write(self, oprot):
3903
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3904
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3905
      return
3906
    oprot.writeStructBegin('addBillingDetails_result')
3907
    if self.success != None:
3908
      oprot.writeFieldBegin('success', TType.BOOL, 0)
3909
      oprot.writeBool(self.success)
3910
      oprot.writeFieldEnd()
3911
    if self.ex != None:
3912
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
3913
      self.ex.write(oprot)
3914
      oprot.writeFieldEnd()
3915
    oprot.writeFieldStop()
3916
    oprot.writeStructEnd()
3917
 
3918
  def __repr__(self):
3919
    L = ['%s=%r' % (key, value)
3920
      for key, value in self.__dict__.iteritems()]
3921
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3922
 
3923
  def __eq__(self, other):
3924
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3925
 
3926
  def __ne__(self, other):
3927
    return not (self == other)
3928
 
1149 chandransh 3929
class addJacketNumber_args:
3930
  """
3931
  Attributes:
3932
   - orderId
3933
   - jacketNumber
3934
  """
3935
 
3936
  thrift_spec = (
3937
    None, # 0
3938
    (1, TType.I64, 'orderId', None, None, ), # 1
3939
    (2, TType.I64, 'jacketNumber', None, None, ), # 2
3940
  )
3941
 
3942
  def __init__(self, orderId=None, jacketNumber=None,):
3943
    self.orderId = orderId
3944
    self.jacketNumber = jacketNumber
3945
 
3946
  def read(self, iprot):
3947
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
3948
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
3949
      return
3950
    iprot.readStructBegin()
3951
    while True:
3952
      (fname, ftype, fid) = iprot.readFieldBegin()
3953
      if ftype == TType.STOP:
3954
        break
3955
      if fid == 1:
3956
        if ftype == TType.I64:
3957
          self.orderId = iprot.readI64();
3958
        else:
3959
          iprot.skip(ftype)
3960
      elif fid == 2:
3961
        if ftype == TType.I64:
3962
          self.jacketNumber = iprot.readI64();
3963
        else:
3964
          iprot.skip(ftype)
3965
      else:
3966
        iprot.skip(ftype)
3967
      iprot.readFieldEnd()
3968
    iprot.readStructEnd()
3969
 
3970
  def write(self, oprot):
3971
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
3972
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
3973
      return
3974
    oprot.writeStructBegin('addJacketNumber_args')
3975
    if self.orderId != None:
3976
      oprot.writeFieldBegin('orderId', TType.I64, 1)
3977
      oprot.writeI64(self.orderId)
3978
      oprot.writeFieldEnd()
3979
    if self.jacketNumber != None:
3980
      oprot.writeFieldBegin('jacketNumber', TType.I64, 2)
3981
      oprot.writeI64(self.jacketNumber)
3982
      oprot.writeFieldEnd()
3983
    oprot.writeFieldStop()
3984
    oprot.writeStructEnd()
3985
 
3986
  def __repr__(self):
3987
    L = ['%s=%r' % (key, value)
3988
      for key, value in self.__dict__.iteritems()]
3989
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
3990
 
3991
  def __eq__(self, other):
3992
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
3993
 
3994
  def __ne__(self, other):
3995
    return not (self == other)
3996
 
3997
class addJacketNumber_result:
3998
  """
3999
  Attributes:
4000
   - success
4001
   - ex
4002
  """
4003
 
4004
  thrift_spec = (
4005
    (0, TType.BOOL, 'success', None, None, ), # 0
4006
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4007
  )
4008
 
4009
  def __init__(self, success=None, ex=None,):
4010
    self.success = success
4011
    self.ex = ex
4012
 
4013
  def read(self, iprot):
4014
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4015
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4016
      return
4017
    iprot.readStructBegin()
4018
    while True:
4019
      (fname, ftype, fid) = iprot.readFieldBegin()
4020
      if ftype == TType.STOP:
4021
        break
4022
      if fid == 0:
4023
        if ftype == TType.BOOL:
4024
          self.success = iprot.readBool();
4025
        else:
4026
          iprot.skip(ftype)
4027
      elif fid == 1:
4028
        if ftype == TType.STRUCT:
4029
          self.ex = TransactionServiceException()
4030
          self.ex.read(iprot)
4031
        else:
4032
          iprot.skip(ftype)
4033
      else:
4034
        iprot.skip(ftype)
4035
      iprot.readFieldEnd()
4036
    iprot.readStructEnd()
4037
 
4038
  def write(self, oprot):
4039
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4040
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4041
      return
4042
    oprot.writeStructBegin('addJacketNumber_result')
4043
    if self.success != None:
4044
      oprot.writeFieldBegin('success', TType.BOOL, 0)
4045
      oprot.writeBool(self.success)
4046
      oprot.writeFieldEnd()
4047
    if self.ex != None:
4048
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4049
      self.ex.write(oprot)
4050
      oprot.writeFieldEnd()
4051
    oprot.writeFieldStop()
4052
    oprot.writeStructEnd()
4053
 
4054
  def __repr__(self):
4055
    L = ['%s=%r' % (key, value)
4056
      for key, value in self.__dict__.iteritems()]
4057
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4058
 
4059
  def __eq__(self, other):
4060
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4061
 
4062
  def __ne__(self, other):
4063
    return not (self == other)
4064
 
921 rajveer 4065
class acceptOrder_args:
4066
  """
4067
  Attributes:
4068
   - orderId
4069
  """
4070
 
4071
  thrift_spec = (
4072
    None, # 0
4073
    (1, TType.I64, 'orderId', None, None, ), # 1
4074
  )
4075
 
4076
  def __init__(self, orderId=None,):
4077
    self.orderId = orderId
4078
 
4079
  def read(self, iprot):
4080
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4081
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4082
      return
4083
    iprot.readStructBegin()
4084
    while True:
4085
      (fname, ftype, fid) = iprot.readFieldBegin()
4086
      if ftype == TType.STOP:
4087
        break
4088
      if fid == 1:
4089
        if ftype == TType.I64:
4090
          self.orderId = iprot.readI64();
4091
        else:
4092
          iprot.skip(ftype)
4093
      else:
4094
        iprot.skip(ftype)
4095
      iprot.readFieldEnd()
4096
    iprot.readStructEnd()
4097
 
4098
  def write(self, oprot):
4099
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4100
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4101
      return
4102
    oprot.writeStructBegin('acceptOrder_args')
4103
    if self.orderId != None:
4104
      oprot.writeFieldBegin('orderId', TType.I64, 1)
4105
      oprot.writeI64(self.orderId)
4106
      oprot.writeFieldEnd()
4107
    oprot.writeFieldStop()
4108
    oprot.writeStructEnd()
4109
 
4110
  def __repr__(self):
4111
    L = ['%s=%r' % (key, value)
4112
      for key, value in self.__dict__.iteritems()]
4113
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4114
 
4115
  def __eq__(self, other):
4116
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4117
 
4118
  def __ne__(self, other):
4119
    return not (self == other)
4120
 
4121
class acceptOrder_result:
4122
  """
4123
  Attributes:
4124
   - success
4125
   - ex
4126
  """
4127
 
4128
  thrift_spec = (
4129
    (0, TType.BOOL, 'success', None, None, ), # 0
4130
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4131
  )
4132
 
4133
  def __init__(self, success=None, ex=None,):
4134
    self.success = success
4135
    self.ex = ex
4136
 
4137
  def read(self, iprot):
4138
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4139
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4140
      return
4141
    iprot.readStructBegin()
4142
    while True:
4143
      (fname, ftype, fid) = iprot.readFieldBegin()
4144
      if ftype == TType.STOP:
4145
        break
4146
      if fid == 0:
4147
        if ftype == TType.BOOL:
4148
          self.success = iprot.readBool();
4149
        else:
4150
          iprot.skip(ftype)
4151
      elif fid == 1:
4152
        if ftype == TType.STRUCT:
4153
          self.ex = TransactionServiceException()
4154
          self.ex.read(iprot)
4155
        else:
4156
          iprot.skip(ftype)
4157
      else:
4158
        iprot.skip(ftype)
4159
      iprot.readFieldEnd()
4160
    iprot.readStructEnd()
4161
 
4162
  def write(self, oprot):
4163
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4164
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4165
      return
4166
    oprot.writeStructBegin('acceptOrder_result')
4167
    if self.success != None:
4168
      oprot.writeFieldBegin('success', TType.BOOL, 0)
4169
      oprot.writeBool(self.success)
4170
      oprot.writeFieldEnd()
4171
    if self.ex != None:
4172
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4173
      self.ex.write(oprot)
4174
      oprot.writeFieldEnd()
4175
    oprot.writeFieldStop()
4176
    oprot.writeStructEnd()
4177
 
4178
  def __repr__(self):
4179
    L = ['%s=%r' % (key, value)
4180
      for key, value in self.__dict__.iteritems()]
4181
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4182
 
4183
  def __eq__(self, other):
4184
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4185
 
4186
  def __ne__(self, other):
4187
    return not (self == other)
4188
 
4189
class billOrder_args:
4190
  """
4191
  Attributes:
4192
   - orderId
4193
  """
4194
 
4195
  thrift_spec = (
4196
    None, # 0
4197
    (1, TType.I64, 'orderId', None, None, ), # 1
4198
  )
4199
 
4200
  def __init__(self, orderId=None,):
4201
    self.orderId = orderId
4202
 
4203
  def read(self, iprot):
4204
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4205
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4206
      return
4207
    iprot.readStructBegin()
4208
    while True:
4209
      (fname, ftype, fid) = iprot.readFieldBegin()
4210
      if ftype == TType.STOP:
4211
        break
4212
      if fid == 1:
4213
        if ftype == TType.I64:
4214
          self.orderId = iprot.readI64();
4215
        else:
4216
          iprot.skip(ftype)
4217
      else:
4218
        iprot.skip(ftype)
4219
      iprot.readFieldEnd()
4220
    iprot.readStructEnd()
4221
 
4222
  def write(self, oprot):
4223
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4224
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4225
      return
4226
    oprot.writeStructBegin('billOrder_args')
4227
    if self.orderId != None:
4228
      oprot.writeFieldBegin('orderId', TType.I64, 1)
4229
      oprot.writeI64(self.orderId)
4230
      oprot.writeFieldEnd()
4231
    oprot.writeFieldStop()
4232
    oprot.writeStructEnd()
4233
 
4234
  def __repr__(self):
4235
    L = ['%s=%r' % (key, value)
4236
      for key, value in self.__dict__.iteritems()]
4237
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4238
 
4239
  def __eq__(self, other):
4240
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4241
 
4242
  def __ne__(self, other):
4243
    return not (self == other)
4244
 
4245
class billOrder_result:
4246
  """
4247
  Attributes:
4248
   - success
4249
   - ex
4250
  """
4251
 
4252
  thrift_spec = (
4253
    (0, TType.BOOL, 'success', None, None, ), # 0
4254
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4255
  )
4256
 
4257
  def __init__(self, success=None, ex=None,):
4258
    self.success = success
4259
    self.ex = ex
4260
 
4261
  def read(self, iprot):
4262
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4263
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4264
      return
4265
    iprot.readStructBegin()
4266
    while True:
4267
      (fname, ftype, fid) = iprot.readFieldBegin()
4268
      if ftype == TType.STOP:
4269
        break
4270
      if fid == 0:
4271
        if ftype == TType.BOOL:
4272
          self.success = iprot.readBool();
4273
        else:
4274
          iprot.skip(ftype)
4275
      elif fid == 1:
4276
        if ftype == TType.STRUCT:
4277
          self.ex = TransactionServiceException()
4278
          self.ex.read(iprot)
4279
        else:
4280
          iprot.skip(ftype)
4281
      else:
4282
        iprot.skip(ftype)
4283
      iprot.readFieldEnd()
4284
    iprot.readStructEnd()
4285
 
4286
  def write(self, oprot):
4287
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4288
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4289
      return
4290
    oprot.writeStructBegin('billOrder_result')
4291
    if self.success != None:
4292
      oprot.writeFieldBegin('success', TType.BOOL, 0)
4293
      oprot.writeBool(self.success)
4294
      oprot.writeFieldEnd()
4295
    if self.ex != None:
4296
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4297
      self.ex.write(oprot)
4298
      oprot.writeFieldEnd()
4299
    oprot.writeFieldStop()
4300
    oprot.writeStructEnd()
4301
 
4302
  def __repr__(self):
4303
    L = ['%s=%r' % (key, value)
4304
      for key, value in self.__dict__.iteritems()]
4305
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4306
 
4307
  def __eq__(self, other):
4308
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4309
 
4310
  def __ne__(self, other):
4311
    return not (self == other)
4312
 
483 rajveer 4313
class getOrdersForTransaction_args:
94 ashish 4314
  """
4315
  Attributes:
4316
   - transactionId
1528 ankur.sing 4317
   - customerId
94 ashish 4318
  """
4319
 
4320
  thrift_spec = (
4321
    None, # 0
4322
    (1, TType.I64, 'transactionId', None, None, ), # 1
1528 ankur.sing 4323
    (2, TType.I64, 'customerId', None, None, ), # 2
94 ashish 4324
  )
4325
 
1528 ankur.sing 4326
  def __init__(self, transactionId=None, customerId=None,):
94 ashish 4327
    self.transactionId = transactionId
1528 ankur.sing 4328
    self.customerId = customerId
94 ashish 4329
 
4330
  def read(self, iprot):
4331
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4332
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4333
      return
4334
    iprot.readStructBegin()
4335
    while True:
4336
      (fname, ftype, fid) = iprot.readFieldBegin()
4337
      if ftype == TType.STOP:
4338
        break
4339
      if fid == 1:
4340
        if ftype == TType.I64:
4341
          self.transactionId = iprot.readI64();
4342
        else:
4343
          iprot.skip(ftype)
1528 ankur.sing 4344
      elif fid == 2:
4345
        if ftype == TType.I64:
4346
          self.customerId = iprot.readI64();
4347
        else:
4348
          iprot.skip(ftype)
94 ashish 4349
      else:
4350
        iprot.skip(ftype)
4351
      iprot.readFieldEnd()
4352
    iprot.readStructEnd()
4353
 
4354
  def write(self, oprot):
4355
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4356
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4357
      return
483 rajveer 4358
    oprot.writeStructBegin('getOrdersForTransaction_args')
94 ashish 4359
    if self.transactionId != None:
4360
      oprot.writeFieldBegin('transactionId', TType.I64, 1)
4361
      oprot.writeI64(self.transactionId)
4362
      oprot.writeFieldEnd()
1528 ankur.sing 4363
    if self.customerId != None:
4364
      oprot.writeFieldBegin('customerId', TType.I64, 2)
4365
      oprot.writeI64(self.customerId)
4366
      oprot.writeFieldEnd()
94 ashish 4367
    oprot.writeFieldStop()
4368
    oprot.writeStructEnd()
4369
 
4370
  def __repr__(self):
4371
    L = ['%s=%r' % (key, value)
4372
      for key, value in self.__dict__.iteritems()]
4373
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4374
 
4375
  def __eq__(self, other):
4376
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4377
 
4378
  def __ne__(self, other):
4379
    return not (self == other)
4380
 
483 rajveer 4381
class getOrdersForTransaction_result:
94 ashish 4382
  """
4383
  Attributes:
4384
   - success
4385
   - ex
4386
  """
4387
 
4388
  thrift_spec = (
483 rajveer 4389
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
94 ashish 4390
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4391
  )
4392
 
4393
  def __init__(self, success=None, ex=None,):
4394
    self.success = success
4395
    self.ex = ex
4396
 
4397
  def read(self, iprot):
4398
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4399
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4400
      return
4401
    iprot.readStructBegin()
4402
    while True:
4403
      (fname, ftype, fid) = iprot.readFieldBegin()
4404
      if ftype == TType.STOP:
4405
        break
4406
      if fid == 0:
483 rajveer 4407
        if ftype == TType.LIST:
4408
          self.success = []
1382 varun.gupt 4409
          (_etype59, _size56) = iprot.readListBegin()
4410
          for _i60 in xrange(_size56):
4411
            _elem61 = Order()
4412
            _elem61.read(iprot)
4413
            self.success.append(_elem61)
483 rajveer 4414
          iprot.readListEnd()
94 ashish 4415
        else:
4416
          iprot.skip(ftype)
4417
      elif fid == 1:
4418
        if ftype == TType.STRUCT:
4419
          self.ex = TransactionServiceException()
4420
          self.ex.read(iprot)
4421
        else:
4422
          iprot.skip(ftype)
4423
      else:
4424
        iprot.skip(ftype)
4425
      iprot.readFieldEnd()
4426
    iprot.readStructEnd()
4427
 
4428
  def write(self, oprot):
4429
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4430
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4431
      return
483 rajveer 4432
    oprot.writeStructBegin('getOrdersForTransaction_result')
94 ashish 4433
    if self.success != None:
483 rajveer 4434
      oprot.writeFieldBegin('success', TType.LIST, 0)
4435
      oprot.writeListBegin(TType.STRUCT, len(self.success))
1382 varun.gupt 4436
      for iter62 in self.success:
4437
        iter62.write(oprot)
483 rajveer 4438
      oprot.writeListEnd()
94 ashish 4439
      oprot.writeFieldEnd()
4440
    if self.ex != None:
4441
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4442
      self.ex.write(oprot)
4443
      oprot.writeFieldEnd()
4444
    oprot.writeFieldStop()
4445
    oprot.writeStructEnd()
4446
 
4447
  def __repr__(self):
4448
    L = ['%s=%r' % (key, value)
4449
      for key, value in self.__dict__.iteritems()]
4450
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4451
 
4452
  def __eq__(self, other):
4453
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4454
 
4455
  def __ne__(self, other):
4456
    return not (self == other)
4457
 
483 rajveer 4458
class getOrdersForCustomer_args:
94 ashish 4459
  """
4460
  Attributes:
483 rajveer 4461
   - customerId
4462
   - from_date
4463
   - to_date
4464
   - status
94 ashish 4465
  """
4466
 
4467
  thrift_spec = (
4468
    None, # 0
483 rajveer 4469
    (1, TType.I64, 'customerId', None, None, ), # 1
4470
    (2, TType.I64, 'from_date', None, None, ), # 2
4471
    (3, TType.I64, 'to_date', None, None, ), # 3
4472
    (4, TType.I32, 'status', None, None, ), # 4
94 ashish 4473
  )
4474
 
483 rajveer 4475
  def __init__(self, customerId=None, from_date=None, to_date=None, status=None,):
4476
    self.customerId = customerId
4477
    self.from_date = from_date
4478
    self.to_date = to_date
4479
    self.status = status
94 ashish 4480
 
4481
  def read(self, iprot):
4482
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4483
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4484
      return
4485
    iprot.readStructBegin()
4486
    while True:
4487
      (fname, ftype, fid) = iprot.readFieldBegin()
4488
      if ftype == TType.STOP:
4489
        break
4490
      if fid == 1:
4491
        if ftype == TType.I64:
483 rajveer 4492
          self.customerId = iprot.readI64();
94 ashish 4493
        else:
4494
          iprot.skip(ftype)
4495
      elif fid == 2:
4496
        if ftype == TType.I64:
483 rajveer 4497
          self.from_date = iprot.readI64();
94 ashish 4498
        else:
4499
          iprot.skip(ftype)
4500
      elif fid == 3:
4501
        if ftype == TType.I64:
483 rajveer 4502
          self.to_date = iprot.readI64();
94 ashish 4503
        else:
4504
          iprot.skip(ftype)
483 rajveer 4505
      elif fid == 4:
4506
        if ftype == TType.I32:
4507
          self.status = iprot.readI32();
4508
        else:
4509
          iprot.skip(ftype)
94 ashish 4510
      else:
4511
        iprot.skip(ftype)
4512
      iprot.readFieldEnd()
4513
    iprot.readStructEnd()
4514
 
4515
  def write(self, oprot):
4516
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4517
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4518
      return
483 rajveer 4519
    oprot.writeStructBegin('getOrdersForCustomer_args')
4520
    if self.customerId != None:
4521
      oprot.writeFieldBegin('customerId', TType.I64, 1)
4522
      oprot.writeI64(self.customerId)
94 ashish 4523
      oprot.writeFieldEnd()
483 rajveer 4524
    if self.from_date != None:
4525
      oprot.writeFieldBegin('from_date', TType.I64, 2)
4526
      oprot.writeI64(self.from_date)
94 ashish 4527
      oprot.writeFieldEnd()
483 rajveer 4528
    if self.to_date != None:
4529
      oprot.writeFieldBegin('to_date', TType.I64, 3)
4530
      oprot.writeI64(self.to_date)
94 ashish 4531
      oprot.writeFieldEnd()
483 rajveer 4532
    if self.status != None:
4533
      oprot.writeFieldBegin('status', TType.I32, 4)
4534
      oprot.writeI32(self.status)
4535
      oprot.writeFieldEnd()
94 ashish 4536
    oprot.writeFieldStop()
4537
    oprot.writeStructEnd()
4538
 
4539
  def __repr__(self):
4540
    L = ['%s=%r' % (key, value)
4541
      for key, value in self.__dict__.iteritems()]
4542
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4543
 
4544
  def __eq__(self, other):
4545
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4546
 
4547
  def __ne__(self, other):
4548
    return not (self == other)
4549
 
483 rajveer 4550
class getOrdersForCustomer_result:
94 ashish 4551
  """
4552
  Attributes:
4553
   - success
4554
   - ex
4555
  """
4556
 
4557
  thrift_spec = (
483 rajveer 4558
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
94 ashish 4559
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4560
  )
4561
 
4562
  def __init__(self, success=None, ex=None,):
4563
    self.success = success
4564
    self.ex = ex
4565
 
4566
  def read(self, iprot):
4567
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4568
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4569
      return
4570
    iprot.readStructBegin()
4571
    while True:
4572
      (fname, ftype, fid) = iprot.readFieldBegin()
4573
      if ftype == TType.STOP:
4574
        break
4575
      if fid == 0:
483 rajveer 4576
        if ftype == TType.LIST:
4577
          self.success = []
1382 varun.gupt 4578
          (_etype66, _size63) = iprot.readListBegin()
4579
          for _i67 in xrange(_size63):
4580
            _elem68 = Order()
4581
            _elem68.read(iprot)
4582
            self.success.append(_elem68)
483 rajveer 4583
          iprot.readListEnd()
94 ashish 4584
        else:
4585
          iprot.skip(ftype)
4586
      elif fid == 1:
4587
        if ftype == TType.STRUCT:
4588
          self.ex = TransactionServiceException()
4589
          self.ex.read(iprot)
4590
        else:
4591
          iprot.skip(ftype)
4592
      else:
4593
        iprot.skip(ftype)
4594
      iprot.readFieldEnd()
4595
    iprot.readStructEnd()
4596
 
4597
  def write(self, oprot):
4598
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4599
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4600
      return
483 rajveer 4601
    oprot.writeStructBegin('getOrdersForCustomer_result')
94 ashish 4602
    if self.success != None:
483 rajveer 4603
      oprot.writeFieldBegin('success', TType.LIST, 0)
4604
      oprot.writeListBegin(TType.STRUCT, len(self.success))
1382 varun.gupt 4605
      for iter69 in self.success:
4606
        iter69.write(oprot)
483 rajveer 4607
      oprot.writeListEnd()
94 ashish 4608
      oprot.writeFieldEnd()
4609
    if self.ex != None:
4610
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4611
      self.ex.write(oprot)
4612
      oprot.writeFieldEnd()
4613
    oprot.writeFieldStop()
4614
    oprot.writeStructEnd()
4615
 
4616
  def __repr__(self):
4617
    L = ['%s=%r' % (key, value)
4618
      for key, value in self.__dict__.iteritems()]
4619
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4620
 
4621
  def __eq__(self, other):
4622
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4623
 
4624
  def __ne__(self, other):
4625
    return not (self == other)
4626
 
483 rajveer 4627
class createOrder_args:
94 ashish 4628
  """
4629
  Attributes:
483 rajveer 4630
   - order
94 ashish 4631
  """
4632
 
4633
  thrift_spec = (
4634
    None, # 0
483 rajveer 4635
    (1, TType.STRUCT, 'order', (Order, Order.thrift_spec), None, ), # 1
94 ashish 4636
  )
4637
 
483 rajveer 4638
  def __init__(self, order=None,):
4639
    self.order = order
94 ashish 4640
 
4641
  def read(self, iprot):
4642
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4643
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4644
      return
4645
    iprot.readStructBegin()
4646
    while True:
4647
      (fname, ftype, fid) = iprot.readFieldBegin()
4648
      if ftype == TType.STOP:
4649
        break
4650
      if fid == 1:
483 rajveer 4651
        if ftype == TType.STRUCT:
4652
          self.order = Order()
4653
          self.order.read(iprot)
94 ashish 4654
        else:
4655
          iprot.skip(ftype)
4656
      else:
4657
        iprot.skip(ftype)
4658
      iprot.readFieldEnd()
4659
    iprot.readStructEnd()
4660
 
4661
  def write(self, oprot):
4662
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4663
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4664
      return
483 rajveer 4665
    oprot.writeStructBegin('createOrder_args')
4666
    if self.order != None:
4667
      oprot.writeFieldBegin('order', TType.STRUCT, 1)
4668
      self.order.write(oprot)
94 ashish 4669
      oprot.writeFieldEnd()
4670
    oprot.writeFieldStop()
4671
    oprot.writeStructEnd()
4672
 
4673
  def __repr__(self):
4674
    L = ['%s=%r' % (key, value)
4675
      for key, value in self.__dict__.iteritems()]
4676
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4677
 
4678
  def __eq__(self, other):
4679
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4680
 
4681
  def __ne__(self, other):
4682
    return not (self == other)
4683
 
483 rajveer 4684
class createOrder_result:
94 ashish 4685
  """
4686
  Attributes:
4687
   - success
4688
   - ex
4689
  """
4690
 
4691
  thrift_spec = (
483 rajveer 4692
    (0, TType.I64, 'success', None, None, ), # 0
94 ashish 4693
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4694
  )
4695
 
4696
  def __init__(self, success=None, ex=None,):
4697
    self.success = success
4698
    self.ex = ex
4699
 
4700
  def read(self, iprot):
4701
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4702
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4703
      return
4704
    iprot.readStructBegin()
4705
    while True:
4706
      (fname, ftype, fid) = iprot.readFieldBegin()
4707
      if ftype == TType.STOP:
4708
        break
4709
      if fid == 0:
483 rajveer 4710
        if ftype == TType.I64:
4711
          self.success = iprot.readI64();
94 ashish 4712
        else:
4713
          iprot.skip(ftype)
4714
      elif fid == 1:
4715
        if ftype == TType.STRUCT:
4716
          self.ex = TransactionServiceException()
4717
          self.ex.read(iprot)
4718
        else:
4719
          iprot.skip(ftype)
4720
      else:
4721
        iprot.skip(ftype)
4722
      iprot.readFieldEnd()
4723
    iprot.readStructEnd()
4724
 
4725
  def write(self, oprot):
4726
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4727
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4728
      return
483 rajveer 4729
    oprot.writeStructBegin('createOrder_result')
94 ashish 4730
    if self.success != None:
483 rajveer 4731
      oprot.writeFieldBegin('success', TType.I64, 0)
4732
      oprot.writeI64(self.success)
94 ashish 4733
      oprot.writeFieldEnd()
4734
    if self.ex != None:
4735
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4736
      self.ex.write(oprot)
4737
      oprot.writeFieldEnd()
4738
    oprot.writeFieldStop()
4739
    oprot.writeStructEnd()
4740
 
4741
  def __repr__(self):
4742
    L = ['%s=%r' % (key, value)
4743
      for key, value in self.__dict__.iteritems()]
4744
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4745
 
4746
  def __eq__(self, other):
4747
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4748
 
4749
  def __ne__(self, other):
4750
    return not (self == other)
4751
 
483 rajveer 4752
class getOrder_args:
94 ashish 4753
  """
4754
  Attributes:
483 rajveer 4755
   - id
94 ashish 4756
  """
4757
 
4758
  thrift_spec = (
4759
    None, # 0
483 rajveer 4760
    (1, TType.I64, 'id', None, None, ), # 1
94 ashish 4761
  )
4762
 
483 rajveer 4763
  def __init__(self, id=None,):
4764
    self.id = id
94 ashish 4765
 
4766
  def read(self, iprot):
4767
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4768
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4769
      return
4770
    iprot.readStructBegin()
4771
    while True:
4772
      (fname, ftype, fid) = iprot.readFieldBegin()
4773
      if ftype == TType.STOP:
4774
        break
4775
      if fid == 1:
4776
        if ftype == TType.I64:
483 rajveer 4777
          self.id = iprot.readI64();
94 ashish 4778
        else:
4779
          iprot.skip(ftype)
4780
      else:
4781
        iprot.skip(ftype)
4782
      iprot.readFieldEnd()
4783
    iprot.readStructEnd()
4784
 
4785
  def write(self, oprot):
4786
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4787
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4788
      return
483 rajveer 4789
    oprot.writeStructBegin('getOrder_args')
4790
    if self.id != None:
4791
      oprot.writeFieldBegin('id', TType.I64, 1)
4792
      oprot.writeI64(self.id)
94 ashish 4793
      oprot.writeFieldEnd()
4794
    oprot.writeFieldStop()
4795
    oprot.writeStructEnd()
4796
 
4797
  def __repr__(self):
4798
    L = ['%s=%r' % (key, value)
4799
      for key, value in self.__dict__.iteritems()]
4800
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4801
 
4802
  def __eq__(self, other):
4803
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4804
 
4805
  def __ne__(self, other):
4806
    return not (self == other)
4807
 
483 rajveer 4808
class getOrder_result:
94 ashish 4809
  """
4810
  Attributes:
4811
   - success
4812
   - ex
4813
  """
4814
 
4815
  thrift_spec = (
483 rajveer 4816
    (0, TType.STRUCT, 'success', (Order, Order.thrift_spec), None, ), # 0
94 ashish 4817
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4818
  )
4819
 
4820
  def __init__(self, success=None, ex=None,):
4821
    self.success = success
4822
    self.ex = ex
4823
 
4824
  def read(self, iprot):
4825
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4826
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4827
      return
4828
    iprot.readStructBegin()
4829
    while True:
4830
      (fname, ftype, fid) = iprot.readFieldBegin()
4831
      if ftype == TType.STOP:
4832
        break
4833
      if fid == 0:
483 rajveer 4834
        if ftype == TType.STRUCT:
4835
          self.success = Order()
4836
          self.success.read(iprot)
94 ashish 4837
        else:
4838
          iprot.skip(ftype)
4839
      elif fid == 1:
4840
        if ftype == TType.STRUCT:
4841
          self.ex = TransactionServiceException()
4842
          self.ex.read(iprot)
4843
        else:
4844
          iprot.skip(ftype)
4845
      else:
4846
        iprot.skip(ftype)
4847
      iprot.readFieldEnd()
4848
    iprot.readStructEnd()
4849
 
4850
  def write(self, oprot):
4851
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4852
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4853
      return
483 rajveer 4854
    oprot.writeStructBegin('getOrder_result')
94 ashish 4855
    if self.success != None:
483 rajveer 4856
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
4857
      self.success.write(oprot)
94 ashish 4858
      oprot.writeFieldEnd()
4859
    if self.ex != None:
4860
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4861
      self.ex.write(oprot)
4862
      oprot.writeFieldEnd()
4863
    oprot.writeFieldStop()
4864
    oprot.writeStructEnd()
4865
 
4866
  def __repr__(self):
4867
    L = ['%s=%r' % (key, value)
4868
      for key, value in self.__dict__.iteritems()]
4869
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4870
 
4871
  def __eq__(self, other):
4872
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4873
 
4874
  def __ne__(self, other):
4875
    return not (self == other)
4876
 
483 rajveer 4877
class getLineItemsForOrder_args:
94 ashish 4878
  """
4879
  Attributes:
483 rajveer 4880
   - orderId
94 ashish 4881
  """
4882
 
4883
  thrift_spec = (
4884
    None, # 0
483 rajveer 4885
    (1, TType.I64, 'orderId', None, None, ), # 1
94 ashish 4886
  )
4887
 
483 rajveer 4888
  def __init__(self, orderId=None,):
4889
    self.orderId = orderId
94 ashish 4890
 
4891
  def read(self, iprot):
4892
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4893
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4894
      return
4895
    iprot.readStructBegin()
4896
    while True:
4897
      (fname, ftype, fid) = iprot.readFieldBegin()
4898
      if ftype == TType.STOP:
4899
        break
4900
      if fid == 1:
4901
        if ftype == TType.I64:
483 rajveer 4902
          self.orderId = iprot.readI64();
94 ashish 4903
        else:
4904
          iprot.skip(ftype)
4905
      else:
4906
        iprot.skip(ftype)
4907
      iprot.readFieldEnd()
4908
    iprot.readStructEnd()
4909
 
4910
  def write(self, oprot):
4911
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4912
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4913
      return
483 rajveer 4914
    oprot.writeStructBegin('getLineItemsForOrder_args')
4915
    if self.orderId != None:
4916
      oprot.writeFieldBegin('orderId', TType.I64, 1)
4917
      oprot.writeI64(self.orderId)
94 ashish 4918
      oprot.writeFieldEnd()
4919
    oprot.writeFieldStop()
4920
    oprot.writeStructEnd()
4921
 
4922
  def __repr__(self):
4923
    L = ['%s=%r' % (key, value)
4924
      for key, value in self.__dict__.iteritems()]
4925
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
4926
 
4927
  def __eq__(self, other):
4928
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
4929
 
4930
  def __ne__(self, other):
4931
    return not (self == other)
4932
 
483 rajveer 4933
class getLineItemsForOrder_result:
94 ashish 4934
  """
4935
  Attributes:
4936
   - success
4937
   - ex
4938
  """
4939
 
4940
  thrift_spec = (
483 rajveer 4941
    (0, TType.LIST, 'success', (TType.STRUCT,(LineItem, LineItem.thrift_spec)), None, ), # 0
94 ashish 4942
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
4943
  )
4944
 
4945
  def __init__(self, success=None, ex=None,):
4946
    self.success = success
4947
    self.ex = ex
4948
 
4949
  def read(self, iprot):
4950
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
4951
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
4952
      return
4953
    iprot.readStructBegin()
4954
    while True:
4955
      (fname, ftype, fid) = iprot.readFieldBegin()
4956
      if ftype == TType.STOP:
4957
        break
4958
      if fid == 0:
483 rajveer 4959
        if ftype == TType.LIST:
4960
          self.success = []
1382 varun.gupt 4961
          (_etype73, _size70) = iprot.readListBegin()
4962
          for _i74 in xrange(_size70):
4963
            _elem75 = LineItem()
4964
            _elem75.read(iprot)
4965
            self.success.append(_elem75)
483 rajveer 4966
          iprot.readListEnd()
94 ashish 4967
        else:
4968
          iprot.skip(ftype)
4969
      elif fid == 1:
4970
        if ftype == TType.STRUCT:
4971
          self.ex = TransactionServiceException()
4972
          self.ex.read(iprot)
4973
        else:
4974
          iprot.skip(ftype)
4975
      else:
4976
        iprot.skip(ftype)
4977
      iprot.readFieldEnd()
4978
    iprot.readStructEnd()
4979
 
4980
  def write(self, oprot):
4981
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
4982
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
4983
      return
483 rajveer 4984
    oprot.writeStructBegin('getLineItemsForOrder_result')
94 ashish 4985
    if self.success != None:
483 rajveer 4986
      oprot.writeFieldBegin('success', TType.LIST, 0)
4987
      oprot.writeListBegin(TType.STRUCT, len(self.success))
1382 varun.gupt 4988
      for iter76 in self.success:
4989
        iter76.write(oprot)
483 rajveer 4990
      oprot.writeListEnd()
94 ashish 4991
      oprot.writeFieldEnd()
4992
    if self.ex != None:
4993
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
4994
      self.ex.write(oprot)
4995
      oprot.writeFieldEnd()
4996
    oprot.writeFieldStop()
4997
    oprot.writeStructEnd()
4998
 
4999
  def __repr__(self):
5000
    L = ['%s=%r' % (key, value)
5001
      for key, value in self.__dict__.iteritems()]
5002
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5003
 
5004
  def __eq__(self, other):
5005
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5006
 
5007
  def __ne__(self, other):
5008
    return not (self == other)
5009
 
1528 ankur.sing 5010
class getOrderForCustomer_args:
5011
  """
5012
  Attributes:
5013
   - orderId
5014
   - customerId
5015
  """
5016
 
5017
  thrift_spec = (
5018
    None, # 0
5019
    (1, TType.I64, 'orderId', None, None, ), # 1
5020
    (2, TType.I64, 'customerId', None, None, ), # 2
5021
  )
5022
 
5023
  def __init__(self, orderId=None, customerId=None,):
5024
    self.orderId = orderId
5025
    self.customerId = customerId
5026
 
5027
  def read(self, iprot):
5028
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5029
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5030
      return
5031
    iprot.readStructBegin()
5032
    while True:
5033
      (fname, ftype, fid) = iprot.readFieldBegin()
5034
      if ftype == TType.STOP:
5035
        break
5036
      if fid == 1:
5037
        if ftype == TType.I64:
5038
          self.orderId = iprot.readI64();
5039
        else:
5040
          iprot.skip(ftype)
5041
      elif fid == 2:
5042
        if ftype == TType.I64:
5043
          self.customerId = iprot.readI64();
5044
        else:
5045
          iprot.skip(ftype)
5046
      else:
5047
        iprot.skip(ftype)
5048
      iprot.readFieldEnd()
5049
    iprot.readStructEnd()
5050
 
5051
  def write(self, oprot):
5052
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5053
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5054
      return
5055
    oprot.writeStructBegin('getOrderForCustomer_args')
5056
    if self.orderId != None:
5057
      oprot.writeFieldBegin('orderId', TType.I64, 1)
5058
      oprot.writeI64(self.orderId)
5059
      oprot.writeFieldEnd()
5060
    if self.customerId != None:
5061
      oprot.writeFieldBegin('customerId', TType.I64, 2)
5062
      oprot.writeI64(self.customerId)
5063
      oprot.writeFieldEnd()
5064
    oprot.writeFieldStop()
5065
    oprot.writeStructEnd()
5066
 
5067
  def __repr__(self):
5068
    L = ['%s=%r' % (key, value)
5069
      for key, value in self.__dict__.iteritems()]
5070
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5071
 
5072
  def __eq__(self, other):
5073
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5074
 
5075
  def __ne__(self, other):
5076
    return not (self == other)
5077
 
5078
class getOrderForCustomer_result:
5079
  """
5080
  Attributes:
5081
   - success
5082
   - ex
5083
  """
5084
 
5085
  thrift_spec = (
5086
    (0, TType.STRUCT, 'success', (Order, Order.thrift_spec), None, ), # 0
5087
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5088
  )
5089
 
5090
  def __init__(self, success=None, ex=None,):
5091
    self.success = success
5092
    self.ex = ex
5093
 
5094
  def read(self, iprot):
5095
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5096
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5097
      return
5098
    iprot.readStructBegin()
5099
    while True:
5100
      (fname, ftype, fid) = iprot.readFieldBegin()
5101
      if ftype == TType.STOP:
5102
        break
5103
      if fid == 0:
5104
        if ftype == TType.STRUCT:
5105
          self.success = Order()
5106
          self.success.read(iprot)
5107
        else:
5108
          iprot.skip(ftype)
5109
      elif fid == 1:
5110
        if ftype == TType.STRUCT:
5111
          self.ex = TransactionServiceException()
5112
          self.ex.read(iprot)
5113
        else:
5114
          iprot.skip(ftype)
5115
      else:
5116
        iprot.skip(ftype)
5117
      iprot.readFieldEnd()
5118
    iprot.readStructEnd()
5119
 
5120
  def write(self, oprot):
5121
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5122
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5123
      return
5124
    oprot.writeStructBegin('getOrderForCustomer_result')
5125
    if self.success != None:
5126
      oprot.writeFieldBegin('success', TType.STRUCT, 0)
5127
      self.success.write(oprot)
5128
      oprot.writeFieldEnd()
5129
    if self.ex != None:
5130
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5131
      self.ex.write(oprot)
5132
      oprot.writeFieldEnd()
5133
    oprot.writeFieldStop()
5134
    oprot.writeStructEnd()
5135
 
5136
  def __repr__(self):
5137
    L = ['%s=%r' % (key, value)
5138
      for key, value in self.__dict__.iteritems()]
5139
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5140
 
5141
  def __eq__(self, other):
5142
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5143
 
5144
  def __ne__(self, other):
5145
    return not (self == other)
5146
 
1220 chandransh 5147
class batchOrders_args:
5148
  """
5149
  Attributes:
5150
   - warehouseId
5151
  """
5152
 
5153
  thrift_spec = (
5154
    None, # 0
5155
    (1, TType.I64, 'warehouseId', None, None, ), # 1
5156
  )
5157
 
5158
  def __init__(self, warehouseId=None,):
5159
    self.warehouseId = warehouseId
5160
 
5161
  def read(self, iprot):
5162
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5163
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5164
      return
5165
    iprot.readStructBegin()
5166
    while True:
5167
      (fname, ftype, fid) = iprot.readFieldBegin()
5168
      if ftype == TType.STOP:
5169
        break
5170
      if fid == 1:
5171
        if ftype == TType.I64:
5172
          self.warehouseId = iprot.readI64();
5173
        else:
5174
          iprot.skip(ftype)
5175
      else:
5176
        iprot.skip(ftype)
5177
      iprot.readFieldEnd()
5178
    iprot.readStructEnd()
5179
 
5180
  def write(self, oprot):
5181
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5182
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5183
      return
5184
    oprot.writeStructBegin('batchOrders_args')
5185
    if self.warehouseId != None:
5186
      oprot.writeFieldBegin('warehouseId', TType.I64, 1)
5187
      oprot.writeI64(self.warehouseId)
5188
      oprot.writeFieldEnd()
5189
    oprot.writeFieldStop()
5190
    oprot.writeStructEnd()
5191
 
5192
  def __repr__(self):
5193
    L = ['%s=%r' % (key, value)
5194
      for key, value in self.__dict__.iteritems()]
5195
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5196
 
5197
  def __eq__(self, other):
5198
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5199
 
5200
  def __ne__(self, other):
5201
    return not (self == other)
5202
 
5203
class batchOrders_result:
5204
  """
5205
  Attributes:
5206
   - success
5207
   - ex
5208
  """
5209
 
5210
  thrift_spec = (
5211
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
5212
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5213
  )
5214
 
5215
  def __init__(self, success=None, ex=None,):
5216
    self.success = success
5217
    self.ex = ex
5218
 
5219
  def read(self, iprot):
5220
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5221
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5222
      return
5223
    iprot.readStructBegin()
5224
    while True:
5225
      (fname, ftype, fid) = iprot.readFieldBegin()
5226
      if ftype == TType.STOP:
5227
        break
5228
      if fid == 0:
5229
        if ftype == TType.LIST:
5230
          self.success = []
1382 varun.gupt 5231
          (_etype80, _size77) = iprot.readListBegin()
5232
          for _i81 in xrange(_size77):
5233
            _elem82 = Order()
5234
            _elem82.read(iprot)
5235
            self.success.append(_elem82)
1220 chandransh 5236
          iprot.readListEnd()
5237
        else:
5238
          iprot.skip(ftype)
5239
      elif fid == 1:
5240
        if ftype == TType.STRUCT:
5241
          self.ex = TransactionServiceException()
5242
          self.ex.read(iprot)
5243
        else:
5244
          iprot.skip(ftype)
5245
      else:
5246
        iprot.skip(ftype)
5247
      iprot.readFieldEnd()
5248
    iprot.readStructEnd()
5249
 
5250
  def write(self, oprot):
5251
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5252
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5253
      return
5254
    oprot.writeStructBegin('batchOrders_result')
5255
    if self.success != None:
5256
      oprot.writeFieldBegin('success', TType.LIST, 0)
5257
      oprot.writeListBegin(TType.STRUCT, len(self.success))
1382 varun.gupt 5258
      for iter83 in self.success:
5259
        iter83.write(oprot)
1220 chandransh 5260
      oprot.writeListEnd()
5261
      oprot.writeFieldEnd()
5262
    if self.ex != None:
5263
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5264
      self.ex.write(oprot)
5265
      oprot.writeFieldEnd()
5266
    oprot.writeFieldStop()
5267
    oprot.writeStructEnd()
5268
 
5269
  def __repr__(self):
5270
    L = ['%s=%r' % (key, value)
5271
      for key, value in self.__dict__.iteritems()]
5272
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5273
 
5274
  def __eq__(self, other):
5275
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5276
 
5277
  def __ne__(self, other):
5278
    return not (self == other)
5279
 
1208 chandransh 5280
class markOrderAsOutOfStock_args:
5281
  """
5282
  Attributes:
5283
   - orderId
5284
  """
5285
 
5286
  thrift_spec = (
5287
    None, # 0
5288
    (1, TType.I64, 'orderId', None, None, ), # 1
5289
  )
5290
 
5291
  def __init__(self, orderId=None,):
5292
    self.orderId = orderId
5293
 
5294
  def read(self, iprot):
5295
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5296
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5297
      return
5298
    iprot.readStructBegin()
5299
    while True:
5300
      (fname, ftype, fid) = iprot.readFieldBegin()
5301
      if ftype == TType.STOP:
5302
        break
5303
      if fid == 1:
5304
        if ftype == TType.I64:
5305
          self.orderId = iprot.readI64();
5306
        else:
5307
          iprot.skip(ftype)
5308
      else:
5309
        iprot.skip(ftype)
5310
      iprot.readFieldEnd()
5311
    iprot.readStructEnd()
5312
 
5313
  def write(self, oprot):
5314
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5315
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5316
      return
5317
    oprot.writeStructBegin('markOrderAsOutOfStock_args')
5318
    if self.orderId != None:
5319
      oprot.writeFieldBegin('orderId', TType.I64, 1)
5320
      oprot.writeI64(self.orderId)
5321
      oprot.writeFieldEnd()
5322
    oprot.writeFieldStop()
5323
    oprot.writeStructEnd()
5324
 
5325
  def __repr__(self):
5326
    L = ['%s=%r' % (key, value)
5327
      for key, value in self.__dict__.iteritems()]
5328
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5329
 
5330
  def __eq__(self, other):
5331
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5332
 
5333
  def __ne__(self, other):
5334
    return not (self == other)
5335
 
5336
class markOrderAsOutOfStock_result:
5337
  """
5338
  Attributes:
5339
   - success
5340
   - ex
5341
  """
5342
 
5343
  thrift_spec = (
5344
    (0, TType.BOOL, 'success', None, None, ), # 0
5345
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5346
  )
5347
 
5348
  def __init__(self, success=None, ex=None,):
5349
    self.success = success
5350
    self.ex = ex
5351
 
5352
  def read(self, iprot):
5353
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5354
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5355
      return
5356
    iprot.readStructBegin()
5357
    while True:
5358
      (fname, ftype, fid) = iprot.readFieldBegin()
5359
      if ftype == TType.STOP:
5360
        break
5361
      if fid == 0:
5362
        if ftype == TType.BOOL:
5363
          self.success = iprot.readBool();
5364
        else:
5365
          iprot.skip(ftype)
5366
      elif fid == 1:
5367
        if ftype == TType.STRUCT:
5368
          self.ex = TransactionServiceException()
5369
          self.ex.read(iprot)
5370
        else:
5371
          iprot.skip(ftype)
5372
      else:
5373
        iprot.skip(ftype)
5374
      iprot.readFieldEnd()
5375
    iprot.readStructEnd()
5376
 
5377
  def write(self, oprot):
5378
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5379
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5380
      return
5381
    oprot.writeStructBegin('markOrderAsOutOfStock_result')
5382
    if self.success != None:
5383
      oprot.writeFieldBegin('success', TType.BOOL, 0)
5384
      oprot.writeBool(self.success)
5385
      oprot.writeFieldEnd()
5386
    if self.ex != None:
5387
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5388
      self.ex.write(oprot)
5389
      oprot.writeFieldEnd()
5390
    oprot.writeFieldStop()
5391
    oprot.writeStructEnd()
5392
 
5393
  def __repr__(self):
5394
    L = ['%s=%r' % (key, value)
5395
      for key, value in self.__dict__.iteritems()]
5396
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5397
 
5398
  def __eq__(self, other):
5399
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5400
 
5401
  def __ne__(self, other):
5402
    return not (self == other)
5403
 
759 chandransh 5404
class markOrdersAsManifested_args:
5405
  """
5406
  Attributes:
5407
   - warehouseId
5408
   - providerId
5409
  """
5410
 
5411
  thrift_spec = (
5412
    None, # 0
5413
    (1, TType.I64, 'warehouseId', None, None, ), # 1
5414
    (2, TType.I64, 'providerId', None, None, ), # 2
5415
  )
5416
 
5417
  def __init__(self, warehouseId=None, providerId=None,):
5418
    self.warehouseId = warehouseId
5419
    self.providerId = providerId
5420
 
5421
  def read(self, iprot):
5422
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5423
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5424
      return
5425
    iprot.readStructBegin()
5426
    while True:
5427
      (fname, ftype, fid) = iprot.readFieldBegin()
5428
      if ftype == TType.STOP:
5429
        break
5430
      if fid == 1:
5431
        if ftype == TType.I64:
5432
          self.warehouseId = iprot.readI64();
5433
        else:
5434
          iprot.skip(ftype)
5435
      elif fid == 2:
5436
        if ftype == TType.I64:
5437
          self.providerId = iprot.readI64();
5438
        else:
5439
          iprot.skip(ftype)
5440
      else:
5441
        iprot.skip(ftype)
5442
      iprot.readFieldEnd()
5443
    iprot.readStructEnd()
5444
 
5445
  def write(self, oprot):
5446
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5447
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5448
      return
5449
    oprot.writeStructBegin('markOrdersAsManifested_args')
5450
    if self.warehouseId != None:
5451
      oprot.writeFieldBegin('warehouseId', TType.I64, 1)
5452
      oprot.writeI64(self.warehouseId)
5453
      oprot.writeFieldEnd()
5454
    if self.providerId != None:
5455
      oprot.writeFieldBegin('providerId', TType.I64, 2)
5456
      oprot.writeI64(self.providerId)
5457
      oprot.writeFieldEnd()
5458
    oprot.writeFieldStop()
5459
    oprot.writeStructEnd()
5460
 
5461
  def __repr__(self):
5462
    L = ['%s=%r' % (key, value)
5463
      for key, value in self.__dict__.iteritems()]
5464
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5465
 
5466
  def __eq__(self, other):
5467
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5468
 
5469
  def __ne__(self, other):
5470
    return not (self == other)
5471
 
5472
class markOrdersAsManifested_result:
5473
  """
5474
  Attributes:
5475
   - success
5476
   - ex
5477
  """
5478
 
5479
  thrift_spec = (
5480
    (0, TType.BOOL, 'success', None, None, ), # 0
5481
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5482
  )
5483
 
5484
  def __init__(self, success=None, ex=None,):
5485
    self.success = success
5486
    self.ex = ex
5487
 
5488
  def read(self, iprot):
5489
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5490
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5491
      return
5492
    iprot.readStructBegin()
5493
    while True:
5494
      (fname, ftype, fid) = iprot.readFieldBegin()
5495
      if ftype == TType.STOP:
5496
        break
5497
      if fid == 0:
5498
        if ftype == TType.BOOL:
5499
          self.success = iprot.readBool();
5500
        else:
5501
          iprot.skip(ftype)
5502
      elif fid == 1:
5503
        if ftype == TType.STRUCT:
5504
          self.ex = TransactionServiceException()
5505
          self.ex.read(iprot)
5506
        else:
5507
          iprot.skip(ftype)
5508
      else:
5509
        iprot.skip(ftype)
5510
      iprot.readFieldEnd()
5511
    iprot.readStructEnd()
5512
 
5513
  def write(self, oprot):
5514
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5515
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5516
      return
5517
    oprot.writeStructBegin('markOrdersAsManifested_result')
5518
    if self.success != None:
5519
      oprot.writeFieldBegin('success', TType.BOOL, 0)
5520
      oprot.writeBool(self.success)
5521
      oprot.writeFieldEnd()
5522
    if self.ex != None:
5523
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5524
      self.ex.write(oprot)
5525
      oprot.writeFieldEnd()
5526
    oprot.writeFieldStop()
5527
    oprot.writeStructEnd()
5528
 
5529
  def __repr__(self):
5530
    L = ['%s=%r' % (key, value)
5531
      for key, value in self.__dict__.iteritems()]
5532
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5533
 
5534
  def __eq__(self, other):
5535
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5536
 
5537
  def __ne__(self, other):
5538
    return not (self == other)
5539
 
1113 chandransh 5540
class markOrdersAsPickedUp_args:
5541
  """
5542
  Attributes:
5543
   - providerId
5544
   - pickupDetails
5545
  """
5546
 
5547
  thrift_spec = (
5548
    None, # 0
5549
    (1, TType.I64, 'providerId', None, None, ), # 1
1246 chandransh 5550
    (2, TType.MAP, 'pickupDetails', (TType.STRING,None,TType.STRING,None), None, ), # 2
1113 chandransh 5551
  )
5552
 
5553
  def __init__(self, providerId=None, pickupDetails=None,):
5554
    self.providerId = providerId
5555
    self.pickupDetails = pickupDetails
5556
 
5557
  def read(self, iprot):
5558
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5559
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5560
      return
5561
    iprot.readStructBegin()
5562
    while True:
5563
      (fname, ftype, fid) = iprot.readFieldBegin()
5564
      if ftype == TType.STOP:
5565
        break
5566
      if fid == 1:
5567
        if ftype == TType.I64:
5568
          self.providerId = iprot.readI64();
5569
        else:
5570
          iprot.skip(ftype)
5571
      elif fid == 2:
5572
        if ftype == TType.MAP:
5573
          self.pickupDetails = {}
1382 varun.gupt 5574
          (_ktype85, _vtype86, _size84 ) = iprot.readMapBegin() 
5575
          for _i88 in xrange(_size84):
5576
            _key89 = iprot.readString();
5577
            _val90 = iprot.readString();
5578
            self.pickupDetails[_key89] = _val90
1113 chandransh 5579
          iprot.readMapEnd()
5580
        else:
5581
          iprot.skip(ftype)
5582
      else:
5583
        iprot.skip(ftype)
5584
      iprot.readFieldEnd()
5585
    iprot.readStructEnd()
5586
 
5587
  def write(self, oprot):
5588
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5589
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5590
      return
5591
    oprot.writeStructBegin('markOrdersAsPickedUp_args')
5592
    if self.providerId != None:
5593
      oprot.writeFieldBegin('providerId', TType.I64, 1)
5594
      oprot.writeI64(self.providerId)
5595
      oprot.writeFieldEnd()
5596
    if self.pickupDetails != None:
5597
      oprot.writeFieldBegin('pickupDetails', TType.MAP, 2)
1246 chandransh 5598
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.pickupDetails))
1382 varun.gupt 5599
      for kiter91,viter92 in self.pickupDetails.items():
5600
        oprot.writeString(kiter91)
5601
        oprot.writeString(viter92)
1113 chandransh 5602
      oprot.writeMapEnd()
5603
      oprot.writeFieldEnd()
5604
    oprot.writeFieldStop()
5605
    oprot.writeStructEnd()
5606
 
5607
  def __repr__(self):
5608
    L = ['%s=%r' % (key, value)
5609
      for key, value in self.__dict__.iteritems()]
5610
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5611
 
5612
  def __eq__(self, other):
5613
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5614
 
5615
  def __ne__(self, other):
5616
    return not (self == other)
5617
 
5618
class markOrdersAsPickedUp_result:
5619
  """
5620
  Attributes:
5621
   - success
5622
   - ex
5623
  """
5624
 
5625
  thrift_spec = (
5626
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
5627
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5628
  )
5629
 
5630
  def __init__(self, success=None, ex=None,):
5631
    self.success = success
5632
    self.ex = ex
5633
 
5634
  def read(self, iprot):
5635
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5636
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5637
      return
5638
    iprot.readStructBegin()
5639
    while True:
5640
      (fname, ftype, fid) = iprot.readFieldBegin()
5641
      if ftype == TType.STOP:
5642
        break
5643
      if fid == 0:
5644
        if ftype == TType.LIST:
5645
          self.success = []
1382 varun.gupt 5646
          (_etype96, _size93) = iprot.readListBegin()
5647
          for _i97 in xrange(_size93):
5648
            _elem98 = Order()
5649
            _elem98.read(iprot)
5650
            self.success.append(_elem98)
1113 chandransh 5651
          iprot.readListEnd()
5652
        else:
5653
          iprot.skip(ftype)
5654
      elif fid == 1:
5655
        if ftype == TType.STRUCT:
5656
          self.ex = TransactionServiceException()
5657
          self.ex.read(iprot)
5658
        else:
5659
          iprot.skip(ftype)
5660
      else:
5661
        iprot.skip(ftype)
5662
      iprot.readFieldEnd()
5663
    iprot.readStructEnd()
5664
 
5665
  def write(self, oprot):
5666
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5667
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5668
      return
5669
    oprot.writeStructBegin('markOrdersAsPickedUp_result')
5670
    if self.success != None:
5671
      oprot.writeFieldBegin('success', TType.LIST, 0)
5672
      oprot.writeListBegin(TType.STRUCT, len(self.success))
1382 varun.gupt 5673
      for iter99 in self.success:
5674
        iter99.write(oprot)
1113 chandransh 5675
      oprot.writeListEnd()
5676
      oprot.writeFieldEnd()
5677
    if self.ex != None:
5678
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5679
      self.ex.write(oprot)
5680
      oprot.writeFieldEnd()
5681
    oprot.writeFieldStop()
5682
    oprot.writeStructEnd()
5683
 
5684
  def __repr__(self):
5685
    L = ['%s=%r' % (key, value)
5686
      for key, value in self.__dict__.iteritems()]
5687
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5688
 
5689
  def __eq__(self, other):
5690
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5691
 
5692
  def __ne__(self, other):
5693
    return not (self == other)
5694
 
1132 chandransh 5695
class markOrdersAsDelivered_args:
5696
  """
5697
  Attributes:
5698
   - providerId
5699
   - deliveredOrders
5700
  """
5701
 
5702
  thrift_spec = (
5703
    None, # 0
5704
    (1, TType.I64, 'providerId', None, None, ), # 1
5705
    (2, TType.MAP, 'deliveredOrders', (TType.STRING,None,TType.STRING,None), None, ), # 2
5706
  )
5707
 
5708
  def __init__(self, providerId=None, deliveredOrders=None,):
5709
    self.providerId = providerId
5710
    self.deliveredOrders = deliveredOrders
5711
 
5712
  def read(self, iprot):
5713
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5714
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5715
      return
5716
    iprot.readStructBegin()
5717
    while True:
5718
      (fname, ftype, fid) = iprot.readFieldBegin()
5719
      if ftype == TType.STOP:
5720
        break
5721
      if fid == 1:
5722
        if ftype == TType.I64:
5723
          self.providerId = iprot.readI64();
5724
        else:
5725
          iprot.skip(ftype)
5726
      elif fid == 2:
5727
        if ftype == TType.MAP:
5728
          self.deliveredOrders = {}
1382 varun.gupt 5729
          (_ktype101, _vtype102, _size100 ) = iprot.readMapBegin() 
5730
          for _i104 in xrange(_size100):
5731
            _key105 = iprot.readString();
5732
            _val106 = iprot.readString();
5733
            self.deliveredOrders[_key105] = _val106
1132 chandransh 5734
          iprot.readMapEnd()
5735
        else:
5736
          iprot.skip(ftype)
5737
      else:
5738
        iprot.skip(ftype)
5739
      iprot.readFieldEnd()
5740
    iprot.readStructEnd()
5741
 
5742
  def write(self, oprot):
5743
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5744
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5745
      return
5746
    oprot.writeStructBegin('markOrdersAsDelivered_args')
5747
    if self.providerId != None:
5748
      oprot.writeFieldBegin('providerId', TType.I64, 1)
5749
      oprot.writeI64(self.providerId)
5750
      oprot.writeFieldEnd()
5751
    if self.deliveredOrders != None:
5752
      oprot.writeFieldBegin('deliveredOrders', TType.MAP, 2)
5753
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.deliveredOrders))
1382 varun.gupt 5754
      for kiter107,viter108 in self.deliveredOrders.items():
5755
        oprot.writeString(kiter107)
5756
        oprot.writeString(viter108)
1132 chandransh 5757
      oprot.writeMapEnd()
5758
      oprot.writeFieldEnd()
5759
    oprot.writeFieldStop()
5760
    oprot.writeStructEnd()
5761
 
5762
  def __repr__(self):
5763
    L = ['%s=%r' % (key, value)
5764
      for key, value in self.__dict__.iteritems()]
5765
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5766
 
5767
  def __eq__(self, other):
5768
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5769
 
5770
  def __ne__(self, other):
5771
    return not (self == other)
5772
 
5773
class markOrdersAsDelivered_result:
5774
  """
5775
  Attributes:
5776
   - ex
5777
  """
5778
 
5779
  thrift_spec = (
5780
    None, # 0
5781
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5782
  )
5783
 
5784
  def __init__(self, ex=None,):
5785
    self.ex = ex
5786
 
5787
  def read(self, iprot):
5788
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5789
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5790
      return
5791
    iprot.readStructBegin()
5792
    while True:
5793
      (fname, ftype, fid) = iprot.readFieldBegin()
5794
      if ftype == TType.STOP:
5795
        break
5796
      if fid == 1:
5797
        if ftype == TType.STRUCT:
5798
          self.ex = TransactionServiceException()
5799
          self.ex.read(iprot)
5800
        else:
5801
          iprot.skip(ftype)
5802
      else:
5803
        iprot.skip(ftype)
5804
      iprot.readFieldEnd()
5805
    iprot.readStructEnd()
5806
 
5807
  def write(self, oprot):
5808
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5809
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5810
      return
5811
    oprot.writeStructBegin('markOrdersAsDelivered_result')
5812
    if self.ex != None:
5813
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5814
      self.ex.write(oprot)
5815
      oprot.writeFieldEnd()
5816
    oprot.writeFieldStop()
5817
    oprot.writeStructEnd()
5818
 
5819
  def __repr__(self):
5820
    L = ['%s=%r' % (key, value)
5821
      for key, value in self.__dict__.iteritems()]
5822
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5823
 
5824
  def __eq__(self, other):
5825
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5826
 
5827
  def __ne__(self, other):
5828
    return not (self == other)
5829
 
1135 chandransh 5830
class markOrdersAsFailed_args:
5831
  """
5832
  Attributes:
5833
   - providerId
5834
   - returnedOrders
5835
  """
5836
 
5837
  thrift_spec = (
5838
    None, # 0
5839
    (1, TType.I64, 'providerId', None, None, ), # 1
5840
    (2, TType.MAP, 'returnedOrders', (TType.STRING,None,TType.STRING,None), None, ), # 2
5841
  )
5842
 
5843
  def __init__(self, providerId=None, returnedOrders=None,):
5844
    self.providerId = providerId
5845
    self.returnedOrders = returnedOrders
5846
 
5847
  def read(self, iprot):
5848
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5849
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5850
      return
5851
    iprot.readStructBegin()
5852
    while True:
5853
      (fname, ftype, fid) = iprot.readFieldBegin()
5854
      if ftype == TType.STOP:
5855
        break
5856
      if fid == 1:
5857
        if ftype == TType.I64:
5858
          self.providerId = iprot.readI64();
5859
        else:
5860
          iprot.skip(ftype)
5861
      elif fid == 2:
5862
        if ftype == TType.MAP:
5863
          self.returnedOrders = {}
1382 varun.gupt 5864
          (_ktype110, _vtype111, _size109 ) = iprot.readMapBegin() 
5865
          for _i113 in xrange(_size109):
5866
            _key114 = iprot.readString();
5867
            _val115 = iprot.readString();
5868
            self.returnedOrders[_key114] = _val115
1135 chandransh 5869
          iprot.readMapEnd()
5870
        else:
5871
          iprot.skip(ftype)
5872
      else:
5873
        iprot.skip(ftype)
5874
      iprot.readFieldEnd()
5875
    iprot.readStructEnd()
5876
 
5877
  def write(self, oprot):
5878
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5879
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5880
      return
5881
    oprot.writeStructBegin('markOrdersAsFailed_args')
5882
    if self.providerId != None:
5883
      oprot.writeFieldBegin('providerId', TType.I64, 1)
5884
      oprot.writeI64(self.providerId)
5885
      oprot.writeFieldEnd()
5886
    if self.returnedOrders != None:
5887
      oprot.writeFieldBegin('returnedOrders', TType.MAP, 2)
5888
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.returnedOrders))
1382 varun.gupt 5889
      for kiter116,viter117 in self.returnedOrders.items():
5890
        oprot.writeString(kiter116)
5891
        oprot.writeString(viter117)
1135 chandransh 5892
      oprot.writeMapEnd()
5893
      oprot.writeFieldEnd()
5894
    oprot.writeFieldStop()
5895
    oprot.writeStructEnd()
5896
 
5897
  def __repr__(self):
5898
    L = ['%s=%r' % (key, value)
5899
      for key, value in self.__dict__.iteritems()]
5900
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5901
 
5902
  def __eq__(self, other):
5903
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5904
 
5905
  def __ne__(self, other):
5906
    return not (self == other)
5907
 
5908
class markOrdersAsFailed_result:
5909
  """
5910
  Attributes:
5911
   - ex
5912
  """
5913
 
5914
  thrift_spec = (
5915
    None, # 0
5916
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
5917
  )
5918
 
5919
  def __init__(self, ex=None,):
5920
    self.ex = ex
5921
 
5922
  def read(self, iprot):
5923
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5924
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5925
      return
5926
    iprot.readStructBegin()
5927
    while True:
5928
      (fname, ftype, fid) = iprot.readFieldBegin()
5929
      if ftype == TType.STOP:
5930
        break
5931
      if fid == 1:
5932
        if ftype == TType.STRUCT:
5933
          self.ex = TransactionServiceException()
5934
          self.ex.read(iprot)
5935
        else:
5936
          iprot.skip(ftype)
5937
      else:
5938
        iprot.skip(ftype)
5939
      iprot.readFieldEnd()
5940
    iprot.readStructEnd()
5941
 
5942
  def write(self, oprot):
5943
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
5944
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
5945
      return
5946
    oprot.writeStructBegin('markOrdersAsFailed_result')
5947
    if self.ex != None:
5948
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
5949
      self.ex.write(oprot)
5950
      oprot.writeFieldEnd()
5951
    oprot.writeFieldStop()
5952
    oprot.writeStructEnd()
5953
 
5954
  def __repr__(self):
5955
    L = ['%s=%r' % (key, value)
5956
      for key, value in self.__dict__.iteritems()]
5957
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
5958
 
5959
  def __eq__(self, other):
5960
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
5961
 
5962
  def __ne__(self, other):
5963
    return not (self == other)
5964
 
1246 chandransh 5965
class updateNonDeliveryReason_args:
5966
  """
5967
  Attributes:
5968
   - providerId
5969
   - undeliveredOrders
5970
  """
5971
 
5972
  thrift_spec = (
5973
    None, # 0
5974
    (1, TType.I64, 'providerId', None, None, ), # 1
5975
    (2, TType.MAP, 'undeliveredOrders', (TType.STRING,None,TType.STRING,None), None, ), # 2
5976
  )
5977
 
5978
  def __init__(self, providerId=None, undeliveredOrders=None,):
5979
    self.providerId = providerId
5980
    self.undeliveredOrders = undeliveredOrders
5981
 
5982
  def read(self, iprot):
5983
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
5984
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
5985
      return
5986
    iprot.readStructBegin()
5987
    while True:
5988
      (fname, ftype, fid) = iprot.readFieldBegin()
5989
      if ftype == TType.STOP:
5990
        break
5991
      if fid == 1:
5992
        if ftype == TType.I64:
5993
          self.providerId = iprot.readI64();
5994
        else:
5995
          iprot.skip(ftype)
5996
      elif fid == 2:
5997
        if ftype == TType.MAP:
5998
          self.undeliveredOrders = {}
1382 varun.gupt 5999
          (_ktype119, _vtype120, _size118 ) = iprot.readMapBegin() 
6000
          for _i122 in xrange(_size118):
6001
            _key123 = iprot.readString();
6002
            _val124 = iprot.readString();
6003
            self.undeliveredOrders[_key123] = _val124
1246 chandransh 6004
          iprot.readMapEnd()
6005
        else:
6006
          iprot.skip(ftype)
6007
      else:
6008
        iprot.skip(ftype)
6009
      iprot.readFieldEnd()
6010
    iprot.readStructEnd()
6011
 
6012
  def write(self, oprot):
6013
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6014
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6015
      return
6016
    oprot.writeStructBegin('updateNonDeliveryReason_args')
6017
    if self.providerId != None:
6018
      oprot.writeFieldBegin('providerId', TType.I64, 1)
6019
      oprot.writeI64(self.providerId)
6020
      oprot.writeFieldEnd()
6021
    if self.undeliveredOrders != None:
6022
      oprot.writeFieldBegin('undeliveredOrders', TType.MAP, 2)
6023
      oprot.writeMapBegin(TType.STRING, TType.STRING, len(self.undeliveredOrders))
1382 varun.gupt 6024
      for kiter125,viter126 in self.undeliveredOrders.items():
6025
        oprot.writeString(kiter125)
6026
        oprot.writeString(viter126)
1246 chandransh 6027
      oprot.writeMapEnd()
6028
      oprot.writeFieldEnd()
6029
    oprot.writeFieldStop()
6030
    oprot.writeStructEnd()
6031
 
6032
  def __repr__(self):
6033
    L = ['%s=%r' % (key, value)
6034
      for key, value in self.__dict__.iteritems()]
6035
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6036
 
6037
  def __eq__(self, other):
6038
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6039
 
6040
  def __ne__(self, other):
6041
    return not (self == other)
6042
 
6043
class updateNonDeliveryReason_result:
6044
  """
6045
  Attributes:
6046
   - ex
6047
  """
6048
 
6049
  thrift_spec = (
6050
    None, # 0
6051
    (1, TType.STRUCT, 'ex', (TransactionServiceException, TransactionServiceException.thrift_spec), None, ), # 1
6052
  )
6053
 
6054
  def __init__(self, ex=None,):
6055
    self.ex = ex
6056
 
6057
  def read(self, iprot):
6058
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6059
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6060
      return
6061
    iprot.readStructBegin()
6062
    while True:
6063
      (fname, ftype, fid) = iprot.readFieldBegin()
6064
      if ftype == TType.STOP:
6065
        break
6066
      if fid == 1:
6067
        if ftype == TType.STRUCT:
6068
          self.ex = TransactionServiceException()
6069
          self.ex.read(iprot)
6070
        else:
6071
          iprot.skip(ftype)
6072
      else:
6073
        iprot.skip(ftype)
6074
      iprot.readFieldEnd()
6075
    iprot.readStructEnd()
6076
 
6077
  def write(self, oprot):
6078
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6079
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6080
      return
6081
    oprot.writeStructBegin('updateNonDeliveryReason_result')
6082
    if self.ex != None:
6083
      oprot.writeFieldBegin('ex', TType.STRUCT, 1)
6084
      self.ex.write(oprot)
6085
      oprot.writeFieldEnd()
6086
    oprot.writeFieldStop()
6087
    oprot.writeStructEnd()
6088
 
6089
  def __repr__(self):
6090
    L = ['%s=%r' % (key, value)
6091
      for key, value in self.__dict__.iteritems()]
6092
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6093
 
6094
  def __eq__(self, other):
6095
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6096
 
6097
  def __ne__(self, other):
6098
    return not (self == other)
6099
 
1408 ankur.sing 6100
class getUndeliveredOrders_args:
6101
  """
6102
  Attributes:
6103
   - providerId
6104
   - warehouseId
6105
  """
6106
 
6107
  thrift_spec = (
6108
    None, # 0
6109
    (1, TType.I64, 'providerId', None, None, ), # 1
6110
    (2, TType.I64, 'warehouseId', None, None, ), # 2
6111
  )
6112
 
6113
  def __init__(self, providerId=None, warehouseId=None,):
6114
    self.providerId = providerId
6115
    self.warehouseId = warehouseId
6116
 
6117
  def read(self, iprot):
6118
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6119
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6120
      return
6121
    iprot.readStructBegin()
6122
    while True:
6123
      (fname, ftype, fid) = iprot.readFieldBegin()
6124
      if ftype == TType.STOP:
6125
        break
6126
      if fid == 1:
6127
        if ftype == TType.I64:
6128
          self.providerId = iprot.readI64();
6129
        else:
6130
          iprot.skip(ftype)
6131
      elif fid == 2:
6132
        if ftype == TType.I64:
6133
          self.warehouseId = iprot.readI64();
6134
        else:
6135
          iprot.skip(ftype)
6136
      else:
6137
        iprot.skip(ftype)
6138
      iprot.readFieldEnd()
6139
    iprot.readStructEnd()
6140
 
6141
  def write(self, oprot):
6142
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6143
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6144
      return
6145
    oprot.writeStructBegin('getUndeliveredOrders_args')
6146
    if self.providerId != None:
6147
      oprot.writeFieldBegin('providerId', TType.I64, 1)
6148
      oprot.writeI64(self.providerId)
6149
      oprot.writeFieldEnd()
6150
    if self.warehouseId != None:
6151
      oprot.writeFieldBegin('warehouseId', TType.I64, 2)
6152
      oprot.writeI64(self.warehouseId)
6153
      oprot.writeFieldEnd()
6154
    oprot.writeFieldStop()
6155
    oprot.writeStructEnd()
6156
 
6157
  def __repr__(self):
6158
    L = ['%s=%r' % (key, value)
6159
      for key, value in self.__dict__.iteritems()]
6160
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6161
 
6162
  def __eq__(self, other):
6163
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6164
 
6165
  def __ne__(self, other):
6166
    return not (self == other)
6167
 
6168
class getUndeliveredOrders_result:
6169
  """
6170
  Attributes:
6171
   - success
6172
  """
6173
 
6174
  thrift_spec = (
6175
    (0, TType.LIST, 'success', (TType.STRUCT,(Order, Order.thrift_spec)), None, ), # 0
6176
  )
6177
 
6178
  def __init__(self, success=None,):
6179
    self.success = success
6180
 
6181
  def read(self, iprot):
6182
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6183
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6184
      return
6185
    iprot.readStructBegin()
6186
    while True:
6187
      (fname, ftype, fid) = iprot.readFieldBegin()
6188
      if ftype == TType.STOP:
6189
        break
6190
      if fid == 0:
6191
        if ftype == TType.LIST:
6192
          self.success = []
6193
          (_etype130, _size127) = iprot.readListBegin()
6194
          for _i131 in xrange(_size127):
6195
            _elem132 = Order()
6196
            _elem132.read(iprot)
6197
            self.success.append(_elem132)
6198
          iprot.readListEnd()
6199
        else:
6200
          iprot.skip(ftype)
6201
      else:
6202
        iprot.skip(ftype)
6203
      iprot.readFieldEnd()
6204
    iprot.readStructEnd()
6205
 
6206
  def write(self, oprot):
6207
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6208
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6209
      return
6210
    oprot.writeStructBegin('getUndeliveredOrders_result')
6211
    if self.success != None:
6212
      oprot.writeFieldBegin('success', TType.LIST, 0)
6213
      oprot.writeListBegin(TType.STRUCT, len(self.success))
6214
      for iter133 in self.success:
6215
        iter133.write(oprot)
6216
      oprot.writeListEnd()
6217
      oprot.writeFieldEnd()
6218
    oprot.writeFieldStop()
6219
    oprot.writeStructEnd()
6220
 
6221
  def __repr__(self):
6222
    L = ['%s=%r' % (key, value)
6223
      for key, value in self.__dict__.iteritems()]
6224
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6225
 
6226
  def __eq__(self, other):
6227
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6228
 
6229
  def __ne__(self, other):
6230
    return not (self == other)
6231
 
304 ashish 6232
class getAlerts_args:
6233
  """
6234
  Attributes:
483 rajveer 6235
   - orderId
304 ashish 6236
   - valid
6237
  """
94 ashish 6238
 
304 ashish 6239
  thrift_spec = (
6240
    None, # 0
483 rajveer 6241
    (1, TType.I64, 'orderId', None, None, ), # 1
304 ashish 6242
    (2, TType.BOOL, 'valid', None, None, ), # 2
6243
  )
6244
 
483 rajveer 6245
  def __init__(self, orderId=None, valid=None,):
6246
    self.orderId = orderId
304 ashish 6247
    self.valid = valid
6248
 
6249
  def read(self, iprot):
6250
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6251
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6252
      return
6253
    iprot.readStructBegin()
6254
    while True:
6255
      (fname, ftype, fid) = iprot.readFieldBegin()
6256
      if ftype == TType.STOP:
6257
        break
6258
      if fid == 1:
6259
        if ftype == TType.I64:
483 rajveer 6260
          self.orderId = iprot.readI64();
304 ashish 6261
        else:
6262
          iprot.skip(ftype)
6263
      elif fid == 2:
6264
        if ftype == TType.BOOL:
6265
          self.valid = iprot.readBool();
6266
        else:
6267
          iprot.skip(ftype)
6268
      else:
6269
        iprot.skip(ftype)
6270
      iprot.readFieldEnd()
6271
    iprot.readStructEnd()
6272
 
6273
  def write(self, oprot):
6274
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6275
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6276
      return
6277
    oprot.writeStructBegin('getAlerts_args')
483 rajveer 6278
    if self.orderId != None:
6279
      oprot.writeFieldBegin('orderId', TType.I64, 1)
6280
      oprot.writeI64(self.orderId)
304 ashish 6281
      oprot.writeFieldEnd()
6282
    if self.valid != None:
6283
      oprot.writeFieldBegin('valid', TType.BOOL, 2)
6284
      oprot.writeBool(self.valid)
6285
      oprot.writeFieldEnd()
6286
    oprot.writeFieldStop()
6287
    oprot.writeStructEnd()
6288
 
6289
  def __repr__(self):
6290
    L = ['%s=%r' % (key, value)
6291
      for key, value in self.__dict__.iteritems()]
6292
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6293
 
6294
  def __eq__(self, other):
6295
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6296
 
6297
  def __ne__(self, other):
6298
    return not (self == other)
6299
 
6300
class getAlerts_result:
6301
  """
6302
  Attributes:
6303
   - success
6304
  """
6305
 
6306
  thrift_spec = (
6307
    (0, TType.LIST, 'success', (TType.STRUCT,(Alert, Alert.thrift_spec)), None, ), # 0
6308
  )
6309
 
6310
  def __init__(self, success=None,):
6311
    self.success = success
6312
 
6313
  def read(self, iprot):
6314
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6315
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6316
      return
6317
    iprot.readStructBegin()
6318
    while True:
6319
      (fname, ftype, fid) = iprot.readFieldBegin()
6320
      if ftype == TType.STOP:
6321
        break
6322
      if fid == 0:
6323
        if ftype == TType.LIST:
6324
          self.success = []
1408 ankur.sing 6325
          (_etype137, _size134) = iprot.readListBegin()
6326
          for _i138 in xrange(_size134):
6327
            _elem139 = Alert()
6328
            _elem139.read(iprot)
6329
            self.success.append(_elem139)
304 ashish 6330
          iprot.readListEnd()
6331
        else:
6332
          iprot.skip(ftype)
6333
      else:
6334
        iprot.skip(ftype)
6335
      iprot.readFieldEnd()
6336
    iprot.readStructEnd()
6337
 
6338
  def write(self, oprot):
6339
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6340
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6341
      return
6342
    oprot.writeStructBegin('getAlerts_result')
6343
    if self.success != None:
6344
      oprot.writeFieldBegin('success', TType.LIST, 0)
6345
      oprot.writeListBegin(TType.STRUCT, len(self.success))
1408 ankur.sing 6346
      for iter140 in self.success:
6347
        iter140.write(oprot)
304 ashish 6348
      oprot.writeListEnd()
6349
      oprot.writeFieldEnd()
6350
    oprot.writeFieldStop()
6351
    oprot.writeStructEnd()
6352
 
6353
  def __repr__(self):
6354
    L = ['%s=%r' % (key, value)
6355
      for key, value in self.__dict__.iteritems()]
6356
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6357
 
6358
  def __eq__(self, other):
6359
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6360
 
6361
  def __ne__(self, other):
6362
    return not (self == other)
6363
 
6364
class setAlert_args:
6365
  """
6366
  Attributes:
483 rajveer 6367
   - orderId
304 ashish 6368
   - unset
6369
   - type
6370
   - comment
6371
  """
6372
 
6373
  thrift_spec = (
6374
    None, # 0
483 rajveer 6375
    (1, TType.I64, 'orderId', None, None, ), # 1
304 ashish 6376
    (2, TType.BOOL, 'unset', None, None, ), # 2
6377
    (3, TType.I64, 'type', None, None, ), # 3
6378
    (4, TType.STRING, 'comment', None, None, ), # 4
6379
  )
6380
 
483 rajveer 6381
  def __init__(self, orderId=None, unset=None, type=None, comment=None,):
6382
    self.orderId = orderId
304 ashish 6383
    self.unset = unset
6384
    self.type = type
6385
    self.comment = comment
6386
 
6387
  def read(self, iprot):
6388
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6389
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6390
      return
6391
    iprot.readStructBegin()
6392
    while True:
6393
      (fname, ftype, fid) = iprot.readFieldBegin()
6394
      if ftype == TType.STOP:
6395
        break
6396
      if fid == 1:
6397
        if ftype == TType.I64:
483 rajveer 6398
          self.orderId = iprot.readI64();
304 ashish 6399
        else:
6400
          iprot.skip(ftype)
6401
      elif fid == 2:
6402
        if ftype == TType.BOOL:
6403
          self.unset = iprot.readBool();
6404
        else:
6405
          iprot.skip(ftype)
6406
      elif fid == 3:
6407
        if ftype == TType.I64:
6408
          self.type = iprot.readI64();
6409
        else:
6410
          iprot.skip(ftype)
6411
      elif fid == 4:
6412
        if ftype == TType.STRING:
6413
          self.comment = iprot.readString();
6414
        else:
6415
          iprot.skip(ftype)
6416
      else:
6417
        iprot.skip(ftype)
6418
      iprot.readFieldEnd()
6419
    iprot.readStructEnd()
6420
 
6421
  def write(self, oprot):
6422
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6423
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6424
      return
6425
    oprot.writeStructBegin('setAlert_args')
483 rajveer 6426
    if self.orderId != None:
6427
      oprot.writeFieldBegin('orderId', TType.I64, 1)
6428
      oprot.writeI64(self.orderId)
304 ashish 6429
      oprot.writeFieldEnd()
6430
    if self.unset != None:
6431
      oprot.writeFieldBegin('unset', TType.BOOL, 2)
6432
      oprot.writeBool(self.unset)
6433
      oprot.writeFieldEnd()
6434
    if self.type != None:
6435
      oprot.writeFieldBegin('type', TType.I64, 3)
6436
      oprot.writeI64(self.type)
6437
      oprot.writeFieldEnd()
6438
    if self.comment != None:
6439
      oprot.writeFieldBegin('comment', TType.STRING, 4)
6440
      oprot.writeString(self.comment)
6441
      oprot.writeFieldEnd()
6442
    oprot.writeFieldStop()
6443
    oprot.writeStructEnd()
6444
 
6445
  def __repr__(self):
6446
    L = ['%s=%r' % (key, value)
6447
      for key, value in self.__dict__.iteritems()]
6448
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6449
 
6450
  def __eq__(self, other):
6451
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6452
 
6453
  def __ne__(self, other):
6454
    return not (self == other)
6455
 
6456
class setAlert_result:
6457
 
6458
  thrift_spec = (
6459
  )
6460
 
6461
  def read(self, iprot):
6462
    if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
6463
      fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
6464
      return
6465
    iprot.readStructBegin()
6466
    while True:
6467
      (fname, ftype, fid) = iprot.readFieldBegin()
6468
      if ftype == TType.STOP:
6469
        break
6470
      else:
6471
        iprot.skip(ftype)
6472
      iprot.readFieldEnd()
6473
    iprot.readStructEnd()
6474
 
6475
  def write(self, oprot):
6476
    if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
6477
      oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
6478
      return
6479
    oprot.writeStructBegin('setAlert_result')
6480
    oprot.writeFieldStop()
6481
    oprot.writeStructEnd()
6482
 
6483
  def __repr__(self):
6484
    L = ['%s=%r' % (key, value)
6485
      for key, value in self.__dict__.iteritems()]
6486
    return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
6487
 
6488
  def __eq__(self, other):
6489
    return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
6490
 
6491
  def __ne__(self, other):
6492
    return not (self == other)
6493
 
6494